/* ── 工业控制台暗色主题 v2（对齐 HL-3 主机厅系统视觉） ── */
    /* 主背景不用纯黑（#10141c ≈ #121212 亮度，冷调），模块两级更亮的深色分层；
       主色仅「蓝 + 紫」两族，绿/琥珀/粉仅作状态语义色；边缘 FFFFFF 6% 微光 */
    :root {
      --hl-bg: #10141c;
      --hl-panel: rgba(34, 40, 51, 0.94);
      --hl-panel-2: rgba(47, 54, 68, 0.96);
      --hl-line: rgba(158, 182, 214, 0.2);
      --hl-line-2: rgba(158, 182, 214, 0.38);
      --hl-fg: #eef3fa;
      --hl-fg-2: #e4edf9;
      --hl-muted: #d3dfee;
      --hl-cyan: #38bdf8;
      --hl-ok: #34d399;
      --hl-warn: #fbbf24;
      --hl-danger: #ff93a4;
      --hl-violet: #bfb3ff;
      --hl-cyan-tx: #b3e6fc;
      --hl-ok-tx: #afeed7;
      --hl-warn-tx: #fdde8e;
      --hl-danger-tx: #ffcfd6;
      --hl-violet-tx: #d0c7ff;
      --hl-sep: rgba(158, 182, 214, 0.78);
      --hl-radius: 16px;

      --ss-bg: #10141c;
      --ss-fg: #eef3fa;
      --ss-muted: #d3dfee;
      --ss-border: rgba(158, 182, 214, 0.2);
      --ss-card: #1c2029;
      --ss-card-fg: #eef3fa;
      --ss-primary: #38bdf8;
      --ss-primary-fg: #04121f;
      --ss-danger: #ff93a4;
      --ss-radius: 16px;
    }

    body {
      min-height: 100vh;
      background:
        radial-gradient(1100px 560px at 82% -12%, rgba(56, 189, 248, 0.09), transparent 62%),
        radial-gradient(900px 520px at -8% 104%, rgba(167, 139, 250, 0.081), transparent 60%),
        var(--hl-bg);
      color: var(--hl-fg);
      font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Segoe UI", sans-serif;
      font-size: 14px;
      line-height: 1.55;
    }
    h1, h2, h3, h4 { margin: 0; font-weight: 650; letter-spacing: 0.01em; }
    p { margin: 0; }
    button { font-family: inherit; }
    /* hidden 属性优先（否则 .boot/.shell 的 display:flex 会盖掉 UA 的 display:none） */
    [hidden] { display: none !important; }

    /* ── 启动屏 ── */
    .boot {
      position: fixed; inset: 0; z-index: 90;
      display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px;
      background:
        radial-gradient(700px 380px at 50% 30%, rgba(56, 189, 248, 0.144), transparent 68%),
        var(--hl-bg);
    }
    .boot-mark {
      font-size: 42px; font-weight: 800; letter-spacing: 0.16em;
      color: #dff2ff; text-shadow: 0 0 34px rgba(56, 189, 248, 0.55);
    }
    .boot-title { color: var(--hl-fg-2); font-size: 15px; letter-spacing: 0.08em; }
    .boot-bar { width: 168px; height: 3px; border-radius: 99px; background: rgba(125, 175, 230, 0.16); overflow: hidden; }
    .boot-bar > span { display: block; width: 40%; height: 100%; border-radius: 99px; background: linear-gradient(90deg, transparent, var(--hl-cyan)); animation: bootRun 1.2s ease-in-out infinite; }
    @keyframes bootRun { 0% { transform: translateX(-110%); } 100% { transform: translateX(320%); } }
    .boot-hint { color: var(--hl-muted); font-size: 12.5px; }

    /* ── 骨架布局 ── */
    .shell { display: flex; min-height: 100vh; }
    .sidebar {
      flex: 0 0 236px; width: 236px;
      display: flex; flex-direction: column; gap: 20px;
      padding: 22px 16px 18px;
      border-right: 1px solid var(--hl-line);
      background: linear-gradient(180deg, rgba(25, 35, 50, 0.94), rgba(22, 26, 34, 0.94));
      position: sticky; top: 0; height: 100vh;
    }
    .brand { display: flex; align-items: center; gap: 11px; }
    .brand-mark {
      width: 44px; height: 44px; flex: 0 0 44px; border-radius: 13px;
      display: grid; place-items: center;
      font-weight: 800; font-size: 13px; letter-spacing: 0.04em; color: #04121f;
      background: linear-gradient(135deg, #7dd3fc, #38bdf8 55%, #22d3ee);
      box-shadow: 0 8px 22px rgba(56, 189, 248, 0.32);
    }
    .brand-text { display: flex; flex-direction: column; line-height: 1.3; min-width: 0; }
    .brand-text strong { font-size: 13.5px; }
    .brand-text span { font-size: 11.5px; color: var(--hl-muted); }

    .nav { display: flex; flex-direction: column; gap: 6px; }
    .nav-item {
      display: flex; align-items: center; gap: 10px;
      padding: 11px 12px; min-height: 44px;
      border: 1px solid transparent; border-radius: 12px;
      background: transparent; color: var(--hl-fg-2);
      font-size: 13.5px; text-align: left; cursor: pointer;
      transition: background 0.18s, border-color 0.18s, color 0.18s;
    }
    .nav-item svg { width: 18px; height: 18px; flex: 0 0 18px; opacity: 0.9; }
    .nav-item:hover { background: rgba(125, 175, 230, 0.08); color: var(--hl-fg); }
    .nav-item.is-active {
      background: linear-gradient(120deg, rgba(56, 189, 248, 0.18), rgba(56, 189, 248, 0.06));
      border-color: rgba(56, 189, 248, 0.36); color: #eaf7ff;
      box-shadow: inset 0 0 0 1px rgba(56, 189, 248, 0.06);
    }
    .nav-badge {
      margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px;
      border-radius: 99px; font-style: normal; font-size: 11px; font-weight: 700;
      display: grid; place-items: center;
      background: rgba(251, 191, 36, 0.18); color: var(--hl-warn-tx);
    }
    .nav-badge:empty { display: none; }

    /* ── 当前模块 / 跨页切换 ── */
    .mod-card {
      display: flex; flex-direction: column; gap: 8px;
      padding: 13px 13px 14px; border-radius: 14px;
      border: 1px solid rgba(56, 189, 248, 0.3);
      background: linear-gradient(150deg, rgba(56, 189, 248, 0.16), rgba(56, 189, 248, 0.04));
    }
    .mod-label { font-size: 11px; color: var(--hl-muted); letter-spacing: 0.08em; }
    .mod-name { font-size: 15px; font-weight: 750; color: #eaf7ff; line-height: 1.3; }
    .mod-switch { width: 100%; margin-top: 2px; text-decoration: none; }
    .mod-pill {
      flex: 1 1 auto; display: flex; align-items: center;
      font-size: 12.5px; color: var(--hl-fg-2); padding-left: 4px;
      white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
    }
    a.btn { text-decoration: none; }

    .side-card {
      margin-top: auto;
      padding: 13px 13px 14px; border-radius: 14px;
      border: 1px solid var(--hl-line); background: rgba(24, 32, 44, 0.7);
    }
    .side-card-title { font-size: 12.5px; font-weight: 650; color: var(--hl-fg-2); margin-bottom: 6px; }
    .side-card p { font-size: 11.5px; line-height: 1.6; color: var(--hl-muted); }
    .sync-line { display: flex; align-items: center; gap: 7px; margin-top: 9px; font-size: 11.5px; color: var(--hl-ok-tx); }
    .side-foot { font-size: 11px; color: rgba(180, 198, 220, 0.95); }

    .dot { width: 7px; height: 7px; border-radius: 99px; background: var(--hl-ok); flex: 0 0 7px; }
    .dot.is-live { animation: pulse 1.8s ease-in-out infinite; }
    @keyframes pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.5); } 50% { box-shadow: 0 0 0 5px rgba(52, 211, 153, 0); } }

    .main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
    .topbar {
      display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
      padding: 18px 22px 14px;
      border-bottom: 1px solid var(--hl-line);
      backdrop-filter: blur(8px);
      position: sticky; top: 0; z-index: 20;
      background: rgba(22, 26, 34, 0.72);
    }
    .topbar-main { min-width: 0; }
    .topbar h1 { font-size: 18px; letter-spacing: 0.02em; }
    .topbar p { font-size: 12px; color: var(--hl-muted); margin-top: 3px; }
    .topbar-actions { margin-left: auto; display: flex; align-items: center; gap: 10px; }
    .sync-pill {
      display: inline-flex; align-items: center; gap: 7px;
      padding: 6px 11px; border-radius: 99px; font-size: 11.5px;
      color: var(--hl-ok-tx); background: rgba(52, 211, 153, 0.1);
      border: 1px solid rgba(52, 211, 153, 0.28); white-space: nowrap;
    }
    .btn {
      display: inline-flex; align-items: center; justify-content: center; gap: 6px;
      min-height: 38px; padding: 0 14px; border-radius: 10px;
      border: 1px solid var(--hl-line-2); background: rgba(32, 45, 64, 0.8);
      color: var(--hl-fg-2); font-size: 13px; cursor: pointer;
      transition: transform 0.12s, background 0.18s, border-color 0.18s, opacity 0.18s;
    }
    .btn:hover { background: rgba(30, 48, 72, 0.9); color: var(--hl-fg); }
    .btn:active { transform: translateY(1px); }
    .btn:disabled { opacity: 0.55; cursor: not-allowed; }
    .btn.ghost { background: transparent; }
    .btn.primary {
      border-color: transparent; color: #04121f; font-weight: 700;
      background: linear-gradient(120deg, #7dd3fc, #38bdf8 60%, #22d3ee);
      box-shadow: 0 8px 20px rgba(56, 189, 248, 0.28);
    }
    .btn.primary:hover { color: #04121f; filter: brightness(1.05); }
    .btn.danger { border-color: rgba(251, 113, 133, 0.45); color: #ffd9df; background: rgba(251, 113, 133, 0.16); }
    .btn.ok { border-color: rgba(52, 211, 153, 0.42); color: #ccfbe8; background: rgba(52, 211, 153, 0.14); }
    .btn.sm { min-height: 34px; padding: 0 11px; font-size: 12.5px; border-radius: 9px; }

    .content { padding: 18px 22px 96px; }
    .view { display: none; }
    .view.is-active { display: block; animation: fadeUp 0.28s ease; }
    @keyframes fadeUp { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

    /* ── 卡片 ── */
    .card {
      border: 1px solid var(--hl-line); border-radius: var(--hl-radius);
      background: var(--hl-panel);
      box-shadow: 0 14px 34px rgba(2, 6, 14, 0.36);
      padding: 16px 16px 18px;
      min-width: 0;
    }
    .card-head { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
    .card-head h2 { font-size: 14px; }
    .card-hint { font-size: 11.5px; color: var(--hl-muted); margin-left: auto; }
    .sort-tag {
      display: inline-flex; align-items: center; gap: 4px;
      padding: 2px 9px; border-radius: 99px; font-size: 11px; font-weight: 600;
      color: var(--hl-cyan-tx); background: rgba(56, 189, 248, 0.12);
      border: 1px solid rgba(56, 189, 248, 0.28); white-space: nowrap;
    }
    .sort-tag::before { content: "\2191"; font-size: 10.5px; opacity: 0.9; }

    /* ── 待闭环任务：快速检索 ── */
    .closure-head { align-items: center; }
    .closure-head .card-hint { margin-left: auto; }
    .closure-search { position: relative; flex: 0 1 300px; min-width: 168px; }
    .closure-search input {
      width: 100%; height: 32px; padding: 0 28px 0 30px;
      border-radius: 9px; border: 1px solid var(--hl-line-2);
      background: rgba(21, 27, 37, 0.72); color: var(--hl-fg);
      font-size: 13px; font-family: inherit; line-height: 1.2;
      -webkit-appearance: none; appearance: none;
      transition: border-color 0.18s, box-shadow 0.18s;
    }
    .closure-search input::placeholder { color: var(--hl-muted); }
    .closure-search input:focus {
      outline: none; border-color: rgba(56, 189, 248, 0.66);
      box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.13);
    }
    .closure-search input::-webkit-search-cancel-button { display: none; }
    .closure-search::before {
      content: "\2315"; position: absolute; left: 9px; top: 50%;
      transform: translateY(-50%); font-size: 15px; line-height: 1;
      color: var(--hl-muted); pointer-events: none;
    }
    .closure-search .cs-clear {
      position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
      width: 22px; height: 22px; padding: 0; border: 0; border-radius: 50%;
      display: grid; place-items: center; cursor: pointer;
      background: rgba(148, 163, 184, 0.18); color: var(--hl-fg-2);
      font-size: 13px; line-height: 1;
    }
    .closure-search .cs-clear:hover { background: rgba(148, 163, 184, 0.32); }
    .kw-hit {
      background: rgba(250, 204, 21, 0.26); color: #fde68a;
      border-radius: 3px; padding: 0 1px;
    }
    html[data-theme="light"] .kw-hit { background: rgba(250, 204, 21, 0.5); color: #7a4a03; }

    /* 超期清单：单项闭环填报跳转 */
    .od-item .od-go { flex: 0 0 auto; white-space: nowrap; }
    .od-item .od-go[disabled] { opacity: 0.55; cursor: not-allowed; }
    .od-deny { font-size: 11px; color: #fca5a5; line-height: 1.4; }
    html[data-theme="light"] .od-deny { color: #b91c1c; }
    @media (max-width: 640px) {
      .od-item { flex-wrap: wrap; }
      .od-item .od-main { flex: 1 1 100%; }
      .od-item .od-go { margin-left: auto; }
    }
    @media (max-width: 900px) {
      .closure-head .card-hint { order: 2; margin-left: auto; }
      .closure-search { order: 3; flex: 1 1 100%; min-width: 0; }
      .closure-search input { height: 38px; font-size: 14px; }
    }

    .layout-2 { display: grid; grid-template-columns: 1fr; gap: 14px; }
    .layout-2 + .layout-2 { margin-top: 14px; }

    /* ── 表单 ── */
    .form { display: grid; grid-template-columns: 1fr; gap: 12px; }
    .field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
    .field > span, .field > label { font-size: 12px; color: var(--hl-muted); }
    .field i { color: var(--hl-danger-tx); font-style: normal; }
    .field input, .field select, .field textarea {
      width: 100%; padding: 10px 11px; border-radius: 10px;
      border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.78);
      color: var(--hl-fg); font-size: 16px; font-family: inherit;
      transition: border-color 0.18s, box-shadow 0.18s;
      -webkit-appearance: none; appearance: none;
    }
    .field textarea { resize: vertical; line-height: 1.6; }
    .field input::placeholder, .field textarea::placeholder { color: rgba(168, 188, 212, 0.9); }
    .field input:focus, .field select:focus, .field textarea:focus {
      outline: none; border-color: rgba(56, 189, 248, 0.7);
      box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.16);
    }
    .field select {
      background-image: linear-gradient(45deg, transparent 50%, var(--hl-muted) 50%), linear-gradient(135deg, var(--hl-muted) 50%, transparent 50%);
      background-position: calc(100% - 17px) calc(50% + 1px), calc(100% - 12px) calc(50% + 1px);
      background-size: 5px 5px, 5px 5px; background-repeat: no-repeat;
      padding-right: 32px;
    }
    .field select option { background: #0f1928; color: var(--hl-fg); }
    .form-foot { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 4px; }
    .form-note { font-size: 11.5px; color: var(--hl-muted); }
    .form-foot .btn { flex: 1 1 160px; }

    /* ── 任务卡片列表 ── */
    .task-list { display: flex; flex-direction: column; gap: 10px; max-height: 640px; overflow-y: auto; padding-right: 2px; }
    .task-item {
      border: 1px solid var(--hl-line); border-radius: 13px;
      background: rgba(24, 32, 44, 0.72); padding: 12px 13px;
      transition: border-color 0.18s, transform 0.18s;
    }
    .task-item:hover { border-color: var(--hl-line-2); transform: translateY(-1px); }
    .task-top { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
    .task-code { font-size: 11px; color: var(--hl-muted); letter-spacing: 0.04em; font-variant-numeric: tabular-nums; }
    .task-name { font-size: 13.5px; line-height: 1.45; }
    .task-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; font-size: 11.5px; color: var(--hl-muted); margin-top: 5px; }
    .task-meta i { font-style: normal; opacity: 0.5; }
    .task-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
    .chip {
      padding: 2px 9px; border-radius: 99px; font-size: 11px; font-weight: 650;
      border: 1px solid transparent; white-space: nowrap;
    }
    .chip.warn { color: var(--hl-warn-tx); background: rgba(251, 191, 36, 0.09); border-color: rgba(251, 191, 36, 0.32); }
    .chip.ok { color: var(--hl-ok-tx); background: rgba(52, 211, 153, 0.09); border-color: rgba(52, 211, 153, 0.32); }
    .chip.danger { color: var(--hl-danger-tx); background: rgba(251, 113, 133, 0.09); border-color: rgba(251, 113, 133, 0.32); }
    .chip.info { color: var(--hl-cyan-tx); background: rgba(56, 189, 248, 0.09); border-color: rgba(56, 189, 248, 0.32); }
    .chip.plain { color: var(--hl-muted); background: rgba(125, 175, 230, 0.08); border-color: var(--hl-line); }
    .task-opinion {
      margin-top: 9px; padding: 8px 10px; border-radius: 10px;
      font-size: 11.5px; line-height: 1.6; color: var(--hl-fg-2);
      background: rgba(125, 175, 230, 0.07); border-left: 2px solid rgba(56, 189, 248, 0.5);
    }
    .task-opinion b { color: var(--hl-fg); font-weight: 650; }

    .empty { padding: 26px 14px; text-align: center; color: var(--hl-muted); font-size: 12.5px; }
    .empty strong { display: block; color: var(--hl-fg-2); font-size: 13px; margin-bottom: 4px; }

    /* ── KPI ── */
    .kpi-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; margin-bottom: 14px; }
    .kpi {
      position: relative; overflow: hidden;
      border: 1px solid var(--hl-line); border-radius: 14px;
      background: var(--hl-panel); padding: 13px 14px 14px;
    }
    .kpi::after { content: ""; position: absolute; left: 0; top: 0; width: 3px; height: 100%; background: var(--hl-cyan); opacity: 0.85; }
    .kpi.warn::after { background: var(--hl-warn); }
    .kpi.ok::after { background: var(--hl-ok); }
    .kpi.danger::after { background: var(--hl-danger); }
    .kpi.info::after { background: var(--hl-cyan); }
    .kpi.violet::after { background: var(--hl-violet); }
    .kpi-label { font-size: 11.5px; color: var(--hl-muted); }
    .kpi-value { font-size: 24px; font-weight: 750; line-height: 1.25; margin-top: 4px; font-variant-numeric: tabular-nums; }
    .kpi-sub { font-size: 11px; color: var(--hl-muted); margin-top: 2px; }

    /* ── 图表 ── */
    .chart-grid { display: grid; grid-template-columns: 1fr; gap: 14px; margin-bottom: 14px; }
    .donut-wrap { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
    .donut { width: 148px; height: 148px; flex: 0 0 148px; }
    .donut-total { fill: var(--hl-fg); font-size: 22px; font-weight: 750; }
    .donut-sub { fill: var(--hl-muted); font-size: 10px; }
    .legend { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; flex: 1 1 140px; min-width: 140px; }
    .legend li { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--hl-fg-2); }
    .legend .dot { width: 8px; height: 8px; flex: 0 0 8px; }
    .legend .lg-name { flex: 1 1 auto; }
    .legend .lg-val { font-variant-numeric: tabular-nums; color: var(--hl-fg); font-weight: 650; }
    .legend .lg-pct { width: 38px; text-align: right; color: var(--hl-muted); font-variant-numeric: tabular-nums; }

    .bars { display: flex; flex-direction: column; gap: 10px; }
    .bar-row { display: grid; grid-template-columns: 78px 1fr 30px; align-items: center; gap: 9px; font-size: 12px; }
    .bar-label { color: var(--hl-fg-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .bar-track { height: 9px; border-radius: 99px; background: rgba(125, 175, 230, 0.12); overflow: hidden; }
    .bar-fill { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, rgba(56, 189, 248, 0.55), #38bdf8); transition: width 0.5s ease; }
    .bar-value { text-align: right; color: var(--hl-fg); font-variant-numeric: tabular-nums; font-weight: 650; }

    .trend { width: 100%; height: auto; display: block; }
    .trend-dot { fill: #04121f; stroke: #38bdf8; stroke-width: 2; }
    .trend-labels { display: flex; justify-content: space-between; margin-top: 4px; font-size: 10.5px; color: var(--hl-muted); font-variant-numeric: tabular-nums; }

    /* ── 队列 / 时间线 ── */
    .seg { display: inline-flex; gap: 4px; padding: 3px; border-radius: 10px; background: rgba(125, 175, 230, 0.08); flex-wrap: wrap; }
    .seg-item {
      border: 0; background: transparent; color: var(--hl-muted);
      padding: 6px 10px; border-radius: 8px; font-size: 12px; cursor: pointer;
      display: inline-flex; align-items: center; gap: 5px; min-height: 32px;
    }
    .seg-item i { font-style: normal; font-size: 10.5px; opacity: 0.85; font-variant-numeric: tabular-nums; }
    .seg-item.is-active { background: rgba(56, 189, 248, 0.18); color: #eaf7ff; box-shadow: inset 0 0 0 1px rgba(56, 189, 248, 0.32); }

    .queue { display: flex; flex-direction: column; gap: 10px; max-height: 520px; overflow-y: auto; }
    .queue-item {
      display: flex; gap: 10px; align-items: flex-start; flex-wrap: wrap;
      padding: 11px 12px; border-radius: 12px;
      border: 1px solid var(--hl-line); background: rgba(24, 32, 44, 0.7);
    }
    .queue-main { flex: 1 1 200px; min-width: 0; }
    .queue-title { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 13px; font-weight: 600; }
    .queue-meta { font-size: 11.5px; color: var(--hl-muted); margin-top: 4px; }
    .queue-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

    .timeline { display: flex; flex-direction: column; gap: 0; }
    .tl-item { position: relative; padding: 0 0 14px 18px; }
    .tl-item::before { content: ""; position: absolute; left: 3px; top: 5px; width: 7px; height: 7px; border-radius: 99px; background: var(--hl-cyan); box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.16); }
    .tl-item::after { content: ""; position: absolute; left: 6px; top: 16px; bottom: 0; width: 1px; background: var(--hl-line); }
    .tl-item:last-child::after { display: none; }
    .tl-head { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; font-size: 12.5px; }
    .tl-name { color: var(--hl-fg); font-weight: 600; }
    .tl-time { margin-left: auto; font-size: 11px; color: var(--hl-muted); font-variant-numeric: tabular-nums; }
    .tl-text { font-size: 11.5px; color: var(--hl-muted); margin-top: 4px; line-height: 1.6; }

    /* ── 弹窗 ── */
    .modal-root { display: none; }
    .modal-root.is-open { display: block; }
    .modal-mask { position: fixed; inset: 0; background: rgba(2, 6, 14, 0.72); backdrop-filter: blur(3px); z-index: 70; }
    .modal {
      position: fixed; z-index: 71; left: 50%; top: 50%; transform: translate(-50%, -50%);
      width: min(440px, calc(100vw - 32px)); max-height: 86vh; overflow: auto;
      border: 1px solid var(--hl-line-2); border-radius: 16px;
      background: #192332; box-shadow: 0 26px 60px rgba(2, 6, 14, 0.6);
      padding: 16px;
    }
    .modal-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
    .modal-head h3 { font-size: 15px; }
    .icon-btn {
      margin-left: auto; width: 32px; height: 32px; border-radius: 9px;
      border: 1px solid var(--hl-line); background: transparent; color: var(--hl-muted);
      font-size: 18px; line-height: 1; cursor: pointer;
    }
    .icon-btn:hover { color: var(--hl-fg); background: rgba(125, 175, 230, 0.1); }
    .modal-body { display: flex; flex-direction: column; gap: 12px; }
    .modal-task { padding: 11px 12px; border-radius: 11px; background: rgba(125, 175, 230, 0.07); border: 1px solid var(--hl-line); }
    .modal-task-name { font-size: 13.5px; font-weight: 650; }
    .modal-task-meta { font-size: 11.5px; color: var(--hl-muted); margin-top: 4px; }
    .modal-foot { display: flex; gap: 10px; margin-top: 16px; }
    .modal-foot .btn { flex: 1 1 0; }

    /* ── 移动端底部导航 ── */
    .mobile-nav { display: none; }

    @media (min-width: 640px) {
      .form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
      .field.span-2 { grid-column: 1 / -1; }
    }
    @media (min-width: 768px) {
      .chart-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
      .chart-grid .card:first-child { grid-column: 1 / -1; }
    }
    @media (min-width: 1024px) {
      .layout-2 { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); }
      .chart-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
      .chart-grid .card:first-child { grid-column: auto; }
      .content { padding: 20px 26px 40px; }
    }
    @media (max-width: 900px) {
      .sidebar { display: none; }
      .topbar { padding: 14px 16px 12px; }
      .content { padding: 14px 14px 92px; }
      .mobile-nav {
        display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
        gap: 6px; padding: 8px 10px calc(8px + env(safe-area-inset-bottom));
        background: rgba(22, 28, 38, 0.94); border-top: 1px solid var(--hl-line);
        backdrop-filter: blur(10px);
      }
      .mobile-nav .btn { flex: 0 0 auto; min-height: 44px; padding: 0 18px; border-radius: 12px; }
      .task-list, .queue { max-height: none; }
    }

    /* ── 区域总览 ── */
    .zone-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
    .zone-card {
      text-align: left; cursor: pointer; width: 100%;
      border: 1px solid var(--hl-line); border-radius: 14px;
      background: rgba(24, 32, 44, 0.72); padding: 13px 14px 14px;
      color: inherit; font: inherit;
      transition: border-color 0.18s, transform 0.18s, background 0.18s;
    }
    .zone-card:hover { border-color: var(--hl-line-2); transform: translateY(-1px); }
    .zone-card.is-active {
      border-color: rgba(56, 189, 248, 0.55);
      background: linear-gradient(160deg, rgba(56, 189, 248, 0.16), rgba(24, 32, 44, 0.72));
      box-shadow: 0 0 0 1px rgba(56, 189, 248, 0.2) inset;
    }
    .zone-head { display: flex; align-items: center; gap: 8px; }
    .zone-name { font-size: 13.5px; font-weight: 700; letter-spacing: 0.01em; }
    .zone-tag { margin-left: auto; font-size: 10.5px; color: var(--hl-muted); }
    .zone-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 10px; margin-top: 11px; }
    .zone-stat { display: flex; flex-direction: column; gap: 1px; }
    .zone-stat b { font-size: 17px; font-weight: 750; font-variant-numeric: tabular-nums; line-height: 1.2; }
    .zone-stat span { font-size: 10.5px; color: var(--hl-muted); }
    .zone-bar { margin-top: 12px; }
    .zone-bar-head { display: flex; align-items: center; justify-content: space-between; font-size: 10.5px; color: var(--hl-muted); margin-bottom: 5px; }

    /* ── 单位 / 人员 卡片 ── */
    .item-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
    .item-name { font-size: 13.5px; font-weight: 650; }
    .item-sub { font-size: 11.5px; color: var(--hl-muted); margin-top: 4px; }
    .item-foot { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
    .kv { font-size: 11.5px; color: var(--hl-muted); }
    .kv b { color: var(--hl-fg-2); font-weight: 600; }

    .nav-count {
      margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px;
      border-radius: 99px; font-size: 11px; font-weight: 700;
      display: grid; place-items: center;
      background: rgba(125, 175, 230, 0.14); color: var(--hl-fg-2);
    }
    .nav-count:empty { display: none; }

    @media (min-width: 640px) {
      .zone-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    }
    @media (min-width: 1024px) {
      .zone-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    }

    @media (max-width: 900px) {
      .mobile-nav button {
        flex: 1 1 0; min-height: 46px; border-radius: 12px; border: 1px solid transparent;
        background: transparent; color: var(--hl-muted); font-size: 12.5px; cursor: pointer;
      }
      .mobile-nav button.is-active {
        color: #eaf7ff; background: rgba(56, 189, 248, 0.16); border-color: rgba(56, 189, 248, 0.34);
      }
    }

    /* ── 区域划分图（复刻参考页 map.js 结构） ── */
    .card-head-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
    .card-sub { font-size: 11px; color: var(--hl-muted); }
    .card-tools { margin-left: auto; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
    .toggle { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; color: var(--hl-muted); cursor: pointer; }
    .toggle input { display: none; }
    .toggle .track { width: 34px; height: 19px; border-radius: 99px; background: rgba(125, 175, 230, 0.25); position: relative; transition: background 0.18s; flex: 0 0 34px; }
    .toggle .track::after { content: ""; position: absolute; top: 2px; left: 2px; width: 15px; height: 15px; border-radius: 99px; background: #cfe4f7; transition: left 0.18s; }
    .toggle input:checked + .track { background: rgba(56, 189, 248, 0.55); }
    .toggle input:checked + .track::after { left: 17px; }

    .map-stage { position: relative; border-radius: 12px; overflow: hidden; border: 1px solid var(--hl-line); background: #161b24; }
    .map-stage img {
      display: block; width: 100%; height: auto; user-select: none; -webkit-user-drag: none;
      filter: brightness(0.52) saturate(0.85) contrast(1.04);
    }
    .map-stage svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
    /* 区域轮廓：只描边不填色，热度由下方光斑层承担（与统计大屏一致） */
    .zone-rect {
      cursor: pointer; fill: transparent;
      stroke: rgba(125, 211, 252, 0.5); stroke-width: 3;
      transition: fill 0.15s, stroke 0.15s;
    }
    .zone-rect:hover { stroke: #7dd3fc; stroke-width: 6; fill: rgba(34, 211, 238, 0.10); }
    .zone-rect.selected { stroke: #fbbf24; stroke-width: 9; fill: rgba(251, 191, 36, 0.10); }

    /* 任务热力：径向光斑 + 模糊 + screen 混合（同统计大屏，只叠色不叠文字） */
    .map-heat {
      position: absolute; inset: 0; z-index: 2;
      pointer-events: none;
      mix-blend-mode: screen;
      opacity: 1;
    }
    .map-heat i {
      position: absolute; display: block; border-radius: 50%;
      transform: translate(-50%, -50%);
      filter: blur(var(--heat-blur, 14px));
      will-change: opacity;
      animation: mapHeatBreathe 4.5s ease-in-out infinite;
    }
    @keyframes mapHeatBreathe { 0%, 100% { opacity: 0.78; } 50% { opacity: 1; } }
    .map-stage svg { z-index: 3; }
    .map-legend { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; margin-top: 10px; font-size: 11.5px; color: var(--hl-muted); }
    .legend-scale { display: inline-flex; align-items: center; gap: 5px; }
    .legend-box { width: 14px; height: 14px; border-radius: 4px; border: 1px solid rgba(34, 211, 238, 0.4); display: inline-block; }
    .zone-tooltip {
      position: fixed; z-index: 95; transform: translate(-50%, calc(-100% - 12px));
      background: #192332; border: 1px solid var(--hl-line-2); border-radius: 10px;
      padding: 10px 12px; min-width: 180px; pointer-events: none;
      box-shadow: 0 14px 34px rgba(2, 6, 14, 0.55);
    }
    .tt-zone { font-weight: 700; font-size: 13px; margin-bottom: 6px; }
    .tt-row { display: flex; justify-content: space-between; gap: 14px; font-size: 11.5px; color: var(--hl-muted); }
    .tt-row b { color: var(--hl-fg); font-variant-numeric: tabular-nums; }
    .tt-sub { margin-top: 6px; font-size: 10.5px; color: var(--hl-muted); border-top: 1px dashed var(--hl-line); padding-top: 6px; }

    /* ── 区域详情面板 ── */
    .overview-grid { display: grid; grid-template-columns: 1fr; gap: 14px; align-items: stretch; }
    /* 左列：主机厅划分（上）+ 区域索引（下），右列：区域详情；两列等高填满 */
    .ov-left { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
    .ov-left .map-card { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
    .ov-left .map-card #zone-map { flex: 1 1 auto; min-height: 0; }
    .ov-left .zone-index-card { flex: 0 0 auto; }
    .overview-grid .zone-panel { display: flex; flex-direction: column; min-width: 0; }
    .overview-grid .zone-panel #zone-panel { flex: 1 1 auto; min-height: 0; }
    .zone-head { display: flex; gap: 12px; align-items: center; }
    .zone-letter {
      width: 52px; height: 52px; flex: 0 0 52px; border-radius: 14px;
      display: grid; place-items: center; font-weight: 800; font-size: 19px; color: #eaf7ff;
      background: linear-gradient(135deg, rgba(56, 189, 248, 0.26), rgba(56, 189, 248, 0.08));
      border: 1px solid rgba(56, 189, 248, 0.42);
    }
    .zone-name { font-size: 16px; font-weight: 750; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
    .zone-name small {
      font-size: 11px; font-weight: 600; color: var(--hl-cyan-tx);
      background: rgba(56, 189, 248, 0.12); border: 1px solid rgba(56, 189, 248, 0.32);
      padding: 1px 8px; border-radius: 99px;
    }
    .zone-head .tiny { font-size: 11px; color: var(--hl-muted); margin-top: 3px; }
    .zone-subzones-wrap { margin-top: 13px; }
    .zone-subzones { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 7px; }
    .row-between { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
    .chip-btn {
      cursor: pointer; border: 1px solid var(--hl-line-2); border-radius: 99px;
      background: rgba(125, 175, 230, 0.06); color: var(--hl-fg-2);
      padding: 5px 11px; font-size: 11.5px; font-family: inherit;
      display: inline-flex; align-items: center; gap: 4px;
      transition: background 0.15s, border-color 0.15s, color 0.15s;
    }
    .chip-btn b { font-weight: 700; }
    .chip-btn:hover { border-color: rgba(56, 189, 248, 0.5); color: var(--hl-fg); }
    .chip-btn.active { background: rgba(56, 189, 248, 0.2); border-color: rgba(56, 189, 248, 0.55); color: #eaf7ff; }
    .zone-metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 13px; }
    .zone-metric { border: 1px solid var(--hl-line); border-radius: 12px; background: rgba(24, 32, 44, 0.7); padding: 10px 8px; text-align: center; }
    .zone-metric b { display: block; font-size: 20px; font-weight: 750; font-variant-numeric: tabular-nums; line-height: 1.25; }
    .zone-metric span { font-size: 10.5px; color: var(--hl-muted); }
    .zone-breakdown { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
    .divider { height: 1px; background: var(--hl-line); margin: 13px 0; }
    .zone-recent { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }
    .zone-recent-item {
      display: flex; align-items: center; gap: 8px; width: 100%;
      padding: 8px 10px; border-radius: 10px; text-align: left; cursor: pointer;
      border: 1px solid var(--hl-line); background: rgba(24, 32, 44, 0.7);
      color: var(--hl-fg-2); font-size: 12px; font-family: inherit;
    }
    .zone-recent-item:hover { border-color: var(--hl-line-2); color: var(--hl-fg); }
    /* 区域 chip 只放区域号：过长时收缩省略，把空间留给任务名 */
    .zone-recent-item .zr-zone {
      flex: 0 1 auto; min-width: 0; max-width: 38%;
      overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
    }
    .zone-recent-item .zr-status { flex: 0 0 auto; }
    /* 任务名完整显示：允许换行，长词不撑破 */
    .zr-name {
      flex: 1 1 auto; min-width: 0;
      white-space: normal; overflow-wrap: anywhere; word-break: break-word;
      line-height: 1.45; text-align: left;
    }
    .zone-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 13px; }
    .zone-actions .btn { flex: 1 1 auto; }
    .zone-chips { display: flex; flex-wrap: wrap; gap: 8px; }
    .zone-chip {
      cursor: pointer; border: 1px solid var(--hl-line-2); border-radius: 12px;
      background: rgba(24, 32, 44, 0.72); color: var(--hl-fg-2);
      padding: 7px 11px; font-size: 12px; font-family: inherit; text-align: left;
      display: flex; flex-direction: column; gap: 1px; min-width: 86px;
      transition: border-color 0.15s, background 0.15s;
    }
    .zone-chip b { font-size: 13px; font-weight: 750; color: var(--hl-fg); }
    .zone-chip span { font-size: 10.5px; color: var(--hl-muted); }
    .zone-chip:hover { border-color: rgba(56, 189, 248, 0.5); }
    .zone-chip.active { border-color: rgba(251, 191, 36, 0.6); background: rgba(251, 191, 36, 0.1); }
    .task-filter { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }

    /* ── 放大弹窗 ── */
    .modal-root { display: none; }
    .modal-root.is-open { display: block; }
    .modal-mask { position: fixed; inset: 0; background: rgba(2, 6, 14, 0.78); backdrop-filter: blur(3px); z-index: 90; }
    .modal {
      position: fixed; z-index: 91; left: 50%; top: 50%; transform: translate(-50%, -50%);
      width: min(1120px, calc(100vw - 28px)); max-height: 92vh; overflow: auto;
      border: 1px solid var(--hl-line-2); border-radius: 16px;
      background: #192332; box-shadow: 0 26px 60px rgba(2, 6, 14, 0.6);
      padding: 16px;
    }
    .modal-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
    .modal-head h3 { font-size: 15px; }
    .modal-head .card-sub { margin-top: 2px; }
    .icon-btn {
      margin-left: auto; width: 32px; height: 32px; border-radius: 9px; flex: 0 0 32px;
      border: 1px solid var(--hl-line); background: transparent; color: var(--hl-muted);
      font-size: 18px; line-height: 1; cursor: pointer;
    }
    .icon-btn:hover { color: var(--hl-fg); background: rgba(125, 175, 230, 0.1); }

    @media (min-width: 1024px) {
      .overview-grid { grid-template-columns: minmax(0, 1.72fr) minmax(0, 1fr); align-items: stretch; }
    }

    /* 单位填报：仅入口表单，限制表单宽度避免过宽 */
    .form.form-fit { max-width: 920px; }

    /* 人员：单位筛选 + 退场操作 */
    .mini-select {
      min-height: 34px; padding: 4px 28px 4px 10px; border-radius: 9px;
      border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.78);
      color: var(--hl-fg); font-size: 13px; font-family: inherit;
      -webkit-appearance: none; appearance: none;
      background-image: linear-gradient(45deg, transparent 50%, var(--hl-muted) 50%), linear-gradient(135deg, var(--hl-muted) 50%, transparent 50%);
      background-position: calc(100% - 16px) calc(50% + 1px), calc(100% - 11px) calc(50% + 1px);
      background-size: 5px 5px, 5px 5px; background-repeat: no-repeat;
      max-width: 220px;
    }
    .mini-select option { background: #0f1928; color: var(--hl-fg); }
    .person-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 10px; }

    /* 人员头像（Q版头像 = 测试数据，真人照片 = 真实数据） */
    .person-row { display: flex; align-items: flex-start; gap: 12px; }
    .person-main { flex: 1 1 auto; min-width: 0; }
    .person-avatar {
      flex: 0 0 52px; width: 52px; height: 52px; border-radius: 50%;
      overflow: hidden; display: flex; align-items: center; justify-content: center;
      font-size: 19px; font-weight: 700; color: #eaf7ff;
      background: linear-gradient(135deg, #29435f, #24344a);
      border: 1.5px solid var(--hl-line-2); box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
    }
    .person-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
    .person-avatar.is-test { border-color: rgba(251, 191, 36, 0.55); }
    .pp-avatar {
      width: 22px; height: 22px; border-radius: 50%; object-fit: cover; display: block;
      border: 1px solid rgba(255, 255, 255, 0.25); flex: 0 0 22px;
    }
    .pp-name { white-space: nowrap; }
    .avatar-legend { font-size: 11px; color: var(--hl-muted); margin: -2px 0 10px; }

    /* 作业负责人 / 安全监护人：下拉 + 快速匹配 */
    .combo { position: relative; display: flex; align-items: center; }
    .combo input {
      width: 100%; min-height: 40px; padding: 0 36px 0 11px; border-radius: 10px;
      border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.78);
      color: var(--hl-fg); font-size: 13px; font-family: inherit;
    }
    .combo input:focus {
      outline: none; border-color: rgba(56, 189, 248, 0.7);
      box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.14);
    }
    .combo-toggle {
      position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
      width: 30px; height: 30px; border: 0; border-radius: 8px; cursor: pointer;
      background: transparent; color: var(--hl-muted); font-size: 13px; line-height: 1;
    }
    .combo-toggle:hover { background: rgba(56, 189, 248, 0.14); color: var(--hl-cyan-tx); }
    .combo-list {
      position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 40;
      max-height: 232px; overflow-y: auto; padding: 5px;
      border: 1px solid rgba(56, 189, 248, 0.32); border-radius: 11px;
      background: linear-gradient(160deg, rgba(25, 35, 50, 0.99), rgba(22, 29, 40, 0.99));
      box-shadow: 0 18px 40px rgba(2, 6, 14, 0.55);
    }
    .combo-item {
      display: flex; align-items: center; gap: 9px; width: 100%;
      padding: 7px 8px; border: 0; border-radius: 8px; cursor: pointer;
      background: transparent; color: var(--hl-fg); font-family: inherit; text-align: left;
    }
    .combo-item:hover { background: rgba(56, 189, 248, 0.12); }
    .combo-item.is-on { background: rgba(56, 189, 248, 0.18); }
    .combo-avatar {
      flex: 0 0 28px; width: 28px; height: 28px; border-radius: 50%; overflow: hidden;
      display: flex; align-items: center; justify-content: center;
      font-size: 12px; font-weight: 700; color: #eaf7ff;
      background: linear-gradient(135deg, #29435f, #24344a); border: 1px solid var(--hl-line-2);
    }
    .combo-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
    .combo-body { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
    .combo-body b { font-size: 12.5px; font-weight: 650; }
    .combo-body em { font-style: normal; font-size: 10.5px; color: var(--hl-muted); }
    .combo-phone { flex: 0 0 auto; font-size: 11px; color: var(--hl-muted); font-variant-numeric: tabular-nums; }
    .combo-empty { padding: 10px; font-size: 11.5px; color: var(--hl-muted); text-align: center; }
    .combo-hint { font-size: 11px; color: var(--hl-muted); margin-top: 5px; }

    /* 任务内容字数统计 */
    .field-tip { font-style: normal; font-size: 11px; color: var(--hl-cyan-tx); opacity: 0.9; margin-left: 4px; }
    .char-count {
      align-self: flex-end; font-size: 11px; color: var(--hl-muted);
      font-variant-numeric: tabular-nums; margin-top: 2px;
    }
    .char-count.is-low { color: var(--hl-warn-tx); }
    .char-count.is-ok { color: var(--hl-ok-tx); }

    /* 作业人员：弹窗勾选入口 */
    .people-picker-btn {
      display: flex; align-items: center; gap: 10px; width: 100%;
      padding: 11px 12px; border-radius: 10px; cursor: pointer;
      border: 1px dashed var(--hl-line-2); background: rgba(21, 27, 37, 0.6);
      color: var(--hl-fg-2); font-size: 13px; font-family: inherit; text-align: left;
      transition: border-color 0.18s, background 0.18s;
    }
    .people-picker-btn:hover { border-color: rgba(56, 189, 248, 0.6); background: rgba(56, 189, 248, 0.08); }
    .people-picker-btn .picker-label { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .people-picker-btn .picker-arrow { flex: 0 0 auto; font-size: 11.5px; color: var(--hl-cyan-tx); }

    /* 已选人员标签 */
    .picked-person {
      display: inline-flex; align-items: center; gap: 6px;
      padding: 3px 4px 3px 3px; border-radius: 99px; font-size: 11.5px;
      border: 1px solid rgba(56, 189, 248, 0.4); background: rgba(56, 189, 248, 0.14); color: #eaf7ff;
    }
    .picked-person em { font-style: normal; font-size: 10px; color: rgba(234, 247, 255, 0.65); }
    .picked-avatar {
      width: 20px; height: 20px; border-radius: 50%; overflow: hidden; flex: 0 0 20px;
      display: flex; align-items: center; justify-content: center;
      font-size: 10px; font-weight: 700; color: #eaf7ff;
      background: linear-gradient(135deg, #29435f, #24344a);
    }
    .picked-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
    .picked-del {
      width: 16px; height: 16px; border: 0; border-radius: 50%; cursor: pointer;
      background: rgba(18, 22, 30, 0.5); color: #cfe6ff; font-size: 11px; line-height: 1;
      display: flex; align-items: center; justify-content: center;
    }
    .picked-del:hover { background: rgba(251, 113, 133, 0.6); color: #fff; }

    /* 作业人员弹窗 */
    .picker-modal { width: min(760px, calc(100vw - 28px)); }
    .picker-toolbar { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
    .picker-toolbar input {
      flex: 1 1 auto; min-height: 38px; padding: 0 11px; border-radius: 10px;
      border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.8);
      color: var(--hl-fg); font-size: 13px; font-family: inherit;
    }
    .picker-toolbar input:focus {
      outline: none; border-color: rgba(56, 189, 248, 0.7);
      box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.14);
    }
    .picker-total { flex: 0 0 auto; font-size: 11.5px; color: var(--hl-muted); }
    .picker-grid {
      display: grid; grid-template-columns: repeat(auto-fill, minmax(112px, 1fr));
      gap: 10px; max-height: 56vh; overflow-y: auto; padding: 2px;
    }
    .picker-card {
      display: flex; flex-direction: column; align-items: center; gap: 4px;
      padding: 12px 8px 10px; border-radius: 12px; cursor: pointer;
      border: 1px solid var(--hl-line); background: rgba(24, 32, 44, 0.72);
      color: var(--hl-fg); font-family: inherit;
      transition: border-color 0.16s, background 0.16s, transform 0.16s;
    }
    .picker-card:hover { border-color: var(--hl-line-2); transform: translateY(-1px); }
    .picker-card b { font-size: 12.5px; font-weight: 650; }
    .picker-card em { font-style: normal; font-size: 10.5px; color: var(--hl-muted); }
    .picker-card.is-on { border-color: rgba(56, 189, 248, 0.75); background: rgba(56, 189, 248, 0.14); }
    .picker-avatar {
      position: relative; width: 52px; height: 52px; border-radius: 50%; overflow: hidden;
      display: flex; align-items: center; justify-content: center;
      font-size: 18px; font-weight: 700; color: #eaf7ff;
      background: linear-gradient(135deg, #29435f, #24344a); border: 1.5px solid var(--hl-line-2);
    }
    .picker-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
    .picker-tick {
      position: absolute; right: -2px; bottom: -2px;
      width: 18px; height: 18px; border-radius: 50%; display: none;
      align-items: center; justify-content: center;
      font-size: 11px; font-style: normal; color: #04121f;
      background: var(--hl-cyan); border: 2px solid #0d1726;
    }
    .picker-card.is-on .picker-tick { display: flex; }
    .picker-empty { grid-column: 1 / -1; padding: 26px 10px; text-align: center; font-size: 12px; color: var(--hl-muted); }
    .picker-modal .modal-foot .btn { flex: 0 0 auto; min-width: 92px; }
    .picker-modal .modal-foot .spacer { flex: 1 1 auto; }

    /* 任务卡片：内容预览 / 操作按钮 / 修改提示条 */
    .task-content-preview {
      margin-top: 7px; font-size: 11.5px; line-height: 1.6; color: var(--hl-fg-2);
      display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
      overflow: hidden; opacity: 0.86;
    }
    .task-actions {
      display: flex; justify-content: flex-end; gap: 8px;
      margin-top: 10px; padding-top: 9px; border-top: 1px dashed var(--hl-line);
    }
    .edit-banner {
      display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
      margin-bottom: 12px; padding: 9px 12px; border-radius: 11px;
      border: 1px solid rgba(56, 189, 248, 0.42); background: rgba(56, 189, 248, 0.12);
      font-size: 12px; color: #dceeff;
    }
    .edit-banner-text { flex: 1 1 auto; min-width: 0; }
    .edit-banner b { font-family: ui-monospace, Menlo, monospace; letter-spacing: 0.03em; }

    /* ── 超期未闭环锁定条（新建任务门禁） ── */
    .overdue-lock {
      display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
      margin-bottom: 12px; padding: 10px 12px; border-radius: 11px;
      border: 1px solid rgba(248, 113, 113, 0.5);
      background: linear-gradient(180deg, rgba(248, 113, 113, 0.16), rgba(248, 113, 113, 0.06));
      font-size: 12px;
    }
    .overdue-lock-ico {
      flex: 0 0 22px; width: 22px; height: 22px; border-radius: 50%;
      display: grid; place-items: center; font-weight: 700; font-size: 13px;
      background: rgba(248, 113, 113, 0.92); color: #200505;
    }
    .overdue-lock-text { flex: 1 1 220px; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
    .overdue-lock-text b { font-size: 13px; color: #ffd7d7; }
    .overdue-lock-text span { color: rgba(255, 235, 235, 0.95); line-height: 1.5; }
    .overdue-lock-acts { display: flex; align-items: center; gap: 8px; margin-left: auto; }
    .btn.is-overdue-locked { opacity: 0.55; cursor: not-allowed; filter: grayscale(0.4); }

    /* ── 超期清单弹窗 ── */
    .od-modal { width: min(620px, calc(100vw - 28px)); }
    .od-lead { margin: 0 0 10px; font-size: 13px; line-height: 1.65; color: #c9d6ea; }
    .od-lead b { color: #ffb4b4; }
    .od-list {
      list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px;
      max-height: 46vh; overflow: auto;
    }
    .od-item {
      display: flex; align-items: center; gap: 10px;
      padding: 9px 11px; border-radius: 10px;
      border: 1px solid var(--hl-line); background: rgba(23, 30, 44, 0.55);
    }
    .od-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
    .od-main b { font-size: 13px; color: #e9efff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .od-meta { font-size: 11.5px; color: #c3d3e6; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .od-hours {
      flex: 0 0 auto; font-style: normal; font-size: 12px; font-weight: 700;
      color: #ff9b9b; font-family: ui-monospace, Menlo, monospace;
    }
    html[data-theme="light"] .overdue-lock {
      border-color: rgba(220, 38, 38, 0.35);
      background: linear-gradient(180deg, rgba(254, 226, 226, 0.92), rgba(254, 242, 242, 0.72));
    }
    html[data-theme="light"] .overdue-lock-text b { color: #991b1b; }
    html[data-theme="light"] .overdue-lock-text span { color: #b91c1c; }
    html[data-theme="light"] .od-lead b { color: #b91c1c; }
    html[data-theme="light"] .od-item { background: #fff; }
    html[data-theme="light"] .od-main b { color: #0f2137; }
    html[data-theme="light"] .od-meta { color: #5d7793; }
    html[data-theme="light"] .od-lead { color: #294761; }
    html[data-theme="light"] .od-hours { color: #b91c1c; }
    @media (max-width: 900px) {
      .overdue-lock-acts { width: 100%; margin-left: 0; }
      .overdue-lock-acts .btn { flex: 1 1 0; }
      .od-list { max-height: 52vh; }
      .od-modal .modal-foot .btn { flex: 1 1 0; }
    }
    .confirm-modal { width: min(460px, calc(100vw - 28px)); }

    /* 任务填报：区域多选 + 任务类型 */
    .zone-picker {
      display: flex; align-items: center; gap: 10px; width: 100%;
      padding: 10px 12px; border-radius: 10px; cursor: pointer;
      border: 1px dashed var(--hl-line-2); background: rgba(21, 27, 37, 0.6);
      color: var(--hl-fg-2); font-size: 13px; font-family: inherit; text-align: left;
      transition: border-color 0.18s, background 0.18s;
    }
    .zone-picker:hover { border-color: rgba(56, 189, 248, 0.6); background: rgba(56, 189, 248, 0.08); }
    .zone-picker-label { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .zone-picker-arrow { flex: 0 0 auto; font-size: 11.5px; color: var(--hl-cyan-tx); }
    .picked-zones { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
    .picked-zones:empty { display: none; }
    .zone-tag {
      display: inline-flex; align-items: center; gap: 6px;
      padding: 3px 9px; border-radius: 99px; font-size: 11.5px;
      border: 1px solid rgba(56, 189, 248, 0.4); background: rgba(56, 189, 248, 0.14); color: #eaf7ff;
    }
    .zone-tag button {
      border: 0; background: transparent; color: inherit; cursor: pointer;
      font-size: 13px; line-height: 1; padding: 0; opacity: 0.7;
    }
    .zone-tag button:hover { opacity: 1; }
    .type-badge {
      display: inline-flex; align-items: center; min-height: 42px; padding: 0 12px;
      border-radius: 10px; font-size: 13px; font-weight: 600;
      border: 1px solid rgba(52, 211, 153, 0.35); background: rgba(52, 211, 153, 0.12); color: #ccfbe8;
    }
    .type-badge.is-temp { border-color: rgba(251, 191, 36, 0.45); background: rgba(251, 191, 36, 0.14); color: #ffe6ad; }
    .modal-foot { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
    .modal-foot .picked-summary { font-size: 12px; color: var(--hl-muted); }
    .modal-foot .spacer { flex: 1 1 auto; }

    /* 任务填报：时间段 + 风险说明 + 二级区域选择 */
    /* 任务填报：计划进场时间段 · 48 个 30 分钟时间块 */
    .slot-picker {
      border: 1px solid var(--hl-line-2); border-radius: 12px;
      background: rgba(21, 27, 37, 0.6); padding: 9px 9px 10px;
    }
    .slot-grid {
      display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 3px;
      user-select: none; -webkit-user-select: none;
    }
    .slot {
      height: 30px; padding: 0; border-radius: 6px; cursor: pointer;
      display: grid; place-items: center;
      border: 1px solid var(--hl-line); background: rgba(25, 35, 49, 0.9);
      color: #a8bdd2; font-family: var(--hl-mono); font-size: 8.5px; line-height: 1;
      letter-spacing: -0.02em; font-variant-numeric: tabular-nums;
      transition: background .12s, border-color .12s, color .12s, box-shadow .12s;
      -webkit-tap-highlight-color: transparent;
    }
    .slot.is-hour { color: var(--hl-fg-2); border-color: var(--hl-line-2); }
    .slot:hover { border-color: rgba(56, 189, 248, 0.45); color: #cdefff; }
    .slot.is-on {
      border-color: rgba(56, 189, 248, 0.85);
      background: linear-gradient(180deg, rgba(56, 189, 248, 0.46), rgba(14, 165, 233, 0.3));
      color: #f2fbff; font-weight: 700;
      box-shadow: inset 0 0 0 1px rgba(56, 189, 248, 0.25), 0 4px 12px -7px rgba(56, 189, 248, 0.95);
    }
    .slot-foot { display: flex; align-items: center; gap: 10px; margin-top: 9px; }
    .slot-sum {
      flex: 1 1 auto; min-width: 0; font-size: 11.5px; line-height: 1.5;
      color: #9fe4ff; word-break: break-all;
    }
    .slot-sum.is-empty { color: var(--hl-muted); }
    .slot-acts { flex: 0 0 auto; display: flex; gap: 6px; }
    .slot-act {
      height: 26px; padding: 0 11px; border-radius: 999px; cursor: pointer;
      border: 1px solid var(--hl-line-2); background: rgba(25, 35, 49, 0.9);
      color: var(--hl-fg-2); font-family: inherit; font-size: 11px;
      transition: border-color .14s, color .14s;
    }
    .slot-act:hover { border-color: rgba(56, 189, 248, 0.55); color: #cdefff; }
    @media (min-width: 720px) {
      .slot-grid { grid-template-columns: repeat(12, minmax(0, 1fr)); }
      .slot { height: 32px; font-size: 9.5px; }
    }
    @media (max-width: 360px) {
      .slot { height: 28px; font-size: 8px; }
    }

    .time-range { display: flex; align-items: center; gap: 8px; }
    .time-range input[type="time"] {
      flex: 1 1 0; min-width: 0; padding: 10px 11px; border-radius: 10px;
      border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.78);
      color: var(--hl-fg); font-size: 16px; font-family: inherit;
    }
    .time-range input[type="time"]:focus { outline: none; border-color: rgba(56, 189, 248, 0.7); box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.16); }
    .time-sep { color: var(--hl-muted); font-size: 12px; }
    .sub-picker {
      margin-top: 12px; padding: 12px 13px; border-radius: 12px;
      border: 1px solid rgba(251, 191, 36, 0.45); background: rgba(251, 191, 36, 0.1);
    }
    .sub-picker-head { font-size: 12.5px; color: #ffe6ad; margin-bottom: 9px; }
    .sub-picker-head b { color: #fff3d1; }
    .sub-picker .zone-subzones { margin-top: 0; }
    .zone-rect.is-locked { opacity: 0.35; cursor: not-allowed; }
    #risk-note-wrap textarea { width: 100%; }

    .sub-picker-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 11px; flex-wrap: wrap; }
    .sub-picker-foot .kv { font-size: 11.5px; color: var(--hl-muted); }

    /* ── 身份绑定网关 ── */
    .gate {
      position: fixed; inset: 0; z-index: 120;
      display: flex; align-items: center; justify-content: center; padding: 20px;
      background:
        radial-gradient(700px 380px at 50% 18%, rgba(56, 189, 248, 0.162), transparent 68%),
        #161a22;
    }
    .gate-card {
      width: min(420px, 100%);
      max-height: 92vh; overflow-y: auto;
      border: 1px solid rgba(56, 189, 248, 0.28); border-radius: 18px;
      padding: 24px 22px 18px;
      background: linear-gradient(160deg, rgba(25, 35, 50, 0.98), rgba(22, 29, 40, 0.98));
      box-shadow: 0 30px 70px rgba(2, 6, 14, 0.6);
    }
    .gate-card.is-wide { width: min(560px, 100%); }
    .gate-brand {
      width: 52px; height: 52px; border-radius: 14px; margin-bottom: 14px;
      display: grid; place-items: center; font-weight: 800; font-size: 13px; letter-spacing: 0.08em;
      color: #eaf7ff;
      background: linear-gradient(135deg, rgba(56, 189, 248, 0.28), rgba(56, 189, 248, 0.08));
      border: 1px solid rgba(56, 189, 248, 0.45);
    }
    .gate-card h2 { font-size: 19px; margin-bottom: 6px; }
    .gate-sub { font-size: 12.5px; color: var(--hl-muted); line-height: 1.65; margin-bottom: 16px; }
    .gate-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
    .gate-field > span { font-size: 12px; color: var(--hl-muted); }
    .gate-field i { color: var(--hl-danger-tx); font-style: normal; }
    .gate-field input {
      min-height: 44px; padding: 0 12px; border-radius: 11px;
      border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.8);
      color: var(--hl-fg); font-size: 14px; font-family: inherit;
    }
    .gate-field input:focus {
      outline: none; border-color: rgba(56, 189, 248, 0.7);
      box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.16);
    }
    #gate-code { letter-spacing: 0.12em; text-transform: uppercase; font-family: ui-monospace, Menlo, monospace; }
    .gate-msg { min-height: 18px; font-size: 12px; color: var(--hl-danger-tx); margin-bottom: 8px; }
    .gate-btn { width: 100%; min-height: 44px; }
    .gate-foot { margin-top: 12px; font-size: 11px; color: rgba(180, 198, 220, 0.95); text-align: center; }

    /* 绑定第二步：本人建档（与人员填报字段一致） */
    .gate-code-chip {
      display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px;
      padding: 9px 12px; border-radius: 11px; margin-bottom: 14px;
      border: 1px solid rgba(56, 189, 248, 0.28); background: rgba(56, 189, 248, 0.08);
      font-size: 11.5px; color: var(--hl-muted);
    }
    .gate-code-chip b {
      font-size: 12px; font-weight: 650; color: #eaf7ff;
      font-family: ui-monospace, Menlo, monospace; letter-spacing: 0.04em;
    }
    .gate-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
    .gate-grid .gate-field { min-width: 0; }
    @media (max-width: 460px) { .gate-grid { grid-template-columns: 1fr; } }
    .gate-field select {
      min-height: 44px; padding: 0 10px; border-radius: 11px;
      border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.8);
      color: var(--hl-fg); font-size: 14px; font-family: inherit;
    }
    .gate-field select:focus {
      outline: none; border-color: rgba(56, 189, 248, 0.7);
      box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.16);
    }
    .gate-field input.is-locked {
      color: var(--hl-muted); background: rgba(56, 189, 248, 0.07);
      border-style: dashed; cursor: not-allowed;
    }
    .gate-field .photo-pick { margin-top: 2px; }
    .gate-field .photo-btn { width: 100%; justify-content: center; }
    .gate-field .photo-preview img { width: 96px; height: 120px; }
    .gate-back {
      width: 100%; min-height: 38px; margin-top: 8px;
      background: transparent; border: 1px solid var(--hl-line-2); color: var(--hl-muted);
    }
    .gate-back:hover { color: var(--hl-fg); border-color: rgba(56, 189, 248, 0.5); }

    /* 已录入直接登录：入口条 + 认证面板（与「完成绑定并进入」并列的第二条入口） */
    .gate-fast {
      display: flex; align-items: center; justify-content: space-between; gap: 10px;
      flex-wrap: wrap; margin: 0 0 14px; padding: 10px 12px;
      border-radius: 11px; border: 1px dashed rgba(56, 189, 248, 0.34);
      background: rgba(56, 189, 248, 0.06);
    }
    .gate-fast-tip { font-size: 11.5px; color: var(--hl-muted); line-height: 1.5; }
    .gate-fast-btn {
      min-height: 36px; padding: 0 14px; border-radius: 10px; cursor: pointer;
      border: 1px solid rgba(56, 189, 248, 0.55); background: rgba(56, 189, 248, 0.14);
      color: #eaf7ff; font-size: 12.5px; font-family: inherit; white-space: nowrap;
      transition: background 0.18s, border-color 0.18s;
    }
    .gate-fast-btn:hover { background: rgba(56, 189, 248, 0.24); border-color: rgba(56, 189, 248, 0.8); }
    .gate-fast-btn:focus-visible { outline: none; box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.2); }
    .gate-fast-head { font-size: 14px; font-weight: 650; color: var(--hl-fg); margin-bottom: 6px; }
    .gate-fast-note { font-size: 11.5px; color: var(--hl-muted); line-height: 1.65; margin-bottom: 14px; }
    @media (max-width: 460px) {
      .gate-fast { flex-direction: column; align-items: stretch; }
      .gate-fast-btn { width: 100%; min-height: 40px; }
    }
    html[data-theme="light"] .gate-fast {
      background: rgba(10, 126, 194, 0.06) !important;
      border-color: rgba(10, 126, 194, 0.3) !important;
    }
    html[data-theme="light"] .gate-fast-btn {
      background: #ffffff; border-color: rgba(10, 126, 194, 0.4); color: var(--hl-fg-2);
    }
    html[data-theme="light"] .gate-fast-btn:hover {
      background: rgba(10, 126, 194, 0.1); border-color: rgba(10, 126, 194, 0.6);
    }

    /* ── 当前身份 ── */
    .id-chip {
      display: flex; flex-direction: column; gap: 1px; padding: 5px 11px; border-radius: 11px;
      border: 1px solid rgba(56, 189, 248, 0.3); background: rgba(56, 189, 248, 0.1);
      max-width: 240px;
    }
    .id-chip b { font-size: 12.5px; color: #eaf7ff; font-weight: 650; }
    .id-chip span { font-size: 10.5px; color: var(--hl-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .code-box {
      padding: 14px; border-radius: 12px; text-align: center;
      font-family: ui-monospace, Menlo, monospace; font-size: 22px; letter-spacing: 0.14em;
      color: #eaf7ff; border: 1px dashed rgba(56, 189, 248, 0.5); background: rgba(56, 189, 248, 0.1);
    }
    .tiny.muted { font-size: 11px; color: var(--hl-muted); }

    /* 绑定后自动带出的只读字段 */
    .field input.is-locked {
      color: var(--hl-fg);
      background: rgba(56, 189, 248, 0.08);
      border-color: rgba(56, 189, 248, 0.35);
      cursor: not-allowed;
    }
    .field select:disabled {
      color: var(--hl-fg);
      background: rgba(56, 189, 248, 0.08);
      border-color: rgba(56, 189, 248, 0.35);
      opacity: 1;
      cursor: not-allowed;
    }


    /* 移动端顶栏：身份区换行收缩，避免横向溢出 */
    @media (max-width: 900px) {
      .topbar { flex-wrap: wrap; }
      .topbar-actions {
        width: 100%; margin-left: 0; flex-wrap: wrap; gap: 8px;
      }
      .id-chip { flex: 1 1 150px; min-width: 0; max-width: none; }
      .id-chip b, .id-chip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
      .sync-pill { flex: 0 0 auto; }
      .topbar-actions .btn { flex: 0 0 auto; }
    }
    @media (max-width: 480px) {
      .sync-pill { display: none; }
    }

    /* ── 照片上传 ── */
    .photo-pick { display: flex; flex-direction: column; gap: 10px; }
    .photo-btn {
      display: flex; align-items: center; justify-content: center; gap: 8px;
      min-height: 84px; border-radius: 12px; cursor: pointer;
      border: 1px dashed var(--hl-line-2); background: rgba(21, 27, 37, 0.6);
      color: var(--hl-muted); font-size: 12.5px; font-family: inherit;
      transition: border-color 0.18s, background 0.18s, color 0.18s;
    }
    .photo-btn:hover { border-color: rgba(56, 189, 248, 0.6); background: rgba(56, 189, 248, 0.08); color: var(--hl-fg-2); }
    .photo-plus { font-size: 22px; line-height: 1; color: var(--hl-cyan-tx); }
    .photo-preview { position: relative; width: 128px; }
    .photo-preview img {
      width: 128px; height: 160px; object-fit: cover; border-radius: 10px;
      border: 1px solid var(--hl-line-2); display: block;
    }
    .photo-del {
      position: absolute; right: 6px; top: 6px;
      border: 0; border-radius: 99px; padding: 3px 9px; cursor: pointer;
      font-size: 11px; font-family: inherit;
      color: #ffd9df; background: rgba(18, 22, 30, 0.72);
    }
    .photo-del:hover { background: rgba(251, 113, 133, 0.5); }
    .photo-err { font-size: 11.5px; color: var(--hl-danger-tx); }

    /* ── 作业人员选择 ── */
    .people-pick { display: flex; flex-wrap: wrap; gap: 8px; }
    .pp-chip {
      display: inline-flex; align-items: center; gap: 6px;
      padding: 7px 12px; border-radius: 99px; cursor: pointer;
      border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.7);
      color: var(--hl-fg-2); font-size: 12.5px; font-family: inherit;
      transition: border-color 0.15s, background 0.15s, color 0.15s;
    }
    .pp-chip em { font-style: normal; font-size: 10.5px; color: var(--hl-muted); }
    .pp-chip:hover { border-color: rgba(56, 189, 248, 0.5); color: var(--hl-fg); }
    .pp-chip.is-on {
      border-color: rgba(56, 189, 248, 0.6); background: rgba(56, 189, 248, 0.18); color: #eaf7ff;
    }
    .pp-chip.is-on em { color: rgba(234, 247, 255, 0.7); }
    .pp-chip.is-on::before { content: "✓"; font-size: 11px; color: var(--hl-cyan-tx); }
    .pp-empty { font-size: 12px; color: var(--hl-muted); }
    .people-pick-hint { font-size: 11.5px; color: var(--hl-muted); margin-top: 2px; }

    /* ── 任务闭环 ── */
    .closure-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-bottom: 12px; }
    .closure-kpi {
      position: relative; display: flex; flex-direction: column; gap: 2px;
      padding: 11px 13px 10px; border-radius: 12px; overflow: hidden;
      border: 1px solid var(--hl-line); background: rgba(24, 32, 44, 0.72);
    }
    .closure-kpi::before {
      content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 2px;
      background: var(--tone, #38bdf8); box-shadow: 0 0 10px var(--tone, #38bdf8);
    }
    .closure-kpi .ck-label { font-size: 11.5px; color: var(--hl-muted); }
    .closure-kpi b { font-size: 22px; line-height: 1.15; color: var(--tone, #eaf7ff); font-variant-numeric: tabular-nums; }
    .closure-kpi em { font-style: normal; font-size: 10.5px; color: rgba(180, 198, 220, 0.95); }
    .closure-kpi.cyan { --tone: #38bdf8; }
    .closure-kpi.violet { --tone: #a78bfa; }
    .closure-kpi.amber { --tone: #fbbf24; }
    .closure-kpi.green { --tone: #34d399; }

    .closure-banner {
      display: flex; align-items: flex-start; gap: 10px;
      padding: 10px 13px; margin-bottom: 14px; border-radius: 12px;
      border: 1px solid rgba(56, 189, 248, 0.28); background: rgba(56, 189, 248, 0.08);
      font-size: 11.5px; line-height: 1.65; color: #cfe8fb;
    }
    .closure-banner-icon { color: var(--hl-cyan-tx); font-size: 14px; line-height: 1.2; }

    .closure-thumbs { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 9px; }
    .closure-thumbs img {
      width: 74px; height: 56px; object-fit: cover; border-radius: 7px;
      border: 1px solid var(--hl-line-2); cursor: pointer;
    }
    .closure-thumbs .thumb-more {
      display: inline-flex; align-items: center; justify-content: center;
      width: 42px; height: 56px; border-radius: 7px; font-size: 11px;
      border: 1px dashed var(--hl-line-2); color: var(--hl-muted);
    }
    .closure-thumbs .thumb-missing {
      display: inline-flex; align-items: center; justify-content: center;
      width: 74px; height: 56px; border-radius: 7px; font-size: 10px;
      border: 1px dashed var(--hl-line-2); color: var(--hl-muted);
    }
    .closure-note { margin-top: 8px; font-size: 11.5px; line-height: 1.6; color: var(--hl-fg-2); }
    .closure-note b { color: var(--hl-muted); font-weight: 600; }

    .closure-modal { width: min(620px, calc(100vw - 28px)); }
    .closure-reject {
      padding: 9px 11px; border-radius: 9px; font-size: 11.5px; line-height: 1.6;
      border: 1px solid rgba(251, 113, 133, 0.35); background: rgba(251, 113, 133, 0.1); color: #ffd9df;
    }
    .closure-photo-head { display: flex; align-items: baseline; justify-content: space-between; font-size: 12px; color: var(--hl-muted); }
    .closure-photo-head i { color: var(--hl-danger-tx); font-style: normal; }
    .closure-photo-count { font-size: 11px; }
    .closure-photo-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
    .closure-photo-item { position: relative; aspect-ratio: 4 / 3; border-radius: 9px; overflow: hidden; border: 1px solid var(--hl-line-2); }
    .closure-photo-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
    .closure-photo-del {
      position: absolute; right: 4px; top: 4px; width: 20px; height: 20px;
      border: 0; border-radius: 50%; cursor: pointer; line-height: 1;
      color: #ffd9df; background: rgba(18, 22, 30, 0.7); font-size: 12px;
    }
    .closure-photo-del:hover { background: rgba(251, 113, 133, 0.65); color: #fff; }
    .closure-photo-missing { display: grid; place-items: center; width: 100%; height: 100%; font-size: 10px; color: var(--hl-muted); }
    .closure-empty {
      grid-column: 1 / -1; padding: 18px 10px; text-align: center; font-size: 11.5px; color: var(--hl-muted);
      border: 1px dashed var(--hl-line-2); border-radius: 10px;
    }
    .closure-note-field { display: flex; flex-direction: column; gap: 6px; }
    .closure-note-field > span { font-size: 12px; color: var(--hl-muted); }
    .closure-note-field i { color: var(--hl-danger-tx); font-style: normal; }
    .closure-note-field textarea {
      width: 100%; padding: 10px 11px; border-radius: 10px; resize: vertical;
      border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.78);
      color: var(--hl-fg); font-size: 13px; font-family: inherit; line-height: 1.6;
    }
    .closure-note-field textarea:focus { outline: none; border-color: rgba(56, 189, 248, 0.7); box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.14); }

    @media (max-width: 900px) {
      .closure-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
      .closure-photo-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    }

    /* 闭环照片规则与分区域上传 */
    .closure-rule {
      padding: 9px 11px; border-radius: 9px; font-size: 11.5px; line-height: 1.7;
      border: 1px solid rgba(56, 189, 248, 0.26); background: rgba(56, 189, 248, 0.07); color: #cfe8fb;
    }
    .closure-rule b { color: #8fe8ff; }
    .closure-rule-tip { display: inline-block; margin-top: 3px; color: #7ee0b8; }

    /* 任务动态 · 双会签阶段状态（总包管理 / 总协调 独立显示） */
    .task-stages { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
    .stg {
      display: inline-flex; align-items: center; gap: 5px;
      height: 22px; padding: 0 9px; border-radius: 999px;
      font-size: 11px; line-height: 1; white-space: nowrap;
      border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, .6); color: var(--hl-fg-2);
    }
    .stg b { font-weight: 700; color: var(--hl-fg); }
    .stg.wait { border-color: rgba(251, 191, 36, .45); background: rgba(251, 191, 36, .12); color: #fcd34d; }
    .stg.wait b { color: #fcd34d; }
    .stg.ok { border-color: rgba(52, 211, 153, .45); background: rgba(52, 211, 153, .12); color: #6ee7b7; }
    .stg.ok b { color: #6ee7b7; }
    .stg.reject { border-color: rgba(251, 113, 133, .45); background: rgba(251, 113, 133, .12); color: #fda4af; }
    .stg.reject b { color: #fda4af; }

    /* 完成情况选择 */
    .cmp-group { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 12px 0; }
    .cmp-opt {
      display: flex; flex-direction: column; gap: 3px; align-items: flex-start;
      padding: 12px 14px; border-radius: 12px; cursor: pointer; font-family: inherit;
      border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.72);
      color: var(--hl-fg-2); text-align: left; transition: border-color .16s, background .16s, transform .16s;
    }
    .cmp-opt b { font-size: 15px; font-weight: 700; }
    .cmp-opt span { font-size: 11px; color: var(--hl-muted); line-height: 1.5; }
    .cmp-opt:hover { border-color: rgba(56, 189, 248, 0.5); transform: translateY(-1px); }
    .cmp-opt.is-on.is-ok { border-color: rgba(52, 211, 153, 0.75); background: rgba(52, 211, 153, 0.14); color: #d7fff0; }
    .cmp-opt.is-on.is-ok b { color: #6ee7b7; }
    .cmp-opt.is-on.is-warn { border-color: rgba(251, 191, 36, 0.75); background: rgba(251, 191, 36, 0.14); color: #fff5d6; }
    .cmp-opt.is-on.is-warn b { color: #fcd34d; }

    .cmp-fields { display: flex; flex-direction: column; gap: 12px; margin: 12px 0; }
    .cmp-fields[hidden] { display: none !important; }
    .cmp-field { display: flex; flex-direction: column; gap: 6px; position: relative; }
    .cmp-field > span { font-size: 12px; color: var(--hl-muted); }
    .cmp-field i { color: var(--hl-danger-tx); font-style: normal; }
    .cmp-field textarea {
      width: 100%; padding: 10px 11px; border-radius: 10px; resize: vertical;
      border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.78);
      color: var(--hl-fg); font-size: 13px; font-family: inherit; line-height: 1.6;
    }
    .cmp-field textarea:focus { outline: none; border-color: rgba(56, 189, 248, 0.7); box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.14); }
    .cmp-count { position: absolute; right: 8px; bottom: 8px; font-style: normal; font-size: 10px; color: var(--hl-muted); }
    .cmp-count.is-ok { color: #34d399; }
    .cmp-count.is-low { color: #fbbf24; }

    /* 是否需要明日继续 · 分段选择 */
    .cmp-seg { display: flex; gap: 8px; }
    .cmp-seg-btn {
      flex: 1 1 0; height: 40px; border-radius: 10px; cursor: pointer; font-family: inherit;
      border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.78); color: var(--hl-fg-2);
      font-size: 13px; transition: border-color 0.15s, background 0.15s, color 0.15s;
    }
    .cmp-seg-btn:hover { border-color: rgba(56, 189, 248, 0.5); }
    .cmp-seg-btn.is-on {
      border-color: rgba(56, 189, 248, 0.85); background: rgba(56, 189, 248, 0.16);
      color: #bae6fd; font-weight: 600;
    }

    /* 完成情况展示 */
    .closure-detail { display: flex; flex-direction: column; gap: 4px; margin-top: 8px; padding: 9px 11px; border-radius: 10px; border: 1px solid var(--hl-line); background: rgba(22, 31, 42, 0.55); }
    .cd-row { display: flex; gap: 8px; font-size: 11.5px; line-height: 1.6; }
    .cd-row i { flex: 0 0 76px; font-style: normal; color: var(--hl-muted); }
    .cd-row span { flex: 1 1 auto; color: var(--hl-fg-2); word-break: break-word; }
    .closure-area-bar { display: flex; flex-wrap: wrap; gap: 6px; }
    .closure-area-chip {
      display: inline-flex; align-items: center; gap: 5px;
      padding: 4px 9px; border-radius: 99px; cursor: pointer; font-family: inherit;
      border: 1px dashed rgba(251, 191, 36, 0.5); background: rgba(251, 191, 36, 0.08); color: #ffe6ad;
      font-size: 11px;
    }
    .closure-area-chip.is-ok { border-style: solid; border-color: rgba(52, 211, 153, 0.5); background: rgba(52, 211, 153, 0.1); color: #b9f5dd; }
    .closure-area-chip b { font-weight: 700; }
    .closure-area-chip em { font-style: normal; opacity: 0.8; }
    .closure-area-chip i { font-style: normal; font-size: 10px; }
    .closure-area-chip i.need { color: #fbbf24; }
    .closure-uploader { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
    .closure-uploader select {
      min-height: 34px; padding: 0 9px; border-radius: 9px;
      border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.78);
      color: var(--hl-fg); font-size: 12px; font-family: inherit;
    }
    .closure-uploader select:focus { outline: none; border-color: rgba(56, 189, 248, 0.7); }
    .closure-photo-tag {
      position: absolute; left: 4px; bottom: 4px; right: 4px;
      padding: 2px 6px; border-radius: 6px; font-size: 9.5px; line-height: 1.4;
      color: #d9f4ff; background: rgba(18, 24, 30, 0.72);
      white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
    }
    .closure-photo-tag.is-permit { color: #ffe6ad; background: rgba(70, 44, 16, 0.78); }
    .closure-photo-item.is-permit { border-color: rgba(251, 191, 36, 0.65); box-shadow: 0 0 0 1px rgba(251, 191, 36, 0.35); }
    .closure-check { display: grid; gap: 4px; padding: 9px 11px; border-radius: 9px; border: 1px solid var(--hl-line); background: rgba(21, 27, 37, 0.5); }
    .cc-row { display: flex; align-items: center; gap: 7px; font-size: 11.5px; color: #ffcf9a; }
    .cc-row i { width: 15px; height: 15px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-style: normal; font-size: 10px; background: rgba(251, 191, 36, 0.18); color: #fbbf24; }
    .cc-row.is-ok { color: #b9f5dd; }
    .cc-row.is-ok i { background: rgba(52, 211, 153, 0.18); color: #34d399; }
    .closure-progress { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
    .cp-item { font-size: 10.5px; padding: 2px 8px; border-radius: 99px; border: 1px solid rgba(251, 191, 36, 0.4); color: #ffd9a0; background: rgba(251, 191, 36, 0.08); }
    .cp-item.is-ok { border-color: rgba(52, 211, 153, 0.45); color: #b9f5dd; background: rgba(52, 211, 153, 0.1); }

    /* ── 单位名录（只读） ── */
    .unit-banner {
      display: flex; align-items: flex-start; gap: 10px;
      padding: 10px 13px; margin-bottom: 14px; border-radius: 12px;
      border: 1px solid rgba(56, 189, 248, 0.28); background: rgba(56, 189, 248, 0.08);
      font-size: 11.5px; line-height: 1.7; color: #cfe8fb;
    }
    .unit-banner b { color: #8fe8ff; }
    .unit-banner-icon { color: var(--hl-cyan-tx); font-size: 14px; line-height: 1.2; }

    .unit-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
    .unit-card {
      border: 1px solid var(--hl-line); border-radius: 13px; overflow: hidden;
      background: linear-gradient(160deg, rgba(26, 36, 50, 0.86), rgba(22, 29, 40, 0.78));
    }
    .unit-head {
      display: flex; align-items: center; justify-content: space-between; gap: 10px;
      padding: 11px 13px; border-bottom: 1px solid var(--hl-line);
      background: rgba(56, 189, 248, 0.05);
    }
    .unit-title { font-size: 13.5px; font-weight: 650; color: var(--hl-fg); letter-spacing: .3px; }
    .unit-chips { display: flex; gap: 6px; flex: none; }
    .unit-body { padding: 10px 13px 6px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 14px; }
    .unit-row { display: flex; align-items: baseline; gap: 8px; min-width: 0; font-size: 11.5px; }
    .unit-row span { flex: none; color: var(--hl-muted); }
    .unit-row b { color: var(--hl-fg-2); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .unit-row b.mono { font-family: ui-monospace, Menlo, monospace; font-size: 11px; letter-spacing: .3px; }
    .unit-foot {
      display: flex; align-items: center; justify-content: space-between; gap: 10px;
      padding: 8px 13px 10px; border-top: 1px dashed var(--hl-line);
      font-size: 11px; color: var(--hl-muted);
    }
    .unit-stat b { color: var(--hl-cyan-tx); font-size: 13px; margin-right: 2px; }
    .unit-note { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 52%; }

    @media (max-width: 900px) {
      .unit-grid { grid-template-columns: 1fr; }
    }

    /* ── 任务动态：按周筛选 ── */
    .task-date-bar {
      display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
      margin: -4px 0 10px; padding: 8px 11px; border-radius: 10px;
      border: 1px solid var(--hl-line); background: rgba(24, 32, 44, 0.5);
    }
    .task-date-bar .tw-label { font-size: 11.5px; color: var(--hl-muted); flex: none; }
    .task-date-bar .mini-input { min-height: 32px; }
    .task-date-bar .tw-hint { font-size: 10.5px; color: rgba(180, 198, 220, 0.95); margin-left: auto; }
    .mini-input {
      min-height: 34px; padding: 4px 10px; border-radius: 9px;
      border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.78);
      color: var(--hl-fg); font-size: 12.5px; font-family: inherit;
      color-scheme: dark;
    }
    .mini-input:focus { outline: none; border-color: rgba(56, 189, 248, 0.55); }
    .mini-input::-webkit-calendar-picker-indicator { filter: invert(0.72); cursor: pointer; }
    .tw-quick {
      cursor: pointer; border: 1px solid var(--hl-line-2); border-radius: 99px;
      background: rgba(125, 175, 230, 0.06); color: var(--hl-fg-2);
      padding: 5px 12px; font-size: 11.5px; font-family: inherit; line-height: 1.4;
      transition: background .15s, border-color .15s, color .15s;
    }
    .tw-quick:hover { border-color: rgba(56, 189, 248, 0.5); color: var(--hl-fg); }
    .tw-quick.is-on { background: rgba(56, 189, 248, 0.18); border-color: rgba(56, 189, 248, 0.55); color: #eaf7ff; font-weight: 600; }
    @media (max-width: 900px) {
      .task-date-bar .tw-hint { margin-left: 0; width: 100%; }
    }

  /* ── 审批单 PDF 预览 ── */
  .pdf-preview { position: fixed; inset: 0; z-index: 130; display: none; }
  .pdf-preview.is-open { display: block; }
  .pdf-mask { position: absolute; inset: 0; background: rgba(2, 6, 14, 0.82); backdrop-filter: blur(3px); }
  .pdf-dialog {
    position: absolute; z-index: 1; left: 50%; top: 50%; transform: translate(-50%, -50%);
    width: min(1000px, calc(100vw - 28px)); height: min(88vh, 1040px);
    display: flex; flex-direction: column; overflow: hidden;
    border: 1px solid rgba(56, 189, 248, 0.28); border-radius: 16px;
    background: #192332; box-shadow: 0 30px 70px rgba(0, 0, 0, 0.6);
  }
  .pdf-head {
    display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
    padding: 11px 14px; border-bottom: 1px solid var(--hl-line);
  }
  .pdf-head-main { min-width: 0; }
  .pdf-title {
    font-size: 13px; font-weight: 650; color: var(--hl-fg);
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  }
  .pdf-meta { margin-top: 2px; font-size: 11px; color: var(--hl-muted); }
  .pdf-actions { margin-left: auto; display: flex; gap: 8px; flex: 0 0 auto; }
  .pdf-pager { display: flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--hl-muted); }
  .pdf-pager button {
    width: 26px; height: 26px; border-radius: 7px; cursor: pointer;
    border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.72);
    color: var(--hl-fg-2); font-size: 15px; line-height: 1;
  }
  .pdf-pager button:hover:not(:disabled) { border-color: rgba(56, 189, 248, 0.6); color: #eafcff; }
  .pdf-pager button:disabled { opacity: 0.35; cursor: default; }
  .pdf-hint {
    padding: 8px 14px; font-size: 11.5px; line-height: 1.7;
    color: #fde68a; background: rgba(120, 53, 15, 0.28);
    border-bottom: 1px solid rgba(251, 191, 36, 0.24);
  }
  .pdf-hint[hidden] { display: none; }
  .pdf-hint b { color: #fef3c7; font-weight: 650; }
  .pdf-hint a { color: #7dd3fc; text-decoration: underline; cursor: pointer; }
  .pdf-body { flex: 1 1 auto; min-height: 0; background: #3a3e45; overflow: auto; padding: 12px; }
  .pdf-page-stage { display: flex; justify-content: center; align-items: flex-start; min-height: 100%; }
  .pdf-page-canvas {
    display: block; width: 100%; max-width: 794px; height: auto;
    background: #fff; border-radius: 2px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
  }
  .pdf-fallback {
    height: 100%; display: grid; place-items: center; padding: 24px; text-align: center;
    color: #dbeafe; font-size: 12.5px; line-height: 1.8;
  }
  .pdf-fallback b { font-size: 14px; color: #eafcff; }
  @media (max-width: 860px) {
    .pdf-dialog { width: calc(100vw - 16px); height: min(86vh, 900px); }
    .pdf-head { padding: 10px 12px; gap: 8px; }
    .pdf-title { font-size: 12.5px; }
    .pdf-pager { margin-left: auto; }
    .pdf-actions { margin-left: 0; width: 100%; }
    .pdf-actions .btn { flex: 1; }
    .pdf-body { padding: 8px; }
  }

  /* ── 任务动态：桌面端滚动区扩展到版块高度的 95% ── */
  .task-scroll { min-height: 0; }
  .task-scroll-head { background: var(--hl-panel); }

  @media (min-width: 1024px) {
    /* 与左侧「新建安装任务」等高：卡片自身不撑高，滚动区绝对定位填满卡片 */
    #task-feed-card { position: relative; display: block; min-height: 520px; }
    #task-feed-card .task-scroll {
      position: absolute; top: 16px; right: 16px; bottom: 18px; left: 16px;
      overflow-y: auto; overflow-x: hidden;
      scrollbar-gutter: stable;
    }
    #task-feed-card .task-scroll-head {
      position: sticky; top: 0; z-index: 3;
      padding-top: 2px; padding-bottom: 2px;
      background: linear-gradient(180deg, var(--hl-panel) 88%, rgba(16, 16, 16, 0));
    }
    #task-feed-card .task-scroll-head .card-head { margin-bottom: 8px; }
    #task-feed-card .task-scroll-head .task-date-bar { margin-top: 0; }
    #task-feed-card .task-list { max-height: none; overflow: visible; padding-right: 0; }
  }

  /* ── 照片处理信息（压缩前后体积）────────────────────────── */
  .photo-meta {
    margin-top: 6px;
    font-family: var(--mono, ui-monospace, Menlo, monospace);
    font-size: 11.5px;
    line-height: 1.4;
    color: #86efac;
    letter-spacing: 0.2px;
  }

  /* ── 待补传提示条 ─────────────────────────────────────── */
  .pending-bar {
    position: fixed;
    left: 50%;
    bottom: 18px;
    transform: translateX(-50%);
    z-index: 99998;
    display: flex;
    align-items: center;
    gap: 10px;
    max-width: min(92vw, 560px);
    padding: 10px 12px 10px 14px;
    border-radius: 12px;
    border: 1px solid rgba(248, 113, 113, 0.5);
    background: rgba(44, 26, 30, 0.96);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(6px);
  }
  .pending-bar .pb-text {
    font-size: 13px;
    line-height: 1.45;
    color: #fecdd3;
  }
  .pending-bar .pb-btn {
    flex: none;
    height: 32px;
    padding: 0 14px;
    border-radius: 8px;
    border: 1px solid rgba(248, 113, 113, 0.6);
    background: rgba(248, 113, 113, 0.18);
    color: #ffe4e6;
    font-size: 12.5px;
    cursor: pointer;
  }
  .pending-bar .pb-btn:disabled { opacity: 0.6; cursor: default; }
  .pending-bar .pb-x {
    flex: none;
    width: 26px;
    height: 26px;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: #fda4af;
    font-size: 17px;
    line-height: 1;
    cursor: pointer;
  }

  /* ── 照片上传失败详情（诊断用，移动端可截图）────────────── */
  .pd-tip {
    position: fixed;
    left: 50%;
    bottom: 74px;
    transform: translateX(-50%);
    z-index: 99997;
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid rgba(248, 113, 113, 0.5);
    background: rgba(44, 26, 30, 0.94);
    color: #fecdd3;
    font-size: 12.5px;
    cursor: pointer;
    white-space: nowrap;
  }
  .pd-mask {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgba(0, 0, 0, 0.55);
  }
  .pd-card {
    width: min(94vw, 460px);
    max-height: 76vh;
    display: flex;
    flex-direction: column;
    border-radius: 14px;
    border: 1px solid rgba(148, 163, 184, 0.3);
    background: #1b2336;
    color: #e2e8f0;
    overflow: hidden;
  }
  .pd-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 14px;
    font-size: 14px;
    font-weight: 700;
    border-bottom: 1px solid rgba(148, 163, 184, 0.2);
  }
  .pd-head button {
    border: 0;
    background: transparent;
    color: #b6c4d4;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
  }
  .pd-body {
    padding: 10px 14px;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
  }
  .pd-row {
    display: flex;
    gap: 10px;
    padding: 6px 0;
    border-bottom: 1px dashed rgba(148, 163, 184, 0.14);
    font-size: 12px;
    line-height: 1.5;
  }
  .pd-row:last-child { border-bottom: 0; }
  .pd-row > span {
    flex: none;
    width: 46px;
    color: #b6c4d4;
  }
  .pd-row > b {
    flex: 1 1 auto;
    min-width: 0;
    font-weight: 400;
    word-break: break-all;
    color: #e2e8f0;
  }
  .pd-foot {
    padding: 10px 14px 14px;
    border-top: 1px solid rgba(148, 163, 184, 0.2);
  }
  .pd-foot button {
    width: 100%;
    height: 36px;
    border-radius: 9px;
    border: 1px solid rgba(56, 189, 248, 0.5);
    background: rgba(56, 189, 248, 0.16);
    color: #bae6fd;
    font-size: 13px;
    cursor: pointer;
  }

  /* ── 可折叠卡片（人员填报 / 本单位在场人员）──────────────── */
  .card.collapse-card { padding: 0; overflow: hidden; }
  .card.collapse-card .card-head {
    margin: 0;
    padding: 13px 16px;
    gap: 10px;
  }
  .card.collapse-card .card-body { padding: 0 16px 18px; }
  .card.collapse-card.is-collapsed .card-body { display: none; }
  .card.collapse-card.is-collapsed .card-head { padding-bottom: 13px; }

  .card-toggle {
    flex: 1 1 200px;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 2px 0;
    border: 0;
    background: transparent;
    color: inherit;
    text-align: left;
    cursor: pointer;
    min-height: 26px;
  }
  .card-toggle:focus-visible { outline: 2px solid rgba(56, 189, 248, 0.6); outline-offset: 3px; border-radius: 6px; }
  .card-toggle .ct-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--hl-fg);
    letter-spacing: 0.2px;
    white-space: nowrap;
  }
  .card-toggle .ct-sub {
    font-size: 11.5px;
    color: var(--hl-muted);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    min-width: 0;
  }
  .card-toggle .ct-chev {
    margin-left: auto;
    flex: none;
    width: 20px;
    height: 20px;
    position: relative;
    border-radius: 6px;
    background: rgba(56, 189, 248, 0.08);
    transition: transform 0.2s ease, background 0.2s ease;
  }
  .card-toggle .ct-chev::before {
    content: '';
    position: absolute;
    left: 7px;
    top: 7px;
    width: 6px;
    height: 6px;
    border-right: 1.6px solid rgba(148, 210, 245, 0.9);
    border-bottom: 1.6px solid rgba(148, 210, 245, 0.9);
    transform: rotate(45deg);
    transition: transform 0.2s ease;
  }
  .card.collapse-card.is-collapsed .card-toggle .ct-chev::before { transform: rotate(-45deg); }
  .card.collapse-card.is-collapsed .card-toggle .ct-chev { background: rgba(56, 189, 248, 0.14); }

  /* 折叠状态下标题行给出人数概览 */
  .card.collapse-card.is-collapsed .card-head { border-bottom: 0; }

  /* ── 在场人员姓名搜索 ───────────────────────────────── */
  .people-search {
    display: flex;
    align-items: center;
    gap: 9px;
    margin: 0 0 10px;
  }
  .people-search input {
    flex: 1 1 auto;
    min-width: 0;
    height: 38px;
    padding: 0 12px;
    border-radius: 10px;
    border: 1px solid var(--hl-line-2);
    background: rgba(21, 27, 37, 0.78);
    color: var(--hl-fg);
    font-size: 15px;
    font-family: inherit;
    transition: border-color 0.18s, box-shadow 0.18s;
    -webkit-appearance: none;
    appearance: none;
  }
  .people-search input::placeholder { color: rgba(148, 163, 184, 0.72); }
  .people-search input:focus {
    outline: none;
    border-color: rgba(56, 189, 248, 0.66);
    box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.13);
  }
  .people-search .ps-hint {
    flex: none;
    font-size: 11.5px;
    color: var(--hl-muted);
    white-space: nowrap;
  }
  .people-search .ps-hint.is-hit { color: #7dd3fc; }
  .ps-mark {
    background: rgba(250, 204, 21, 0.26);
    color: #fde68a;
    border-radius: 3px;
    padding: 0 1px;
  }

  @media (max-width: 900px) {
    .card.collapse-card .card-head { padding: 12px 13px; }
    .card.collapse-card .card-body { padding: 0 13px 15px; }
    .card-toggle { flex: 1 1 100%; }
    .card-toggle .ct-sub { display: none; }
    .card-toggle .ct-chev { width: 22px; height: 22px; }
    .card-toggle .ct-chev::before { left: 8px; top: 8px; }
    .people-search input { height: 42px; font-size: 16px; }
  }
  .card.collapse-card.is-collapsed { align-self: start; }

  /* ── 照片上传阶段提示（处理中 / 上传中 / 校验中）────────── */
  .photo-stage {
    position: fixed;
    left: 50%;
    bottom: 84px;
    transform: translate(-50%, 8px);
    z-index: 99999;
    display: flex;
    align-items: center;
    gap: 10px;
    max-width: min(92vw, 460px);
    padding: 10px 16px 10px 14px;
    border-radius: 12px;
    border: 1px solid rgba(56, 189, 248, 0.42);
    background: rgba(21, 32, 44, 0.96);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(8px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
  }
  .photo-stage.is-on {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, 0);
  }
  .photo-stage.is-done { border-color: rgba(52, 211, 153, 0.5); }
  .photo-stage .ps-spin {
    flex: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid rgba(56, 189, 248, 0.25);
    border-top-color: #38bdf8;
    animation: psSpin 0.8s linear infinite;
  }
  .photo-stage.is-done .ps-spin {
    border-color: rgba(52, 211, 153, 0.9);
    animation: none;
  }
  .photo-stage .ps-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
  .photo-stage .ps-main {
    font-size: 13px;
    font-weight: 600;
    color: #e6f4ff;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .photo-stage.is-done .ps-main { color: #86efac; }
  .photo-stage .ps-sub {
    font-size: 11px;
    color: rgba(148, 197, 226, 0.85);
    line-height: 1.3;
    font-style: normal;
    white-space: nowrap;
  }
  @keyframes psSpin { to { transform: rotate(360deg); } }

  .photo-meta.is-passthrough { color: #fcd34d; }

  @media (max-width: 900px) {
    .photo-stage { bottom: 92px; padding: 9px 14px; }
    .photo-stage .ps-main { font-size: 12.5px; }
  }

  /* =========================================================
     未来科技感主题层（Theme Layer）
     仅视觉：深空蓝紫渐变 / 毛玻璃拟态 / 霓虹光晕 / 蓝紫青渐变描边
     ⚠ 不改任何结构、布局尺寸与交互逻辑，只覆盖颜色、背景、阴影、字体
     ========================================================= */
  :root {
    --hl-bg: #10141c;
    --hl-panel: rgba(34, 40, 54, 0.72);
    --hl-panel-2: rgba(47, 54, 72, 0.80);
    --hl-line: rgba(158, 182, 214, 0.20);
    --hl-line-2: rgba(158, 182, 214, 0.38);
    --hl-fg: #eef3fa;
    --hl-fg-2: #e4edf9;
    --hl-muted: #d3dfee;
    --hl-cyan: #38bdf8;
    --hl-violet: #bfb3ff;
    --hl-cyan-tx: #b3e6fc;
    --hl-ok-tx: #afeed7;
    --hl-warn-tx: #fdde8e;
    --hl-danger-tx: #ffcfd6;
    --hl-violet-tx: #d0c7ff;
    --hl-sep: rgba(158, 182, 214, 0.78);
    --hl-radius: 18px;

    /* 主题扩展 token */
    --tk-glass: linear-gradient(160deg, rgba(43, 50, 68, 0.72), rgba(27, 32, 43, 0.62));
    --tk-glass-2: linear-gradient(160deg, rgba(50, 58, 77, 0.62), rgba(29, 34, 47, 0.5));
    --tk-edge: 0 0 0 1px rgba(158, 182, 214, 0.22);
    --tk-glow-cyan: 0 0 22px -4px rgba(56, 189, 248, 0.42);
    --tk-glow-violet: 0 0 22px -4px rgba(176, 160, 255, 0.42);
    --tk-lift: 0 18px 46px -24px rgba(2, 6, 23, 0.95), 0 2px 8px -4px rgba(2, 6, 23, 0.7);
    --tk-inset: inset 0 1px 0 rgba(255, 255, 255, 0.07);
    --tk-font: "Inter", -apple-system, BlinkMacSystemFont, "SF Pro Display", "PingFang SC",
      "Hiragino Sans GB", "Microsoft YaHei", "Segoe UI", sans-serif;
  }

  /* ── 深空背景：三层星云 + 极淡网格（纯背景，不占布局）── */
  body {
    background-color: #10141c;
    background-image:
      radial-gradient(1200px 620px at 78% -14%, rgba(56, 189, 248, 0.108), transparent 60%),
      radial-gradient(980px 560px at -10% 106%, rgba(139, 92, 246, 0.108), transparent 62%),
      radial-gradient(760px 460px at 50% 44%, rgba(45, 212, 191, 0.045), transparent 68%),
      linear-gradient(rgba(158, 182, 214, 0.026) 1px, transparent 1px),
      linear-gradient(90deg, rgba(158, 182, 214, 0.026) 1px, transparent 1px),
      linear-gradient(180deg, #161a23 0%, #10141c 48%, #0f121a 100%);
    background-size: auto, auto, auto, 62px 62px, 62px 62px, auto;
    background-attachment: fixed;
    font-family: var(--tk-font);
    color: var(--hl-fg);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
  }

  /* ── 侧边栏：磨砂玻璃 + 蓝紫分隔 ── */
  .sidebar {
    background: linear-gradient(180deg, rgba(38, 43, 59, 0.86), rgba(23, 28, 38, 0.9)) !important;
    border-right: 1px solid rgba(158, 182, 214, 0.20);
    -webkit-backdrop-filter: blur(22px) saturate(150%);
    backdrop-filter: blur(22px) saturate(150%);
    box-shadow: 1px 0 0 rgba(255, 255, 255, 0.03), 24px 0 60px -40px rgba(56, 189, 248, 0.35);
  }
  .brand-mark {
    background: linear-gradient(135deg, #22d3ee, #6366f1 52%, #a78bfa) !important;
    color: #04060f !important;
    box-shadow: 0 0 20px -2px rgba(99, 102, 241, 0.6), var(--tk-inset);
  }
  .nav-item {
    border-radius: 13px;
    transition: background 0.2s, box-shadow 0.2s, color 0.2s;
  }
  .nav-item:hover { background: rgba(99, 102, 241, 0.12); }
  .nav-item.is-on {
    background: linear-gradient(120deg, rgba(34, 211, 238, 0.18), rgba(139, 92, 246, 0.20)) !important;
    box-shadow: var(--tk-edge), 0 0 22px -8px rgba(99, 102, 241, 0.7), var(--tk-inset);
    color: #f5f7ff !important;
  }

  /* ── 毛玻璃卡片：半透明 + 微阴影 + 渐变描边（只改视觉，不改尺寸）── */
  .card, .mod-card, .gate-card, .closure-kpi, .kpi, .combo, .overview-card {
    background: var(--tk-glass) !important;
    -webkit-backdrop-filter: blur(18px) saturate(145%);
    backdrop-filter: blur(18px) saturate(145%);
    border-color: rgba(129, 140, 248, 0.16) !important;
    box-shadow: var(--tk-edge), var(--tk-lift), var(--tk-inset);
  }
  .card:hover, .mod-card:hover { box-shadow: var(--tk-edge), 0 22px 54px -26px rgba(2, 6, 23, 1), var(--tk-inset); }

  /* 顶部信息条 / 视图头：轻玻璃 */
  .view-head, .ap-head, .screen-top {
    background: var(--tk-glass-2) !important;
    -webkit-backdrop-filter: blur(16px) saturate(140%);
    backdrop-filter: blur(16px) saturate(140%);
    border-radius: var(--hl-radius);
  }

  /* ── 霓虹按钮 ── */
  .btn {
    border-radius: 12px;
    transition: box-shadow 0.2s, transform 0.16s, background 0.2s, border-color 0.2s;
  }
  .btn.primary {
    background: linear-gradient(135deg, #22d3ee, #6366f1 54%, #a78bfa) !important;
    border-color: transparent !important;
    color: #04060f !important;
    font-weight: 700;
    box-shadow: 0 0 20px -4px rgba(99, 102, 241, 0.7), 0 8px 20px -12px rgba(34, 211, 238, 0.8), var(--tk-inset);
  }
  .btn.primary:hover:not(:disabled) {
    box-shadow: 0 0 30px -2px rgba(99, 102, 241, 0.85), 0 10px 24px -12px rgba(34, 211, 238, 0.95), var(--tk-inset);
    transform: translateY(-1px);
  }
  .btn.primary:disabled { opacity: 0.5; box-shadow: none; }
  .btn.ghost {
    background: rgba(32, 38, 62, 0.55) !important;
    border-color: rgba(129, 140, 248, 0.28) !important;
    color: var(--hl-fg-2) !important;
  }
  .btn.ghost:hover:not(:disabled) {
    border-color: rgba(34, 211, 238, 0.55) !important;
    box-shadow: 0 0 18px -8px rgba(34, 211, 238, 0.8);
  }

  /* ── 数据强调：发光数字 / 徽标 ── */
  .kpi-value, .closure-kpi b, .donut-total b { text-shadow: 0 0 18px rgba(34, 211, 238, 0.32); }
  .kpi.cyan .kpi-value { text-shadow: 0 0 18px rgba(34, 211, 238, 0.45); }
  .kpi.violet .kpi-value { text-shadow: 0 0 18px rgba(167, 139, 250, 0.45); }
  .kpi.green .kpi-value { text-shadow: 0 0 18px rgba(52, 211, 153, 0.4); }
  .chip {
    border-radius: 99px;
    border-color: rgba(129, 140, 248, 0.26);
    background: rgba(99, 102, 241, 0.12);
  }

  /* ── 表单控件：玻璃输入 ── */
  .input, .mini-input, .mini-select, select, textarea {
    background: rgba(24, 28, 44, 0.7) !important;
    border-color: rgba(129, 140, 248, 0.22) !important;
    border-radius: 12px;
    transition: border-color 0.18s, box-shadow 0.18s, background 0.18s;
  }
  .input:focus, .mini-input:focus, select:focus, textarea:focus {
    border-color: rgba(34, 211, 238, 0.7) !important;
    box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.14), 0 0 20px -8px rgba(34, 211, 238, 0.9) !important;
    background: rgba(26, 32, 52, 0.85) !important;
  }

  /* ── 弹窗：磨砂 + 光晕描边 ── */
  .modal-mask { background: rgba(3, 5, 14, 0.72) !important; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
  .modal {
    background: linear-gradient(165deg, rgba(34, 40, 68, 0.92), rgba(23, 26, 42, 0.94)) !important;
    border: 1px solid rgba(129, 140, 248, 0.22) !important;
    box-shadow: 0 0 0 1px rgba(129, 140, 248, 0.12), 0 40px 90px -40px rgba(2, 6, 23, 1),
      0 0 60px -30px rgba(99, 102, 241, 0.8) !important;
    -webkit-backdrop-filter: blur(24px) saturate(150%);
    backdrop-filter: blur(24px) saturate(150%);
  }

  /* ── 区域卡 / 列表项 hover 光晕 ── */
  .zone-card, .task-item, .people-item {
    background: var(--tk-glass-2) !important;
    border-color: rgba(129, 140, 248, 0.14) !important;
    box-shadow: var(--tk-inset);
  }
  .zone-card:hover, .task-item:hover, .people-item:hover {
    border-color: rgba(34, 211, 238, 0.4) !important;
    box-shadow: 0 0 24px -10px rgba(34, 211, 238, 0.75), var(--tk-inset);
  }
  .zone-card.is-active {
    border-color: rgba(34, 211, 238, 0.6) !important;
    background: linear-gradient(160deg, rgba(34, 211, 238, 0.16), rgba(139, 92, 246, 0.14)) !important;
    box-shadow: 0 0 0 1px rgba(34, 211, 238, 0.28) inset, 0 0 28px -10px rgba(34, 211, 238, 0.9);
  }

  /* ── 滚动条 ── */
  * { scrollbar-width: thin; scrollbar-color: rgba(129, 140, 248, 0.35) transparent; }
  ::-webkit-scrollbar { width: 9px; height: 9px; }
  ::-webkit-scrollbar-track { background: transparent; }
  ::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, rgba(34, 211, 238, 0.45), rgba(139, 92, 246, 0.45));
    border-radius: 99px;
    border: 2px solid transparent;
    background-clip: padding-box;
  }
  ::-webkit-scrollbar-thumb:hover { background: linear-gradient(180deg, rgba(34, 211, 238, 0.7), rgba(139, 92, 246, 0.7)); background-clip: padding-box; }

  /* ── 日间高对比度：保证正文与次要文字在亮环境下仍清晰 ── */
  @media (prefers-contrast: more) {
    :root { --hl-muted: #a8b6e0; --hl-fg-2: #dbe3ff;  --hl-cyan-tx: var(--hl-cyan); --hl-ok-tx: var(--hl-ok); --hl-warn-tx: var(--hl-warn); --hl-danger-tx: var(--hl-danger); --hl-violet-tx: var(--hl-violet); --hl-sep: var(--hl-line-2); }
    .card, .mod-card, .kpi { background: rgba(12, 16, 34, 0.92) !important; }
  }
  @media (prefers-reduced-motion: reduce) {
    .btn, .nav-item, .zone-card, .task-item { transition: none; }
  }

  /* 移动端性能降级：固定背景 + 大半径毛玻璃在低端机 / 微信内核上会明显拖慢首屏 */
  @media (max-width: 900px) {
    body { background-attachment: scroll; }
    .card, .mod-card, .gate-card, .closure-kpi, .kpi, .combo, .overview-card,
    .sidebar, .modal {
      -webkit-backdrop-filter: blur(8px) saturate(120%) !important;
      backdrop-filter: blur(8px) saturate(120%) !important;
    }
  }
  @media (hover: none) {
    .card:hover, .mod-card:hover { box-shadow: var(--tk-edge), var(--tk-lift), var(--tk-inset); }
  }

  /* 首屏加载条：数据未到齐时显示，数据填充后自动移除 */
  .load-bar {
    position: fixed; top: 0; left: 0; height: 2px; width: 100%; z-index: 99999;
    background: linear-gradient(90deg, transparent, #22d3ee 35%, #a78bfa 65%, transparent);
    background-size: 45% 100%;
    background-repeat: no-repeat;
    animation: loadSlide 1.1s linear infinite;
    pointer-events: none;
  }
  @keyframes loadSlide { 0% { background-position: -45% 0; } 100% { background-position: 145% 0; } }

  /* 业务数据未到时的占位提示（身份已就绪、界面已显示，数据在后台补齐） */
  .data-pending {
    display: flex; align-items: center; gap: 9px;
    margin: 0 0 14px; padding: 11px 14px; border-radius: 11px;
    border: 1px dashed rgba(125, 175, 230, 0.38);
    background: rgba(125, 175, 230, 0.06);
    font-size: 12.5px; color: var(--hl-muted);
  }
  .data-pending::before {
    content: ''; width: 13px; height: 13px; border-radius: 50%;
    border: 2px solid rgba(125, 175, 230, 0.3); border-top-color: #22d3ee;
    animation: dpSpin 0.8s linear infinite; flex: none;
  }
  @keyframes dpSpin { to { transform: rotate(360deg); } }

  /* =========================================================
     是否必须使用行车（任务填报）
     分段选择 + 强制填写弹窗（吊装物项 / 使用时间 / 时长 / 落点区域）
     ========================================================= */
  .crane-seg { display: flex; gap: 8px; max-width: 260px; }
  .crane-btn {
    flex: 1 1 0; height: 38px; border-radius: 10px; cursor: pointer; font-family: inherit;
    border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.78); color: var(--hl-fg-2);
    font-size: 13px; transition: border-color 0.15s, background 0.15s, color 0.15s, box-shadow 0.15s;
  }
  .crane-btn:hover { border-color: rgba(56, 189, 248, 0.5); }
  .crane-btn.is-on {
    border-color: rgba(56, 189, 248, 0.85); background: rgba(56, 189, 248, 0.16);
    color: #bae6fd; font-weight: 600;
    box-shadow: 0 0 18px -8px rgba(56, 189, 248, 0.9);
  }
  .crane-btn[data-crane="是"].is-on {
    border-color: rgba(251, 191, 36, 0.85); background: rgba(251, 191, 36, 0.14); color: #fde68a;
    box-shadow: 0 0 18px -8px rgba(251, 191, 36, 0.9);
  }

  .crane-sum {
    display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
    margin-top: 9px; padding: 9px 12px; border-radius: 10px;
    border: 1px solid rgba(251, 191, 36, 0.28); background: rgba(251, 191, 36, 0.07);
    font-size: 11.5px; color: var(--hl-fg-2); line-height: 1.6;
  }
  .crane-sum .cs-ok { color: #86efac; font-weight: 600; }
  .crane-sum .cs-warn { color: #fbbf24; font-weight: 600; }
  .crane-sum .cs-edit {
    margin-left: auto; padding: 4px 12px; border-radius: 8px; cursor: pointer;
    border: 1px solid rgba(56, 189, 248, 0.45); background: rgba(56, 189, 248, 0.12);
    color: #bae6fd; font-family: inherit; font-size: 11.5px;
  }
  .crane-sum .cs-edit:hover { background: rgba(56, 189, 248, 0.22); }

  /* 吊装信息弹窗 */
  .modal.crane-modal { width: min(560px, 92vw); }
  .crane-body { display: flex; flex-direction: column; gap: 13px; }
  .crane-body .field { display: flex; flex-direction: column; gap: 6px; }
  .crane-body .field > span { font-size: 12.5px; color: var(--hl-fg-2); }
  .crane-body .field > span i { color: var(--hl-danger-tx); font-style: normal; }
  .crane-body .field-tip { font-size: 10.5px; color: var(--hl-muted); font-style: normal; }
  .crane-body input {
    height: 38px; padding: 0 11px; border-radius: 10px;
    border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.78);
    color: var(--hl-fg); font-family: inherit; font-size: 13px;
  }
  .crane-body input:focus {
    outline: none; border-color: rgba(56, 189, 248, 0.7);
    box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.12);
  }
  .crane-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

  /* ── 预计使用时间段：48 窗格选择器（2 行 × 24 列，每格 30 分钟） ── */
  .ts-box {
    border: 1px solid var(--hl-line); border-radius: 11px;
    padding: 9px 10px 8px; background: rgba(125, 175, 230, 0.05);
  }
  .ts-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 7px; }
  .ts-head b {
    font-size: 12.5px; font-weight: 600; color: var(--hl-muted);
    font-family: var(--mono); letter-spacing: 0.2px;
  }
  .ts-head b.is-set { color: #7dd3fc; }
  .ts-head .ts-clear {
    font-size: 11px; color: var(--hl-muted); background: none; border: 0;
    cursor: pointer; padding: 2px 4px; border-radius: 6px; font-family: inherit;
  }
  .ts-head .ts-clear:hover { color: #fca5a5; background: rgba(248, 113, 113, 0.1); }
  .ts-axis {
    position: relative; height: 12px; margin: 0 0 3px;
    font-family: var(--mono); font-size: 9px; color: var(--hl-muted); opacity: 0.85;
  }
  .ts-axis span { position: absolute; top: 0; transform: translateX(-50%); white-space: nowrap; }
  .ts-axis span.p0 { left: 0; transform: none; }
  .ts-axis span.p1 { left: 33.333%; }
  .ts-axis span.p2 { left: 66.667%; }
  .ts-axis span.p3 { left: 100%; transform: translateX(-100%); }
  .ts-grid {
    display: grid; grid-template-columns: repeat(24, 1fr); gap: 1px;
    touch-action: none; -webkit-user-select: none; user-select: none;
  }
  .ts-cell {
    height: 22px; border-radius: 2px; cursor: pointer;
    background: rgba(125, 175, 230, 0.1);
    transition: background 0.12s;
  }
  .ts-cell:hover { background: rgba(125, 175, 230, 0.24); }
  .ts-cell.is-sel {
    background: linear-gradient(180deg, rgba(56, 189, 248, 0.85), rgba(56, 189, 248, 0.55));
    box-shadow: 0 0 8px -3px rgba(56, 189, 248, 0.9);
  }
  .ts-cell.is-edge { box-shadow: inset 0 0 0 1px rgba(224, 242, 254, 0.75); }
  @media (max-width: 640px) {
    /* 时间段格子：纵向加高，提升手指点选容错（仍保持 30 分钟粒度与 48 格不变） */
    .ts-cell { height: 34px; }
    .ts-grid { gap: 2px; }
    .ts-head b { font-size: 12px; }
    .ts-axis span { font-size: 10px; }
  }

  /* ── 手机端适配（≤480px）：可读性、触控与折叠优化 ── */
  @media (max-width: 480px) {
    /* 顶栏：标题与副标题紧凑，操作行不挤压 */
    .topbar h1 { font-size: 16px; line-height: 1.25; }
    .topbar p { font-size: 11.5px; }
    .topbar { padding: 12px 14px 10px; }

    /* 触控：次级按钮与表单控件最小高度 42px（Apple/Android 触控建议 ≥44，此处兼顾密度） */
    .btn.sm, .btn.primary.sm, .btn.ghost.sm, .card-toggle,
    .chip-btn, .cz-btn, .arc-day-btn, .cs-edit, .combo-toggle,
    .crane-btn, .modal-foot .btn {
      min-height: 42px;
    }
    .combo-toggle { min-width: 42px; }
    .field select, .field input, .field textarea, .mini-select { min-height: 42px; }

    /* 计划进场时间段：格子加高、字号提升，便于手指点选 */
    .slot { height: 38px; font-size: 10.5px; }
    .slot-grid { gap: 4px; }
    .slot-sum { font-size: 12px; }

    /* 任务内容预览：手机端由 2 行放宽到 3 行，减少内容被折叠 */
    .task-content-preview { -webkit-line-clamp: 3; font-size: 12px; line-height: 1.55; }

    /* 可读性：10.5px 级辅助文本抬到 11.5px */
    .kv, .chip, .card-sub, .field-tip, .id-chip span, .sync-pill,
    .task-meta, .zone-recent-item, .cs-note, .unit-row, .data-note {
      font-size: 11.5px;
    }

    /* 表单：标签与输入在窄屏更紧凑，避免横向挤压 */
    .field > span { font-size: 12px; }
    .card { padding: 14px; }
    .content { padding: 12px 12px calc(92px + env(safe-area-inset-bottom)); }
  }

  /* ── 超窄屏（≤360px）：进一步压缩内边距与字号，避免换行错乱 ── */
  @media (max-width: 360px) {
    .content { padding: 10px 10px calc(92px + env(safe-area-inset-bottom)); }
    .card { padding: 12px; }
    .topbar h1 { font-size: 15px; }
    .btn { padding: 0 12px; }
    .ts-cell { height: 30px; }
    .field > span { font-size: 11.5px; }
  }

  .crane-zones { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 2px; }
  .cz-btn {
    min-width: 46px; height: 32px; padding: 0 11px; border-radius: 9px; cursor: pointer;
    border: 1px solid var(--hl-line-2); background: rgba(21, 27, 37, 0.78); color: var(--hl-fg-2);
    font-family: inherit; font-size: 12px; transition: all 0.15s;
  }
  .cz-btn:hover { border-color: rgba(56, 189, 248, 0.5); }
  .cz-btn.is-on {
    border-color: rgba(56, 189, 248, 0.85); background: rgba(56, 189, 248, 0.18);
    color: #bae6fd; font-weight: 600;
  }
  .crane-err { font-size: 11.5px; color: #fca5a5; }

  /* 闭环填报身份提示 */
  .closure-id {
    padding: 8px 11px; border-radius: 9px; font-size: 11.5px; line-height: 1.6; margin-bottom: 9px;
  }
  .closure-id.ok {
    border: 1px solid rgba(52, 211, 153, 0.32); background: rgba(52, 211, 153, 0.09); color: #a7f3d0;
  }
  .closure-id.deny {
    border: 1px solid rgba(248, 113, 113, 0.38); background: rgba(248, 113, 113, 0.1); color: #fecaca;
  }
  .closure-id.deny span { color: #fca5a5; opacity: 0.85; }

  @media (max-width: 640px) {
    .crane-row { grid-template-columns: 1fr; }
    .crane-seg { max-width: none; }
  }

  /* 手机端数据组件未加载时的引导面板 */
  .env-guide {
    position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%);
    z-index: 99998; width: min(360px, calc(100vw - 32px));
    padding: 16px 16px 14px; border-radius: 14px;
    border: 1px solid rgba(251, 191, 36, 0.45);
    background: linear-gradient(165deg, rgba(50, 42, 24, 0.97), rgba(30, 27, 20, 0.98));
    box-shadow: 0 24px 60px -20px rgba(0, 0, 0, 0.85);
    color: #fde68a;
  }
  .env-guide .eg-title { font-size: 14px; font-weight: 700; margin-bottom: 8px; color: #fcd34d; }
  .env-guide .eg-body { font-size: 12px; line-height: 1.75; color: #fde68a; opacity: 0.92; }
  .env-guide .eg-body b { color: #fff7d6; }
  .env-guide .eg-acts { display: flex; gap: 8px; margin-top: 13px; }
  .env-guide .eg-acts .btn { flex: 1 1 0; }

  /* 数据加载失败诊断面板 */
  .diag-panel {
    position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%);
    z-index: 99998; width: min(420px, calc(100vw - 28px));
    max-height: calc(100vh - 60px); overflow-y: auto;
    padding: 15px 15px 13px; border-radius: 14px;
    border: 1px solid rgba(248, 113, 113, 0.42);
    background: linear-gradient(165deg, rgba(46, 28, 32, 0.98), rgba(30, 24, 26, 0.99));
    box-shadow: 0 24px 60px -20px rgba(0, 0, 0, 0.9);
    color: #fecaca;
  }
  .diag-panel .dg-title { font-size: 14px; font-weight: 700; margin-bottom: 10px; color: #fca5a5; }
  .diag-panel .dg-list { display: flex; flex-direction: column; gap: 4px; margin-bottom: 10px; }
  .diag-panel .dg-row {
    display: flex; align-items: baseline; gap: 7px;
    font-size: 11.5px; line-height: 1.5; padding: 5px 8px; border-radius: 7px;
    background: rgba(255, 255, 255, 0.035);
  }
  .diag-panel .dg-row i { font-style: normal; font-weight: 700; }
  .diag-panel .dg-row i.ok { color: #86efac; }
  .diag-panel .dg-row i.bad { color: #ffa8a8; }
  .diag-panel .dg-row span { color: #fecaca; font-family: var(--mono); font-size: 10.5px; }
  .diag-panel .dg-row em { margin-left: auto; font-style: normal; color: #fca5a5; opacity: 0.8; font-size: 10px; }
  .diag-panel .dg-sum {
    font-size: 10.5px; line-height: 1.65; color: #fda4af; opacity: 0.85;
    padding: 8px 9px; border-radius: 8px; background: rgba(16, 16, 16, 0.3);
    word-break: break-all; margin-bottom: 11px;
  }
  /* 网络自检结论 */
  .diag-panel .dg-net {
    font-size: 11px; line-height: 1.6; color: #fecaca;
    padding: 7px 9px; margin-bottom: 9px; border-radius: 8px;
    border: 1px solid rgba(125, 175, 230, 0.28); background: rgba(125, 175, 230, 0.08);
    word-break: break-word;
  }
  .diag-panel .dg-net b { font-weight: 700; }
  .diag-panel .dg-net b.ok { color: #86efac; }
  .diag-panel .dg-net b.bad { color: #ffa8a8; }
  .diag-panel .dg-acts { display: flex; gap: 7px; }
  .diag-panel .dg-acts .btn { flex: 1 1 0; }

  /* 诊断面板：未登录提示 */
  .diag-panel .dg-login {
    padding: 9px 10px; margin-bottom: 10px; border-radius: 9px;
    border: 1px solid rgba(251, 191, 36, 0.45); background: rgba(251, 191, 36, 0.1);
    font-size: 11.5px; line-height: 1.7; color: #fde68a;
  }
  .diag-panel .dg-login b { color: #fcd34d; }
  .diag-panel .dg-acts a.btn { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }

/* =========================================================
   主题层：日间 / 夜间（三端统一 token）
   机制：html[data-theme] = auto | light | dark
        auto → 跟随系统 prefers-color-scheme
   仅覆盖颜色与视觉，不改任何结构与业务逻辑
   ========================================================= */
:root {
  --hl-theme-shadow: 0 10px 30px -18px rgba(2, 10, 24, 0.55);
  --hl-theme-shadow-2: 0 18px 44px -26px rgba(2, 10, 24, 0.7);
  --hl-glass: rgba(8, 14, 24, 0.94);
  --hl-input-bg: rgba(7, 13, 23, 0.78);
  --hl-map-filter: brightness(0.52) saturate(0.85) contrast(1.04);
  --hl-map-blend: screen;
  --hl-body-bg:
    radial-gradient(1100px 560px at 82% -12%, rgba(56, 189, 248, 0.144), transparent 62%),
    radial-gradient(900px 520px at -8% 104%, rgba(167, 139, 250, 0.126), transparent 60%),
    var(--hl-bg);
}

/* ── 日间主题变量 ── */
html[data-theme="light"] {
  --hl-bg: #f2f6fc;
  --hl-panel: rgba(255, 255, 255, 0.94);
  --hl-panel-2: #eaf1fa;
  --hl-line: rgba(23, 62, 110, 0.12);
  --hl-line-2: rgba(23, 62, 110, 0.22);
  --hl-fg: #0f2137;
  --hl-fg-2: #294761;
  --hl-muted: #5d7793; --hl-cyan-tx: var(--hl-cyan); --hl-ok-tx: var(--hl-ok); --hl-warn-tx: var(--hl-warn); --hl-danger-tx: var(--hl-danger); --hl-violet-tx: var(--hl-violet); --hl-sep: var(--hl-line-2);
  --hl-cyan: #0a7ec2;
  --hl-ok: #0f9b6c;
  --hl-warn: #b0700a;
  --hl-danger: #d62f4d;
  --hl-violet: #6b4fd0;

  --hl-theme-shadow: 0 8px 24px -16px rgba(20, 50, 90, 0.35);
  --hl-theme-shadow-2: 0 16px 40px -24px rgba(20, 50, 90, 0.4);
  --hl-glass: rgba(255, 255, 255, 0.96);
  --hl-input-bg: #ffffff;
  --hl-map-filter: brightness(1.04) saturate(0.96) contrast(1.02);
  --hl-map-blend: multiply;
  --hl-body-bg:
    radial-gradient(1100px 560px at 82% -12%, rgba(10, 126, 194, 0.10), transparent 62%),
    radial-gradient(900px 520px at -8% 104%, rgba(107, 79, 208, 0.08), transparent 60%),
    var(--hl-bg);

  color-scheme: light;
}

/* auto 模式下跟随系统浅色 */
@media (prefers-color-scheme: light) {
  html[data-theme="auto"] {
    --hl-bg: #f2f6fc;
    --hl-panel: rgba(255, 255, 255, 0.94);
    --hl-panel-2: #eaf1fa;
    --hl-line: rgba(23, 62, 110, 0.12);
    --hl-line-2: rgba(23, 62, 110, 0.22);
    --hl-fg: #0f2137;
    --hl-fg-2: #294761;
    --hl-muted: #5d7793; --hl-cyan-tx: var(--hl-cyan); --hl-ok-tx: var(--hl-ok); --hl-warn-tx: var(--hl-warn); --hl-danger-tx: var(--hl-danger); --hl-violet-tx: var(--hl-violet); --hl-sep: var(--hl-line-2);
    --hl-cyan: #0a7ec2;
    --hl-ok: #0f9b6c;
    --hl-warn: #b0700a;
    --hl-danger: #d62f4d;
    --hl-violet: #6b4fd0;
    --hl-theme-shadow: 0 8px 24px -16px rgba(20, 50, 90, 0.35);
    --hl-theme-shadow-2: 0 16px 40px -24px rgba(20, 50, 90, 0.4);
    --hl-glass: rgba(255, 255, 255, 0.96);
    --hl-input-bg: #ffffff;
    --hl-map-filter: brightness(1.04) saturate(0.96) contrast(1.02);
    --hl-map-blend: multiply;
    --hl-body-bg:
      radial-gradient(1100px 560px at 82% -12%, rgba(10, 126, 194, 0.10), transparent 62%),
      radial-gradient(900px 520px at -8% 104%, rgba(107, 79, 208, 0.08), transparent 60%),
      var(--hl-bg);
    color-scheme: light;
  }
}

/* ── 日间主题：组件级覆盖（深色硬编码背景 / 发光效果） ── */
html[data-theme="light"] body {
  background: var(--hl-body-bg);
}
html[data-theme="light"] .topbar,
html[data-theme="light"] .mobile-nav {
  background: var(--hl-glass);
  border-color: var(--hl-line);
  box-shadow: var(--hl-theme-shadow);
}
html[data-theme="light"] .card,
html[data-theme="light"] .panel,
html[data-theme="light"] .unit-card,
html[data-theme="light"] .closure-kpi,
html[data-theme="light"] .task-item,
html[data-theme="light"] .zone-panel,
html[data-theme="light"] .slot-picker,
html[data-theme="light"] .crane-body,
html[data-theme="light"] .ts-box {
  background: var(--hl-panel);
  border-color: var(--hl-line);
  box-shadow: var(--hl-theme-shadow);
}
html[data-theme="light"] .modal,
html[data-theme="light"] .boot {
  background: #ffffff;
  border-color: var(--hl-line-2);
  box-shadow: var(--hl-theme-shadow-2);
  color: var(--hl-fg);
}
html[data-theme="light"] input,
html[data-theme="light"] select,
html[data-theme="light"] textarea,
html[data-theme="light"] .mini-select {
  background: var(--hl-input-bg) !important;
  color: var(--hl-fg);
  border-color: var(--hl-line-2);
}
html[data-theme="light"] input::placeholder,
html[data-theme="light"] textarea::placeholder { color: #93a8bd; }
html[data-theme="light"] .slot,
html[data-theme="light"] .ts-cell,
html[data-theme="light"] .cz-btn,
html[data-theme="light"] .crane-btn,
html[data-theme="light"] .chip-btn {
  background: #eef4fb;
  border-color: var(--hl-line-2);
  color: var(--hl-fg-2);
}
html[data-theme="light"] .slot.is-on,
html[data-theme="light"] .ts-cell.is-sel {
  background: linear-gradient(180deg, #38bdf8, #0a7ec2);
  color: #ffffff;
  border-color: #0a7ec2;
}
html[data-theme="light"] .cz-btn.is-on {
  background: rgba(10, 126, 194, 0.14);
  color: #085f93;
  border-color: #0a7ec2;
}
html[data-theme="light"] .chip {
  background: #e9f1fa;
  border-color: var(--hl-line);
  color: var(--hl-fg-2);
}
html[data-theme="light"] .chip.ok { background: rgba(15, 155, 108, 0.12); color: #0b7a55; }
html[data-theme="light"] .chip.warn { background: rgba(176, 112, 10, 0.12); color: #8a5806; }
html[data-theme="light"] .chip.danger { background: rgba(214, 47, 77, 0.12); color: #b02440; }
html[data-theme="light"] .chip.info { background: rgba(10, 126, 194, 0.12); color: #085f93; }

/* 地图：日间恢复真实亮度，热力改用正片叠底 */
html[data-theme="light"] .map-stage img { filter: var(--hl-map-filter); }
html[data-theme="light"] .map-heat { mix-blend-mode: var(--hl-map-blend); opacity: 0.72; }
html[data-theme="light"] .zone-rect { stroke: rgba(10, 126, 194, 0.45); }
html[data-theme="light"] .zone-rect.selected { stroke: #d98a00; }

/* 表格 / 列表 / 分隔线 */
html[data-theme="light"] .data-table th { background: #eaf1fa; color: var(--hl-fg-2); }
html[data-theme="light"] .data-table td { border-color: var(--hl-line); }
html[data-theme="light"] .kv-row,
html[data-theme="light"] .task-actions { border-color: var(--hl-line); }
html[data-theme="light"] .zone-recent-item {
  background: #f4f8fd;
  border-color: var(--hl-line);
}
html[data-theme="light"] .zone-recent-item:hover { border-color: var(--hl-cyan); }

/* 主按钮在日间加深，保证对比度 */
html[data-theme="light"] .btn.primary {
  background: linear-gradient(180deg, #1591d8, #0a6fab);
  color: #ffffff;
  box-shadow: 0 6px 16px -10px rgba(10, 111, 171, 0.8);
}
html[data-theme="light"] .btn.ghost {
  background: #ffffff;
  border-color: var(--hl-line-2);
  color: var(--hl-fg-2);
}

/* 主题切换按钮 */
.theme-toggle {
  display: inline-flex; align-items: center; gap: 6px;
  height: 34px; padding: 0 11px; border-radius: 10px;
  border: 1px solid var(--hl-line-2); background: transparent;
  color: var(--hl-fg-2); font-family: inherit; font-size: 12px;
  cursor: pointer; white-space: nowrap; transition: border-color .15s, color .15s, background .15s;
}
.theme-toggle:hover { border-color: var(--hl-cyan); color: var(--hl-cyan-tx); }
.theme-toggle .tt-icon { font-size: 14px; line-height: 1; }
@media (max-width: 480px) {
  .theme-toggle { min-height: 42px; padding: 0 10px; }
  .theme-toggle .tt-label { display: none; }
}

/* ── 日间主题：选中态可读性（浅底上改深色文字） ── */
html[data-theme="light"] .tw-quick {
  background: #eef4fb; border-color: var(--hl-line-2); color: var(--hl-fg-2);
}
html[data-theme="light"] .tw-quick:hover { border-color: #0a7ec2; color: #085f93; }
html[data-theme="light"] .tw-quick.is-on {
  background: rgba(10, 126, 194, 0.14) !important;
  border-color: #0a7ec2 !important;
  color: #075a8c !important;
  font-weight: 650;
}
html[data-theme="light"] .chip-btn.is-on,
html[data-theme="light"] .chip-btn.active {
  background: rgba(10, 126, 194, 0.14) !important;
  border-color: #0a7ec2 !important;
  color: #075a8c !important;
}
html[data-theme="light"] .picker-card.is-on { border-color: #0a7ec2 !important; color: #075a8c !important; }
html[data-theme="light"] .nav-item.is-active {
  background: linear-gradient(120deg, rgba(10,126,194,0.14), rgba(107,79,208,0.10)) !important;
  color: #075a8c !important;
}

/* ── 日间主题：第二批覆盖（深色渐变卡片 / 侧栏 / KPI / 索引等） ── */
html[data-theme="light"] .kpi,
html[data-theme="light"] .mod-card,
html[data-theme="light"] .zone-card,
html[data-theme="light"] .zone-card.is-active,
html[data-theme="light"] .zone-chip,
html[data-theme="light"] .zone-chip.is-active,
html[data-theme="light"] .zone-metric,
html[data-theme="light"] .zone-recent-item,
html[data-theme="light"] .closure-detail,
html[data-theme="light"] .task-date-bar,
html[data-theme="light"] .sidebar,
html[data-theme="light"] .env-guide,
html[data-theme="light"] .diag-panel,
html[data-theme="light"] .combo-list,
html[data-theme="light"] .picker-card,
html[data-theme="light"] .slot-act,
html[data-theme="light"] .gate-card,
html[data-theme="light"] .pdf-dialog,
html[data-theme="light"] .pd-card {
  background: var(--hl-panel) !important;
  background-image: none !important;
  border-color: var(--hl-line);
  color: var(--hl-fg);
}
html[data-theme="light"] .zone-card.is-active,
html[data-theme="light"] .zone-chip.is-active {
  background: rgba(10, 126, 194, 0.10) !important;
  border-color: rgba(10, 126, 194, 0.45);
}
html[data-theme="light"] .map-stage { background: #e8eef6; }
html[data-theme="light"] .sidebar { border-right-color: var(--hl-line); }
html[data-theme="light"] .sidebar .nav-item { color: var(--hl-fg-2); }
html[data-theme="light"] .sidebar .nav-item.is-active { background: rgba(10, 126, 194, 0.10); color: #085f93; }
html[data-theme="light"] .closure-banner { background: rgba(10, 126, 194, 0.07); border-color: rgba(10, 126, 194, 0.25); color: var(--hl-fg-2); }
html[data-theme="light"] .boot { background: linear-gradient(180deg, #f2f6fc, #e6eef8); }
html[data-theme="light"] .mini-select option { background: #ffffff; color: var(--hl-fg); }
html[data-theme="light"] .picker-card.is-on,
html[data-theme="light"] .combo-item.is-on { background: rgba(10, 126, 194, 0.12); }
html[data-theme="light"] .sync-pill { background: rgba(15, 155, 108, 0.1); color: #0b7a55; }
html[data-theme="light"] .theme-toggle { background: #ffffff; }
html[data-theme="light"] .crane-err { color: #b02440; }

/* ── 日间主题：第三批（侧栏底卡 / 区域面板内部 / 杂项） ── */
html[data-theme="light"] .side-card,
html[data-theme="light"] .zone-head,
html[data-theme="light"] .zone-breakdown,
html[data-theme="light"] .zone-metrics,
html[data-theme="light"] .zone-subzones,
html[data-theme="light"] .zone-subzones-wrap,
html[data-theme="light"] .zone-recent {
  background: transparent;
  border-color: var(--hl-line);
}
html[data-theme="light"] .side-card { background: #e9f0f9; }
html[data-theme="light"] .zone-letter { color: #ffffff; }
html[data-theme="light"] .divider { border-color: var(--hl-line); }
html[data-theme="light"] .kv, html[data-theme="light"] .kv-day, html[data-theme="light"] .tiny { color: var(--hl-fg-2); }
html[data-theme="light"] .row-between { color: var(--hl-fg-2); }
html[data-theme="light"] .gate { background: var(--hl-body-bg); }
html[data-theme="light"] .diag-panel .dg-list,
html[data-theme="light"] .diag-panel .dg-sum { background: rgba(214, 47, 77, 0.06); color: #8a3543; }
html[data-theme="light"] .load-bar { background: rgba(10, 126, 194, 0.14); }
html[data-theme="light"] .chip.plain { background: #eef3f9; }
html[data-theme="light"] .task-meta, html[data-theme="light"] .task-code { color: var(--hl-muted); }
html[data-theme="light"] ::-webkit-scrollbar-thumb { background: rgba(23, 62, 110, 0.22); }

/* ── 日间主题：第四批（科技感层 !important 深色的对等覆盖） ── */
html[data-theme="light"] {
  --tk-glass: linear-gradient(160deg, rgba(255, 255, 255, 0.92), rgba(240, 246, 252, 0.84)) !important;
  --tk-glass-2: linear-gradient(160deg, rgba(255, 255, 255, 0.82), rgba(238, 244, 251, 0.74)) !important;
  --tk-edge: 0 0 0 1px rgba(23, 62, 110, 0.12);
  --tk-lift: 0 14px 36px -22px rgba(20, 50, 90, 0.35), 0 2px 8px -4px rgba(20, 50, 90, 0.22);
  --tk-inset: inset 0 1px 0 rgba(255, 255, 255, 0.85);
}
html[data-theme="light"] .sidebar {
  background: linear-gradient(180deg, #ffffff, #f0f5fb) !important;
}
html[data-theme="light"] .brand-mark {
  background: linear-gradient(135deg, #22d3ee, #0a6fab 52%, #6b4fd0) !important;
  color: #ffffff !important;
}
html[data-theme="light"] .nav-item.is-on {
  background: linear-gradient(120deg, rgba(10, 126, 194, 0.12), rgba(107, 79, 208, 0.12)) !important;
  color: #085f93 !important;
}
html[data-theme="light"] .btn.primary {
  background: linear-gradient(135deg, #38bdf8, #0a6fab 54%, #6b4fd0) !important;
  color: #ffffff !important;
}
html[data-theme="light"] .btn.ghost {
  background: #ffffff !important;
  border-color: rgba(23, 62, 110, 0.22) !important;
  color: var(--hl-fg-2) !important;
}
html[data-theme="light"] .input, html[data-theme="light"] .mini-input,
html[data-theme="light"] .mini-select, html[data-theme="light"] select,
html[data-theme="light"] textarea {
  background: #ffffff !important;
  color: var(--hl-fg) !important;
  border-color: rgba(23, 62, 110, 0.22) !important;
}
html[data-theme="light"] .modal-mask { background: rgba(15, 30, 55, 0.38) !important; }
html[data-theme="light"] .kpi-value, html[data-theme="light"] .closure-kpi b,
html[data-theme="light"] .donut-total b { text-shadow: none; }
html[data-theme="light"] .card, html[data-theme="light"] .mod-card,
html[data-theme="light"] .gate-card, html[data-theme="light"] .closure-kpi,
html[data-theme="light"] .kpi, html[data-theme="light"] .combo, html[data-theme="light"] .overview-card {
  border-color: rgba(23, 62, 110, 0.14) !important;
}

/* ── 日间主题：高亮背景块文字可读性（语义按钮 / 状态标签 / 提示条） ── */
html[data-theme="light"] .btn {
  background: #ffffff;
  border-color: rgba(23, 62, 110, 0.22);
  color: var(--hl-fg-2);
}
html[data-theme="light"] .btn.ok {
  background: rgba(15, 155, 108, 0.12) !important;
  border-color: rgba(15, 155, 108, 0.45) !important;
  color: #0b7a55 !important;
}
html[data-theme="light"] .btn.danger {
  background: rgba(214, 47, 77, 0.10) !important;
  border-color: rgba(214, 47, 77, 0.42) !important;
  color: #b02440 !important;
}
html[data-theme="light"] .btn.warn {
  background: rgba(176, 112, 10, 0.12) !important;
  border-color: rgba(176, 112, 10, 0.42) !important;
  color: #8a5806 !important;
}
html[data-theme="light"] .stage.ok { color: #0b7a55 !important; background: rgba(15, 155, 108, 0.12) !important; }
html[data-theme="light"] .stage.reject { color: #b02440 !important; background: rgba(214, 47, 77, 0.10) !important; }
html[data-theme="light"] .stage.wait { color: #8a5806 !important; background: rgba(176, 112, 10, 0.12) !important; }
html[data-theme="light"] .stage { color: var(--hl-fg-2); }
html[data-theme="light"] .day-tag {
  color: #075a8c !important;
  background: rgba(10, 126, 194, 0.12) !important;
  border-color: rgba(10, 126, 194, 0.4) !important;
}
html[data-theme="light"] .risk-inline {
  color: #8a5806 !important;
  background: rgba(176, 112, 10, 0.10) !important;
  border-left-color: rgba(176, 112, 10, 0.6) !important;
}
html[data-theme="light"] .risk-note, html[data-theme="light"] .field-tip { color: #8a5806; }
html[data-theme="light"] .photo-btn {
  color: #4a6280;
  background: #f4f8fd;
  border-color: rgba(23, 62, 110, 0.22);
}
html[data-theme="light"] .photo-btn:hover { background: #eaf2fb; color: #085f93; border-color: #0a7ec2; }
html[data-theme="light"] .zone-letter {
  background: linear-gradient(135deg, #0a7ec2, #6b4fd0) !important;
  color: #ffffff !important;
}
html[data-theme="light"] .brand-mark {
  background: linear-gradient(135deg, #0e7fb8, #4a3ab0) !important;
  color: #ffffff !important;
}
html[data-theme="light"] .cs-ok { color: #0b7a55 !important; background: rgba(15, 155, 108, 0.12) !important; }
html[data-theme="light"] .cs-warn { color: #8a5806 !important; background: rgba(176, 112, 10, 0.12) !important; }
html[data-theme="light"] .closure-banner { color: #294761; }

/* ── 日间主题：高亮块第二批（审批阶段条 / 选择器 / 主按钮对比） ── */
html[data-theme="light"] .stg { color: var(--hl-fg-2); background: #eef4fb; border-color: var(--hl-line-2); }
html[data-theme="light"] .stg b { color: var(--hl-fg); }
html[data-theme="light"] .stg.ok { color: #0b7a55 !important; background: rgba(15,155,108,0.12) !important; border-color: rgba(15,155,108,0.45) !important; }
html[data-theme="light"] .stg.ok b { color: #0b7a55 !important; }
html[data-theme="light"] .stg.reject { color: #b02440 !important; background: rgba(214,47,77,0.10) !important; border-color: rgba(214,47,77,0.42) !important; }
html[data-theme="light"] .stg.reject b { color: #b02440 !important; }
html[data-theme="light"] .stg.wait { color: #8a5806 !important; background: rgba(176,112,10,0.12) !important; border-color: rgba(176,112,10,0.45) !important; }
html[data-theme="light"] .stg.wait b { color: #8a5806 !important; }
html[data-theme="light"] .zone-picker,
html[data-theme="light"] .people-picker-btn {
  background: #f4f8fd;
  border-color: rgba(23, 62, 110, 0.24);
  color: var(--hl-fg-2);
}
html[data-theme="light"] .zone-picker:hover,
html[data-theme="light"] .people-picker-btn:hover {
  background: #eaf2fb; border-color: #0a7ec2; color: #085f93;
}
/* 主按钮渐变加深，提高白字对比 */
html[data-theme="light"] .btn.primary {
  background: linear-gradient(180deg, #0f8fd0, #0a6a9f) !important;
  color: #ffffff !important;
}
