/* ===========================================================
   Day01 · XX智维 — 设计系统
   =========================================================== */
:root {
  --bg: #040a14;
  --bg-2: #07111f;
  --panel-a: rgba(19, 33, 56, 0.92);
  --panel-b: rgba(9, 18, 33, 0.94);
  --line: rgba(96, 165, 250, 0.14);
  --line-2: rgba(96, 165, 250, 0.28);
  --txt: #e8f0ff;
  --muted: #93a7c9;
  --dim: #61789e;
  --cyan: #22d3ee;
  --blue: #4f8cff;
  --green: #2dd4a3;
  --amber: #fbbf4a;
  --red: #fb6c7d;
  --purple: #a78bfa;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.28);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body { height: 100%; }

body {
  background:
    radial-gradient(1100px 620px at 12% -12%, rgba(34, 211, 238, 0.13), transparent 62%),
    radial-gradient(900px 560px at 92% -6%, rgba(79, 140, 255, 0.14), transparent 60%),
    radial-gradient(800px 700px at 60% 110%, rgba(45, 212, 163, 0.06), transparent 65%),
    var(--bg);
  color: var(--txt);
  font: 13px/1.55 "HarmonyOS Sans SC", "Microsoft YaHei UI", "Microsoft YaHei", "PingFang SC", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(96, 165, 250, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(96, 165, 250, 0.035) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(1200px 700px at 50% 0%, #000 20%, transparent 78%);
  pointer-events: none;
  z-index: 0;
}

button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; }
a { color: inherit; text-decoration: none; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: rgba(96, 165, 250, 0.22); border-radius: 8px; }
::-webkit-scrollbar-thumb:hover { background: rgba(96, 165, 250, 0.36); }
::-webkit-scrollbar-track { background: transparent; }

#root { position: relative; z-index: 1; display: flex; height: 100vh; }

/* ---------------- 侧边栏 ---------------- */
.sidebar {
  width: 222px;
  flex: 0 0 222px;
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(11, 21, 38, 0.92), rgba(5, 11, 21, 0.88));
  backdrop-filter: blur(6px);
}

.brand { display: flex; align-items: center; gap: 11px; padding: 18px 18px 16px; }
.brand-mark {
  width: 38px; height: 38px; flex: 0 0 38px;
  display: grid; place-items: center;
  border-radius: 11px;
  background: linear-gradient(145deg, rgba(34, 211, 238, 0.22), rgba(79, 140, 255, 0.14));
  border: 1px solid rgba(34, 211, 238, 0.35);
  box-shadow: 0 0 22px rgba(34, 211, 238, 0.18), inset 0 0 14px rgba(34, 211, 238, 0.12);
}
.brand-name { font-size: 15px; font-weight: 700; letter-spacing: 0.5px; }
.brand-sub { font-size: 10.5px; color: var(--dim); letter-spacing: 0.6px; }

.nav { flex: 1; padding: 6px 12px; overflow-y: auto; }
.nav-label { font-size: 10px; color: var(--dim); letter-spacing: 1.6px; padding: 12px 10px 7px; }
.nav-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 11px; margin-bottom: 3px;
  border-radius: 9px;
  color: var(--muted);
  font-size: 13px;
  transition: background 0.16s, color 0.16s;
  border: 1px solid transparent;
}
.nav-item svg { width: 16px; height: 16px; opacity: 0.85; }
.nav-item:hover { background: rgba(96, 165, 250, 0.08); color: var(--txt); }
.nav-item.active {
  background: linear-gradient(90deg, rgba(34, 211, 238, 0.16), rgba(34, 211, 238, 0.02));
  border-color: rgba(34, 211, 238, 0.24);
  color: #dffaff;
  box-shadow: inset 2px 0 0 var(--cyan);
}
.nav-item.active svg { opacity: 1; color: var(--cyan); }
.nav-badge {
  margin-left: auto; font-size: 10px; padding: 1px 6px; border-radius: 20px;
  background: rgba(251, 108, 125, 0.18); color: #ffb3bd; border: 1px solid rgba(251, 108, 125, 0.3);
}

.sidebar-foot { padding: 12px; border-top: 1px solid var(--line); }
.ai-launch {
  width: 100%;
  display: flex; align-items: center; gap: 9px;
  padding: 11px 12px;
  border-radius: 11px;
  background: linear-gradient(120deg, rgba(34, 211, 238, 0.18), rgba(167, 139, 250, 0.14));
  border: 1px solid rgba(34, 211, 238, 0.3);
  font-size: 12.5px;
  transition: transform 0.16s, box-shadow 0.16s;
}
.ai-launch:hover { transform: translateY(-1px); box-shadow: 0 8px 22px rgba(34, 211, 238, 0.16); }
.ai-launch small { display: block; color: #9fd8e4; font-size: 10px; }
.ai-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 8px var(--green); animation: pulse 2.4s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }

/* ---------------- 主区 ---------------- */
.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }

.topbar {
  height: 58px; flex: 0 0 58px;
  display: flex; align-items: center; gap: 14px;
  padding: 0 22px;
  border-bottom: 1px solid var(--line);
  background: rgba(6, 13, 25, 0.55);
  backdrop-filter: blur(8px);
}
.crumbs { font-size: 12px; color: var(--dim); display: flex; align-items: center; gap: 7px; }
.crumbs b { color: var(--muted); font-weight: 500; }
.crumbs .sep { opacity: 0.45; }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 12px; }
.clock { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 9px; border-radius: 20px; font-size: 11px;
  border: 1px solid var(--line); background: rgba(96, 165, 250, 0.07); color: var(--muted);
}
.pill.ok { border-color: rgba(45, 212, 163, 0.3); background: rgba(45, 212, 163, 0.1); color: #8df0d4; }
.avatar {
  width: 30px; height: 30px; border-radius: 50%;
  display: grid; place-items: center; font-size: 12px; font-weight: 600;
  background: linear-gradient(140deg, #2c4a80, #1b2f52);
  border: 1px solid rgba(96, 165, 250, 0.35);
}

.view { flex: 1; overflow-y: auto; padding: 18px 22px 30px; }
.page-head { display: flex; align-items: flex-end; gap: 14px; margin-bottom: 15px; }
.page-title { font-size: 19px; font-weight: 650; letter-spacing: 0.3px; }
.page-desc { font-size: 12px; color: var(--dim); margin-top: 3px; }
.page-actions { margin-left: auto; display: flex; gap: 8px; }

.btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 13px; border-radius: 9px; font-size: 12.5px;
  border: 1px solid var(--line-2); color: var(--txt);
  background: rgba(96, 165, 250, 0.08);
  transition: background 0.16s, border-color 0.16s, transform 0.16s;
}
.btn:hover { background: rgba(96, 165, 250, 0.16); }
.btn:active { transform: translateY(1px); }
.btn.primary {
  background: linear-gradient(120deg, #1fa8c4, #2f6fe0);
  border-color: transparent; color: #fff; font-weight: 600;
  box-shadow: 0 6px 18px rgba(47, 111, 224, 0.28);
}
.btn.primary:hover { filter: brightness(1.08); }
.btn.sm { padding: 5px 10px; font-size: 11.5px; }
.btn.ghost { background: transparent; }

/* ---------------- 网格 / 卡片 ---------------- */
.grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 14px; }
.col-3 { grid-column: span 3; }
.col-4 { grid-column: span 4; }
.col-5 { grid-column: span 5; }
.col-6 { grid-column: span 6; }
.col-7 { grid-column: span 7; }
.col-8 { grid-column: span 8; }
.col-9 { grid-column: span 9; }
.col-12 { grid-column: span 12; }

.card {
  position: relative;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--panel-a), var(--panel-b));
  box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, 0.035);
  overflow: hidden;
}
.card::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(600px 160px at 10% -40%, rgba(34, 211, 238, 0.1), transparent 70%);
}
.card-hd {
  display: flex; align-items: center; gap: 8px;
  padding: 13px 16px 11px;
  border-bottom: 1px solid rgba(96, 165, 250, 0.08);
}
.card-title { font-size: 13.5px; font-weight: 600; letter-spacing: 0.2px; }
.card-title .card-sub { margin-left: 5px; font-weight: 400; }
.card-sub { font-size: 11px; color: var(--dim); }
.card-tools { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.card-bd { padding: 14px 16px 16px; position: relative; z-index: 1; }
.card-bd.flush { padding: 4px 0 0; }

.seg { display: inline-flex; background: rgba(96, 165, 250, 0.08); border: 1px solid var(--line); border-radius: 8px; padding: 2px; }
.seg button { padding: 3px 10px; font-size: 11.5px; color: var(--muted); border-radius: 6px; }
.seg button.on { background: rgba(34, 211, 238, 0.18); color: #d6fbff; }

/* ---------------- KPI ---------------- */
.kpi-row { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.kpi {
  position: relative;
  padding: 13px 15px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(19, 33, 56, 0.9), rgba(9, 18, 33, 0.92));
  overflow: hidden;
}
.kpi::after {
  content: ""; position: absolute; right: -26px; bottom: -30px; width: 92px; height: 92px;
  border-radius: 50%; background: radial-gradient(circle, rgba(34, 211, 238, 0.13), transparent 68%);
}
.kpi-label { font-size: 11.5px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.kpi-value { font-size: 26px; font-weight: 650; letter-spacing: 0.4px; font-variant-numeric: tabular-nums; margin: 4px 0 2px; }
.kpi-value small { font-size: 12px; font-weight: 400; color: var(--muted); margin-left: 3px; }
.kpi-foot { display: flex; align-items: center; gap: 6px; font-size: 10.5px; color: var(--dim); white-space: nowrap; }
.kpi-foot > span:last-child { overflow: hidden; text-overflow: ellipsis; }
.delta { display: inline-flex; align-items: center; gap: 2px; font-size: 10.5px; padding: 1px 5px; border-radius: 5px; }
.delta.up { color: #6ff0c6; background: rgba(45, 212, 163, 0.12); }
.delta.down { color: #ffb3bd; background: rgba(251, 108, 125, 0.12); }
.kpi .spark { position: absolute; right: 12px; top: 34px; opacity: 0.7; }

/* ---------------- 图表 ---------------- */
.chart-wrap { position: relative; }
.chart-wrap svg { display: block; width: 100%; height: auto; overflow: visible; }
.chart-tip {
  position: absolute; pointer-events: none; z-index: 5;
  min-width: 108px; padding: 7px 9px;
  border-radius: 8px; border: 1px solid var(--line-2);
  background: rgba(7, 15, 28, 0.96);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.45);
  font-size: 11px; opacity: 0; transform: translate(-50%, -112%); transition: opacity 0.12s;
}
.chart-tip.show { opacity: 1; }
.chart-tip .tt { color: var(--dim); margin-bottom: 4px; }
.chart-tip .tr { display: flex; align-items: center; gap: 6px; justify-content: space-between; }
.chart-tip .tr b { font-variant-numeric: tabular-nums; }

.legend { display: flex; flex-wrap: wrap; gap: 12px; }
.legend-item { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; color: var(--muted); }
.legend-dot { width: 7px; height: 7px; border-radius: 2px; }

/* ---------------- 列表 / 排行 ---------------- */
.rank { display: flex; flex-direction: column; gap: 11px; }
.rank-item { display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; align-items: center; }
.rank-name { font-size: 12.5px; }
.rank-name span { color: var(--dim); font-size: 10.5px; margin-left: 6px; }
.rank-val { font-size: 12.5px; font-variant-numeric: tabular-nums; }
.rank-val.warn { color: var(--amber); }
.rank-val.bad { color: var(--red); }
.bar-track { grid-column: 1 / -1; height: 5px; border-radius: 4px; background: rgba(96, 165, 250, 0.12); overflow: hidden; }
.bar-fill { height: 100%; border-radius: 4px; transition: width 0.6s ease; }

.feed { display: flex; flex-direction: column; gap: 9px; max-height: 268px; overflow-y: auto; padding-right: 2px; }
.feed-item { display: flex; gap: 9px; padding: 8px 9px; border-radius: 9px; background: rgba(96, 165, 250, 0.05); border: 1px solid transparent; transition: border-color 0.16s, background 0.16s; }
.feed-item:hover { border-color: var(--line-2); background: rgba(96, 165, 250, 0.1); cursor: pointer; }
.feed-dot { width: 6px; height: 6px; border-radius: 50%; margin-top: 6px; flex: 0 0 6px; }
.feed-main { min-width: 0; }
.feed-title { font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.feed-meta { font-size: 10.5px; color: var(--dim); margin-top: 2px; }
.feed-time { margin-left: auto; font-size: 10.5px; color: var(--dim); white-space: nowrap; }

/* ---------------- 标签 ---------------- */
.tag {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 1px 7px; border-radius: 5px; font-size: 10.5px; line-height: 18px;
  border: 1px solid transparent; white-space: nowrap;
}
.tag.red { color: #ffb0b9; background: rgba(251, 108, 125, 0.12); border-color: rgba(251, 108, 125, 0.3); }
.tag.amber { color: #ffd79a; background: rgba(251, 191, 74, 0.12); border-color: rgba(251, 191, 74, 0.3); }
.tag.green { color: #8ff0d2; background: rgba(45, 212, 163, 0.12); border-color: rgba(45, 212, 163, 0.3); }
.tag.blue { color: #a8c7ff; background: rgba(79, 140, 255, 0.14); border-color: rgba(79, 140, 255, 0.3); }
.tag.cyan { color: #a5f3ff; background: rgba(34, 211, 238, 0.12); border-color: rgba(34, 211, 238, 0.3); }
.tag.gray { color: var(--muted); background: rgba(147, 167, 201, 0.1); border-color: rgba(147, 167, 201, 0.22); }
.tag.purple { color: #d6c7ff; background: rgba(167, 139, 250, 0.14); border-color: rgba(167, 139, 250, 0.3); }

/* ---------------- 表格 ---------------- */
.tbl-wrap { overflow: auto; }
table.tbl { width: 100%; border-collapse: collapse; font-size: 12px; }
table.tbl th {
  position: sticky; top: 0; z-index: 2;
  text-align: left; font-weight: 500; color: var(--dim); font-size: 11px;
  padding: 9px 12px; background: rgba(8, 17, 31, 0.96);
  border-bottom: 1px solid var(--line); white-space: nowrap;
}
table.tbl td { padding: 9px 12px; border-bottom: 1px solid rgba(96, 165, 250, 0.07); color: #cfe0f8; }
table.tbl tbody tr { transition: background 0.14s; }
table.tbl tbody tr:hover { background: rgba(96, 165, 250, 0.07); cursor: pointer; }
table.tbl tbody tr.sel { background: rgba(34, 211, 238, 0.09); }
table.tbl .mono { font-family: "Cascadia Mono", Consolas, monospace; font-size: 11.5px; color: var(--muted); }
table.tbl .num { font-variant-numeric: tabular-nums; }

.health { display: flex; align-items: center; gap: 7px; min-width: 92px; }
.health-num { font-variant-numeric: tabular-nums; font-size: 12px; width: 22px; }
.health-bar { flex: 1; height: 4px; border-radius: 3px; background: rgba(96, 165, 250, 0.14); overflow: hidden; }
.health-bar i { display: block; height: 100%; border-radius: 3px; }

/* ---------------- 空状态 / 提示 ---------------- */
.empty { padding: 34px 12px; text-align: center; color: var(--dim); font-size: 12px; }

/* ---------------- 抽屉 ---------------- */
.mask {
  position: fixed; inset: 0; background: rgba(2, 6, 14, 0.55);
  backdrop-filter: blur(2px); opacity: 0; pointer-events: none; transition: opacity 0.2s; z-index: 40;
}
.mask.show { opacity: 1; pointer-events: auto; }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; width: 480px; max-width: 92vw;
  background: linear-gradient(180deg, #0c1729, #070f1c);
  border-left: 1px solid var(--line-2);
  box-shadow: -18px 0 46px rgba(0, 0, 0, 0.5);
  transform: translateX(102%); transition: transform 0.26s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 41; display: flex; flex-direction: column;
}
.drawer.show { transform: none; }
.drawer-hd { display: flex; align-items: flex-start; gap: 10px; padding: 17px 18px 13px; border-bottom: 1px solid var(--line); }
.drawer-title { font-size: 15px; font-weight: 600; }
.drawer-sub { font-size: 11.5px; color: var(--dim); margin-top: 2px; }
.drawer-bd { flex: 1; overflow-y: auto; padding: 16px 18px 26px; }
.icon-btn { width: 28px; height: 28px; border-radius: 7px; display: grid; place-items: center; color: var(--muted); border: 1px solid transparent; }
.icon-btn:hover { background: rgba(96, 165, 250, 0.1); border-color: var(--line); }

.kv { display: grid; grid-template-columns: 96px 1fr; gap: 8px 10px; font-size: 12px; }
.kv dt { color: var(--dim); }
.kv dd { color: #d5e4fa; }

/* ---------------- AI 面板 ---------------- */
.ai-panel {
  position: fixed; right: 22px; bottom: 22px; width: 418px; height: 566px; max-height: 76vh;
  display: flex; flex-direction: column;
  border-radius: 16px; border: 1px solid rgba(34, 211, 238, 0.28);
  background: linear-gradient(180deg, rgba(12, 24, 42, 0.985), rgba(6, 13, 25, 0.99));
  box-shadow: 0 26px 70px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(34, 211, 238, 0.06), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  z-index: 50; transform: translateY(16px) scale(0.98); opacity: 0; pointer-events: none;
  transition: transform 0.22s, opacity 0.22s;
}
.ai-panel.show { transform: none; opacity: 1; pointer-events: auto; }
.ai-hd { display: flex; align-items: center; gap: 9px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.ai-orb {
  width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center;
  background: linear-gradient(140deg, rgba(34, 211, 238, 0.3), rgba(167, 139, 250, 0.25));
  border: 1px solid rgba(34, 211, 238, 0.4);
  box-shadow: 0 0 16px rgba(34, 211, 238, 0.25);
}
.ai-hd .t { font-size: 12.5px; font-weight: 600; }
.ai-hd .s { font-size: 10.5px; color: var(--dim); }
.chat { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 12px; }
.msg { max-width: 92%; font-size: 12.5px; line-height: 1.65; }
.msg .bubble { padding: 9px 11px; border-radius: 11px; }
.msg.ai { align-self: flex-start; }
.msg.ai .bubble { background: rgba(34, 211, 238, 0.08); border: 1px solid rgba(34, 211, 238, 0.18); border-top-left-radius: 3px; }
.msg.user { align-self: flex-end; }
.msg.user .bubble { background: linear-gradient(135deg, rgba(47, 111, 224, 0.5), rgba(31, 168, 196, 0.42)); border: 1px solid rgba(79, 140, 255, 0.4); border-top-right-radius: 3px; }
.msg .bubble p { margin: 0 0 6px; }
.msg .bubble p:last-child { margin-bottom: 0; }
.msg .bubble ul { margin: 4px 0 4px 16px; }
.msg .bubble li { margin-bottom: 3px; }
.msg .bubble b { color: #9ff3ff; font-weight: 600; }
.msg .cite { margin-top: 7px; padding-top: 7px; border-top: 1px dashed rgba(96, 165, 250, 0.22); font-size: 10.5px; color: var(--dim); }
.msg .cite span { display: block; margin-top: 2px; color: #9db7dd; }
.quick { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 14px 10px; }
.chip {
  font-size: 11px; padding: 4px 9px; border-radius: 20px;
  border: 1px solid var(--line-2); color: var(--muted); background: rgba(96, 165, 250, 0.06);
  transition: all 0.15s;
}
.chip:hover { border-color: rgba(34, 211, 238, 0.45); color: #d9fbff; background: rgba(34, 211, 238, 0.12); }
.ai-input { display: flex; gap: 8px; padding: 10px 12px 12px; border-top: 1px solid var(--line); }
.ai-input input {
  flex: 1; background: rgba(96, 165, 250, 0.07); border: 1px solid var(--line);
  border-radius: 9px; padding: 8px 11px; font-size: 12.5px; outline: none;
}
.ai-input input:focus { border-color: rgba(34, 211, 238, 0.5); box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.1); }
.send { width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; background: linear-gradient(135deg, #1fa8c4, #2f6fe0); color: #fff; }

.typing span { display: inline-block; width: 4px; height: 4px; border-radius: 50%; background: #7fe8f6; margin-right: 3px; animation: blink 1.2s infinite; }
.typing span:nth-child(2) { animation-delay: 0.2s; }
.typing span:nth-child(3) { animation-delay: 0.4s; }
@keyframes blink { 0%, 100% { opacity: 0.25; } 50% { opacity: 1; } }

/* ---------------- 状态监测 ---------------- */
.dev-list { display: flex; flex-direction: column; gap: 4px; max-height: 520px; overflow-y: auto; }
.dev-row { display: flex; align-items: center; gap: 9px; padding: 8px 9px; border-radius: 9px; border: 1px solid transparent; font-size: 12px; transition: all 0.15s; }
.dev-row:hover { background: rgba(96, 165, 250, 0.08); }
.dev-row.on { background: rgba(34, 211, 238, 0.1); border-color: rgba(34, 211, 238, 0.3); }
.dev-row .nm { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; flex: 0 0 7px; }

.param-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.param { padding: 11px 13px; border-radius: 11px; border: 1px solid var(--line); background: rgba(96, 165, 250, 0.045); }
.param .k { font-size: 11px; color: var(--dim); }
.param .v { font-size: 20px; font-weight: 620; margin-top: 2px; font-variant-numeric: tabular-nums; }
.param .v small { font-size: 11px; color: var(--muted); font-weight: 400; margin-left: 3px; }
.param .h { font-size: 10.5px; color: var(--dim); margin-top: 2px; }

/* ---------------- 诊断 ---------------- */
.alarm-list { display: flex; flex-direction: column; gap: 7px; max-height: 660px; overflow-y: auto; }
.alarm-card {
  padding: 10px 11px; border-radius: 10px; border: 1px solid var(--line);
  background: rgba(96, 165, 250, 0.045); transition: all 0.16s; position: relative;
}
.alarm-card:hover { border-color: var(--line-2); background: rgba(96, 165, 250, 0.09); }
.alarm-card.on { border-color: rgba(34, 211, 238, 0.45); background: rgba(34, 211, 238, 0.09); box-shadow: inset 2px 0 0 var(--cyan); }
.alarm-card .top { display: flex; align-items: center; gap: 6px; font-size: 10.5px; color: var(--dim); }
.alarm-card .ti { font-size: 12.5px; margin: 5px 0 4px; line-height: 1.4; }
.alarm-card .sub { display: flex; align-items: center; gap: 8px; font-size: 10.5px; color: var(--dim); }

.ai-box {
  border: 1px solid rgba(34, 211, 238, 0.26);
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.08), rgba(79, 140, 255, 0.05));
  border-radius: 12px; padding: 13px 15px;
}
.ai-box-hd { display: flex; align-items: center; gap: 7px; font-size: 12px; color: #a5f3ff; margin-bottom: 7px; }
.ai-box-hd svg, .sect svg, .insight-ic svg, .ai-hd .ai-orb svg { width: 14px; height: 14px; flex: 0 0 14px; }
.ai-hd .ai-orb svg { width: 16px; height: 16px; flex: 0 0 16px; }
.conf-bar { height: 6px; border-radius: 4px; background: rgba(96, 165, 250, 0.16); overflow: hidden; margin-top: 6px; }
.conf-bar i { display: block; height: 100%; background: linear-gradient(90deg, #22d3ee, #4f8cff); border-radius: 4px; }

.chain { display: flex; flex-direction: column; gap: 0; }
.chain-item { display: grid; grid-template-columns: 20px 1fr; gap: 9px; position: relative; padding-bottom: 13px; }
.chain-item:last-child { padding-bottom: 0; }
.chain-item::before { content: ""; position: absolute; left: 9px; top: 18px; bottom: 0; width: 1px; background: rgba(96, 165, 250, 0.22); }
.chain-item:last-child::before { display: none; }
.chain-dot {
  width: 19px; height: 19px; border-radius: 50%; display: grid; place-items: center;
  font-size: 9px; background: rgba(34, 211, 238, 0.16); border: 1px solid rgba(34, 211, 238, 0.4); color: #a5f3ff;
}
.chain-t { font-size: 12px; font-weight: 550; }
.chain-d { font-size: 11px; color: var(--dim); }

.doc-row { display: flex; gap: 8px; align-items: flex-start; padding: 7px 0; border-bottom: 1px dashed rgba(96, 165, 250, 0.14); font-size: 11.5px; }
.doc-row:last-child { border-bottom: 0; }
.doc-row .ic { width: 22px; height: 22px; border-radius: 6px; display: grid; place-items: center; background: rgba(96, 165, 250, 0.12); color: #9dc0ff; flex: 0 0 22px; }

/* ---------------- 看板 ---------------- */
.kanban { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.kcol { border: 1px solid var(--line); border-radius: 12px; background: rgba(96, 165, 250, 0.035); padding: 10px; min-height: 320px; }
.kcol-hd { display: flex; align-items: center; gap: 7px; font-size: 12px; margin-bottom: 9px; padding: 0 2px; }
.kcol-hd .n { margin-left: auto; font-size: 10.5px; color: var(--dim); background: rgba(96, 165, 250, 0.12); padding: 0 6px; border-radius: 20px; }
.kcard { padding: 10px; border-radius: 9px; border: 1px solid var(--line); background: linear-gradient(180deg, rgba(19, 33, 56, 0.95), rgba(11, 21, 38, 0.95)); margin-bottom: 8px; transition: all 0.15s; }
.kcard:hover { border-color: var(--line-2); transform: translateY(-1px); }
.kcard .t { font-size: 12px; line-height: 1.45; margin-bottom: 6px; }
.kcard .m { font-size: 10.5px; color: var(--dim); display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.kcard .pbar { height: 3px; border-radius: 3px; background: rgba(96, 165, 250, 0.14); margin-top: 8px; overflow: hidden; }
.kcard .pbar i { display: block; height: 100%; background: linear-gradient(90deg, #22d3ee, #4f8cff); }

.stat4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.stat {
  padding: 12px 14px; border-radius: 11px; border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(19, 33, 56, 0.88), rgba(9, 18, 33, 0.9));
}
.stat .k { font-size: 11px; color: var(--muted); }
.stat .v { font-size: 22px; font-weight: 620; font-variant-numeric: tabular-nums; margin-top: 3px; }
.stat .v small { font-size: 11px; color: var(--muted); font-weight: 400; }

/* ---------------- 表单 ---------------- */
.field { display: flex; flex-direction: column; gap: 5px; }
.field label { font-size: 11px; color: var(--dim); }
.input, select.input {
  background: rgba(96, 165, 250, 0.07); border: 1px solid var(--line);
  border-radius: 8px; padding: 7px 10px; font-size: 12px; outline: none; min-width: 0;
}
.input:focus { border-color: rgba(34, 211, 238, 0.5); }
.toolbar { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.toolbar .spacer { flex: 1; }
.search { position: relative; }
.search input { padding-left: 28px; width: 210px; }
.search svg { position: absolute; left: 9px; top: 50%; transform: translateY(-50%); width: 13px; height: 13px; color: var(--dim); }

/* ---------------- Toast ---------------- */
.toast {
  position: fixed; left: 50%; bottom: 30px; transform: translate(-50%, 14px);
  padding: 10px 16px; border-radius: 10px; font-size: 12.5px;
  border: 1px solid rgba(45, 212, 163, 0.4); background: rgba(9, 28, 26, 0.96);
  color: #a9f5dd; box-shadow: 0 12px 34px rgba(0, 0, 0, 0.5);
  opacity: 0; pointer-events: none; transition: all 0.24s; z-index: 80; display: flex; align-items: center; gap: 8px;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------------- 动画 ---------------- */
.fade { animation: fadeUp 0.38s ease both; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(9px); } to { opacity: 1; transform: none; } }
.d1 { animation-delay: 0.04s; } .d2 { animation-delay: 0.08s; } .d3 { animation-delay: 0.12s; }
.d4 { animation-delay: 0.16s; } .d5 { animation-delay: 0.2s; } .d6 { animation-delay: 0.24s; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .fade { opacity: 1 !important; transform: none !important; }
}

/* 截图 / 低性能终端：index.html?static=1 关闭所有入场动效，保证首帧完整可见 */
.no-anim *, .no-anim *::before, .no-anim *::after { animation: none !important; transition: none !important; }
.no-anim .fade { opacity: 1 !important; transform: none !important; }

/* ---------------- 响应式 ---------------- */
@media (max-width: 1500px) {
  .kpi-row { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 1280px) {
  .sidebar { width: 64px; flex: 0 0 64px; }
  .brand { padding: 16px 12px; justify-content: center; }
  .brand-text, .nav-label, .nav-item span, .ai-launch span, .ai-launch small { display: none; }
  .nav-item { justify-content: center; padding: 10px; }
  .nav-badge { display: none; }
  .ai-launch { justify-content: center; padding: 11px; }
  .col-3, .col-4, .col-5 { grid-column: span 6; }
  .col-7, .col-8, .col-9 { grid-column: span 12; }
  .kanban { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .kpi-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .col-3, .col-4, .col-5, .col-6 { grid-column: span 12; }
  .stat4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .param-grid { grid-template-columns: 1fr; }
  .ai-panel { right: 10px; bottom: 10px; width: calc(100vw - 20px); }
  .diag-grid, .doc-grid { grid-template-columns: 1fr; }
}

/* ---------------- 补充组件 ---------------- */
.delta.good { color: #6ff0c6; background: rgba(45, 212, 163, 0.12); }

.dl { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.dl-row { display: flex; align-items: center; gap: 7px; font-size: 11.5px; color: var(--muted); }
.dl-row b { margin-left: auto; color: #d5e4fa; font-weight: 500; font-variant-numeric: tabular-nums; }
.dl-row em { font-style: normal; width: 42px; text-align: right; color: var(--dim); font-size: 10.5px; }

.stack { display: flex; flex-direction: column; gap: 9px; }
.insight { display: flex; gap: 9px; padding: 9px 10px; border-radius: 9px; background: rgba(96, 165, 250, 0.05); border: 1px solid var(--line); }
.insight-ic { width: 26px; height: 26px; flex: 0 0 26px; border-radius: 8px; display: grid; place-items: center; border: 1px solid; }
.insight-t { font-size: 11.5px; font-weight: 550; line-height: 1.5; }
.insight-d { font-size: 10.5px; color: var(--dim); margin-top: 3px; line-height: 1.55; }

.hbar-row { display: flex; align-items: center; gap: 9px; font-size: 11.5px; color: var(--muted); }
.hbar-label { width: 44px; flex: 0 0 44px; }
.hint-line {
  margin-top: 11px; padding: 9px 11px; border-radius: 8px;
  background: rgba(34, 211, 238, 0.06); border: 1px dashed rgba(34, 211, 238, 0.22);
  font-size: 11.5px; color: var(--muted); line-height: 1.65;
}

.sect { font-size: 11px; color: var(--dim); letter-spacing: 1px; margin: 16px 0 8px; display: flex; align-items: center; gap: 7px; }
.sect::after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, rgba(96, 165, 250, 0.25), transparent); }
.diag-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 2px; }

.advice { display: flex; flex-direction: column; gap: 7px; }
.advice-row { display: flex; gap: 8px; font-size: 11.5px; color: #cfe0f8; line-height: 1.65; }
.advice-n {
  width: 17px; height: 17px; flex: 0 0 17px; border-radius: 5px; display: grid; place-items: center;
  font-size: 10px; background: rgba(34, 211, 238, 0.14); color: #a5f3ff;
  border: 1px solid rgba(34, 211, 238, 0.25); margin-top: 1px;
}
.case-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px dashed rgba(96, 165, 250, 0.14); }
.case-row:last-child { border-bottom: 0; }

table.tbl.mini th, table.tbl.mini td { padding: 7px 8px; font-size: 11.5px; }

.doc-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
.doc-item {
  display: flex; align-items: center; gap: 9px; padding: 10px 11px; border-radius: 9px;
  border: 1px solid var(--line); background: rgba(96, 165, 250, 0.045);
  transition: all 0.15s; cursor: pointer;
}
.doc-item:hover { border-color: var(--line-2); background: rgba(96, 165, 250, 0.09); }

.heat { display: flex; flex-direction: column; gap: 3px; }
.heat-row { display: grid; grid-template-columns: 32px repeat(24, minmax(0, 1fr)); gap: 3px; align-items: center; }
.heat-x { font-size: 8.5px; color: var(--dim); text-align: center; height: 11px; }
.heat-y { font-size: 9.5px; color: var(--dim); }
.heat-cell { height: 15px; border-radius: 3px; display: block; }
.heat-legend { display: flex; align-items: center; gap: 4px; margin-top: 10px; font-size: 10px; color: var(--dim); }
.heat-legend i { width: 14px; height: 8px; border-radius: 2px; display: block; }

/* ===========================================================
   Day02 专用组件：视频墙 / 四色图 / 作业票校验
   =========================================================== */
.cam { border: 1px solid var(--line); border-radius: 11px; overflow: hidden; background: #0a1524; transition: all 0.18s; cursor: pointer; }
.cam:hover { border-color: rgba(34, 211, 238, 0.42); transform: translateY(-1px); box-shadow: 0 10px 26px rgba(0, 0, 0, 0.35); }
.cam-view { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: #08111f; }
.cam-view .scene { position: absolute; inset: 0; width: 100%; height: 100%; }
.cam-scan { position: absolute; left: 0; right: 0; height: 28%; background: linear-gradient(180deg, rgba(34, 211, 238, 0), rgba(34, 211, 238, 0.09), rgba(34, 211, 238, 0)); animation: scan 6.5s linear infinite; pointer-events: none; }
@keyframes scan { 0% { top: -30%; } 100% { top: 100%; } }
.cam-hud { position: absolute; top: 7px; left: 8px; right: 8px; display: flex; align-items: center; gap: 5px; font-size: 9.5px; color: #cfe0f8; text-shadow: 0 1px 4px rgba(0, 0, 0, 0.8); }
.cam-hud .cam-time { margin-left: auto; font-variant-numeric: tabular-nums; color: #9db7dd; }
.rec { width: 5px; height: 5px; border-radius: 50%; background: #fb6c7d; box-shadow: 0 0 6px #fb6c7d; animation: pulse 1.8s infinite; }
.cam-ai { position: absolute; bottom: 6px; right: 7px; font-size: 8.5px; padding: 1px 5px; border-radius: 4px; color: #a5f3ff; background: rgba(34, 211, 238, 0.16); border: 1px solid rgba(34, 211, 238, 0.3); }
.det { position: absolute; border: 1.4px solid #fb6c7d; border-radius: 3px; box-shadow: 0 0 16px rgba(251, 108, 125, 0.3); animation: detpulse 2s infinite; }
.det b { position: absolute; top: -17px; left: -1px; font-size: 9px; font-weight: 600; background: #fb6c7d; color: #1c0609; padding: 0 4px; border-radius: 3px 3px 3px 0; white-space: nowrap; }
.det.amber { border-color: #fbbf4a; box-shadow: 0 0 16px rgba(251, 191, 74, 0.28); }
.det.amber b { background: #fbbf4a; color: #241802; }
@keyframes detpulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.62; } }
.cam-info { display: flex; align-items: center; gap: 8px; padding: 7px 10px 8px; }
.cam-name { font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cam-meta { margin-left: auto; display: flex; align-items: center; gap: 5px; font-size: 10px; color: var(--dim); white-space: nowrap; }
.cam-meta .tag { font-size: 9.5px; padding: 0 5px; line-height: 15px; }
.cam-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.cam-grid-4 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.cam-detail { position: relative; aspect-ratio: 16 / 9; border-radius: 10px; overflow: hidden; border: 1px solid var(--line-2); margin-bottom: 4px; }
.cam-detail .scene { position: absolute; inset: 0; width: 100%; height: 100%; }

.permit-list { display: flex; flex-direction: column; gap: 2px; }
.permit-row { display: flex; align-items: center; gap: 10px; padding: 9px 8px; border-radius: 8px; border-bottom: 1px dashed rgba(96, 165, 250, 0.12); transition: background 0.15s; cursor: pointer; }
.permit-row:hover { background: rgba(96, 165, 250, 0.07); }
.pr-l { flex: 1; min-width: 0; }
.pr-t { font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pr-d { font-size: 10.5px; color: var(--dim); margin-top: 2px; }
.pr-r { display: flex; align-items: center; gap: 5px; }

.zmap { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: 84px; gap: 8px; }
.zone { border: 1px solid; border-radius: 10px; padding: 8px 10px; display: flex; flex-direction: column; justify-content: space-between; }
.zone-hd { display: flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; }
.zone-hd .tag { font-size: 9px; padding: 0 5px; line-height: 15px; }
.zone-body { font-size: 10.5px; color: var(--muted); display: flex; align-items: center; gap: 5px; }
.zone-body b { font-size: 17px; font-variant-numeric: tabular-nums; color: #e8f0ff; }

.risk-list { display: flex; flex-direction: column; }
.risk-row { display: flex; align-items: center; gap: 12px; padding: 10px 4px; border-bottom: 1px dashed rgba(96, 165, 250, 0.12); }
.risk-row:last-child { border-bottom: 0; }
.risk-t { font-size: 12.5px; }
.risk-d { font-size: 10.5px; color: var(--dim); margin-top: 3px; }
.risk-r { display: flex; flex-direction: column; align-items: flex-end; gap: 5px; min-width: 92px; }
.risk-rate { width: 84px; height: 3px; border-radius: 3px; background: rgba(96, 165, 250, 0.14); overflow: hidden; }
.risk-rate i { display: block; height: 100%; border-radius: 3px; }

.algo-list { display: flex; flex-direction: column; }
.algo-row { display: flex; align-items: center; gap: 8px; font-size: 11.5px; color: var(--muted); padding: 5.5px 0; border-bottom: 1px dashed rgba(96, 165, 250, 0.1); }
.algo-row:last-child { border-bottom: 0; }
.algo-row .tag { margin-left: auto; font-size: 9.5px; padding: 0 5px; line-height: 15px; }
.algo-dot { width: 6px; height: 6px; border-radius: 50%; flex: 0 0 6px; }

.stat-mini { display: flex; align-items: center; justify-content: space-between; font-size: 11.5px; color: var(--muted); padding: 6px 0; border-bottom: 1px dashed rgba(96, 165, 250, 0.12); }
.stat-mini:last-of-type { border-bottom: 0; }
.stat-mini b { color: #e8f0ff; font-size: 13px; font-variant-numeric: tabular-nums; }

.check-list { display: flex; flex-direction: column; gap: 7px; }
.check-row { display: flex; gap: 9px; padding: 9px 10px; border-radius: 8px; border: 1px solid var(--line); background: rgba(96, 165, 250, 0.04); }
.check-row.bad { border-color: rgba(251, 108, 125, 0.32); background: rgba(251, 108, 125, 0.07); }
.check-ic { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; background: rgba(45, 212, 163, 0.15); color: #8ff0d2; flex: 0 0 18px; margin-top: 1px; }
.check-row.bad .check-ic { background: rgba(251, 108, 125, 0.16); color: #ffb0b9; }
.check-t { font-size: 12px; }
.check-d { font-size: 10.5px; color: var(--dim); margin-top: 2px; line-height: 1.5; }

.det-row { display: flex; align-items: center; gap: 9px; padding: 8px 0; border-bottom: 1px dashed rgba(96, 165, 250, 0.14); font-size: 12px; }
.det-row:last-child { border-bottom: 0; }

.ai-box.warn { border-color: rgba(251, 108, 125, 0.3); background: linear-gradient(135deg, rgba(251, 108, 125, 0.1), rgba(251, 191, 74, 0.05)); }
.ai-box.warn .ai-box-hd { color: #ffb0b9; }

@media (max-width: 1280px) {
  .cam-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.cam-add { border: 1px dashed rgba(96, 165, 250, 0.28); border-radius: 11px; display: grid; place-items: center; min-height: 180px; background: rgba(96, 165, 250, 0.03); cursor: pointer; transition: all 0.15s; }
.cam-add:hover { border-color: rgba(34, 211, 238, 0.5); background: rgba(34, 211, 238, 0.06); }
.cam-add-in { display: flex; flex-direction: column; align-items: center; gap: 7px; color: var(--muted); font-size: 11px; text-align: center; }
.cam-add-plus { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-size: 20px; color: #67e8f9; border: 1px dashed rgba(34, 211, 238, 0.45); }
.cam-add-in b { font-size: 12.5px; color: #cfe0f8; font-weight: 550; }

.cam.offline .cam-view { filter: grayscale(1) brightness(0.62); }
.cam.offline .rec { background: #5f7599; box-shadow: none; animation: none; }
.cam.offline .cam-info .cam-name { color: #93a7c9; }
.cam-off { position: absolute; inset: 0; display: grid; place-items: center; font-size: 11px; letter-spacing: 2px; color: #cfe0f8; background: rgba(4, 10, 20, 0.35); }

/* ===========================================================
   Day03 专用组件：文档审查 / 相似度矩阵 / 关系图谱
   =========================================================== */
.doc-stats { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; padding: 13px 16px; border: 1px solid var(--line); border-radius: 12px; background: linear-gradient(180deg, rgba(19, 33, 56, 0.9), rgba(9, 18, 33, 0.92)); }
.doc-stat { display: flex; flex-direction: column; gap: 2px; min-width: 76px; padding-right: 12px; border-right: 1px solid var(--line); }
.doc-stat:last-child { border-right: 0; padding-right: 0; }
.ds-n { font-size: 24px; font-weight: 650; line-height: 1.1; font-variant-numeric: tabular-nums; }
.ds-k { font-size: 10.5px; color: var(--dim); }

.doc-body { display: flex; flex-direction: column; gap: 10px; max-height: calc(100vh - 320px); overflow-y: auto; padding-right: 4px; }
.clause { display: flex; gap: 10px; padding: 10px 12px; border-radius: 9px; border: 1px solid var(--line); border-left: 3px solid var(--line-2); background: rgba(96, 165, 250, 0.03); cursor: pointer; transition: all 0.15s; }
.clause:hover { background: rgba(96, 165, 250, 0.07); }
.clause.on { border-color: rgba(34, 211, 238, 0.45); border-left-color: #22d3ee; background: rgba(34, 211, 238, 0.07); box-shadow: 0 0 0 1px rgba(34, 211, 238, 0.1); }
.clause.sev-red { border-left-color: rgba(251, 108, 125, 0.85); }
.clause.sev-amber { border-left-color: rgba(251, 191, 74, 0.85); }
.clause.sev-blue { border-left-color: rgba(79, 140, 255, 0.85); }
.clause.sev-green { border-left-color: rgba(45, 212, 163, 0.7); }
.clause.resolved { opacity: 0.55; }
.cl-no { font-family: "Cascadia Mono", Consolas, monospace; font-size: 10.5px; color: var(--dim); width: 32px; flex: 0 0 32px; padding-top: 2px; }
.cl-body { flex: 1; min-width: 0; }
.cl-body p { font-size: 12.5px; line-height: 1.8; color: #d5e4fa; }
.cl-meta { display: flex; align-items: center; gap: 8px; margin-top: 6px; }
.cl-meta .mono { font-size: 10.5px; color: var(--dim); }

mark.hl { background: transparent; color: inherit; padding: 0; }
mark.hl.red { background: rgba(251, 108, 125, 0.15); border-bottom: 1px solid rgba(251, 108, 125, 0.5); }
mark.hl.amber { background: rgba(251, 191, 74, 0.14); border-bottom: 1px solid rgba(251, 191, 74, 0.45); }
mark.hl.blue { background: rgba(79, 140, 255, 0.14); border-bottom: 1px solid rgba(79, 140, 255, 0.45); }
mark.hl.green { background: rgba(45, 212, 163, 0.1); border-bottom: 1px solid rgba(45, 212, 163, 0.35); }

.anno-list { display: flex; flex-direction: column; gap: 8px; max-height: calc(100vh - 320px); overflow-y: auto; padding-right: 4px; }
.anno-item { padding: 10px 11px; border-radius: 9px; border: 1px solid var(--line); border-left: 3px solid transparent; background: rgba(96, 165, 250, 0.04); cursor: pointer; transition: all 0.15s; }
.anno-item:hover { background: rgba(96, 165, 250, 0.09); }
.anno-item.on { border-color: rgba(34, 211, 238, 0.4); background: rgba(34, 211, 238, 0.07); }
.anno-item.sev-red { border-left-color: rgba(251, 108, 125, 0.85); }
.anno-item.sev-amber { border-left-color: rgba(251, 191, 74, 0.85); }
.anno-item.sev-blue { border-left-color: rgba(79, 140, 255, 0.85); }
.anno-item.resolved { opacity: 0.5; }
.anno-hd { display: flex; align-items: center; gap: 7px; font-size: 12px; }
.anno-tx { font-size: 11px; color: var(--muted); line-height: 1.65; margin-top: 5px; }
.anno-law { font-size: 10px; color: var(--dim); margin-top: 6px; border-top: 1px dashed rgba(96, 165, 250, 0.14); padding-top: 5px; }
.anno-ok { font-size: 10.5px; color: #8ff0d2; margin-top: 5px; display: flex; align-items: center; gap: 4px; }

.mx { display: flex; flex-direction: column; gap: 4px; }
.mx-row { display: grid; grid-template-columns: 30px repeat(5, minmax(0, 1fr)); gap: 4px; }
.mx-h { font-size: 10.5px; color: var(--dim); display: grid; place-items: center; height: 24px; }
.mx-cell { height: 40px; border-radius: 6px; display: grid; place-items: center; font-size: 12px; font-variant-numeric: tabular-nums; cursor: pointer; border: 1px solid transparent; transition: all 0.15s; }
.mx-cell:hover { transform: translateY(-1px); border-color: rgba(255, 255, 255, 0.2); }
.mx-cell.diag { background: rgba(96, 165, 250, 0.04); color: var(--dim); cursor: default; transform: none; border-color: transparent; }
.mx-cell.low { background: rgba(96, 165, 250, 0.06); color: #8ea4c8; }
.mx-cell.mid { background: rgba(79, 140, 255, 0.16); color: #bcd4ff; }
.mx-cell.warm { background: rgba(251, 191, 74, 0.2); color: #ffd79a; }
.mx-cell.hot { background: rgba(251, 108, 125, 0.24); color: #ffb0b9; font-weight: 600; }

.graph-svg { width: 100%; height: auto; display: block; }
.gnode { cursor: pointer; }
.gnode:hover circle { filter: brightness(1.35); }
.graph-legend { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 6px; font-size: 10.5px; color: var(--dim); }
.graph-legend span { display: flex; align-items: center; gap: 5px; }
.graph-legend i { width: 7px; height: 7px; border-radius: 50%; display: block; }

.flag-list { display: flex; flex-direction: column; }
.flag-row { display: flex; align-items: flex-start; gap: 9px; padding: 9px 4px; border-bottom: 1px dashed rgba(96, 165, 250, 0.12); }
.flag-row:last-child { border-bottom: 0; }
.flag-row .status-dot { margin-top: 5px; }

.score-row { display: flex; align-items: center; gap: 10px; font-size: 11.5px; color: var(--muted); }
.score-name { width: 118px; flex: 0 0 118px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.score-row b { font-size: 12px; color: #e8f0ff; font-variant-numeric: tabular-nums; }

.engine-row { display: flex; align-items: flex-start; gap: 9px; }
.engine-row b { font-size: 12px; font-weight: 550; }

.diff-hd { display: flex; align-items: center; gap: 8px; font-size: 11.5px; color: var(--muted); margin-bottom: 6px; }
.diff-box { padding: 11px 13px; border-radius: 9px; border: 1px solid var(--line); background: rgba(96, 165, 250, 0.045); font-size: 12px; line-height: 1.85; color: #d5e4fa; }

@media (max-width: 1280px) {
  .doc-body, .anno-list { max-height: none; }
  .doc-stats { flex-wrap: wrap; }
}
