/* ============================================================
   医学教学智能辅助系统 V1.0 · 统一设计系统
   医院信息化风格：医疗蓝主色 · 卡片化 · 8px 栅格 · 无外部依赖
   ============================================================ */
:root {
  --primary: #1a5cb8;
  --primary-dark: #144a96;
  --primary-light: #e8f1fd;
  --success: #1e8e38;
  --warning: #d97706;
  --danger: #d92d20;
  --purple: #7c3aed;
  --ink: #1f2937;
  --ink-2: #4b5563;
  --ink-3: #8a94a3;
  --line: #e5e9f0;
  --bg: #f4f6fa;
  --card: #ffffff;
  --radius: 8px;
  --shadow: 0 1px 3px rgba(16, 42, 90, .08);
  --nav-w: 220px;
  --topbar-h: 56px;
  font-size: 14px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif;
  color: var(--ink); background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
table { border-collapse: collapse; }
i { font-style: normal; }

/* ---------- 顶栏 ---------- */
.topbar { height: var(--topbar-h); background: var(--primary); position: sticky; top: 0; z-index: 50; }
.topbar-inner { max-width: 1680px; margin: 0 auto; height: 100%; display: flex; align-items: center; justify-content: space-between; padding: 0 24px; }
.brand { display: flex; align-items: center; gap: 12px; }
.brand-logo { width: 34px; height: 34px; border-radius: 8px; background: #fff; color: var(--primary); font-size: 18px; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.brand-name { color: #fff; font-size: 16px; font-weight: 600; letter-spacing: .5px; }
.brand-sub { color: rgba(255,255,255,.65); font-size: 11px; margin-top: 1px; }
.topbar-right { display: flex; align-items: center; gap: 12px; color: #fff; font-size: 13px; }
.topbar-right .avatar { width: 32px; height: 32px; border-radius: 50%; background: rgba(255,255,255,.2); display: flex; align-items: center; justify-content: center; font-size: 13px; }
.tag { padding: 3px 10px; border-radius: 20px; font-size: 12px; background: rgba(255,255,255,.15); color: #fff; }
.tag-blue { background: #fff; color: var(--primary); font-weight: 600; }

/* ---------- 布局：PC 管理台（左导航） ---------- */
.layout { display: flex; min-height: calc(100vh - var(--topbar-h)); max-width: 1680px; margin: 0 auto; }
.sidebar { width: var(--nav-w); background: #fff; border-right: 1px solid var(--line); position: sticky; top: var(--topbar-h); height: calc(100vh - var(--topbar-h)); padding: 16px 12px; overflow-y: auto; }
.side-group { margin-top: 14px; }
.side-group-t { font-size: 11px; color: var(--ink-3); padding: 6px 12px 4px; letter-spacing: 1px; }
.side-item { display: flex; align-items: center; gap: 8px; padding: 9px 12px; border-radius: 6px; color: var(--ink-2); font-size: 13.5px; cursor: pointer; }
.side-item svg { width: 16px; height: 16px; flex: none; }
.side-item:hover { background: var(--primary-light); color: var(--primary); }
.side-item.on { background: var(--primary); color: #fff; font-weight: 500; }
.side-item .side-badge { margin-left: auto; background: var(--danger); color: #fff; font-size: 10px; border-radius: 8px; padding: 1px 6px; }
.side-item.on .side-badge { background: rgba(255,255,255,.9); color: var(--danger); }

.content { flex: 1; min-width: 0; padding: 20px 24px 48px; }
.breadcrumb { font-size: 12px; color: var(--ink-3); margin-bottom: 14px; }
.breadcrumb b { color: var(--ink-2); font-weight: 500; }
.page-title { font-size: 20px; font-weight: 600; margin: 4px 0 6px; }
.page-sub { font-size: 13px; color: var(--ink-2); margin-bottom: 16px; }

/* ---------- 通用卡片 ---------- */
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 20px; margin-bottom: 16px; border: 1px solid #eef1f6; }
.card h3 { font-size: 14.5px; font-weight: 600; margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.card h3 .more { margin-left: auto; font-size: 12px; color: var(--primary); font-weight: 400; cursor: pointer; }
.grid { display: grid; gap: 16px; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

/* ---------- KPI 指标卡 ---------- */
.kpi { background: #fff; border: 1px solid #eef1f6; border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; }
.kpi .kpi-label { font-size: 12px; color: var(--ink-3); margin-bottom: 8px; display: flex; align-items: center; gap: 6px; }
.kpi .kpi-value { font-size: 26px; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: -.5px; }
.kpi .kpi-value small { font-size: 13px; font-weight: 400; color: var(--ink-3); margin-left: 4px; }
.kpi .kpi-foot { margin-top: 8px; font-size: 12px; color: var(--ink-3); display: flex; align-items: center; gap: 6px; }
.kpi .delta-up { color: var(--success); }
.kpi .delta-down { color: var(--danger); }
.kpi .kpi-bar { height: 4px; background: #eef1f6; border-radius: 2px; margin-top: 10px; overflow: hidden; }
.kpi .kpi-bar b { display: block; height: 100%; background: var(--primary); }
.kpi.hot { background: linear-gradient(135deg, #1a5cb8, #2f7fe0); color: #fff; }
.kpi.hot .kpi-label, .kpi.hot .kpi-foot { color: rgba(255,255,255,.75); }
.kpi.hot .kpi-bar { background: rgba(255,255,255,.25); }
.kpi.hot .kpi-bar b { background: #fff; }
.kpi.alert .kpi-value { color: var(--warning); }

/* ---------- 表格 ---------- */
.table-wrap { overflow-x: auto; }
.table { width: 100%; font-size: 13px; min-width: 720px; }
.table th { text-align: left; font-weight: 500; color: var(--ink-3); font-size: 12px; padding: 10px 12px; border-bottom: 1px solid var(--line); background: #fafbfc; white-space: nowrap; }
.table td { padding: 11px 12px; border-bottom: 1px solid #f0f2f6; vertical-align: middle; }
.table tbody tr:nth-child(even) { background: #fcfdfe; }
.table tbody tr:hover { background: var(--primary-light); }
.table .num { font-variant-numeric: tabular-nums; }
.table .op-link { color: var(--primary); cursor: pointer; font-size: 12.5px; }
.table .op-link + .op-link { margin-left: 12px; }
.table .op-link.danger { color: var(--danger); }

/* ---------- 状态标签 ---------- */
.st { display: inline-flex; align-items: center; gap: 5px; padding: 2.5px 9px; border-radius: 20px; font-size: 12px; white-space: nowrap; }
.st::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.st-green { color: var(--success); background: #e9f6ec; }
.st-orange { color: var(--warning); background: #fef3e2; }
.st-red { color: var(--danger); background: #fde8e6; }
.st-blue { color: var(--primary); background: var(--primary-light); }
.st-gray { color: var(--ink-3); background: #f1f3f6; }
.st-purple { color: var(--purple); background: #f1eafd; }

/* ---------- 按钮 ---------- */
.btn { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: 6px; font-size: 13px; cursor: pointer; border: 1px solid transparent; background: transparent; }
.btn-p { background: var(--primary); color: #fff; }
.btn-p:hover { background: var(--primary-dark); }
.btn-s { border-color: var(--line); color: var(--ink-2); background: #fff; }
.btn-s:hover { border-color: var(--primary); color: var(--primary); }
.btn-d { color: var(--danger); }
.btn-d:hover { background: #fde8e6; }
.btn-t { color: var(--primary); padding: 4px 6px; }
.btn-lg { padding: 11px 26px; font-size: 15px; border-radius: 8px; }

/* ---------- 表单 ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 24px; }
.form-item { display: flex; flex-direction: column; gap: 6px; }
.form-item.full { grid-column: 1 / -1; }
.form-item label { font-size: 13px; color: var(--ink-2); }
.form-item label b { color: var(--danger); font-weight: 400; }
.input, .select, .textarea { border: 1px solid var(--line); border-radius: 6px; padding: 8px 10px; font-size: 13px; color: var(--ink); background: #fff; font-family: inherit; }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(26,92,184,.12); }
.textarea { min-height: 72px; resize: vertical; }
.form-hint { font-size: 12px; color: var(--ink-3); }
.form-check { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink-2); }
.switch { width: 34px; height: 19px; border-radius: 10px; background: var(--primary); position: relative; flex: none; }
.switch::after { content: ""; position: absolute; right: 2px; top: 2px; width: 15px; height: 15px; border-radius: 50%; background: #fff; }
.switch.off { background: #cfd6e0; }
.switch.off::after { right: auto; left: 2px; }

/* ---------- 筛选工具条 ---------- */
.toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.toolbar .input, .toolbar .select { width: auto; min-width: 130px; }
.toolbar .spacer { flex: 1; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 14px; }
.tab { padding: 9px 16px; font-size: 13.5px; color: var(--ink-2); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tab.on { color: var(--primary); border-color: var(--primary); font-weight: 500; }
.tab .n { color: var(--ink-3); font-size: 12px; margin-left: 4px; }
.pager { display: flex; gap: 6px; align-items: center; margin-top: 14px; font-size: 12.5px; color: var(--ink-3); }
.pager button { min-width: 28px; height: 28px; border: 1px solid var(--line); background: #fff; border-radius: 5px; cursor: pointer; color: var(--ink-2); }
.pager button.on { background: var(--primary); border-color: var(--primary); color: #fff; }

/* ---------- 图表（纯 SVG 容器） ---------- */
.chart-card { background: #fff; border: 1px solid #eef1f6; border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; }
.chart-title { font-size: 14px; font-weight: 600; margin-bottom: 4px; }
.chart-sub { font-size: 12px; color: var(--ink-3); margin-bottom: 12px; }
.legend { display: flex; flex-wrap: wrap; gap: 14px; font-size: 12px; color: var(--ink-2); margin-top: 10px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 5px; vertical-align: -1px; }
svg text { font-family: inherit; }

/* ---------- 时间线 / 空状态 / 提示 ---------- */
.tl { position: relative; padding-left: 18px; }
.tl::before { content: ""; position: absolute; left: 5px; top: 4px; bottom: 4px; width: 2px; background: #e8edf4; }
.tl-item { position: relative; padding-bottom: 16px; }
.tl-item::before { content: ""; position: absolute; left: -18px; top: 3px; width: 12px; height: 12px; border-radius: 50%; background: #fff; border: 3px solid var(--primary); }
.tl-item.done::before { border-color: var(--success); }
.tl-item.warn::before { border-color: var(--warning); }
.tl-t { font-size: 12px; color: var(--ink-3); }
.tl-c { font-size: 13px; margin-top: 2px; }
.empty { text-align: center; color: var(--ink-3); font-size: 13px; padding: 40px 0; }
.alert-strip { display: flex; align-items: center; gap: 10px; background: #fff8ec; border: 1px solid #fde3b3; color: #8a5b00; border-radius: 8px; padding: 10px 14px; font-size: 13px; margin-bottom: 14px; }
.alert-strip.red { background: #fdf1f0; border-color: #f6c9c5; color: #8f241d; }

/* ---------- 角色卡（总览页） ---------- */
.bg-page { background: var(--bg); }
.container { max-width: 1200px; margin: 24px auto; padding: 0 20px; }
.page-desc { font-size: 13.5px; color: var(--ink-2); line-height: 1.8; margin-bottom: 20px; }
.role-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.role-card { display: block; border: 1px solid #eef1f6; border-radius: 10px; padding: 20px; background: #fff; box-shadow: var(--shadow); transition: transform .15s, box-shadow .15s; }
.role-card:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(16,42,90,.12); }
.role-icon { width: 44px; height: 44px; border-radius: 10px; display: flex; align-items: center; justify-content: center; margin-bottom: 12px; }
.role-icon svg { width: 24px; height: 24px; }
.ri-blue { background: var(--primary-light); color: var(--primary); }
.ri-green { background: #e9f6ec; color: var(--success); }
.ri-orange { background: #fef3e2; color: var(--warning); }
.ri-purple { background: #f1eafd; color: var(--purple); }
.role-card h3 { font-size: 15.5px; font-weight: 600; margin-bottom: 6px; }
.role-card p { font-size: 13px; color: var(--ink-2); line-height: 1.7; margin-bottom: 12px; }
.role-card .links { display: flex; gap: 14px; font-size: 12.5px; color: var(--primary); }
.role-card .links span::after { content: " →"; }
.section-title { font-size: 15px; font-weight: 600; margin-bottom: 12px; }
.mobile-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.m-card { display: flex; flex-direction: column; gap: 6px; border: 1px solid #eef1f6; border-radius: 8px; padding: 14px; font-size: 14px; font-weight: 500; background: #fff; box-shadow: var(--shadow); }
.m-card:hover { border-color: var(--primary); }
.m-dot { width: 10px; height: 10px; border-radius: 50%; }
.d-purple { background: var(--purple); } .d-orange { background: var(--warning); } .d-blue { background: var(--primary); } .d-green { background: var(--success); }
.m-go { font-size: 12px; color: var(--ink-3); font-weight: 400; }
.ds-grid { display: grid; grid-template-columns: 1fr 1.2fr 1.2fr; gap: 16px; }
.ds-block { border: 1px solid #eef1f6; border-radius: 8px; padding: 14px 16px; background: #fafbfd; }
.ds-block h4 { font-size: 13px; font-weight: 600; margin-bottom: 10px; }
.color-row { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--ink-2); padding: 4px 0; }
.color-row i { width: 16px; height: 16px; border-radius: 4px; border: 1px solid rgba(0,0,0,.08); }
.ds-list { font-size: 12.5px; color: var(--ink-2); line-height: 2; }
.note { font-size: 12px; color: var(--ink-3); margin-top: 10px; line-height: 1.7; }
.footer { text-align: center; color: var(--ink-3); font-size: 12px; padding: 24px 0 40px; }

/* ---------- 进度条 / 排名 ---------- */
.rank { display: flex; flex-direction: column; gap: 10px; }
.rank-item { display: grid; grid-template-columns: 22px 1fr 44px; gap: 10px; align-items: center; font-size: 13px; }
.rank-item .rk { width: 20px; height: 20px; border-radius: 5px; background: #eef1f6; color: var(--ink-3); font-size: 11px; display: flex; align-items: center; justify-content: center; }
.rank-item:nth-child(1) .rk { background: #ffd7d4; color: var(--danger); }
.rank-item:nth-child(2) .rk { background: #fde3b3; color: var(--warning); }
.rank-item:nth-child(3) .rk { background: var(--primary-light); color: var(--primary); }
.rank-item .pbar { height: 8px; background: #eef1f6; border-radius: 4px; overflow: hidden; }
.rank-item .pbar b { display: block; height: 100%; background: var(--primary); border-radius: 4px; }
.rank-item .pval { text-align: right; font-variant-numeric: tabular-nums; color: var(--ink-2); }

/* ---------- 雷达图卡片 / 头像组 ---------- */
.ava { width: 26px; height: 26px; border-radius: 50%; background: var(--primary); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 12px; margin-left: -6px; border: 2px solid #fff; }
.ava:first-child { margin-left: 0; }
.ava.a2 { background: var(--success); } .ava.a3 { background: var(--warning); } .ava.a4 { background: var(--purple); }

/* ---------- 驾驶舱大屏（深色） ---------- */
body.bigscreen { background: #0b1f3a; color: #dbe7f5; }
.bigscreen .topbar { background: #0d2547; }
.bigscreen .bs-wrap { max-width: 1680px; margin: 0 auto; padding: 18px 24px 40px; }
.bs-head { display: flex; align-items: center; justify-content: space-between; padding: 6px 4px 18px; }
.bs-head h1 { font-size: 24px; font-weight: 700; color: #fff; letter-spacing: 2px; }
.bs-head .bs-time { color: #7ea6d8; font-size: 13px; font-variant-numeric: tabular-nums; }
.bs-grid { display: grid; grid-template-columns: 300px 1fr 300px; gap: 14px; }
.bs-col { display: flex; flex-direction: column; gap: 14px; }
.bs-card { background: #12315a; border: 1px solid #1e4070; border-radius: 10px; padding: 16px; }
.bs-card h3 { font-size: 14px; font-weight: 600; color: #9cc4ee; margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.bs-card h3::before { content: ""; width: 3px; height: 14px; background: #3b82f6; border-radius: 2px; }
.bs-kpis { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.bs-kpi { background: #0e2a4f; border-radius: 8px; padding: 12px; }
.bs-kpi .v { font-size: 24px; font-weight: 700; color: #fff; font-variant-numeric: tabular-nums; }
.bs-kpi .v em { font-style: normal; font-size: 12px; font-weight: 400; color: #7ea6d8; margin-left: 3px; }
.bs-kpi .l { font-size: 12px; color: #7ea6d8; margin-top: 4px; }
.bs-live { font-size: 12px; color: #7ea6d8; }
.bs-live b { color: #34d399; font-size: 15px; font-variant-numeric: tabular-nums; }
.pulse { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #34d399; animation: pulse 1.6s infinite; margin-right: 6px; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(52,211,153,.55);} 70% { box-shadow: 0 0 0 8px rgba(52,211,153,0);} 100% { box-shadow: 0 0 0 0 rgba(52,211,153,0);} }
.bs-table { width: 100%; font-size: 12.5px; }
.bs-table th { color: #7ea6d8; font-weight: 400; text-align: left; padding: 7px 8px; border-bottom: 1px solid #1e4070; }
.bs-table td { padding: 8px; border-bottom: 1px solid #16345c; color: #dbe7f5; }
.bs-st { font-size: 11px; padding: 2px 8px; border-radius: 10px; }
.bs-st.run { background: rgba(52,211,153,.15); color: #34d399; }
.bs-st.wait { background: rgba(251,191,36,.15); color: #fbbf24; }
.bs-st.done { background: rgba(126,166,216,.18); color: #9cc4ee; }

/* ---------- 移动端 H5 ---------- */
body.mobile { background: #eef1f6; }
.phone-frame { min-height: 100vh; background: #f4f6fa; max-width: 480px; margin: 0 auto; }
.m-top { background: var(--primary); color: #fff; padding: 14px 16px 44px; position: relative; }
.m-top .m-title { font-size: 17px; font-weight: 600; }
.m-top .m-sub { font-size: 12px; opacity: .75; margin-top: 3px; }
.m-top .m-bell { position: absolute; right: 16px; top: 13px; font-size: 17px; }
.m-page { padding: 14px; margin-top: -30px; min-height: calc(100vh - 84px); }
.m-card { background: #fff; border-radius: 10px; box-shadow: var(--shadow); padding: 14px; margin-bottom: 12px; }
.m-card h3 { font-size: 14px; font-weight: 600; margin-bottom: 10px; display: flex; align-items: center; }
.m-card h3 .more { margin-left: auto; font-size: 12px; color: var(--ink-3); font-weight: 400; }
.m-kpis { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.m-kpi { background: #fff; border-radius: 10px; box-shadow: var(--shadow); padding: 12px; }
.m-kpi .v { font-size: 21px; font-weight: 700; font-variant-numeric: tabular-nums; }
.m-kpi .v small { font-size: 12px; color: var(--ink-3); font-weight: 400; }
.m-kpi .l { font-size: 11.5px; color: var(--ink-3); margin-top: 3px; }
.m-kpi.hot { background: linear-gradient(135deg,#1a5cb8,#2f7fe0); color: #fff; }
.m-kpi.hot .l { color: rgba(255,255,255,.8); }
.m-list { background: #fff; border-radius: 10px; box-shadow: var(--shadow); overflow: hidden; }
.m-list-item { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-bottom: 1px solid #f2f4f8; }
.m-list-item:last-child { border-bottom: none; }
.m-list-item .li-icon { width: 36px; height: 36px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 17px; flex: none; }
.m-list-item .li-main { flex: 1; min-width: 0; }
.m-list-item .li-t { font-size: 13.5px; font-weight: 500; }
.m-list-item .li-s { font-size: 11.5px; color: var(--ink-3); margin-top: 2px; }
.m-list-item .li-r { font-size: 11.5px; color: var(--ink-3); flex: none; }
.m-tabs { display: flex; background: #fff; border-radius: 10px; overflow: hidden; box-shadow: var(--shadow); margin-bottom: 12px; }
.m-tab { flex: 1; text-align: center; padding: 10px 0; font-size: 13px; color: var(--ink-2); position: relative; }
.m-tab.on { color: var(--primary); font-weight: 600; }
.m-tab.on::after { content: ""; position: absolute; left: 50%; bottom: 0; transform: translateX(-50%); width: 24px; height: 3px; background: var(--primary); border-radius: 2px; }
.m-tab .n { font-size: 11px; }
.m-tab .badge { position: absolute; top: 4px; right: 14px; background: var(--danger); color: #fff; font-size: 10px; border-radius: 8px; padding: 0 5px; }
.m-tabbar { position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 480px; height: 62px; background: #fff; border-top: 1px solid var(--line); display: flex; z-index: 40; }
.m-tab-item { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; font-size: 10.5px; color: var(--ink-3); }
.m-tab-item .ti { width: 18px; height: 18px; display: flex; align-items: center; justify-content: center; }
.m-tab-item .ti svg { width: 18px; height: 18px; }
.m-tab-item.on { color: var(--primary); font-weight: 500; }
.m-fab { position: fixed; bottom: 86px; left: 50%; transform: translateX(-50%); width: 132px; height: 44px; border-radius: 22px; background: var(--primary); color: #fff; font-size: 14.5px; font-weight: 600; display: flex; align-items: center; justify-content: center; gap: 6px; box-shadow: 0 6px 16px rgba(26,92,184,.4); z-index: 39; }
.m-search { display: flex; align-items: center; gap: 8px; background: #fff; border-radius: 10px; padding: 10px 14px; margin-bottom: 12px; box-shadow: var(--shadow); font-size: 13px; color: var(--ink-3); }
.m-qr { width: 150px; height: 150px; margin: 12px auto; }
.m-steps { display: flex; justify-content: space-between; position: relative; margin: 18px 8px 6px; }
.m-step { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 11px; color: var(--ink-3); z-index: 1; }
.m-step i { width: 26px; height: 26px; border-radius: 50%; background: #fff; border: 2px solid #d5dce6; display: flex; align-items: center; justify-content: center; font-size: 12px; color: var(--ink-3); }
.m-step.on i { border-color: var(--primary); background: var(--primary); color: #fff; }
.m-step.on { color: var(--primary); font-weight: 500; }
.m-step:not(:first-child)::before { content: ""; position: absolute; top: 13px; left: 0; right: 0; height: 2px; background: #e5eaf1; z-index: 0; }

/* ---------- 打印 / 水印示意 ---------- */
.wm-sample { position: relative; overflow: hidden; }
.wm-sample::after { content: "导出人：科教-张明 · 2026-04-02 09:30 · 院级数据"; position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; transform: rotate(-18deg); color: rgba(26,92,184,.08); font-size: 22px; font-weight: 700; letter-spacing: 4px; pointer-events: none; }

/* ---------- 场景流程页（scenarios） ---------- */
.sc-wrap { max-width: 980px; margin: 0 auto; padding: 20px 20px 60px; }
.sc-steps-nav { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.sc-steps-nav a { font-size: 12.5px; border: 1px solid var(--line); background: #fff; border-radius: 16px; padding: 5px 12px; color: var(--ink-2); }
.sc-pill { font-size: 12.5px; border: 1px solid var(--line); background: #fff; border-radius: 16px; padding: 5px 12px; color: var(--ink-2); display: inline-block; }
.sc-steps-nav .sc-arr { color: var(--ink-3); font-size: 12px; display: inline-block; }
.sc-steps-nav a.on { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 500; }
.sc-step { display: flex; gap: 16px; background: #fff; border: 1px solid #eef1f6; border-radius: 8px; box-shadow: var(--shadow); padding: 18px 20px; margin-bottom: 14px; }
.sc-num { width: 34px; height: 34px; flex: none; border-radius: 50%; background: var(--primary); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 15px; }
.sc-body { flex: 1; min-width: 0; }
.sc-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 6px; }
.sc-head .sc-title { font-size: 15px; font-weight: 600; }
.sc-role { display: inline-flex; align-items: center; padding: 2px 10px; border-radius: 12px; font-size: 11px; font-weight: 600; }
.sc-role.leader { background: #e9f6ec; color: var(--success); }
.sc-role.admin { background: var(--primary-light); color: var(--primary); }
.sc-role.teacher { background: #fef3e2; color: var(--warning); }
.sc-role.student { background: #f1eafd; color: var(--purple); }
.sc-role.system { background: #f1f3f6; color: var(--ink-3); }
.sc-desc { font-size: 13px; color: var(--ink-2); line-height: 1.8; }
.sc-record { margin-top: 10px; display: flex; align-items: flex-start; gap: 8px; background: #f4f6fa; border-radius: 6px; padding: 9px 12px; font-size: 12px; color: var(--ink-2); }
.sc-record b { color: var(--ink); flex: none; }
.sc-ops { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.sc-ops .sc-lb { font-size: 12px; color: var(--ink-3); }
.sc-ops a { font-size: 12px; border: 1px solid var(--line); background: #fff; border-radius: 14px; padding: 4px 12px; color: var(--primary); font-weight: 500; }
.sc-ops a:hover { border-color: var(--primary); background: var(--primary-light); }
.sc-index-card { display: block; border: 1px solid #eef1f6; border-radius: 10px; background: #fff; box-shadow: var(--shadow); padding: 18px 20px; }
.sc-index-card:hover { border-color: var(--primary); }
.sc-index-card h3 { font-size: 15px; font-weight: 600; margin-bottom: 6px; }
.sc-index-card p { font-size: 12.5px; color: var(--ink-2); line-height: 1.7; margin-bottom: 10px; }
.sc-index-card .sc-meta { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
/* 档案凭证卡片 */
.cert-card { border: 1px dashed #b9d4f5; background: #f8fbff; border-radius: 8px; padding: 14px 16px; position: relative; overflow: hidden; }
.cert-card .cert-no { font-size: 11px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.cert-card .wm { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; transform: rotate(-18deg); color: rgba(26,92,184,.07); font-size: 20px; font-weight: 700; letter-spacing: 4px; pointer-events: none; }

/* ---------- 响应式 ---------- */
@media (max-width: 1200px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .ds-grid { grid-template-columns: 1fr; }
  .mobile-grid { grid-template-columns: repeat(2, 1fr); }
  .bs-grid { grid-template-columns: 1fr; }
  .bs-col { flex-direction: row; flex-wrap: wrap; }
  .bs-col .bs-card { flex: 1 1 320px; }
}
@media (max-width: 900px) {
  .layout { flex-direction: column; }
  .sidebar { width: 100%; position: static; height: auto; display: flex; flex-wrap: wrap; gap: 6px; border-right: none; border-bottom: 1px solid var(--line); }
  .side-group { margin-top: 0; flex: 1; min-width: 200px; }
  .side-group-t { padding: 4px 8px; }
  .role-grid { grid-template-columns: 1fr; }
  .grid-2, .grid-3, .form-grid { grid-template-columns: 1fr; }
  .content { padding: 14px 14px 90px; }
}

/* ---------- 弹窗 / 抽屉（交互原型组件） ---------- */
.modal-mask { position: fixed; inset: 0; background: rgba(11,31,58,.5); z-index: 100; display: flex; align-items: center; justify-content: center; padding: 16px; }
.modal { background: var(--card); border-radius: var(--radius); width: 100%; max-width: 560px; max-height: 88vh; overflow: auto; box-shadow: 0 12px 40px rgba(16,42,90,.25); }
.modal.modal-lg { max-width: 760px; }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.modal-head h3 { font-size: 15px; color: var(--ink); }
.modal-x { background: none; border: 0; font-size: 18px; color: var(--ink-3); cursor: pointer; padding: 2px 6px; line-height: 1; }
.modal-x:hover { color: var(--danger); }
.modal-body { padding: 18px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 12px 18px; border-top: 1px solid var(--line); }
.modal-foot .btn { min-width: 72px; justify-content: center; }
.modal-body .form-grid { grid-template-columns: 1fr 1fr; gap: 12px 16px; }
.modal-body label { display: block; font-size: 12px; color: var(--ink-3); margin-bottom: 5px; }
.modal-body .input, .modal-body .select, .modal-body .textarea { width: 100%; }
.modal-body .field-full { grid-column: 1 / -1; }
/* 表单值 */
.form-val { display: flex; justify-content: space-between; padding: 9px 0; border-bottom: 1px dashed var(--line); font-size: 13px; }
.form-val:last-child { border-bottom: 0; }
.form-val span { color: var(--ink-3); }
.form-val b { color: var(--ink); font-weight: 500; text-align: right; }
/* 导入拖拽区 */
.dropzone { border: 2px dashed var(--line); border-radius: 8px; padding: 26px 16px; text-align: center; color: var(--ink-3); font-size: 13px; background: var(--bg); cursor: pointer; transition: border-color .15s; }
.dropzone:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-light); }
.dz-file { display: flex; align-items: center; gap: 10px; background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; margin-top: 10px; font-size: 13px; }
.dz-file .file-ico { width: 34px; height: 34px; border-radius: 6px; background: var(--primary-light); color: var(--primary); display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; flex: none; }
.dz-file small { color: var(--ink-3); display: block; }
/* 提示 toast */
.toast { position: fixed; left: 50%; bottom: 64px; transform: translateX(-50%) translateY(20px); background: #1f2937; color: #fff; font-size: 13px; padding: 9px 18px; border-radius: 8px; opacity: 0; pointer-events: none; transition: all .25s; z-index: 200; box-shadow: 0 6px 20px rgba(16,42,90,.3); }
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
/* 表格行内工具条 */
.tbl-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.tbl-tools .spacer { flex: 1; }
.m-modal-mask { position: fixed; inset: 0; background: rgba(11,31,58,.6); z-index: 120; display: none; }
.m-sheet { position: absolute; left: 0; right: 0; bottom: 0; background: var(--card); border-radius: 14px 14px 0 0; padding: 16px 16px calc(16px + env(safe-area-inset-bottom)); max-height: 78%; overflow: auto; }
.m-sheet .m-sheet-h { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.m-sheet .m-sheet-h b { font-size: 15px; }
.m-sheet .m-sheet-x { background: none; border: 0; font-size: 18px; color: var(--ink-3); cursor: pointer; }
.m-sheet .m-sheet-act { display: flex; gap: 8px; margin-top: 14px; }
.m-sheet .m-sheet-act .btn { flex: 1; justify-content: center; }
.m-list-check { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px dashed var(--line); font-size: 13px; }
.m-list-check:last-child { border-bottom: 0; }
.m-list-check input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--primary); }
@media (max-width: 900px) {
  .modal { max-width: 100%; }
  .modal-body .form-grid { grid-template-columns: 1fr; }
}
