/* CIS design system — shared semantic structure, with CIS teal/red identity. */
:root{
  --ds-font:"Source Sans Pro","Noto Sans SC","Microsoft YaHei",Arial,sans-serif;
  --ds-canvas:#f4faf9;--ds-surface:#ffffff;--ds-surface-raised:#ffffff;--ds-surface-muted:#f4faf9;--ds-field:#ffffff;
  --ds-text:#14242a;--ds-text-secondary:#50666c;--ds-text-muted:#5a6b72;
  --ds-line:#dbe7e8;--ds-line-strong:#bed0d2;--ds-accent:#00736e;--ds-accent-soft:#e4f4f2;
  --ds-danger:#af2b2e;--ds-radius-sm:8px;--ds-radius-md:12px;--ds-radius-lg:18px;
  --ds-shadow:0 8px 24px rgba(24, 61, 66, 0.08);--ds-shadow-raised:0 14px 34px rgba(24, 61, 66, 0.12);
  --ds-space-1:4px;--ds-space-2:8px;--ds-space-3:12px;--ds-space-4:16px;--ds-space-5:24px;
}
html[data-theme="dark"]{
  --ds-canvas:#101b20;--ds-surface:#1b2d32;--ds-surface-raised:#27464c;--ds-surface-muted:#1b2d32;--ds-field:#14242a;
  --ds-text:#edf8f7;--ds-text-secondary:#bed0d2;--ds-text-muted:#829ba2;
  --ds-line:#3a565e;--ds-line-strong:#4d7378;--ds-accent:#79d8d0;--ds-accent-soft:#27464c;
  --ds-danger:#ff9299;--ds-shadow:0 8px 24px rgba(0, 0, 0, 0.2);--ds-shadow-raised:0 14px 34px rgba(0, 0, 0, 0.3);
}
.cis-app-shell{font-family:var(--ds-font);color:var(--ds-text);font-size:14px;line-height:1.5}
.cis-app-shell :is(h1,h2,h3){letter-spacing:-.015em}.cis-app-shell h1{font-size:28px;font-weight:760;line-height:1.25}.cis-app-shell h2{font-size:20px;font-weight:740;line-height:1.32}.cis-app-shell h3{font-size:16px;font-weight:720;line-height:1.38}
.cis-app-shell :is(.workspace-intro,.saile-data-page-head,.saile-admin-head,.cis-form-context,.sam-document-context){border-radius:var(--ds-radius-lg);box-shadow:var(--ds-shadow)}
.cis-app-shell :is(.formx .form-sec,.formx .form-content-group,.formx .detail-field,.formx .detail-record,.card,.saile-report-data){border-radius:var(--ds-radius-md)}
.cis-app-shell .formx :is(.field>label,.field>.field-label,.detail-record-field>label){color:var(--ds-text-secondary);font-size:13px!important;font-weight:700!important;line-height:1.45}
.cis-app-shell .formx :is(.field>.val,input,select,textarea){font-size:14px!important;line-height:1.5}
.cis-app-shell .formx .field>.val{min-height:42px;border-radius:var(--ds-radius-sm)}
.cis-app-shell :is(.formx,.cis-page) .field-follow-note{color:var(--ds-text-muted)!important;font-size:12px!important;line-height:1.5!important}
.cis-app-shell :is(.formx,.cis-page) small{color:var(--ds-text-muted);font-size:12px!important;line-height:1.45!important}
.cis-app-shell .fill-focus-item>b{font-size:13px;line-height:1.35}
.cis-app-shell :is(.btn,.native-add,.detail-master-add){min-height:36px;border-radius:var(--ds-radius-sm);font-size:13px;font-weight:720;line-height:1.2}
.cis-app-shell .btn-ghost{border-color:var(--ds-line);background:var(--ds-surface);color:var(--ds-text-secondary)}
.cis-app-shell .btn-ghost:hover{border-color:var(--ds-line-strong);background:var(--ds-surface-muted);color:var(--ds-text)}
.cis-app-shell :is(.report-data-grid th,.business-data-row.head){color:var(--ds-text-secondary);font-size:12px;font-weight:750}
.cis-app-shell :is(.report-data-grid td,.business-data-row){font-size:13px;line-height:1.45}
@media(max-width:767px){.cis-app-shell{font-size:14px}.cis-app-shell h1{font-size:24px}.cis-app-shell h2{font-size:18px}.cis-app-shell :is(.workspace-intro,.saile-data-page-head,.saile-admin-head,.cis-form-context,.sam-document-context){border-radius:var(--ds-radius-md)}}


/* 提交检查汇总：校验失败时常驻在表单顶部，替代一闪即逝的 toast。
   每条都是可聚焦按钮，点击直接跳到出错字段。 */
.form-error-summary{
  margin:0 0 16px;border:1px solid color-mix(in srgb,var(--ds-danger) 32%,var(--ds-surface));
  border-left:4px solid var(--ds-danger);border-radius:var(--ds-radius-md);
  background:color-mix(in srgb,var(--ds-danger) 6%,var(--ds-surface));
  box-shadow:var(--ds-shadow);scroll-margin-top:96px;
}
.form-error-summary:focus-visible{outline:2px solid var(--focus-ring,var(--ds-danger));outline-offset:2px}
.form-error-summary>header{display:flex;gap:10px;align-items:flex-start;padding:14px 16px 10px}
.form-error-summary>header>i{
  flex:none;display:grid;width:22px;height:22px;place-items:center;border-radius:50%;
  background:var(--ds-danger);color:#ffffff;font-size:13px;font-style:normal;font-weight:800;line-height:1;
}
.form-error-summary>header b{display:block;color:var(--ds-danger);font-size:15px;font-weight:750;line-height:1.35}
.form-error-summary>header small{display:block;margin-top:2px;color:var(--ds-text-secondary);font-size:12px;line-height:1.5}
.form-error-summary>ol{display:grid;gap:2px;margin:0;padding:0 10px 10px;list-style:none}
.form-error-item{
  display:block;width:100%;padding:8px 10px;border:0;border-radius:var(--ds-radius-sm);
  background:transparent;color:inherit;text-align:left;cursor:pointer;
}
.form-error-item:hover{background:color-mix(in srgb,var(--ds-danger) 9%,transparent)}
.form-error-item:focus-visible{outline:2px solid var(--focus-ring,var(--ds-danger));outline-offset:-2px}
.form-error-item b{display:block;font-size:13px;font-weight:700;line-height:1.4}
.form-error-item small{display:block;color:var(--ds-text-secondary);font-size:12px;line-height:1.45}
.formx .field.invalid{scroll-margin-top:96px}
@media(max-width:767px){.form-error-summary{margin-bottom:12px}.form-error-summary>header{padding:12px 13px 8px}}

/* 高风险操作确认框：替代原生 confirm()，把“改什么、影响谁、能不能撤销”写清楚。 */
.zai-confirm-backdrop{
  position:fixed;z-index:2400;inset:0;display:grid;place-items:center;padding:20px;
  background:rgba(14, 28, 33, 0.42);backdrop-filter:blur(2px);-webkit-backdrop-filter:blur(2px);
}
.zai-confirm{
  width:min(440px,100%);padding:22px 22px 16px;border:1px solid var(--ds-line);
  border-radius:var(--ds-radius-lg);background:var(--ds-surface);box-shadow:var(--ds-shadow-raised);
}
.zai-confirm h2{margin:0;color:var(--ds-text);font-size:19px;font-weight:740;line-height:1.35}
.zai-confirm>p{margin:9px 0 0;color:var(--ds-text-secondary);font-size:14px;line-height:1.6}
.zai-confirm-impact{
  display:grid;gap:6px;margin:14px 0 0;padding:12px 14px;
  border-radius:var(--ds-radius-sm);background:var(--ds-surface-muted);list-style:none;
}
.zai-confirm-impact li{
  position:relative;padding-left:16px;color:var(--ds-text-secondary);font-size:13px;line-height:1.55;
}
.zai-confirm-impact li::before{
  position:absolute;top:.62em;left:3px;width:5px;height:5px;border-radius:50%;
  background:var(--ds-text-muted);content:"";
}
.zai-confirm-danger .zai-confirm-impact{background:color-mix(in srgb,var(--ds-danger) 7%,var(--ds-surface))}
.zai-confirm-danger .zai-confirm-impact li::before{background:var(--ds-danger)}
.zai-confirm-danger h2{color:var(--ds-danger)}
.zai-confirm>footer{display:flex;justify-content:flex-end;gap:10px;margin-top:18px}
.zai-confirm>footer .btn{min-height:40px;padding:0 18px}
@media(max-width:520px){
  .zai-confirm{padding:18px 17px 14px}
  .zai-confirm>footer{flex-direction:column-reverse}
  .zai-confirm>footer .btn{width:100%}
}
/* 暗色配对文字色。这些颜色原先只有亮色字面量，暗色下既不翻转也没有覆盖，
   在深色表面上对比度低到 1.0–2.9:1。亮色侧按 ΔE≤8 归并（标准档预算内）并逐条
   核对自身底色（含写成 var() 的）仍 ≥4.5:1；暗色侧保住色相彩度、只提明度到
   刚好达标。两侧都由脚本核算，不是手调。 */
:root{--text-neutral-strong3:#244047;--text-warn-base6:#a0620d;--text-neutral-base5:#536a7b;--text-teal-strong2:#397875;--text-blue-base5:#4f6bb7;--text-red-strong2:#9b2226;--text-teal-base3:#0a7e5f;--text-blue-strong1:#39546b;--text-blue-base4:#606f86;--text-red-base4:#b12035;--text-teal-soft4:#067e80;--text-green:#137555;--text-red-soft7:#ae3543;--text-teal-strong1:#316360;--text-neutral-base4:#3f5668;--text-neutral-soft7:#617777;--text-warn-strong1:#84500e;--text-warn-base4:#80632e;--text-neutral-strong1:#172d3e;--text-blue-soft7:#8259dc;--text-red-base5:#7a5659;--text-red-base6:#9e4347;--text-red-soft8:#c32631;--text-warn-soft7:#ac5b00;--text-neutral-strong2:#432e30;--text-neutral-soft6:#7c6568;--text-blue-strong2:#49618e;--text-blue-strong3:#5264bd;--text-blue-base6:#2a78af;--text-blue-soft8:#0075cc;--text-red-strong1:#623b3e;--text-red-strong3:#7f4350;--text-red-soft9:#d3364f;--text-warn-strong2:#825225;--text-warn-strong3:#87601d;--text-warn-base5:#7b6b48;--text-warn-soft8:#986a00;}
html[data-theme="dark"]{--text-neutral-strong3:#7a979f;--text-warn-base6:#c78433;--text-neutral-base5:#7e96a8;--text-teal-strong2:#5e9d99;--text-blue-base5:#778fde;--text-red-strong2:#eb6a62;--text-teal-base3:#3fa381;--text-blue-strong1:#7b95af;--text-blue-base4:#8494ac;--text-red-base4:#f46168;--text-teal-soft4:#3ea0a2;--text-green:#49a27f;--text-red-soft7:#e96a71;--text-teal-strong1:#699c98;--text-neutral-base4:#7e95a9;--text-neutral-soft7:#809796;--text-warn-strong1:#c28644;--text-warn-base4:#ae8e56;--text-neutral-strong1:#7f95a9;--text-blue-soft7:#a579ff;--text-red-base5:#b0898b;--text-red-base6:#d87677;--text-red-soft8:#fb5c59;--text-warn-soft7:#d47d2b;--text-neutral-strong2:#a68c8e;--text-neutral-soft6:#a58c90;--text-blue-strong2:#7c92c3;--text-blue-strong3:#7e8be9;--text-blue-base6:#5398d1;--text-blue-soft8:#4894ef;--text-red-strong1:#b48789;--text-red-strong3:#c2808c;--text-red-soft9:#fa5b6c;--text-warn-strong2:#be8757;--text-warn-strong3:#b78b47;--text-warn-base5:#a2916c;--text-warn-soft8:#bc8a2a;}


/* ── 小Zai 对话工作区：--chat-* 的暗色取值 ──────────────────────────────
   这七个 token 此前只有亮色值，于是暗色下正文与品牌字都压在 1.1–1.4:1。
   accent 与 --brand-text 同值；tint/tint-strong 沿面板自身色相抬高明度
   （暗色里的「抬起」就该这样，按亮色那层底的彩度直接搬会读成灰）；
   分隔线转成提亮的白，而不是压暗的深色。
   :is() 连写四遍是**特异度垫高**，不改匹配范围：亮色定义在
   `html .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6`（0,4,2），
   单写一遍只有 (0,3,1) 会输——线上实测过 --chat-ink 仍是亮色值。 */
html[data-theme="dark"] :is(.zai-chat-v6,.zai-chat-v7,.zai-chat-v8,.zai-chat-workspace,.zai-chat-shell,.zai-floating-shell,cis-assistant):is(.zai-chat-v6,.zai-chat-v7,.zai-chat-v8,.zai-chat-workspace,.zai-chat-shell,.zai-floating-shell,cis-assistant):is(.zai-chat-v6,.zai-chat-v7,.zai-chat-v8,.zai-chat-workspace,.zai-chat-shell,.zai-floating-shell,cis-assistant):is(.zai-chat-v6,.zai-chat-v7,.zai-chat-v8,.zai-chat-workspace,.zai-chat-shell,.zai-floating-shell,cis-assistant){--chat-accent:#ff9299;--chat-deep:#ffb5bb;--chat-tint:#213439;--chat-tint-strong:#2c3f44;--chat-line:rgba(255, 255, 255, 0.1);--chat-ink:#ebf2f5;--chat-muted:#a1adb0}


/* ── 小Zai 对话/助手工作区的暗色（Pass E8 生成） ─────────────────────────────
   这块界面原本只有 2–4 条暗色规则，等于没有暗色主题：屏幕上那一版是亮色界面
   被全局暗色规则零散刷到的结果，所以层次全平、还留着白底和近白分隔线。
   写在本文件是因为它最后加载——助手样式的胜出规则在 zai-workspace.css，
   而 design-system.css 还压了 15 条，只有放这里才能稳定生效。
   映射：背景按白度排名落到暗色抬起层（保序）；浅色描边转为同 alpha 的白；
   阴影按感知强度重解；**文字一律不动**（亮色下的白字多压在品牌按钮上，暗色下仍对）。 */
html[data-theme="dark"] .zai-fab{box-shadow:0 10px 26px rgba(0, 0, 0, 0.528);border:1px solid rgba(255, 255, 255, 0.16)}
html[data-theme="dark"] .zai-dialog{border:1px solid rgba(255, 255, 255, 0.16);background:rgba(44, 63, 68, 0.92);box-shadow:0 30px 90px rgba(0, 0, 0, 0.55),inset 0 1px 0 rgba(255, 255, 255, 0.06)}
html[data-theme="dark"] .zai-dialog-head{border-bottom:1px solid rgba(255, 255, 255, 0.16);background:radial-gradient(280px 90px at 90% -40%,rgba(0, 51, 49, 0.13),transparent 72%),rgba(44, 63, 68, 0.84)}
html[data-theme="dark"] .zai-brand-mark{background:linear-gradient(135deg,var(--zai-teal),#003634)}
html[data-theme="dark"] .zai-context{border:1px solid rgba(255, 255, 255, 0.13)}
html[data-theme="dark"] .zai-conversation{background:radial-gradient(360px 170px at 50% -20%,rgba(0, 51, 49, 0.06),transparent 72%),#2b3d42}
html[data-theme="dark"] .zai-orb{border:1px solid rgba(255, 255, 255, 0.12);background:linear-gradient(145deg,#2c3f44,var(--zai-teal-bg))}
html[data-theme="dark"] .zai-starters button{background:rgba(44, 63, 68, 0.86)}
html[data-theme="dark"] .zai-starters button:hover{border-color:rgba(255, 255, 255, 0.16)}
html[data-theme="dark"] .zai-page-facts{border:1px solid rgba(255, 255, 255, 0.14);background:rgba(48, 60, 58, 0.72)}
html[data-theme="dark"] .zai-message.user{background:linear-gradient(135deg,var(--brand),#640002)}
html[data-theme="dark"] .zai-files{border:1px solid rgba(255, 255, 255, 0.14);background:rgba(44, 63, 68, 0.78)}
html[data-theme="dark"] .zai-composer{background:rgba(44, 63, 68, 0.96)}
html[data-theme="dark"] .zai-composer textarea:focus{border-color:rgba(255, 255, 255, 0.16);box-shadow:0 0 0 3px rgba(0, 0, 0, 0.132)}
html[data-theme="dark"] .zai-send{background:linear-gradient(135deg,var(--zai-teal),#003231)}
html[data-theme="dark"] .zai-hub-hero{background:radial-gradient(circle at 50% -15%,rgba(0, 54, 50, 0.36),transparent 22rem),
    radial-gradient(circle at 90% 15%,rgba(189, 58, 62, 0.4),transparent 24rem),
    linear-gradient(125deg,#102f36,#1a4a4d 58%,#5d1a1e 122%);border-bottom:1px solid rgba(255, 255, 255, 0.16);border-color:rgba(255, 255, 255, 0.16);box-shadow:0 1px 0 rgba(255, 255, 255, 0.06) inset,0 28px 68px rgba(0, 0, 0, 0.44)}
html[data-theme="dark"] .zai-hub-hero:after{background:radial-gradient(circle,rgba(0, 51, 49, 0.07),transparent 70%)}
html[data-theme="dark"] .zai-hub-orb{border:1px solid rgba(255, 255, 255, 0.16);background:linear-gradient(145deg,#660000,#86191d);box-shadow:0 15px 36px rgba(0, 0, 0, 0.44),inset 0 1px rgba(255, 255, 255, 0.06);border-color:rgba(255, 255, 255, 0.16)}
html[data-theme="dark"] .zai-hub-orb:after{border:1px solid rgba(255, 255, 255, 0.1)}
html[data-theme="dark"] .zai-hub-composer{border:1px solid rgba(255, 255, 255, 0.16);background:rgba(44, 63, 68, 0.12);box-shadow:inset 0 1px rgba(255, 255, 255, 0.06),0 18px 45px rgba(0, 0, 0, 0.308);border-color:rgba(255, 255, 255, 0.16)}
html[data-theme="dark"] .zai-hub-composer:focus-within{border-color:rgba(255, 255, 255, 0.16);box-shadow:0 24px 68px rgba(0, 0, 0, 0.286),0 0 0 4px rgba(0, 0, 0, 0.099)}
html[data-theme="dark"] .zai-hub-submit{background:linear-gradient(145deg,#680000,#86191d)}
html[data-theme="dark"] .zai-hub-prompts button{border:1px solid rgba(255, 255, 255, 0.16);background:rgba(44, 63, 68, 0.075);border-color:rgba(255, 255, 255, 0.14)}
html[data-theme="dark"] .zai-hub-prompts button:hover{border-color:rgba(255, 255, 255, 0.16)}
html[data-theme="dark"] .zai-hub-stats article{border:1px solid rgba(255, 255, 255, 0.16);background:rgba(44, 63, 68, 0.82);box-shadow:0 8px 26px rgba(0, 0, 0, 0.088),inset 0 1px 0 rgba(255, 255, 255, 0.06)}
html[data-theme="dark"] .zai-hub-stats article:before{background:#00295b}
html[data-theme="dark"] .zai-hub-stats article.red:before{background:#670005}
html[data-theme="dark"] .zai-hub-stats article.blue:before{background:#002773}
html[data-theme="dark"] .zai-hub-stats article.amber:before{background:#4a2500}
html[data-theme="dark"] .zai-hub-panel{border:1px solid rgba(255, 255, 255, 0.16);background:rgba(44, 63, 68, 0.84);box-shadow:0 10px 32px rgba(0, 0, 0, 0.11),inset 0 1px 0 rgba(255, 255, 255, 0.06)}
html[data-theme="dark"] .zai-hub-panel>header{border-bottom:1px solid rgba(255, 255, 255, 0.16)}
html[data-theme="dark"] .zai-hub-item:hover{background:rgba(0, 51, 49, 0.025)}
html[data-theme="dark"] .zai-page-plan .zai-page-overwrite{background:#3e3a34;border-color:#2c454c}
html[data-theme="dark"] .zai-file-item.failed,html[data-theme="dark"] .zai-file-item.partial{border-color:#2c454c;background:#3e3a34}
html[data-theme="dark"] .zai-codex-float>.zai-file-tray{background:rgba(44, 63, 68, 0.98)}
html[data-theme="dark"] .zai-hub-hero::before{background-image:radial-gradient(circle,rgba(44, 63, 68, 0.2) 1px,transparent 1.4px)}
html[data-theme="dark"] .zai-hub-hero::after{background:linear-gradient(90deg,transparent,#620009,#003733,transparent)}
html[data-theme="dark"] .zai-hub-orb::after{border-color:rgba(255, 255, 255, 0.13)}
html[data-theme="dark"] .zai-hub-composer footer{border-top-color:rgba(255, 255, 255, 0.12)}
html[data-theme="dark"] .zai-hub-attach{border:1px solid rgba(255, 255, 255, 0.15) !important;background:rgba(44, 63, 68, 0.08) !important;box-shadow:inset 0 1px rgba(255, 255, 255, 0.04)}
html[data-theme="dark"] .zai-hub-attach:hover{background:rgba(44, 63, 68, 0.15) !important}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-history{background:linear-gradient(180deg,#323b3a 0,#2c3f44 42%,#2a3d42 100%)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-brand-mark{background:linear-gradient(135deg,#00332f,#146778)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-history-new,html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-new{border:1px solid #2c454c}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-history-new:hover,html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-new:hover{border-color:#2c454c}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-history-item.active{border-color:#2c454c}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-main{background:linear-gradient(140deg,#2c3f44 0,#2c3f44 64%,#2a3d42 100%)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-head{background:rgba(44, 63, 68, 0.85)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-workspace-conversation{background:radial-gradient(circle at 72% 9%,rgba(40, 59, 58, 0.65),transparent 28%)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-workspace-welcome>span{background:linear-gradient(135deg,#00332f,#146778)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-workspace-welcome button:hover,html[data-theme="dark"] cis-assistant[data-chat-route] .zai-compose-shortcuts button:hover{border-color:#2c454c}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-workspace-turn.user p{border-color:#2c454c;background:linear-gradient(135deg,#00302d,#146c7b)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-composer-card:focus-within{border-color:#2c454c;box-shadow:0 0 0 3px rgba(0, 0, 0, 0.22),0 8px 18px rgba(0, 0, 0, 0.143)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-composer-actions .zai-send{background:linear-gradient(135deg,#00322e,#146778)}
html[data-theme="dark"] .zai-composer-actions .zai-send:hover{background:#00302d}
html[data-theme="dark"] .zai-composer-actions .zai-send:disabled{background:#213032}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-redesign{box-shadow:0 24px 64px rgba(0, 0, 0, 0.22),inset 0 1px 0 rgba(255, 255, 255, 0.06)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-redesign .zai-history{background:linear-gradient(162deg,#2c3f44 0,#323b3a 100%)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-redesign .zai-brand-mark{background:linear-gradient(145deg,#00322e,#215b70)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-history-collapse{background:rgba(44, 63, 68, 0.8)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-history-collapse:hover{border-color:#2c454c}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-redesign .zai-history-new{border:1px solid rgba(255, 255, 255, 0.16);background:linear-gradient(135deg,rgba(0, 49, 45, 0.12),rgba(38, 110, 126, 0.06)),#2c3f44}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-redesign .zai-history-search{background:rgba(44, 63, 68, 0.76)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-redesign .zai-history-item.active{border-color:rgba(255, 255, 255, 0.16);background:linear-gradient(105deg,rgba(0, 49, 45, 0.12),rgba(44, 63, 68, 0.88) 75%)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-redesign .zai-history-item.active:before{background:linear-gradient(#00322e,#267087)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-redesign .zai-chat-main{background:radial-gradient(760px 300px at 55% -15%,rgba(0, 56, 50, 0.12),transparent 70%),linear-gradient(155deg,#2c3f44,#2a3d42)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-redesign .zai-chat-head{background:rgba(44, 63, 68, 0.75)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-redesign .zai-history-toggle{background:rgba(44, 63, 68, 0.86)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-head-status{border:1px solid rgba(255, 255, 255, 0.15);background:rgba(43, 61, 66, 0.82)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-head-status>i{background:#263a36}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-head-status.processing{border-color:#2c454c}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-head-status.fallback{border-color:#2c454c;background:#3e3a34}
html[data-theme="dark"] .zai-chat-head-status.fallback>i{background:#403621}
html[data-theme="dark"] .zai-chat-redesign .zai-turn-avatar{background:linear-gradient(145deg,#00322e,#246175)}
html[data-theme="dark"] .zai-chat-redesign .zai-workspace-turn.user p{background:linear-gradient(135deg,#00302d,#146778)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-intent-summary{border:1px solid rgba(255, 255, 255, 0.14);background:rgba(43, 61, 66, 0.86)}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-intent-summary.fallback{border-color:#2c454c;background:#3e3a34}
html[data-theme="dark"] .zai-intent-summary.fallback header>span{background:#403621}
html[data-theme="dark"] .zai-intent-summary.fallback header em{background:#403621}
html[data-theme="dark"] .zai-intent-summary-body span{border:1px solid rgba(255, 255, 255, 0.13)}
html[data-theme="dark"] .zai-intent-summary footer{border-top:1px solid rgba(255, 255, 255, 0.14)}
html[data-theme="dark"] .zai-intent-summary footer button{border:1px solid #2c454c}
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-chat-redesign .zai-workspace-composer{background:linear-gradient(180deg,rgba(43, 61, 67, 0.38),rgba(44, 63, 68, 0.94) 35%);box-shadow:0 -13px 30px rgba(0, 0, 0, 0.055)}
html[data-theme="dark"] .zai-chat-redesign .zai-compose-shortcuts button{background:rgba(44, 63, 68, 0.8)}
html[data-theme="dark"] .zai-chat-redesign .zai-composer-card{background:rgba(44, 63, 68, 0.97);box-shadow:0 13px 32px rgba(0, 0, 0, 0.176),inset 0 1px rgba(255, 255, 255, 0.06)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6{border:1px solid rgba(255, 255, 255, 0.16);background:rgba(44, 63, 68, 0.78);box-shadow:0 22px 64px rgba(0, 0, 0, 0.198),inset 0 1px 0 rgba(255, 255, 255, 0.06)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-history{background:linear-gradient(180deg,rgba(44, 63, 68, 0.98),rgba(42, 60, 65, 0.95))}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-brand-mark{box-shadow:0 8px 18px rgba(0, 0, 0, 0.44),inset 0 1px rgba(255, 255, 255, 0.06)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-history-collapse{background:rgba(44, 63, 68, 0.7)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-history-new{background:rgba(44, 63, 68, 0.86)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-history-search{background:rgba(44, 63, 68, 0.72)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-history-item.active{background:linear-gradient(100deg,rgba(175, 43, 46, 0.095),rgba(44, 63, 68, 0.82))}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-chat-main{background:radial-gradient(720px 300px at 52% -18%,rgba(175, 43, 46, 0.055),transparent 72%),linear-gradient(180deg,rgba(44, 63, 68, 0.96),rgba(44, 63, 68, 0.92))}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-chat-head{background:rgba(44, 63, 68, 0.72)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-chat-head-status{background:rgba(44, 63, 68, 0.64)}
html[data-theme="dark"] .zai-assistant-avatar{background:#2c3f44 url('/assets/zai-avatars/xiaozai-cis.png?v=20260905-zai-v2') center/118% no-repeat !important}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-workspace-turn.user p{background:linear-gradient(135deg,var(--chat-tint),rgba(44, 63, 68, 0.96))}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-workspace-welcome button{background:rgba(44, 63, 68, 0.72)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-intent-summary{background:rgba(43, 61, 66, 0.72)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-workspace-composer{background:linear-gradient(180deg,rgba(44, 63, 68, 0.15),rgba(44, 63, 68, 0.96) 28%)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-compose-shortcuts button{background:rgba(44, 63, 68, 0.72)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-composer-card{box-shadow:0 13px 36px rgba(0, 0, 0, 0.176),inset 0 1px 0 rgba(255, 255, 255, 0.06)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-composer-card:focus-within{box-shadow:0 15px 40px rgba(0, 0, 0, 0.209),0 0 0 3px rgba(0, 0, 0, 0.099)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-chat-head-status.model-name{background:rgba(43, 61, 66, 0.78)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-chat-head-status.model-name.fallback{border-color:rgba(255, 255, 255, 0.16);background:#3e3a34}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-voice[aria-pressed=true]{box-shadow:0 0 0 4px rgba(0, 0, 0, 0.176)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7.voice-listening .zai-composer-card{box-shadow:0 15px 42px rgba(0, 0, 0, 0.242),0 0 0 4px rgba(0, 0, 0, 0.121)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-composer-card{background:linear-gradient(135deg,#2a3d42 0%,#2c3f44 22%,#2c3f44 100%);box-shadow:0 10px 26px rgba(0, 0, 0, 0.165),inset 0 1px 0 rgba(255, 255, 255, 0.06)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-input-tool{box-shadow:inset 0 1px 0 rgba(255, 255, 255, 0.06)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-input-tool:hover{border-color:#2c454c}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-composer-card:has(textarea:placeholder-shown) .zai-send,html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-send:disabled{background:linear-gradient(145deg,#003238,#003037)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-compose-shortcuts button{border-color:rgba(255, 255, 255, 0.16);background:rgba(44, 63, 68, 0.72)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-send{box-shadow:0 5px 12px rgba(0, 0, 0, 0.308);background:linear-gradient(145deg,#003339,#006f76)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-composer-card:focus-within{border-color:#2c454c;box-shadow:0 0 0 3px rgba(0, 0, 0, 0.198),0 10px 26px rgba(0, 0, 0, 0.165)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-workspace-composer{background:linear-gradient(180deg,rgba(43, 61, 67, 0),rgba(43, 61, 67, 0.96) 55%,#2c3f44)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-history{background:linear-gradient(180deg,#2c3f44 0%,#2c3f44 100%)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-chat-main{background:radial-gradient(760px 260px at 58% -14%,rgba(0, 50, 55, 0.055),transparent 70%),linear-gradient(180deg,#2c3f44,#2c3f44 100%)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-chat-head{background:rgba(44, 63, 68, 0.86)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-workspace-turn.user p{background:linear-gradient(135deg,#2b3d43,#2c3f44)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v7 .zai-intent-summary{background:rgba(44, 63, 68, 0.78)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v8 .zai-chat-main{background:linear-gradient(180deg,#2c3f44 0%,#2c3f44 100%)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v8 .zai-chat-head{background:rgba(44, 63, 68, 0.94)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v8 .zai-workspace-turn.user p{border:1px solid #2c454c}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v8 .zai-workspace-composer{background:rgba(44, 63, 68, 0.96);box-shadow:0 -8px 24px rgba(0, 0, 0, 0.055)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v8 .zai-composer-card:focus-within{border-color:#2c454c;box-shadow:0 0 0 3px rgba(0, 0, 0, 0.154)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v8 .zai-composer-card:has(textarea:placeholder-shown) .zai-send,html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v8 .zai-send:disabled{background:#223135}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-floating-shell{border:1px solid rgba(255, 255, 255, 0.14);box-shadow:0 20px 48px rgba(0, 0, 0, 0.55),0 4px 14px rgba(0, 0, 0, 0.308)}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-floating-brand{border-right:1px solid rgba(255, 255, 255, 0.15)}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-floating-plus{background:rgba(44, 63, 68, 0.09)}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-floating-plus:hover{background:rgba(44, 63, 68, 0.16)}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-floating-compose kbd{border:1px solid rgba(255, 255, 255, 0.16);color:var(--ds-text-muted)}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-floating-send{background:#003135}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-floating-send:hover{background:#003537}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-floating-collapse:hover{background:rgba(44, 63, 68, 0.12)}
html[data-theme="dark"] .formx .zai-date-trigger{background:linear-gradient(180deg,#2c3f44,color-mix(in srgb,var(--brand-bg) 30%,#2c3f44));box-shadow:0 3px 10px rgba(0, 0, 0, 0.11),inset 0 1px 0 rgba(255, 255, 255, 0.06)}
html[data-theme="dark"] .formx .zai-date-popover{background:rgba(44, 63, 68, 0.98);box-shadow:0 18px 48px rgba(0, 0, 0, 0.396)}
html[data-theme="dark"] .formx .zai-date-head button:hover{background:color-mix(in srgb,var(--brand) 14%,#2c3f44)}
html[data-theme="dark"] .formx .zai-date-day.is-selected{background:linear-gradient(135deg,var(--brand),color-mix(in srgb,var(--brand) 78%,#00238b))}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-codex-result{border:1px solid rgba(255, 255, 255, 0.16);box-shadow:0 14px 36px rgba(0, 0, 0, 0.44)}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-codex-result>button:hover{background:rgba(44, 63, 68, 0.065)}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-codex-thinking i{background:#003735}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-codex-command{border:1px solid rgba(255, 255, 255, 0.16);box-shadow:0 20px 48px rgba(0, 0, 0, 0.55)}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-codex-attach:hover,html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-codex-voice:hover,html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-codex-collapse:hover{background:rgba(44, 63, 68, 0.1)}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-codex-model{border:1px solid rgba(255, 255, 255, 0.14)}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-codex-send{background:#223132}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v8 .zai-history-item.active{border-color:#2c454c}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v8 .zai-workspace-welcome button:hover{border-color:#2c454c}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v8 .zai-send{background:#003033}
@media(max-width:820px){
html[data-theme="dark"] cis-assistant[data-chat-route] .zai-history{box-shadow:14px 0 30px rgba(0, 0, 0, 0.33)}
}


/* ── 暗色下仍为浅色的背景（Pass E9 生成） ───────────────────────────────
   这些规则把背景写死成亮色字面量，暗色主题从没覆盖过它们，于是在深色界面上
   留下一块白药丸；品牌文字提亮后压在上面更读不出来。修的是背景而不是文字：
   映射同 Pass E8——按白度排名保序落到暗色抬起层，alpha 与 var() 原样保留。 */
html[data-theme="dark"] .hdr-grad{background:radial-gradient(320px 190px at 106% -25%, rgba(44, 63, 68, 0.16), transparent 65%),
    repeating-linear-gradient(115deg, rgba(44, 63, 68, 0.05) 0 1.5px, transparent 1.5px 13px),
    var(--grad)}
html[data-theme="dark"] .cis-org-select>i{background:#34383d}
html[data-theme="dark"] .workbench-filters button{background:rgba(44, 63, 68, 0.74)}
html[data-theme="dark"] .workbench-kind.templates{background:#15111e}
html[data-theme="dark"] .workbench-process-switcher button{background:rgba(44, 63, 68, 0.72)}
html[data-theme="dark"] .workbench-process-switcher button.active{background:linear-gradient(135deg,#2c3f44,var(--brand-bg))}
html[data-theme="dark"] .workbench-stage-filters button{background:rgba(44, 63, 68, 0.65)}
html[data-theme="dark"] .workbench-type-row button{background:rgba(44, 63, 68, 0.7)}
html[data-theme="dark"] .workbench-owner-avatar{background:linear-gradient(135deg,#610009,#af2b2e)}
html[data-theme="dark"] .cis-intake-head>span{background:linear-gradient(145deg,#003432,#08736f)}
html[data-theme="dark"] .cis-review-actions .btn:disabled,html[data-theme="dark"] .cis-full-actions .btn:disabled{background:#25373c}
html[data-theme="dark"] .cis-approval-metrics span{background:rgba(41, 59, 65, 0.82)}
html[data-theme="dark"] .cis-approval-metrics span:first-child,html[data-theme="dark"] .cis-approval-metrics span:last-child{background:rgba(0, 51, 50, 0.08)}
html[data-theme="dark"] .cis-top-nav-item:hover{background:rgba(42, 60, 66, 0.9)}
html[data-theme="dark"] .cis-top-user>.avatar{background:linear-gradient(135deg,#610009,var(--brand))}
html[data-theme="dark"] .report-center-hero>label{background:rgba(40, 58, 63, 0.9)}
html[data-theme="dark"] .saile-admin-card{background:rgba(44, 63, 68, 0.86)}
html[data-theme="dark"] .saile-report-tab:hover{background:rgba(44, 63, 68, 0.72)}
html[data-theme="dark"] .workbench-ai-prompts button{background:rgba(44, 63, 68, 0.72)}
html[data-theme="dark"] .workbench-ai-result.warn>i{background:#322a1f}
html[data-theme="dark"] .workbench-ai-result.info>i{background:#272b34}
html[data-theme="dark"] .workbench-ai-result.ok>i{background:#222d28}
html[data-theme="dark"] .usage-table th{background:rgba(42, 61, 66, 0.75)}
html[data-theme="dark"] .usage-person i{background:linear-gradient(135deg,var(--brand,#4f6bb7),#003432)}
html[data-theme="dark"] .cis-workbench-actions .workbench-smart-action{background:linear-gradient(112deg,#2a3d42 0%,#323b3a 62%,#2d3b3d 100%) padding-box,
    linear-gradient(115deg,#003532 0%,#003642 48%,#00352d 100%) border-box}
html[data-theme="dark"] .workbench-primary-card{background:linear-gradient(135deg,rgba(44, 63, 68, 0.97),rgba(44, 63, 68, 0.92))}
html[data-theme="dark"] .workbench-other-stats button{background:rgba(44, 63, 68, 0.72)}
html[data-theme="dark"] .workbench-common-forms a{background:linear-gradient(135deg,#2c3f44,#2c3f44)}
html[data-theme="dark"] .workbench-common-forms a:nth-child(3) i{background:#322a1f}
html[data-theme="dark"] .workbench-common-forms a:nth-child(4) i{background:#272b34}
html[data-theme="dark"] .workbench-list-hint{background:linear-gradient(90deg,#283a3f,#283a3f)}
html[data-theme="dark"] .workbench-common-launches>a:nth-child(3n)>i{background:#322a1f !important}
html[data-theme="dark"] .workbench-primary-card.other{background:linear-gradient(120deg,#2c3f44,#2c3f44)}
html[data-theme="dark"] .cis-workbench-actions .workbench-smart-chip{background:linear-gradient(140deg,#005e5b,#00322f)}
html[data-theme="dark"] .workbench-year-panel button:hover b{background:#283637}
html[data-theme="dark"] .workbench-year-panel button.active b{background:rgba(44, 63, 68, 0.18)}
html[data-theme="dark"] .account-profile-avatar{background:linear-gradient(145deg,#003332,#087f79)}
html[data-theme="dark"] .workbench-personal-expenses>header>b.is-error{background:#322a1f}
html[data-theme="dark"] .workbench-personal-expense-source.error>i{background:#322a1b}
html[data-theme="dark"] .workbench-personal-expense-source.error em{background:#322a1b}
html[data-theme="dark"] .cis-fill-guidance-head>em.warn{background:#322a1b}
html[data-theme="dark"] .cis-fill-guidance-head>em.ok{background:#222d28}
html[data-theme="dark"] .cis-fill-guidance-list button{background:rgba(44, 63, 68, 0.9)}
html[data-theme="dark"] .cis-fill-guidance-list i{background:#322a1f}
html[data-theme="dark"] .cis-full-main>.form-sec:not(.approval-sec)>h3{background:linear-gradient(100deg,#192b30,#1b2d32)}
html[data-theme="dark"] .cis-application-summary .cis-fill-guidance>i{background:#322a1f}
html[data-theme="dark"] .cis-application-summary .cis-fill-guidance.ok>i{background:#222d28}
html[data-theme="dark"] .sam-document-context header em.pending{background:#322a1b}
html[data-theme="dark"] .sam-document-context header em.ok{background:#222d28}
html[data-theme="dark"] .formx .anchor-nav .fchip.done>em{background:rgba(0, 52, 22, 0.1)}
html[data-theme="dark"] .section-name>.num{background:linear-gradient(135deg,var(--brand),#003432)}
html[data-theme="dark"] .section-status b{background:rgba(39, 57, 62, 0.72)}
html[data-theme="dark"] .section-status.done b{background:rgba(0, 52, 22, 0.09)}
html[data-theme="dark"] .auto-data-icon{background:rgba(0, 52, 22, 0.1)}
html[data-theme="dark"] .detail-record-toggle>span{background:rgba(47, 57, 57, 0.86)}
html[data-theme="dark"] .display-value,html[data-theme="dark"] .detail-display{background:rgba(43, 61, 66, 0.78)}
html[data-theme="dark"] .node-edit-mark{background:#322a1b}
html[data-theme="dark"] .sam-approval-command-decision textarea{background:rgba(44, 63, 68, 0.94)}
html[data-theme="dark"] .form-rail-v2 .cis-fill-guidance>i{background:#322a1f}
html[data-theme="dark"] .form-rail-v2 .cis-fill-guidance.ok>i{background:#222d28}
html[data-theme="dark"] .expense-ticket-main{background:radial-gradient(circle at 100% 0,rgba(0, 143, 138, 0.08),transparent 34%),#2c3f44}
html[data-theme="dark"] .expense-ticket-select{background:linear-gradient(135deg,var(--brand),#003432)}
html[data-theme="dark"] .expense-ticket-group .reimbursement-editable-input{background:linear-gradient(145deg,#2a3d42,#2c3f44)}
html[data-theme="dark"] .applause-hero>em{background:rgba(27, 45, 50, 0.9)}
html[data-theme="dark"] .applause-step>header>i{background:linear-gradient(135deg,var(--brand),#003430)}
html[data-theme="dark"] .applause-person-remove{background:rgba(40, 58, 63, 0.9)}
html[data-theme="dark"] .applause-story>textarea,html[data-theme="dark"] .applause-story-read{background:linear-gradient(145deg,#00161b,rgba(0, 22, 27, 0.92))}
html[data-theme="dark"] .formx.applause-mode .cis-recovery-note{background:#2c2923}
html[data-theme="dark"] .detail-field-hint{background:rgba(43, 61, 66, 0.92)}
html[data-theme="dark"] .report-contract-filters input{background:rgba(44, 63, 68, 0.74)}
html[data-theme="dark"] .btn-ghost{background:rgba(44, 63, 68, 0.76)}
html[data-theme="dark"] .cis-form-context .cis-form-meta span,html[data-theme="dark"] .cis-form-context .cis-form-meta a{background:rgba(44, 63, 68, 0.1)}
html[data-theme="dark"] .field input,html[data-theme="dark"] .field select,html[data-theme="dark"] .field textarea,html[data-theme="dark"] .field .val,html[data-theme="dark"] .form-sec input,html[data-theme="dark"] .form-sec select,html[data-theme="dark"] .form-sec textarea{background:rgba(44, 63, 68, 0.78)}
html[data-theme="dark"] .empty,html[data-theme="dark"] .precheck{background:rgba(42, 60, 65, 0.7)}
html[data-theme="dark"] .cis-top-nav a.router-link-active{background:linear-gradient(145deg,#1b2d32,#2f2425)}
html[data-theme="dark"] .workbench-ai-auto > header .chip{background:rgba(0, 53, 44, 0.13)}
html[data-theme="dark"] .workbench-ai-result{background:linear-gradient(145deg,rgba(44, 63, 68, 0.1),rgba(44, 63, 68, 0.045))}
html[data-theme="dark"] .workbench-ai-result.warn > i{background:rgba(80, 31, 0, 0.13)}
html[data-theme="dark"] .workbench-ai-result.ok > i{background:rgba(0, 53, 38, 0.13)}
html[data-theme="dark"] .workbench-ai-result.info > i{background:rgba(0, 42, 99, 0.13)}
html[data-theme="dark"] .cis-form-context .cis-form-meta a:hover{background:rgba(44, 63, 68, 0.17)}
html[data-theme="dark"] .native-report th,html[data-theme="dark"] .native-table th{background:rgba(39, 57, 62, 0.72)}
html[data-theme="dark"] .cis-workbench-kpi{background:linear-gradient(145deg,rgba(27, 45, 50, 0.96),rgba(25, 43, 48, 0.83))}
html[data-theme="dark"] .workbench-zero-state{background:radial-gradient(circle at 50% 8%,#252d2d 0,rgba(38, 46, 46, 0.55) 20%,#1f3136 58%)}
html[data-theme="dark"] .saile-admin-card>i{background:color-mix(in srgb,var(--admin-accent) 10%,#2c3f44) !important}
html[data-theme="dark"] .admin-split>.tree .ti.sel{background:#3f3838 !important}
html[data-theme="dark"] .cis-role-editor-error{background:#2c2923}
html[data-theme="dark"] .cis-data-scope-editor-meta>p{background:#2c2923}
html[data-theme="dark"] .report-category-nav-item.active{background:#2d2626}
html[data-theme="dark"] .cis-app-shell .cis-logout{background:rgba(31, 49, 54, 0.72)}
html[data-theme="dark"] .cis-app-shell .cis-top-notification{background:rgba(44, 63, 68, 0.78)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-history-collapse{background:rgba(40, 58, 63, 0.7)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-history-new{background:rgba(31, 49, 54, 0.86)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-workspace-turn.user p{background:linear-gradient(135deg,var(--chat-tint),rgba(27, 45, 50, 0.96))}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-workspace-welcome button{background:rgba(44, 63, 68, 0.72)}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] .zai-chat-v6 .zai-compose-shortcuts button{background:rgba(40, 58, 63, 0.72)}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-floating-plus{background:rgba(44, 63, 68, 0.09)}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-floating-collapse:hover{background:rgba(44, 63, 68, 0.12)}
html[data-theme="dark"] .formx input[type="date"],html[data-theme="dark"] .formx input[type="datetime-local"]{background:linear-gradient(180deg,#2c3f44,color-mix(in srgb,var(--brand-bg) 34%,#2c3f44)) !important}
html[data-theme="dark"] .cis-app-shell + cis-assistant .zai-codex-send{background:#223132}
html[data-theme="dark"] .cis-workbench-prefill{background:linear-gradient(120deg,#2a3d42 0%,#2c3f44 70%)}
html[data-theme="dark"] .cis-business-domain>nav>a{background:rgba(44, 63, 68, 0.72)}
html[data-theme="dark"] .cis-business-center-hero>a{background:rgba(44, 63, 68, 0.82)}
html[data-theme="dark"] .cis-business-portal-identity>i{background:rgba(0, 22, 27, 0.72)}
html[data-theme="dark"] .cis-business-portal-identity nav span{background:rgba(44, 63, 68, 0.64)}
html[data-theme="dark"] .formx .detail-record-field>input,html[data-theme="dark"] .formx .detail-record-field>select,html[data-theme="dark"] .formx .detail-record-field .selector-control>input{background:linear-gradient(180deg,#2c3f44,color-mix(in srgb,var(--brand-bg) 30%,#2c3f44)) !important}
html[data-theme="dark"] .formx .field .selector-control>input{background:linear-gradient(180deg,#2c3f44,color-mix(in srgb,var(--brand-bg) 30%,#2c3f44))}
html[data-theme="dark"] .role-data-notice{background:#2c2923}
html[data-theme="dark"] .role-permission-state.is-unknown{background:#2c2923}
html[data-theme="dark"] .bre-warning{background:#2c2923}
html[data-theme="dark"] .cis-app-shell .domain-directory>div>a{background:#2c3f44}
html[data-theme="dark"] body .approval-pagination .approval-page-buttons button[aria-current="page"]{background:color-mix(in srgb,var(--page-accent) 9%,#00161b)}
html[data-theme="dark"] body .cis-approval-list .approval-process-tabs .fchip strong{background:#272b30}
html[data-theme="dark"] body .cis-approval-list .approval-process-tabs .fchip.on strong{background:rgba(44, 63, 68, 0.18)}
html[data-theme="dark"] body .cis-approval-list .request-card-status.request-invoice b{background:#322a1f}
html[data-theme="dark"] .approval-decision button{background:#1b2d32}
@media(max-width:767px){
html[data-theme="dark"] .cis-app-shell .domain-mobile-switch select{background:#1f3136}
}

/* ── 小Zai 对话工作区的表面层次（暗色专属，手写） ──────────────────────────
   v8 那层把侧栏、抬头、主区、输入区**全部**指向 var(--ds-surface)。亮色下这是
   「一张白纸 + 浅灰描边」，读起来干净；暗色下浅灰描边几乎看不见，于是整块塌成
   一个色，谁也分不出边界。

   层次是**向下**拉开的：内容区维持原表面，外围 chrome 与侧栏依次下沉。
   先试过反过来（把抬头和输入区抬亮），线上实测压在上面的既有次要文字掉到
   3.96–4.34:1——内容区的既有文字色全是按那个表面调的，抬亮它就等于破坏它们。
   现在这版用实测到的五个次要文字色回验过，每级最差 ≥4.6:1。 */
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] :is(.zai-chat-v6,.zai-chat-v7,.zai-chat-v8) .zai-history{background:#102227;border-right-color:#2c454c}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] :is(.zai-chat-v6,.zai-chat-v7,.zai-chat-v8) .zai-history>header,html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] :is(.zai-chat-v6,.zai-chat-v7,.zai-chat-v8) .zai-history>footer{background:#102227;border-color:#2c454c}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] :is(.zai-chat-v6,.zai-chat-v7,.zai-chat-v8) .zai-history-search{background:#15272c;border-color:#2c454c}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] :is(.zai-chat-v6,.zai-chat-v7,.zai-chat-v8) .zai-chat-head{background:#15272c;border-bottom-color:#2c454c}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] :is(.zai-chat-v6,.zai-chat-v7,.zai-chat-v8) .zai-chat-main{background:#1b2d32}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] :is(.zai-chat-v6,.zai-chat-v7,.zai-chat-v8) .zai-workspace-composer,html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] :is(.zai-chat-v6,.zai-chat-v7,.zai-chat-v8) .zai-composer{background:#15272c;border-top-color:#2c454c}
html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] :is(.zai-chat-v6,.zai-chat-v7,.zai-chat-v8) .zai-composer-card,html[data-theme="dark"] .cis-app-shell cis-assistant[data-chat-route] :is(.zai-chat-v6,.zai-chat-v7,.zai-chat-v8) .zai-input-tools{background:#1b2d32;border-color:#2c454c}

/* 欢迎页那颗徽标：底色被自动映射成了浅色品牌调，白色 ✦ 压上去只有 2.23:1。
   它是「品牌色实心块 + 白字」，暗色下该保持饱和而不是提亮。
   :is() 连写四遍同样是特异度垫高：胜出的亮色规则是
   `html .<系统> .zai-chat-v6 .zai-welcome .zai-orb`（0,4,1），单写一遍只有 (0,1,1)。 */
html[data-theme="dark"] :is(.zai-orb):is(.zai-orb):is(.zai-orb):is(.zai-orb){background:linear-gradient(145deg,#c84240,#af2b2e);border-color:rgba(255, 255, 255, 0.14)}


/* ── 当文字用、却没有暗色变体的颜色 token（Pass E10 生成） ─────────────
   --brand 修完之后，角色权限页线上仍然是 2.19:1——那条规则用的是 var(--role-accent)。
   判据：被用作 color、暗色作用域里没重新定义过、解析出来压在暗色表面上 < 4.5:1。
   逐定义点生成而不是写一条全局的，因为 --domain / --pv 按类别有 5–6 个不同取值，
   压平会毁掉区分。同时当背景用的走 --<token>-text 配对，只改文字用法。 */
html[data-theme="dark"] .cis-business-domain{--domain-text:#ff8d83}
html[data-theme="dark"] .cis-business-domain.legal{--domain-text:#b4a7c9}
html[data-theme="dark"] .cis-business-domain.people{--domain-text:#e69e4c}
html[data-theme="dark"] .cis-business-domain.technology{--domain-text:#79b7cd}
html[data-theme="dark"] .cis-business-domain.integrity{--domain-text:#5cbdb5}
html[data-theme="dark"] .cis-business-portal{--domain-text:#ff8d83}
html[data-theme="dark"] .cis-business-portal.legal{--domain-text:#b4a7c9}
html[data-theme="dark"] .cis-business-portal.people{--domain-text:#e69e4c}
html[data-theme="dark"] .cis-business-portal.technology{--domain-text:#79b7cd}
html[data-theme="dark"] .cis-business-portal.integrity{--domain-text:#5cbdb5}
html[data-theme="dark"] .formx.applause-mode{--applause-ink:#a2aebc}
html[data-theme="dark"] .formx.applause-mode{--applause-coral:#ff89a3}
html[data-theme="dark"] .business-role-dialog{--bre-ink:#a8aeb4}
html[data-theme="dark"] .workbench-process-context{--pv-text:#80adff}
html[data-theme="dark"] .workbench-process-context.red{--pv-text:#ff8c82}
html[data-theme="dark"] .workbench-process-context.violet{--pv-text:#c897ff}
html[data-theme="dark"] .workbench-process-context.cyan{--pv-text:#5eb9d7}
html[data-theme="dark"] .workbench-process-context.amber{--pv-text:#ed9b33}
html[data-theme="dark"] .workbench-process-context.teal{--pv-text:#4ebdba}
html[data-theme="dark"] .cis-workbench-kpi.request{--kpi-color:#74b9c4}
html[data-theme="dark"] .cis-workbench-kpi.processed{--kpi-color:#70bba0}
html[data-theme="dark"] .cis-workbench-kpi.attention{--kpi-color:#ed9a4b}
html[data-theme="dark"] body :is(.cis-approval-list, .sam-app-shell) .approval-pagination{--page-accent-text:#9fa6ff}
html[data-theme="dark"] body .cis-approval-list .approval-pagination{--page-accent-text:#ff8d89}


/* ── 当文字用、却没有暗色变体的颜色 token（Pass E10 生成） ─────────────
   --brand 修完之后，角色权限页线上仍然是 2.19:1——那条规则用的是 var(--role-accent)。
   判据：被用作 color、暗色作用域里没重新定义过、解析出来压在暗色表面上 < 4.5:1。
   逐定义点生成而不是写一条全局的，因为 --domain / --pv 按类别有 5–6 个不同取值，
   压平会毁掉区分。另一半是「有暗色变体但不够用」的：Pass C 那批配对 token 的暗色值
   是按画布/卡面算的，压在抬起层上会掉到 3.3–3.8，这里按暗色实际取值复判后提亮。
   压平会毁掉区分。同时当背景用的走 --<token>-text 配对，只改文字用法。 */
html[data-theme="dark"] .role-workspace{--role-accent-text-text:#ff8c82}
html[data-theme="dark"] .business-role-dialog{--role-accent-text-text:#ff8c82}
html[data-theme="dark"] .audit-workspace,html[data-theme="dark"] .audit-dialog{--audit-accent-text-text:#ff8c82}
html[data-theme="dark"]{--text-red-soft7:#ff8b90}
html[data-theme="dark"]{--text-warn-soft8:#daa445}
html[data-theme="dark"]{--text-blue-soft8:#6db1ff}
html[data-theme="dark"]{--text-red-soft9:#ff8a96}
html[data-theme="dark"]{--text-warn-base6:#e59e4c}
html[data-theme="dark"]{--text-blue-soft7:#c899ff}
html[data-theme="dark"]{--text-blue-strong1:#95b0ca}
html[data-theme="dark"]{--text-blue-strong2:#98aee0}
html[data-theme="dark"]{--text-red-strong2:#ff8c81}
html[data-theme="dark"]{--text-blue-base5:#93a9fb}
html[data-theme="dark"]{--text-green:#66bf9a}
html[data-theme="dark"]{--text-teal-base3:#5ec09c}
html[data-theme="dark"]{--text-red-soft8:#ff8c83}
html[data-theme="dark"]{--text-warn-soft7:#f39745}
html[data-theme="dark"]{--text-blue-strong3:#9ca7ff}
html[data-theme="dark"]{--text-neutral-base5:#98b1c3}
html[data-theme="dark"]{--text-neutral-base4:#98b0c4}
html[data-theme="dark"]{--text-neutral-strong3:#94b2ba}
html[data-theme="dark"]{--text-blue-base4:#9eafc7}
html[data-theme="dark"]{--text-neutral-strong1:#99b0c4}
html[data-theme="dark"]{--text-red-base4:#ff8b8e}
html[data-theme="dark"]{--text-neutral-soft7:#9ab2b1}
html[data-theme="dark"]{--text-warn-strong1:#e0a05d}
html[data-theme="dark"]{--text-blue-base6:#71b3ed}
html[data-theme="dark"]{--text-warn-base5:#bdab85}
html[data-theme="dark"]{--text-warn-strong2:#dba170}
html[data-theme="dark"]{--text-teal-strong1:#83b7b3}
html[data-theme="dark"]{--text-teal-strong2:#79b8b4}
html[data-theme="dark"]{--text-red-base6:#f69191}
html[data-theme="dark"]{--text-warn-strong3:#d4a560}
html[data-theme="dark"]{--text-red-strong3:#df9aa6}
html[data-theme="dark"]{--text-warn-base4:#caa86f}
html[data-theme="dark"]{--chat-muted:#a4b0b3}
html[data-theme="dark"]{--text-neutral-strong2:#c3a8aa}
html[data-theme="dark"]{--text-red-base5:#cca3a5}
html[data-theme="dark"]{--text-red-strong1:#d0a1a3}
html[data-theme="dark"]{--text-neutral-soft6:#c2a8ac}
html[data-theme="dark"]{--text-teal-soft4:#5ebdbe}

/* --ink-4 与 --ds-text-muted 的暗色值压在抬起层上也不够。它们被 E10 归为「双用」
   而没自动改，但逐处查过：各自只有 1 处当背景用——侧栏拖拽把手的 hover 填色、
   确认框列表的小圆点，上面都没有文字，提亮反而更对。文字用法则有 269–367 处。 */
html[data-theme="dark"]{--ink-4:#9cb1b7;--ds-text-muted:#98b2b9}

/* 浮动助手输入区的快捷键提示原本是 52% 半透明文字，合成到暗底上只有 4.27–4.39:1。
   半透明文字的实际颜色取决于底色，静态检查按设计跳过 alpha<0.95 的情况，所以前面
   几个 Pass 都没覆盖到它——是线上逐元素实测才找出来的。这里换成不透明的次要文字色。 */
