:root {
  --bg: #070c16;
  --bg-2: #0b1322;
  --card: #0f1829;
  --card-2: #121d31;
  --line: rgba(148, 178, 235, 0.13);
  --line-strong: rgba(148, 178, 235, 0.24);
  --text: #e9eefb;
  --muted: #8b9cbb;
  --accent: #38bdf8;
  --accent-2: #22d3ee;
  --accent-3: #818cf8;
  --brand: #0a4f9e;
  --brand-2: #14a8c8;
  --good: #34d399;
  --warn: #fbbf24;
  --bad: #fb7185;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 18px 40px rgba(2, 8, 20, 0.45);
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

html, body {
  margin: 0;
  min-height: 100%;
}

body {
  color: var(--text);
  background:
    radial-gradient(1200px 700px at 8% -12%, rgba(56, 130, 246, 0.16), transparent 60%),
    radial-gradient(900px 600px at 100% 0%, rgba(34, 211, 238, 0.08), transparent 55%),
    var(--bg);
  font-family: "Segoe UI", "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", system-ui, sans-serif;
  font-size: 14px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0; font-weight: 650; letter-spacing: 0.2px; }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: #23324d; border-radius: 10px; border: 2px solid var(--bg); }
::-webkit-scrollbar-track { background: transparent; }

.muted { color: var(--muted); }
.small { font-size: 12.5px; }
.tiny { font-size: 11.5px; }
.num { text-align: right; font-variant-numeric: tabular-nums; }
.hr { border: 0; border-top: 1px solid var(--line); margin: 16px 0; }
.row-inline { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }
.local-import {
  margin-top: 14px; padding-top: 12px;
  border-top: 1px dashed var(--line);
  display: flex; flex-direction: column; gap: 6px;
}
.local-import .input { flex: 1; min-width: 240px; }

/* ---------------------------------------------------------------- 布局 */
.app { display: flex; min-height: 100vh; }

.rail {
  position: sticky;
  top: 0;
  height: 100vh;
  width: 212px;
  flex: 0 0 212px;
  padding: 20px 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  background: linear-gradient(180deg, rgba(13, 22, 38, 0.95), rgba(6, 10, 18, 0.98));
  border-right: 1px solid var(--line);
  z-index: 20;
}

.brand { display: flex; align-items: center; gap: 11px; padding: 2px 6px; }
.logo {
  width: 38px; height: 38px; flex: 0 0 38px;
  display: grid; place-items: center;
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(10, 79, 158, 0.35);
}
.logo img { width: 100%; height: 100%; object-fit: contain; display: block; }
.brand-text { display: flex; flex-direction: column; min-width: 0; }
.brand-text b { font-size: 15px; }
.brand-text small { color: var(--muted); font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 130px; }

.nav { display: flex; flex-direction: column; gap: 4px; }
.nav-item {
  display: flex; align-items: center; gap: 11px;
  padding: 10px 12px;
  border-radius: 10px;
  color: #a9bbd9;
  font-size: 13.5px;
  border: 1px solid transparent;
  transition: 0.16s ease;
}
.nav-item svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; opacity: 0.9; }
.nav-item:hover { background: rgba(56, 189, 248, 0.07); color: #dce9ff; text-decoration: none; }
.nav-item.active {
  background: linear-gradient(90deg, rgba(20, 168, 200, 0.16), rgba(10, 79, 158, 0.05));
  border-color: rgba(20, 168, 200, 0.28);
  color: #eaf7ff;
}
.nav-item.active svg { color: var(--accent); }

.rail-foot { margin-top: auto; display: flex; align-items: center; gap: 8px; padding: 0 8px; flex-wrap: wrap; }
.db-dot { color: var(--good); font-size: 10px; text-shadow: 0 0 8px rgba(52, 211, 153, 0.8); }
.db-dot.off { color: var(--bad); text-shadow: none; }
.lock-link {
  margin-left: auto; border: 0; background: none; color: #7f9bc4;
  font-size: 11.5px; cursor: pointer; padding: 2px 0;
}
.lock-link:hover { color: var(--accent); }
.slogan {
  padding: 8px 8px 2px; color: #5b7198;
  font-size: 10.5px; letter-spacing: 3px; text-align: center;
}

.main { flex: 1; min-width: 0; padding: 22px 26px 48px; }
.view { animation: fade 0.22s ease; max-width: 1760px; margin: 0 auto; }
@keyframes fade { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

/* ---------------------------------------------------------------- 通用组件 */
.page-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 18px; flex-wrap: wrap; margin-bottom: 18px;
}
.page-head h1 { font-size: 23px; letter-spacing: 0.3px; }
.page-head .sub { margin: 4px 0 0; color: var(--muted); font-size: 12.8px; }
.head-actions { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }

.card {
  background: linear-gradient(180deg, rgba(20, 31, 51, 0.92), rgba(13, 21, 36, 0.92));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 18px;
  box-shadow: var(--shadow);
  position: relative;
}
.card-title { font-size: 14.5px; margin-bottom: 14px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 36px; padding: 0 15px;
  border-radius: 9px;
  border: 1px solid var(--line-strong);
  background: rgba(148, 178, 235, 0.08);
  color: var(--text);
  cursor: pointer;
  font-size: 13px;
  transition: 0.15s ease;
  white-space: nowrap;
}
.btn:hover { background: rgba(148, 178, 235, 0.16); border-color: rgba(148, 178, 235, 0.4); text-decoration: none; }
.btn.primary {
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  border-color: transparent;
  box-shadow: 0 8px 20px rgba(10, 79, 158, 0.3);
  font-weight: 600;
}
.btn.primary:hover { filter: brightness(1.08); }
.btn.ghost { background: transparent; }
.btn.icon { width: 36px; padding: 0; font-size: 17px; color: var(--muted); }
.btn.danger { color: var(--bad); border-color: rgba(251, 113, 133, 0.35); }
.btn.small { height: 29px; padding: 0 10px; font-size: 12.2px; border-radius: 7px; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-row { display: flex; gap: 9px; flex-wrap: wrap; margin-top: 16px; }
.link { border: 0; background: none; color: var(--accent); cursor: pointer; padding: 0; font-size: 12.5px; }
.link:hover { text-decoration: underline; }

.seg {
  display: inline-flex; align-items: center; gap: 2px;
  padding: 3px;
  background: rgba(10, 18, 32, 0.85);
  border: 1px solid var(--line);
  border-radius: 10px;
  flex-wrap: wrap;
}
.seg button {
  border: 0; background: transparent; color: var(--muted);
  padding: 5px 10px; border-radius: 7px; cursor: pointer; font-size: 12.5px;
  transition: 0.15s ease;
  white-space: nowrap;
}
.seg button:hover { color: var(--text); }
.seg button.on { background: rgba(56, 189, 248, 0.16); color: #d9f4ff; box-shadow: inset 0 0 0 1px rgba(56, 189, 248, 0.25); }

.date-range { display: inline-flex; align-items: center; gap: 6px; }
.date-range .dash { color: var(--muted); }
input[type="date"], .input, select.input {
  height: 34px;
  padding: 0 10px;
  border-radius: 8px;
  border: 1px solid var(--line-strong);
  background: rgba(8, 14, 26, 0.9);
  color: var(--text);
  color-scheme: dark;
  outline: none;
}
input[type="date"]:focus, .input:focus, select.input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.12); }
select.input { padding-right: 26px; }

.chk { display: inline-flex; align-items: center; gap: 7px; color: #b9c8e2; font-size: 12.8px; cursor: pointer; user-select: none; }
.chk input { accent-color: var(--accent); width: 15px; height: 15px; }
.chk.inline { margin-top: 12px; }

.badge {
  display: inline-flex; align-items: center;
  padding: 1px 8px; border-radius: 20px;
  font-size: 11.5px; border: 1px solid var(--line-strong);
  color: var(--muted);
}
.badge.green { color: var(--good); border-color: rgba(52, 211, 153, 0.35); background: rgba(52, 211, 153, 0.08); }
.badge.gray { color: #90a2c0; }
.badge.warn { color: var(--warn); border-color: rgba(251, 191, 36, 0.35); background: rgba(251, 191, 36, 0.08); }

/* ---------------------------------------------------------------- 大屏 */
.dash-head { align-items: flex-start; margin-bottom: 16px; }
.dash-head h1 { font-size: 25px; }
.head-actions { justify-content: flex-end; }

.kpi-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 13px;
  margin-bottom: 14px;
}
#pickerSummary { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.kpi {
  background: linear-gradient(160deg, rgba(24, 38, 61, 0.9), rgba(12, 20, 34, 0.92));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 16px 12px;
  position: relative;
  overflow: hidden;
}
.kpi::after {
  content: ""; position: absolute; right: -30px; top: -40px;
  width: 120px; height: 120px; border-radius: 50%;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.16), transparent 65%);
}
.kpi .k-label { color: var(--muted); font-size: 12.3px; display: flex; align-items: center; gap: 6px; }
.kpi .k-value {
  font-size: 30px; font-weight: 700; line-height: 1.25; margin-top: 4px;
  font-variant-numeric: tabular-nums; letter-spacing: 0.5px;
}
.kpi .k-value small { font-size: 13px; font-weight: 500; color: var(--muted); margin-left: 4px; }
.kpi .k-foot { font-size: 11.8px; color: var(--muted); margin-top: 3px; display: flex; align-items: center; gap: 6px; }
.delta { font-variant-numeric: tabular-nums; font-weight: 600; }
.delta.up { color: var(--good); }
.delta.down { color: var(--bad); }
.delta.flat { color: var(--muted); }

.grid-dash {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 13px;
}
.span2 { grid-column: span 2; }
.chart-card { padding: 14px 16px 10px; display: flex; flex-direction: column; min-width: 0; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; min-height: 26px; }
.card-head h3 { font-size: 14px; font-weight: 600; }
.card-head .hint { color: var(--muted); font-size: 11.5px; }
.chart-wrap { position: relative; height: clamp(230px, 27vh, 310px); width: 100%; }
.chart-wrap canvas { width: 100%; height: 100%; display: block; }

.chart-tip {
  position: absolute; pointer-events: none; z-index: 8;
  background: rgba(9, 16, 29, 0.96);
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  padding: 8px 10px;
  font-size: 12px;
  min-width: 120px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.45);
  opacity: 0; transition: opacity 0.1s;
}
.chart-tip.show { opacity: 1; }
.chart-tip .tip-title { color: var(--muted); margin-bottom: 5px; font-size: 11.5px; }
.chart-tip .tip-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.chart-tip .tip-row b { font-variant-numeric: tabular-nums; font-weight: 600; }
.tip-dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; margin-right: 6px; }

.rank-list { display: flex; flex-direction: column; gap: 3px; overflow-y: auto; max-height: 246px; padding-right: 4px; }
.rank-item {
  display: grid;
  grid-template-columns: 24px minmax(52px, 84px) 1fr 62px;
  align-items: center;
  gap: 8px;
  padding: 5px 6px;
  border-radius: 8px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: 0.15s;
}
.rank-item:hover { background: rgba(56, 189, 248, 0.07); border-color: rgba(56, 189, 248, 0.16); }
.rank-item.active { background: rgba(56, 189, 248, 0.12); border-color: rgba(56, 189, 248, 0.3); }
.rank-idx { font-size: 11.5px; color: var(--muted); text-align: center; font-variant-numeric: tabular-nums; }
.rank-idx.top { color: #ffd166; font-weight: 700; }
.rank-name { font-size: 12.8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rank-bar { height: 7px; border-radius: 6px; background: rgba(148, 178, 235, 0.1); overflow: hidden; }
.rank-fill { height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--brand), var(--brand-2)); transition: width 0.5s ease; }
.rank-val { text-align: right; font-size: 12.5px; font-variant-numeric: tabular-nums; }
.rank-val small { display: block; font-size: 10.5px; color: var(--muted); }
.rank-empty { color: var(--muted); text-align: center; padding: 40px 0; font-size: 12.5px; }

.chips { display: flex; gap: 5px; flex-wrap: wrap; justify-content: flex-end; max-width: 70%; }
.chip {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 2px 9px; border-radius: 20px;
  border: 1px solid var(--line);
  background: rgba(10, 18, 32, 0.7);
  font-size: 11.5px; color: #b9c8e2; cursor: pointer;
  transition: 0.15s;
}
.chip .dot { width: 6px; height: 6px; border-radius: 50%; }
.chip.off { opacity: 0.38; }
.chip:hover { border-color: var(--line-strong); }

.dash-foot { margin-top: 12px; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

.alert {
  display: flex; align-items: center; gap: 9px;
  padding: 9px 13px;
  border-radius: 10px;
  font-size: 12.5px;
  border: 1px solid rgba(251, 191, 36, 0.28);
  background: rgba(251, 191, 36, 0.07);
  color: #f6d78a;
}
.alert a { color: #fde68a; text-decoration: underline; }
.alert.bad { border-color: rgba(251, 113, 133, 0.3); background: rgba(251, 113, 133, 0.08); color: #ffc2cc; }

.empty-overlay {
  position: fixed; inset: 0 0 0 212px;
  background: rgba(5, 9, 17, 0.72);
  backdrop-filter: blur(3px);
  display: grid; place-items: center;
  z-index: 30;
}
.empty-box {
  text-align: center; padding: 36px 44px;
  border-radius: 18px;
  border: 1px solid var(--line-strong);
  background: #0d1626;
  box-shadow: var(--shadow);
  max-width: 420px;
}
.empty-icon { font-size: 40px; }
.empty-box h2 { margin: 10px 0 6px; font-size: 20px; }
.empty-box p { color: var(--muted); margin: 0 0 18px; }

/* ---------------------------------------------------------------- 导入 */
.import-top { display: grid; grid-template-columns: 1.35fr 1fr; gap: 13px; margin-bottom: 13px; }
.tabs { display: flex; gap: 4px; margin-bottom: 12px; background: rgba(8, 14, 26, 0.7); padding: 4px; border-radius: 11px; border: 1px solid var(--line); }
.tab {
  flex: 1; border: 0; background: transparent; color: var(--muted);
  padding: 8px 10px; border-radius: 8px; cursor: pointer; font-size: 13px;
}
.tab.on { background: rgba(56, 189, 248, 0.14); color: #dff6ff; box-shadow: inset 0 0 0 1px rgba(56, 189, 248, 0.25); }
.hint-box { color: var(--muted); font-size: 12.3px; margin: 0 0 12px; }

.dropzone {
  border: 1.5px dashed rgba(148, 178, 235, 0.3);
  border-radius: 13px;
  padding: 26px 18px;
  text-align: center;
  cursor: pointer;
  background: rgba(9, 16, 29, 0.55);
  transition: 0.18s;
}
.dropzone:hover, .dropzone.drag { border-color: var(--accent); background: rgba(56, 189, 248, 0.06); }
.dropzone .dz-icon { font-size: 30px; color: var(--accent); line-height: 1; margin-bottom: 8px; }
.dropzone .dz-main { font-size: 14px; }
.dropzone .dz-main b { color: var(--accent); }

.tips h3 { font-size: 14px; margin-bottom: 10px; }
.tips ol { margin: 0; padding-left: 20px; color: #a9bbd9; font-size: 12.4px; line-height: 1.9; }
.tips b { color: #dce9ff; }

.stage-card { margin-bottom: 13px; }
.field-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 11px; }
.field { display: flex; flex-direction: column; gap: 4px; }
.field label { font-size: 12px; color: var(--muted); }
.field label .req { color: var(--bad); margin-left: 2px; }
.field label .opt { color: #66789a; font-size: 10.5px; margin-left: 5px; }
.field select { width: 100%; }
.option-row { display: flex; gap: 18px; flex-wrap: wrap; align-items: center; margin-top: 14px; padding-top: 13px; border-top: 1px solid var(--line); }
.option-row > label { font-size: 12.3px; color: var(--muted); display: inline-flex; align-items: center; gap: 7px; }

.stat-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); gap: 9px; margin: 4px 0 12px; }
.stat {
  background: rgba(8, 14, 26, 0.65);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 9px 11px;
}
.stat span { display: block; color: var(--muted); font-size: 11.5px; }
.stat b { font-size: 19px; font-variant-numeric: tabular-nums; }
.stat b.warn { color: var(--warn); }
.stat b.bad { color: var(--bad); }

.warn-list { margin: 8px 0; padding-left: 18px; color: #e7cf9a; font-size: 12.4px; }
.warn-list li { margin: 3px 0; }
details.err-box { margin-top: 8px; color: var(--muted); font-size: 12px; }
details.err-box summary { cursor: pointer; }
details.err-box ul { max-height: 160px; overflow: auto; color: #f0b6b6; }

/* ---------------------------------------------------------------- 表格 */
.table-toolbar { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
.table-toolbar .input { width: 220px; }
.table-scroll { overflow: auto; border: 1px solid var(--line); border-radius: 11px; }
.table { width: 100%; border-collapse: collapse; font-size: 13px; }
.table th, .table td { padding: 9px 12px; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; }
.table th {
  background: rgba(9, 16, 29, 0.9);
  color: var(--muted);
  font-weight: 600;
  font-size: 11.8px;
  position: sticky; top: 0; z-index: 2;
}
.table tbody tr:hover { background: rgba(56, 189, 248, 0.05); }
.table tbody tr:last-child td { border-bottom: 0; }
.table td.num, .table th.num { text-align: right; }
.table td.ops, .table th.ops { text-align: right; }
.table.small th, .table.small td { padding: 7px 9px; font-size: 12.2px; }
.table .row-ops { display: inline-flex; gap: 4px; }
.empty-tip { color: var(--muted); font-size: 12.5px; padding: 26px 8px; text-align: center; }
.table .name-cell { color: #eaf2ff; font-weight: 600; }
.table .muted-cell { color: var(--muted); }
.table .clickable { cursor: pointer; }

/* ---------------------------------------------------------------- 导出 */
.export-grid { display: grid; grid-template-columns: 400px 1fr; gap: 13px; align-items: start; }
.form-row { display: grid; grid-template-columns: 78px 1fr; align-items: center; gap: 10px; margin-bottom: 12px; }
.form-row > label { color: var(--muted); font-size: 12.5px; }
.form-row .seg { width: 100%; }
.form-row .seg button { flex: 1; text-align: center; }
.people-picker { border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.people-tools { display: flex; align-items: center; gap: 12px; padding: 7px 10px; background: rgba(8, 14, 26, 0.7); border-bottom: 1px solid var(--line); }
.people-list { max-height: 210px; overflow: auto; padding: 6px; display: grid; grid-template-columns: 1fr 1fr; gap: 2px; }
.person-check {
  display: flex; align-items: center; gap: 7px; padding: 5px 7px; border-radius: 7px;
  font-size: 12.5px; cursor: pointer; color: #c4d3ea;
}
.person-check:hover { background: rgba(56, 189, 248, 0.07); }
.person-check input { accent-color: var(--accent); }
.person-check .inactive { color: var(--muted); font-size: 11px; }
.preview-scroll { max-height: calc(100vh - 260px); min-height: 320px; }
.preview-scroll .table td { white-space: nowrap; }

/* ---------------------------------------------------------------- 设置 */
.settings-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; align-items: start; }
.info-list { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.info-row { display: flex; justify-content: space-between; border-bottom: 1px dashed var(--line); padding-bottom: 5px; font-size: 12.7px; }
.info-row span { color: var(--muted); }

/* ---------------------------------------------------------------- 批量导入 */
.batch-card { margin-top: 13px; }
.batch-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.batch-grid .field { gap: 6px; }
.batch-grid input[type="file"] { height: auto; padding: 7px 9px; font-size: 12px; }
.batch-grid textarea { resize: vertical; min-height: 72px; padding: 8px 10px; }
.batch-card .option-row { margin-top: 10px; }
.batch-result { margin-top: 12px; font-size: 12.5px; }
#batchResult .ok { color: var(--good); }
#batchResult .err { color: var(--bad); }

/* ---------------------------------------------------------------- 管理密码 */
.lock-screen {
  position: fixed; inset: 0; z-index: 95;
  display: grid; place-items: center; padding: 20px;
  background:
    radial-gradient(900px 600px at 15% 0%, rgba(20, 168, 200, 0.16), transparent 60%),
    radial-gradient(700px 500px at 90% 100%, rgba(10, 79, 158, 0.22), transparent 60%),
    rgba(4, 8, 16, 0.94);
  backdrop-filter: blur(6px);
}
.lock-card {
  width: min(420px, 100%);
  background: linear-gradient(180deg, #0e1a2d, #0a1220);
  border: 1px solid var(--line-strong);
  border-radius: 20px;
  padding: 34px 32px 26px;
  text-align: center;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
}
.lock-logo {
  width: 96px; height: 96px; object-fit: contain;
  background: #fff; border-radius: 18px; padding: 6px;
  margin-bottom: 14px;
}
.lock-card h2 { font-size: 20px; letter-spacing: 0.5px; }
.lock-sub { color: var(--muted); font-size: 12.5px; margin: 6px 0 18px; line-height: 1.8; }
#lockForm { display: flex; flex-direction: column; gap: 10px; }
#lockForm .input { height: 42px; text-align: center; letter-spacing: 2px; }
#lockForm .btn { height: 42px; }
.lock-error { min-height: 18px; color: var(--bad); font-size: 12.5px; margin-top: 8px; }
.lock-foot { color: #5b7198; font-size: 11px; letter-spacing: 4px; margin: 16px 0 0; }

/* ---------------------------------------------------------------- 提示 / 弹窗 */
.toast {
  position: fixed; left: 50%; bottom: 26px; transform: translate(-50%, 14px);
  background: #12213a; border: 1px solid var(--line-strong);
  padding: 10px 18px; border-radius: 10px; font-size: 13px;
  opacity: 0; pointer-events: none; transition: 0.22s; z-index: 100;
  box-shadow: var(--shadow); max-width: 90vw;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.err { border-color: rgba(251, 113, 133, 0.5); color: #ffd3da; }
.toast.ok { border-color: rgba(52, 211, 153, 0.45); }

.modal-backdrop {
  position: fixed; inset: 0; background: rgba(4, 8, 15, 0.7);
  display: grid; place-items: center; z-index: 90; padding: 20px;
}
.modal {
  width: 100%; max-width: 440px;
  background: #0e1727; border: 1px solid var(--line-strong);
  border-radius: 15px; box-shadow: var(--shadow);
  padding: 20px;
}
.modal h3 { font-size: 16px; margin-bottom: 14px; }
.modal .form-row { grid-template-columns: 82px 1fr; }
.modal-foot { display: flex; justify-content: flex-end; gap: 9px; margin-top: 18px; }
.modal p { color: var(--muted); font-size: 13px; }

/* ---------------------------------------------------------------- 响应式 */
@media (max-width: 1360px) {
  .export-grid { grid-template-columns: 1fr; }
}
@media (max-width: 1200px) {
  .kpi-row { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 1180px) {
  .grid-dash { grid-template-columns: 1fr 1fr; }
  .span2 { grid-column: span 2; }
  .import-top { grid-template-columns: 1fr; }
  .settings-grid { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .rail { width: 64px; flex-basis: 64px; padding: 16px 8px; }
  .brand { justify-content: center; padding: 0; }
  .brand-text, .rail-foot span, .nav-item span { display: none; }
  .nav-item { justify-content: center; padding: 11px 0; }
  .empty-overlay { inset: 0 0 0 64px; }
  .main { padding: 16px; }
  .kpi-row { grid-template-columns: 1fr 1fr; }
  .grid-dash { grid-template-columns: 1fr; }
  .span2 { grid-column: span 1; }
  .chart-wrap { height: 250px; }
  .chips { max-width: 100%; justify-content: flex-start; }
  .head-actions { justify-content: flex-start; }
  .people-list { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; gap: 6px; }
}
