/* 博涵经营工作台 · 样式
   方向：账本与公文。冷调纸白底、浅色侧栏、宋体页题、等宽数字；
   印章红只用于废标/风险，琥珀色只用于业务链条条带这一处标志性元素。 */
:root {
  --paper: #f5f6f3;
  --surface: #ffffff;
  --sunk: #eef0ec;
  --ink: #1d2622;
  --ink-2: #47524c;
  --ink-3: #78837d;
  --rule: #dce1db;
  --rule-2: #e9ece7;
  --green: #24533f;      /* 主操作：墨绿 */
  --green-h: #1b4232;
  --green-t: #e6efe9;
  --amber: #e29a2e;      /* 链条条带 */
  --amber-d: #8f5a06;
  --amber-t: #fbf1df;
  --red: #b3372a;        /* 印章红：废标、风险、超额 */
  --red-t: #f8e9e6;
  --ok: #2d7a55;
  --ok-t: #e5f2ea;
  --warn: #a8650a;
  --warn-t: #fbf0de;
  --blue: #2f5c86;
  --blue-t: #e7eef5;
  --focus: #3d7fb8;
  --sans: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", "Source Han Sans SC", system-ui, sans-serif;
  --serif: "Songti SC", "STSong", "Noto Serif SC", "Source Han Serif SC", "SimSun", serif;
  --num: "DIN Alternate", "Bahnschrift", "DIN 2014", "Roboto Condensed", var(--sans);
  --mono: "SF Mono", "Cascadia Mono", Consolas, monospace;
  --r: 6px;
  --r-s: 4px;
  --pop: 0 10px 30px rgba(29, 38, 34, .16), 0 1px 3px rgba(29, 38, 34, .08);
  color-scheme: light;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--paper); color: var(--ink); font: 14px/1.65 var(--sans); -webkit-font-smoothing: antialiased; }
a { color: var(--green); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
::selection { background: #cfe3d6; }
.num { font-family: var(--num); font-variant-numeric: tabular-nums; letter-spacing: .01em; }
.muted { color: var(--ink-3); }
.small { font-size: 12px; }
.nowrap { white-space: nowrap; }
.right { text-align: right; }
.hide { display: none !important; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* ── 外框 ── */
.app { display: grid; grid-template-columns: 216px 1fr; min-height: 100vh; }
.side { background: var(--sunk); border-right: 1px solid var(--rule); position: sticky; top: 0; height: 100vh; overflow-y: auto; display: flex; flex-direction: column; }
.brand { padding: 18px 18px 14px; border-bottom: 1px solid var(--rule); }
.brand b { font-family: var(--serif); font-size: 19px; letter-spacing: .08em; font-weight: 700; display: block; }
.brand span { font-size: 12px; color: var(--ink-3); }
.nav { padding: 10px 8px 20px; flex: 1; }
.nav h6 { margin: 14px 10px 4px; font-size: 12px; font-weight: 500; color: var(--ink-3); }
.nav a { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: var(--r-s); color: var(--ink-2); position: relative; }
.nav a:hover { background: #e3e7e1; text-decoration: none; color: var(--ink); }
.nav a.on { background: var(--surface); color: var(--ink); font-weight: 600; box-shadow: inset 0 0 0 1px var(--rule); }
.nav a.on::before { content: ""; position: absolute; left: -8px; top: 7px; bottom: 7px; width: 3px; background: var(--amber); border-radius: 0 2px 2px 0; }
.nav a svg { width: 17px; height: 17px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.nav a em { margin-left: auto; font-style: normal; font-size: 11px; font-family: var(--num); background: var(--red); color: #fff; border-radius: 9px; padding: 0 6px; line-height: 17px; }
.side-foot { padding: 12px 18px; border-top: 1px solid var(--rule); font-size: 12px; color: var(--ink-3); }
.main { min-width: 0; display: flex; flex-direction: column; }
.top { height: 52px; display: flex; align-items: center; gap: 14px; padding: 0 28px; border-bottom: 1px solid var(--rule); background: var(--surface); position: sticky; top: 0; z-index: 20; }
.crumb { color: var(--ink-3); font-size: 13px; }
.crumb b { color: var(--ink); font-weight: 600; }
.top .grow { flex: 1; }
.search-btn { display: flex; align-items: center; gap: 8px; border: 1px solid var(--rule); background: var(--paper); border-radius: var(--r-s); padding: 5px 10px; color: var(--ink-3); cursor: pointer; min-width: 240px; font-size: 13px; }
.search-btn kbd { margin-left: auto; font: 11px var(--sans); border: 1px solid var(--rule); border-radius: 3px; padding: 0 4px; background: var(--surface); }
.who { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.who .av { width: 28px; height: 28px; border-radius: 50%; background: var(--green); color: #fff; display: grid; place-items: center; font-size: 12px; }
.content { padding: 24px 28px 60px; max-width: 1480px; width: 100%; }

/* ── 页头 ── */
.ph { display: flex; align-items: flex-end; gap: 20px; margin-bottom: 18px; flex-wrap: wrap; }
.ph h1 { font-family: var(--serif); font-size: 26px; font-weight: 700; letter-spacing: .04em; margin: 0; line-height: 1.3; }
.ph p { margin: 4px 0 0; color: var(--ink-2); max-width: 760px; }
.ph .acts { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }

/* ── 按钮 ── */
.btn { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--rule); background: var(--surface); padding: 6px 13px; border-radius: var(--r-s); cursor: pointer; font-size: 13px; line-height: 1.5; white-space: nowrap; color: var(--ink); }
.btn:hover { border-color: #b9c2ba; background: #fafbf9; text-decoration: none; }
.btn.pri { background: var(--green); border-color: var(--green); color: #fff; }
.btn.pri:hover { background: var(--green-h); }
.btn.warn { color: var(--red); border-color: #e3c1bb; }
.btn.ghost { border-color: transparent; background: none; color: var(--green); padding: 4px 6px; }
.btn.ghost:hover { background: var(--green-t); }
.btn.sm { padding: 3px 9px; font-size: 12px; }
.btn[disabled], .btn.busy { opacity: .55; cursor: not-allowed; }
.btn.busy::after { content: ""; width: 12px; height: 12px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.btn svg { width: 15px; height: 15px; stroke: currentColor; fill: none; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

/* ── 表单 ── */
label.f { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--ink-2); }
label.f > span { font-weight: 500; }
.inp, select.inp, textarea.inp { border: 1px solid #cfd6cf; border-radius: var(--r-s); padding: 6px 9px; background: #fff; font-size: 13px; min-width: 0; width: 100%; }
textarea.inp { min-height: 90px; resize: vertical; line-height: 1.6; }
.inp:focus { outline: 2px solid #b9d4c3; border-color: var(--green); }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px 16px; }
.grid4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px 16px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row.end { justify-content: flex-end; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.span2 { grid-column: span 2; }
.span3 { grid-column: span 3; }

/* ── 面板 ── */
.panel { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r); margin-bottom: 18px; min-width: 0; }
.panel > header { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-bottom: 1px solid var(--rule-2); }
.panel > header h2 { font-size: 15px; margin: 0; font-weight: 600; }
.panel > header .sub { color: var(--ink-3); font-size: 12px; }
.panel > header .acts { margin-left: auto; display: flex; gap: 6px; align-items: center; }
.panel > .body { padding: 14px 16px; }
.panel > .body.flush { padding: 0; }
.cols { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(300px, 1fr); gap: 18px; align-items: start; }
.cols.even { grid-template-columns: 1fr 1fr; }
.cols.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }

/* ── 指标条：一行横排，用竖线分隔，不做成卡片 ── */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r); margin-bottom: 18px; }
.kpi { padding: 14px 18px; border-right: 1px solid var(--rule-2); min-width: 0; }
.kpi:last-child { border-right: 0; }
.kpi .v { font-family: var(--num); font-size: 26px; line-height: 1.15; font-variant-numeric: tabular-nums; }
.kpi .v small { font-size: 13px; color: var(--ink-3); margin-left: 3px; font-family: var(--sans); }
.kpi .l { font-size: 12px; color: var(--ink-2); margin-top: 3px; }
.kpi .d { font-size: 12px; color: var(--ink-3); }
.kpi.risk .v { color: var(--red); }
.kpi.warn .v { color: var(--warn); }

/* ── 业务链条条带（标志性元素） ── */
.chain { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); margin-bottom: 18px; border-radius: var(--r); overflow: hidden; border: 1px solid #e7cf9f; background: var(--amber-t); }
.chain a { position: relative; padding: 10px 12px 10px 18px; color: var(--ink); display: block; min-width: 0; border-right: 1px solid #ecd6aa; }
.chain a:last-child { border-right: 0; }
.chain a:hover { background: #f8e6c4; text-decoration: none; }
.chain a .s { font-family: var(--num); font-size: 12px; color: var(--amber-d); }
.chain a b { display: block; font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chain a .c { font-size: 12px; color: var(--ink-2); }
.chain a .c i { font-style: normal; color: var(--red); font-weight: 600; }
.chain a::after { content: ""; position: absolute; right: -7px; top: 50%; width: 12px; height: 12px; background: inherit; border-top: 1px solid #ecd6aa; border-right: 1px solid #ecd6aa; transform: translateY(-50%) rotate(45deg); z-index: 1; }
.chain a:last-child::after { display: none; }
.chain a.on { background: var(--amber); color: #2a1a00; }
.chain a.on .s, .chain a.on .c { color: #3d2800; }

/* 步骤条（投标项目九步，沿用条带语言） */
.steps { display: flex; border: 1px solid var(--rule); border-radius: var(--r); background: var(--surface); overflow-x: auto; margin-bottom: 16px; }
.steps button { flex: 1; min-width: 104px; border: 0; background: none; padding: 9px 10px 8px 14px; text-align: left; cursor: pointer; border-right: 1px solid var(--rule-2); position: relative; }
.steps button:last-child { border-right: 0; }
.steps button .n { font-family: var(--num); font-size: 12px; color: var(--ink-3); }
.steps button b { display: block; font-size: 13px; font-weight: 600; white-space: nowrap; }
.steps button .st { font-size: 11px; color: var(--ink-3); }
.steps button.done .n { color: var(--ok); }
.steps button.done .st { color: var(--ok); }
.steps button.on { background: var(--amber-t); box-shadow: inset 0 -3px 0 var(--amber); }
.steps button:hover:not(.on) { background: #fafbf9; }

/* ── 表格 ── */
.tbl-wrap { overflow-x: auto; }
table.t { width: 100%; border-collapse: collapse; font-size: 13px; }
table.t th { text-align: left; font-weight: 500; color: var(--ink-3); font-size: 12px; padding: 8px 12px; border-bottom: 1px solid var(--rule); background: #fafbf9; white-space: nowrap; position: sticky; top: 0; }
table.t td { padding: 8px 12px; border-bottom: 1px solid var(--rule-2); vertical-align: top; }
table.t tr:last-child td { border-bottom: 0; }
table.t tbody tr:hover td { background: #fafcfa; }
table.t tr.click { cursor: pointer; }
table.t td.n, table.t th.n { text-align: right; font-family: var(--num); font-variant-numeric: tabular-nums; white-space: nowrap; }
table.t tfoot td { border-top: 1px solid var(--rule); font-weight: 600; background: #fafbf9; }
table.t.dense td { padding: 5px 10px; }
.cell-clip { max-width: 360px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ── 标记 ── */
.tag { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; line-height: 18px; padding: 0 7px; border-radius: 3px; background: var(--sunk); color: var(--ink-2); white-space: nowrap; }
.tag.ok { background: var(--ok-t); color: var(--ok); }
.tag.warn { background: var(--warn-t); color: var(--warn); }
.tag.risk { background: var(--red-t); color: var(--red); }
.tag.info { background: var(--blue-t); color: var(--blue); }
.tag.green { background: var(--green-t); color: var(--green); }
.tag.demo { background: transparent; border: 1px dashed #c2c9c2; color: var(--ink-3); }
.tag.amber { background: var(--amber-t); color: var(--amber-d); }
.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--ink-3); vertical-align: 1px; margin-right: 6px; }
.dot.ok { background: var(--ok); } .dot.warn { background: var(--amber); } .dot.risk { background: var(--red); } .dot.info { background: var(--blue); }
.code { font-family: var(--num); font-size: 12px; color: var(--ink-2); }
.seal { display: inline-block; border: 1.5px solid var(--red); color: var(--red); font-size: 11px; padding: 0 5px; border-radius: 3px; transform: rotate(-4deg); font-weight: 600; letter-spacing: .1em; }

/* 进度条（额度） */
.meter { height: 8px; background: var(--sunk); border-radius: 4px; overflow: hidden; position: relative; }
.meter i { display: block; height: 100%; background: var(--ok); border-radius: 4px; }
.meter.warn i { background: var(--amber); }
.meter.risk i { background: var(--red); }
.meter .tick { position: absolute; top: -2px; bottom: -2px; width: 1px; background: var(--ink-3); opacity: .6; }

/* 提示条 */
.note { border-left: 3px solid var(--green); background: var(--green-t); padding: 10px 14px; border-radius: 0 var(--r-s) var(--r-s) 0; margin: 0 0 14px; font-size: 13px; color: var(--ink-2); }
.note.warn { border-color: var(--amber); background: var(--warn-t); }
.note.risk { border-color: var(--red); background: var(--red-t); }
.note.plain { border-color: var(--rule); background: var(--surface); }
.note b { color: var(--ink); }

/* 分栏标签页 */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--rule); margin-bottom: 14px; overflow-x: auto; }
.tabs button { border: 0; background: none; padding: 8px 14px; cursor: pointer; color: var(--ink-2); border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; font-size: 13px; }
.tabs button.on { color: var(--ink); border-bottom-color: var(--green); font-weight: 600; }
.tabs button em { font-style: normal; font-family: var(--num); color: var(--ink-3); margin-left: 4px; }

/* 列表项（例外清单） */
.list { margin: 0; padding: 0; list-style: none; }
.list li { display: flex; gap: 12px; padding: 10px 16px; border-bottom: 1px solid var(--rule-2); align-items: flex-start; }
.list li:last-child { border-bottom: 0; }
.list li .ic { width: 22px; flex: none; padding-top: 2px; }
.list li .tx { flex: 1; min-width: 0; }
.list li .tx b { font-weight: 600; }
.list li .tx p { margin: 2px 0 0; color: var(--ink-3); font-size: 12px; }
.list li .go { flex: none; }

/* 空状态 */
.empty { padding: 36px 20px; text-align: center; color: var(--ink-3); }
.empty b { display: block; color: var(--ink-2); font-size: 15px; margin-bottom: 4px; }

/* 弹层 */
.overlay { position: fixed; inset: 0; background: rgba(29, 38, 34, .32); z-index: 50; display: flex; justify-content: flex-end; }
.overlay.center { align-items: center; justify-content: center; }
.drawer { width: min(760px, 100%); height: 100%; background: var(--surface); display: flex; flex-direction: column; box-shadow: var(--pop); animation: slidein .18s ease-out; }
.drawer.wide { width: min(1080px, 100%); }
@keyframes slidein { from { transform: translateX(24px); opacity: .6; } }
.drawer > header { padding: 14px 20px; border-bottom: 1px solid var(--rule); display: flex; gap: 10px; align-items: center; }
.drawer > header h3 { margin: 0; font-size: 17px; font-family: var(--serif); }
.drawer > header .x { margin-left: auto; }
.drawer > .body { padding: 16px 20px; overflow-y: auto; flex: 1; }
.drawer > footer { padding: 12px 20px; border-top: 1px solid var(--rule); display: flex; gap: 8px; justify-content: flex-end; }
.dialog { width: min(520px, calc(100% - 32px)); background: var(--surface); border-radius: var(--r); box-shadow: var(--pop); }
.dialog > header { padding: 14px 18px 0; }
.dialog > header h3 { margin: 0; font-size: 16px; }
.dialog > .body { padding: 12px 18px; }
.dialog > footer { padding: 10px 18px 16px; display: flex; gap: 8px; justify-content: flex-end; }
.toast-box { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); z-index: 80; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast { background: var(--ink); color: #fff; padding: 8px 16px; border-radius: var(--r-s); font-size: 13px; box-shadow: var(--pop); max-width: 560px; }
.toast.risk { background: var(--red); }

/* 命令面板 */
.palette { width: min(620px, calc(100% - 32px)); background: var(--surface); border-radius: var(--r); box-shadow: var(--pop); margin-top: 12vh; align-self: flex-start; overflow: hidden; }
.palette input { width: 100%; border: 0; border-bottom: 1px solid var(--rule); padding: 14px 18px; font-size: 15px; outline: none; }
.palette ul { list-style: none; margin: 0; padding: 6px; max-height: 50vh; overflow-y: auto; }
.palette li { padding: 8px 12px; border-radius: var(--r-s); cursor: pointer; display: flex; gap: 10px; align-items: baseline; }
.palette li.on, .palette li:hover { background: var(--green-t); }
.palette li small { color: var(--ink-3); margin-left: auto; font-size: 12px; }

/* 正文（Markdown 渲染） */
.prose { font-size: 14px; line-height: 1.8; color: var(--ink); max-width: 860px; }
.prose h1, .prose h2, .prose h3, .prose h4 { font-family: var(--serif); line-height: 1.4; margin: 1.2em 0 .5em; }
.prose h2 { font-size: 18px; } .prose h3 { font-size: 16px; } .prose h4 { font-size: 14px; }
.prose p { margin: .5em 0; }
.prose table { border-collapse: collapse; margin: .8em 0; font-size: 13px; }
.prose th, .prose td { border: 1px solid var(--rule); padding: 5px 9px; text-align: left; }
.prose th { background: #fafbf9; }
.prose ul, .prose ol { padding-left: 1.6em; }
.prose .todo { background: var(--warn-t); color: var(--warn); padding: 0 3px; border-radius: 2px; }
.prose mark.hit { background: #fde7a8; }
.prose blockquote { margin: .6em 0; padding: 4px 12px; border-left: 3px solid var(--rule); color: var(--ink-2); }

/* 流式输出 */
.stream { white-space: pre-wrap; font-size: 13px; line-height: 1.7; background: #fafbf9; border: 1px solid var(--rule-2); border-radius: var(--r-s); padding: 10px 12px; max-height: 360px; overflow-y: auto; color: var(--ink-2); }
.ai-meta { font-size: 12px; color: var(--ink-3); display: flex; gap: 10px; align-items: center; }

/* 原文核对 */
.q { font-size: 12px; color: var(--ink-3); margin-top: 3px; }
.q.bad { color: var(--red); }
.q::before { content: "原文 "; color: var(--ink-3); }
.q.bad::before { content: "原文未核对上 "; }

/* 泳道图 */
.swim { display: grid; grid-template-columns: 110px repeat(8, minmax(118px, 1fr)); border: 1px solid var(--rule); border-radius: var(--r); background: var(--surface); overflow-x: auto; }
.swim .h { padding: 8px 10px; font-size: 12px; background: #fafbf9; border-bottom: 1px solid var(--rule); border-right: 1px solid var(--rule-2); }
.swim .h b { display: block; font-size: 13px; color: var(--ink); }
.swim .ln { padding: 8px 10px; font-size: 13px; font-weight: 600; border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule-2); background: #fafbf9; }
.swim .ln small { display: block; font-weight: 400; color: var(--ink-3); font-size: 11px; }
.swim .cell { padding: 6px; border-right: 1px solid var(--rule-2); border-bottom: 1px solid var(--rule-2); display: flex; flex-direction: column; gap: 5px; min-height: 52px; }
.node { text-align: left; border: 1px solid var(--rule); background: #fff; border-radius: var(--r-s); padding: 4px 7px; cursor: pointer; font-size: 12px; line-height: 1.4; }
.node:hover { border-color: var(--green); }
.node .id { font-family: var(--num); color: var(--ink-3); font-size: 11px; }
.node.p { border-left: 3px solid var(--red); }
.node.on { background: var(--green); color: #fff; border-color: var(--green); }
.node.on .id { color: #cfe3d6; }
.node.dim { opacity: .28; }
.fdots { display: inline-flex; gap: 3px; margin-left: 4px; vertical-align: 1px; }
.fdots i { width: 6px; height: 6px; border-radius: 50%; display: inline-block; }
.fA { background: var(--blue); } .fB { background: var(--amber); } .fC { background: var(--ok); }

/* 文档阅读 */
.doc-layout { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 18px; align-items: start; }
.doc-list { position: sticky; top: 70px; max-height: calc(100vh - 90px); overflow-y: auto; }
.doc-list a { display: block; padding: 5px 10px; border-radius: var(--r-s); color: var(--ink-2); font-size: 13px; }
.doc-list a.on { background: var(--green-t); color: var(--green); font-weight: 600; }
.doc-list h6 { margin: 12px 10px 4px; font-size: 12px; color: var(--ink-3); font-weight: 500; }
.sop-steps { counter-reset: s; list-style: none; padding: 0; margin: 0; }
.sop-steps li { display: grid; grid-template-columns: 34px 120px 1fr; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--rule-2); }
.sop-steps li::before { counter-increment: s; content: counter(s); font-family: var(--num); font-size: 18px; color: var(--amber-d); }
.sop-steps .who { font-weight: 600; font-size: 13px; }
.sop-steps .who small { display: block; font-weight: 400; color: var(--ink-3); }

/* 登录 */
.login { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(360px, .9fr); }
.login .l { background: var(--sunk); padding: 56px 64px; display: flex; flex-direction: column; justify-content: space-between; border-right: 1px solid var(--rule); }
.login .l h1 { font-family: var(--serif); font-size: 34px; letter-spacing: .06em; margin: 0 0 10px; }
.login .l p { color: var(--ink-2); max-width: 520px; }
.login .r { display: flex; align-items: center; justify-content: center; padding: 40px; }
.login form { width: 340px; display: flex; flex-direction: column; gap: 14px; }
.login form h2 { margin: 0 0 4px; font-size: 18px; }
.login .mini-chain { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: #e7cf9f; border: 1px solid #e7cf9f; border-radius: var(--r); overflow: hidden; max-width: 560px; }
.login .mini-chain div { background: var(--amber-t); padding: 10px 12px; font-size: 13px; }
.login .mini-chain div span { display: block; font-family: var(--num); font-size: 11px; color: var(--amber-d); }

/* 编辑器 */
.editor { width: 100%; min-height: 420px; border: 1px solid var(--rule); border-radius: var(--r-s); padding: 14px 16px; font: 14px/1.85 var(--sans); resize: vertical; background: #fff; }
.split { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 16px; align-items: start; }
.outline-list { list-style: none; margin: 0; padding: 0; }
.outline-list li { padding: 6px 10px; border-radius: var(--r-s); cursor: pointer; font-size: 13px; display: flex; gap: 6px; align-items: baseline; }
.outline-list li:hover { background: var(--sunk); }
.outline-list li.on { background: var(--green-t); color: var(--green); font-weight: 600; }
.outline-list li.l2 { padding-left: 22px; }
.outline-list li.l3 { padding-left: 34px; font-size: 12px; }
.outline-list li .st { margin-left: auto; }

/* 评分条 */
.bar { display: flex; align-items: center; gap: 8px; }
.bar .track { flex: 1; height: 6px; background: var(--sunk); border-radius: 3px; overflow: hidden; }
.bar .track i { display: block; height: 100%; background: var(--green); }
.bar .track i.lo { background: var(--red); }
.bar .track i.mid { background: var(--amber); }

/* 打印 */
@media print {
  .side, .top, .acts, .btn, .tabs { display: none !important; }
  .app { display: block; }
  .content { padding: 0; }
  .panel { border: 0; }
}

/* 窄屏 */
@media (max-width: 1100px) {
  .cols, .cols.even, .cols.three { grid-template-columns: 1fr; }
  .chain { grid-template-columns: repeat(4, 1fr); }
  .chain a::after { display: none; }
  .doc-layout, .split { grid-template-columns: 1fr; }
  .doc-list { position: static; max-height: none; }
}
@media (max-width: 760px) {
  .app { grid-template-columns: 1fr; }
  .side { position: fixed; z-index: 60; width: 240px; transform: translateX(-100%); transition: transform .2s; }
  .side.open { transform: none; box-shadow: var(--pop); }
  .menu-btn { display: inline-flex !important; }
  .content { padding: 16px; }
  .top { padding: 0 16px; }
  .search-btn { min-width: 0; }
  .search-btn span { display: none; }
  .grid2, .grid3, .grid4 { grid-template-columns: 1fr; }
  .span2, .span3 { grid-column: auto; }
  .login { grid-template-columns: 1fr; }
  .login .l { padding: 32px 20px; }
  .chain { grid-template-columns: repeat(2, 1fr); }
}
.menu-btn { display: none; }
