/* ============================================================
   一线服务台 · 港区值班台（Harbor Console）
   工业仪表盘气质：混凝土中性 + 墨色 + 单信号色（深青）
   字体全部取自系统，无外链、无第三方依赖
   ============================================================ */

:root {
  /* 中性：冷灰阶（现代 SaaS） */
  --bg: #f3f5fa;
  --panel: #ffffff;
  --panel-2: #f8f9fd;
  --panel-3: #f1f3f9;
  --line: #e7eaf2;
  --line-strong: #d4dae6;
  --text: #0b1220;
  --text-2: #33405a;
  --muted: #4a5670;   /* 标签：对比度 ≥7:1，小字清晰 */
  --faint: #586580;   /* 辅助：对比度 ≥5.5:1，过 AA */
  --ink: #0b1220;

  /* 强调色：单一深青（与大屏同一支信号色，2026-11 统一，替换原靛蓝） */
  --brand: #0b6e64;
  --brand-2: #12968a;
  --brand-deep: #08544c;
  --brand-weak: #e8f5f3;
  --brand-line: rgba(11, 110, 100, .16);
  --glow: rgba(11, 110, 100, .18);

  /* 语义色：只承担状态含义 */
  --red: #d92d20;
  --red-weak: #fef3f2;
  --amber: #b54708;
  --amber-weak: #fffaeb;
  --ok: #475467;          /* 已完成/已恢复：中性，靠 ✓ 与安静退底表达 */
  --ok-weak: #f1f4f9;
  --ok-line: #d4dae6;
  --purple: #6941c6;
  --purple-weak: #f4f3ff;
  /* 语义浅底配色的描边档（原散落在页面内联 style 里） */
  --amber-line: #fde3b5;

  /* 侧栏：深墨控制台（与登录页品牌区同一套色） */
  --navy: #0b1220;
  --side-bg-1: #0c1424;
  --side-bg-2: #090f1b;
  --side-line: rgba(255, 255, 255, .075);
  --side-text: rgba(203, 213, 225, .76);
  --side-text-2: rgba(148, 163, 184, .62);
  --side-hover: rgba(255, 255, 255, .055);
  --side-active: rgba(18, 150, 138, .20);

  --sidebar-w: 240px;
  --radius: 14px;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --shadow: 0 1px 2px rgba(11, 18, 32, .04), 0 12px 28px -22px rgba(11, 18, 32, .36);
  --shadow-lift: 0 2px 4px rgba(11, 18, 32, .04), 0 18px 40px -22px rgba(11, 18, 32, .28);

  /* 字体：几何无衬线（系统栈），数字同族使用等宽数字 */
  --font-sans: "Segoe UI", -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei UI", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  --font-display: var(--font-sans);
  --mono: "JetBrains Mono", "Cascadia Mono", Consolas, "SFMono-Regular", "Liberation Mono", monospace;

  /* 字号阶梯（全站唯一基准，共 9 档正文 + 3 档大屏数字；2026-11-25 可读性上调一档：中文正文 15px 起，辅助 12.5px 起） */
  --fs-micro: 12px;   /* eyebrow / 表头 / 侧栏 micro */
  --fs-caption: 12.5px;   /* caption / meta / foot / 副标题 */
  --fs-label: 13.5px;     /* 表单标签 / 控件 / 表格次级单元 / 卡片正文 */
  --fs-body: 15px;    /* 正文基线 / 正文标题（加粗） */
  --fs-h4: 16px;        /* 弹窗 / 抽屉标题 */
  --fs-h3: 19px;        /* 详情 / 区块二级标题 */
  --fs-h2: 26px;        /* 页面主标题 */
  --fs-hero: 32px;      /* 工作台主标题 / KPI 读数 */
  --fs-hero-lg: 38px;   /* 大屏百分比 */
  --fs-hero-xl: 44px;   /* 大屏最大百分比 */

  /* 图表：青碧单色阶 → 灰蓝 → 中性灰 */
  --chart-1: #0b6e64;
  --chart-2: #12968a;
  --chart-3: #2fb3a4;
  --chart-4: #79e4d6;
  --chart-5: #94a3b8;
  --chart-6: #cbd5e1;
  --chart-track: #eef1f5;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.62;
  font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font-family: inherit; font-size: inherit; color: inherit; }
button { cursor: pointer; }
::placeholder { color: var(--muted); opacity: 1; }
h1, h2, h3, h4 { font-family: var(--font-sans); }

.app { min-height: 100vh; }

/* ---------- 侧边栏（深墨控制台） ---------- */
.sidebar {
  position: fixed; inset: 0 auto 0 0; width: var(--sidebar-w);
  background:
    radial-gradient(560px 340px at 10% -10%, rgba(18, 150, 138, .26), transparent 62%),
    linear-gradient(180deg, var(--side-bg-1) 0%, var(--side-bg-2) 100%);
  color: var(--side-text);
  display: flex; flex-direction: column; z-index: 40;
  border-right: 1px solid rgba(15, 23, 42, .7); overflow: hidden;
}
/* 极淡网格：只在左上角透出，呼应登录页品牌区 */
.sidebar::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .55;
  background-image:
    linear-gradient(rgba(255, 255, 255, .05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .05) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(130% 68% at 0% 0%, #000, transparent 76%);
  mask-image: radial-gradient(130% 68% at 0% 0%, #000, transparent 76%);
}
.brand { position: relative; display: flex; gap: 11px; align-items: center; padding: 22px 18px 16px; }
.logo {
  width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center;
  background: linear-gradient(145deg, #5ecfc0 0%, #0b6e64 52%, #08544c 100%);
  color: #fff; flex: none;
  box-shadow: 0 10px 22px -10px rgba(11, 110, 100, .95), inset 0 1px 0 rgba(255, 255, 255, .32);
}
.brand-name { font-size: var(--fs-h4); font-weight: 650; color: #fff; letter-spacing: -.01em; }
.brand-sub { font-size: var(--fs-micro); color: var(--side-text-2); margin-top: 3px; letter-spacing: .04em; }

.nav { padding: 0 10px 10px; flex: 1; overflow-y: auto; min-height: 0; position: relative; }
/* 全局细滚动条：仅在内容溢出时出现，悬停加深 */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #cfd5de; border: 2px solid transparent; border-radius: 8px; background-clip: content-box; }
::-webkit-scrollbar-thumb:hover { background: #b3bbc7; background-clip: content-box; }
::-webkit-scrollbar-corner { background: transparent; }
/* 侧栏：深色底上的细滚动条 */
.nav::-webkit-scrollbar { width: 6px; }
.nav::-webkit-scrollbar-track { background: transparent; }
.nav::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .14); border: 0; border-radius: 999px; }
.nav:hover::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .22); }
.nav::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, .32); }
.nav::-webkit-scrollbar-button { display: none; height: 0; }

/* 分组标题：小一号、加宽字距，右侧接一条极淡指引线，分组边界靠"线"而不是额外留白 */
.nav-group {
  display: flex; align-items: center; gap: 9px;
  font-size: var(--fs-micro); color: rgba(148, 163, 184, .58); letter-spacing: .16em;
  padding: 12px 11px 5px; line-height: 1.2; font-weight: 600;
}
.nav-group.is-first { padding-top: 6px; }
.nav-group::after {
  content: ""; flex: 1; height: 1px;
  background: linear-gradient(90deg, rgba(255, 255, 255, .1), rgba(255, 255, 255, 0));
}
.nav-item {
  display: flex; align-items: center; gap: 10px; height: 32px; padding: 0 11px; margin-bottom: 0;
  border-radius: 9px; color: var(--side-text); font-size: var(--fs-label); position: relative;
  transition: background-color .16s var(--ease), color .16s var(--ease), box-shadow .16s var(--ease);
}
.nav-item:hover { background: var(--side-hover); color: #fff; }
.nav-item[hidden] { display: none !important; }
.nav-item.active {
  background: linear-gradient(90deg, rgba(18, 150, 138, .26), rgba(18, 150, 138, .05));
  color: #fff; font-weight: 600;
  box-shadow: inset 0 0 0 1px rgba(111, 217, 203, .22);
}
/* 选中态左侧冷光条：全站唯一的"活信号" */
.nav-item.active::before {
  content: ""; display: block; position: absolute; left: -1px; top: 9px; bottom: 9px; width: 3px;
  border-radius: 0 3px 3px 0; background: #79e4d6;
  box-shadow: 0 0 12px rgba(111, 217, 203, .9);
}
/* 导航图标：桌面常显，窄屏折叠为图标轨道 */
.ni { display: grid; place-items: center; width: 18px; height: 18px; color: rgba(148, 163, 184, .82); flex: none; }
.ni svg { width: 18px; height: 18px; display: block; }
.nav-item:hover .ni { color: rgba(226, 232, 240, .95); }
.nav-item.active .ni { color: #a9d9cf; }
/* 侧栏导航不显示数量角标；具体数量保留在各业务页面内 */
.nav-item em { display: none; }

/* 底部固定栏：系统设置独立成栏，与上方的业务导航分开 */
.nav-tail {
  position: relative; flex: none; padding: 8px 10px 10px;
  border-top: 1px solid var(--side-line);
  background: linear-gradient(180deg, rgba(255, 255, 255, .03), rgba(255, 255, 255, 0));
}
/* 只压住底部一行，说明还能继续滚；内容装得下时它落在空白处，不遮条目 */
.nav-tail::before {
  content: ""; position: absolute; left: 0; right: 0; top: -16px; height: 16px; pointer-events: none;
  background: linear-gradient(180deg, rgba(9, 15, 27, 0), rgba(9, 15, 27, .88));
}
.nav-tail .nav-item { margin-bottom: 0; }

/* ---------- 主区域 ---------- */
.main {
  margin-left: var(--sidebar-w); min-height: 100vh; position: relative;
  background:
    radial-gradient(1100px 420px at 54% -200px, rgba(18, 150, 138, .085), transparent 72%),
    radial-gradient(circle at 1px 1px, rgba(11, 110, 100, .05) 1px, transparent 0) 0 0 / 26px 26px,
    var(--bg);
}
.topbar {
  position: sticky; top: 0; z-index: 30; height: 64px; display: flex; align-items: center;
  gap: 14px; padding: 0 max(30px, calc((100% - 1600px) / 2));
  background: rgba(255, 255, 255, .78);
  backdrop-filter: saturate(180%) blur(18px);
  -webkit-backdrop-filter: saturate(180%) blur(18px);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 1px 0 rgba(11, 18, 32, .03);
}
.topbar::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(11, 110, 100, .42) 18%, rgba(18, 150, 138, .22) 42%, transparent 100%);
  background-size: 55% 100%; background-repeat: no-repeat;
  animation: topbar-scan 11s linear infinite;
  pointer-events: none;
}
/* 顶栏底部一条缓慢扫过的微光，提示控制台处于在线状态 */
@keyframes topbar-scan {
  0% { background-position: -60% 0; }
  100% { background-position: 170% 0; }
}
.search-wrap { position: relative; flex: 1; max-width: 520px; display: flex; align-items: center; }
.search-wrap > svg { position: absolute; left: 12px; color: var(--faint); pointer-events: none; }
.search-wrap input {
  width: 100%; height: 36px; border: 1px solid transparent; border-radius: 10px;
  padding: 0 12px 0 34px; background: #f1f4f9; outline: none; color: var(--text-2);
  font-size: var(--fs-label); transition: background-color .16s var(--ease), border-color .16s var(--ease), box-shadow .16s var(--ease);
}
.search-wrap input::placeholder { color: #7b879b; }
.search-wrap input:hover { background: #eaedf4; }
.search-wrap input:focus { border-color: var(--brand-line); background: #fff; box-shadow: 0 0 0 3px rgba(11, 110, 100, .11); }
.search-panel {
  position: absolute; top: 42px; left: 0; right: 0; background: #fff; border: 1px solid var(--line);
  border-radius: 10px; box-shadow: 0 16px 40px rgba(16, 24, 40, .12); padding: 6px; display: none; max-height: 460px; overflow: auto;
}
.search-panel.show { display: block; }
.sp-group { font-size: var(--fs-caption); color: var(--faint); padding: 8px 8px 4px; letter-spacing: .06em; }
.sp-item { padding: 9px 10px; border-radius: 7px; display: flex; gap: 8px; align-items: center; cursor: pointer; }
.sp-item:hover { background: var(--panel-3); }
.sp-item .sp-title { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sp-item .sp-code { font-family: var(--mono); font-size: var(--fs-caption); color: var(--muted); }
.sp-empty { padding: 18px; text-align: center; color: var(--muted); }

.top-actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.user-box {
  display: flex; align-items: center; gap: 8px; padding-left: 12px; border-left: 1px solid var(--line);
  position: relative; cursor: pointer; user-select: none;
}
.user-meta { line-height: 1.3; }
.avatar {
  width: 30px; height: 30px; border-radius: 50%;
  background: linear-gradient(145deg, #5ecfc0, #0b6e64); color: #fff;
  display: grid; place-items: center; font-weight: 650; font-size: var(--fs-caption); flex: none;
  box-shadow: 0 4px 10px -5px rgba(11, 110, 100, .8), inset 0 1px 0 rgba(255, 255, 255, .3);
}
.user-name { font-size: var(--fs-label); font-weight: 600; color: var(--text); max-width: 132px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-role { font-size: var(--fs-caption); color: var(--muted); }
.user-caret { font-size: var(--fs-caption); color: var(--faint); margin-left: 2px; }
.user-menu {
  position: absolute; right: 0; top: 44px; min-width: 148px; background: #fff; border: 1px solid var(--line);
  border-radius: 10px; box-shadow: 0 16px 40px rgba(16, 24, 40, .12); padding: 5px; z-index: 50;
}
.user-menu-item {
  display: block; width: 100%; text-align: left; border: 0; background: none; padding: 8px 10px;
  border-radius: 7px; font-size: var(--fs-label); color: var(--text-2);
}
.user-menu-item:hover { background: var(--panel-3); }
.user-menu-item.danger { color: var(--red); }
.user-menu-item.danger:hover { background: var(--red-weak); color: #b42318; }

/* ---------- 登录页 ---------- */
.login-screen {
  min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.04fr) minmax(400px, .96fr);
  background: #f7f8fc; position: relative; overflow: hidden;
}
/* 细网格 + 两团冷光，只做背景，不承载信息 */
.login-screen::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .55;
  background-image:
    linear-gradient(rgba(13, 21, 38, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(13, 21, 38, .035) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: radial-gradient(96% 82% at 52% 0%, #000 0%, transparent 72%);
  mask-image: radial-gradient(96% 82% at 52% 0%, #000 0%, transparent 72%);
}
.login-screen::after {
  content: ""; position: absolute; inset: -15%; pointer-events: none;
  background:
    radial-gradient(640px 420px at 82% 16%, rgba(18, 150, 138, .10), transparent 66%),
    radial-gradient(560px 420px at 46% 96%, rgba(11, 110, 100, .06), transparent 62%);
}
.login-stage {
  position: relative; z-index: 1; display: flex; flex-direction: column;
  padding: 44px 56px 36px; color: #fff; overflow: hidden;
  background:
    radial-gradient(760px 460px at 6% -6%, rgba(18, 150, 138, .30), transparent 62%),
    radial-gradient(600px 460px at 96% 106%, rgba(8, 84, 76, .34), transparent 62%),
    linear-gradient(158deg, #131b2f 0%, #0d1526 56%, #0a111e 100%);
}
.login-stage::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, .06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .06) 1px, transparent 1px);
  background-size: 52px 52px;
  -webkit-mask-image: radial-gradient(88% 78% at 28% 26%, #000, transparent 78%);
  mask-image: radial-gradient(88% 78% at 28% 26%, #000, transparent 78%);
}
.login-stage > * { position: relative; z-index: 1; }
.ls-brand { display: flex; align-items: center; gap: 12px; }
.ls-brand .login-logo {
  width: 40px; height: 40px; border-radius: 11px;
  box-shadow: 0 8px 22px -6px rgba(18, 150, 138, .7), inset 0 1px 0 rgba(255, 255, 255, .3);
}
.ls-name { font-size: 16px; font-weight: 650; letter-spacing: -.01em; color: #fff; }
.ls-sub { font-size: 12.5px; color: rgba(203, 213, 225, .62); margin-top: 2px; letter-spacing: .04em; }
.ls-body { margin: auto 0; padding: 44px 0; max-width: 460px; }
.ls-eyebrow {
  font-family: var(--mono); font-size: 12.5px; font-weight: 600;
  letter-spacing: .2em; color: rgba(121, 228, 214, .85);
}
.ls-title {
  margin: 14px 0 0; font-size: clamp(30px, 3.1vw, 42px); font-weight: 650;
  line-height: 1.2; letter-spacing: -.03em; color: #fff;
}
.ls-desc { margin: 16px 0 0; font-size: 15px; line-height: 1.75; color: rgba(203, 213, 225, .72); max-width: 42ch; }
.ls-mods { list-style: none; margin: 34px 0 0; padding: 0; border-top: 1px solid rgba(255, 255, 255, .10); }
.ls-mods li {
  display: flex; align-items: baseline; gap: 10px; padding: 12px 0;
  border-bottom: 1px solid rgba(255, 255, 255, .07); font-size: 13.5px; color: rgba(226, 232, 240, .94);
}
.ls-mods li i {
  width: 5px; height: 5px; border-radius: 50%; background: #5ecfc0; flex: none;
  box-shadow: 0 0 0 3px rgba(111, 217, 203, .16);
  transform: translateY(-2px);
}
.ls-mods li span { margin-left: auto; font-size: 12.5px; color: rgba(148, 163, 184, .66); text-align: right; }
.ls-foot {
  display: flex; align-items: center; gap: 8px; font-size: 12.5px;
  color: rgba(148, 163, 184, .7); letter-spacing: .02em;
}
.ls-live {
  width: 6px; height: 6px; border-radius: 50%; background: var(--brand-2);
  box-shadow: 0 0 0 3px rgba(18, 150, 138, .16);
}
.login-panel { position: relative; z-index: 1; display: grid; place-items: center; padding: 40px 32px; }
.login-card {
  width: 100%; max-width: 400px; background: var(--panel); border: 1px solid var(--line); border-radius: 18px;
  padding: 34px 32px 26px; position: relative; overflow: hidden;
  box-shadow: 0 28px 64px -32px rgba(13, 21, 38, .34), 0 2px 10px -4px rgba(13, 21, 38, .06);
}
.login-card::before {
  content: ""; display: block; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, #12968a 0%, #0b6e64 46%, rgba(11, 110, 100, 0) 100%);
}
/* 后端未启动时的降级页直接放卡片，仍居中 */
.login-screen > .login-card { grid-column: 1 / -1; grid-row: 1; place-self: center; }
.login-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 26px; }
.login-logo { width: 40px; height: 40px; }
.login-name { font-size: 19px; font-weight: 650; letter-spacing: -.02em; }
.login-sub { font-size: 12.5px; color: var(--faint); margin-top: 3px; letter-spacing: .04em; }
.login-field { margin-bottom: 16px; }
.login-field label { display: block; font-size: 13.5px; font-weight: 600; color: var(--text-2); margin-bottom: 6px; letter-spacing: .01em; }
.login-field input {
  width: 100%; height: 44px; border: 1px solid var(--line-strong); border-radius: 10px;
  padding: 0 12px; background: #fbfcfe; outline: none; font-size: 15px;
  transition: border-color .16s var(--ease), box-shadow .16s var(--ease), background-color .16s var(--ease);
}
.login-field input:hover { border-color: #c3cad8; }
.login-field input:focus { border-color: var(--brand); background: #fff; outline: 2px solid var(--brand); outline-offset: 1px; }
.login-msg {
  display: none; margin: 4px 0 12px; padding: 9px 11px; border-radius: 8px;
  background: var(--red-weak); color: var(--red); font-size: 13.5px;
}
.login-msg.show { display: block; }
.login-submit {
  width: 100%; height: 46px; justify-content: center; margin-top: 8px; font-weight: 600;
  border-radius: 10px; font-size: 15px; letter-spacing: .06em;
}
.login-foot { margin-top: 18px; font-size: 12.5px; color: var(--faint); line-height: 1.6; text-align: center; }
@media (max-width: 1023px) {
  .login-screen { grid-template-columns: minmax(0, 1fr); }
  .login-stage { display: none; }
  .login-panel { min-height: 100vh; padding: 32px 20px; }
}
@media (max-width: 600px) {
  .login-card { padding: 28px 22px 22px; border-radius: 16px; }
  .login-panel { padding: 20px 14px; }
}

.view { padding: 30px 34px 56px; max-width: 1600px; margin: 0 auto; }

/* ---------- 通用 ---------- */
.page-head {
  display: flex; align-items: flex-end; gap: 18px; margin-bottom: 22px;
  padding-bottom: 18px; border-bottom: 1px solid var(--line);
}
.page-title {
  font-size: var(--fs-h2); font-weight: 680; letter-spacing: -.03em; margin: 0;
  padding-left: 0; border-left: 0; line-height: 1.2;
}
/* 工作台主标题：渐变字 + 底部光带，控制台主视觉（仅首页使用） */
.dash-title {
  font-size: var(--fs-hero); font-weight: 720; letter-spacing: -.035em; line-height: 1.15;
  display: inline-block; position: relative; padding-bottom: 12px;
  color: var(--ink);
  background: linear-gradient(115deg, #0b1220 0%, #07302c 42%, #0b6e64 78%, #12968a 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 1px 0 rgba(255, 255, 255, .5);
}
.dash-title::after {
  content: ""; position: absolute; left: 3px; bottom: 0; width: 60px; height: 3px; border-radius: 3px;
  background: linear-gradient(90deg, #12968a, rgba(18, 150, 138, .08));
  box-shadow: 0 0 14px rgba(18, 150, 138, .65);
}
@media (max-width: 600px) {
  .dash-title { font-size: var(--fs-h2); }
  .dash-title::after { width: 44px; }
}
.page-sub { color: var(--muted); font-size: var(--fs-label); margin-top: 6px; padding-left: 0; line-height: 1.6; }
/* 页眉元信息：按条目换行，窄屏折行时不会留下孤立的分隔点 */
.page-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 20px; }
.page-meta span { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
/* 页眉小标：只在工作台等总览页使用，强化控制台属性 */
.page-eyebrow {
  display: flex; align-items: center; gap: 8px; margin-bottom: 8px;
  font-family: var(--mono); font-size: var(--fs-micro); font-weight: 600;
  letter-spacing: .16em; color: var(--brand-2); text-transform: uppercase;
}
.page-eyebrow::before {
  content: ""; width: 14px; height: 2px; border-radius: 2px;
  background: linear-gradient(90deg, #12968a, rgba(18, 150, 138, .12));
}
.page-head .spacer { flex: 1; }

.card {
  background:
    linear-gradient(90deg, transparent, rgba(18, 150, 138, .22) 28%, rgba(18, 150, 138, .22) 72%, transparent) top left / 100% 1px no-repeat,
    var(--panel);
  border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease), transform .18s var(--ease);
}
.card-head { display: flex; align-items: center; gap: 9px; padding: 16px 20px 11px; }
.card-title { font-size: var(--fs-body); font-weight: 650; color: var(--text); letter-spacing: -.005em; }
.card-title::before { display: none; }
.card-sub { font-size: var(--fs-caption); color: var(--faint); }
.card-body { padding: 0 20px 20px; }
.card-link { margin-left: auto; font-size: var(--fs-caption); color: var(--brand); cursor: pointer; font-weight: 550; }
.card-link:hover { text-decoration: underline; }
/* 分组小标题：只在长页面用于分开同权重卡片 */
.section-label {
  display: flex; align-items: center; gap: 9px;
  font-size: var(--fs-caption); font-weight: 600; color: var(--faint); letter-spacing: .08em;
  margin: 22px 0 10px;
}
.section-label::before {
  content: ""; width: 5px; height: 5px; flex: none; border-radius: 1px;
  background: var(--brand-2); box-shadow: 0 0 8px var(--glow);
}
.section-label:first-child { margin-top: 0; }
.section-label::after { content: ""; flex: 1; height: 1px; background: var(--line); }
/* 折线图：进入时主线绘制一次，末点光晕缓慢呼吸 */
.ln-glow, .ln-main {
  stroke-dasharray: 2400; stroke-dashoffset: 2400;
  animation: ln-draw 1.3s var(--ease) .1s forwards;
}
@keyframes ln-draw { to { stroke-dashoffset: 0; } }
.ln-alt { animation: ln-fade .9s var(--ease) .55s both; }
@keyframes ln-fade { from { opacity: 0; } to { opacity: 1; } }
.end-halo { animation: halo-breathe 3.4s ease-in-out 1.5s infinite; }
@keyframes halo-breathe { 0%, 100% { opacity: .9; } 50% { opacity: .3; } }

/* 长条形列表：限高内滚，避免单卡撑高整行 */
.bar-scroll {
  max-height: 260px; overflow: auto; padding-right: 2px;
  scrollbar-width: thin; scrollbar-color: rgba(15, 23, 42, .18) transparent;
}
.bar-scroll:hover { scrollbar-color: var(--line-strong) transparent; }
.bar-scroll::-webkit-scrollbar { width: 6px; }
.bar-scroll::-webkit-scrollbar-thumb { background: rgba(15, 23, 42, .18); border-radius: 999px; }
.bar-scroll:hover::-webkit-scrollbar-thumb { background: var(--line-strong); }
/* 卡内滚动的列表：滚动条常隐、悬停显现，底部柔化避免行被切断 */
.repair-scroll {
  max-height: calc(100vh - 430px); overflow: auto;
  scrollbar-width: thin; scrollbar-color: transparent transparent;
  -webkit-mask-image: linear-gradient(180deg, #000 calc(100% - 24px), transparent 100%);
  mask-image: linear-gradient(180deg, #000 calc(100% - 24px), transparent 100%);
}
.repair-scroll:hover { scrollbar-color: var(--line-strong) transparent; }
.repair-scroll::-webkit-scrollbar { width: 6px; }
.repair-scroll::-webkit-scrollbar-track { background: transparent; }
.repair-scroll::-webkit-scrollbar-thumb { background: transparent; border-radius: 999px; }
.repair-scroll:hover::-webkit-scrollbar-thumb { background: var(--line-strong); }

.grid { display: grid; gap: 16px; }
.g-6 { grid-template-columns: repeat(6, 1fr); }
.g-4 { grid-template-columns: repeat(4, 1fr); }
.g-3 { grid-template-columns: repeat(3, 1fr); }
.g-2 { grid-template-columns: repeat(2, 1fr); }
.g-main { grid-template-columns: minmax(0, 2.05fr) minmax(300px, .95fr); align-items: start; }
.stack { display: flex; flex-direction: column; gap: 16px; }

/* 首页顶层：事件通报占前两列（约 2/3 宽），右上本周待办；下一行变更通知/通知/会议通知三块并排 */
.dash-top {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(280px, 320px);
  grid-template-rows: auto auto;
  gap: 16px; align-items: stretch; margin-bottom: 16px;
}
.dash-top > .card { display: flex; flex-direction: column; min-width: 0; }
.dash-top > .card > .card-body { flex: 1 1 auto; min-height: 0; overflow: auto; scrollbar-width: thin; scrollbar-color: transparent transparent; }
.dash-top > .card:hover > .card-body { scrollbar-color: var(--line-strong) transparent; }
.dash-top > .card > .card-body::-webkit-scrollbar { width: 6px; height: 6px; }
.dash-top > .card > .card-body::-webkit-scrollbar-thumb { background: transparent; border-radius: 999px; }
.dash-top > .card:hover > .card-body::-webkit-scrollbar-thumb { background: var(--line-strong); }
.dash-top > .ev-card { grid-column: 1 / span 2; grid-row: 1; }
/* 主事件卡：四角 HUD 描角，强化控制台观感 */
.ev-card { position: relative; }
.ev-card::before, .ev-card::after {
  content: ""; position: absolute; width: 16px; height: 16px; pointer-events: none; z-index: 2;
  border: 0 solid rgba(18, 150, 138, .34);
}
.ev-card::before { top: 0; left: 0; border-top-width: 1px; border-left-width: 1px; border-top-left-radius: var(--radius); }
.ev-card::after { right: 0; bottom: 0; border-right-width: 1px; border-bottom-width: 1px; border-bottom-right-radius: var(--radius); }
.dash-todo { grid-column: 3; grid-row: 1; }
.dash-change { grid-column: 1; grid-row: 2; }
.dash-notice { grid-column: 2; grid-row: 2; }
.meeting-card { grid-column: 3; grid-row: 2; }
/* 本周待办与事件卡同高：待办列表铺满卡片剩余高度，条目多时在卡内滚动，避免卡内出现大片空白 */
.dash-todo > .card-body { max-height: none; }
.dash-change > .card-body, .dash-notice > .card-body { max-height: 250px; }
/* 列表超出时底部柔化，避免行被生硬截断（仅用于限高的变更/通知卡） */
@media (min-width: 1181px) {
  /* 待办卡与事件卡同高：列表按卡片剩余高度铺满并滚动，不靠条目数撑高整行 */
  .dash-top > .dash-todo > .card-body { flex: 1 1 0; min-height: 0; }
  /* 仅当待办列表真的滚动时底部渐隐（由 initTodoFade 打标），最后一行不会被生硬截断 */
  .dash-top > .dash-todo > .card-body.is-scroll {
    -webkit-mask-image: linear-gradient(180deg, #000 calc(100% - 20px), transparent 100%);
    mask-image: linear-gradient(180deg, #000 calc(100% - 20px), transparent 100%);
  }
  .dash-change > .card-body, .dash-notice > .card-body {
    -webkit-mask-image: linear-gradient(180deg, #000 calc(100% - 24px), transparent 100%);
    mask-image: linear-gradient(180deg, #000 calc(100% - 24px), transparent 100%);
  }
}
.dash-top .card-head { flex-wrap: wrap; row-gap: 4px; }
.dash-top .card-sub { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 顶部三列的记录名统一走 13.5 档，与待办/维修同一层级 */
.dash-top .lr-title { font-size: var(--fs-label); }
.meet-empty { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; text-align: center; padding: 4px 8px; }
.meet-empty b { font-size: var(--fs-body); font-weight: 600; color: var(--text-2); }
.meet-empty span { font-size: var(--fs-caption); line-height: 1.6; color: var(--faint); }
.dash-fault { margin-bottom: 16px; }
.row { display: flex; align-items: center; gap: 8px; }
.row.wrap { flex-wrap: wrap; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.mono { font-family: var(--mono); font-size: var(--fs-caption); letter-spacing: .01em; }
.nowrap { white-space: nowrap; }
.right { text-align: right; }
.mt8 { margin-top: 8px; } .mt12 { margin-top: 12px; } .mt16 { margin-top: 16px; }
.mb8 { margin-bottom: 8px; } .mb12 { margin-bottom: 12px; }
.w100 { width: 100%; }

/* 按钮 */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 34px; padding: 0 14px; border-radius: 9px; border: 1px solid var(--line-strong);
  white-space: nowrap;
  background: #fff; color: var(--text-2); font-size: var(--fs-label); font-weight: 550;
  box-shadow: 0 1px 2px rgba(11, 18, 32, .04);
  transition: background-color .15s var(--ease), border-color .15s var(--ease), color .15s var(--ease), box-shadow .2s var(--ease), transform .15s var(--ease);
}
.btn:hover { border-color: #c3c9d4; background: var(--panel-2); color: var(--text); box-shadow: 0 2px 6px -3px rgba(11, 18, 32, .16); }
.btn svg { flex: none; display: block; }
.btn:active:not(:disabled) { background: var(--panel-3); transform: translateY(1px); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn.primary {
  background: linear-gradient(180deg, #12968a 0%, #0b6e64 100%); border-color: #0b6e64; color: #fff;
  box-shadow: 0 1px 2px rgba(13, 21, 38, .10), 0 4px 12px -6px rgba(11, 110, 100, .55), inset 0 1px 0 rgba(255, 255, 255, .16);
}
.btn.primary:hover {
  background: linear-gradient(180deg, #625bf0 0%, #4a42d8 100%); border-color: #4a42d8; color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px -8px rgba(11, 110, 100, .6), 0 1px 2px rgba(13, 21, 38, .12), inset 0 1px 0 rgba(255, 255, 255, .18);
}
.btn.primary:active:not(:disabled) {
  background: #08544c; border-color: #08544c; transform: translateY(0);
  box-shadow: 0 1px 2px rgba(13, 21, 38, .14), inset 0 1px 2px rgba(13, 21, 38, .18);
}
.btn.danger { color: var(--red); border-color: #f4c7c3; background: #fff; }
.btn.danger:hover { background: var(--red-weak); border-color: #f0b4ae; }
.btn.success { color: var(--text-2); border-color: var(--ok-line); background: #fff; }
.btn.success:hover { background: var(--ok-weak); }
.btn.ghost { border-color: transparent; background: transparent; color: var(--muted); box-shadow: none; }
.btn.ghost:hover { background: var(--panel-3); color: var(--text-2); }
.btn.sm { height: 28px; padding: 0 10px; font-size: var(--fs-caption); border-radius: 7px; }
.btn.xs { height: 24px; padding: 0 8px; font-size: var(--fs-caption); border-radius: 6px; }
.btn.block { width: 100%; }

/* 标签 */
.badge {
  display: inline-flex; align-items: center; gap: 4px; height: 21px; padding: 0 8px;
  border-radius: 6px; font-size: var(--fs-caption); font-weight: 550; white-space: nowrap;
  background: var(--panel-3); color: var(--text-2);
  box-shadow: inset 0 0 0 1px rgba(11, 18, 32, .025);
}
.badge.blue { background: var(--brand-weak); color: var(--brand); }
.badge.red { background: var(--red-weak); color: var(--red); }
.badge.amber { background: var(--amber-weak); color: var(--amber); }
.badge.green { background: var(--ok-weak); color: var(--ok); box-shadow: inset 0 0 0 1px var(--ok-line); }
.badge.green:not(:has(.sync-stage-icon))::before { content: "\2713"; font-weight: 700; font-size: var(--fs-micro); }
.badge.purple { background: var(--purple-weak); color: var(--purple); }
.badge.gray { background: rgba(93, 106, 126, .07); color: var(--muted); }
.badge.dot::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }

.prio { font-weight: 600; font-family: var(--mono); font-size: 12.5px; padding: 1px 6px; border-radius: 5px; }
.prio.P1 { background: var(--red-weak); color: var(--red); }
.prio.P2 { background: var(--amber-weak); color: var(--amber); }
.prio.P3 { background: var(--brand-weak); color: var(--brand); }
.prio.P4 { background: var(--panel-3); color: var(--muted); }
.prio.p-unk { background: var(--panel-3); color: var(--muted); }

/* KPI：浅色仪表块，保留网格、灯带与等宽读数 */
.kpi {
  background:
    radial-gradient(120% 150% at 100% 0%, rgba(18, 150, 138, .10), transparent 60%),
    linear-gradient(rgba(11, 110, 100, .045) 1px, transparent 1px) 0 0 / 26px 26px,
    linear-gradient(90deg, rgba(11, 110, 100, .045) 1px, transparent 1px) 0 0 / 26px 26px,
    linear-gradient(180deg, #fdfdff 0%, #f5f7fd 100%);
  border: 1px solid rgba(11, 110, 100, .14); border-radius: var(--radius);
  padding: 17px 19px 15px; position: relative; overflow: hidden;
  box-shadow: 0 1px 2px rgba(11, 18, 32, .03), 0 14px 30px -26px rgba(11, 18, 32, .45), inset 0 1px 0 #fff;
}
/* 顶部灯带：浅底上收窄为更实的一道靛蓝细线 */
.kpi::before {
  content: ""; display: block; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, rgba(11, 110, 100, .68) 0%, rgba(18, 150, 138, .16) 46%, rgba(18, 150, 138, 0) 84%);
}
.kpi-label { font-size: var(--fs-caption); color: var(--muted); display: flex; align-items: center; gap: 6px; letter-spacing: .08em; font-weight: 600; }
.kpi-label::before { display: none; }
.kpi-value {
  font-family: var(--mono); font-size: var(--fs-hero); font-weight: 680; letter-spacing: -.02em;
  margin-top: 9px; font-variant-numeric: tabular-nums; line-height: 1.05; color: var(--ink);
  text-shadow: 0 0 20px rgba(11, 110, 100, .15);
}
.kpi-value small { font-size: var(--fs-caption); font-weight: 400; color: var(--faint); margin-left: 4px; font-family: var(--font-sans); letter-spacing: 0; }
.kpi-value.is-sm { font-size: var(--fs-h2); }
.kpi-value.is-text { font-size: var(--fs-h4); font-weight: 500; letter-spacing: 0; color: var(--muted); text-shadow: none; }
.kpi-foot { font-size: var(--fs-caption); color: var(--faint); margin-top: 6px; }

/* 表格 */
.table-wrap {
  overflow-x: auto;
  scrollbar-width: thin; scrollbar-color: rgba(15, 23, 42, .18) transparent;
}
.table-wrap:hover { scrollbar-color: var(--line-strong) transparent; }
.table-wrap::-webkit-scrollbar { height: 6px; }
.table-wrap::-webkit-scrollbar-track { background: transparent; }
.table-wrap::-webkit-scrollbar-thumb { background: rgba(15, 23, 42, .18); border-radius: 999px; }
.table-wrap:hover::-webkit-scrollbar-thumb { background: var(--line-strong); }
table.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tbl th {
  text-align: left; font-weight: 600; color: #667085; font-size: 12px; letter-spacing: .07em;
  padding: 10px 12px; border-bottom: 1px solid var(--line); background: #fafbfe; white-space: nowrap;
}
.tbl th:first-child { border-top-left-radius: 8px; }
.tbl th:last-child { border-top-right-radius: 8px; }
.tbl td { padding: 11px 12px; border-bottom: 1px solid #f0f2f7; vertical-align: middle; }
/* 编码与时间列不折行，避免时间被拆成两行把行高撑乱 */
.tbl td.mono { white-space: nowrap; }
.tbl tbody tr { transition: background-color .12s var(--ease); }
.tbl tbody tr.clickable { cursor: pointer; }
.tbl tbody tr.clickable:hover { background: #f7f9ff; }
.tbl tbody tr.clickable:hover td:first-child { box-shadow: inset 2px 0 0 var(--brand); }
.tbl tr:last-child td { border-bottom: none; }
.tbl .title-cell { max-width: 380px; }
.tbl .title-main { font-weight: 550; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tbl .title-sub { font-size: 12.5px; color: var(--faint); margin-top: 1px; }
/* 账号表列多，避免中文名逐列折行 */
.accounts-tbl td { white-space: nowrap; }
.accounts-tbl td .title-main, .accounts-tbl td .title-sub { white-space: nowrap; }
.accounts-tbl td:first-child { font-family: var(--mono); font-size: 12.5px; color: var(--text-2); letter-spacing: .01em; }
th.sortable { cursor: pointer; user-select: none; white-space: nowrap; }
th.sortable:hover { color: var(--brand); }
th .sort-mark { color: var(--brand); margin-left: 2px; font-size: 12.5px; }
.empty {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  padding: 36px 16px; text-align: center; color: var(--muted); font-size: var(--fs-label); line-height: 1.6;
}
.empty b { font-size: var(--fs-body); font-weight: 600; color: var(--text-2); }
.empty span { font-size: var(--fs-caption); color: var(--faint); max-width: 340px; }
/* 表格空态：td 不能改成 flex，否则 colspan 宽度塌陷成窄条 */
.tbl td.empty {
  display: table-cell; padding: 36px 16px; text-align: center;
  color: var(--muted); font-size: var(--fs-label); line-height: 1.6;
}
.tbl td.empty b { display: block; }
.tbl td.empty span { display: block; margin-top: 2px; max-width: none; }

/* 状态 */
.status { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; white-space: nowrap; }
.status::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--faint); }
.status.new::before { background: #d92d20; }
.status.assigned::before { background: #f79009; }
.status.in_progress::before { background: #2e90fa; }
.status.hold::before { background: #98a2b3; }
.status.resolved::before { background: var(--ok); }
.status.closed::before { background: #98a2b3; }
.status.pending_approval::before { background: #f79009; }
.status.approved::before { background: #2e90fa; }
.status.implementing::before { background: var(--purple); }
.status.completed::before { background: var(--ok); }
.status.rolled_back::before { background: #d92d20; }
.status.cancelled::before, .status.rejected::before { background: #98a2b3; }
.status.delayed::before { background: #f79009; }
.status.submitted::before { background: #2e90fa; }
.status.accepted::before, .status.pending_confirm::before { background: #2e90fa; }

/* SLA */
.sla { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.sla.ok { color: var(--ok); }
.sla.warn { color: var(--amber); }
.sla.breach { color: var(--red); font-weight: 600; }
.sla.done { color: var(--muted); }
.sla i { width: 5px; height: 5px; border-radius: 50%; background: currentColor; display: inline-block; }

/* 筛选 */
.filters { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 13px 20px; border-bottom: 1px solid var(--line); background: #fcfcfe; }
.input, select.input {
  height: 34px; border: 1px solid var(--line-strong); border-radius: 9px; padding: 0 11px;
  background: #fff; outline: none; color: var(--text-2); font-size: 13.5px;
  transition: border-color .16s var(--ease), box-shadow .16s var(--ease);
}
.input:hover { border-color: #c3cad8; }
.input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(11, 110, 100, .12); }
select.input { padding-right: 4px; }
textarea.input { height: auto; padding: 8px 9px; resize: vertical; line-height: 1.6; }
.field { display: flex; flex-direction: column; gap: 5px; margin-bottom: 12px; }
.field > label { font-size: 12.5px; color: var(--text-2); font-weight: 500; }
.field > label span.req { color: var(--red); }
.field .hint { font-size: 12.5px; color: var(--faint); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
.form-grid .full { grid-column: 1 / -1; }

.tabs { display: flex; gap: 4px; align-items: center; border-bottom: 1px solid var(--line); padding: 0 12px; overflow-x: auto; }
.tab {
  padding: 11px 13px; font-size: 13.5px; color: var(--muted); border-bottom: 2px solid transparent;
  white-space: nowrap; cursor: pointer; background: none; border-top: 0; border-left: 0; border-right: 0;
  border-radius: 8px 8px 0 0;
  transition: background-color .15s var(--ease), color .15s var(--ease);
}
.tab:hover { color: var(--text); background: #f7f8fd; }
.tab.active {
  color: var(--brand); border-bottom-color: var(--brand); font-weight: 600;
  background: linear-gradient(180deg, rgba(11, 110, 100, .07), rgba(11, 110, 100, 0));
}
.tab .cnt { font-size: 12.5px; color: var(--faint); margin-left: 4px; font-variant-numeric: tabular-nums; }

/* 工作台 */
.alert-strip {
  display: flex; align-items: center; gap: 11px; padding: 12px 16px; border-radius: 12px;
  background: linear-gradient(90deg, #fff8f7 0%, #fffdfd 78%);
  border: 1px solid #f6d7d2; color: var(--text-2);
  margin-bottom: 16px; font-size: var(--fs-label); position: relative; overflow: hidden;
  box-shadow: 0 10px 24px -22px rgba(217, 45, 32, .7);
}
.alert-strip::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px;
  background: linear-gradient(180deg, #f97066, #d92d20);
}
.alert-strip .pulse { width: 7px; height: 7px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 3px rgba(217, 45, 32, .12), 0 0 10px rgba(217, 45, 32, .55); flex: none; }
.alert-strip b { color: var(--red); font-weight: 650; font-variant-numeric: tabular-nums; }
.alert-strip a { color: var(--red); font-weight: 600; }
/* 宽屏下收起事件卡的滑动说明，避免头部控件拥挤 */
@media (min-width: 1280px) {
  .ev-card-head .card-sub { display: none; }
}

.port-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; }
.port-card {
  border: 1px solid var(--line); border-radius: 12px; padding: 12px 13px; background: #fff; cursor: pointer;
  transition: border-color .17s var(--ease), box-shadow .17s var(--ease), background-color .17s var(--ease), transform .17s var(--ease);
  position: relative;
}
.port-card:hover { border-color: #c6caf0; background: #fcfcff; transform: translateY(-2px); box-shadow: var(--shadow-lift); }
.port-card .pc-code { font-family: var(--mono); font-size: var(--fs-micro); color: var(--faint); letter-spacing: .02em; }
.port-card .pc-name { font-size: var(--fs-label); font-weight: 600; margin: 2px 0 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.port-card .pc-foot { display: flex; align-items: center; justify-content: space-between; font-size: var(--fs-caption); color: var(--muted); }
.port-card .pc-open { font-weight: 650; font-size: var(--fs-h3); color: var(--text); font-variant-numeric: tabular-nums; font-family: var(--font-sans); letter-spacing: -.02em; }
.port-card.has-open { border-left: 1px solid var(--line); }
.port-card.has-p1 { border-color: #f6d0cb; background: linear-gradient(180deg, #fffbfa, #fff); box-shadow: inset 3px 0 0 rgba(240, 68, 56, .6); }
.port-card .pc-badge { font-size: var(--fs-caption); padding: 1px 6px; border-radius: 6px; background: var(--red-weak); color: var(--red); font-weight: 550; }

.list-row { display: flex; gap: 10px; padding: 13px 10px; margin: 0 -10px; border-radius: 9px; border-bottom: 1px solid #f0f1f5; cursor: pointer; transition: background-color .13s var(--ease); }
.list-row:last-child { border-bottom: none; }
.list-row:hover { background: #f8f9fe; }
.list-row:hover .lr-title { color: var(--brand); }
.lr-main { flex: 1; min-width: 0; }
.lr-title { font-size: var(--fs-body); font-weight: 550; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lr-sub { font-size: var(--fs-caption); color: var(--faint); margin-top: 2px; display: flex; gap: 8px; flex-wrap: wrap; }
.lr-side { text-align: right; flex: none; }
/* 首页故障台账紧凑行：收紧行高与字号，只保留口岸/状态 */
.list-row.compact { padding: 7px 0; align-items: center; }
.list-row.compact .lr-title { font-size: var(--fs-label); font-weight: 500; }
.list-row.compact .lr-sub { margin-top: 1px; font-size: var(--fs-caption); gap: 6px; }
.list-more { border-top: 1px solid #f0f1f5; margin-top: 2px; padding-top: 8px; font-size: var(--fs-label); }
.list-more a { color: var(--brand); }
.list-more a:hover { text-decoration: underline; }

.mini-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.mini-table td { padding: 7px 0; border-bottom: 1px solid #f0f1f5; }
.mini-table tr:last-child td { border-bottom: none; }

/* 图表 */
.chart-legend { display: flex; gap: 14px; font-size: 12.5px; color: var(--muted); flex-wrap: wrap; }
.legend-item { display: inline-flex; align-items: center; gap: 5px; }
.legend-swatch { width: 8px; height: 8px; border-radius: 8px; }
.bar-row { display: grid; grid-template-columns: 96px 1fr 38px; align-items: center; gap: 9px; margin-bottom: 9px; font-size: 12.5px; }
.bar-label { color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar-track { height: 8px; border-radius: 999px; background: var(--chart-track); overflow: hidden; }
.bar-fill { height: 100%; border-radius: 999px; background: linear-gradient(90deg, #12968a, #0b6e64); box-shadow: 0 0 10px -1px rgba(11, 110, 100, .45); }
.bar-val { text-align: right; color: var(--muted); font-variant-numeric: tabular-nums; font-family: var(--mono); font-size: 12.5px; }
/* 三列并排的卡片里，压缩标签列给条形留出长度 */
.card-body.grid.g-3 .bar-row { grid-template-columns: 78px 1fr 34px; gap: 7px; }
.donut-wrap { display: flex; align-items: center; justify-content: center; gap: 22px; }
.donut { width: 120px; height: 120px; border-radius: 50%; position: relative; flex: none; }
.donut::after { content: ""; position: absolute; inset: 19px; border-radius: 50%; background: #fff; }
.donut-center { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; z-index: 1; }
.donut-center b { font-size: 26px; line-height: 1.1; font-family: var(--font-sans); font-weight: 650; letter-spacing: -.02em; }
.donut-center span { font-size: 12.5px; color: var(--muted); }
.donut-legend { flex: 0 1 160px; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.dl-item { display: flex; align-items: center; gap: 7px; font-size: 12.5px; }
.dl-item .n { margin-left: auto; color: var(--muted); font-variant-numeric: tabular-nums; font-family: var(--mono); font-size: 12.5px; }

/* 看板：待办 / 维修进度 */
.todo-row { display: flex; align-items: flex-start; gap: 10px; padding: 12px 0; border-bottom: 1px solid #f0f1f5; }
.todo-row:last-child { border-bottom: none; }
.todo-row.clickable { cursor: pointer; }
.todo-row.clickable:hover { background: #fafbfc; border-radius: 6px; }
.todo-type { flex: none; font-size: var(--fs-caption); font-weight: 600; padding: 2px 7px; border-radius: 6px; margin-top: 1px; }
.todo-type.red { background: var(--red-weak); color: var(--red); }
.todo-type.purple { background: var(--purple-weak); color: var(--purple); }
.todo-type.blue { background: var(--brand-weak); color: var(--brand); }
.todo-type.amber { background: var(--amber-weak); color: var(--amber); }
.todo-main { flex: 1; min-width: 0; }
.todo-title { font-size: var(--fs-label); font-weight: 550; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.due-overdue { color: var(--red); }
.todo-meta { font-size: var(--fs-caption); color: var(--faint); margin-top: 1px; }
.todo-due { flex: none; font-size: var(--fs-caption); color: var(--muted); font-variant-numeric: tabular-nums; padding-top: 2px; }

/* 维修进度：单行紧凑列表（设备 / 进度 / 节点 / 处理人 / 时限） */
.rep-list { display: flex; flex-direction: column; }
.rep-row {
  display: grid; grid-template-columns: minmax(0, 1fr) 120px 104px minmax(0, 84px) 108px;
  align-items: center; column-gap: 14px;
  padding: 8px 10px; margin: 0 -10px; border-radius: 8px;
  border-bottom: 1px solid #f0f1f5; transition: background-color .13s var(--ease);
}
.rep-row:hover { background: #f8f9fe; }
.rep-row:last-child { border-bottom: none; }
.rep-main { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
.rep-device { font-size: var(--fs-label); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rep-code { font-size: var(--fs-micro); color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rep-steps { display: flex; gap: 4px; }
.rep-steps i { height: 5px; flex: 1; border-radius: 999px; background: #e9edf3; }
.rep-steps i.on { background: linear-gradient(90deg, #5ecfc0, #0b6e64); box-shadow: 0 0 8px -2px rgba(11, 110, 100, .5); }
.rep-status { justify-self: start; }
.rep-handler, .rep-due { font-size: var(--fs-caption); color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rep-due { text-align: right; font-variant-numeric: tabular-nums; }
.repair-item:hover { border-color: var(--line-strong); background: #fff; transform: translateY(-1px); box-shadow: var(--shadow-lift); }
.steps { align-self: center; display: flex; gap: 5px; margin: 0; max-width: none; }
.steps i { height: 5px; flex: 1; border-radius: 999px; background: #e9edf3; }
.steps i.on { background: linear-gradient(90deg, #5ecfc0, #0b6e64); box-shadow: 0 0 8px -2px rgba(11, 110, 100, .5); }
.src-note { font-size: 12.5px; color: var(--faint); background: var(--panel-3); border-radius: 8px; padding: 8px 10px; margin-top: 8px; }

/* 详情 */
.detail-head { display: flex; align-items: flex-start; gap: 14px; margin-bottom: 14px; }
.back { color: var(--muted); font-size: 13.5px; cursor: pointer; display: inline-flex; align-items: center; gap: 4px; margin-bottom: 8px; }
.back:hover { color: var(--brand); }
.detail-title { font-size: 19px; font-weight: 600; margin: 0; line-height: 1.35; }
.detail-meta { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 7px; }
.action-bar { display: flex; gap: 8px; flex-wrap: wrap; margin-left: auto; align-items: flex-start; }
.info-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px 18px; }
.info-item .k { font-size: 12.5px; color: var(--faint); margin-bottom: 2px; letter-spacing: .02em; }
.info-item .v { font-size: 13.5px; color: var(--text-2); }
.info-item .v strong { color: var(--text); }

.sla-panel { background: var(--panel-2); border: 1px solid var(--line); border-radius: 8px; padding: 12px; }
.sla-line { display: flex; justify-content: space-between; font-size: 13.5px; padding: 5px 0; }
.sla-line b { font-variant-numeric: tabular-nums; font-family: var(--mono); font-weight: 600; }
.progress { height: 6px; border-radius: 999px; background: var(--chart-track); overflow: hidden; margin: 7px 0 3px; }
.progress > i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, #12968a, #0b6e64); transition: width .3s var(--ease); }
.progress.red > i { background: var(--red); }
.progress.amber > i { background: var(--amber); }
.progress.green > i { background: var(--brand-2); }

.timeline { position: relative; padding-left: 20px; }
.timeline::before { content: ""; position: absolute; left: 5px; top: 6px; bottom: 6px; width: 1px; background: var(--line); }
.tl-item { position: relative; padding-bottom: 16px; }
.tl-item::before {
  content: ""; position: absolute; left: -19px; top: 5px; width: 7px; height: 7px; border-radius: 50%;
  background: #fff; border: 2px solid #98a2b3;
}
.tl-item.progress::before { border-color: var(--brand); }
.tl-item.recovery::before { border-color: var(--brand-2); }
.tl-item.note::before { border-color: #98a2b3; }
.tl-head { display: flex; gap: 8px; align-items: center; font-size: 12.5px; color: var(--muted); }
.tl-head b { color: var(--text-2); font-weight: 550; }
.tl-content { font-size: 13.5px; color: var(--text-2); margin-top: 3px; white-space: pre-wrap; }
.tl-tag { font-size: 12.5px; padding: 0 5px; border-radius: 8px; background: var(--panel-3); color: var(--muted); }
.comment-box { display: flex; gap: 8px; margin-top: 10px; }
.comment-box textarea { flex: 1; height: 60px; }

.notice-mini { border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; margin-bottom: 8px; background: var(--panel-2); }
.notice-mini .nm-head { display: flex; align-items: center; gap: 7px; }
.notice-mini .nm-title { font-size: 13.5px; font-weight: 550; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.notice-mini .nm-time { font-size: 12.5px; color: var(--faint); }

/* 时间线 */
.window-strip { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 4px; }
.win-day { min-width: 118px; border: 1px solid var(--line); border-radius: 8px; padding: 9px; background: var(--panel-2); }
.win-day.today { border-color: #c7cbf7; background: var(--brand-weak); }
.win-day .wd-date { font-size: 12.5px; color: var(--muted); font-family: var(--mono); }
.win-item { font-size: 12.5px; margin-top: 6px; padding: 5px 6px; border-radius: 8px; background: #fff; border: 1px solid #eef1f5; }
.win-item b { display: block; font-size: 12.5px; color: var(--brand); font-family: var(--mono); }

/* 服务目录 */
.catalog-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.catalog-card {
  border: 1px solid var(--line); border-radius: 8px; padding: 12px; background: #fff; cursor: pointer;
  transition: border-color .15s var(--ease), background-color .15s var(--ease);
}
.catalog-card:hover { border-color: var(--brand); background: var(--panel-2); }
.catalog-card .cc-name { font-weight: 600; font-size: 13.5px; }
.catalog-card .cc-cat { font-size: 12.5px; color: var(--faint); margin-top: 2px; }
.catalog-card .cc-sla { font-size: 12.5px; color: var(--brand); margin-top: 8px; }

/* 抽屉 / 弹窗（浮层允许投影） */
.overlay { position: fixed; inset: 0; background: rgba(15, 23, 42, .45); z-index: 60; display: flex; justify-content: flex-end; }
.overlay.center { align-items: center; justify-content: center; }
.drawer {
  width: 620px; max-width: 94vw; height: 100%; background: var(--panel); box-shadow: -12px 0 40px rgba(16, 24, 40, .14);
  display: flex; flex-direction: column; animation: slideIn .22s var(--ease);
}
@keyframes slideIn { from { transform: translateX(30px); opacity: .6; } to { transform: none; opacity: 1; } }
.drawer-head { padding: 16px 20px 12px; border-bottom: 1px solid var(--line); display: flex; gap: 10px; align-items: flex-start; }
.drawer-head h3 { margin: 0; font-size: 16px; }
.drawer-head .sub { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.drawer-body { padding: 18px 20px; overflow-y: auto; flex: 1; }
.drawer-foot { padding: 12px 20px; border-top: 1px solid var(--line); display: flex; gap: 8px; justify-content: flex-end; background: var(--panel-2); }
.icon-btn { border: 0; background: transparent; color: var(--muted); width: 28px; height: 28px; border-radius: 8px; font-size: 19px; line-height: 1; }
.icon-btn:hover { background: var(--panel-3); color: var(--text); }

.modal {
  width: 560px; max-width: 92vw; max-height: 90vh; background: var(--panel); border-radius: 14px;
  box-shadow: 0 24px 64px rgba(16, 24, 40, .18); display: flex; flex-direction: column; animation: pop .18s var(--ease);
}
.modal.wide { width: 780px; }
/* 宽弹窗里是短字段：窄屏也保持两列，避免一路竖排拉得过长 */
@media (max-width: 760px) { .modal.wide .form-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .modal.wide .form-grid { grid-template-columns: 1fr; } }
/* 表单撑满弹窗剩余高度，内容超高时只滚 modal-body，底部按钮始终可见 */
.modal > form { display: flex; flex-direction: column; flex: 1; min-height: 0; }
@keyframes pop { from { transform: translateY(8px) scale(.985); opacity: .7; } to { transform: none; opacity: 1; } }
.modal-head { padding: 16px 18px 10px; display: flex; align-items: flex-start; gap: 10px; border-bottom: 1px solid var(--line); }
.modal-head h3 { margin: 0; font-size: 16px; }
.modal-head .sub { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.modal-body { padding: 16px 18px 4px; overflow-y: auto; flex: 1; min-height: 0; }
.modal-foot { padding: 12px 18px 16px; display: flex; gap: 8px; justify-content: flex-end; flex: none; }

/* 通报预览 */
.notice-preview {
  background: var(--panel-2); border: 1px solid var(--line); border-radius: 8px; padding: 14px;
  font-family: var(--mono); font-size: 13.5px; white-space: pre-wrap; line-height: 1.75; color: #1f2a3a;
  min-height: 200px;
}
.channel-row { display: flex; gap: 8px; flex-wrap: wrap; }
.chk {
  display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line-strong); border-radius: 8px;
  padding: 5px 9px; font-size: 13.5px; cursor: pointer; background: #fff;
}
.chk input { accent-color: var(--brand); }
.chk.on { border-color: var(--brand); background: var(--brand-weak); color: var(--brand); }

/* toast */
#toastRoot { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%); z-index: 90; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast {
  background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 10px; font-size: 13.5px;
  box-shadow: 0 12px 30px rgba(16, 24, 40, .24); animation: pop .18s var(--ease); max-width: 70vw;
}
.toast.err { background: #b42318; }
.toast.ok { background: var(--ink); }

.loading {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  padding: 60px 0; color: var(--muted); font-size: var(--fs-label);
}
.loading::before {
  content: ""; width: 14px; height: 14px; border-radius: 50%; flex: none;
  border: 2px solid var(--line); border-top-color: var(--brand);
  animation: sd-spin .7s linear infinite;
}
@keyframes sd-spin { to { transform: rotate(360deg); } }
/* 表格/卡片内的就地加载 */
.loading-inline { display: inline-flex; align-items: center; justify-content: center; gap: 8px; color: var(--muted); font-size: var(--fs-label); }
.loading-inline::before {
  content: ""; width: 12px; height: 12px; border-radius: 50%; flex: none;
  border: 2px solid var(--line); border-top-color: var(--brand);
  animation: sd-spin .7s linear infinite;
}

/* 今日值班 */
.duty-card .card-head { flex-wrap: wrap; row-gap: 6px; }
.duty-head .duty-nav { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.duty-nav .input { height: 30px; width: 138px; padding: 0 8px; }
.duty-date-hint { flex-basis: 100%; font-size: var(--fs-caption); color: var(--muted); line-height: 1.5; }
.duty-date-hint b { color: var(--text-2); font-weight: 600; }
.duty-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; align-items: stretch; }
.duty-group { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 10px; background: #fff; min-width: 0; overflow: hidden; }
.duty-group-head { display: flex; align-items: center; gap: 6px; padding: 10px 12px; border-bottom: 1px solid var(--line); flex-wrap: wrap; row-gap: 4px; background: var(--panel-2); }
.duty-group-title { font-size: var(--fs-label); font-weight: 600; }
.duty-group-hint { font-size: var(--fs-caption); color: var(--faint); }
.duty-group-head .badge { margin-left: auto; }
.duty-badges { margin-left: auto; display: flex; align-items: center; gap: 4px; flex: none; }
.duty-badges .badge { margin-left: 0; }
.duty-group-body { padding: 8px 11px; flex: 1 1 auto; min-height: 240px; max-height: 300px; overflow: auto; scrollbar-gutter: stable; }
/* 三张值班卡共用同一套分组标题与人员行 */
.duty-section { padding: 7px 0 5px; border-bottom: 1px solid var(--line); }
.duty-section:first-child { padding-top: 2px; }
.duty-section:last-child { border-bottom: 0; padding-bottom: 2px; }
.duty-section-head { display: flex; align-items: baseline; gap: 8px; margin-bottom: 2px; }
.duty-section-name { flex: 1 1 auto; min-width: 0; font-size: var(--fs-caption); font-weight: 600; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.duty-section-count { flex: none; font-size: var(--fs-caption); color: var(--faint); }
.duty-section-sub { font-size: var(--fs-caption); color: var(--faint); margin-bottom: 3px; }
.duty-row { display: flex; align-items: baseline; gap: 6px; padding: 3px 0; min-width: 0; }
.dp-person { flex: 0 1 auto; min-width: 48px; font-size: var(--fs-label); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dp-meta { flex: 0 1 auto; min-width: 0; font-size: var(--fs-caption); color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.duty-tel { flex: none; margin-inline-start: auto; font-family: var(--mono); font-size: var(--fs-caption); color: var(--text-2); white-space: nowrap; }
.duty-empty { padding: 16px 2px; text-align: center; color: var(--muted); font-size: var(--fs-label); line-height: 1.8; }
.duty-empty span { color: var(--faint); font-size: var(--fs-caption); }
.duty-missing { color: var(--amber); }
.duty-loading { padding: 26px; text-align: center; color: var(--muted); font-size: var(--fs-label); }
.duty-note { padding: 7px 11px 9px; border-top: 1px solid var(--line); font-size: var(--fs-caption); color: var(--faint); line-height: 1.6; }
.duty-group-body > .duty-empty { min-height: 100%; display: flex; flex-direction: column; justify-content: center; }

/* ---------- 故障台账 / 通报台账 ---------- */
.kpi-sub { font-size: 12.5px; color: var(--faint); margin-top: 4px; }
.stat-title { font-size: 12.5px; font-weight: 600; color: var(--muted); margin-bottom: 8px; letter-spacing: .04em; }
.kv-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px 18px; }
.kv-k { font-size: 12.5px; color: var(--faint); margin-bottom: 3px; }
.kv-v { font-size: 15px; line-height: 1.5; word-break: break-word; }
.kv.span2 { grid-column: span 2; }
.ledger-list { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.ledger-row { padding: 10px 14px; border-bottom: 1px solid var(--line); cursor: pointer; }
.ledger-row:last-child { border-bottom: 0; }
.ledger-row:hover { background: #fafbfc; }
.ledger-title { font-size: 15px; font-weight: 600; }
.ledger-meta { margin-top: 4px; display: flex; flex-wrap: wrap; gap: 8px; font-size: 12.5px; color: var(--muted); }
.ledger-group + .ledger-group { border-top: 1px solid var(--line); }
.ledger-group-head .lg-caret { color: var(--brand); cursor: pointer; }
.ledger-flow { background: var(--panel-2); border-top: 1px solid var(--line); }
.flow-row { display: flex; gap: 12px; padding: 9px 14px 9px 22px; border-bottom: 1px solid #f0f1f5; }
.flow-row:last-child { border-bottom: 0; }
.flow-time { flex: 0 0 118px; font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; font-family: var(--mono); }
.flow-title { font-size: 13.5px; color: var(--text); display: flex; gap: 6px; align-items: baseline; }
.flow-body { min-width: 0; }

/* ---------- 通用分页 / 排序 / 补充说明 ---------- */
.pager { display: flex; align-items: center; gap: 6px; padding: 10px 16px; border-top: 1px solid var(--line); font-size: 13.5px; color: var(--muted); flex-wrap: wrap; }
.pager .spacer { flex: 1; }
.pager button { min-width: 28px; height: 28px; padding: 0 8px; border: 1px solid var(--line); background: #fff; border-radius: 7px; font-size: 13.5px; color: var(--text-2); cursor: pointer; }
.pager button:hover:not(:disabled) { border-color: var(--brand); color: var(--brand); }
.pager button.active { background: var(--brand); border-color: var(--brand); color: #fff; }
.pager button:disabled { opacity: .45; cursor: not-allowed; }
.info-note { font-size: 13.5px; color: var(--muted); line-height: 1.7; }

/* ---------- 工作台：事件通报横向卡片 ---------- */
.ev-card-head { flex-wrap: wrap; row-gap: 6px; }
.ev-nav { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.ev-nav .card-link { margin-left: 6px; }
.ev-nav .btn[disabled] { opacity: .38; cursor: default; }
.ev-count { min-width: 46px; text-align: center; font-size: var(--fs-caption); color: var(--muted); font-variant-numeric: tabular-nums; font-family: var(--mono); }
.ev-rail {
  display: flex; gap: 16px; margin: 0 18px 18px; overflow-x: auto; overflow-y: hidden;
  scroll-snap-type: x mandatory; overscroll-behavior-x: contain;
  flex: 1 1 auto; min-height: 0; padding-bottom: 4px; cursor: grab;
}
.ev-rail.dragging { cursor: grabbing; scroll-snap-type: none; }
/* 滚动条常态隐形，悬停/拖拽时显现，避免卡片底部出现常驻灰条 */
.ev-rail { scrollbar-width: thin; scrollbar-color: transparent transparent; }
.ev-rail:hover, .ev-rail.dragging { scrollbar-color: var(--line-strong) transparent; }
.ev-rail::-webkit-scrollbar { height: 6px; }
.ev-rail::-webkit-scrollbar-track { background: transparent; }
.ev-rail::-webkit-scrollbar-thumb { background: transparent; border-radius: 999px; }
.ev-rail:hover::-webkit-scrollbar-thumb, .ev-rail.dragging::-webkit-scrollbar-thumb { background: var(--line-strong); }
.ev-rail::-webkit-scrollbar-thumb:hover { background: #b9c0cd; }
.ev-slide {
  flex: 0 0 100%; min-width: 0; align-self: stretch; scroll-snap-align: start;
  display: flex; flex-direction: column; justify-content: flex-start; gap: 10px;
  border: 1px solid var(--line); border-radius: 12px;
  background: linear-gradient(180deg, #fbfcff 0%, #ffffff 62%);
  padding: 17px 18px 14px 20px; position: relative; overflow: hidden;
  box-shadow: inset 0 1px 0 #fff;
}
/* 左侧状态色带：进行中=红 / 已恢复=绿，扫一眼即知当前态 */
.ev-slide::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px;
  background: var(--line-strong);
}
.ev-slide.is-active::before { background: linear-gradient(180deg, #f97066, #d92d20); box-shadow: 2px 0 12px -2px rgba(217, 45, 32, .4); }
.ev-slide.is-recovered::before { background: linear-gradient(180deg, #94a3b8, #64748b); box-shadow: 2px 0 12px -2px rgba(71, 84, 103, .3); }
.ev-head { display: flex; align-items: flex-start; gap: 10px; padding-bottom: 11px; border-bottom: 1px solid var(--line); }
.ev-title-wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; min-width: 0; }
.ev-title { margin: 0; font-size: var(--fs-h4); font-weight: 680; line-height: 1.4; color: var(--text); letter-spacing: -.015em; }
.ev-tags { margin-left: auto; display: flex; gap: 6px; flex: none; }
/* 字段多列并排：容器够宽时一行四列（对齐参考版式），变窄自动降为三列/两列；长字段整行 */
.ev-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(216px, 1fr)); gap: 8px 24px; margin: 0; align-items: start; }
.ev-f { display: flex; gap: 10px; min-width: 0; font-size: var(--fs-label); line-height: 1.7; padding: 6px 0; }
/* 标签：更小更粗，作为说明性 caption，与 label 档的值拉开层级 */
.ev-f dt { flex: none; width: 72px; color: var(--muted); font-size: var(--fs-caption); font-weight: 600; letter-spacing: .02em; padding-top: 1px; }
.ev-f dd { margin: 0; flex: 1 1 auto; min-width: 0; color: var(--text-2); white-space: pre-line; word-break: break-word; overflow-wrap: anywhere; }
/* 事实字段限两行，避免个别长值把整行撑高；完整内容见悬停提示与「查看原文」 */
.ev-f:not(.span-all) dd {
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
/* 超长事实字段（如影响范围）改为整行通栏，不再被挤在窄列里逐字折行 */
.ev-f.wide { grid-column: 1 / -1; }
/* 叙述型字段（故障描述/原因/进展）：独立成块，靛蓝左条 + 浅底，与上方键值事实区视觉分层 */
.ev-f.span-all {
  grid-column: 1 / -1; flex-direction: column; gap: 4px;
  background: linear-gradient(180deg, #f6f8ff, #fbfcff);
  border: 1px solid var(--line); border-left: 2px solid var(--brand);
  border-radius: 8px; padding: 9px 13px; margin: 3px 0;
}
.ev-f.span-all dt { width: auto; color: var(--brand); font-weight: 650; letter-spacing: .04em; padding-top: 0; }
.ev-f.span-all dd {
  line-height: 1.75;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.ev-foot {
  margin-top: auto; padding-top: 10px; border-top: 1px solid var(--line);
  display: flex; align-items: center; gap: 16px; font-size: var(--fs-caption); color: var(--faint);
}
.ev-more { margin-left: auto; color: var(--brand); cursor: pointer; }
.ev-more:hover { text-decoration: underline; }

/* ---------- C′ 四层事件通报：关键值(含处理人) / 叙述 / 次要折叠 ---------- */
/* 关键值区：编号 / 时间 / 影响范围 / 处理人员，一屏抓完必读信息 */
.ev-keygrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 9px; margin: 0; }
.ev-kv { min-width: 0; background: var(--panel-2); border: 1px solid var(--line); border-radius: 9px; padding: 8px 11px; }
.ev-kv-k { font-size: var(--fs-caption); color: var(--muted); font-weight: 600; line-height: 1.4; }
.ev-kv-v { font-size: var(--fs-body); color: var(--ink); font-weight: 600; margin-top: 3px; line-height: 1.45; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-variant-numeric: tabular-nums; }
/* 叙述区：故障描述 / 原因 / 进展，连续阅读，浅底左条 */
.ev-narrative { display: flex; flex-direction: column; gap: 7px; }
.ev-para { display: flex; gap: 10px; align-items: flex-start; font-size: var(--fs-body); line-height: 1.7; color: var(--text-2); }
.ev-para-k { flex: none; width: 66px; color: var(--brand); font-weight: 650; letter-spacing: .03em; }
.ev-para-v { flex: 1 1 auto; min-width: 0; word-break: break-word; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
/* 次要折叠：来源 / 通知人 / 恢复时间 */
.ev-fold { border-top: 1px solid var(--line); padding-top: 8px; }
.ev-fold summary { list-style: none; cursor: pointer; font-size: var(--fs-label); color: var(--brand); font-weight: 600; display: flex; align-items: center; }
.ev-fold summary::-webkit-details-marker { display: none; }
.ev-fold-arrow { margin-left: auto; transition: transform .18s var(--ease); }
.ev-fold[open] .ev-fold-arrow { transform: rotate(180deg); }
.ev-fold-body { margin: 9px 0 0; display: flex; flex-direction: column; gap: 6px; }
.ev-fold-body .ev-para { font-size: var(--fs-label); }
.ev-fold-body .ev-para-k { color: var(--muted); }

/* ---------- 项目交付 ---------- */
.delv-tbl th, .delv-tbl td { white-space: nowrap; }
/* 首列吸附：横向滚动 12 个月时仍能看到交付物名称 */
.delv-tbl .delv-name { position: sticky; left: 0; z-index: 1; min-width: 210px; max-width: 300px; background: #fff; }
.delv-tbl thead .delv-name { background: #fafbfe; z-index: 2; }
.delv-tbl tbody tr.clickable:hover .delv-name { background: #f7f9ff; }
.delv-tbl .delv-name .title-main { white-space: normal; overflow: visible; }
.delv-tbl .dcell-td, .delv-tbl .dcell-th { padding: 8px 6px; text-align: center; }
.delv-tbl .dcell-th.is-current { color: var(--brand); background: var(--brand-weak); }
.dcell {
  display: inline-flex; align-items: center; justify-content: center; min-width: 50px; height: 22px;
  padding: 0 6px; border-radius: 5px; font-size: 12px; font-weight: 550; white-space: nowrap;
}
.dcell.s-green { background: var(--brand-weak); color: var(--brand); }
.dcell.s-teal { background: var(--brand-weak); color: var(--brand-2); }
.dcell.s-blue { background: var(--brand-weak); color: var(--brand); }
.dcell.s-amber { background: var(--amber-weak); color: var(--amber); }
.dcell.s-gray { background: rgba(93, 106, 126, .07); color: var(--muted); }
.dcell.s-none { background: transparent; color: #c4cad4; }
.delv-legend { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 12.5px; color: var(--muted); }
.delv-legend-item { display: inline-flex; align-items: center; gap: 4px; }
.delv-legend-item i { width: 8px; height: 8px; border-radius: 8px; display: inline-block; }
.delv-legend-item i.s-green { background: var(--brand); }
.delv-legend-item i.s-teal { background: var(--brand-2); }
.delv-legend-item i.s-blue { background: var(--brand); }
.delv-legend-item i.s-amber { background: var(--amber); }
.delv-legend-item i.s-gray { background: var(--muted); }
.delv-months { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.delv-month {
  display: flex; flex-direction: column; gap: 6px; padding: 8px 10px;
  border: 1px solid var(--line); border-radius: 8px; background: #fcfcfe;
}
.delv-month .dm-label { font-size: 12.5px; color: var(--muted); }
.delv-month.is-current { border-color: rgba(11, 110, 100, .35); background: var(--brand-weak); }

/* ---------- 响应式 ---------- */
@media (max-width: 1320px) {
  .g-6 { grid-template-columns: repeat(3, 1fr); }
  .port-grid { grid-template-columns: repeat(4, 1fr); }
  .catalog-grid { grid-template-columns: repeat(3, 1fr); }
  .info-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 1280px) {
  .dash-top { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 300px; }
}
@media (max-width: 1180px) {
  /* 1024 级宽屏：事件卡通栏，其余四块两两并排，避免空态卡片把页面拉得很长 */
  .dash-top { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dash-top > .ev-card { grid-column: 1 / -1; }
  .dash-change, .dash-notice, .dash-todo, .meeting-card { grid-column: auto; grid-row: auto; }
  .dash-todo { order: 9; }
  .dash-todo > .card-body, .dash-change > .card-body, .dash-notice > .card-body { max-height: 250px; }
  .ev-slide { height: auto; align-self: flex-start; justify-content: flex-start; }
}
/* 1024 窄屏：保留文字导航，靠收窄内边距而不是拉扁行高 */
@media (max-width: 1080px) and (min-width: 901px) {
  :root { --sidebar-w: 200px; }
  .brand { justify-content: flex-start; gap: 9px; padding: 16px 14px 12px; }
  .brand-sub { display: none; }
  .brand-name { font-size: 15px; }
  .nav { padding: 2px 8px 4px; }
  .nav-group { padding: 14px 9px 5px; letter-spacing: .12em; }
  .nav-item { padding: 0 9px; gap: 8px; }
  .nav-tail { padding: 8px 8px 10px; }
  .g-main { grid-template-columns: minmax(0, 1fr); }
  .g-4 { grid-template-columns: repeat(2, 1fr); }
  .view { padding: 22px 22px 36px; }
}
/* 窄屏表格保留可读列宽，超出部分在卡片内横向滚动，避免状态/角色被挤成竖排 */
@media (max-width: 1080px) {
  .table-wrap { -webkit-overflow-scrolling: touch; }
  .table-wrap > .tbl { min-width: 1000px; }
  /* 数据源状态为三列摘要表，收窄最小宽度并允许长路径折行，避免关键状态列被裁切 */
  .sync-sources .table-wrap > .tbl { min-width: 640px; }
  .sync-sources .tbl th, .sync-sources .tbl td { word-break: break-word; }
  /* 双列卡片允许收缩，表格在卡片内部滚动，避免整页被 1000px 表格撑宽 */
  .g-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  /* 7 天变更窗口在窄屏换行，避免末列被裁切 */
  .window-strip { flex-wrap: wrap; }
  /* 事件字段在 1080 以下保持两列，避免值列被压到 132px 后折行 */
  .ev-fields { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
}
/* 客服质效底部两张口径表在窄屏整行展示，减少表内横向滚动 */
@media (max-width: 1180px) {
  .grid.g-2.cs-bottom { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 900px) {
  .sidebar { width: 64px; }
  .brand > div:last-child, .nav-group, .nav-item em { display: none; }
  .nav { padding: 4px 6px; }
  .nav-tail { padding: 8px 6px 10px; }
  .brand { justify-content: center; padding: 16px 0; }
  .nav-item { justify-content: center; font-size: 0; padding: 8px; gap: 0; height: 38px; }
  .ni { display: grid; place-items: center; width: 20px; height: 20px; }
  .ni svg { width: 20px; height: 20px; }
  .main { margin-left: 64px; }
  .g-main { grid-template-columns: minmax(0, 1fr); }
  .g-4 { grid-template-columns: repeat(2, 1fr); }
  /* 三列图表卡在平板宽度会把条形压成短线，降为两列 */
  .g-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  /* 页头操作区在窄屏换行，避免按钮被压成多行 */
  .page-head { flex-wrap: wrap; row-gap: 10px; }
  .page-head .spacer { display: none; }
  .page-head > .btn { margin-left: auto; }
  /* 图标侧栏下恢复单列，卡片不再限高，内容完整展开 */
  .dash-top { grid-template-columns: minmax(0, 1fr); }
  .dash-todo > .card-body, .dash-change > .card-body, .dash-notice > .card-body { max-height: none; }
}
@media (max-width: 820px) {
  /* 三组值班卡在平板竖屏放不下三列（口岸卡会裁掉电话），改为纵向排列 */
  .duty-grid { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .duty-head .duty-nav { width: 100%; margin-left: 0; }
  .g-6, .g-4, .g-3, .g-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .port-grid, .catalog-grid { grid-template-columns: repeat(2, 1fr); }
  .topbar { padding: 0 14px; gap: 8px; }
  .view { padding: 16px 14px 30px; }
  .search-wrap { max-width: none; }
  .form-grid { grid-template-columns: 1fr; }
  .info-grid { grid-template-columns: repeat(2, 1fr); }
  #userSelect { max-width: 92px; }
  /* 维修进度：窄屏隐藏处理人列，保留设备/进度/节点/时限 */
  .rep-row { grid-template-columns: minmax(0, 1fr) 90px 92px 96px; column-gap: 10px; }
  .rep-handler { display: none; }
  /* 页签在窄屏换行，避免右侧页签被裁切又无滚动提示 */
  .tabs { flex-wrap: wrap; }
  .delv-months { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  /* 手机竖屏：图表/表单类双列与三列卡片改为单列，避免图例出界和竖排文字 */
  .g-2, .g-3 { grid-template-columns: minmax(0, 1fr); }
  .port-grid, .catalog-grid { grid-template-columns: 1fr; }
  /* 维修进度：手机改为两行——设备+节点，进度+时限 */
  .rep-row { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "main status" "steps due"; row-gap: 6px; }
  .rep-main { grid-area: main; }
  .rep-status { grid-area: status; justify-self: end; }
  .rep-steps { grid-area: steps; }
  .rep-due { grid-area: due; }
  /* 事件卡头部在手机上换行：标题独占一整行，标签另起一行，避免标题被挤成竖排 */
  .ev-head { flex-wrap: wrap; row-gap: 8px; }
  .ev-title-wrap { flex: 1 1 100%; }
  .ev-tags { margin-left: 0; width: 100%; flex-wrap: wrap; }
  .user-meta { display: none; }
  .user-box { padding-left: 10px; }
  /* 卡片头在手机宽度整体换行：标题保持单行，副标题自然落到下一行 */
  .card-head { flex-wrap: wrap; row-gap: 5px; }
  .card-title { white-space: nowrap; }
  .pager button { min-width: 32px; height: 32px; }
  .icon-btn { width: 32px; height: 32px; }
}
@media (max-width: 1080px) { .ledger-list { grid-template-columns: 1fr; } }
@media (max-width: 900px) { .kv-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .kv-grid { grid-template-columns: 1fr; } .kv.span2 { grid-column: span 1; } }

/* ---------- 数据读取 ---------- */
.sync-refresh-hint { font-size: 12.5px; color: var(--faint); }
.sync-hero { padding: 20px 20px 16px; }
.sync-hero-top { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.sync-hero-lead { min-width: 0; flex: 1 1 360px; }
.sync-state { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.sync-state .mono { font-size: 12.5px; color: var(--faint); }
.sync-live { font-size: 12.5px; color: var(--brand); }
.sync-live::before {
  content: ""; display: inline-block; width: 5px; height: 5px; border-radius: 50%;
  background: var(--brand); margin-right: 4px; vertical-align: 1px;
  box-shadow: 0 0 0 3px rgba(11, 110, 100, .12);
}
.sync-headline { display: flex; align-items: baseline; gap: 4px; margin-top: 12px; flex-wrap: wrap; }
.sync-pct { font-family: var(--font-sans); font-size: 46px; font-weight: 650; line-height: .95; letter-spacing: -.03em; }
.sync-pct-unit { font-size: 19px; color: var(--muted); }
.sync-count { margin-left: 10px; font-size: 13.5px; color: var(--muted); }
.sync-pct.is-unknown { font-size: 34px; color: var(--faint); letter-spacing: 0; }
.sync-meter { height: 8px; border-radius: 999px; background: #eef1f5; overflow: hidden; margin-top: 13px; }
.sync-meter.is-unknown { background: repeating-linear-gradient(135deg, #eef1f5 0 6px, #dfe3ea 6px 12px); }
.sync-meter > i { display: block; height: 100%; background: linear-gradient(90deg, #12968a, #0b6e64); border-radius: 999px; box-shadow: 0 0 12px -1px rgba(11, 110, 100, .5); transition: width .45s var(--ease); }
.sync-meta { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 10px; font-size: 12.5px; color: var(--faint); }
.sync-facts { display: grid; grid-template-columns: repeat(2, minmax(92px, auto)); gap: 10px 22px; align-content: start; padding-top: 2px; }
.sync-facts > div { display: flex; flex-direction: column; gap: 1px; }
.sync-facts span { font-size: 12.5px; color: var(--faint); }
.sync-facts b { font-family: var(--font-sans); font-size: 19px; font-weight: 650; line-height: 1.25; }
.sync-facts b.is-bad { color: var(--red); }
.sync-banner { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; margin-top: 12px; padding: 10px 12px; border-radius: 9px; border: 1px solid transparent; font-size: 12.5px; line-height: 1.6; }
.sync-banner b { font-weight: 600; }
.sync-banner.amber { background: var(--amber-weak); color: var(--amber); border-color: var(--amber-line); }
.sync-banner.red { background: var(--red-weak); color: var(--red); border-color: #f6d3cf; }
.sync-banner.green { background: var(--ok-weak); color: var(--ok); border-color: var(--ok-line); }
.sync-hero-foot { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 12px; padding-top: 11px; border-top: 1px solid var(--line); font-size: 12.5px; color: var(--faint); }
.sync-hero-foot .mono { font-size: 12.5px; color: var(--muted); }
.sync-stages .card-body { padding-top: 2px; }
.sync-stage { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 10px; padding: 13px 10px 12px; border-bottom: 1px solid #f0f1f5; position: relative; border-radius: 8px; }
.sync-stage:last-child { border-bottom: 0; }
.sync-stage.s-running { background: #fbfbff; }
.sync-stage-mark { font-family: var(--mono); font-size: 12.5px; color: var(--faint); padding-top: 2px; }
.sync-stage-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.sync-stage-name { font-size: 13.5px; font-weight: 600; }
.sync-stage-pct { font-size: 12.5px; color: var(--muted); font-family: var(--mono); }
.sync-stage-time { margin-left: auto; font-size: 12.5px; color: var(--faint); font-family: var(--mono); }
.sync-stage-src { margin-top: 2px; font-size: 12.5px; color: var(--faint); font-family: var(--mono); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sync-bar { height: 6px; border-radius: 999px; background: #eef1f5; overflow: hidden; margin-top: 7px; }
.sync-bar > i { display: block; height: 100%; background: var(--brand); border-radius: 999px; transition: width .3s var(--ease); }
.sync-bar.is-live { background: repeating-linear-gradient(135deg, #eef1f5 0 5px, #dfe3ea 5px 10px); }
.sync-stage.s-failed .sync-bar > i { background: var(--red); }
.sync-stage.s-done .sync-bar > i { background: var(--brand); }
.sync-stage.s-pending .sync-bar, .sync-stage.s-skipped .sync-bar { opacity: .4; }
.sync-stage.s-pending .sync-bar > i, .sync-stage.s-skipped .sync-bar > i { background: #98a2b3; }
.sync-stage-foot { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 6px; font-size: 12.5px; color: var(--muted); }
.sync-stage-foot .live { color: var(--brand); font-weight: 500; }
.sync-stage-foot .err { flex-basis: 100%; color: var(--red); }
.sync-stage-foot .note { flex-basis: 100%; color: var(--faint); }
.sync-empty .empty { padding: 56px 20px 44px; }
.sync-empty-title { font-size: 16px; font-weight: 600; color: var(--text); }
.sync-empty .mono { font-size: 12.5px; color: var(--muted); }
@media (max-width: 760px) {
  .sync-hero-top { flex-direction: column; gap: 14px; }
  .sync-facts { grid-template-columns: repeat(2, 1fr); width: 100%; padding-top: 8px; }
  .sync-pct { font-size: 40px; }
}

/* ---------- 键盘焦点与动效降级 ---------- */
.nav-item:focus-visible, .btn:focus-visible, .tab:focus-visible, .pager button:focus-visible,
.icon-btn:focus-visible, .sp-item:focus-visible, .card-link:focus-visible {
  outline: 2px solid var(--brand); outline-offset: 2px;
}
.sidebar .nav-item:focus-visible { outline-color: var(--brand-2); }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important; animation-iteration-count: 1 !important;
    transition-duration: .01ms !important; scroll-behavior: auto !important;
  }
}

/* ---------- 设置：顶部二级页签 + 内容 ---------- */
.set-tabs { margin-bottom: 18px; }
.set-tabs .tab { display: inline-flex; align-items: center; text-decoration: none; }
.set-body { min-width: 0; }
.set-body .page-head { margin-bottom: 16px; }

/* ============================================================
   登录同步进度覆盖层（独立挂载点，z-index 70）
   只使用 :root 既有令牌；色值字面量仅取视觉规范 §1.2/§1.3 指定值
   ============================================================ */
#syncOverlayRoot { position: relative; z-index: 70; }
.sync-overlay {
  position: fixed; inset: 0; z-index: 70;
  display: flex; align-items: center; justify-content: center; padding: 48px 24px;
  background:
    radial-gradient(900px 460px at 50% -12%, var(--glow), transparent 68%),
    rgba(15, 23, 42, .52);
  backdrop-filter: saturate(120%) blur(12px);
  -webkit-backdrop-filter: saturate(120%) blur(12px);
  animation: soFade .16s var(--ease);
}
@keyframes soFade { from { opacity: 0; } to { opacity: 1; } }
.sync-overlay [hidden] { display: none !important; }
.sync-overlay__panel {
  width: 100%; max-width: 880px; max-height: calc(100vh - 96px);
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: 0 24px 64px rgba(16, 24, 40, .18);
  display: flex; flex-direction: column; overflow: hidden;
  animation: pop .18s var(--ease);
}
.sync-overlay__panel:focus { outline: none; }
.sync-overlay__panel:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.sync-overlay__head { flex: none; padding: 20px 28px 16px; border-bottom: 1px solid var(--line); }
.sync-overlay__body { flex: 1 1 auto; min-height: 0; padding: 22px 28px 8px; display: flex; flex-direction: column; }
.sync-overlay__foot {
  flex: none; padding: 12px 28px 16px; border-top: 1px solid var(--line);
  background: var(--panel-2); display: flex; justify-content: flex-end; align-items: center; gap: 8px;
}
.sync-overlay__hint { margin-right: auto; font-size: var(--fs-caption); }
.sync-overlay__actions { display: flex; justify-content: flex-end; align-items: center; gap: 8px; flex-wrap: wrap; }
.sync-overlay__eyebrow { font-size: var(--fs-micro); color: var(--faint); letter-spacing: .12em; text-transform: uppercase; }
.sync-overlay__title-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.sync-overlay__title { margin: 0; font-size: var(--fs-h3); font-weight: 600; color: var(--text); }
.sync-overlay__live {
  width: 6px; height: 6px; border-radius: 50%; background: var(--brand);
  animation: halo-breathe 2s ease-in-out infinite;
}
.sync-overlay__title-row .mono { margin-left: auto; font-size: var(--fs-caption); }
.sync-overlay__banner.sync-banner { margin: 0 0 12px; }

/* 总进度：单列纵排（大数 → 光束 → 脚注），与下方阶段列表同宽 */
.sync-overlay .sync-total { display: block; }
.sync-total__lead { min-width: 0; }
.sync-overlay .sync-headline { display: flex; align-items: baseline; gap: 4px; flex-wrap: wrap; margin-top: 14px; }
.sync-total__value {
  font-family: var(--font-sans); font-size: var(--fs-hero-lg); font-weight: 650; line-height: .95;
  letter-spacing: -.03em; color: var(--text); font-variant-numeric: tabular-nums;
}
.sync-total__unit { font-size: var(--fs-h3); color: var(--muted); margin-left: 2px; }
.sync-total__caption { margin-left: 10px; font-size: var(--fs-label); color: var(--muted); }
.sync-total.is-unknown .sync-total__value, .sync-total.is-empty .sync-total__value {
  font-size: var(--fs-hero); color: var(--faint); letter-spacing: 0;
}
.sync-total__meter {
  height: 10px; border-radius: 999px; margin-top: 14px;
  background: var(--chart-track); overflow: hidden;
}
.sync-total__meter.is-unknown {
  background: repeating-linear-gradient(135deg, var(--chart-track) 0 6px, var(--line-strong) 6px 12px);
}
.sync-total__fill {
  display: block; height: 100%; border-radius: 999px;
  background: linear-gradient(90deg, var(--brand-2), var(--brand));
  box-shadow: 0 0 12px -1px var(--glow);
  transition: width .45s var(--ease);
}
.sync-total.is-empty .sync-total__fill { background: var(--chart-5); box-shadow: none; }
.sync-total.is-stalled .sync-total__meter {
  background: repeating-linear-gradient(135deg, var(--chart-track) 0 6px, var(--line-strong) 6px 12px);
}
.sync-total.is-stalled .sync-total__fill { opacity: .55; }
.sync-total__meta { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 10px; font-size: var(--fs-caption); color: var(--faint); }
.sync-total__meta b { font-weight: 500; }

/* 阶段列表（唯一滚动区） */
.sync-stage-list { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; position: relative; }
.sync-stage-list__head {
  flex: none; display: flex; justify-content: space-between; gap: 8px;
  padding-bottom: 8px; border-bottom: 1px solid var(--line);
  font-size: var(--fs-caption); color: var(--muted);
}
.sync-stage-list__scroll {
  flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain;
  scrollbar-width: thin; scrollbar-color: var(--line-strong) transparent;
}
.sync-stage-list__scroll::-webkit-scrollbar { width: 6px; }
.sync-stage-list__scroll::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 999px; }
.sync-stage-list__fade {
  position: absolute; left: 0; right: 0; bottom: 0; height: 24px;
  pointer-events: none; background: linear-gradient(transparent, var(--panel));
}
.sync-overlay .sync-stage {
  grid-template-columns: 24px minmax(0, 1fr); gap: 10px;
  padding: 10px 0; border-bottom: 1px solid var(--line);
}
.sync-overlay .sync-stage:last-child { border-bottom: 0; }
.sync-overlay .sync-stage.s-running { background: rgba(238, 242, 255, .55); }
.sync-overlay .sync-stage-mark { padding-top: 1px; }
.sync-overlay .sync-stage-name { font-size: var(--fs-label); }
.sync-overlay .sync-stage-time { margin-left: auto; }
.sync-overlay .sync-stage-foot { margin-top: 5px; }
.sync-overlay .sync-stage:focus { outline: none; }
.sync-overlay .sync-stage:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.sync-overlay .sync-stage.is-placeholder {
  display: block; height: 10px; padding: 0; border: 0; border-radius: 6px;
  background: var(--panel-2); opacity: .35;
}
.sync-overlay .sync-stage.is-placeholder > * { display: none; }
.sync-overlay .sync-stage-icon {
  width: 14px; height: 14px; flex: none; display: inline-flex;
  align-items: center; justify-content: center;
  font-family: var(--mono); font-size: var(--fs-caption); line-height: 1;
}
.sync-overlay .sync-stage-icon.is-spin {
  border: 2px solid var(--line); border-top-color: var(--brand); border-radius: 50%;
  animation: sd-spin .7s linear infinite;
}
.sync-overlay .sync-stage-icon[data-status="done"]::before { content: "✓"; color: var(--brand-2); }
.sync-overlay .sync-stage-icon[data-status="failed"]::before { content: "!"; color: var(--red); font-weight: 700; }
.sync-overlay .sync-stage-icon[data-status="pending"]::before { content: "○"; color: var(--faint); }
.sync-overlay .sync-stage-icon[data-status="skipped"]::before { content: "⊘"; color: var(--faint); }
.sync-overlay .sync-stage-icon[data-status="stalled"]::before { content: "‖"; color: var(--amber); font-weight: 700; }
.sync-overlay .sync-bar { height: 6px; margin-top: 6px; background: var(--chart-track); }
.sync-overlay .sync-bar.is-live {
  background: repeating-linear-gradient(135deg, var(--chart-track) 0 5px, var(--line-strong) 5px 10px);
}
.sync-overlay .sync-bar.is-empty > i { background: var(--chart-5); }
.sync-overlay .s-stalled .sync-bar {
  background: repeating-linear-gradient(135deg, var(--chart-track) 0 5px, var(--line-strong) 5px 10px);
}
.sync-overlay .s-stalled .sync-bar > i { background: var(--amber); opacity: .6; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* 断点沿用现有 1280 / 1080 / 900 / 760 / 600 体系 */
@media (max-width: 1280px) {
  .sync-overlay { padding: 40px; }
  .sync-overlay__panel { max-width: 820px; max-height: calc(100vh - 80px); }
}
@media (max-width: 1080px) {
  .sync-overlay__panel { max-width: 720px; }
}
@media (max-width: 900px) {
  .sync-overlay { padding: 20px; }
  .sync-overlay__panel { max-width: 640px; max-height: calc(100vh - 40px); }
  .sync-overlay__head { padding: 18px; }
  .sync-overlay__body { padding: 18px 18px 8px; }
  .sync-overlay__foot { padding: 12px 18px; }
  .sync-total__value { font-size: var(--fs-hero); }
  .sync-overlay .sync-stage-time { margin-left: 0; }
}
@media (max-width: 760px) {
  .sync-overlay { padding: 12px; }
  .sync-overlay__panel { max-width: 100%; max-height: calc(100vh - 24px); }
  .sync-overlay__head { padding: 14px; }
  .sync-overlay__body { padding: 14px 14px 6px; }
  .sync-overlay__foot { padding: 10px 14px 12px; }
  .sync-overlay__hint { display: none; }
  .sync-overlay .sync-stage { grid-template-columns: minmax(0, 1fr); gap: 6px; }
  .sync-overlay .sync-stage-mark { display: none; }
  .sync-overlay .sync-stage-time { margin-left: auto; }
}
@media (max-width: 600px) {
  .sync-overlay { padding: 8px; }
  .sync-overlay__panel { max-height: calc(100vh - 16px); }
  .sync-overlay__head { padding: 12px; }
  .sync-overlay__body { padding: 12px 12px 6px; }
  .sync-overlay__foot { padding: 10px 12px; }
  .sync-total__meta { gap: 8px; }
  .sync-overlay .sync-stage-time { margin-left: 0; }
}

/* ============================================================
   数据读取页 · 双栏看板（sv-* 只服务这一页，不与其他页面耦合）
   左栏汇总 + 数据源；右栏阶段明细表。
   全页只有一条总进度条；行内细条只出现在「读取中 / 失败」两态，
   避免 12 行各画一条长横线把页面划花。
   ============================================================ */
.sv-grid { display: grid; grid-template-columns: 296px minmax(0, 1fr); gap: 16px; align-items: start; }
.sv-banners { display: grid; gap: 8px; margin-bottom: 14px; }
.sv-banners .sync-banner { margin: 0; }

/* ---- 左栏 ---- */
.sv-side { padding: 20px 18px 16px; }
.sv-runstate { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.sv-runid { font-size: 12px; color: var(--faint); }
.sv-pct {
  margin-top: 14px; font-size: 50px; font-weight: 680; line-height: .9;
  letter-spacing: -.04em; font-variant-numeric: tabular-nums; color: var(--text);
}
.sv-pct small { font-size: 19px; font-weight: 500; color: var(--muted); margin-left: 2px; }
.sv-pct.is-unknown { font-size: 36px; font-weight: 500; color: var(--faint); letter-spacing: 0; }
.sv-cap { margin-top: 8px; font-size: 12.5px; color: var(--faint); }
.sv-track { height: 5px; border-radius: 99px; background: #eceff7; margin-top: 14px; overflow: hidden; }
.sv-track > i { display: block; height: 100%; border-radius: 99px;
  background: linear-gradient(90deg, #12968a, #0b6e64); transition: width .4s var(--ease); }
.sv-track.is-unknown { background: repeating-linear-gradient(135deg, #eceff7 0 6px, #e3e7f0 6px 12px); }
.sv-track.is-unknown > i { display: none; }

.sv-kv {
  display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 8px 12px;
  margin: 16px 0 0; padding-top: 14px; border-top: 1px solid var(--line); font-size: 12.5px;
}
.sv-kv dt { color: var(--faint); }
.sv-kv dd { margin: 0; text-align: right; color: var(--text-2);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sv-kv dd.is-bad { color: var(--red); font-weight: 600; }

.sv-src { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.sv-src h3 { margin: 0 0 10px; font-size: 12.5px; font-weight: 600; color: var(--faint); letter-spacing: .04em; }
.sv-src h3 .mono { color: #98a2b3; font-weight: 400; margin-left: 3px; }
.sv-src ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.sv-src li { display: flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--text-2); min-width: 0; }
.sv-src-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sv-src-state { margin-left: auto; color: #8b95a8; font-size: 12px; white-space: nowrap; }
.sv-src-empty { font-size: 12.5px; color: var(--red); }

/* ---- 右栏：明细表 ---- */
.sv-table { overflow: hidden; }
.sv-tbl { width: 100%; border-collapse: collapse; table-layout: fixed; }
.sv-tbl thead th {
  text-align: left; font-size: 12px; font-weight: 600; color: var(--faint);
  letter-spacing: .04em; padding: 10px 14px; background: var(--panel-2);
  border-bottom: 1px solid var(--line); white-space: nowrap;
}
.sv-tbl tbody td { padding: 10px 14px; border-bottom: 1px solid var(--line);
  font-size: 13.5px; vertical-align: middle; }
.sv-tbl tbody tr:last-child td { border-bottom: 0; }
.sv-tbl tbody tr:hover td { background: var(--panel-2); }
.sv-n { width: 34px; color: #98a2b3; font-family: var(--mono); font-size: 12px; }
.sv-name { position: relative; min-width: 0; }
.sv-name-t { font-weight: 600; font-size: 14px; color: var(--text); }
.sv-row.is-pending .sv-name-t, .sv-row.is-skipped .sv-name-t { font-weight: 400; color: var(--faint); }
.sv-name .sv-dot { display: inline-block; margin-right: 7px; vertical-align: 1px; }
.sv-src-line { display: block; margin: 2px 0 0 13px; font-size: 12px; color: #98a2b3;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sv-err { display: block; margin: 2px 0 0 13px; font-size: 12px; color: var(--red); }
.sv-mini { position: absolute; left: 14px; right: 14px; bottom: 4px; height: 3px;
  border-radius: 99px; background: #e8ecf5; overflow: hidden; }
.sv-mini > i { display: block; height: 100%; border-radius: 99px; background: var(--brand); }
.sv-row.is-failed .sv-mini > i { background: var(--red); }
.sv-row.is-running .sv-name { padding-bottom: 20px; }
/* 异常行左侧加一道色条，扫读时不必逐个读文字 */
.sv-row.is-running td:first-child { box-shadow: inset 2px 0 0 var(--brand); }
.sv-row.is-failed td:first-child { box-shadow: inset 2px 0 0 var(--red); }

.sv-tbl .sv-state { width: 88px; font-size: 12.5px; color: var(--faint); white-space: nowrap; }
.sv-tbl thead .sv-state { font-size: 12px; }
.sv-row.is-running .sv-state { color: var(--brand-deep); font-weight: 600; }
.sv-row.is-failed .sv-state { color: var(--red); }
.sv-tbl .sv-qty { width: 124px; text-align: right; font-size: 12.5px; color: var(--text-2);
  white-space: nowrap; font-variant-numeric: tabular-nums; }
.sv-tbl .sv-ms { width: 84px; text-align: right; font-size: 12.5px; color: #98a2b3; white-space: nowrap; }
.sv-tbl thead .sv-qty, .sv-tbl thead .sv-ms { font-size: 12px; }
.sv-row.is-pending .sv-qty, .sv-row.is-skipped .sv-qty { color: #9aa3b4; }

.sv-foot { display: flex; gap: 20px; flex-wrap: wrap; margin-top: 12px; font-size: 12.5px; color: #8b95a8; }
.sv-foot .mono { color: var(--muted); }

.sv-dot { width: 6px; height: 6px; border-radius: 50%; flex: none; }
.sv-dot.is-ok { background: var(--ok); }
.sv-dot.is-run { background: var(--brand); box-shadow: 0 0 0 3px rgba(11, 110, 100, .14); }
.sv-dot.is-bad { background: var(--red); }
.sv-dot.is-warn { background: #f79009; }
.sv-dot.is-idle { background: #c7cddb; }
.sv-dot.is-info { background: #2e90fa; }

@media (max-width: 1080px) {
  .sv-grid { grid-template-columns: minmax(0, 1fr); }
  .sv-src ul { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .sv-side { padding: 16px 14px 12px; }
  .sv-pct { font-size: 42px; }
  .sv-src ul { grid-template-columns: minmax(0, 1fr); }
  .sv-tbl thead th, .sv-tbl tbody td { padding: 9px 10px; }
  .sv-tbl .sv-ms, .sv-tbl thead .sv-ms { display: none; }
  .sv-tbl .sv-qty { width: 84px; }
  .sv-tbl .sv-state { width: 60px; }
  .sv-mini { left: 10px; right: 10px; }
}

/* ============================================================
   V1 白底钢蓝主题（2026-11-24）
   纯追加覆盖，不改动上方任何原始规则与 HTML 骨架。
   基准：白色界面小样_V1.html —— 白底 #FFFFFF + 亮钢蓝 #1A4BE0
   治四项症状：颜色乱（单一强调色）/ 土（零渐变零发光）/ 看不清（灰阶达标）/ 层级乱（1px 边框分层）
   语义色（红/琥珀/绿）保留，只表达状态；不碰布局尺寸、路由、接口。
   ============================================================ */
html:root {
  /* 表面：纯白底 */
  --bg: #ffffff;
  --panel: #ffffff;
  --panel-2: #f7f8fa;
  --panel-3: #f1f3f6;
  --line: #e5e7eb;
  --line-strong: #d6dae1;
  /* 文本：全部 ≥4.5:1（白底实测） */
  --text: #111111;
  --text-2: #3d4450;
  --muted: #596270;
  --faint: #6b7482;
  --ink: #111111;
  /* 强调：亮钢蓝单一色相 */
  --brand: #1a4be0;
  --brand-2: #3a67e8;
  --brand-deep: #1439ad;
  --brand-weak: #eef2ff;
  --brand-line: rgba(26, 75, 224, .18);
  --brand-line-strong: rgba(26, 75, 224, .35);
  --glow: rgba(26, 75, 224, .14);
  /* 语义：红/琥珀保留，绿用深绿保证白底可读 */
  --red: #b42318;
  --red-weak: #fef3f2;
  --red-line: #f4c7c3;
  --amber: #91560a;
  --amber-weak: #fffaeb;
  --amber-line: #fde3b5;
  --ok: #067647;
  --ok-weak: #ecfdf3;
  --ok-line: #c6e9d4;
  --purple: #6941c6;         /* 保留令牌兼容旧引用，但 V1 下不再用于新组件 */
  --purple-weak: #f4f3ff;
  /* 侧栏：浅色，靠边框分层 */
  --navy: #111111;
  --side-bg-1: #fcfcfd;
  --side-bg-2: #fcfcfd;
  --side-line: rgba(17, 17, 17, .09);
  --side-text: #3d4450;
  --side-text-2: #6b7482;
  --side-hover: #f1f3f6;
  --side-active: rgba(26, 75, 224, .10);
  /* 圆角统一：大 10 / 中 8 / 小 6 */
  --radius: 10px;
  /* 阴影：极轻，只给浮层 */
  --shadow: 0 1px 2px rgba(17, 17, 17, .04), 0 8px 20px -16px rgba(17, 17, 17, .18);
  --shadow-lift: 0 2px 6px rgba(17, 17, 17, .06), 0 14px 30px -18px rgba(17, 17, 17, .22);
  /* 图表：钢蓝单色阶 → 灰 → 中性 */
  --chart-1: #1a4be0;
  --chart-2: #3a67e8;
  --chart-3: #6f92f0;
  --chart-4: #a9bff8;
  --chart-5: #94a3b8;
  --chart-6: #cbd5e1;
  --chart-track: #eef1f5;
}

/* ---------- 侧栏：浅色，去渐变/网格/冷光条 ---------- */
html .sidebar {
  background: var(--side-bg-1);
  color: var(--side-text);
  border-right: 1px solid var(--side-line);
}
html .sidebar::before { display: none; }
html .brand-name { color: var(--text); }
html .brand-sub { color: var(--muted); }
html .logo {
  background: var(--brand);
  box-shadow: none;
  border-radius: 8px;
}
html .nav-group { color: var(--faint); letter-spacing: .12em; }
html .nav-group::after { background: linear-gradient(90deg, rgba(17,17,17,.12), transparent); }
html .nav-item { color: var(--side-text); border-radius: 8px; }
html .nav-item:hover { background: var(--side-hover); color: var(--text); }
html .nav-item.active {
  background: var(--side-active);
  color: var(--brand);
  box-shadow: inset 0 0 0 1px var(--brand-line);
}
html .nav-item.active::before { background: var(--brand); box-shadow: none; border-radius: 0 3px 3px 0; }
html .ni { color: var(--muted); }
html .nav-item:hover .ni { color: var(--text); }
html .nav-item.active .ni { color: var(--brand); }
html .nav::-webkit-scrollbar-thumb { background: rgba(17,17,17,.18); }
html .nav:hover::-webkit-scrollbar-thumb { background: rgba(17,17,17,.28); }
html .nav::-webkit-scrollbar-thumb:hover { background: rgba(17,17,17,.38); }
html .nav-tail { border-top-color: var(--side-line); }

/* ---------- 顶栏 ---------- */
html .topbar::after { background: var(--line); }
html .search-wrap input::placeholder { color: var(--faint); }
html .search-wrap input:hover { background: var(--panel-2); }
html .search-wrap input:focus {
  border-color: var(--brand);
  background: #fff;
  box-shadow: 0 0 0 3px var(--brand-line);
}

/* ---------- 登录页：浅色舞台，去双层径向渐变与网格 ---------- */
html .login-screen { background: #ffffff; }
html .login-screen::before, html .login-screen::after { display: none; }
html .login-stage {
  color: var(--text);
  background: #f7f8fa;
  border-right: 1px solid var(--line);
}
html .login-stage::before { display: none; }
html .ls-name { color: var(--text); }
html .ls-sub { color: var(--muted); }
html .ls-eyebrow { color: var(--brand); }
html .ls-title { color: var(--text); }
html .ls-desc { color: var(--text-2); }
html .ls-mods { border-top-color: var(--line); }
html .ls-mods li { color: var(--text-2); border-bottom-color: var(--line); }
html .ls-mods li i { background: var(--brand); box-shadow: 0 0 0 3px var(--brand-line); }
html .ls-mods li span { color: var(--muted); }
html .ls-foot { color: var(--muted); }
html .ls-live { background: var(--brand); box-shadow: 0 0 0 3px var(--brand-line); }
html .ls-brand .login-logo { box-shadow: none; }
html .login-card { border-radius: 10px; box-shadow: var(--shadow); }
html .login-card::before { background: var(--brand); height: 2px; }
html .login-field input { background: #fff; }
html .login-field input:hover { border-color: var(--line-strong); }
html .login-submit { border-radius: 8px; }

/* ---------- 通用组件：灭渐变发光，边框分层 ---------- */
html .card { border: 1px solid var(--line); border-radius: var(--radius); box-shadow: none; }
html .card-title { color: var(--text); font-weight: 600; }
html .card-link { color: var(--brand); }
html .btn { border-radius: 8px; box-shadow: none; }
html .btn:hover { box-shadow: none; background: var(--panel-2); }
html .btn.primary {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
  box-shadow: none;
}
html .btn.primary:hover { background: var(--brand-deep); border-color: var(--brand-deep); box-shadow: none; }
html .login-submit,
html .sync-overlay .btn.primary { background: var(--brand); border-color: var(--brand); box-shadow: none; }
html .badge.blue { background: var(--brand-weak); color: var(--brand); }
html .badge.green { background: var(--ok-weak); color: var(--ok); box-shadow: none; }
html .badge.purple { background: var(--brand-weak); color: var(--brand); }

/* KPI：无彩色左条、无光晕，纯白卡 + 1px 边框 */
html .kpi { background: var(--panel); border: 1px solid var(--line); box-shadow: none; }
html .kpi::before, html .kpi::after { display: none !important; }
html .kpi-label { color: var(--muted); }
html .kpi-value { color: var(--text); text-shadow: none; }
html .kpi-value small, html .kpi-foot, html .kpi-sub { color: var(--faint); }

/* 表格：透明表头、细分隔线，去掉彩色状态点的杂色 */
html .tbl th { background: transparent; color: var(--muted); }
html .tbl td { border-bottom-color: var(--line); }
html .tbl tbody tr.clickable:hover { background: var(--panel-2); }
html .status.new::before, html .status.rolled_back::before { background: var(--red); }
html .status.assigned::before, html .status.pending_approval::before, html .status.delayed::before { background: var(--amber); }
html .status.in_progress::before, html .status.approved::before,
html .status.submitted::before, html .status.accepted::before, html .status.pending_confirm::before { background: var(--brand); }
html .status.implementing::before { background: var(--brand-2); }
html .status.resolved::before, html .status.completed::before { background: var(--ok); }
html .status.hold::before, html .status.closed::before, html .status.cancelled::before,
html .status.rejected::before { background: var(--faint); }

/* 进度条 / 步骤条 / 光晕：收敛为钢蓝实色，去流光去发光 */
html .bar-fill,
html .progress > i,
html .steps i.on,
html .rep-steps i.on,
html .sync-meter > i,
html .sync-bar > i,
html .sv-track > i { background: var(--brand); box-shadow: none; }
html .sync-meter.is-unknown,
html .sync-bar.is-live,
html .sv-track.is-unknown { background: var(--panel-3); }

/* 模态 / 抽屉：1px 边框 + 极轻阴影 */
html .modal { border: 1px solid var(--line); box-shadow: var(--shadow-lift); border-radius: var(--radius); }

/* 数据读取页 sv-* 的杂色收敛 */
html .sv-dot.is-info { background: var(--brand); }
html .sv-dot.is-warn { background: var(--amber); }
html .sv-dot.is-run { box-shadow: 0 0 0 3px var(--brand-line); }
html .sv-tbl .sv-ms,
html .sv-src h3 .mono,
html .sv-n,
html .sv-src-line,
html .sv-row.is-pending .sv-qty,
html .sv-row.is-skipped .sv-qty,
html .sv-foot { color: var(--faint); }

/* 读取已结束但没收到完成回执：中性灰，别用红色冒充失败 */
html .sv-row.is-unreported .sv-state { color: var(--amber); }
html .sync-stage.s-unreported .sync-bar { opacity: .4; }
html .sync-stage.s-unreported .sync-bar > i { background: #98a2b3; }

/* 全局：清除所有遗留青碧/靛紫硬编码（登录页舞台与覆盖层已单独处理） */
html .ev-slide.is-active::before { background: var(--red); box-shadow: none; }
html .ev-slide.is-recovered::before { background: var(--ok); box-shadow: none; }
html .port-card.has-p1 { box-shadow: inset 3px 0 0 var(--red); background: var(--panel); }
html .port-card:hover { border-color: var(--brand-line); box-shadow: var(--shadow-lift); }

/* ---------- V1 钢蓝：补齐遗漏的青绿残留 ---------- */
html .main { background: var(--bg); }
html .avatar { background: var(--brand); box-shadow: none; }
html .dash-title {
  color: var(--text);
  background: none;
  -webkit-text-fill-color: currentColor;
}
html .dash-title::after { background: var(--brand); box-shadow: none; }
html .tab.active { background: var(--brand-weak); }
html .input:focus, html select.input:focus { box-shadow: 0 0 0 3px var(--brand-line); }
html .ev-card::before, html .ev-card::after { border-color: var(--brand-line-strong); }
html .delv-month.is-current { border-color: var(--brand-line-strong); }
html .sync-live::before { box-shadow: 0 0 0 3px var(--brand-line); }

/* ---------- 登录同步覆盖层：浅色主题 + 阶段平铺（无内嵌滚动） ---------- */
html .sync-overlay {
  background: rgba(247, 248, 250, .88);
  backdrop-filter: saturate(120%) blur(12px);
  -webkit-backdrop-filter: saturate(120%) blur(12px);
  padding: 20px 24px;
}
html .sync-overlay__panel {
  max-width: 1120px;
  max-height: calc(100vh - 40px);
  overflow-y: auto;
  box-shadow: 0 24px 64px rgba(16, 24, 40, .16);
}
html .sync-overlay__head { padding: 14px 24px 10px; }
html .sync-overlay__body { flex: none; padding: 12px 24px 4px; }
html .sync-overlay .sync-headline { margin-top: 8px; }
html .sync-overlay .sync-total__value { font-size: clamp(38px, 3.6vw, 46px); }
html .sync-overlay .sync-total__meter { margin-top: 10px; }
html .sync-overlay .sync-total__meta { margin-top: 6px; }
html .sync-overlay .sync-stage-list { flex: none; }
html .sync-stage-list__scroll {
  overflow: visible;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 28px;
  align-content: start;
}
html .sync-stage-list__fade { display: none; }
html .sync-stage-list__head { padding-bottom: 6px; }
html .sync-overlay .sync-stage-list__count { color: var(--muted); font-size: 12.5px; }
html .sync-overlay .sync-stage-list__count b { color: var(--text); font-weight: 600; }
html .sync-stage-list__flags { display: inline-flex; align-items: center; gap: 6px; }
html .sync-flag {
  display: inline-flex; align-items: center; gap: 5px;
  height: 18px; padding: 0 8px; border-radius: 999px;
  font-size: 12px; line-height: 1; color: var(--muted);
  background: rgba(93, 106, 126, .08);
}
html .sync-flag b { color: var(--text-2); font-weight: 600; }
html .sync-flag.is-bad { background: var(--red-weak); color: var(--red); }
html .sync-flag.is-bad b { color: var(--red); }
html .sync-total__meta-item { display: inline-flex; align-items: baseline; gap: 6px; }
html .sync-overlay .sync-total__meta-item b { color: var(--text-2); }
html .sync-total__meta-k { color: var(--faint); }
html .sync-overlay .sync-stage {
  padding: 6px 6px 7px;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
}
html .sync-overlay .sync-stage.s-running {
  background: var(--brand-weak);
  border-radius: 6px;
}
html .sync-overlay .sync-stage-name { font-size: 14px; }
html .sync-overlay .sync-stage-foot { margin-top: 3px; gap: 10px; }
@media (max-width: 900px) {
  html .sync-stage-list__scroll { grid-template-columns: minmax(0, 1fr); }
}

/* ============================================================
   iOS 浅色毛玻璃 · 登录同步覆盖层（2026-11-24）
   用户选定档：iOS 浅色毛玻璃（小样 F 档）。仅换材质，不动 DOM/状态机/布局尺寸/两列平铺。
   对比度实算（白62%叠淡紫光斑底）：正文16.9 / 次5.45 / 蓝5.94 / 绿5.03，全过 AA。
   选择器特异性对齐现有 html .sync-overlay 块，后置覆盖。
   ============================================================ */
/* 遮罩：三层彩色光斑当模糊源 + 强饱和增强（iOS vibrancy） */
html .sync-overlay {
  background:
    radial-gradient(700px 460px at 12% 6%, rgba(227,212,240,.85), transparent 66%),
    radial-gradient(620px 440px at 92% 94%, rgba(207,224,242,.85), transparent 64%),
    radial-gradient(520px 380px at 78% 12%, rgba(217,230,245,.70), transparent 62%),
    linear-gradient(160deg, rgba(240,238,248,.90), rgba(232,240,250,.90));
  backdrop-filter: blur(30px) saturate(180%);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
}
/* 面板：白 62% 高通透 + 强模糊 + 0.5px 白高光边 + 顶部内高光 + 18px 圆角 */
html .sync-overlay__panel {
  background: rgba(255,255,255,.62);
  border: 0.5px solid rgba(255,255,255,.7);
  border-radius: 18px;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.85),
    inset 0 0 0 0.5px rgba(255,255,255,.5),
    0 24px 70px -20px rgba(70,60,110,.28),
    0 6px 18px -10px rgba(70,60,110,.18);
  backdrop-filter: blur(28px) saturate(170%);
  -webkit-backdrop-filter: blur(28px) saturate(170%);
}
/* 分层材质：页眉页脚半透明，比正文更透 */
html .sync-overlay__head {
  background: rgba(255,255,255,.30);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
}
html .sync-overlay__foot {
  background: rgba(255,255,255,.36);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
}
/* 轨道在玻璃上要看得见：中性半透明槽 */
html .sync-overlay .sync-total__meter,
html .sync-overlay .sync-bar,
html .sync-overlay .sync-meter { background: rgba(80,90,120,.14); }
html .sync-overlay .sync-total__meter.is-unknown,
html .sync-overlay .sync-bar.is-live { background: repeating-linear-gradient(135deg, rgba(80,90,120,.14) 0 6px, rgba(80,90,120,.22) 6px 12px); }
/* 阶段行在玻璃面板上：hover/选中态用低透明底，避免糊成白块 */
html .sync-overlay .sync-stage.s-running { background: rgba(26,75,224,.08); }

/* 故障统计看板：4 核心数 + 近 14 天摘要 */
.fault-stat .card-head { padding-bottom: 4px; }
.fault-stat .card-body { padding-top: 6px; }
.stat-kpis { gap: 12px; margin-bottom: 16px; }
.stat-kpis .kpi { padding: 14px 16px 12px; }
.kpi-value.is-open { color: var(--red); text-shadow: none; }
.kpi-value.is-closed { color: var(--brand-2); text-shadow: none; }
/* 近 14 天摘要：一行小指标，不做图 */
.fault-sum {
  display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px 22px;
  padding: 11px 16px;
  background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px;
  font-size: var(--fs-caption); color: var(--muted);
}
.fault-sum-label { font-weight: 600; color: var(--text); letter-spacing: .04em; }
.fault-sum-item b { color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; margin: 0 1px; }
.fault-sum-item small { color: var(--faint); margin-left: 2px; }
.fault-sum-item.is-up b { color: var(--red); }
.fault-sum-item.is-down b { color: var(--brand-2); }
html .kpi-value.is-open { color: var(--red); }
html .kpi-value.is-closed { color: var(--brand-2); }
