/* 0829项目资料室 · 设计系统
   基调：机要资料室——沉稳、克制、高可读；深海军蓝导航 + 米白工作区 + 一处高饱和主色
   所有颜色/字号/间距只从这里取值，页面文件不写裸色 */

:root {
  --font: "Inter", -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei UI", "Microsoft YaHei", "Noto Sans CJK SC", "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;

  --bg: #F3F5F9;
  --bg-2: #EBEFF5;
  --surface: #FFFFFF;
  --surface-2: #F8FAFC;
  --surface-3: #F1F4F8;
  --line: #E5E9F0;
  --line-2: #D3DAE5;
  --ink: #101828;
  --ink-2: #344054;
  --ink-3: #667085;
  --ink-4: #98A2B3;

  --nav-bg: #0F1B33;
  --nav-bg-2: #16264A;
  --nav-ink: #C7D2E6;
  --nav-ink-2: #7F91B3;
  --nav-active: rgba(255,255,255,.08);

  --accent: #2E5BFF;
  --accent-2: #1F47D9;
  --accent-soft: #EAF0FF;
  --accent-ring: rgba(46,91,255,.22);
  --gold: #C79A2B;
  --gold-soft: #FBF3DF;

  /* 状态色（提供状态）——经色觉缺陷分辨校验，与图标/文字同时出现，绝不只靠颜色 */
  --st-none: #C4CBD6;      --st-none-soft: #F1F3F7;  --st-none-ink: #667085;
  --st-prep: #E8A317;      --st-prep-soft: #FFF5E0;  --st-prep-ink: #8A5B00;
  --st-done: #1B9E5F;      --st-done-soft: #E2F6EC;  --st-done-ink: #0B6B3E;
  --st-na:   #4B7BB5;      --st-na-soft:   #E7F0FA;  --st-na-ink:   #2B5787;
  --st-third:#C2479F;      --st-third-soft:#FAE8F4;  --st-third-ink: #8A2C6E;

  --ok: #12915F;    --ok-soft: #E3F5EC;
  --warn: #D98A0C;  --warn-soft: #FFF3DD;
  --danger: #D23B3B;--danger-soft: #FCE7E7;
  --info: #2E5BFF;  --info-soft: #EAF0FF;

  /* 核心方向色（4 类，经全对校验） */
  --d0: #3D4F8C; --d1: #2F6BFF; --d2: #0FA37F; --d3: #B4702B;

  --r-sm: 8px; --r: 12px; --r-lg: 16px; --r-xl: 22px;
  --sh-sm: 0 1px 2px rgba(16,24,40,.05), 0 1px 3px rgba(16,24,40,.04);
  --sh: 0 6px 16px -6px rgba(16,24,40,.10), 0 2px 6px rgba(16,24,40,.04);
  --sh-lg: 0 24px 48px -16px rgba(16,24,40,.22), 0 8px 16px -8px rgba(16,24,40,.08);
  --ease: cubic-bezier(.2,.7,.2,1);
  --sidebar-w: 248px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); font-size: 14px; line-height: 1.6; color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; }
h1, h2, h3, h4 { margin: 0; font-weight: 600; line-height: 1.3; letter-spacing: -.01em; }
h1 { font-size: 22px; } h2 { font-size: 18px; } h3 { font-size: 15px; } h4 { font-size: 14px; }
p { margin: 0; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
code, .mono { font-family: var(--mono); font-size: 12.5px; }
::selection { background: var(--accent-soft); }
[hidden] { display: none !important; }
.muted { color: var(--ink-3); }
.faint { color: var(--ink-4); }
.small { font-size: 12.5px; }
.tiny { font-size: 11.5px; }
.strong { font-weight: 600; }
.num { font-variant-numeric: tabular-nums; }
.nowrap { white-space: nowrap; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row { display: flex; align-items: center; gap: 8px; }
.row.wrap { flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.col { display: flex; flex-direction: column; gap: 8px; }
.grow { flex: 1 1 auto; min-width: 0; }
.gap-4 { gap: 4px; } .gap-12 { gap: 12px; } .gap-16 { gap: 16px; } .gap-24 { gap: 24px; }
.mt-8 { margin-top: 8px; } .mt-12 { margin-top: 12px; } .mt-16 { margin-top: 16px; } .mt-24 { margin-top: 24px; } .mt-32 { margin-top: 32px; }
.mb-8 { margin-bottom: 8px; } .mb-12 { margin-bottom: 12px; } .mb-16 { margin-bottom: 16px; } .mb-24 { margin-bottom: 24px; }
.center { text-align: center; }
.right { text-align: right; }
svg.i { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
svg.i.sm { width: 15px; height: 15px; }
svg.i.lg { width: 22px; height: 22px; }

/* ───────── 应用骨架 ───────── */
.app { display: grid; grid-template-columns: var(--sidebar-w) 1fr; min-height: 100vh; }
.sidebar { position: sticky; top: 0; height: 100vh; background: linear-gradient(180deg, var(--nav-bg) 0%, var(--nav-bg-2) 100%); color: var(--nav-ink); display: flex; flex-direction: column; padding: 22px 16px; overflow: hidden; }
.sidebar::before { content: ""; position: absolute; inset: 0; background: radial-gradient(600px 280px at -10% -10%, rgba(46,91,255,.28), transparent 60%), radial-gradient(400px 260px at 120% 110%, rgba(199,154,43,.14), transparent 60%); pointer-events: none; }
.sidebar > * { position: relative; }
.brand { display: flex; align-items: center; gap: 12px; padding: 4px 8px 20px; border-bottom: 1px solid rgba(255,255,255,.08); margin-bottom: 14px; }
.brand-mark { width: 38px; height: 38px; border-radius: 11px; background: linear-gradient(135deg, #3B6BFF, #1E3FBF); display: grid; place-items: center; color: #fff; box-shadow: 0 6px 16px -6px rgba(46,91,255,.8); flex: none; }
.brand-mark svg { width: 20px; height: 20px; }
.brand-title { font-weight: 600; color: #fff; font-size: 14.5px; line-height: 1.25; letter-spacing: .01em; }
.brand-sub { font-size: 11.5px; color: var(--nav-ink-2); margin-top: 3px; }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav-label { font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--nav-ink-2); padding: 14px 12px 6px; }
.nav a { display: flex; align-items: center; gap: 11px; padding: 9px 12px; border-radius: 9px; color: var(--nav-ink); font-weight: 500; transition: background .15s var(--ease), color .15s; }
.nav a:hover { background: rgba(255,255,255,.05); text-decoration: none; color: #fff; }
.nav a.active { background: var(--nav-active); color: #fff; box-shadow: inset 0 0 0 1px rgba(255,255,255,.06); }
.nav a .badge { margin-left: auto; }
.sidebar-foot { margin-top: auto; padding-top: 14px; border-top: 1px solid rgba(255,255,255,.08); }
.user-chip { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 10px; }
.user-chip:hover { background: rgba(255,255,255,.05); }
.avatar { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-size: 12.5px; font-weight: 600; color: #fff; background: linear-gradient(135deg, #5B7CFF, #2E5BFF); flex: none; letter-spacing: .02em; }
.avatar.sm { width: 24px; height: 24px; font-size: 10.5px; }
.avatar.gold { background: linear-gradient(135deg, #E0B84C, #B7861A); }
.avatar.teal { background: linear-gradient(135deg, #2DBB95, #0F8E6C); }
.avatar.plum { background: linear-gradient(135deg, #D46A9F, #A33A70); }
.user-name { color: #fff; font-weight: 500; font-size: 13.5px; line-height: 1.2; }
.user-role { color: var(--nav-ink-2); font-size: 11.5px; }
.secure-pill { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border-radius: 999px; background: rgba(27,158,95,.14); color: #8FE3B8; font-size: 11.5px; font-weight: 500; border: 1px solid rgba(143,227,184,.18); }
.secure-pill .dot { width: 6px; height: 6px; border-radius: 50%; background: #3DD68C; box-shadow: 0 0 0 3px rgba(61,214,140,.18); animation: pulse 2.2s infinite; }
@keyframes pulse { 0%,100% { box-shadow: 0 0 0 3px rgba(61,214,140,.18); } 50% { box-shadow: 0 0 0 6px rgba(61,214,140,.06); } }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 32px; background: rgba(243,245,249,.92); -webkit-backdrop-filter: saturate(160%) blur(10px); backdrop-filter: saturate(160%) blur(10px); border-bottom: 1px solid var(--line); }
.topbar h1 { font-size: 19px; }
.crumb { color: var(--ink-3); font-size: 12.5px; margin-bottom: 2px; }
.content { padding: 28px 32px 56px; max-width: 1360px; width: 100%; }
.page { animation: fadein .25s var(--ease); }
@keyframes fadein { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

/* ───────── 卡片 / 面板 ───────── */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--sh-sm); }
.card.pad { padding: 20px 22px; }
.card.hover:hover { box-shadow: var(--sh); border-color: var(--line-2); }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 22px; border-bottom: 1px solid var(--line); }
.card-head h3 { font-size: 15px; }
.card-body { padding: 20px 22px; }
.section-title { display: flex; align-items: baseline; gap: 10px; margin-bottom: 14px; }
.section-title h2 { font-size: 16px; }
.section-title .muted { font-size: 12.5px; }
.grid { display: grid; gap: 16px; }
.grid.c2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.c3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.c4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid.c5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
@media (max-width: 1100px) { .grid.c4, .grid.c5 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid.c3 { grid-template-columns: repeat(2, minmax(0,1fr)); } }
@media (max-width: 760px) { .grid.c2, .grid.c3, .grid.c4, .grid.c5 { grid-template-columns: 1fr; } }

/* KPI 指标块 */
.kpi { padding: 18px 20px; display: flex; flex-direction: column; gap: 6px; position: relative; overflow: hidden; }
.kpi .label { font-size: 12.5px; color: var(--ink-3); font-weight: 500; }
.kpi .value { font-size: 30px; font-weight: 600; letter-spacing: -.02em; line-height: 1.1; color: var(--ink); }
.kpi .value small { font-size: 14px; color: var(--ink-4); font-weight: 500; margin-left: 4px; letter-spacing: 0; }
.kpi .sub { font-size: 12px; color: var(--ink-3); }
.kpi .icon { position: absolute; right: 16px; top: 16px; width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); }
.kpi .icon.ok { background: var(--ok-soft); color: var(--ok); }
.kpi .icon.warn { background: var(--warn-soft); color: var(--warn); }
.kpi .icon.gold { background: var(--gold-soft); color: var(--gold); }
.kpi .icon.slate { background: var(--surface-3); color: var(--ink-3); }

/* 进度条 / 环 */
.bar { height: 8px; background: var(--surface-3); border-radius: 999px; overflow: hidden; display: flex; }
.bar > i { display: block; height: 100%; border-radius: 999px; transition: width .5s var(--ease); }
.bar.thin { height: 5px; }
.bar.segs > i { border-radius: 0; margin-right: 2px; }
.bar.segs > i:last-child { margin-right: 0; }
.ring { position: relative; width: 112px; height: 112px; }
.ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring .track { stroke: var(--surface-3); }
.ring .fill { stroke: var(--accent); stroke-linecap: round; transition: stroke-dashoffset .7s var(--ease); }
.ring .txt { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; }
.ring .txt b { font-size: 24px; font-weight: 600; letter-spacing: -.02em; line-height: 1; }
.ring .txt span { font-size: 11.5px; color: var(--ink-3); margin-top: 3px; }

/* ───────── 标签 / 徽章 ───────── */
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 2px 8px; border-radius: 999px; font-size: 11.5px; font-weight: 500; line-height: 18px; white-space: nowrap; border: 1px solid transparent; }
.badge.gray { background: var(--surface-3); color: var(--ink-3); }
.badge.outline { background: transparent; border-color: var(--line-2); color: var(--ink-3); }
.badge.blue { background: var(--accent-soft); color: var(--accent-2); }
.badge.gold { background: var(--gold-soft); color: #8A6414; }
.badge.ok { background: var(--ok-soft); color: #0B6B3E; }
.badge.warn { background: var(--warn-soft); color: #8A5B00; }
.badge.danger { background: var(--danger-soft); color: #A12626; }
.badge.navy { background: #E8ECF5; color: #23355F; }
.badge .dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; opacity: .85; }
.st { display: inline-flex; align-items: center; gap: 6px; padding: 3px 9px 3px 7px; border-radius: 999px; font-size: 12px; font-weight: 500; white-space: nowrap; }
.st::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.st.none { background: var(--st-none-soft); color: var(--st-none-ink); }
.st.none::before { background: var(--st-none); }
.st.prep { background: var(--st-prep-soft); color: var(--st-prep-ink); }
.st.prep::before { background: var(--st-prep); }
.st.done { background: var(--st-done-soft); color: var(--st-done-ink); }
.st.done::before { background: var(--st-done); }
.st.na { background: var(--st-na-soft); color: var(--st-na-ink); }
.st.na::before { background: var(--st-na); }
.st.third { background: var(--st-third-soft); color: var(--st-third-ink); }
.st.third::before { background: var(--st-third); }
.state { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 500; padding: 2px 8px; border-radius: 6px; }
.state.draft { color: #8A5B00; background: var(--warn-soft); border: 1px dashed #E5B75C; }
.state.submitted { color: #0B6B3E; background: var(--ok-soft); }
.state.none { color: var(--ink-4); background: var(--surface-3); }
.chip { display: inline-flex; align-items: center; gap: 4px; padding: 1px 7px; border-radius: 6px; background: var(--surface-3); color: var(--ink-3); font-size: 11.5px; white-space: nowrap; }
.chip.code { font-family: var(--mono); font-weight: 600; color: var(--ink-2); background: var(--surface-2); border: 1px solid var(--line); }
.dir-dot { width: 9px; height: 9px; border-radius: 3px; flex: none; }
.first { color: var(--gold); display: inline-flex; align-items: center; gap: 3px; font-size: 11.5px; font-weight: 600; white-space: nowrap; }

/* ───────── 按钮 ───────── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 8px 14px; border-radius: 9px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink-2); font-weight: 500; font-size: 13.5px; line-height: 20px; transition: all .15s var(--ease); white-space: nowrap; }
.btn:hover { background: var(--surface-2); border-color: #BFC8D6; color: var(--ink); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; box-shadow: 0 4px 10px -4px rgba(46,91,255,.6); }
.btn.primary:hover { background: var(--accent-2); border-color: var(--accent-2); }
.btn.navy { background: var(--nav-bg-2); border-color: var(--nav-bg-2); color: #fff; }
.btn.navy:hover { background: #1F3363; }
.btn.ghost { background: transparent; border-color: transparent; color: var(--ink-2); }
.btn.ghost:hover { background: var(--surface-3); }
.btn.danger { color: var(--danger); border-color: #F1C4C4; background: #fff; }
.btn.danger:hover { background: var(--danger-soft); }
.btn.ok { background: var(--ok); border-color: var(--ok); color: #fff; }
.btn.sm { padding: 5px 10px; font-size: 12.5px; border-radius: 8px; }
.btn.xs { padding: 3px 8px; font-size: 12px; border-radius: 7px; gap: 5px; }
.btn.lg { padding: 11px 20px; font-size: 14.5px; border-radius: 11px; }
.btn.block { width: 100%; }
.btn.icon { padding: 7px; }
.btn .spin { width: 14px; height: 14px; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; border-radius: 50%; animation: spin .7s linear infinite; }
.btn:not(.primary) .spin { border-color: var(--line-2); border-top-color: var(--accent); }
@keyframes spin { to { transform: rotate(360deg); } }

/* ───────── 表单 ───────── */
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 12.5px; font-weight: 500; color: var(--ink-2); }
.field .hint { font-size: 12px; color: var(--ink-4); }
.input, .select, .textarea { width: 100%; padding: 9px 12px; border-radius: 9px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); transition: border-color .15s, box-shadow .15s; outline: none; }
.input:focus, .select:focus, .textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-ring); }
.input::placeholder, .textarea::placeholder { color: var(--ink-4); }
.input.sm { padding: 6px 10px; font-size: 13px; border-radius: 8px; }
.textarea { min-height: 96px; resize: vertical; line-height: 1.55; }
.textarea.mono { font-family: var(--mono); font-size: 12.5px; }
.select { appearance: none; background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23667085' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'/></svg>"); background-repeat: no-repeat; background-position: right 10px center; padding-right: 32px; }
.input-icon { position: relative; }
.input-icon svg { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--ink-4); }
.input-icon .input { padding-left: 34px; }
.seg { display: inline-flex; background: var(--surface-3); padding: 3px; border-radius: 10px; gap: 2px; }
.seg button { border: 0; background: transparent; padding: 6px 12px; border-radius: 8px; color: var(--ink-3); font-weight: 500; font-size: 13px; transition: all .15s; }
.seg button.active { background: var(--surface); color: var(--ink); box-shadow: var(--sh-sm); }
.radio-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.radio-pills label { display: inline-flex; align-items: center; gap: 7px; padding: 7px 12px; border-radius: 9px; border: 1px solid var(--line-2); background: var(--surface); cursor: pointer; font-size: 13px; transition: all .15s; }
.radio-pills label:hover { border-color: #BFC8D6; }
.radio-pills input { display: none; }
.radio-pills label.on { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-2); box-shadow: 0 0 0 3px var(--accent-ring); }
.radio-pills label .st { padding: 0; background: transparent !important; }
.switch { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-size: 13px; color: var(--ink-2); }
.switch input { display: none; }
.switch i { width: 34px; height: 20px; border-radius: 999px; background: var(--line-2); position: relative; transition: background .2s; }
.switch i::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: left .2s var(--ease); }
.switch input:checked + i { background: var(--accent); }
.switch input:checked + i::after { left: 16px; }
.check { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; }
.check input { width: 16px; height: 16px; accent-color: var(--accent); margin: 0; }

/* ───────── 表格 ───────── */
.table-wrap { overflow: auto; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); }
table.tbl { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13.5px; }
.tbl th { position: sticky; top: 0; z-index: 1; text-align: left; font-weight: 600; font-size: 12px; color: var(--ink-3); letter-spacing: .02em; background: var(--surface-2); padding: 11px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl td { padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl tbody tr { transition: background .12s; }
.tbl tbody tr:hover td { background: var(--surface-2); }
.tbl tr.clickable { cursor: pointer; }
.tbl tr.open td { background: var(--accent-soft); }
.tbl .sub-row td { background: var(--surface-2); padding: 0; }
.tbl.compact th, .tbl.compact td { padding: 8px 12px; font-size: 13px; }

/* ───────── 列表行（清单） ───────── */
.group-head { display: flex; align-items: center; gap: 10px; padding: 18px 4px 8px; }
.group-head h3 { font-size: 15px; }
.group-head .bar { width: 120px; }
.item-row { display: grid; grid-template-columns: 58px 1fr auto; gap: 14px; align-items: center; padding: 12px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; margin-bottom: 8px; cursor: pointer; transition: all .15s var(--ease); }
.item-row:hover { border-color: var(--line-2); box-shadow: var(--sh); transform: translateY(-1px); }
.item-row.active { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-ring); }
.item-row .name { font-weight: 500; color: var(--ink); line-height: 1.45; }
.item-row .meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 5px; }
.item-row .rightcol { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; min-width: 150px; }
.others { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; color: var(--ink-3); }
.others .avatars { display: inline-flex; }
.others .avatars .avatar { margin-left: -6px; border: 2px solid var(--surface); }
.others .avatars .avatar:first-child { margin-left: 0; }

/* ───────── 抽屉 / 弹窗 / 提示 ───────── */
.backdrop { position: fixed; inset: 0; background: rgba(16,24,40,.42); -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px); z-index: 60; opacity: 0; transition: opacity .2s; }
.backdrop.show { opacity: 1; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(640px, 100vw); background: var(--surface); z-index: 61; box-shadow: var(--sh-lg); display: flex; flex-direction: column; transform: translateX(100%); transition: transform .28s var(--ease); overscroll-behavior: contain; }
.drawer.show { transform: none; }
.drawer-head { padding: 18px 24px; border-bottom: 1px solid var(--line); display: flex; align-items: flex-start; gap: 12px; }
.drawer-body { flex: 1; overflow: auto; padding: 22px 24px 32px; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
.drawer-foot { padding: 14px 24px; border-top: 1px solid var(--line); display: flex; align-items: center; gap: 10px; background: var(--surface-2); position: relative; transition: box-shadow .2s; }
.drawer-foot.shadow { box-shadow: 0 -12px 20px -10px rgba(16,24,40,.28); }
.drawer-foot.shadow::before { content: "↓ 下方还有内容"; position: absolute; top: -26px; left: 50%; transform: translateX(-50%); font-size: 11px; color: var(--ink-3); background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 2px 10px; box-shadow: var(--sh-sm); pointer-events: none; }
.modal { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; padding: 20px; }
.modal .box { background: var(--surface); border-radius: var(--r-xl); box-shadow: var(--sh-lg); width: min(560px, 100%); max-height: 90vh; overflow: auto; overscroll-behavior: contain; animation: pop .22s var(--ease); }
.modal .box.wide { width: min(880px, 100%); }
@keyframes pop { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }
.modal-head { padding: 18px 24px 6px; display: flex; align-items: center; justify-content: space-between; }
.modal-body { padding: 12px 24px 20px; }
.modal-foot { padding: 12px 24px 20px; display: flex; justify-content: flex-end; gap: 10px; }
.toasts { position: fixed; top: 18px; left: 50%; transform: translateX(-50%); z-index: 90; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; }
.toasts .toast { pointer-events: auto; }
.toast { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border-radius: 11px; background: #14213D; color: #fff; box-shadow: var(--sh-lg); font-size: 13.5px; animation: pop .2s var(--ease); max-width: 420px; }
.toast.ok { background: #0E6B45; } .toast.err { background: #9B2C2C; } .toast.warn { background: #8A5B00; }
.callout { display: flex; gap: 12px; padding: 14px 16px; border-radius: 12px; background: var(--accent-soft); color: #23355F; border: 1px solid #D5E0FF; font-size: 13.5px; line-height: 1.6; }
.callout svg { flex: none; margin-top: 2px; color: var(--accent); }
.callout.gold { background: var(--gold-soft); border-color: #F0E1B5; color: #6E4E0A; }
.callout.gold svg { color: var(--gold); }
.callout.warn { background: var(--warn-soft); border-color: #F3DCB0; color: #6E4A00; }
.callout.warn svg { color: var(--warn); }
.callout.ok { background: var(--ok-soft); border-color: #BFE7D2; color: #0B4F2E; }
.callout.ok svg { color: var(--ok); }
.callout.danger { background: var(--danger-soft); border-color: #F3C2C2; color: #7A1E1E; }
.callout.danger svg { color: var(--danger); }
.empty { text-align: center; padding: 48px 20px; color: var(--ink-3); }
.empty svg { width: 40px; height: 40px; stroke-width: 1.4; color: var(--ink-4); margin-bottom: 10px; }
.empty h4 { color: var(--ink-2); margin-bottom: 4px; }
.skeleton { background: linear-gradient(90deg, var(--surface-3) 25%, var(--bg-2) 37%, var(--surface-3) 63%); background-size: 400% 100%; animation: shimmer 1.4s infinite; border-radius: 8px; }
@keyframes shimmer { 0% { background-position: 100% 0; } 100% { background-position: 0 0; } }
kbd { font-family: var(--mono); font-size: 11px; padding: 1px 5px; border-radius: 5px; border: 1px solid var(--line-2); background: var(--surface-2); color: var(--ink-3); }
.divider { height: 1px; background: var(--line); margin: 16px 0; }
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin-bottom: 18px; }
.tabs button { border: 0; background: transparent; padding: 10px 14px; color: var(--ink-3); font-weight: 500; border-bottom: 2px solid transparent; margin-bottom: -1px; transition: all .15s; }
.tabs button:hover { color: var(--ink); }
.tabs button.active { color: var(--accent-2); border-bottom-color: var(--accent); }
.live { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--ink-3); }
.live .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 3px rgba(18,145,95,.18); animation: pulse 2s infinite; }
.live.off .dot { background: var(--ink-4); box-shadow: none; animation: none; }

/* 文件 */
.dropzone { border: 1.5px dashed var(--line-2); border-radius: 12px; padding: 22px; text-align: center; color: var(--ink-3); background: var(--surface-2); transition: all .15s; cursor: pointer; }
.dropzone:hover, .dropzone.over { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-2); }
.dropzone svg { width: 26px; height: 26px; stroke-width: 1.5; margin-bottom: 6px; }
.file-row { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); margin-top: 8px; }
.file-row .ficon { width: 34px; height: 34px; border-radius: 8px; display: grid; place-items: center; font-size: 10px; font-weight: 700; color: #fff; letter-spacing: .02em; flex: none; }
.file-row .fname { font-weight: 500; }
.file-row .fmeta { font-size: 11.5px; color: var(--ink-4); }
.file-row .bar { height: 4px; margin-top: 4px; }
.ficon.pdf { background: #D0453C; } .ficon.xls { background: #1E8F52; } .ficon.doc { background: #2B6CD9; } .ficon.ppt { background: #D06A2B; } .ficon.zip { background: #6B6F7B; } .ficon.img { background: #8A5AD6; } .ficon.oth { background: #4B5563; }

/* 树 */
.tree { font-size: 13.5px; }
.tree .node { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 8px; }
.tree .node:hover { background: var(--surface-2); }
.tree .node .tog { width: 18px; height: 18px; display: grid; place-items: center; color: var(--ink-4); cursor: pointer; border-radius: 5px; }
.tree .node .tog:hover { background: var(--surface-3); color: var(--ink-2); }
.tree .node .tog svg { transition: transform .15s; }
.tree .node.open > .tog svg { transform: rotate(90deg); }
.tree .children { margin-left: 26px; border-left: 1px solid var(--line); padding-left: 6px; }
.tree .cnt { font-size: 11.5px; color: var(--ink-4); }
.tree .node .act { margin-left: auto; opacity: 0; transition: opacity .12s; }
.tree .node:hover .act { opacity: 1; }

/* 资料地图（热图格） */
.heat { display: grid; grid-template-columns: repeat(auto-fill, minmax(30px, 1fr)); gap: 4px; }
.heat .cell { aspect-ratio: 1; border-radius: 6px; background: var(--st-none-soft); display: grid; place-items: center; font-size: 9.5px; font-family: var(--mono); color: var(--ink-4); cursor: pointer; position: relative; transition: transform .12s, box-shadow .12s; border: 1px solid transparent; }
.heat .cell:hover { transform: scale(1.12); box-shadow: var(--sh); z-index: 2; }
.heat .cell.prep { background: var(--st-prep); color: #fff; }
.heat .cell.done { background: var(--st-done); color: #fff; }
.heat .cell.na { background: var(--st-na); color: #fff; }
.heat .cell.third { background: var(--st-third); color: #fff; }
.heat .cell.draft { border: 1.5px dashed var(--st-prep); background: var(--st-prep-soft); color: var(--st-prep-ink); }
.heat .cell.first::after { content: ""; position: absolute; top: 2px; right: 2px; width: 5px; height: 5px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 1px #fff; }
.legend { display: flex; flex-wrap: wrap; gap: 14px; font-size: 12px; color: var(--ink-3); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 12px; height: 12px; border-radius: 4px; display: inline-block; }

/* 纪要正文（markdown） */
.md { font-size: 14px; line-height: 1.75; color: var(--ink-2); }
.md h1 { font-size: 20px; margin: 0 0 14px; color: var(--ink); }
.md h2 { font-size: 16px; margin: 22px 0 10px; padding-bottom: 6px; border-bottom: 1px solid var(--line); color: var(--ink); }
.md h3 { font-size: 14.5px; margin: 16px 0 6px; color: var(--ink); }
.md p { margin: 0 0 10px; }
.md ul, .md ol { margin: 0 0 10px; padding-left: 22px; }
.md li { margin: 3px 0; }
.md table { border-collapse: collapse; width: 100%; margin: 8px 0 14px; font-size: 13px; }
.md th, .md td { border: 1px solid var(--line); padding: 6px 10px; text-align: left; vertical-align: top; }
.md th { background: var(--surface-2); font-weight: 600; }
.md blockquote { margin: 8px 0; padding: 6px 14px; border-left: 3px solid var(--line-2); color: var(--ink-3); }
.md code { background: var(--surface-3); padding: 1px 5px; border-radius: 5px; }
.md hr { border: 0; border-top: 1px solid var(--line); margin: 16px 0; }

/* 登录页 */
.login { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; }
.login-brand { position: relative; overflow: hidden; background: linear-gradient(160deg, #0C1730 0%, #14264D 55%, #1B2F5C 100%); color: #fff; padding: 56px 64px; display: flex; flex-direction: column; }
.login-brand::before { content: ""; position: absolute; inset: 0; background-image: linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px); background-size: 44px 44px; mask-image: radial-gradient(700px 500px at 30% 20%, #000, transparent 75%); }
.login-brand::after { content: ""; position: absolute; width: 520px; height: 520px; right: -180px; bottom: -220px; border-radius: 50%; background: radial-gradient(circle at 30% 30%, rgba(46,91,255,.55), rgba(46,91,255,0) 60%); filter: blur(10px); }
.login-brand > * { position: relative; z-index: 1; }
.login-brand h1 { font-size: 34px; font-weight: 600; letter-spacing: -.02em; line-height: 1.2; margin-top: 18px; }
.login-brand .lead { color: #AEBBD8; font-size: 15px; margin-top: 14px; max-width: 460px; line-height: 1.7; }
.login-points { margin-top: 44px; display: grid; gap: 14px; max-width: 480px; }
.login-points > div { display: flex; gap: 12px; align-items: flex-start; color: #D6DFF0; font-size: 13.5px; line-height: 1.55; }
.login-points .ic { width: 34px; height: 34px; border-radius: 10px; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.09); display: grid; place-items: center; color: #8FB0FF; flex: none; }
.login-points b { display: block; color: #fff; font-weight: 600; margin-bottom: 1px; }
.login-foot { margin-top: auto; color: #6F82A8; font-size: 12px; line-height: 1.7; }
.login-panel { display: grid; place-items: center; padding: 40px 24px; background: var(--bg); }
.login-card { width: min(420px, 100%); background: var(--surface); border-radius: 20px; box-shadow: var(--sh-lg); border: 1px solid var(--line); padding: 36px 36px 30px; }
.login-card h2 { font-size: 22px; letter-spacing: -.01em; }
.login-card .sub { color: var(--ink-3); margin-top: 6px; font-size: 13.5px; }
.login-card .field { margin-top: 18px; }
.login-card .input { padding: 11px 13px; font-size: 14.5px; }
.login-card .btn { margin-top: 22px; }
.login-note { margin-top: 20px; font-size: 12px; color: var(--ink-4); text-align: center; line-height: 1.7; }
.err-box { margin-top: 14px; padding: 10px 12px; border-radius: 9px; background: var(--danger-soft); color: #8F1F1F; font-size: 13px; display: none; }
.err-box.show { display: block; }
@media (max-width: 900px) { .login { grid-template-columns: 1fr; } .login-brand { padding: 36px 28px; min-height: 40vh; } .login-points { display: none; } }

/* 响应式：窄屏收起侧栏 */
@media (max-width: 960px) {
  .app { grid-template-columns: 1fr; }
  .sidebar { position: fixed; z-index: 50; left: 0; top: 0; width: var(--sidebar-w); transform: translateX(-100%); transition: transform .25s var(--ease); }
  .sidebar.open { transform: none; }
  .topbar { padding: 12px 16px; }
  .content { padding: 18px 16px 48px; }
  .menu-btn { display: inline-flex !important; }
  .live span:last-child { display: none; }
}
@media (max-width: 760px) {
  .item-row { grid-template-columns: 58px 1fr; }
  .item-row .rightcol { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: space-between; min-width: 0; }
  .topbar h1 { font-size: 17px; }
  .crumb { display: none; }
}
.menu-btn { display: none; }
@media print { .sidebar, .topbar, .btn { display: none !important; } .app { display: block; } }
