/* =============================================
   天眼 · 企业级暗色主题 v2
   配色: 玄青底 / 金线 / 克莱因蓝 / 警焰红
   调性: 指挥中心 · 情报大屏 · 总裁视角
   ============================================= */

:root {
  /* 背景层级 */
  --bg-deep: #0a0e17;          /* 最底层 - 太空黑 */
  --bg-primary: #0f1520;       /* 主要背景 - 深蓝黑 */
  --bg-secondary: #161e2e;     /* 卡片背景 */
  --bg-tertiary: #1c2638;      /* 卡片hover/选中 */
  --bg-elevated: #1f2a3e;      /* 模态框/弹窗 */
  --bg-glass: rgba(15,21,32,0.85); /* 玻璃态 */
  --bg-card: var(--bg-secondary);   /* 卡片背景 - 覆盖亮色主题的白色 */

  /* 边框 */
  --border-color: rgba(212,175,55,0.12);
  --border-light: rgba(212,175,55,0.06);
  --border-active: rgba(212,175,55,0.4);

  /* 文字 */
  --text-primary: #e8e6e3;     /* 主文字 - 暖白 */
  --text-secondary: #a8a4a0;   /* 次要文字 */
  --text-muted: #6b6a68;       /* 辅助文字 */
  --text-dim: #3d3c3a;        /* 极淡文字 */

  /* 品牌色 - 暗金 + 克莱因蓝 */
  --gold: #d4af37;
  --gold-light: #f0d68a;
  --gold-dark: #a0842c;
  --blue: #0a4da4;
  --blue-light: #1a6ad4;
  --blue-glow: rgba(10,77,164,0.3);

  /* 语义色 */
  --red: #c41e1e;
  --red-light: #e84545;
  --red-glow: rgba(196,30,30,0.25);
  --orange: #d97706;
  --green: #018b8d;
  --green-light: #0abab5;
  --purple: #7c5ce7;

  /* 卡片 */
  --card-bg: linear-gradient(135deg, #161e2e 0%, #1a2335 100%);
  --card-border: 1px solid rgba(212,175,55,0.08);
  --card-shadow: 0 2px 20px rgba(0,0,0,0.3);
  --card-radius: 8px;

  /* 侧栏 */
  --sidebar-bg: linear-gradient(180deg, #0a0e17 0%, #0f1520 100%);
  --sidebar-width: 220px;
  --sidebar-border: 1px solid rgba(212,175,55,0.06);

  /* 动效 */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.3s ease;
}

/* ========== 基础 ========== */
html, body {
  background: var(--bg-deep) !important;
  margin: 0;
  min-height: 100vh;
}
body {
  background: var(--bg-deep);
  color: var(--text-primary);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
}

/* ========== 滚动条 ========== */
::-webkit-scrollbar { width: 4px; height: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(212,175,55,0.15); border-radius: 2px; }
::-webkit-scrollbar-thumb:hover { background: rgba(212,175,55,0.3); }

/* ========== 布局 ========== */
.app-layout {
  background: var(--bg-deep);
}

/* ========== 侧边栏 ========== */
.sidebar {
  background: var(--sidebar-bg);
  border-right: var(--sidebar-border);
  width: var(--sidebar-width);
}

.sidebar-header {
  border-bottom: 1px solid rgba(212,175,55,0.08);
  padding: 20px 16px;
}

.sidebar-logo {
  color: var(--gold) !important;
  padding: 20px 12px;
  gap: 10px;
}

.logo-icon {
  font-size: 14px !important;
  line-height: 1;
}

.sidebar-logo span {
  color: var(--text-primary);
}

.sidebar-nav {
  padding: 12px 8px;
}

.sidebar-nav a {
  color: var(--text-secondary);
  padding: 10px 12px;
  margin: 2px 0;
  border-radius: 6px;
  font-size: 13px;
  transition: all var(--transition-fast);
  border-left: 2px solid transparent;
}

.sidebar-nav a:hover {
  background: rgba(212,175,55,0.06);
  color: var(--text-primary);
}

.sidebar-nav a.active {
  background: rgba(212,175,55,0.08);
  color: var(--gold);
  border-left-color: var(--gold);
}

.sidebar-nav a .icon {
  margin-right: 8px;
  font-size: 15px;
}

.sidebar-footer {
  border-top: 1px solid rgba(212,175,55,0.08);
  padding: 12px 8px;
  margin-top: auto;
}

.sidebar-footer a {
  color: var(--text-muted);
  padding: 8px 12px;
  font-size: 12px;
}

.sidebar-footer a:hover {
  color: var(--text-secondary);
  background: rgba(212,175,55,0.04);
}

/* ========== 全屏展示模式：侧栏隐藏 + 悬停滑出 ========== */
/* 用 JS 直接操控 sidebar.style.display，CSS 只负责全屏时侧栏浮出的样式 */

/* 全屏时，根背景为深色，防止白底 */
:fullscreen,
:-webkit-full-screen {
  background: var(--bg-deep) !important;
}

/* 全屏时鼠标移到左边缘侧栏浮出（由 JS 加 fs-sidebar-visible 类） */
:fullscreen.fs-sidebar-visible .sidebar,
:-webkit-full-screen.fs-sidebar-visible .sidebar {
  position: fixed !important;
  left: 0 !important;
  top: 0 !important;
  width: 220px;
  height: 100vh;
  z-index: 100;
  flex-direction: column;
  box-shadow: 4px 0 24px rgba(0,0,0,0.5);
  border-right: none;
}

/* 全屏模式内容区域占满 */
:fullscreen .app-layout,
:-webkit-full-screen .app-layout {
  min-height: 100vh;
  background: var(--bg-deep);
}

:fullscreen .main-content,
:-webkit-full-screen .main-content {
  margin-left: 0;
  width: 100%;
  min-height: 100vh;
  background: var(--bg-primary);
}

:fullscreen .main-container,
:-webkit-full-screen .main-container {
  max-width: 100%;
  padding-left: 28px;
  padding-right: 28px;
}

/* 全屏模式强制卡片保持深色 */
:fullscreen .card,
:-webkit-full-screen .card,
:fullscreen .stat-card,
:-webkit-full-screen .stat-card,
:fullscreen .admin-section,
:-webkit-full-screen .admin-section {
  background: linear-gradient(135deg, #161e2e 0%, #1a2335 100%) !important;
}

/* 全屏模式：大屏沉浸增强（更大字号、更多留白） */
:fullscreen .stat-card .value,
:-webkit-full-screen .stat-card .value {
  font-size: 36px;
}

:fullscreen .stat-card,
:-webkit-full-screen .stat-card {
  padding: 20px 24px;
}

:fullscreen .card-header h3,
:-webkit-full-screen .card-header h3 {
  font-size: 16px;
}

:fullscreen .page-header h1,
:-webkit-full-screen .page-header h1 {
  font-size: 24px;
}

:fullscreen .page-header p,
:-webkit-full-screen .page-header p {
  font-size: 14px;
}

/* 兼容旧版：JS 添加 fs-active 类也能触发 */
.app-layout.fs-active .sidebar {
  display: none !important;
}

.app-layout.fs-active.fs-sidebar-visible .sidebar {
  display: flex !important;
  position: fixed !important;
  left: 0 !important;
  top: 0 !important;
  width: 220px;
  height: 100vh;
  z-index: 100;
  flex-direction: column;
  box-shadow: 4px 0 24px rgba(0,0,0,0.5);
  border-right: none;
}

.app-layout.fs-active .main-content {
  margin-left: 0;
  width: 100%;
}

/* ========== 主内容 ========== */
.main-content {
  background: var(--bg-primary);
}

.main-container {
  padding: 16px 20px;
}

/* ========== 页面标题 ========== */
.page-header h1 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: 1px;
}

.page-header h1 span {
  font-size: 22px;
}

.page-header p {
  color: var(--text-muted);
  font-size: 13px;
}

.header-sub {
  font-size: 11px;
  color: var(--text-muted);
  background: rgba(212,175,55,0.06);
  border: 1px solid rgba(212,175,55,0.1);
}

/* ========== 统计卡片 ========== */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.stat-card {
  background: var(--card-bg);
  border: var(--card-border);
  border-radius: var(--card-radius);
  box-shadow: var(--card-shadow);
  padding: 16px;
  position: relative;
  overflow: hidden;
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, var(--gold), transparent);
  opacity: 0.6;
}

.stat-card .label {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 4px;
}

.stat-card .value {
  font-size: 28px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.1;
}

.stat-card .sub {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* 语义色卡 */
.stat-card.accent-gold .value { color: var(--gold); }
.stat-card.accent-blue .value { color: var(--blue-light); }
.stat-card.accent-red .value { color: var(--red-light); }
.stat-card.accent-green .value { color: var(--green-light); }
.stat-card.accent-purple .value { color: var(--purple); }
.stat-card.accent-orange .value { color: var(--orange); }
.stat-card.accent-cyan .value { color: var(--green-light); }

.stat-card.accent-gold::before { background: linear-gradient(90deg, var(--gold), transparent); }
.stat-card.accent-blue::before { background: linear-gradient(90deg, var(--blue-light), transparent); }
.stat-card.accent-red::before { background: linear-gradient(90deg, var(--red-light), transparent); }
.stat-card.accent-green::before { background: linear-gradient(90deg, var(--green-light), transparent); }
.stat-card.accent-purple::before { background: linear-gradient(90deg, var(--purple), transparent); }
.stat-card.accent-orange::before { background: linear-gradient(90deg, var(--orange), transparent); }
.stat-card.accent-cyan::before { background: linear-gradient(90deg, var(--green-light), transparent); }

/* ========== 卡片 ========== */
.card {
  background: var(--card-bg);
  border: var(--card-border);
  border-radius: var(--card-radius);
  box-shadow: var(--card-shadow);
}

.card-header {
  padding: 14px 16px 10px;
  border-bottom: 1px solid rgba(212,175,55,0.06);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.card-header h3 {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0.5px;
}

.card-body {
  padding: 12px 16px;
}

.card-body.compact {
  padding: 8px 12px;
}

/* ========== 情报卡片 ========== */
.intel-card {
  padding: 10px 12px;
  margin: 4px 0;
  background: var(--bg-secondary);
  border: 1px solid rgba(212,175,55,0.04);
  border-radius: 6px;
  transition: all var(--transition-fast);
}

.intel-card:hover {
  background: var(--bg-tertiary);
  border-color: rgba(212,175,55,0.1);
}

.intel-card .top {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
}

.intel-card .summary {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 4px 0;
}

.intel-card .meta {
  display: flex;
  gap: 12px;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 6px;
}

.brand-tag {
  font-weight: 600;
  font-size: 12px;
  color: var(--gold);
}

.event-tag {
  font-size: 10px;
  padding: 1px 6px;
  border-radius: 3px;
  background: rgba(212,175,55,0.1);
  color: var(--gold-light);
}

/* ========== 标签 ========== */
.tag {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 3px;
  font-weight: 500;
}

.tag-gold { background: rgba(212,175,55,0.15); color: var(--gold); }
.tag-blue { background: rgba(10,77,164,0.2); color: var(--blue-light); }
.tag-red { background: rgba(196,30,30,0.2); color: var(--red-light); }
.tag-green { background: rgba(1,139,141,0.2); color: var(--green-light); }
.tag-purple { background: rgba(124,92,231,0.2); color: var(--purple); }
.tag-orange { background: rgba(217,119,6,0.2); color: var(--orange); }
.tag-cyan { background: rgba(10,186,181,0.2); color: var(--green-light); }
.tag-gray { background: rgba(107,106,104,0.15); color: var(--text-muted); }
.tag-yellow { background: rgba(212,175,55,0.15); color: var(--gold-light); }

/* ========== 按钮 ========== */
.btn {
  font-size: 12px;
  padding: 6px 14px;
  border-radius: 4px;
  border: 1px solid rgba(212,175,55,0.2);
  background: var(--bg-secondary);
  color: var(--text-primary);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn:hover {
  background: var(--bg-tertiary);
  border-color: rgba(212,175,55,0.3);
}

.btn-primary {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
}

.btn-primary:hover {
  background: var(--blue-light);
  border-color: var(--blue-light);
}

.btn-outline {
  background: transparent;
  border-color: rgba(212,175,55,0.2);
  color: var(--text-secondary);
}

.btn-sm {
  font-size: 11px;
  padding: 4px 10px;
}

/* ========== 筛选按钮 ========== */
.filter-btn {
  font-size: 11px;
  padding: 4px 12px;
  border-radius: 4px;
  border: 1px solid rgba(212,175,55,0.1);
  background: var(--bg-secondary);
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.filter-btn:hover {
  border-color: rgba(212,175,55,0.25);
  color: var(--text-secondary);
}

.filter-btn.active {
  background: rgba(212,175,55,0.12);
  border-color: var(--gold);
  color: var(--gold);
}

/* ========== 表格 ========== */
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.data-table thead th {
  color: var(--text-muted);
  font-weight: 500;
  text-transform: uppercase;
  font-size: 10px;
  letter-spacing: 0.5px;
  padding: 8px 10px;
  border-bottom: 1px solid rgba(212,175,55,0.08);
  text-align: left;
}

.data-table tbody td {
  padding: 8px 10px;
  border-bottom: 1px solid rgba(212,175,55,0.04);
  color: var(--text-secondary);
}

.data-table tbody tr:hover {
  background: rgba(212,175,55,0.03);
}

/* ========== 页脚栏 ========== */
.footer-bar {
  color: var(--text-muted);
  font-size: 11px;
  border-top: 1px solid rgba(212,175,55,0.06);
  padding: 12px 0;
  margin-top: 20px;
}

/* ========== 空状态 ========== */
.empty-state {
  color: var(--text-muted);
  padding: 40px 20px;
  text-align: center;
}

.empty-state p {
  margin: 4px 0;
  font-size: 13px;
}

/* ========== 加载 ========== */
.loading {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 40px;
}

.spinner {
  width: 24px;
  height: 24px;
  border: 2px solid rgba(212,175,55,0.1);
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ========== 品牌梯队 ========== */
.tier-section {
  margin-bottom: 20px;
}

.tier-header {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  padding: 8px 12px;
  background: var(--bg-secondary);
  border-left: 2px solid var(--gold);
  border-radius: 4px;
  margin-bottom: 8px;
}

/* ========== 品牌卡片网格 ========== */
/* ========== 品牌分类排行条 ========== */
.brand-rank-list { margin-top: 12px; }
.brand-rank-row { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.brand-rank-name { width: 80px; font-size: 12px; font-weight: 600; color: var(--text-primary); flex-shrink: 0; }
.brand-rank-bar { flex: 1; height: 18px; background: var(--bg-secondary); border-radius: 4px; overflow: hidden; }
.brand-rank-fill { display: block; height: 100%; border-radius: 4px; transition: width 0.4s; opacity: 0.85; }
.brand-rank-data { width: 180px; font-size: 11px; color: var(--text-muted); flex-shrink: 0; text-align: right; }
.brand-rank-data strong { color: var(--text-primary); font-size: 13px; }

/* ========== 预警项 ========== */
.alert-item {
  display: flex;
  gap: 10px;
  padding: 10px 12px;
  margin: 4px 0;
  background: var(--bg-secondary);
  border-radius: 6px;
  border-left: 3px solid transparent;
}

.alert-item.high {
  border-left-color: var(--red);
  background: rgba(196,30,30,0.06);
}

.alert-item.medium {
  border-left-color: var(--orange);
}

.alert-item .badge {
  font-size: 16px;
  line-height: 1.4;
}

.alert-item .title {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.alert-item .desc {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.4;
}

.alert-item .meta {
  font-size: 10px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* ========== 管理=tab ========== */
.tab-btn {
  font-size: 12px;
  padding: 6px 14px;
  border: 1px solid rgba(212,175,55,0.1);
  background: var(--bg-secondary);
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition-fast);
  border-radius: 4px;
}

.tab-btn:hover {
  background: var(--bg-tertiary);
  color: var(--text-secondary);
}

.tab-btn.active {
  background: rgba(212,175,55,0.1);
  border-color: var(--gold);
  color: var(--gold);
}

/* ========== 模态框 ========== */
.modal {
  background: var(--bg-elevated);
  border: 1px solid rgba(212,175,55,0.15);
  border-radius: 10px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

/* ========== 管理管理页面卡片 ========== */
.admin-section {
  background: var(--card-bg);
  border: var(--card-border);
  border-radius: var(--card-radius);
  box-shadow: var(--card-shadow);
  margin-bottom: 16px;
}

.section-title {
  padding: 12px 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  border-bottom: 1px solid rgba(212,175,55,0.06);
}

.section-body {
  padding: 12px 16px;
}

/* ========== 表单 ========== */
input, textarea, select {
  background: var(--bg-secondary) !important;
  border: 1px solid rgba(212,175,55,0.12) !important;
  color: var(--text-primary) !important;
  border-radius: 4px !important;
  padding: 8px 12px !important;
  font-size: 13px !important;
}

input:focus, textarea:focus, select:focus {
  border-color: var(--gold) !important;
  box-shadow: 0 0 0 2px rgba(212,175,55,0.08) !important;
}

/* ========== 链接 ========== */
a {
  color: var(--gold-light);
  text-decoration: none;
}

a:hover {
  color: var(--gold);
}

/* ========== 区域面板 ========== */
.region-detail-panel {
  padding: 12px;
}

.rd-header {
  margin-bottom: 12px;
}

.rd-city-item {
  padding: 10px;
  margin: 6px 0;
  background: var(--bg-secondary);
  border-radius: 6px;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.rd-city-item:hover {
  background: var(--bg-tertiary);
}

.rd-section-label {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

.rd-intel-item {
  padding: 8px;
  margin: 4px 0;
  background: var(--bg-secondary);
  border-radius: 4px;
}

/* ========== 输入组 ========== */
.form-card {
  background: var(--bg-secondary);
  border: 1px solid rgba(212,175,55,0.06);
  border-radius: 6px;
  padding: 16px;
  margin-bottom: 12px;
}

/* ========== 其他 ========== */
/* ========== 顶部状态栏 ========== */
.top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(212,175,55,0.08);
}

.top-bar-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.top-bar-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.page-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: 1px;
  margin: 0;
}

.status-indicator {
  font-size: 10px;
  color: var(--green-light);
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; }
}

.status-text {
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 0.5px;
}

.info-chip {
  font-size: 11px;
  color: var(--text-muted);
  padding: 3px 8px;
  background: rgba(212,175,55,0.04);
  border: 1px solid rgba(212,175,55,0.06);
  border-radius: 4px;
  white-space: nowrap;
}

/* ========== KPI 信号板 ========== */
.kpi-row {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 1px;
  background: rgba(212,175,55,0.06);
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 20px;
}

.kpi-tile {
  background: var(--bg-primary);
  padding: 14px 12px;
  text-align: center;
  position: relative;
  transition: background var(--transition-fast);
}

.kpi-tile:hover {
  background: var(--bg-secondary);
}

.kpi-tile::after {
  content: '';
  position: absolute;
  top: 0;
  left: 10%;
  width: 80%;
  height: 2px;
  border-radius: 0 0 2px 2px;
  opacity: 0.8;
}

.kpi-tile.accent-cyan::after { background: var(--green-light); }
.kpi-tile.accent-green::after { background: var(--green); }
.kpi-tile.accent-purple::after { background: var(--purple); }
.kpi-tile.accent-orange::after { background: var(--orange); }
.kpi-tile.accent-yellow::after { background: var(--gold); }
.kpi-tile.accent-blue::after { background: var(--blue-light); }

.kpi-label {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 4px;
}

.kpi-value {
  font-size: 26px;
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 2px;
  color: var(--text-primary);
}

.kpi-tile.accent-cyan .kpi-value { color: var(--green-light); }
.kpi-tile.accent-green .kpi-value { color: var(--green); }
.kpi-tile.accent-purple .kpi-value { color: var(--purple); }
.kpi-tile.accent-orange .kpi-value { color: var(--orange); }
.kpi-tile.accent-yellow .kpi-value { color: var(--gold); }
.kpi-tile.accent-blue .kpi-value { color: var(--blue-light); }

.kpi-delta {
  font-size: 10px;
  color: var(--text-muted);
}

/* ========== 面板系统（平铺） ========== */
.panel-row {
  display: flex;
  gap: 1px;
  background: rgba(212,175,55,0.06);
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 1px;
}

.panel {
  flex: 1;
  background: var(--bg-primary);
  padding: 0;
  overflow: hidden;
}

.panel-wide {
  flex: 1.5;
}

.panel-narrow {
  flex: 1;
}

.panel-full {
  background: var(--bg-primary);
  border: none;
  border-radius: 6px;
  margin-bottom: 1px;
  overflow: hidden;
}

.panel-titlebar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px 6px;
  border-bottom: 1px solid rgba(212,175,55,0.05);
}

.panel-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0.3px;
}

.panel-badge {
  font-size: 10px;
  color: var(--text-muted);
  padding: 2px 8px;
  border-radius: 10px;
  background: rgba(212,175,55,0.06);
}

.panel-sub {
  font-size: 10px;
  color: var(--text-muted);
}

.panel-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.panel-body {
  padding: 8px 14px 14px;
}

.panel-chart {
  padding: 4px 14px 14px;
  height: 280px;
}

.panel-report {
  max-height: 600px;
  overflow-y: auto;
}

/* ========== 态势流条目 ========== */
.flow-item {
  display: flex;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(212,175,55,0.03);
}

.flow-item:last-child {
  border-bottom: none;
}

.flow-icon {
  font-size: 14px;
  line-height: 1.5;
  flex-shrink: 0;
}

.flow-content {
  flex: 1;
  min-width: 0;
}

.flow-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.flow-desc {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.flow-meta {
  font-size: 10px;
  color: var(--text-muted);
  margin-top: 3px;
}

/* ========== 列表条目 ========== */
.list-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 0;
  border-bottom: 1px solid rgba(212,175,55,0.03);
  font-size: 12px;
  color: var(--text-secondary);
}

.list-item:last-child {
  border-bottom: none;
}

.list-item strong {
  color: var(--text-primary);
  font-weight: 600;
}

/* ========== 维度卡片 ========== */
.dim-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 1px;
  background: rgba(212,175,55,0.06);
  border-radius: 4px;
  overflow: hidden;
}

.dim-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 16px 8px;
  background: var(--bg-primary);
  text-decoration: none;
  transition: all var(--transition-fast);
}

.dim-card:hover {
  background: var(--bg-secondary);
}

.dim-icon {
  font-size: 22px;
  line-height: 1;
}

.dim-name {
  font-size: 11px;
  color: var(--text-secondary);
  text-align: center;
  line-height: 1.3;
}

.dim-count {
  font-size: 11px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 4px;
}

.dim-bar {
  display: inline-block;
  width: 40px;
  height: 3px;
  background: rgba(212,175,55,0.08);
  border-radius: 2px;
  overflow: hidden;
  vertical-align: middle;
}

.dim-bar span {
  display: block;
  height: 100%;
  background: var(--gold);
  border-radius: 2px;
  transition: width 0.6s;
}

/* ========== 响应式 ========== */
@media (max-width: 1024px) {
  .kpi-row { grid-template-columns: repeat(3, 1fr); }
  .dim-grid { grid-template-columns: repeat(3, 1fr); }
  .panel-row { flex-direction: column; }
}

@media (max-width: 640px) {
  .kpi-row { grid-template-columns: repeat(2, 1fr); }
  .dim-grid { grid-template-columns: repeat(2, 1fr); }
  .top-bar { flex-direction: column; align-items: flex-start; gap: 8px; }
}
.text-secondary { color: var(--text-secondary); }
.text-muted { color: var(--text-muted); }
.text-sm { font-size: 11px; }

.admin-grid { display: flex; gap: 8px; align-items: center; margin-bottom: 12px; }
.flex-between { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; }
.flex-row { display: flex; align-items: center; gap: 8px; }
.flex-row-wrap { display: flex; flex-wrap: wrap; align-items: center; }

.mb-16 { margin-bottom: 16px; }

/* ========== 监测维度入口（暗色适配） ========== */
.dim-entry {
  background: var(--bg-secondary);
  border-color: var(--border-light);
}
.dim-entry:hover {
  background: var(--bg-tertiary);
  border-color: var(--border-color);
}
