:root {
  --bg: #f9fafb; --card: #fff; --border: #e5e7eb; --border-soft: #f3f4f6;
  --text: #111827; --text-2: #374151; --muted: #6b7280; --muted-2: #9ca3af;
  --brand: #3b82f6; --brand-600: #2563eb; --brand-50: #eff6ff;
  --emerald: #10b981; --red: #ef4444; --amber: #f59e0b; --violet: #8b5cf6; --cyan: #06b6d4;
  --radius: 8px; --shadow: 0 1px 2px rgba(0,0,0,.05);
  /* 语义色（深色主题下覆盖） */
  --good-bg: #ecfdf5; --good-fg: #047857; --good-ring: #a7f3d0;
  --info-bg: #eff6ff; --info-fg: #1d4ed8; --info-ring: #bfdbfe;
  --bad-bg: #fef2f2; --bad-fg: #b91c1c; --bad-ring: #fecaca;
  --warn-bg: #fffbeb; --warn-fg: #b45309; --warn-ring: #fde68a; --warn-text: #92400e;
  --tick: #d1d5db; --hover: rgba(229,231,235,.6); --overlay: rgba(255,255,255,.95);
  --bar-fill: #dbeafe; --mask: rgba(17,24,39,.35); --pop-shadow: 0 4px 12px rgba(0,0,0,.08);
  --toast-bg: #111827; --toast-fg: #fff;
  color-scheme: light;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  font-family: Inter, -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 14px; color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
/* Planner 风格外壳：灰色侧栏 + 白色主区 + 面包屑顶栏 */
.layout { display: flex; min-height: 100vh; }
.sidebar {
  width: 240px; flex-shrink: 0; background: var(--bg); display: flex; flex-direction: column;
  padding: 12px; position: sticky; top: 0; height: 100vh; overflow-y: auto; transition: margin-left .15s ease;
}
body.collapsed .sidebar { margin-left: -240px; }
.ws { display: flex; gap: 10px; align-items: center; padding: 8px; border: 1px solid var(--border); border-radius: 6px; background: var(--card); box-shadow: var(--shadow); margin-bottom: 18px; }
.ws-logo { width: 32px; height: 32px; border-radius: 6px; background: var(--brand); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 600; font-size: 14px; flex-shrink: 0; }
.ws-name { font-size: 13px; font-weight: 600; color: var(--text); }
.ws-sub { font-size: 12px; color: var(--muted); }
.nav-group { margin-bottom: 16px; }
.nav-label { font-size: 12px; color: var(--muted); padding: 4px 8px 6px; }
#nav a { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border-radius: 6px; color: var(--text-2); margin-bottom: 2px; font-size: 13px; }
#nav a svg { width: 18px; height: 18px; color: var(--muted-2); flex-shrink: 0; }
#nav a:hover { background: var(--hover); color: var(--text); }
#nav a.active { background: var(--card); color: var(--brand-600); font-weight: 500; box-shadow: var(--pop-shadow), 0 0 0 1px var(--border); }
#nav a.active svg { color: var(--brand-600); }
.sidebar-foot { margin-top: auto; font-size: 12px; color: var(--muted); padding: 8px; line-height: 1.7; border-top: 1px solid var(--border); }
.main { flex: 1; min-width: 0; background: var(--card); border-left: 1px solid var(--border); }
.topbar { position: sticky; top: 0; z-index: 11; height: 56px; background: var(--card); border-bottom: 1px solid var(--border); padding: 0 24px; display: flex; gap: 12px; align-items: center; }
.icon-btn { border: 0; background: none; padding: 6px; border-radius: 6px; cursor: pointer; color: var(--muted); display: inline-flex; }
.icon-btn:hover { background: var(--border-soft); color: var(--text); }
.icon-btn svg { width: 18px; height: 18px; }
.vsep { width: 1px; height: 20px; background: var(--border); }
.crumb { display: flex; gap: 8px; align-items: center; font-size: 13px; color: var(--muted); }
.crumb a:hover { color: var(--text); }
.crumb b { color: var(--text); font-weight: 500; }
.filterbar { position: sticky; top: 56px; z-index: 10; background: var(--overlay); backdrop-filter: blur(6px); border-bottom: 1px solid var(--border); padding: 10px 24px; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.view { padding: 24px 24px 48px; }
h1 { font-size: 20px; font-weight: 600; margin: 0 0 4px; }
h2 { font-size: 15px; font-weight: 600; margin: 0; }
.sub { color: var(--muted); font-size: 13px; margin: 0 0 20px; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 20px; }
.page-head .sub { margin: 0; }

/* controls */
.seg { display: inline-flex; border: 1px solid var(--border); border-radius: 6px; background: var(--card); overflow: hidden; box-shadow: var(--shadow); }
.seg button { border: 0; background: none; padding: 6px 12px; font: inherit; font-size: 13px; color: var(--text-2); cursor: pointer; border-right: 1px solid var(--border); }
.seg button:last-child { border-right: 0; }
.seg button.on { background: var(--border-soft); color: var(--text); font-weight: 500; }
.input, select.input {
  border: 1px solid var(--border); border-radius: 6px; background: var(--card); padding: 6px 10px;
  font: inherit; font-size: 13px; color: var(--text); box-shadow: var(--shadow); height: 32px;
}
.input:focus { outline: 2px solid var(--brand-50); border-color: var(--brand); }
.btn {
  border: 1px solid var(--border); background: var(--card); border-radius: 6px; padding: 0 12px; height: 32px;
  font: inherit; font-size: 13px; color: var(--text-2); cursor: pointer; box-shadow: var(--shadow); white-space: nowrap;
}
.btn:hover { background: var(--bg); }
.btn.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn.primary:hover { background: var(--brand-600); }
.btn.danger { color: var(--red); }
.btn.sm { height: 26px; padding: 0 8px; font-size: 12px; }
.spacer { flex: 1; }
.muted { color: var(--muted); }
.small { font-size: 12px; }

/* cards & grid */
.card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 16px; }
.grid { display: grid; gap: 16px; margin-bottom: 16px; }
.g5 { grid-template-columns: repeat(5, minmax(0,1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0,1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0,1fr)); }
.g2 { grid-template-columns: repeat(2, minmax(0,1fr)); }
.g21 { grid-template-columns: 2fr 1fr; }
@media (max-width: 1200px) { .g5 { grid-template-columns: repeat(3,1fr); } .g21, .g3 { grid-template-columns: 1fr; } }
.kpi-label { color: var(--muted); font-size: 13px; }
.kpi-value { font-size: 24px; font-weight: 600; margin: 6px 0 8px; letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.kpi-foot { font-size: 12px; color: var(--muted); display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }

/* badges & deltas */
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 999px; font-size: 12px; font-weight: 500; white-space: nowrap; }
.b-good { background: var(--good-bg); color: var(--good-fg); box-shadow: inset 0 0 0 1px var(--good-ring); }
.b-normal { background: var(--info-bg); color: var(--info-fg); box-shadow: inset 0 0 0 1px var(--info-ring); }
.b-poor { background: var(--bad-bg); color: var(--bad-fg); box-shadow: inset 0 0 0 1px var(--bad-ring); }
.b-watch { background: var(--warn-bg); color: var(--warn-fg); box-shadow: inset 0 0 0 1px var(--warn-ring); }
.b-gray { background: var(--border-soft); color: var(--text-2); box-shadow: inset 0 0 0 1px var(--border); }
.delta { font-weight: 500; font-size: 12px; padding: 1px 6px; border-radius: 4px; }
.delta.up { color: var(--good-fg); background: var(--good-bg); }
.delta.down { color: var(--bad-fg); background: var(--bad-bg); }
.delta.flat { color: var(--muted); background: var(--border-soft); }
.miss { color: var(--amber); font-size: 12px; cursor: help; }
.na { color: var(--muted-2); }

/* tables */
.table-wrap { overflow-x: auto; margin: 0 -20px -20px; }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
th { text-align: left; font-size: 13px; font-weight: 600; color: var(--text); padding: 10px 12px; border-bottom: 1px solid var(--border); white-space: nowrap; background: var(--card); }
th.sortable { cursor: pointer; user-select: none; }
th.sortable:hover { color: var(--text); }
th.sorted { color: var(--brand-600); }
td { padding: 10px 12px; border-bottom: 1px solid var(--border-soft); color: var(--text-2); white-space: nowrap; }
th:first-child, td:first-child { padding-left: 20px; }
th:last-child, td:last-child { padding-right: 20px; }
td.num, th.num { text-align: right; }
tr.click { cursor: pointer; }
tr.click:hover td { background: var(--bg); }
tr.nodata td { color: var(--muted-2); }
.thumb { width: 36px; height: 36px; border-radius: 6px; object-fit: cover; background: var(--border-soft); border: 1px solid var(--border); flex-shrink: 0; }
.mat-cell { display: flex; gap: 10px; align-items: center; }
.mat-cell .code { font-weight: 500; color: var(--text); }
.mat-cell .name { font-size: 12px; color: var(--muted); max-width: 200px; overflow: hidden; text-overflow: ellipsis; }
.pager { display: flex; justify-content: space-between; align-items: center; padding: 12px 20px 0; font-size: 13px; color: var(--muted); }
.pager .btns { display: flex; gap: 6px; }

/* tabs */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--border); margin-bottom: 16px; }
.tabs button { border: 0; background: none; font: inherit; font-size: 13px; color: var(--muted); padding: 8px 12px; cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tabs button.on { color: var(--brand-600); border-bottom-color: var(--brand); font-weight: 500; }
.tabs button .cnt { margin-left: 4px; font-size: 11px; color: var(--muted-2); }

/* charts */
.chart { position: relative; width: 100%; }
.chart svg { display: block; overflow: visible; }
.chart .grid-line { stroke: var(--border-soft); }
.chart .axis-text { fill: var(--muted); font-size: 11px; }
.legend { display: flex; gap: 14px; font-size: 12px; color: var(--muted); flex-wrap: wrap; }
.legend i, .tt-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; vertical-align: middle; }
.tooltip { position: fixed; z-index: 50; pointer-events: none; background: var(--card); border: 1px solid var(--border); border-radius: 6px; box-shadow: var(--pop-shadow); font-size: 12px; min-width: 150px; }
.tt-head { padding: 6px 10px; border-bottom: 1px solid var(--border); font-weight: 500; }
.tt-row { padding: 4px 10px; display: flex; justify-content: space-between; gap: 16px; }
.tt-row b { font-weight: 500; font-variant-numeric: tabular-nums; }
.barlist .row { display: flex; align-items: center; gap: 12px; margin-bottom: 6px; font-size: 13px; }
.barlist .bar { flex: 1; position: relative; height: 28px; }
.barlist .fill { position: absolute; inset: 0 auto 0 0; background: var(--bar-fill); border-radius: 4px; }
.barlist .lbl { position: relative; line-height: 28px; padding-left: 8px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.barlist .val { width: 90px; text-align: right; font-variant-numeric: tabular-nums; color: var(--text); }
.barlist .row.link { cursor: pointer; }
.barlist .row.link:hover .lbl { color: var(--brand-600); }
.catbar { display: flex; height: 8px; border-radius: 4px; overflow: hidden; gap: 2px; margin: 8px 0 16px; }
.catbar span { display: block; }

/* misc */
.notice { display: flex; gap: 10px; padding: 10px 14px; border-radius: 6px; font-size: 13px; margin-bottom: 16px; background: var(--warn-bg); color: var(--warn-text); border: 1px solid var(--warn-ring); line-height: 1.6; }
.notice.info { background: var(--info-bg); color: var(--info-fg); border-color: var(--info-ring); }
.notice a { text-decoration: underline; cursor: pointer; }
.reasons { list-style: none; padding: 0; margin: 0; }
.reasons li { padding: 7px 0; border-bottom: 1px solid var(--border-soft); font-size: 13px; display: flex; gap: 8px; align-items: flex-start; }
.reasons li:last-child { border: 0; }
.ri { width: 18px; height: 18px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 11px; flex-shrink: 0; margin-top: 1px; }
.ri.good { background: var(--good-bg); color: var(--good-fg); } .ri.poor { background: var(--bad-bg); color: var(--bad-fg); }
.ri.neutral { background: var(--border-soft); color: var(--muted); } .ri.guard { background: var(--warn-bg); color: var(--warn-fg); }
.empty { text-align: center; padding: 48px 20px; color: var(--muted); }
.empty h2 { color: var(--text); margin-bottom: 8px; }
.form-row { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; font-size: 13px; }
.form-row label { width: 150px; color: var(--text-2); }
.form-row .input { width: 120px; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; font-size: 13px; }
.kv dt { color: var(--muted); } .kv dd { margin: 0; }
.modal-mask { position: fixed; inset: 0; background: var(--mask); z-index: 60; display: flex; align-items: center; justify-content: center; }
.modal { background: var(--card); border-radius: 10px; padding: 24px; width: 420px; box-shadow: 0 10px 30px rgba(0,0,0,.15); }
.modal p { color: var(--text-2); line-height: 1.6; }
.modal .acts { display: flex; justify-content: flex-end; gap: 8px; margin-top: 20px; }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); background: var(--toast-bg); color: var(--toast-fg); padding: 10px 16px; border-radius: 6px; font-size: 13px; z-index: 70; }
.mono { font-family: ui-monospace, Consolas, monospace; font-size: 12px; }
pre.mono { background: var(--bg); border: 1px solid var(--border); border-radius: 6px; padding: 10px; white-space: pre-wrap; margin: 8px 0 0; }

/* Planner 组件：比例卡片 + 刻度条、工具栏、分组行、圆点徽章、头像组 */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 20px; overflow: hidden; }
.stat { padding: 16px 20px; border-left: 1px solid var(--border); margin-left: -1px; }
.stat-title { font-size: 13px; color: var(--muted); }
.stat-val { font-size: 20px; font-weight: 600; margin-top: 4px; color: var(--text); font-variant-numeric: tabular-nums; }
.ticks { display: flex; gap: 2px; align-items: center; margin-top: 8px; }
.ticks i { width: 4px; height: 14px; border-radius: 2px; background: var(--tick); }
.ticks .ratio { margin-left: 8px; font-size: 13px; color: var(--muted-2); font-weight: 500; }
.ticks .ratio b { color: var(--text-2); font-weight: 500; }
.toolbar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
.search { position: relative; }
.search svg { position: absolute; left: 9px; top: 8px; width: 16px; height: 16px; color: var(--muted-2); pointer-events: none; }
.search .input { padding-left: 32px; width: 260px; }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 10px; border: 1px dashed var(--tick); border-radius: 6px; font-size: 13px; color: var(--text-2); cursor: help; }
tr.group td { background: var(--bg); color: var(--text); font-weight: 600; padding-top: 9px; padding-bottom: 9px; border-bottom: 1px solid var(--border); }
tr.group .cnt { margin-left: 8px; font-weight: 500; color: var(--muted); }
.badge .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex-shrink: 0; }
.avs { display: flex; align-items: center; }
.av { width: 22px; height: 22px; border-radius: 50%; color: #fff; font-size: 11px; font-weight: 500; display: inline-flex; align-items: center; justify-content: center; box-shadow: 0 0 0 2px var(--card); flex-shrink: 0; }
.av + .av { margin-left: -4px; }
.av.more { background: var(--border); color: var(--text-2); }
.av-name { margin-left: 8px; font-size: 13px; }
.card { box-shadow: none; }
.tabs { margin-bottom: 14px; }
.tabs button { padding: 0 12px 9px; }

[hidden] { display: none !important; }
.chart .hover-line { stroke: var(--tick); }

/* 深色主题 */
html.dark {
  --bg: #030712; --card: #0b1120; --border: #1f2937; --border-soft: #111827;
  --text: #f9fafb; --text-2: #d1d5db; --muted: #9ca3af; --muted-2: #6b7280;
  --brand: #3b82f6; --brand-600: #60a5fa; --brand-50: rgba(59,130,246,.12);
  --shadow: 0 1px 2px rgba(0,0,0,.4);
  --good-bg: rgba(16,185,129,.12); --good-fg: #34d399; --good-ring: rgba(52,211,153,.25);
  --info-bg: rgba(59,130,246,.12); --info-fg: #60a5fa; --info-ring: rgba(96,165,250,.3);
  --bad-bg: rgba(239,68,68,.12); --bad-fg: #f87171; --bad-ring: rgba(248,113,113,.25);
  --warn-bg: rgba(245,158,11,.1); --warn-fg: #fbbf24; --warn-ring: rgba(251,191,36,.25); --warn-text: #fcd34d;
  --tick: #374151; --hover: rgba(31,41,55,.7); --overlay: rgba(11,17,32,.92);
  --bar-fill: rgba(59,130,246,.22); --mask: rgba(0,0,0,.6); --pop-shadow: 0 4px 16px rgba(0,0,0,.5);
  --toast-bg: #f9fafb; --toast-fg: #111827;
  color-scheme: dark;
}
html.dark .thumb { filter: brightness(.85); }

/* 左下角用户菜单（无登录，仅本机显示名 + 主题切换） */
.user-btn { display: flex; align-items: center; gap: 10px; width: 100%; margin-top: 8px; padding: 6px 8px; border: 0; background: none; border-radius: 6px; cursor: pointer; font: inherit; color: var(--text); text-align: left; }
.user-btn:hover, .user-btn[aria-expanded="true"] { background: var(--hover); }
.user-btn .av { width: 28px; height: 28px; font-size: 12px; box-shadow: none; }
.user-btn .u-name { flex: 1; min-width: 0; font-size: 13px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-btn svg { width: 16px; height: 16px; color: var(--muted-2); flex-shrink: 0; }
.menu { position: fixed; z-index: 40; width: 232px; background: var(--card); border: 1px solid var(--border); border-radius: 8px; box-shadow: var(--pop-shadow); padding: 4px; font-size: 13px; }
.menu-head { padding: 8px 10px 6px; }
.menu-head b { display: block; color: var(--text); font-weight: 600; }
.menu-head span { font-size: 12px; color: var(--muted); }
.menu-label { padding: 8px 10px 4px; font-size: 12px; color: var(--muted); }
.menu-sep { height: 1px; background: var(--border); margin: 4px 0; }
.menu-item { display: flex; align-items: center; gap: 10px; width: 100%; padding: 7px 10px; border: 0; background: none; border-radius: 5px; font: inherit; color: var(--text-2); cursor: pointer; text-align: left; }
.menu-item:hover, .menu-item:focus-visible { background: var(--hover); color: var(--text); outline: none; }
.menu-item svg { width: 16px; height: 16px; color: var(--muted); flex-shrink: 0; }
.menu-item .check { margin-left: auto; color: var(--brand-600); visibility: hidden; }
.menu-item[aria-checked="true"] .check { visibility: visible; }
.menu-item[aria-checked="true"] { color: var(--text); font-weight: 500; }

/* 登录前隐藏主界面；非管理员隐藏管理入口 */
html:not(.authed) .layout { display: none; }
html.authed #auth-root { display: none; }
html:not(.is-admin) .admin-only { display: none !important; }
.auth-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px; background: var(--bg); }
.auth-card { width: 100%; max-width: 380px; background: var(--card); border: 1px solid var(--border); border-radius: 10px; box-shadow: var(--pop-shadow); padding: 28px; }
.auth-brand { display: flex; gap: 10px; align-items: center; margin-bottom: 24px; }
.auth-card h1 { font-size: 18px; }
.auth-card .sub { margin-bottom: 18px; }
.field { display: block; margin: 0 0 14px; border: 0; padding: 0; }
.field > span, .field > legend { display: block; font-size: 13px; color: var(--text-2); margin-bottom: 6px; font-weight: 500; padding: 0; }
.field .input { width: 100%; height: 36px; }
.auth-btn { width: 100%; height: 36px; margin-top: 4px; }
.auth-err { color: var(--bad-fg); background: var(--bad-bg); border: 1px solid var(--bad-ring); border-radius: 6px; padding: 8px 10px; font-size: 13px; margin: 0 0 12px; }
.auth-foot { margin: 16px 0 0; text-align: center; }
.auth-foot a { text-decoration: underline; }
.modal form, form.modal { margin: 0; }
.modal { max-height: calc(100vh - 48px); overflow-y: auto; }
.owner-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px 12px; max-height: 180px; overflow-y: auto; padding: 8px; border: 1px solid var(--border); border-radius: 6px; font-size: 13px; }
.owner-list label { display: flex; gap: 6px; align-items: center; cursor: pointer; }
.temp-pw { font-size: 20px !important; letter-spacing: 1px; text-align: center; padding: 12px; border: 1px dashed var(--tick); border-radius: 6px; background: var(--bg); user-select: all; color: var(--text); }
input:disabled, select:disabled { opacity: .6; cursor: not-allowed; }

/* 侧栏二级菜单：经营总览下的监控、核查 */
.nav-sub { position: relative; margin: 0 0 4px 17px; padding-left: 12px; border-left: 1px solid var(--tick); }
#nav .nav-sub a { padding: 5px 8px; font-size: 13px; }
#nav a.parent { color: var(--text); font-weight: 500; }
#nav a.parent svg { color: var(--brand-600); }
/* 总览 / 监控 / 核查 页面标签 */
.page-tabs { margin: 4px 0 20px; }
.page-tabs a { padding: 0 12px 9px; font-size: 13px; color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.page-tabs a:hover { color: var(--text-2); border-bottom-color: var(--tick); }
.page-tabs a.on { color: var(--brand-600); border-bottom-color: var(--brand); font-weight: 500; }
.seg button { white-space: nowrap; }
/* 监控卡片 */
.mon-card .card-head { margin-bottom: 8px; }
.mon-big { font-size: 22px; font-weight: 600; margin: 0 0 8px; font-variant-numeric: tabular-nums; }
/* 核查：可展开的检查项 */
.au-card { padding: 0 20px; }
.au-item { border-bottom: 1px solid var(--border); }
.au-item:last-child { border-bottom: 0; }
.au-item summary { list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 16px 0; cursor: pointer; }
.au-item summary::-webkit-details-marker { display: none; }
.au-item summary:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 4px; }
.au-left, .au-right { display: flex; align-items: center; gap: 10px; }
.au-title { font-size: 14px; font-weight: 500; color: var(--text); }
.au-ratio { font-size: 13px; color: var(--muted-2); font-variant-numeric: tabular-nums; }
.au-ratio b { color: var(--text-2); font-weight: 500; }
.au-ic { width: 18px; height: 18px; flex-shrink: 0; }
.au-ic.pass { color: var(--good-fg); }
.au-ic.warn { color: var(--warn-fg); }
.au-ic.fail { color: var(--bad-fg); }
.au-chev { width: 18px; height: 18px; color: var(--muted-2); transition: transform .15s; }
.au-item[open] .au-chev { transform: rotate(180deg); }
.au-body { padding: 0 0 18px; }
.au-body .table-wrap { margin: 0; }
.au-body td .au-ic { width: 16px; height: 16px; }
.au-none { margin: 0; padding: 10px 12px; border-radius: 6px; background: var(--bg); color: var(--muted); }

/* 商品主图 */
a > .thumb { display: block; }
.mat-cell .thumb { background: var(--bg); }
.chart .mark-line { stroke: var(--warn-fg); stroke-width: 1.2; stroke-dasharray: 4 3; }
.chart .mark-text { fill: var(--warn-fg); font-size: 10px; font-weight: 500; }
.tt-mark { color: var(--warn-fg); font-weight: 500; border-top: 1px solid var(--border); margin-top: 2px; padding-top: 6px; }
.img-changes { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.img-change { display: flex; gap: 12px; align-items: center; padding: 10px; border: 1px solid var(--border); border-radius: 8px; }
.img-pair { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.img-arrow { color: var(--muted-2); }
.img-strip { display: flex; flex-wrap: wrap; gap: 12px; }
.img-cell { display: flex; flex-direction: column; align-items: center; gap: 4px; }

/* 网格里的卡片可以缩小，图表按容器宽度重绘 */
.grid > * { min-width: 0; }
.chart { overflow: hidden; }
