:root {
  --bg: #f5f7fa;
  --surface: #ffffff;
  --surface-2: #fafbfd;
  --ink: #0d1526;
  --ink-2: #4a5568;
  --muted: #94a1b2;
  --line: #e8edf5;
  --line-2: #f1f4f9;
  --primary: #165dff;
  --primary-dark: #0d47d9;
  --primary-soft: #eff4ff;
  --success: #12b76a;
  --success-soft: #e8f8f0;
  --warn: #f79009;
  --warn-soft: #fff6e8;
  --danger: #f04438;
  --danger-soft: #feecea;
  --radius: 14px;
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, .04);
  --shadow: 0 6px 24px -12px rgba(16, 24, 40, .18);
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: system-ui, -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}
button, input, select { font-family: inherit; font-size: inherit; color: inherit; }
button { cursor: pointer; border: none; background: none; }
a { color: inherit; text-decoration: none; }
.num { font-variant-numeric: tabular-nums; }

/* ================= 骨架 ================= */
.app { display: grid; grid-template-columns: 204px 1fr; height: 100vh; overflow: hidden; }

/* 侧栏：改为浅色，弱化存在感 */
.side {
  background: var(--surface);
  border-right: 1px solid var(--line);
  display: flex; flex-direction: column;
  padding: 20px 14px 14px; gap: 2px;
}
.brand { display: flex; align-items: center; gap: 10px; padding: 0 6px 22px; }
.brand-mark {
  width: 30px; height: 30px; border-radius: 9px;
  background: linear-gradient(150deg, #2b74ff, #165dff);
  display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 14px;
  box-shadow: 0 4px 10px rgba(22, 93, 255, .28);
}
.brand-txt { line-height: 1.3; }
.brand-txt b { display: block; font-size: 14px; letter-spacing: .2px; }
.brand-txt span { font-size: 10.5px; color: var(--muted); letter-spacing: .8px; }

.nav-label { font-size: 11px; color: var(--muted); padding: 6px 10px 8px; letter-spacing: .6px; }
.nav-item {
  display: flex; align-items: center; gap: 9px;
  padding: 8px 10px; border-radius: 9px; margin-bottom: 2px;
  color: var(--ink-2); font-size: 13px; transition: .14s;
}
.nav-item:hover { background: var(--surface-2); color: var(--ink); }
.nav-item.on { background: var(--primary-soft); color: #1148c9; font-weight: 600; }
.nav-item svg { width: 16px; height: 16px; flex: none; }
/* 侧栏底部：今日进度小卡 */
.side-card {
  margin-top: auto;
  background: linear-gradient(160deg, #f7f9ff, #f2f5fd);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 12px 12px 11px;
  margin-bottom: 10px;
}
.side-card:empty { display: none; }
.side-card .sc-top { display: flex; align-items: baseline; justify-content: space-between; }
.side-card .sc-top span { font-size: 11.5px; color: var(--muted); }
.side-card .sc-top b { font-size: 13px; color: var(--primary); font-weight: 650; }
.side-card .sc-bar { height: 5px; border-radius: 99px; background: #e3e9f5; overflow: hidden; margin: 7px 0 8px; }
.side-card .sc-bar i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, #4d8bff, #165dff); }
.side-card .sc-num { display: flex; align-items: baseline; gap: 4px; margin-bottom: 8px; }
.side-card .sc-num b { font-size: 19px; font-weight: 700; letter-spacing: -.4px; line-height: 1; }
.side-card .sc-num span { font-size: 11px; color: var(--muted); }
.side-card .sc-row { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--muted); padding: 2px 0; }
.side-card .sc-row b { color: var(--ink-2); font-weight: 600; }

.side-foot {
  padding: 10px 8px 2px; font-size: 11.5px;
  color: var(--muted); line-height: 1.9; border-top: 1px solid var(--line-2);
}

.main { display: flex; flex-direction: column; overflow: hidden; }
.topbar {
  height: 58px; flex: none;
  display: flex; align-items: center; gap: 12px;
  padding: 0 26px;
}
.topbar h1 { font-size: 16.5px; margin: 0; font-weight: 650; letter-spacing: .1px; white-space: nowrap; }
.topbar .sub { color: var(--muted); font-size: 12.5px; }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 8px; }

.view { padding: 4px 26px 30px; overflow-y: auto; flex: 1; }

/* ================= 通用件 ================= */
.panel {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow-sm);
}
.panel-h { display: flex; align-items: center; gap: 8px; padding: 16px 18px 0; }
.panel-h h2 { font-size: 13.5px; margin: 0; font-weight: 600; }
.panel-h .hint { color: var(--muted); font-size: 11.5px; }
.panel-h .right { margin-left: auto; display: flex; gap: 8px; align-items: center; }

.btn {
  display: inline-flex; align-items: center; gap: 6px;
  height: 32px; padding: 0 12px; border-radius: 8px;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink-2);
  font-size: 12.5px; transition: .14s; white-space: nowrap;
}
.btn:hover { border-color: #d3dceb; color: var(--ink); }
.btn.primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.btn.primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); color: #fff; }
.btn.ghost { border-color: transparent; background: transparent; color: var(--muted); }
.btn.ghost:hover { background: var(--surface-2); color: var(--ink-2); }
.btn.icon { width: 32px; padding: 0; justify-content: center; }
.btn svg { width: 15px; height: 15px; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  height: 26px; padding: 0 10px; border-radius: 99px;
  font-size: 11.5px; background: var(--surface-2); border: 1px solid var(--line); color: var(--ink-2);
}
.chip .dot { width: 6px; height: 6px; border-radius: 99px; background: var(--muted); }
.chip.ok { background: var(--success-soft); border-color: #cdf0de; color: #08875a; }
.chip.ok .dot { background: var(--success); }
.chip.warn { background: var(--warn-soft); border-color: #ffe6c2; color: #b25e00; }
.chip.warn .dot { background: var(--warn); }
.chip.err { background: #fdeceb; border-color: #f9d4d1; color: #c0352d; }
.chip.err .dot { background: var(--danger); }
.chip.live .dot { animation: pulse 1.5s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1 } 50% { opacity: .25 } }

.tag { display: inline-flex; align-items: center; height: 21px; padding: 0 7px; border-radius: 5px; font-size: 11.5px; font-weight: 500; }
.tag.pending { background: #f1f3f7; color: #667085; }
.tag.partial { background: var(--primary-soft); color: #1148c9; }
.tag.done { background: var(--success-soft); color: #08875a; }
.tag.over { background: var(--danger-soft); color: #c0281c; }
.tag.box-done { background: #12b76a; color: #fff; font-weight: 700; }
.tag.box-wait { background: #f79009; color: #fff; font-weight: 700; }

select.date, input.search {
  height: 32px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface);
  padding: 0 10px; font-size: 12.5px; color: var(--ink); outline: none;
}
input.search { width: 220px; }
input.search:focus, select.date:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(22, 93, 255, .09); }

/* ================= 看板 · 一屏铺满 ================= */
/* 三块：左上=进度主卡，左下=待扫清单，右列=最近扫描（跨两行） */
.view.dash {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 348px;
  grid-template-rows: auto minmax(190px, 1fr);
  gap: 14px;
  padding: 2px 24px 20px;
}
.view.dash > .panel { min-width: 0; }

.hero-main { grid-column: 1; grid-row: 1; padding: 18px 20px 16px; display: flex; flex-direction: column; }
.hero-top { display: flex; align-items: flex-end; gap: 16px; }
.hero-cap { font-size: 12px; color: var(--muted); margin-bottom: 6px; }
.hero-num { display: flex; align-items: baseline; gap: 8px; }
.hero-num b { font-size: 40px; font-weight: 700; letter-spacing: -1.4px; line-height: 1; }
.hero-num span { font-size: 13.5px; color: var(--muted); }
.hero-pct { margin-left: auto; text-align: right; }
.hero-pct b { display: block; font-size: 21px; font-weight: 650; letter-spacing: -.4px; color: var(--primary); }
.hero-pct span { font-size: 11.5px; color: var(--muted); }

.hero-main .bar { height: 8px; border-radius: 99px; background: #eff2f7; overflow: hidden; display: flex; margin: 16px 0 10px; }
.hero-main .bar > i { display: block; height: 100%; transition: width .5s cubic-bezier(.2, .8, .2, 1); }
.hero-main .bar > i.done { background: var(--success); }
.hero-main .bar > i.partial { background: var(--primary); }

.hero-legend { display: flex; gap: 18px; font-size: 11.5px; color: var(--ink-2); }
.hero-legend span { display: inline-flex; align-items: center; gap: 6px; }
.hero-legend em { width: 7px; height: 7px; border-radius: 99px; font-style: normal; }

/* 四个指标：等分 + 竖线分隔，避免宽屏下松散 */
.hero-stats {
  display: grid; grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line-2); margin-top: 16px; padding-top: 14px;
}
.hero-stats > div { padding: 0 18px; border-left: 1px solid var(--line-2); min-width: 0; }
.hero-stats > div:first-child { padding-left: 0; border-left: none; }
.hero-stats b { display: block; font-size: 19px; font-weight: 650; letter-spacing: -.3px; line-height: 1.25; }
.hero-stats span { font-size: 11.5px; color: var(--muted); }
.hero-stats i { font-style: normal; font-size: 11.5px; margin-left: 3px; color: var(--muted); font-weight: 400; }

/* 主面板内的线路进度：双列铺开，避免纵向拉长 */
.route-block { border-top: 1px solid var(--line-2); margin-top: 16px; padding-top: 13px; }
.route-block .route-row:last-child, .route-block .route-row:nth-last-child(2) { margin-bottom: 0; }
.route-block .bh { display: flex; align-items: baseline; gap: 8px; margin-bottom: 5px; }
.route-block .bh b { font-size: 12.5px; font-weight: 600; }
.route-block .bh span { font-size: 11.5px; color: var(--muted); }
.route-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1px 24px; }
.route-row {
  display: grid; grid-template-columns: 82px 1fr 72px 40px; align-items: center;
  gap: 10px; padding: 4px 7px; border-radius: 7px; cursor: pointer; font-size: 12px;
  font-variant-numeric: tabular-nums; min-width: 0;
}
.route-row:hover { background: var(--surface-2); }
.route-row .track { position: relative; height: 5px; border-radius: 99px; background: #eff2f7; overflow: hidden; }
.route-row .track i { position: absolute; left: 0; top: 0; height: 100%; border-radius: 99px; }
.route-row .pct { text-align: right; color: var(--ink-2); font-variant-numeric: tabular-nums; white-space: nowrap; }
.route-row .left { text-align: right; color: var(--warn); font-variant-numeric: tabular-nums; white-space: nowrap; }
.route-row .left em { color: var(--success); font-style: normal; }

/* 右列：贯穿两行，内部滚动 */
.feed-panel {
  grid-column: 2; grid-row: 1 / span 2;
  display: flex; flex-direction: column; overflow: hidden; min-height: 0;
}
.feed-panel .panel-h { flex: none; padding-bottom: 10px; border-bottom: 1px solid var(--line-2); }

/* 左下：待扫清单填满剩余高度 */
.pending-panel {
  grid-column: 1; grid-row: 2;
  display: flex; flex-direction: column; overflow: hidden; min-height: 0;
}
.pending-panel .panel-h { flex: none; padding-bottom: 12px; }
.pending-panel .table-wrap { flex: 1; min-height: 0; overflow: auto; }
/* 定宽列：1440 及以下也不会横向溢出 */
.pending-panel table { table-layout: fixed; }
.pending-panel th, .pending-panel td { padding-left: 12px; padding-right: 12px; overflow: hidden; }
.pending-panel th:nth-child(1) { width: 20%; }
.pending-panel th:nth-child(2) { width: 15%; }
.pending-panel th:nth-child(3) { width: 10%; }
.pending-panel th:nth-child(4) { width: 26%; }
.pending-panel th:nth-child(5) { width: 11%; }
.pending-panel th:nth-child(6) { width: 8%; }
.pending-panel th:nth-child(7) { width: 10%; }

/* ================= 看板 · 下方 ================= */
.row-2 { display: grid; grid-template-columns: minmax(0, 1fr) 356px; gap: 16px; margin-top: 16px; align-items: stretch; }
.row-2 > .panel { display: flex; flex-direction: column; }
.row-2 > .panel > .panel-h { flex: none; }
.panel-b { flex: 1; display: flex; flex-direction: column; }
.row-2 .kv { gap: 20px 12px; }
.panel-b > *:last-child { margin-top: auto; }
.panel-b > button:last-child { align-self: flex-start; }

/* 表格 */
.table-wrap { overflow: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
thead th {
  position: sticky; top: 0; z-index: 1;
  background: var(--surface); color: var(--muted); font-weight: 500; font-size: 11.5px;
  text-align: left; padding: 9px 14px; border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
tbody td { padding: 10px 14px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
tbody td.mono { white-space: nowrap; }
tbody tr { transition: background .12s; }
tbody tr:hover { background: #fafcff; }
tbody tr:last-child td { border-bottom: none; }
td.mono, .mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12.5px; }
.muted { color: var(--muted); }
.addr { max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-2); font-size: 12.5px; }
.tb-sub { font-size: 11px; color: var(--muted); margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini-bar { width: 64px; height: 5px; border-radius: 99px; background: #eff2f7; overflow: hidden; display: inline-block; vertical-align: middle; }
.mini-bar i { display: block; height: 100%; background: var(--primary); }
.mini-bar i.done { background: var(--success); }
.row-click { cursor: pointer; }

.empty { padding: 46px 20px; text-align: center; color: var(--muted); font-size: 12.5px; line-height: 1.9; }

/* 最近扫描 */
.feed { padding: 8px 10px 12px; flex: 1; min-height: 0; overflow-y: auto; }
.feed-item { display: flex; gap: 10px; padding: 10px 10px; border-radius: 9px; }
.feed-item:hover { background: var(--surface-2); }
.feed-dot { width: 7px; height: 7px; border-radius: 99px; margin-top: 6px; flex: none; background: var(--success); }
.feed-dot.dup, .feed-dot.over { background: var(--warn); }
.feed-dot.unknown { background: var(--danger); }
.feed-main { min-width: 0; flex: 1; }
.feed-main b { font-weight: 600; font-size: 12.5px; font-family: ui-monospace, Menlo, monospace; letter-spacing: .2px; }
.feed-main p { margin: 3px 0 0; font-size: 11.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.feed-time { font-size: 11px; color: var(--muted); white-space: nowrap; text-align: right; }

/* ================= 线路标签 ================= */
.rt {
  display: inline-block; font-size: 11px; font-weight: 600; line-height: 1;
  padding: 4px 7px; border-radius: 5px; color: #fff; letter-spacing: .3px; white-space: nowrap;
}

/* ================= 过滤条 ================= */
.toolbar { display: flex; align-items: center; gap: 10px; padding: 14px 18px; flex-wrap: wrap; }
.seg { display: inline-flex; background: #f2f5fa; border-radius: 9px; padding: 3px; gap: 2px; }
.seg button { height: 27px; padding: 0 11px; border-radius: 7px; font-size: 12px; color: var(--ink-2); }
.seg button.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); font-weight: 600; }
.seg button .n { margin-left: 5px; color: var(--muted); font-variant-numeric: tabular-nums; font-weight: 400; }

/* ================= 抽屉 ================= */
.drawer-mask { position: fixed; inset: 0; background: rgba(13, 21, 38, .32); opacity: 0; pointer-events: none; transition: .2s; z-index: 40; }
.drawer-mask.on { opacity: 1; pointer-events: auto; }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; width: 560px; max-width: 94vw;
  background: var(--surface); box-shadow: -16px 0 48px rgba(16, 24, 40, .12);
  transform: translateX(100%); transition: transform .26s cubic-bezier(.3, .8, .3, 1); z-index: 41;
  display: flex; flex-direction: column;
}
.drawer.on { transform: none; }
.drawer-h { padding: 20px 24px 16px; border-bottom: 1px solid var(--line); display: flex; align-items: flex-start; gap: 12px; }
.drawer-h h3 { margin: 0 0 6px; font-size: 16.5px; font-weight: 650; letter-spacing: .2px; }
.drawer-h .sub { font-size: 12.5px; color: var(--muted); }
.drawer-b { padding: 20px 24px 30px; overflow-y: auto; }
.kv { display: grid; grid-template-columns: 78px 1fr; gap: 9px 12px; font-size: 13px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; color: var(--ink); }
.section-t { font-size: 11.5px; font-weight: 600; color: var(--muted); letter-spacing: .6px; margin: 24px 0 10px; text-transform: uppercase; }
.big-progress { display: flex; align-items: center; gap: 14px; padding: 15px 16px; background: var(--surface-2); border-radius: 11px; border: 1px solid var(--line-2); }
.big-progress .p { font-size: 24px; font-weight: 650; letter-spacing: -.5px; }

/* ================= 设置页 ================= */
.form-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 13px 14px; border: 1px solid var(--line); border-radius: 10px; margin-bottom: 10px;
}
.form-row small { display: block; font-size: 11.5px; color: var(--muted); margin-top: 3px; }
.form-row input[type="number"], .form-row input[type="text"] {
  width: 88px; height: 30px; border: 1px solid var(--line); border-radius: 7px; padding: 0 9px; font-size: 12.5px;
}

/* 提示 */
.toast {
  position: fixed; left: 50%; bottom: 38px; transform: translate(-50%, 12px);
  background: #0d1526; color: #fff; padding: 10px 16px; border-radius: 9px;
  font-size: 12.5px; opacity: 0; pointer-events: none; transition: .2s; z-index: 60;
  box-shadow: 0 10px 30px rgba(13, 21, 38, .26);
}
.toast.on { opacity: 1; transform: translate(-50%, 0); }

/* 低高度屏（1366×768 等）：压缩进度卡，给待扫清单多留几行 */
@media (max-height: 830px) and (min-width: 1181px) {
  .hero-main { padding: 14px 18px 12px; }
  .hero-num b { font-size: 34px; }
  .hero-main .bar { margin: 12px 0 8px; }
  .hero-stats { margin-top: 12px; padding-top: 11px; }
  .hero-stats b { font-size: 17px; }
  .route-block { margin-top: 12px; padding-top: 10px; }
  .route-row { padding: 3px 7px; }
}

/* 超宽屏：线路三列、指标收紧，避免进度条无限拉长 */
@media (min-width: 1900px) {
  .route-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px 28px; }
  .route-row { grid-template-columns: 80px 1fr 68px 36px; }
  .hero-stats > div { padding: 0 24px; }
  .pending-panel th:nth-child(1) { width: 17%; }
  .pending-panel th:nth-child(2) { width: 12%; }
  .pending-panel th:nth-child(3) { width: 8%; }
  .pending-panel th:nth-child(4) { width: 39%; }
  .pending-panel th:nth-child(5) { width: 9%; }
  .pending-panel th:nth-child(6) { width: 7%; }
  .pending-panel th:nth-child(7) { width: 8%; }
}

@media (max-width: 1180px) {
  .view.dash { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto 300px auto; gap: 12px; }
  .hero-main { grid-column: 1; grid-row: 1; }
  .feed-panel { grid-column: 1; grid-row: 2; }
  .pending-panel { grid-column: 1; grid-row: 3; max-height: 62vh; }
  .hero-stats { grid-template-columns: repeat(2, 1fr); gap: 14px 0; }
  .hero-stats > div:nth-child(3) { padding-left: 0; border-left: none; }
  .route-grid { grid-template-columns: minmax(0, 1fr); }
  .row-2 { grid-template-columns: 1fr; }
  .topbar .sub { display: none; }
}

/* ================= 登录 / 注册 ================= */
[hidden] { display: none !important; }

.auth-wrap { position: fixed; inset: 0; display: grid; grid-template-columns: 1.05fr .95fr; background: var(--bg); z-index: 10; }
.auth-aside {
  position: relative; overflow: hidden; padding: 54px 56px;
  justify-content: center;
  background: linear-gradient(150deg, #10357e 0%, #165dff 58%, #3b7bff 100%);
  color: #fff; display: flex; flex-direction: column;
}
.auth-aside::after {
  content: ''; position: absolute; right: -120px; bottom: -160px; width: 460px; height: 460px;
  border-radius: 50%; background: rgba(255, 255, 255, .07);
}
.auth-aside::before {
  content: ''; position: absolute; right: 60px; top: -80px; width: 240px; height: 240px;
  border-radius: 50%; background: rgba(255, 255, 255, .05);
}
.auth-brand { display: flex; align-items: center; gap: 11px; position: absolute; top: 54px; left: 56px; z-index: 1; }
.auth-brand .brand-mark { background: rgba(255, 255, 255, .18); box-shadow: none; }
.auth-brand .brand-txt b { color: #fff; font-size: 15px; }
.auth-brand .brand-txt span { color: rgba(255, 255, 255, .7); }
.auth-aside h2 { margin: 0; font-size: 27px; line-height: 1.45; font-weight: 650; letter-spacing: .2px; position: relative; z-index: 1; }
.auth-points { list-style: none; margin: 26px 0 0; padding: 0; position: relative; z-index: 1; }
.auth-points li { position: relative; padding-left: 22px; margin-bottom: 13px; font-size: 13px; color: rgba(255, 255, 255, .86); line-height: 1.7; }
.auth-points li::before {
  content: ''; position: absolute; left: 2px; top: 8px; width: 6px; height: 6px;
  border-radius: 99px; background: #7fe3b0; box-shadow: 0 0 0 4px rgba(127, 227, 176, .18);
}
.auth-foot { position: absolute; left: 56px; bottom: 40px; font-size: 12px; color: rgba(255, 255, 255, .55); z-index: 1; }

.auth-main { display: grid; place-items: center; padding: 30px; }
.auth-box { width: 100%; max-width: 350px; }
.auth-box h3 { margin: 0 0 6px; font-size: 22px; font-weight: 650; letter-spacing: .2px; }
.auth-tip { margin: 0 0 24px; font-size: 12.5px; color: var(--muted); }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 12px; color: var(--ink-2); margin-bottom: 6px; }
.field input {
  width: 100%; height: 40px; border-radius: 10px; border: 1px solid var(--line);
  background: #fff; padding: 0 12px; font-size: 13.5px; outline: none; transition: .14s;
}
.field input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(22, 93, 255, .1); }
.auth-btn {
  width: 100%; height: 42px; border-radius: 10px; margin-top: 8px;
  background: var(--primary); color: #fff; font-size: 14px; font-weight: 600;
  box-shadow: 0 8px 18px -8px rgba(22, 93, 255, .55); transition: .14s;
}
.auth-btn:hover { background: var(--primary-dark); }
.auth-btn:disabled { opacity: .65; cursor: default; }
.auth-switch { margin-top: 16px; text-align: center; font-size: 12.5px; color: var(--muted); }
.auth-switch a { color: var(--primary); font-weight: 600; }
.auth-err { margin-top: 12px; min-height: 18px; font-size: 12.5px; color: var(--danger); text-align: center; line-height: 1.6; }

@media (max-width: 900px) {
  .auth-wrap { grid-template-columns: 1fr; }
  .auth-aside { display: none; }
}

/* ================= 侧栏用户 ================= */
.side-user { border-top: 1px solid var(--line-2); padding-top: 10px; }
.su-btn {
  width: 100%; display: flex; align-items: center; gap: 9px; padding: 7px 8px;
  border-radius: 9px; text-align: left; transition: .14s;
}
.su-btn:hover { background: var(--surface-2); }
.su-avatar {
  width: 28px; height: 28px; border-radius: 9px; flex: none;
  background: linear-gradient(150deg, #2b74ff, #165dff); color: #fff;
  display: grid; place-items: center; font-size: 13px; font-weight: 600;
}
.su-txt { min-width: 0; flex: 1; line-height: 1.35; }
.su-txt b { display: block; font-size: 12.5px; font-weight: 600; }
.su-txt small { display: block; font-size: 10.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.su-btn svg { color: var(--muted); flex: none; }

/* ================= 抽屉表单 ================= */
.form-grid { display: grid; gap: 12px; }
.form-grid label { display: block; font-size: 12px; color: var(--ink-2); }
.form-grid input, .form-grid select {
  display: block; width: 100%; height: 36px; margin-top: 6px; padding: 0 10px;
  border: 1px solid var(--line); border-radius: 8px; background: #fff; font-size: 13px; outline: none;
}
.form-grid input:focus, .form-grid select:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(22, 93, 255, .09); }
.form-grid input:disabled { background: var(--surface-2); color: var(--muted); }

/* ================= 日志 / 用户表格 ================= */
.view.fill { display: flex; flex-direction: column; min-height: 0; overflow: hidden; }
.view.fill > .panel { flex: 1; min-height: 0; display: flex; flex-direction: column; overflow: hidden; }
.view.fill > .panel > .toolbar { flex: none; }
.view.fill .table-wrap { flex: 1; min-height: 0; overflow: auto; }
.view.fill .pager { flex: none; }
.pager { display: flex; align-items: center; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--line-2); font-size: 12px; }
.audit-table td { vertical-align: top; }
.audit-table tbody td { padding-top: 9px; padding-bottom: 9px; }
.seg button[disabled] { cursor: default; }
