/* ================= 浅色主题：数据库大屏 / 侧边栏 / 页面组件 ================= */
body.light .sidebar { border-right-color: #dbe4f0; }
body.light .brand { border-bottom-color: #dbe4f0; }
body.light .brand-logo { background: linear-gradient(135deg, #0284c7, #22d3ee); color: #fff; }
body.light .brand-text { color: #0f172a; }
body.light .nav-group-title { color: #94a3b8; }
body.light .nav-group-title:hover { color: #0284c7; }
body.light .nav-group-arrow { color: #94a3b8; }
body.light .nav-group.open .nav-group-arrow { color: #0284c7; }
body.light .nav-item.main-tab { background: transparent; border-color: transparent; color: #475569; }
body.light .nav-item.main-tab .tab-label { background: none; border: none; color: inherit; box-shadow: none; }
body.light .nav-item.main-tab:hover { background: rgba(2,132,199,.06); color: #0284c7; }
body.light .nav-item.main-tab.active { background: rgba(2,132,199,.1); border-color: rgba(2,132,199,.35); color: #0891b2; box-shadow: none; }
body.light .sidebar-foot { border-top-color: #dbe4f0; }
body.light .app-main .topbar { border-bottom-color: #dbe4f0; }
body.light .page-title { color: #0f172a; }
body.light .user-info { color: #64748b; }
body.light .page-desc { color: #64748b; }
body.light .filter-bar { background: #f8fafc; border-color: #dbe4f0; }
body.light .filter-item { color: #475569; }
body.light .filter-item input, body.light .filter-item select { background: #fff; border-color: #cbd5e1; color: #0f172a; }
body.light .filter-item input[type="date"]::-webkit-calendar-picker-indicator { filter: none; }
body.light .filter-item.checkbox-item { color: #475569; }
body.light .panel { background: #fff; border-color: #dbe4f0; }
body.light .panel-title { color: #0891b2; }
body.light .panel-sub { color: #94a3b8; }
body.light .btn-ghost { background: #fff; border-color: #cbd5e1; color: #475569; }
body.light .btn-ghost:hover { border-color: #0891b2; color: #0891b2; }
body.light .btn-mini { background: #fff; border-color: #cbd5e1; color: #475569; }
body.light .btn-mini:hover { border-color: #0891b2; color: #0891b2; }
body.light .btn-danger { background: rgba(220,38,38,.06); border-color: rgba(220,38,38,.35); color: #dc2626; }
body.light .sub-tabs { border-bottom-color: #dbe4f0; }
body.light .sub-tab { color: #64748b; }
body.light .sub-tab.active { background: rgba(2,132,199,.08); border-color: rgba(2,132,199,.35); color: #0891b2; }
body.light .info-row .k { color: #64748b; }
body.light .info-row .v { color: #0f172a; }
body.light .hint-line { color: #64748b; }
body.light .hint-line code { background: #f1f5f9; color: #0369a1; }
body.light .preview-url { background: #f8fafc; border-color: #dbe4f0; color: #0369a1; }
body.light .badge-ok { background: rgba(5,150,105,.12); color: #059669; }
body.light .badge-off { background: rgba(220,38,38,.1); color: #dc2626; }
body.light .badge-warn { background: rgba(217,119,6,.12); color: #b45309; }
body.light .empty-cell { color: #64748b; }
body.light .page .kpi-card { background: linear-gradient(180deg, #fff, #f8fafc); border-color: #dbe4f0; }
body.light .page .kpi-label { color: #475569; }
body.light .page .kpi-value { color: #0f766e; text-shadow: none; }
body.light .page .kpi-sub { color: #64748b; }
body.light .page .kpi-card::before { box-shadow: none; }

/* 数据大屏 KPI 卡片：浅色主题下改为浅色底，覆盖深色科技风渐变 */
body.light .home-dash .kpi-card { background: linear-gradient(180deg, #ffffff, #f8fafc); border-color: #dbe4f0; box-shadow: 0 1px 3px rgba(15,23,42,.05); }
body.light .home-dash .kpi-label { color: #475569; }
body.light .home-dash .kpi-value { color: #0f766e; text-shadow: none; }
body.light .home-dash .kpi-sub { color: #64748b; }
body.light .home-dash .kpi-card::before { background: linear-gradient(180deg, #0891b2, #0284c7); box-shadow: none; }

/* 数据大屏浅色主题 */
body.light .home-dash { border-color: #dbe4f0; color: #334155; background: radial-gradient(1200px 600px at 50% 0%, rgba(2,132,199,.10), transparent 62%), linear-gradient(180deg, #ffffff 0%, #f1f5f9 100%); }
body.light .home-dash::before { background-image: linear-gradient(rgba(2,132,199,.06) 1px, transparent 1px), linear-gradient(90deg, rgba(2,132,199,.06) 1px, transparent 1px); }
body.light .dash-top { border-bottom-color: #dbe4f0; }
body.light .dash-status { color: #0891b2; }
body.light .dash-title { color: #0f172a; text-shadow: none; }
body.light .dash-meta { color: #0369a1; }
body.light .dash-range { background: #fff; border-color: #cbd5e1; color: #475569; }
body.light .dash-icon-btn { background: #fff; border-color: #cbd5e1; color: #0891b2; }
body.light .dash-icon-btn:hover { border-color: #0891b2; color: #0369a1; box-shadow: none; }
body.light .dash-panel { background: #fff; border-color: #dbe4f0; }
body.light .dash-panel::before, body.light .dash-panel::after { border-color: #22d3ee; opacity: .8; }
body.light .dash-panel-hd { border-bottom-color: #e8edf5; color: #0891b2; }
body.light .dash-table th { background: #f8fafc; color: #475569; }
body.light .dash-table td { color: #1e293b; border-bottom-color: #eef2f7; }
body.light .dash-empty { color: #64748b; }
body.light .dash-table .td-income { color: #059669; }
body.light .dash-table .live-ok { color: #059669; }
body.light .dash-table .live-fail { color: #dc2626; }
body.light .map-legend { color: #64748b; }
body.light .dash-range { color: #334155; }

@media (max-width: 1100px) {
  .card.app-shell { flex-direction: column; }
  .sidebar { position: static; width: 100%; flex: none; max-height: none; padding-right: 0; border-right: none; border-bottom: 1px solid #1c2940; padding-bottom: 12px; }
  .main-tabs { flex-direction: row; flex-wrap: wrap; }
  .nav-group { flex-direction: row; flex-wrap: wrap; align-items: center; }
  .nav-group-title { width: 100%; cursor: default; }
  .nav-group-content { max-height: none !important; opacity: 1 !important; flex-direction: row; flex-wrap: wrap; }
  .nav-group-arrow { display: none !important; }
  .nav-item.main-tab { width: auto; }
  .sidebar-foot { flex-direction: row; border-top: none; }
  .sidebar-foot .theme-toggle { width: auto; }
  .grid-2 { grid-template-columns: 1fr; }
}
body.light .apidoc-code { background: #f8fafc; border-color: #e2e8f0; color: #334155; }
body.light .apidoc-copy { background: #fff; border: 1px solid #cbd5e1; color: #475569; }
body.light .apidoc-copy:hover { color: #0284c7; border-color: #0284c7; background: #fff; }
@media (max-width: 900px) {
  .apidoc-layout { flex-direction: column; }
  .apidoc-sidebar { width: 100%; position: static; max-height: none; }
  .apidoc-main { padding: 18px 16px; }
}
