/* ==========================================================================
   admin.css — 一学 · 驾校约车 · PC 管理端（1440×900 基准，最小 1280）
   只给 admin.html 用；与手机端共用 tokens.css，不加载 base.css / ui.css。
   结构：侧栏 220（<1280 收 72） + 顶栏 56 + 内容区（表格页最大 1240，居中）。
   所有颜色 / 字体 / 圆角 / 阴影 / 间距都走 tokens.css 的变量，本文件不写死。
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
html, body { min-height: 100%; }
body.admin {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--fs-15);
  line-height: var(--lh-pc);
  color: var(--c-text-1);
  background: var(--c-bg);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, p, figure, pre { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button, input, textarea, select { font: inherit; color: inherit; }
button { border: 0; background: none; padding: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
svg { display: block; }
b { font-weight: var(--fw-s); }
.num { font-family: var(--font-num); font-variant-numeric: tabular-nums; font-feature-settings: "tnum" 1; font-style: normal; white-space: nowrap; }
.hide { display: none !important; }
.grow { flex: 1 1 auto; min-width: 0; }
:focus-visible { outline: 2px solid var(--c-brand); outline-offset: 2px; }

/* ---------- 骨架 ---------- */
.app { display: flex; min-height: 100vh; }
.sidebar {
  flex: 0 0 var(--w-side); width: var(--w-side); height: 100vh; position: sticky; top: 0;
  display: flex; flex-direction: column; padding: var(--sp-16) var(--sp-12) var(--sp-12);
  background: var(--c-card); border-right: 1px solid var(--c-line); z-index: 50;
}
.brand { display: flex; align-items: center; gap: var(--sp-10); padding: var(--sp-2) var(--sp-8) var(--sp-16); }
.brand__logo {
  width: 34px; height: 34px; border-radius: var(--r-10); flex: 0 0 auto;
  background: var(--c-brand); color: var(--c-on-brand);
  display: grid; place-items: center; box-shadow: var(--sh-brand);
}
.brand__text { display: flex; flex-direction: column; min-width: 0; }
.brand__text b { font-size: var(--fs-16); letter-spacing: -.01em; line-height: 1.3; }
.brand__text span { font-size: var(--fs-11); color: var(--c-text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-co {
  display: flex; align-items: center; gap: var(--sp-8); margin: 0 var(--sp-2) var(--sp-12); padding: var(--sp-8) var(--sp-10);
  background: var(--c-fill); border: 1px solid var(--c-line); border-radius: var(--r-12); text-align: left;
}
.side-co:hover { border-color: var(--c-line-2); }
.side-co__main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.side-co__main b { font-size: var(--fs-12); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-co__main span { font-size: var(--fs-11); color: var(--c-text-2); }
.side-co__dot { width: 7px; height: 7px; border-radius: var(--r-99); background: var(--c-success); flex: 0 0 auto; outline: 3px solid var(--c-success-soft); }

.nav { flex: 1; min-height: 0; overflow-y: auto; }
.nav__label { padding: var(--sp-12) var(--sp-10) var(--sp-4); font-size: var(--fs-10); letter-spacing: .1em; color: var(--c-text-2); font-weight: var(--fw-m); }
.nav__item {
  position: relative; display: flex; align-items: center; gap: var(--sp-10);
  min-height: 40px; padding: 0 var(--sp-10); margin: var(--sp-2) 0; border-radius: var(--r-10);
  font-size: var(--fs-13); color: var(--c-text-2);
  transition: background var(--t-fast), color var(--t-fast);
}
.nav__item:hover { background: var(--c-fill); color: var(--c-text-1); }
.nav__item.is-on { background: var(--c-brand-soft); color: var(--c-brand-ink); font-weight: var(--fw-m); }
.nav__item.is-on::before {
  content: ""; position: absolute; left: -12px; top: 9px; bottom: 9px; width: 3px;
  border-radius: 0 var(--r-2) var(--r-2) 0; background: var(--c-brand);
}
.nav__icon { display: inline-flex; color: currentColor; }
.nav__badge {
  margin-left: auto; min-width: 18px; height: 18px; padding: 0 var(--sp-4); border-radius: var(--r-99);
  background: var(--c-brand); color: var(--c-on-brand); font-size: var(--fs-10); line-height: 18px;
  text-align: center; font-variant-numeric: tabular-nums;
}
.side-foot { flex: 0 0 auto; padding-top: var(--sp-10); border-top: 1px solid var(--c-line); }
.side-user { display: flex; align-items: center; gap: var(--sp-8); padding: var(--sp-6) var(--sp-4) 0; }
.side-user__main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.side-user__main b { font-size: var(--fs-12); }
.side-user__main span { font-size: var(--fs-10); color: var(--c-text-2); }
.dot-online { width: 7px; height: 7px; border-radius: var(--r-99); background: var(--c-success); flex: 0 0 auto; }

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: var(--sp-10);
  height: var(--h-top); padding: 0 var(--sp-24);
  background: var(--c-glass); backdrop-filter: blur(14px); border-bottom: 1px solid var(--c-line);
}
.crumb { display: flex; align-items: center; gap: var(--sp-6); font-size: var(--fs-12); color: var(--c-text-2); white-space: nowrap; }
.crumb i { color: var(--c-text-4); font-style: normal; }
.crumb b { color: var(--c-text-1); font-weight: var(--fw-m); }
.topbar__spacer { flex: 1; }
.top-search {
  display: flex; align-items: center; gap: var(--sp-6); width: 236px; height: 34px; padding: 0 var(--sp-12);
  background: var(--c-fill); border-radius: var(--r-99); color: var(--c-text-2);
}
.top-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-size: var(--fs-12); color: var(--c-text-1); }
.top-search input::placeholder { color: var(--c-text-3); }
.top-ver {
  display: inline-flex; align-items: center; height: 26px; padding: 0 var(--sp-10);
  border-radius: var(--r-99); background: var(--c-brand-soft); color: var(--c-brand-ink);
  font-size: var(--fs-11); font-weight: var(--fw-m); white-space: nowrap;
}
.top-fresh {
  display: inline-flex; align-items: center; gap: var(--sp-6); height: 26px; padding: 0 var(--sp-10);
  border-radius: var(--r-99); background: var(--c-fill); font-size: var(--fs-11); color: var(--c-text-2); white-space: nowrap;
}
.top-date { font-size: var(--fs-11); color: var(--c-text-2); white-space: nowrap; }
.top-user { display: inline-flex; align-items: center; gap: var(--sp-6); padding-left: var(--sp-10); border-left: 1px solid var(--c-line); font-size: var(--fs-11); color: var(--c-text-2); white-space: nowrap; }
.top-user .avatar { width: 24px; height: 24px; font-size: var(--fs-10); }
.icon-btn {
  position: relative; width: 34px; height: 34px; border-radius: var(--r-99);
  display: grid; place-items: center; color: var(--c-text-2); background: var(--c-fill);
}
.icon-btn:hover { color: var(--c-text-1); background: var(--c-line); }
.icon-btn__dot {
  position: absolute; top: 5px; right: 6px; min-width: 14px; height: 14px; padding: 0 var(--sp-2);
  border-radius: var(--r-99); background: var(--c-brand); color: var(--c-on-brand);
  font-size: var(--fs-10); line-height: 14px; text-align: center; font-variant-numeric: tabular-nums;
}
.view { flex: 1; width: 100%; max-width: var(--w-content); margin: 0 auto; padding: var(--sp-20) var(--sp-24) var(--sp-10); }
.view--wide { max-width: none; padding: var(--sp-16) var(--sp-16) var(--sp-10); }
.admin-foot {
  position: sticky; bottom: 0; z-index: 20;
  max-width: var(--w-content); width: 100%; margin: 0 auto; padding: var(--sp-10) var(--sp-24) var(--sp-12);
  font-size: var(--fs-11); color: var(--c-text-2); display: flex; gap: var(--sp-10); flex-wrap: wrap;
  background: var(--c-glass); backdrop-filter: blur(12px); border-top: 1px solid var(--c-line);
}
.view--wide ~ .admin-foot { max-width: none; }

/* ---------- 通用件 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--sp-6);
  height: 38px; padding: 0 var(--sp-16); border-radius: var(--r-99); border: 1px solid transparent;
  font-size: var(--fs-13); font-weight: var(--fw-m); white-space: nowrap;
  transition: background var(--t-fast), border-color var(--t-fast), color var(--t-fast);
}
.btn--primary { background: var(--c-brand-strong); color: var(--c-on-brand); box-shadow: var(--sh-brand); }
.btn--primary:hover { background: var(--c-brand-ink); }
.btn--ghost { background: var(--c-card); border-color: var(--c-line-2); color: var(--c-text-1); }
.btn--ghost:hover { background: var(--c-fill); }
.btn--soft { background: var(--c-brand-soft); color: var(--c-brand-ink); }
.btn--soft:hover { background: var(--c-brand-weak); }
.btn--danger { background: var(--c-danger-soft); color: var(--c-danger-ink); }
.btn--danger:hover { background: var(--c-danger); color: var(--c-on-brand); }
.btn--sm { height: 30px; padding: 0 var(--sp-10); font-size: var(--fs-12); }
.btn--xs { height: 26px; padding: 0 var(--sp-8); font-size: var(--fs-11); }
.btn--block { width: 100%; }
.btn:disabled { opacity: .42; box-shadow: none; cursor: not-allowed; }
.btn:disabled:hover { background: var(--c-fill); color: var(--c-text-2); }

.card { background: var(--c-card); border: 1px solid var(--c-line); border-radius: var(--r-14); box-shadow: var(--sh-1); }
.panel { background: var(--c-card); border: 1px solid var(--c-line); border-radius: var(--r-14); box-shadow: var(--sh-1); overflow: hidden; }
.panel + .panel, .panel + .card, .card + .panel { margin-top: var(--sp-14); }
.panel__head { display: flex; align-items: center; gap: var(--sp-8); padding: var(--sp-12) var(--sp-16); border-bottom: 1px solid var(--c-line); flex-wrap: wrap; }
.panel__title { font-size: var(--fs-14); font-weight: var(--fw-s); }
.panel__sub { font-size: var(--fs-11); color: var(--c-text-2); }
.panel__action { margin-left: auto; font-size: var(--fs-12); color: var(--c-brand); display: inline-flex; align-items: center; gap: var(--sp-2); }
.panel__action:hover { color: var(--c-brand-strong); }
.panel__body { padding: var(--sp-14) var(--sp-16); }
.panel__body--flush { padding: 0; }

.tag {
  display: inline-flex; align-items: center; gap: var(--sp-4); padding: var(--sp-2) var(--sp-8); border-radius: var(--r-99);
  font-size: var(--fs-10); font-weight: var(--fw-m); line-height: 1.6; background: var(--c-fill); color: var(--c-text-2); white-space: nowrap;
}
.tag--brand { background: var(--c-brand-soft); color: var(--c-brand-ink); }
.tag--warn { background: var(--c-warn-soft); color: var(--c-warn-ink); }
.tag--success { background: var(--c-success-soft); color: var(--c-success-ink); }
.tag--danger { background: var(--c-danger-soft); color: var(--c-danger-ink); }
.tag--info { background: var(--c-info-soft); color: var(--c-info-ink); }
.tag--muted { background: var(--c-fill); color: var(--c-text-2); }
.tag--line { background: transparent; border: 1px solid var(--c-line-2); }
.tag--wait { background: var(--c-flow-wait-soft); color: var(--c-brand-ink); }
.tag--pass { background: var(--c-flow-pass-soft); color: var(--c-flow-pass); }
.tag--reject { background: var(--c-flow-reject-soft); color: var(--c-flow-reject); }
.tag--cc { background: var(--c-flow-cc-soft); color: var(--c-flow-cc-ink); }

.avatar {
  flex: 0 0 auto; width: 30px; height: 30px; border-radius: var(--r-99); display: inline-flex;
  align-items: center; justify-content: center; color: var(--c-on-brand);
  font-size: var(--fs-11); font-weight: var(--fw-m); background: var(--c-brand);
}
.avatar--sm { width: 26px; height: 26px; font-size: var(--fs-10); }
.avatar--lg { width: 42px; height: 42px; font-size: var(--fs-14); }
.avatar--t2 { background: var(--c-info); }
.avatar--t3 { background: var(--c-warn); }
.avatar--t4 { background: var(--c-success); }
.avatar--t5 { background: var(--c-purple); }

/* ---------- 页头 ---------- */
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: var(--sp-18); margin-bottom: var(--sp-16); }
.page-head__eyebrow { font-size: var(--fs-11); color: var(--c-text-2); letter-spacing: .06em; }
.page-head h1 { font-size: var(--fs-24); font-weight: var(--fw-s); letter-spacing: -.02em; line-height: 1.25; margin-top: var(--sp-2); }
.page-head__sub { font-size: var(--fs-12); color: var(--c-text-2); margin-top: var(--sp-4); }
.page-head__actions { display: flex; align-items: center; gap: var(--sp-8); flex: 0 0 auto; }

/* ---------- 指标卡 ---------- */
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--sp-12); margin-bottom: var(--sp-14); }
.kpi { padding: var(--sp-14) var(--sp-16); }
.kpi--link { display: block; width: 100%; text-align: left; cursor: pointer; transition: border-color var(--t-fast), box-shadow var(--t-fast), transform var(--t-fast); }
.kpi--link:hover { border-color: var(--c-brand-weak); box-shadow: var(--sh-2); transform: translateY(-1px); }
.kpi__label { display: flex; align-items: center; gap: var(--sp-6); font-size: var(--fs-11); color: var(--c-text-2); }
.kpi__label .kpi__go { margin-left: auto; color: var(--c-text-3); }
.kpi__value {
  display: flex; align-items: baseline; gap: var(--sp-4); margin-top: var(--sp-4);
  font-size: var(--fs-26); font-weight: var(--fw-s); letter-spacing: -.02em; line-height: 1.15;
  font-variant-numeric: tabular-nums;
}
.kpi__value small { font-size: var(--fs-11); font-weight: var(--fw-r); color: var(--c-text-2); letter-spacing: 0; }
.kpi__sub { font-size: var(--fs-10); color: var(--c-text-2); margin-top: var(--sp-4); }
.kpi--warn { background: var(--c-warn-soft); border-color: var(--c-warn-soft); }
.kpi--warn .kpi__value { color: var(--c-warn-ink); }
.kpi--danger { background: var(--c-danger-soft); border-color: var(--c-danger-soft); }
.kpi--danger .kpi__value { color: var(--c-danger-ink); }

/* ---------- 进度条 ---------- */
.bar { display: inline-block; width: 100%; height: 6px; border-radius: var(--r-99); background: var(--c-line); overflow: hidden; min-width: 56px; vertical-align: middle; }
.bar span { display: block; height: 100%; border-radius: var(--r-99); background: var(--c-brand); }
.bar--done span { background: var(--c-success); }
.bar--warn span { background: var(--c-warn); }
.bar--danger span { background: var(--c-danger); }
.bar--muted span { background: var(--c-line-2); }
.prog-cell { display: flex; align-items: center; gap: var(--sp-8); }
.prog-cell .bar { flex: 1; }

/* ---------- 表格 ---------- */
.table-wrap { overflow-x: auto; }
table.tbl { width: 100%; border-collapse: collapse; font-size: var(--fs-12); }
table.tbl th {
  padding: 0 var(--sp-12); height: var(--h-thead); text-align: left; font-size: var(--fs-10); font-weight: var(--fw-m);
  color: var(--c-text-2); background: var(--c-fill); border-bottom: 1px solid var(--c-line);
  white-space: nowrap; position: sticky; top: 0; z-index: 1;
}
table.tbl td { padding: 0 var(--sp-12); height: var(--h-row); border-bottom: 1px solid var(--c-line); vertical-align: middle; white-space: nowrap; }
table.tbl tbody tr:last-child td { border-bottom: 0; }
table.tbl tbody tr { transition: background var(--t-fast); }
table.tbl tbody tr.is-click { cursor: pointer; }
table.tbl tbody tr.is-click:hover { background: var(--c-fill); }
table.tbl tbody tr.is-overdue td { background: var(--c-danger-soft); }
table.tbl .text-right { text-align: right; }
table.tbl .text-center { text-align: center; }
.cell { display: flex; align-items: center; gap: var(--sp-8); min-width: 0; }
.cell__main { display: flex; flex-direction: column; min-width: 0; line-height: 1.35; }
.cell__main b { font-size: var(--fs-12); font-weight: var(--fw-m); }
.cell__main .sub { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sub { font-size: var(--fs-10); color: var(--c-text-2); }
.sub--sm { font-size: var(--fs-10); }
.table-foot {
  display: flex; align-items: center; justify-content: space-between; gap: var(--sp-12);
  padding: var(--sp-8) var(--sp-16); border-top: 1px solid var(--c-line); font-size: var(--fs-11); color: var(--c-text-2);
}

/* ---------- 筛选 ---------- */
.filter-row { display: flex; align-items: center; gap: var(--sp-8); margin-bottom: var(--sp-10); flex-wrap: wrap; }
.search {
  display: flex; align-items: center; gap: var(--sp-6); height: 32px; padding: 0 var(--sp-12);
  background: var(--c-card); border: 1px solid var(--c-line); border-radius: var(--r-99); color: var(--c-text-2);
}
.search input { border: 0; outline: 0; background: transparent; font-size: var(--fs-12); width: 200px; color: var(--c-text-1); }
.search input::placeholder { color: var(--c-text-3); }
.chip {
  height: 30px; padding: 0 var(--sp-12); border-radius: var(--r-99); border: 1px solid var(--c-line);
  background: var(--c-card); font-size: var(--fs-12); color: var(--c-text-2); white-space: nowrap;
}
.chip:hover { border-color: var(--c-line-2); color: var(--c-text-1); }
.chip.is-on { background: var(--c-brand-soft); border-color: var(--c-brand-weak); color: var(--c-brand-ink); font-weight: var(--fw-m); }
.chip__n { font-variant-numeric: tabular-nums; color: var(--c-text-3); margin-left: var(--sp-4); }
.chip.is-on .chip__n { color: var(--c-brand-ink); }
.seg { display: inline-flex; gap: var(--sp-2); padding: var(--sp-2); background: var(--c-fill); border-radius: var(--r-99); }
.seg__btn { min-height: 28px; padding: 0 var(--sp-12); border-radius: var(--r-99); font-size: var(--fs-11); color: var(--c-text-2); }
.seg__btn.is-on { background: var(--c-card); color: var(--c-text-1); font-weight: var(--fw-m); box-shadow: var(--sh-1); }
.toolbar { display: flex; align-items: center; gap: var(--sp-10); flex-wrap: wrap; }
.toolbar__note { font-size: var(--fs-11); color: var(--c-text-2); }

/* ---------- 勾选 ---------- */
.check { position: relative; width: 18px; height: 18px; display: inline-block; vertical-align: middle; flex: 0 0 auto; }
.check input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; margin: 0; cursor: pointer; }
.check span {
  width: 18px; height: 18px; border-radius: var(--r-6); border: 1.4px solid var(--c-line-2);
  display: grid; place-items: center; color: transparent; background: var(--c-card); pointer-events: none;
}
.check input:checked + span { background: var(--c-brand); border-color: var(--c-brand); color: var(--c-on-brand); }
.check input:focus-visible + span { outline: 2px solid var(--c-brand); outline-offset: 2px; }
.check input:disabled + span { background: var(--c-fill); border-color: var(--c-line); }

/* ---------- 开关 ---------- */
.switch {
  position: relative; width: 38px; height: 22px; border-radius: var(--r-99);
  background: var(--c-line-2); flex: 0 0 auto; transition: background var(--t-base);
}
.switch__knob {
  position: absolute; left: 2px; top: 2px; width: 18px; height: 18px;
  border-radius: var(--r-99); background: var(--c-card); box-shadow: var(--sh-1);
  transition: transform var(--t-base) var(--ease-spring);
}
.switch.is-on { background: var(--c-brand); }
.switch.is-on .switch__knob { transform: translateX(16px); }
.switch.is-disabled { opacity: .5; cursor: not-allowed; }

/* ---------- 列表行 ---------- */
.row {
  display: flex; align-items: flex-start; gap: var(--sp-10); padding: var(--sp-10) 0;
  border-top: 1px solid var(--c-line);
}
.row:first-child { border-top: 0; padding-top: var(--sp-2); }
.row--flush:first-child { padding-top: var(--sp-10); }
.row__main { flex: 1; min-width: 0; }
.row__title { font-size: var(--fs-12); font-weight: var(--fw-m); }
.row__meta { font-size: var(--fs-10); color: var(--c-text-2); margin-top: var(--sp-2); }
.row__quote { font-size: var(--fs-12); color: var(--c-text-1); margin-top: var(--sp-6); line-height: 1.55; }
.row__side { flex: 0 0 auto; display: flex; align-items: center; gap: var(--sp-6); }
.row__amt { font-size: var(--fs-13); font-weight: var(--fw-s); font-variant-numeric: tabular-nums; }
.split { display: grid; grid-template-columns: 1.25fr .75fr; gap: var(--sp-14); align-items: start; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-14); align-items: start; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--sp-14); align-items: start; }

/* ---------- 明细 / 说明 ---------- */
.kv { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-8) var(--sp-14); }
.kv--3 { grid-template-columns: repeat(3, 1fr); }
.kv > div { display: flex; flex-direction: column; gap: var(--sp-2); min-width: 0; }
.kv dt, .kv .k { font-size: var(--fs-10); color: var(--c-text-2); }
.kv dd, .kv .v { margin: 0; font-size: var(--fs-12); font-weight: var(--fw-m); overflow: hidden; text-overflow: ellipsis; }
.note { display: flex; align-items: flex-start; gap: var(--sp-6); font-size: var(--fs-11); color: var(--c-text-2); line-height: 1.6; }
.note b { color: var(--c-text-1); }
.note--warn { color: var(--c-warn-ink); }
.note--danger { color: var(--c-danger-ink); }
.note--success { color: var(--c-success-ink); }
.quote {
  background: var(--c-fill); border-radius: var(--r-10); padding: var(--sp-8) var(--sp-12);
  font-size: var(--fs-12); line-height: 1.6; color: var(--c-text-1);
}
.quote--danger { background: var(--c-danger-soft); color: var(--c-danger-ink); }
.sect { margin-top: var(--sp-16); }
.sect:first-child { margin-top: 0; }
.sect__title {
  display: flex; align-items: center; gap: var(--sp-6); margin-bottom: var(--sp-8);
  font-size: var(--fs-10); font-weight: var(--fw-m); letter-spacing: .06em; color: var(--c-text-2);
}
.sect__title .tag { margin-left: auto; letter-spacing: 0; }
.empty { padding: var(--sp-24) var(--sp-16); text-align: center; font-size: var(--fs-12); color: var(--c-text-2); }
.empty b { display: block; font-size: var(--fs-13); color: var(--c-text-1); margin-bottom: var(--sp-4); }

/* ---------- 占位色块 ---------- */
.ph-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(108px, 1fr)); gap: var(--sp-8); }
.ph { border-radius: var(--r-8); overflow: hidden; border: 1px solid var(--c-line); background: var(--c-card); }
.ph__img { height: 58px; background: var(--c-tone-1); display: grid; place-items: center; color: var(--c-tone-ink); position: relative; }
.ph__img::after { content: ""; position: absolute; inset: 0; background: linear-gradient(160deg, var(--c-image-tint), transparent 55%), linear-gradient(0deg, var(--c-tone-shade), transparent 60%); }
.ph--t2 .ph__img { background: var(--c-tone-2); }
.ph--t3 .ph__img { background: var(--c-tone-3); }
.ph--t4 .ph__img { background: var(--c-tone-4); }
.ph--t5 .ph__img { background: var(--c-tone-5); }
.ph--t6 .ph__img { background: var(--c-tone-6); }
.ph__cap { padding: var(--sp-4) var(--sp-6); font-size: var(--fs-10); line-height: 1.4; color: var(--c-text-2); }
.ph__cap b { display: block; color: var(--c-text-1); font-weight: var(--fw-m); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- 抽屉 ---------- */
.drawer { position: fixed; inset: 0; z-index: 120; display: none; }
.drawer.is-on { display: block; }
.drawer__mask { position: absolute; inset: 0; background: var(--c-mask); opacity: 0; transition: opacity var(--t-base); }
.drawer.is-on .drawer__mask { opacity: 1; }
.drawer__card {
  position: absolute; top: 0; right: 0; bottom: 0; width: var(--w-drawer); max-width: 96vw;
  display: flex; flex-direction: column; background: var(--c-card);
  box-shadow: var(--sh-3); transform: translateX(14px); opacity: .6;
  transition: transform var(--t-base) var(--ease-out), opacity var(--t-base);
}
.drawer.is-on .drawer__card { transform: none; opacity: 1; }
.drawer__head { flex: 0 0 auto; display: flex; align-items: flex-start; gap: var(--sp-8); padding: var(--sp-16) var(--sp-18) var(--sp-12); border-bottom: 1px solid var(--c-line); }
.drawer__title { font-size: var(--fs-17); font-weight: var(--fw-s); letter-spacing: -.01em; line-height: 1.35; }
.drawer__sub { font-size: var(--fs-11); color: var(--c-text-2); margin-top: var(--sp-2); }
.drawer__close { margin-left: auto; width: 30px; height: 30px; border-radius: var(--r-99); background: var(--c-fill); color: var(--c-text-2); display: grid; place-items: center; flex: 0 0 auto; }
.drawer__close:hover { background: var(--c-line); color: var(--c-text-1); }
.drawer__body { flex: 1; min-height: 0; overflow-y: auto; padding: var(--sp-14) var(--sp-18) var(--sp-18); }
.drawer__foot { flex: 0 0 auto; display: flex; gap: var(--sp-8); padding: var(--sp-12) var(--sp-18); border-top: 1px solid var(--c-line); background: var(--c-card); }
.drawer__foot .btn { flex: 1; }

/* ---------- 表单 ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-10) var(--sp-12); }
.field { display: flex; flex-direction: column; gap: var(--sp-4); min-width: 0; }
.field--full { grid-column: 1 / -1; }
.field > span { font-size: var(--fs-10); color: var(--c-text-2); }
.field input, .field select, .field textarea {
  height: 36px; min-width: 0; padding: 0 var(--sp-10); font-size: var(--fs-12);
  border: 1px solid var(--c-line-2); border-radius: var(--r-8); background: var(--c-card);
  color: var(--c-text-1); outline: 0; transition: border-color var(--t-fast);
}
.field textarea { height: 74px; padding: var(--sp-8) var(--sp-10); line-height: 1.55; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--c-brand); }
.field input[readonly] { background: var(--c-fill); color: var(--c-text-2); }
.field__hint { font-size: var(--fs-10); color: var(--c-text-2); line-height: 1.5; }
.field__err { font-size: var(--fs-10); color: var(--c-danger-ink); }
.field.is-bad input, .field.is-bad select, .field.is-bad textarea { border-color: var(--c-danger); }
.line-rows { display: grid; gap: var(--sp-8); }
.line-row { display: grid; grid-template-columns: 1.6fr 64px 64px 92px 28px; gap: var(--sp-6); align-items: center; }
.line-row input { height: 34px; padding: 0 var(--sp-8); border: 1px solid var(--c-line-2); border-radius: var(--r-8); font-size: var(--fs-12); outline: 0; min-width: 0; }
.line-row input:focus { border-color: var(--c-brand); }
.line-row .icon-btn { width: 28px; height: 28px; border-radius: var(--r-8); }

/* ---------- 弹窗 ---------- */
.modal { position: fixed; inset: 0; z-index: 140; display: none; align-items: center; justify-content: center; padding: var(--sp-20); }
.modal.is-on { display: flex; }
.modal__mask { position: absolute; inset: 0; background: var(--c-mask); }
.modal__card {
  position: relative; z-index: 1; width: 420px; max-width: 100%;
  background: var(--c-card); border-radius: var(--r-18); padding: var(--sp-18); box-shadow: var(--sh-3);
}
.modal__title { font-size: var(--fs-16); font-weight: var(--fw-s); }
.modal__text { font-size: var(--fs-12); color: var(--c-text-2); line-height: 1.65; margin-top: var(--sp-6); }
.modal__actions { display: flex; gap: var(--sp-8); margin-top: var(--sp-16); }
.modal__actions .btn { flex: 1; }

/* ---------- 提示条 ---------- */
.toast {
  position: fixed; left: 50%; bottom: 28px; transform: translate(-50%, 10px);
  z-index: 160; max-width: 480px; padding: var(--sp-8) var(--sp-16); border-radius: var(--r-99);
  background: var(--c-scrim); color: var(--c-on-dark); font-size: var(--fs-12);
  opacity: 0; pointer-events: none; transition: opacity var(--t-fast), transform var(--t-fast);
}
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* ---------- 报表通用 ---------- */
.chart { display: flex; align-items: flex-end; gap: var(--sp-12); height: 132px; padding-top: var(--sp-6); }
.chart__col { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: var(--sp-4); height: 100%; }
.chart__bar { width: 100%; max-width: 46px; border-radius: var(--r-6) var(--r-6) 0 0; background: var(--c-chart-1); min-height: 2px; }
.chart__bar--soft { background: var(--c-chart-2); }
.chart__bar--muted { background: var(--c-chart-4); }
.chart__val { font-size: var(--fs-10); font-variant-numeric: tabular-nums; color: var(--c-text-1); }
.chart__label { font-size: var(--fs-10); color: var(--c-text-2); text-align: center; line-height: 1.3; }
.rate-row { display: flex; align-items: center; gap: var(--sp-10); padding: var(--sp-8) 0; border-top: 1px solid var(--c-line); }
.rate-row:first-child { border-top: 0; }
.rate-row__main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: var(--sp-4); }
.rate-row__top { display: flex; align-items: baseline; gap: var(--sp-6); }
.rate-row__top b { font-size: var(--fs-12); }
.rate-row__top span { font-size: var(--fs-10); color: var(--c-text-2); }
.rate-row__pct { flex: 0 0 auto; font-size: var(--fs-13); font-weight: var(--fw-s); font-variant-numeric: tabular-nums; }
.csv {
  font-size: var(--fs-11); line-height: 1.6; white-space: pre-wrap; word-break: break-all;
  background: var(--c-fill); border-radius: var(--r-10); padding: var(--sp-10) var(--sp-12); max-height: 320px; overflow: auto;
  font-variant-numeric: tabular-nums;
}
.set-layout { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, .65fr); gap: var(--sp-14); align-items: start; }

/* ---------- 窄屏：侧栏收成 72px 图标栏 ---------- */
@media (max-width: 1279px) {
  .sidebar { flex-basis: var(--w-side-min); width: var(--w-side-min); padding: var(--sp-16) var(--sp-8) var(--sp-12); }
  .brand { justify-content: center; padding: var(--sp-2) 0 var(--sp-14); }
  .brand__text, .side-co__main, .side-co > svg, .nav__label, .nav__text, .side-user__main, .dot-online { display: none; }
  .side-co { justify-content: center; padding: var(--sp-8); }
  .side-co__dot { margin: 0; }
  .nav__item { justify-content: center; padding: 0; }
  .nav__item.is-on::before { left: -8px; }
  .nav__badge { position: absolute; top: 5px; right: 6px; margin: 0; transform: none; }
  .side-user { justify-content: center; padding: var(--sp-6) 0 0; }
  .top-search { width: 190px; }
  .view { padding: var(--sp-20) var(--sp-20) var(--sp-10); }
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split, .set-layout { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 1023px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .top-search, .top-ver, .top-fresh { display: none; }
  .kv--3 { grid-template-columns: 1fr 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
