/* =========================================================
 * OUSIF 调研演示网站 · 主样式
 * 深色科技风：深藏青底 + 科技蓝/青强调；零外链、系统字体栈
 * ========================================================= */

:root {
  --bg: #0b1220;
  --bg-2: #0e1830;
  --panel: #131f38;
  --panel-2: #17263f;
  --line: #22355c;
  --text: #e7eefb;
  --muted: #93a6c9;
  --accent: #35c4ff;
  --accent-2: #2dd4bf;
  --warn: #ffb454;
  --ok: #34d399;
  --std: #34d399;   /* 〔标准〕绿 */
  --draft: #fbbf24; /* 〔草案〕琥珀 */
  --radius: 12px;
  --font: "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body { height: 100%; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}

code, .code { font-family: Consolas, "Courier New", monospace; }

button { font-family: var(--font); cursor: pointer; }

/* ---------- 顶栏与模式 Tab ---------- */
.topbar {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 10px 22px;
  background: var(--bg-2);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 50;
}
.topbar .brand {
  font-weight: 700;
  font-size: 17px;
  letter-spacing: 0.5px;
  white-space: nowrap;
}
.topbar .brand em { color: var(--accent); font-style: normal; }
.mode-tabs { display: flex; gap: 6px; margin-left: auto; }
.mode-tab {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--muted);
  border-radius: 999px;
  padding: 7px 20px;
  font-size: 15px;
  transition: color .3s ease, border-color .3s ease, background .3s ease;
}
.mode-tab:hover { color: var(--text); border-color: var(--accent); }
.mode-tab.active {
  color: #04121f;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  border-color: transparent;
  font-weight: 700;
}

.mode-pane { display: none; min-height: calc(100vh - 57px); }
.mode-pane.active { display: block; }

/* ---------- 徽标：〔标准〕绿 / 〔草案〕琥珀 ---------- */
.tag {
  display: inline-block;
  font-size: 0.42em;
  font-weight: 700;
  line-height: 1;
  padding: 0.35em 0.7em;
  border-radius: 999px;
  vertical-align: middle;
  position: relative;
  cursor: default;
  white-space: nowrap;
}
.tag-std { color: #06281c; background: var(--std); }
.tag-draft { color: #3a2a00; background: var(--draft); }
.tag[data-src]:hover::after {
  content: attr(data-src);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 8px);
  transform: translateX(-50%);
  background: #0a1020;
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
  font-weight: 400;
  line-height: 1.5;
  padding: 8px 12px;
  border-radius: 8px;
  width: max-content;
  max-width: 340px;
  white-space: normal;
  z-index: 90;
  box-shadow: 0 8px 24px rgba(0,0,0,.5);
  pointer-events: none;
}

/* ---------- 演示模式 ---------- */
#mode-slides { position: relative; }
.slide-stage {
  position: relative;
  height: calc(100vh - 57px);
  min-height: 600px;
  overflow: hidden;
  background:
    radial-gradient(1200px 500px at 80% -10%, rgba(53,196,255,.08), transparent 60%),
    radial-gradient(900px 500px at 10% 110%, rgba(45,212,191,.06), transparent 60%),
    var(--bg);
}
.slide {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 4vh 6vw 10vh;
  opacity: 0;
  transform: translateX(40px);
  transition: opacity .45s ease-out, transform .45s ease-out;
  pointer-events: none;
}
.slide.current { opacity: 1; transform: none; pointer-events: auto; }
.slide.leaving { opacity: 0; transform: translateX(-40px); }

.slide h1 {
  font-size: clamp(28px, 3.4vw, 46px);
  line-height: 1.25;
  margin-bottom: 3.2vh;
  color: var(--text);
  border-left: 6px solid var(--accent);
  padding-left: 18px;
}

/* 统一入场动效：淡入 + 位移，子元素逐级 */
.slide-anim { opacity: 0; transform: translateY(22px); transition: opacity .5s ease-out, transform .5s ease-out; }
.slide.current .slide-anim { opacity: 1; transform: none; }
.slide.current .slide-anim:nth-of-type(1) { transition-delay: .08s; }
.slide.current .slide-anim:nth-of-type(2) { transition-delay: .2s; }
.slide.current .slide-anim:nth-of-type(3) { transition-delay: .32s; }
.slide.current .slide-anim:nth-of-type(4) { transition-delay: .44s; }

.big-list { list-style: none; font-size: clamp(20px, 1.9vw, 28px); }
.big-list li { margin: 1.6vh 0; padding-left: 1.2em; position: relative; }
.big-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.62em;
  width: 0.45em; height: 0.45em;
  border-radius: 2px;
  background: var(--accent);
}
.big-list.left { text-align: left; }
.num-list { counter-reset: n; }
.num-list li { counter-increment: n; }
.num-list li::before {
  content: counter(n);
  background: var(--panel-2);
  border: 1px solid var(--accent);
  color: var(--accent);
  border-radius: 50%;
  width: 1.1em; height: 1.1em;
  top: 0.3em;
  font-size: 0.8em;
  font-weight: 700;
  text-align: center;
  line-height: 1.15em;
}
.big-list strong, .slide strong { color: var(--accent); }
.big-list strong.warn, .slide strong.warn { color: var(--warn); }
.big-list strong.ok, .slide strong.ok { color: var(--ok); }

.slide blockquote {
  margin-top: 3vh;
  padding: 1.6vh 2vw;
  border-left: 4px solid var(--accent-2);
  background: rgba(45,212,191,.07);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-size: clamp(18px, 1.7vw, 25px);
  color: var(--accent-2);
}
.slide-foot { margin-top: 2.4vh; color: var(--muted); font-size: clamp(14px, 1.2vw, 18px); }
.slide-lead { font-size: clamp(18px, 1.6vw, 24px); color: var(--muted); margin-bottom: 2vh; }

/* 封面页 */
.cover-box { text-align: center; }
.cover-sub { font-size: clamp(24px, 2.6vw, 38px); color: var(--accent); margin: 2vh 0 4vh; font-weight: 700; }
.cover-tag {
  display: inline-block;
  border: 1px solid var(--line);
  color: var(--muted);
  border-radius: 999px;
  padding: 8px 26px;
  font-size: clamp(15px, 1.3vw, 19px);
  margin-bottom: 5vh;
}
.cover-agenda { font-size: clamp(19px, 1.8vw, 26px); color: var(--text); line-height: 2; }
.cover-box .big-list { display: inline-block; text-align: left; margin-bottom: 4vh; }

/* 页码 / 按钮 */
.slide-hud {
  position: absolute;
  left: 22px; bottom: 16px;
  color: var(--muted);
  font-size: 14px;
  z-index: 20;
  display: flex; gap: 14px; align-items: center;
}
.slide-hud .page-no { font-variant-numeric: tabular-nums; font-size: 15px; color: var(--text); }
.slide-tools {
  position: absolute;
  right: 22px; bottom: 14px;
  display: flex; gap: 8px;
  z-index: 20;
}
.ghost-btn {
  background: rgba(19,31,56,.8);
  border: 1px solid var(--line);
  color: var(--muted);
  border-radius: 8px;
  padding: 6px 14px;
  font-size: 14px;
  transition: color .3s, border-color .3s;
}
.ghost-btn:hover { color: var(--accent); border-color: var(--accent); }

/* 讲稿抽屉 */
.speaker-drawer {
  position: fixed;
  top: 0; right: 0; bottom: 0;
  width: min(420px, 90vw);
  background: #0d1730;
  border-left: 1px solid var(--line);
  box-shadow: -12px 0 40px rgba(0,0,0,.5);
  transform: translateX(100%);
  transition: transform .4s ease-out;
  z-index: 100;
  display: flex; flex-direction: column;
}
.speaker-drawer.open { transform: none; }

/* 讲稿抽屉打开时，顶栏与内容区同步让位，避免抽屉遮挡正文 */
.topbar, .mode-pane { transition: margin-right .4s ease-out; }
body.notes-open .topbar,
body.notes-open .mode-pane { margin-right: min(420px, 90vw); }
/* 抽屉打开后可用宽度变窄：幻灯改为顶端对齐、竖向可滚动，
   双栏版式降为单栏，防止内容溢出、与右下按钮碰撞 */
body.notes-open .slide {
  justify-content: flex-start;
  overflow-y: auto;
  padding-bottom: 72px;
}
body.notes-open .journey-layout,
body.notes-open .mxn-layout { grid-template-columns: 1fr; }
/* 抽屉打开且幻灯可滚动时，左下页码与右下按钮加实底，避免滚动内容透到控件下面 */
body.notes-open .slide-hud,
body.notes-open .slide-tools {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 4px 10px;
}
body.notes-open .slide-tools { padding: 6px; }
.speaker-drawer header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--line);
  display: flex; justify-content: space-between; align-items: center;
  font-weight: 700;
}
.speaker-drawer .notes-body {
  padding: 20px;
  white-space: pre-wrap;
  color: var(--text);
  font-size: 15.5px;
  line-height: 1.9;
  overflow-y: auto;
}

/* 快捷键帮助 */
.help-overlay {
  position: fixed; inset: 0;
  background: rgba(4,10,22,.82);
  display: none;
  align-items: center; justify-content: center;
  z-index: 120;
}
.help-overlay.open { display: flex; }
.help-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px 36px;
  min-width: 340px;
}
.help-card h3 { margin-bottom: 14px; color: var(--accent); }
.help-card table { border-collapse: collapse; font-size: 15px; }
.help-card td { padding: 5px 14px 5px 0; color: var(--muted); }
.help-card td:first-child { color: var(--text); font-weight: 700; white-space: nowrap; }

/* ---------- 第 2 页：M×N 动画 ---------- */
.mxn-layout { display: grid; grid-template-columns: 5fr 6fr; gap: 3vw; align-items: center; }
.mxn-stage { position: relative; }
#mxnSvg { width: 100%; height: auto; display: block; }
.mxn-caption {
  text-align: center;
  font-size: clamp(18px, 1.8vw, 26px);
  font-weight: 700;
  min-height: 1.6em;
  margin-top: 6px;
  color: var(--warn);
  transition: color .4s;
}
.mxn-caption.solved { color: var(--ok); }
.mxn-stage .ghost-btn { display: block; margin: 8px auto 0; }
.mxn-node-label { font-size: 22px; fill: var(--text); font-family: var(--font); }
.mxn-node-sub { font-size: 14px; fill: var(--muted); font-family: var(--font); }
.mxn-line { fill: none; stroke: var(--warn); stroke-width: 1.6; opacity: .85; }
.mxn-line.solution { stroke: var(--accent-2); stroke-width: 2.4; }
.mxn-hub { fill: #123c2f; stroke: var(--accent-2); stroke-width: 2; }

/* ---------- 第 3 页：翻译中枢流程图 ---------- */
.flow-diagram {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.2vw;
  margin: 2vh 0 4vh;
}
.flow-col { display: flex; flex-direction: column; gap: 1.4vh; }
.flow-node {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.4vh 1.4vw;
  text-align: center;
  font-size: clamp(16px, 1.5vw, 22px);
  font-weight: 700;
}
.flow-node .node-sub { display: block; font-size: 0.62em; color: var(--muted); font-weight: 400; margin-top: 2px; }
.flow-node.dev { border-color: #3a4a75; }
.flow-node.hub { border-color: var(--accent-2); background: rgba(45,212,191,.1); color: var(--accent-2); }
.flow-node.proto { border-color: var(--accent); background: rgba(53,196,255,.1); color: var(--accent); }
.flow-node.api { border-color: var(--accent); }
.flow-node.plat { border-color: var(--ok); background: rgba(52,211,153,.1); color: var(--ok); }
.flow-arrow {
  width: 2.6vw; height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  position: relative;
  border-radius: 2px;
}
.flow-arrow::after {
  content: "";
  position: absolute;
  right: -1px; top: -5px;
  border-left: 11px solid var(--accent-2);
  border-top: 6.5px solid transparent;
  border-bottom: 6.5px solid transparent;
}
.flow-diagram [data-order] { opacity: 0; transform: translateY(16px) scale(.96); transition: opacity .45s ease-out, transform .45s ease-out; }
.flow-diagram [data-order].in { opacity: 1; transform: none; }

/* ---------- 第 4 页：分层架构图 ---------- */
.arch-wrap { position: relative; max-width: 1100px; margin: 0 auto; }
.arch-flight { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 5; overflow: visible; }
.arch-wrap > .arch-layer, .arch-link, .arch-bottom {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .5s ease-out, transform .5s ease-out, box-shadow .5s ease-out, border-color .5s ease-out;
}
.arch-wrap .lit { opacity: 1; transform: none; }
.arch-bottom > .arch-layer { opacity: 1; transform: none; }
.arch-layer {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2vh 2vw;
  text-align: center;
}
.arch-layer .arch-label { display: block; font-size: clamp(18px, 1.8vw, 26px); font-weight: 700; }
.arch-layer .arch-detail { display: block; margin-top: 6px; color: var(--muted); font-size: clamp(13px, 1.2vw, 17px); }
.arch-platform { border-color: var(--ok); }
.arch-core { border-color: var(--accent); background: rgba(53,196,255,.07); }
.arch-adapter { border-color: var(--accent-2); }
.arch-link {
  text-align: center;
  color: var(--accent);
  font-size: clamp(14px, 1.3vw, 18px);
  padding: 1vh 0;
}
.arch-link::before { content: "▲"; display: block; font-size: 0.8em; color: var(--accent-2); }
.arch-bottom { display: grid; grid-template-columns: 1fr 1fr; gap: 2vw; }
.arch-wrap .lit.pulse { box-shadow: 0 0 0 2px rgba(53,196,255,.35), 0 0 30px rgba(53,196,255,.15); }

/* ---------- 第 5 页：对比表 ---------- */
.cmp-table {
  width: 100%;
  max-width: 1100px;
  border-collapse: collapse;
  font-size: clamp(16px, 1.5vw, 22px);
  margin-bottom: 3vh;
}
.cmp-table th, .cmp-table td {
  border: 1px solid var(--line);
  padding: 1.4vh 1.2vw;
  text-align: left;
}
.cmp-table thead th { background: var(--panel-2); color: var(--accent); font-size: 1.1em; }
.cmp-table tbody td:first-child { color: var(--muted); white-space: nowrap; }

/* ---------- 第 6 页：四卡片 ---------- */
.card-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2vh 2vw; max-width: 1200px; }
.key-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2.2vh 1.6vw;
  transition: border-color .3s;
}
.key-card:hover { border-color: var(--accent); }
.key-card h3 { color: var(--accent); font-size: clamp(19px, 1.8vw, 26px); margin-bottom: 1vh; }
.key-card p { font-size: clamp(15px, 1.4vw, 20px); color: var(--text); margin-bottom: 1.2vh; }
.key-card code { color: var(--accent-2); font-size: 0.86em; }

/* ---------- 第 7 页：报文旅行 ---------- */
.journey-layout { display: grid; grid-template-columns: 5fr 6fr; gap: 2vw; align-items: start; }
.journey-map { display: flex; flex-direction: column; gap: 1.2vh; }
.jm-row {
  display: flex; align-items: center; gap: 10px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 1.2vh 1vw;
  font-size: clamp(13px, 1.15vw, 17px);
  transition: border-color .4s, background .4s, box-shadow .4s;
}
.jm-row .jm-priv { color: var(--warn); font-family: Consolas, monospace; flex: 1; word-break: break-all; }
.jm-row .jm-arrow { color: var(--accent-2); font-weight: 700; }
.jm-row .jm-std { color: var(--accent-2); font-family: Consolas, monospace; flex: 1.2; word-break: break-all; }
.jm-row.active {
  border-color: var(--accent);
  background: rgba(53,196,255,.09);
  box-shadow: 0 0 18px rgba(53,196,255,.18);
}
.journey-json {
  background: #081020;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2vh 1.4vw;
  font-family: Consolas, "Courier New", monospace;
  font-size: clamp(13px, 1.15vw, 17.5px);
  line-height: 1.75;
  overflow-x: auto;
}
.jl { color: var(--muted); border-radius: 6px; padding: 0 8px; transition: background .35s, color .35s; white-space: pre; }
.jl .jl-key { color: #7fb3e8; }
.jl .jl-str { color: var(--accent-2); }
.jl .jl-topic { color: var(--warn); }
.jl-reply { margin-top: 8px; border-top: 1px dashed var(--line); padding-top: 8px; }
.jl.active { background: rgba(53,196,255,.13); color: var(--text); }
.journey-bar { display: flex; align-items: center; gap: 12px; margin-top: 2vh; }
.journey-step-text {
  flex: 1;
  min-height: 2.6em;
  font-size: clamp(15px, 1.4vw, 20px);
  color: var(--text);
  background: rgba(19,31,56,.7);
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: 8px;
  padding: 1vh 1.2vw;
}

/* ---------- 承诺框 ---------- */
.promise-box {
  margin-top: 3vh;
  border: 1px solid var(--accent-2);
  background: rgba(45,212,191,.08);
  border-radius: var(--radius);
  padding: 2vh 2vw;
  font-size: clamp(17px, 1.6vw, 23px);
}
.promise-box strong { color: var(--accent-2); }

/* ---------- 对表模式 ---------- */
.form-wrap { max-width: 1180px; margin: 0 auto; padding: 24px 22px 60px; }
.sub-tabs { display: flex; gap: 8px; margin-bottom: 20px; }
.sub-tab {
  background: var(--panel);
  border: 1px solid var(--line);
  color: var(--muted);
  border-radius: 8px;
  padding: 8px 18px;
  font-size: 15px;
}
.sub-tab.active { color: var(--accent); border-color: var(--accent); font-weight: 700; }
.sub-pane { display: none; }
.sub-pane.active { display: block; }

.form-head {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr auto;
  gap: 14px;
  align-items: end;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 18px;
  margin-bottom: 18px;
}
.form-head label { display: block; color: var(--muted); font-size: 13px; margin-bottom: 5px; }
.form-head input, .form-head select {
  width: 100%;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  padding: 9px 12px;
  font-size: 15px;
  font-family: var(--font);
}
.form-head input:focus, .form-head select:focus { outline: none; border-color: var(--accent); }
.company-meta { grid-column: 1 / -1; color: var(--muted); font-size: 14px; min-height: 1.4em; }
.company-meta b { color: var(--accent-2); }
.save-state { color: var(--muted); font-size: 13px; text-align: right; white-space: nowrap; }
.form-actions { display: flex; gap: 10px; margin: 0 0 18px; }
.action-btn {
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  color: #04121f;
  border: none;
  border-radius: 8px;
  padding: 10px 22px;
  font-size: 15px;
  font-weight: 700;
}
.action-btn.secondary { background: var(--panel-2); color: var(--text); border: 1px solid var(--line); }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-section {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 20px;
}
.form-section.wide { grid-column: 1 / -1; }
.form-section h3 {
  color: var(--accent);
  font-size: 17px;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}
.opt-row { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 8px 0; align-items: center; }
.opt-row .row-label { color: var(--muted); font-size: 14px; margin-right: 4px; }
.chk { display: inline-flex; align-items: center; gap: 7px; font-size: 15px; cursor: pointer; }
.chk input { accent-color: var(--accent); width: 16px; height: 16px; cursor: pointer; }
.txt {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  padding: 7px 10px;
  font-size: 14.5px;
  font-family: var(--font);
  min-width: 180px;
}
.txt:focus { outline: none; border-color: var(--accent); }
.txt.grow { flex: 1; min-width: 120px; }
.txt.small { min-width: 90px; width: 110px; }

.res-table, .todo-table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.res-table th, .res-table td, .todo-table th, .todo-table td {
  border: 1px solid var(--line);
  padding: 8px 10px;
  text-align: center;
}
.res-table th { background: var(--panel-2); color: var(--muted); font-weight: 400; }
.res-table td:first-child, .todo-table th { text-align: left; }
.res-table input[type="radio"] { accent-color: var(--accent-2); width: 16px; height: 16px; }
.todo-table .txt { width: 100%; min-width: 0; border: none; background: transparent; }
.form-note { margin-top: 16px; color: var(--muted); font-size: 13.5px; }

/* 一页看懂（正面概念页） */
.concept { max-width: 1080px; margin: 0 auto; }
.concept h2 { color: var(--accent); margin: 26px 0 12px; font-size: 21px; }
.concept .one-liner { font-size: 18.5px; line-height: 1.9; }
.concept .one-liner strong { color: var(--accent-2); }
.concept-diagram {
  display: flex; align-items: center; justify-content: center;
  gap: 14px; margin: 22px 0; flex-wrap: wrap;
}
.concept-box {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 20px;
  text-align: center;
  font-size: 15.5px;
  line-height: 1.9;
}
.concept-box.dev { border-color: #3a4a75; }
.concept-box.mid { border-color: var(--accent-2); color: var(--accent-2); font-weight: 700; }
.concept-box.plat { border-color: var(--ok); text-align: left; }
.concept-box .box-title { font-weight: 700; color: var(--text); display: block; margin-bottom: 4px; }
.concept-box small { color: var(--muted); display: block; margin-top: 6px; }
.fact-table { width: 100%; border-collapse: collapse; font-size: 15.5px; }
.fact-table td { border: 1px solid var(--line); padding: 12px 16px; vertical-align: top; }
.fact-table td:first-child { white-space: nowrap; color: var(--accent); font-weight: 700; width: 120px; }
.concept .four-designs {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 20px;
  font-size: 15.5px;
  line-height: 2;
}
.concept .std-foot { color: var(--muted); font-size: 13.5px; margin-top: 18px; font-style: italic; }

/* ---------- 名册模式 ---------- */
.roster-wrap { max-width: 1240px; margin: 0 auto; padding: 24px 22px 60px; }
.roster-views { display: flex; gap: 8px; margin-bottom: 20px; flex-wrap: wrap; }
.roster-tab {
  background: var(--panel);
  border: 1px solid var(--line);
  color: var(--muted);
  border-radius: 999px;
  padding: 8px 18px;
  font-size: 14.5px;
}
.roster-tab.active { color: #04121f; background: var(--accent); border-color: transparent; font-weight: 700; }
.batch-block { margin-bottom: 30px; }
.batch-head {
  display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap;
  border-left: 5px solid var(--accent);
  padding-left: 14px;
  margin-bottom: 14px;
}
.batch-head h3 { font-size: 19px; }
.batch-head .batch-date { color: var(--accent); font-weight: 700; }
.batch-head .batch-cities { color: var(--muted); font-size: 14px; }
.batch-head .batch-note { color: var(--muted); font-size: 13px; }
.company-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; align-items: start; }
.company-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: 10px;
  padding: 13px 15px;
  cursor: pointer;
  transition: border-color .3s, transform .3s;
}
.company-card:hover { transform: translateY(-2px); border-color: var(--accent); }
.company-card .c-name { font-weight: 700; font-size: 16px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.company-card .c-prod { color: var(--muted); font-size: 13.5px; margin-top: 4px; }
.company-card .c-meta { color: var(--muted); font-size: 13px; margin-top: 6px; display: flex; gap: 12px; flex-wrap: wrap; }
.visited-pill {
  background: var(--ok); color: #06281c;
  font-size: 11px; font-weight: 700;
  border-radius: 999px; padding: 2px 8px;
}
.domain-pill { font-size: 11px; font-weight: 700; border-radius: 999px; padding: 2px 8px; color: #06121f; }
.company-detail {
  display: none;
  margin-top: 10px;
  border-top: 1px dashed var(--line);
  padding-top: 10px;
  font-size: 13.5px;
  color: var(--text);
  line-height: 1.8;
}
.company-card.expanded .company-detail { display: block; }
.company-detail h4 { color: var(--accent-2); font-size: 13.5px; margin: 8px 0 4px; }
.company-detail ul { padding-left: 18px; color: var(--muted); }
.domain-section { margin-bottom: 34px; }
.domain-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 14px; border-left: 5px solid; padding-left: 14px; }
.domain-head h3 { font-size: 19px; }
.domain-head .d-count { color: var(--muted); font-size: 13.5px; }
.feedback-block { margin-top: 40px; }
.feedback-block h3 { color: var(--accent-2); margin-bottom: 12px; font-size: 19px; }
.feedback-table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.feedback-table th, .feedback-table td { border: 1px solid var(--line); padding: 12px 14px; text-align: left; vertical-align: top; }
.feedback-table th { background: var(--panel-2); color: var(--muted); font-weight: 400; white-space: nowrap; }

/* ---------- 响应式 ---------- */
@media (max-width: 1400px) {
  .mxn-layout, .journey-layout { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 900px) {
  .mxn-layout, .journey-layout, .form-grid, .card-grid { grid-template-columns: 1fr; }
  .form-head { grid-template-columns: 1fr 1fr; }
  .flow-diagram { flex-wrap: wrap; }
  .topbar { flex-wrap: wrap; gap: 10px; }
  .mode-tabs { margin-left: 0; }
}

/* ---------- 打印：对表 A4 一页 ---------- */
@media print {
  @page { size: A4 portrait; margin: 7mm; }
  body { background: #fff; color: #000; font-size: 8.5pt; line-height: 1.4; }
  .topbar, .sub-tabs, .form-actions, .save-state, .speaker-drawer, .help-overlay,
  #mode-slides, #mode-roster, #pane-concept, .mxn-stage .ghost-btn { display: none !important; }
  .mode-pane { display: none; }
  #mode-form { display: block !important; min-height: 0; }
  #pane-checklist { display: block !important; }
  .form-wrap { max-width: none; padding: 0; }
  .form-head { grid-template-columns: 2fr 1fr 1fr; gap: 4px 8px; border: 1px solid #999; background: #fff; padding: 5px 8px; margin-bottom: 5px; }
  .form-head label { color: #333; font-size: 7pt; margin-bottom: 2px; }
  .form-head input, .form-head select { border: none; border-bottom: 1px solid #666; background: #fff; color: #000; border-radius: 0; padding: 1px 3px; font-size: 8.5pt; }
  .company-meta { color: #333; font-size: 7.5pt; }
  .form-grid { gap: 4px; }
  .form-section { border: 1px solid #999; background: #fff; border-radius: 3px; padding: 5px 8px; break-inside: avoid; }
  .form-section h3 { color: #000; font-size: 9pt; border-bottom: 1px solid #999; margin-bottom: 3px; padding-bottom: 2px; }
  .opt-row { gap: 2px 8px; margin: 2px 0; }
  .chk { font-size: 8pt; gap: 4px; }
  .chk input { width: 10px; height: 10px; }
  .txt { border: none; border-bottom: 1px solid #666; background: #fff; color: #000; border-radius: 0; font-size: 8pt; padding: 1px 2px; min-width: 70px; }
  .res-table th, .res-table td, .todo-table th, .todo-table td { border: 1px solid #999; padding: 2px 4px; font-size: 7.5pt; color: #000; }
  .res-table th, .todo-table th { background: #eee; }
  .form-note { color: #333; font-size: 7pt; margin-top: 3px; }
}

/* =========================================================
 * 领导谈判版新增组件（15 页版）
 * ========================================================= */

/* 底部进度条 */
.slide-progress {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 3px;
  background: rgba(34,53,92,.55);
  z-index: 30;
}
.slide-progress i {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  transition: width .45s ease-out;
}

/* 〔规划〕灰徽标 / 〔国标〕蓝徽标 */
.tag-plan { color: #d7e0f2; background: #44547a; }
.tag-gb { color: #06182e; background: #60a5fa; }

/* ---------- 封面（大气版） ---------- */
.slide[data-type="cover"] { text-align: center; }
.slide[data-type="cover"] h1 {
  border-left: none;
  padding-left: 0;
  text-align: center;
  font-size: clamp(38px, 4.8vw, 72px);
  font-weight: 800;
  letter-spacing: 1px;
  margin-bottom: 1.6vh;
  background: linear-gradient(100deg, #eaf3ff 20%, var(--accent) 55%, var(--accent-2) 85%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.cover-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(900px 420px at 50% -8%, rgba(53,196,255,.16), transparent 62%),
    radial-gradient(760px 420px at 50% 112%, rgba(45,212,191,.12), transparent 62%);
}
.cover-bg::before {
  content: "";
  position: absolute;
  inset: -60px;
  background:
    repeating-linear-gradient(0deg, rgba(96,165,250,.055) 0 1px, transparent 1px 56px),
    repeating-linear-gradient(90deg, rgba(96,165,250,.055) 0 1px, transparent 1px 56px);
  animation: gridDrift 26s linear infinite;
}
@keyframes gridDrift {
  from { transform: translate(0, 0); }
  to { transform: translate(56px, 56px); }
}
.cover-box { position: relative; z-index: 1; }
.cover-orgs { color: var(--muted); font-size: clamp(14px, 1.25vw, 18px); letter-spacing: 2px; }
.cover-orgs.dim { margin-top: 3.4vh; letter-spacing: 1px; }
.cover-line { font-size: clamp(17px, 1.6vw, 24px); color: var(--text); margin-top: 1.2vh; }
.cover-line strong { color: var(--accent-2); }
.cover-policy {
  color: var(--muted);
  font-size: clamp(12.5px, 1.12vw, 16px);
  margin-top: 1.6vh;
  letter-spacing: 0.3px;
}
.cover-policy strong { color: var(--accent); font-weight: 700; }
.cover-agenda-mini {
  margin-top: 2vh;
  color: var(--muted);
  font-size: clamp(13px, 1.15vw, 16.5px);
  letter-spacing: 1.5px;
}
.cover-badges { display: flex; justify-content: center; gap: 12px; margin: 2.6vh 0 0; flex-wrap: wrap; }
.cb-item {
  border: 1px solid var(--line);
  background: rgba(19,31,56,.72);
  color: var(--text);
  border-radius: 999px;
  padding: 7px 20px;
  font-size: clamp(13px, 1.15vw, 16px);
}
.slide[data-type="cover"] .cover-sub { margin: 1vh 0 1.6vh; }
.slide[data-type="cover"] .cover-tag { margin-bottom: 3vh; }
.closing-list { text-align: left; display: inline-block; margin-bottom: 4.5vh; }

/* 大数字带（封面 / 数据页共用） */
.stat-band {
  display: flex;
  justify-content: center;
  gap: clamp(20px, 3.6vw, 64px);
  margin-top: 4vh;
  flex-wrap: wrap;
}
.stat { display: block; text-align: center; min-width: 150px; max-width: 260px; }
.stat .num {
  display: inline-block;
  font-size: clamp(34px, 3.6vw, 58px);
  font-weight: 800;
  line-height: 1.1;
  color: #fff;
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 26px rgba(53,196,255,.35);
}
.stat .unit { color: var(--accent); font-weight: 700; font-size: clamp(15px, 1.4vw, 21px); margin-left: 4px; }
.stat .lbl { display: block; color: var(--muted); font-size: clamp(12px, 1.05vw, 15px); margin-top: 6px; line-height: 1.5; }
.stat-col { display: flex; flex-direction: column; gap: 2.4vh; }
.stat-col .stat { text-align: left; min-width: 0; max-width: none; }
.stat-col .stat .num { font-size: clamp(30px, 3vw, 48px); }
.stat-col .stat .lbl { max-width: 34em; }

/* ---------- 第 3 页：SDK 实证 ---------- */
.evidence-layout { display: grid; grid-template-columns: 32fr 68fr; gap: 2.6vw; align-items: start; }
.sdk-table { width: 100%; border-collapse: collapse; font-size: clamp(13px, 1.18vw, 17px); }
.sdk-table th, .sdk-table td { border: 1px solid var(--line); padding: 1.1vh 0.9vw; text-align: left; vertical-align: top; }
.sdk-table thead th { background: var(--panel-2); color: var(--accent); white-space: nowrap; }
.sdk-table tbody td:first-child { color: var(--text); font-weight: 700; white-space: nowrap; }
.big-list.tight { font-size: clamp(16px, 1.45vw, 21px); margin-top: 1.8vh; }
.big-list.tight li { margin: 1vh 0; }

/* ---------- 第 5 页：生态全景 ---------- */
.eco-layout { display: grid; grid-template-columns: 46fr 54fr; gap: 2.6vw; align-items: start; }
.eco-chips { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 2.2vh; }
.eco-chip {
  background: rgba(53,196,255,.1);
  border: 1px solid var(--accent);
  color: var(--accent);
  border-radius: 999px;
  padding: 6px 22px;
  font-size: clamp(15px, 1.4vw, 20px);
  font-weight: 700;
}
.eco-chip-note { color: var(--muted); font-size: clamp(12px, 1.05vw, 15px); width: 100%; }
.eco-left blockquote { margin-top: 2.2vh; font-size: clamp(16px, 1.5vw, 21px); }
.wall-title { color: var(--muted); font-size: clamp(13px, 1.15vw, 16px); margin-bottom: 1.2vh; }
.wall { display: flex; flex-wrap: wrap; gap: 7px; align-content: flex-start; }
.wall-item {
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 3px solid var(--line);
  border-radius: 7px;
  padding: 4px 10px;
  font-size: clamp(12px, 1.02vw, 14.5px);
  color: var(--text);
  white-space: nowrap;
  opacity: 0;
  animation: wallIn .45s ease-out forwards;
}
@keyframes wallIn {
  from { opacity: 0; transform: translateY(10px) scale(.94); }
  to { opacity: 1; transform: none; }
}

/* ---------- 第 6 页：KPI 指标带 ---------- */
.kpi-strip {
  display: flex;
  justify-content: center;
  gap: clamp(14px, 2.4vw, 44px);
  margin-top: 3vh;
  flex-wrap: wrap;
}
.kpi { text-align: center; min-width: 110px; }
.kpi b {
  display: block;
  font-size: clamp(19px, 1.9vw, 29px);
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}
.kpi span { color: var(--muted); font-size: clamp(11.5px, 1vw, 14.5px); }

/* ---------- 第 10 页：标准底座表 ---------- */
.std-table { width: 100%; border-collapse: collapse; font-size: clamp(14px, 1.3vw, 18.5px); }
.std-table th, .std-table td { border: 1px solid var(--line); padding: 1.3vh 1vw; text-align: left; vertical-align: top; }
.std-table thead th { background: var(--panel-2); color: var(--accent); }
.std-table td small { color: var(--muted); }
.std-table .tag { font-size: 12.5px; }

/* ---------- 第 11 页：合规牵引 ---------- */
.law-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 2vw; }
.law-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2vh 1.6vw;
}
.law-card h3 { color: var(--accent); font-size: clamp(18px, 1.7vw, 25px); margin-bottom: 1.2vh; }
.law-card ul { list-style: none; }
.law-card li {
  position: relative;
  padding-left: 1.1em;
  margin: 1vh 0;
  font-size: clamp(14.5px, 1.35vw, 19.5px);
  line-height: 1.75;
}
.law-card li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.68em;
  width: 0.42em; height: 0.42em;
  border-radius: 2px;
  background: var(--accent-2);
}
.law-card li.law-hard { color: var(--warn); }
.law-card li.law-hard::before { background: var(--warn); }

/* ---------- 第 12 页：路线图时间线 ---------- */
.done-strip { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 3.2vh; }
.done-label { color: var(--ok); font-weight: 700; font-size: clamp(13px, 1.15vw, 16px); margin-right: 6px; }
.done-chip {
  border: 1px solid rgba(52,211,153,.55);
  background: rgba(52,211,153,.08);
  color: var(--text);
  border-radius: 999px;
  padding: 5px 14px;
  font-size: clamp(12.5px, 1.1vw, 15.5px);
}
.tl { display: flex; gap: 1.6vw; }
.tl-item {
  flex: 1;
  position: relative;
  border-top: 2px solid var(--line);
  padding-top: 1.8vh;
}
.tl-item::before {
  content: "";
  position: absolute;
  top: -7px; left: 0;
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 12px rgba(53,196,255,.6);
}
.tl-item.hot { border-top-color: var(--accent-2); }
.tl-item.hot::before { background: var(--accent-2); box-shadow: 0 0 14px rgba(45,212,191,.75); }
.tl-item.future { border-top-style: dashed; }
.tl-item.future::before { background: var(--warn); box-shadow: 0 0 12px rgba(255,180,84,.55); }
.tl-date { color: var(--accent); font-weight: 800; font-size: clamp(16px, 1.5vw, 22px); font-variant-numeric: tabular-nums; }
.tl-item.hot .tl-date { color: var(--accent-2); }
.tl-item.future .tl-date { color: var(--warn); }
.tl-t { font-weight: 700; font-size: clamp(15px, 1.4vw, 20px); margin: 4px 0; }
.tl-d { color: var(--muted); font-size: clamp(12.5px, 1.12vw, 15.5px); line-height: 1.65; }

/* ---------- 第 13 页：投入与回报 ---------- */
.io-split { display: grid; grid-template-columns: 1fr 1fr; gap: 2vw; }
.io-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2.2vh 1.8vw;
}
.io-card h3 { font-size: clamp(18px, 1.7vw, 25px); margin-bottom: 1.4vh; }
.io-card.give { border-top: 3px solid var(--warn); }
.io-card.give h3 { color: var(--warn); }
.io-card.get { border-top: 3px solid var(--ok); }
.io-card.get h3 { color: var(--ok); }
.io-card ol, .io-card ul { list-style: none; }
.io-card li {
  position: relative;
  padding-left: 1.15em;
  margin: 1.2vh 0;
  font-size: clamp(14.5px, 1.35vw, 19.5px);
  line-height: 1.7;
}
.io-card li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.66em;
  width: 0.44em; height: 0.44em;
  border-radius: 2px;
  background: var(--accent);
}
.io-card.give li::before { background: var(--warn); }
.io-card.get li::before { background: var(--ok); }

/* ---------- 新组件响应式 ---------- */
@media (max-width: 1100px) {
  .evidence-layout, .eco-layout, .law-layout, .io-split { grid-template-columns: 1fr; }
  .tl { flex-direction: column; gap: 2vh; }
  .tl-item { border-top: none; border-left: 2px solid var(--line); padding: 0 0 0 18px; }
  .tl-item::before { top: 4px; left: -7px; }
  .tl-item.hot { border-left-color: var(--accent-2); }
  .tl-item.future { border-left-style: dashed; }
}

/* =========================================================
 * 问卷 / 管理员看板 / 登录门禁（2026-08 新增）
 * ========================================================= */

/* hidden 属性兜底（作者样式 display 会盖掉 UA 的 [hidden] 规则） */
[hidden] { display: none !important; }

/* ---------- 登录门禁：未登录隐藏 .gate-admin ---------- */
body:not(.authed) .gate-admin { display: none !important; }

.auth-btn { white-space: nowrap; }
.auth-btn.authed { color: var(--ok); border-color: var(--ok); }

/* 问卷路由：全屏接管，只留品牌栏 */
body.route-survey .mode-tabs,
body.route-survey .auth-btn { display: none; }

/* ---------- 问卷填写页 ---------- */
.survey-wrap { max-width: 1080px; margin: 0 auto; padding: 28px 22px 70px; }
.survey-intro { margin-bottom: 18px; }
.survey-intro h1 { font-size: 26px; margin-bottom: 10px; }
.survey-intro h1::before { content: ''; display: inline-block; width: 10px; height: 22px; margin-right: 10px; border-radius: 3px; background: linear-gradient(180deg, var(--accent), var(--accent-2)); vertical-align: -2px; }
.survey-intro p { color: var(--muted); font-size: 14px; margin-bottom: 6px; }
.survey-meta { font-size: 13px; }
.req { color: #ff7a7a; font-weight: 700; }

.reg-section { margin-bottom: 16px; }
.reg-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 20px; }
.reg-field label { display: block; font-size: 13.5px; color: var(--muted); margin-bottom: 5px; }
.reg-field input {
  width: 100%;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  padding: 9px 12px;
  font-size: 14.5px;
  font-family: var(--font);
}
.reg-field input:focus { outline: none; border-color: var(--accent); }
.reg-field input.field-error { border-color: #ff7a7a; box-shadow: 0 0 0 2px rgba(255,122,122,.18); }

.sv-submitted {
  border: 1px solid var(--ok);
  background: rgba(52,211,153,.08);
  color: var(--ok);
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 13.5px;
  margin-bottom: 14px;
}

.survey-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 18px;
  flex-wrap: wrap;
}
.action-btn.big { font-size: 16px; padding: 12px 30px; }

.survey-done, .survey-error {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: var(--radius);
  padding: 34px 30px;
  text-align: center;
  margin-top: 30px;
}
.survey-done h2, .survey-error h2 { color: var(--accent-2); margin-bottom: 12px; }
.survey-error h2 { color: var(--warn); }
.survey-done p, .survey-error p { color: var(--muted); font-size: 14.5px; margin-bottom: 10px; }
.survey-done .modal-btns, .survey-error .action-btn { margin-top: 14px; }

/* 小号按钮（表格行内/填表人复制） */
.mini-btn {
  background: var(--panel-2);
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: 6px;
  padding: 3px 10px;
  font-size: 12.5px;
  margin: 1px 2px;
  transition: border-color .2s ease, color .2s ease;
}
.mini-btn:hover { border-color: var(--accent); color: var(--accent); }
.mini-btn.danger:hover { border-color: #ff7a7a; color: #ff7a7a; }

/* ---------- 弹窗 ---------- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(4,10,22,.72);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 20px;
}
.modal-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 28px;
  width: 380px;
  max-width: 100%;
  box-shadow: 0 18px 60px rgba(0,0,0,.55);
}
.modal-card.wide { width: 860px; max-height: 86vh; display: flex; flex-direction: column; }
.modal-card h3 { margin-bottom: 16px; font-size: 18px; }
.modal-field { display: block; font-size: 13.5px; color: var(--muted); margin-bottom: 12px; }
.modal-field input {
  display: block;
  width: 100%;
  margin-top: 5px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  padding: 9px 12px;
  font-size: 14.5px;
  font-family: var(--font);
}
.modal-field input:focus { outline: none; border-color: var(--accent); }
.login-err { color: #ff7a7a; font-size: 13px; min-height: 20px; }
.modal-btns { display: flex; gap: 10px; justify-content: center; margin-top: 8px; }
.modal-note { color: var(--muted); font-size: 12.5px; margin-top: 14px; }

.resp-body { overflow: auto; font-size: 13.5px; }
.resp-reg, .resp-ans { width: 100%; border-collapse: collapse; margin-bottom: 14px; }
.resp-reg th, .resp-reg td, .resp-ans th, .resp-ans td {
  border: 1px solid var(--line);
  padding: 6px 10px;
  text-align: left;
  vertical-align: top;
}
.resp-reg th, .resp-ans th { background: var(--panel-2); color: var(--muted); font-weight: 400; width: 180px; white-space: nowrap; }
.resp-raw summary { color: var(--muted); cursor: pointer; font-size: 12.5px; }
.resp-raw pre {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  font-size: 12px;
  overflow: auto;
  max-height: 300px;
  margin-top: 8px;
}

/* ---------- Toast ---------- */
.toast-wrap { position: fixed; right: 18px; bottom: 18px; z-index: 300; display: flex; flex-direction: column; gap: 8px; }
.toast {
  background: var(--panel-2);
  border: 1px solid var(--accent);
  color: var(--text);
  border-radius: 10px;
  padding: 10px 16px;
  font-size: 13.5px;
  box-shadow: 0 10px 30px rgba(0,0,0,.5);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .3s ease, transform .3s ease;
}
.toast.show { opacity: 1; transform: none; }

/* ---------- 管理员看板 ---------- */
.admin-wrap { max-width: 1180px; margin: 0 auto; padding: 24px 22px 60px; }
.admin-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 8px; }
.admin-head h2 { font-size: 22px; }
.admin-toolbar { display: flex; gap: 8px; flex-wrap: wrap; }
.admin-toolbar .action-btn { font-size: 13.5px; padding: 8px 16px; }
.action-btn.danger { border-color: #ff7a7a; color: #ff7a7a; }
.action-btn.danger:hover { background: rgba(255,122,122,.12); }
.admin-hint { color: var(--muted); font-size: 12.5px; margin-bottom: 14px; }
.admin-hint b { color: var(--warn); }

.dropzone {
  border: 1.5px dashed var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  text-align: center;
  padding: 18px;
  font-size: 13.5px;
  cursor: pointer;
  margin-bottom: 18px;
  transition: border-color .2s ease, background .2s ease;
}
.dropzone:hover, .dropzone.over { border-color: var(--accent); background: rgba(53,196,255,.06); color: var(--accent); }

.kpi-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 16px; }
.kpi-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 18px;
  text-align: center;
}
.kpi-num { font-size: 26px; font-weight: 700; color: var(--accent); }
.kpi-card:nth-child(2) .kpi-num { color: var(--accent-2); }
.kpi-card:nth-child(3) .kpi-num { color: var(--warn); }
.kpi-card:nth-child(4) .kpi-num { font-size: 18px; padding-top: 6px; color: var(--text); }
.kpi-label { color: var(--muted); font-size: 13px; margin-top: 4px; }

.admin-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.admin-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 18px;
  margin-bottom: 14px;
}
.admin-card h3 { font-size: 15.5px; margin-bottom: 12px; color: var(--text); }

.bar-row { display: flex; align-items: center; gap: 10px; margin: 7px 0; font-size: 13px; }
.bar-label { width: 190px; flex: none; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar-track { flex: 1; height: 10px; background: var(--bg-2); border-radius: 999px; overflow: hidden; }
.bar-track i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--accent), var(--accent-2)); border-radius: 999px; transition: width .5s ease; }
.bar-num { width: 48px; flex: none; text-align: right; color: var(--muted); font-variant-numeric: tabular-nums; }

.agg-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 26px; }
.agg-block h4 { font-size: 13.5px; color: var(--muted); margin-bottom: 8px; font-weight: 700; }
.agg-row { display: flex; align-items: center; gap: 10px; margin: 5px 0; font-size: 12.5px; }
.agg-label { width: 200px; flex: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.agg-empty { color: var(--muted); font-size: 12.5px; }

.custom-add { display: flex; gap: 8px; margin-bottom: 12px; }
.custom-add input {
  flex: 1;
  max-width: 360px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  padding: 8px 12px;
  font-size: 13.5px;
  font-family: var(--font);
}
.custom-add input:focus { outline: none; border-color: var(--accent); }

.admin-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.admin-table th, .admin-table td {
  border-bottom: 1px solid var(--line);
  padding: 8px 10px;
  text-align: left;
  vertical-align: middle;
}
.admin-table th { color: var(--muted); font-weight: 400; white-space: nowrap; }
.admin-table td.ops { white-space: nowrap; }
.admin-table .domain-pill { margin-left: 0; }

.pill { display: inline-block; font-size: 11.5px; font-weight: 700; border-radius: 999px; padding: 2px 9px; margin-left: 6px; }
.pill-ok { background: rgba(52,211,153,.15); color: var(--ok); border: 1px solid var(--ok); margin-left: 0; }
.pill-wait { background: rgba(147,166,201,.12); color: var(--muted); border: 1px solid var(--line); margin-left: 0; }
.pill-custom { background: rgba(251,191,36,.14); color: var(--draft); border: 1px solid var(--draft); }

/* ---------- 响应式 ---------- */
@media (max-width: 900px) {
  .reg-grid, .admin-cols, .agg-grid { grid-template-columns: 1fr; }
  .kpi-row { grid-template-columns: repeat(2, 1fr); }
  .bar-label, .agg-label { width: 130px; }
}

/* ---------- 打印隔离 ---------- */
@media print {
  #mode-survey, #mode-admin, .modal-overlay, .toast-wrap { display: none !important; }
}

/* =========================================================
 * 回执 PDF 导出（打印视图，2026-08 新增）
 * 屏幕上看不到 #printZone；点「导出 PDF」后 body 加 .print-receipt，
 * 打印时只输出回执内容，在打印对话框选「另存为 PDF」即得文件。
 * ========================================================= */
#printZone { display: none; }

.rcpt { color: #000; }
.rcpt + .rcpt { break-before: page; }
.rcpt-head { border-bottom: 2.5px solid #0b1220; padding-bottom: 6px; margin-bottom: 10px; }
.rcpt-head h1 { font-size: 15pt; color: #000; }
.rcpt-head .rcpt-sub { color: #333; font-size: 8.5pt; margin-top: 2px; }
.rcpt h2 { font-size: 10.5pt; color: #000; margin: 10px 0 4px; border-left: 4px solid #0b1220; padding-left: 6px; }
.rcpt table { width: 100%; border-collapse: collapse; }
.rcpt th, .rcpt td { border: 1px solid #999; padding: 3px 6px; font-size: 8.5pt; text-align: left; vertical-align: top; }
.rcpt th { background: #eee; width: 170px; font-weight: 700; }
.rcpt-foot { margin-top: 12px; color: #555; font-size: 7.5pt; border-top: 1px solid #999; padding-top: 4px; }

@media print {
  /* 回执打印模式：压掉既有「对表打印」规则，只输出回执 */
  body.print-receipt #mode-form,
  body.print-receipt .mode-pane,
  body.print-receipt .topbar,
  body.print-receipt .modal-overlay,
  body.print-receipt .speaker-drawer,
  body.print-receipt .toast-wrap { display: none !important; }
  body.print-receipt #printZone { display: block !important; }
}

/* =========================================================
 * 2026-08 新增：PHP API 版配套样式
 * 管理内部 Tab / 名录编辑行 / 名册搜索框 / 页码跳转菜单
 * ========================================================= */

/* ---------- 名册搜索框 ---------- */
.roster-search {
  margin-left: auto;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--text);
  padding: 7px 16px;
  font-size: 14px;
  font-family: var(--font);
  min-width: 220px;
}
.roster-search:focus { outline: none; border-color: var(--accent); }
.roster-search::placeholder { color: var(--muted); }
.roster-empty { color: var(--muted); font-size: 14px; padding: 12px 4px; }

/* ---------- 管理内部 Tab ---------- */
.admin-tabs { display: flex; gap: 8px; margin-bottom: 18px; flex-wrap: wrap; }
.admin-pane { display: none; }
.admin-pane.active { display: block; }

/* 离线提示：隐藏管理操作区，只留说明 */
.admin-offline-note {
  color: var(--warn);
  background: rgba(255, 180, 84, .08);
  border: 1px dashed var(--warn);
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 14px;
  margin-bottom: 14px;
}
.admin-wrap.is-offline .admin-tabs,
.admin-wrap.is-offline .admin-pane { display: none; }

/* ---------- 名录/批次编辑行 ---------- */
.admin-table .cell-in {
  width: 100%;
  min-width: 72px;
  background: var(--bg-2);
  border: 1px solid var(--accent);
  border-radius: 6px;
  color: var(--text);
  padding: 4px 8px;
  font-size: 12.5px;
  font-family: var(--font);
}
.admin-table select.cell-in { padding: 4px 4px; }
.admin-table tr.edit-row td { background: rgba(53, 196, 255, .05); }
.co-add { flex-wrap: wrap; }
.co-add input { flex: 1 1 140px; }
.co-add select {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  padding: 9px 10px;
  font-size: 14px;
  font-family: var(--font);
}

/* ---------- 域编辑表单（批次与域 Tab） ---------- */
.meta-edit {
  margin-top: 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 14px 16px;
  background: var(--bg-2);
}
.meta-edit h4 { font-size: 14.5px; margin-bottom: 10px; color: var(--accent-2); }
.meta-edit-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px 14px;
  margin-bottom: 10px;
}
.meta-edit-grid label, .meta-edit-field {
  display: block;
  font-size: 12.5px;
  color: var(--muted);
}
.meta-edit-grid input, .meta-edit-field textarea {
  display: block;
  width: 100%;
  margin-top: 4px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  padding: 8px 10px;
  font-size: 13.5px;
  font-family: var(--font);
}
.meta-edit-grid input[type="color"] { padding: 2px; height: 36px; }
.meta-edit-field { margin-bottom: 10px; }
.meta-edit-field textarea { resize: vertical; line-height: 1.5; }
.meta-edit-grid input:focus, .meta-edit-field textarea:focus { outline: none; border-color: var(--accent); }

/* ---------- 问卷题目 Tab ---------- */
.qdef-text {
  width: 100%;
  min-height: 340px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--text);
  padding: 12px 14px;
  font-family: Consolas, "Courier New", monospace;
  font-size: 13px;
  line-height: 1.55;
  resize: vertical;
  white-space: pre;
}
.qdef-text:focus { outline: none; border-color: var(--accent); }
.qdef-toolbar { margin: 12px 0; }

/* 问卷题目可视化编辑器 */
.qdef-tip { color: var(--muted); font-size: 12.5px; margin: 4px 0 12px; line-height: 1.6; }
.qdef-editor { display: flex; flex-direction: column; gap: 14px; }
.qd-sec { border: 1px solid var(--line); border-radius: 12px; background: var(--bg-2); padding: 12px 14px; }
.qd-sec-bar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.qd-sec-no { font-weight: 700; color: var(--accent); font-size: 13px; white-space: nowrap; }
.qd-f { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 12.5px; }
.qd-f.grow, .qd-f .grow { flex: 1; min-width: 120px; }
.qd-f-t { color: var(--muted); font-size: 12.5px; margin-right: 6px; }
.qd-note { display: flex; margin-top: 8px; }
.qd-note input { flex: 1; }
.qd-f.chk input { width: auto; }
.qd-sec input[type="text"], .qd-sec input[type="number"], .qd-sec select {
  background: var(--bg); border: 1px solid var(--line); border-radius: 8px;
  color: var(--text); padding: 6px 9px; font-size: 13px; font-family: var(--font); min-width: 0;
}
.qd-sec input:focus, .qd-sec select:focus { outline: none; border-color: var(--accent); }
.qd-id { width: 110px; }
.qd-ops { display: inline-flex; gap: 4px; margin-left: auto; }
.qd-ops button, .qd-mini, .qd-x {
  background: var(--bg); border: 1px solid var(--line); border-radius: 7px; color: var(--muted);
  cursor: pointer; font-size: 12.5px; padding: 3px 8px; line-height: 1.4;
}
.qd-ops button:hover, .qd-mini:hover { border-color: var(--accent); color: var(--accent); }
.qd-x { color: var(--muted); padding: 3px 7px; }
.qd-x:hover { border-color: #e05d5d; color: #e05d5d; }
.qd-row { border: 1px dashed var(--line); border-radius: 10px; margin-top: 10px; padding: 10px 12px; }
.qd-row-bar { display: flex; align-items: center; }
.qd-tag {
  display: inline-block; font-size: 11.5px; color: var(--accent-2);
  border: 1px solid var(--accent-2); border-radius: 999px; padding: 1px 9px; white-space: nowrap;
}
.qd-tag.alt { color: var(--accent); border-color: var(--accent); }
.qd-parts { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.qd-part { border: 1px solid var(--line); border-radius: 9px; padding: 8px 10px; background: rgba(255,255,255,.02); }
.qd-part-bar { display: flex; align-items: center; }
.qd-part-body { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; align-items: center; }
.qd-part-body > input[type="text"] { flex: 1; }
.qd-opts { display: flex; flex-direction: column; gap: 6px; flex-basis: 100%; margin-top: 2px; }
.qd-opt { display: flex; gap: 6px; align-items: center; }
.qd-opt input { flex: 1; }
.qd-addpart { display: flex; gap: 8px; margin-top: 8px; align-items: center; }
.qd-matrix { display: flex; flex-wrap: wrap; gap: 8px 12px; margin-top: 8px; align-items: center; }
.qd-cols, .qd-items { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; flex-basis: 100%; }
.qd-col { display: inline-flex; gap: 4px; align-items: center; }
.qd-col input { width: 96px; }
.qd-item { display: flex; gap: 6px; align-items: center; flex-basis: 100%; }
.qd-item input:first-child { width: 150px; }
.qd-item .grow { flex: 1; }
.qd-addrow { margin-top: 10px; display: flex; gap: 8px; align-items: center; color: var(--muted); font-size: 12.5px; }
.qd-addsec { text-align: center; }
.qdef-adv { margin-top: 10px; border-top: 1px solid var(--line); padding-top: 10px; }
.qdef-adv summary { cursor: pointer; color: var(--muted); font-size: 13px; }
.qdef-adv summary:hover { color: var(--accent); }
.qdef-adv-tip { color: var(--muted); font-size: 12px; margin: 8px 0; }
.qdef-adv .qdef-text { min-height: 220px; margin-bottom: 8px; }

/* 名录批量新增 */
.bulk-add { margin: 10px 0 4px; }
.bulk-add summary { cursor: pointer; color: var(--muted); font-size: 13px; }
.bulk-add summary:hover { color: var(--accent); }
.bulk-tip { color: var(--muted); font-size: 12.5px; margin: 8px 0; line-height: 1.6; }
.bulk-tip .code { color: var(--accent-2); font-size: 12px; }
.bulk-add textarea {
  width: 100%; background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px;
  color: var(--text); padding: 10px 12px; font-size: 13px; font-family: var(--font);
  line-height: 1.7; resize: vertical;
}
.bulk-add textarea:focus { outline: none; border-color: var(--accent); }
.bulk-bar { display: flex; gap: 10px; margin-top: 8px; align-items: center; }
.bulk-bar select {
  background: var(--bg-2); border: 1px solid var(--line); border-radius: 8px;
  color: var(--text); padding: 7px 10px; font-size: 13px; font-family: var(--font);
}
.bulk-bar select:focus { outline: none; border-color: var(--accent); }

.schema-help {
  border-top: 1px solid var(--line);
  margin-top: 6px;
  padding-top: 12px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}
.schema-help h4 { color: var(--text); font-size: 13.5px; margin-bottom: 6px; }
.schema-help ul { padding-left: 20px; margin: 6px 0; }
.schema-help .code { color: var(--accent-2); font-size: 12px; }

/* ---------- 账号 Tab ---------- */
.account-card { max-width: 460px; }

/* ---------- 页码跳转菜单（复用 help-overlay 模式） ---------- */
.page-no { cursor: pointer; user-select: none; }
.page-no:hover { color: var(--accent); }
.jump-card { width: 420px; max-width: 92vw; max-height: 82vh; overflow: auto; }
.jump-list { display: flex; flex-direction: column; gap: 6px; }
.jump-item {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  padding: 8px 12px;
  font-size: 14px;
  text-align: left;
  transition: border-color .2s ease, color .2s ease;
}
.jump-item:hover { border-color: var(--accent); color: var(--accent); }
.jump-item.current { border-color: var(--accent-2); color: var(--accent-2); font-weight: 700; }
.jump-no {
  flex: none;
  width: 24px;
  text-align: right;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.jump-item.current .jump-no { color: var(--accent-2); }
.jump-tip { margin-top: 12px; color: var(--muted); font-size: 12.5px; }

@media (max-width: 900px) {
  .meta-edit-grid { grid-template-columns: 1fr 1fr; }
  .roster-search { margin-left: 0; width: 100%; }
}
