/* ============================================================
   i会计 iAccounting — 样式表
   ============================================================

   两套外壳，视觉刻意拉开距离：

     客户 Portal   浅色 + 科技蓝，像面向客户的财务 SaaS 产品
     内部 Admin    深色侧边栏，像内部管理系统

   看起来像的话，早晚有人在客户界面上做全平台的判断。

   ── 关于虚线 ────────────────────────────────────────────────
   这份文件里**一处 dashed 都没有**，这是刻意的。
   上传区原本用 `border: 2px dashed` 做拖拽提示，而它挂在一个
   <label> 上（默认 display:inline）；inline 盒里放块级子元素会被
   浏览器拆成多个行内片段，每个片段各画一段自己的边框 ——
   于是卡片左下角出现一条竖虚线加一个 L 形折角。

   加 display:block 能修好，但只要虚线还在，这类问题就还有复发的
   土壤（将来任何人改了 display、加了 float、套了 flex 都可能重现）。
   所以这次直接换掉表现手法：实线 + 内层浅色面板 + 悬停变色，
   **不依赖任何 dashed**。没有虚线，就不会有虚线残影。
   ============================================================ */

:root {
    /* ---- 科技蓝主色阶 ---- */
    --brand-950: #071a33;
    --brand-900: #0b2545;
    --brand-800: #10305a;
    --brand-700: #16406f;
    --brand-600: #1259a8;
    --brand-500: #1f6feb;
    --brand-400: #4d8ef7;
    --brand-300: #8fb8fb;
    --brand-100: #dce9fd;
    --brand-050: #f2f7ff;

    --bg: #f4f6fb;
    --panel: #ffffff;
    --panel-2: #fafbfe;
    --border: #dfe4ec;
    --border-strong: #c6cedb;
    --text: #16202c;
    --text-2: #3d4a5c;
    --muted: #6b7789;

    --accent: var(--brand-500);
    --accent-soft: var(--brand-100);

    --ok: #0f7b4f;
    --ok-soft: #e4f5ec;
    --warn: #92600a;
    --warn-soft: #fdf4e0;
    --err: #b42318;
    --err-soft: #fdecea;

    --radius: 12px;
    --radius-sm: 8px;
    --radius-lg: 18px;

    --shadow-sm: 0 1px 2px rgba(16, 48, 90, .06);
    --shadow: 0 2px 8px rgba(16, 48, 90, .07), 0 1px 2px rgba(16, 48, 90, .05);
    --shadow-lg: 0 10px 32px rgba(11, 37, 69, .10);

    --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
            "Hiragino Sans GB", "Microsoft YaHei", Roboto, Helvetica, Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #0e141c;
        --panel: #151d27;
        --panel-2: #111922;
        --border: #263141;
        --border-strong: #35435a;
        --text: #e7ecf3;
        --text-2: #bcc7d6;
        --muted: #8996a8;
        --brand-100: #16304f;
        --brand-050: #101d2e;
        --accent: var(--brand-400);
        --accent-soft: #16304f;
        --ok: #4ade80;
        --ok-soft: #10281c;
        --warn: #fbbf24;
        --warn-soft: #2e2410;
        --err: #f87171;
        --err-soft: #35191a;
    }
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    font-size: 15px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3 { color: var(--text); letter-spacing: -.01em; }
h1 { font-size: 25px; margin: 0 0 6px; font-weight: 700; }
h2 { font-size: 18px; margin: 0 0 12px; font-weight: 650; }
h3 { font-size: 15px; margin: 0 0 8px; font-weight: 650; }

code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: .92em;
    background: var(--brand-050);
    border: 1px solid var(--border);
    border-radius: 5px;
    padding: 1px 5px;
}

.muted { color: var(--muted); }
.small { font-size: 13px; }
.sub { color: var(--muted); margin: 0 0 18px; }
.num { text-align: right; font-variant-numeric: tabular-nums; }

/* ---------- 容器 ---------- */
.wrap {
    width: 100%;
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 24px;
}

main { padding: 26px 0 60px; }

/* ============================================================
   客户 Portal — 顶栏
   ============================================================ */

.site {
    background: var(--panel);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 20;
}

.site-bar {
    display: flex;
    align-items: center;
    gap: 18px;
    flex-wrap: wrap;
    min-height: 58px;
    padding: 8px 24px;
}

.brand {
    font-weight: 700;
    font-size: 17px;
    letter-spacing: -.02em;
    display: flex;
    align-items: baseline;
    gap: 7px;
    white-space: nowrap;
}
.brand a { color: inherit; text-decoration: none; }
.brand span {
    font-weight: 500;
    font-size: 11px;
    color: var(--brand-600);
    background: var(--brand-100);
    border-radius: 4px;
    padding: 2px 6px;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.portal-nav { display: flex; gap: 2px; flex-wrap: wrap; flex: 1; }
.portal-nav a {
    color: var(--text-2);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    padding: 7px 12px;
    border-radius: var(--radius-sm);
    transition: background .12s, color .12s;
}
.portal-nav a:hover { background: var(--brand-050); color: var(--brand-600); text-decoration: none; }
.portal-nav a.on { background: var(--brand-100); color: var(--brand-700); font-weight: 650; }

.who {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 13px;
    color: var(--muted);
    white-space: nowrap;
}
.who .sep { opacity: .4; }

/* ============================================================
   Hero — 首屏价值主张
   ============================================================ */

.hero {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-lg);
    padding: 34px 34px 30px;
    margin-bottom: 22px;
    color: #eaf2ff;
    background:
        radial-gradient(1100px 420px at 88% -30%, rgba(77, 142, 247, .40), transparent 62%),
        linear-gradient(135deg, var(--brand-900) 0%, var(--brand-800) 48%, var(--brand-700) 100%);
    box-shadow: var(--shadow-lg);
}

/* 细网格纹理：数据处理的观感，不喧宾夺主 */
.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, .05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, .05) 1px, transparent 1px);
    background-size: 34px 34px;
    pointer-events: none;
    mask-image: linear-gradient(to bottom right, rgba(0,0,0,.9), transparent 72%);
    -webkit-mask-image: linear-gradient(to bottom right, rgba(0,0,0,.9), transparent 72%);
}

.hero > * { position: relative; z-index: 1; }

.hero .eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--brand-300);
    background: rgba(143, 184, 251, .12);
    border: 1px solid rgba(143, 184, 251, .28);
    border-radius: 999px;
    padding: 4px 12px;
    margin-bottom: 14px;
}
.hero .eyebrow::before {
    content: "";
    width: 6px; height: 6px;
    border-radius: 50%;
    background: #5ee9a4;
    box-shadow: 0 0 0 3px rgba(94, 233, 164, .18);
}

.hero h1 {
    color: #fff;
    font-size: 29px;
    line-height: 1.3;
    margin: 0 0 10px;
    letter-spacing: -.02em;
}
.hero .lede {
    color: #c3d6f4;
    max-width: 62ch;
    margin: 0 0 22px;
    font-size: 15px;
}

.hero-points {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 12px;
}
.hero-points li {
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: var(--radius);
    padding: 13px 15px;
    backdrop-filter: blur(2px);
}
.hero-points strong {
    display: block;
    color: #fff;
    font-size: 14px;
    font-weight: 650;
    margin-bottom: 3px;
}
.hero-points .hint { color: #b6cbeb; font-size: 12.5px; line-height: 1.55; display: block; }

.hero .actions { margin-top: 20px; }
.hero .btn.ghost {
    background: rgba(255, 255, 255, .10);
    border-color: rgba(255, 255, 255, .26);
    color: #eaf2ff;
}
.hero .btn.ghost:hover { background: rgba(255, 255, 255, .17); }

/* ---------- 段落标题 ---------- */
.section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
    margin: 30px 0 12px;
}
.section-head h2 { margin: 0; }
.section-head .hint { color: var(--muted); font-size: 13px; }

/* ============================================================
   卡片 / 面板
   ============================================================ */

.panel, .card {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
    margin-bottom: 18px;
    box-shadow: var(--shadow-sm);
}

.card { margin-bottom: 0; }

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 14px;
}

/* 保留期限之类的说明卡 */
.info-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 12px;
}
.info-card {
    background: var(--panel);
    border: 1px solid var(--border);
    border-left: 3px solid var(--brand-400);
    border-radius: var(--radius-sm);
    padding: 13px 15px;
    box-shadow: var(--shadow-sm);
}
.info-card .k {
    color: var(--muted);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .03em;
    text-transform: uppercase;
    margin-bottom: 4px;
}
.info-card .v { font-size: 20px; font-weight: 700; color: var(--brand-700); line-height: 1.25; }
.info-card .d { color: var(--muted); font-size: 12.5px; margin-top: 3px; }

/* ---------- 统计卡 ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.stat {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 15px;
    background: var(--panel);
    box-shadow: var(--shadow-sm);
}
.stat .n { font-size: 26px; font-weight: 700; line-height: 1.2; letter-spacing: -.02em; }
.stat .k { color: var(--muted); font-size: 12.5px; margin-top: 3px; }
.stat.ok .n { color: var(--ok); }
.stat.warn .n { color: var(--warn); }
.stat.err .n { color: var(--err); }

/* ---------- 隐私优先区块（沿用旧 class 名）---------- */
.privacy-first { background: var(--panel); }
.privacy-points {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 13px;
}
.privacy-points li {
    background: var(--brand-050);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 13px 15px;
}
.privacy-points strong { display: block; margin-bottom: 3px; font-weight: 650; }
.privacy-points .hint { color: var(--muted); font-size: 12.5px; line-height: 1.55; }

/* ---------- data-status 组件 ---------- */
.data-status { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; }

/* ============================================================
   上传区 —— 重做，不使用任何 dashed
   ============================================================ */

.upload-card {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 26px;
    margin-bottom: 18px;
    box-shadow: var(--shadow);
}

.dropzone {
    /* block 是硬要求：这是个 <label>，默认 inline。
       inline 盒里放块级子元素会被拆成多个行内片段，每个片段各画一段
       自己的边框 —— 那正是当初卡片左下角那条竖线加折角的来源。
       现在边框改成实线，即便万一又变回 inline 也不会出现虚线残影。 */
    display: block;
    width: 100%;
    border: 1px solid var(--border-strong);
    border-radius: var(--radius);
    padding: 40px 24px;
    text-align: center;
    background:
        linear-gradient(180deg, var(--brand-050) 0%, var(--panel) 100%);
    cursor: pointer;
    transition: border-color .15s, background .15s, box-shadow .15s;
}
.dropzone:hover {
    border-color: var(--brand-400);
    box-shadow: 0 0 0 4px var(--brand-100);
}
.dropzone.hover {
    border-color: var(--brand-500);
    background: linear-gradient(180deg, var(--brand-100) 0%, var(--brand-050) 100%);
    box-shadow: 0 0 0 4px var(--brand-100);
}

.dropzone .icon {
    width: 46px;
    height: 46px;
    margin: 0 auto 13px;
    border-radius: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--brand-600), var(--brand-400));
    color: #fff;
    font-size: 21px;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(18, 89, 168, .28);
}
.dropzone .big { font-size: 17px; font-weight: 650; margin-bottom: 5px; color: var(--text); }
.dropzone .hint { color: var(--muted); font-size: 13px; }
.dropzone input[type=file] { display: none; }

.filelist { margin-top: 15px; text-align: left; }
.filelist div {
    font-size: 13px;
    color: var(--text-2);
    padding: 7px 11px;
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-top: 6px;
}

.upload-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
}
.upload-foot .note { color: var(--muted); font-size: 12.5px; max-width: 46ch; }

/* ---------- 流程提示 ---------- */
.steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
    counter-reset: step;
}
.step {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 13px 15px 13px 46px;
    position: relative;
    box-shadow: var(--shadow-sm);
}
.step::before {
    counter-increment: step;
    content: counter(step);
    position: absolute;
    left: 14px;
    top: 13px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--brand-100);
    color: var(--brand-700);
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}
.step strong { display: block; font-size: 14px; font-weight: 650; }
.step .hint { color: var(--muted); font-size: 12.5px; }

/* ============================================================
   按钮
   ============================================================ */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-sm);
    background: var(--panel);
    color: var(--text);
    padding: 9px 16px;
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    text-decoration: none;
    transition: background .12s, border-color .12s, box-shadow .12s, transform .06s;
}
.btn:hover { background: var(--panel-2); border-color: var(--brand-300); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn:disabled, .btn[disabled] { opacity: .5; cursor: not-allowed; }

.btn.primary {
    background: linear-gradient(180deg, var(--brand-500), var(--brand-600));
    border-color: var(--brand-600);
    color: #fff;
    box-shadow: 0 2px 8px rgba(18, 89, 168, .26);
}
.btn.primary:hover {
    background: linear-gradient(180deg, var(--brand-400), var(--brand-500));
    border-color: var(--brand-500);
}
.btn.primary:disabled { background: var(--brand-300); border-color: var(--brand-300); box-shadow: none; }

.btn.ghost { background: transparent; border-color: var(--border-strong); color: var(--text-2); }
.btn.ghost:hover { background: var(--brand-050); border-color: var(--brand-300); color: var(--brand-700); }

.btn.danger { border-color: var(--err); color: var(--err); background: var(--panel); }
.btn.danger:hover { background: var(--err-soft); }

.btn.big { padding: 12px 24px; font-size: 15px; }

.actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-top: 16px; }

/* ============================================================
   表单
   ============================================================ */

.field label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: var(--muted);
    letter-spacing: .02em;
    margin-bottom: 5px;
}
.field input[type=text], .field input[type=email], .field input[type=password],
.field select, .account-select, select, input[type=text], input[type=email], input[type=password] {
    font-family: inherit;
    font-size: 14px;
    color: var(--text);
    background: var(--panel);
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-sm);
    padding: 9px 11px;
    transition: border-color .12s, box-shadow .12s;
}
input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--brand-400);
    box-shadow: 0 0 0 3px var(--brand-100);
}
.checkbox { display: inline-flex; align-items: center; gap: 7px; font-size: 14px; }

/* ============================================================
   提示条 / 徽标
   ============================================================ */

.notice {
    border-radius: var(--radius-sm);
    padding: 12px 15px;
    margin-bottom: 16px;
    font-size: 14px;
    border: 1px solid transparent;
    border-left-width: 3px;
}
.notice.ok { background: var(--ok-soft); color: var(--ok); border-left-color: var(--ok); }
.notice.warn { background: var(--warn-soft); color: var(--warn); border-left-color: var(--warn); }
.notice.err { background: var(--err-soft); color: var(--err); border-left-color: var(--err); }
.notice.info { background: var(--brand-050); color: var(--brand-700); border-left-color: var(--brand-500); }

.badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 999px;
    padding: 3px 10px;
    background: var(--brand-100);
    color: var(--brand-700);
    white-space: nowrap;
}
.badge.ok { background: var(--ok-soft); color: var(--ok); }
.badge.warn { background: var(--warn-soft); color: var(--warn); }
.badge.err { background: var(--err-soft); color: var(--err); }

/* ============================================================
   表格
   ============================================================ */

.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { padding: 10px 11px; text-align: left; border-bottom: 1px solid var(--border); }
th {
    color: var(--muted);
    font-weight: 600;
    font-size: 12px;
    letter-spacing: .03em;
    text-transform: uppercase;
    background: var(--panel-2);
    white-space: nowrap;
}
tbody tr:hover { background: var(--brand-050); }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }

/* ============================================================
   确认分组 / 任务详情 等既有组件
   ============================================================ */

.group {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 14px;
    overflow: hidden;
    background: var(--panel);
    box-shadow: var(--shadow-sm);
}
.group-head {
    background: var(--panel-2);
    border-bottom: 1px solid var(--border);
    padding: 13px 16px;
}
.group-body { padding: 16px; }
.row1 { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.sub-row { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 5px; }
.meta { color: var(--muted); font-size: 12.5px; }
.desc { font-weight: 600; }
.grow { flex: 1; }
.bar { height: 7px; border-radius: 999px; background: var(--border); overflow: hidden; }
.bar > span { display: block; height: 100%; background: linear-gradient(90deg, var(--brand-500), var(--brand-400)); }
.centered { text-align: center; }
.empty { color: var(--muted); text-align: center; padding: 30px 0; }
.failed { color: var(--err); }
.doc { max-width: 74ch; }
.doc h2 { margin-top: 26px; }
.doc li { margin-bottom: 5px; }

/* ============================================================
   内部管理后台 —— 侧边栏布局
   ============================================================

   与客户 Portal 完全不同的外壳。之前 banner 直接贴浏览器左边、
   而 header 与主体在固定宽度容器里，三者不在同一条对齐线上；
   现在整体改成 sidebar + content 网格，所有内容共用同一套边界。
   ============================================================ */

body.admin { background: var(--bg); }

.adm-shell {
    display: grid;
    grid-template-columns: 232px minmax(0, 1fr);
    min-height: 100vh;
}

/* ---- 侧边栏 ---- */
.adm-side {
    background: linear-gradient(180deg, var(--brand-950) 0%, var(--brand-900) 100%);
    color: #c8d8ef;
    display: flex;
    flex-direction: column;
    padding: 18px 14px;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}

.adm-brand {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 4px 8px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, .10);
    margin-bottom: 14px;
}
.adm-brand .mark {
    width: 32px; height: 32px;
    border-radius: 9px;
    background: linear-gradient(135deg, var(--brand-500), var(--brand-400));
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-weight: 700; font-size: 15px;
    box-shadow: 0 3px 10px rgba(31, 111, 235, .35);
    flex: none;
}
.adm-brand .name { color: #fff; font-weight: 700; font-size: 15px; line-height: 1.25; }
.adm-brand .kind {
    display: block;
    font-size: 10.5px;
    font-weight: 600;
    letter-spacing: .09em;
    text-transform: uppercase;
    color: #ff9d9d;
}

.adm-nav { display: flex; flex-direction: column; gap: 2px; flex: 1; }
.adm-nav a {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #b7c8e2;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    padding: 9px 12px;
    border-radius: var(--radius-sm);
    transition: background .12s, color .12s;
}
.adm-nav a .dot {
    width: 5px; height: 5px; border-radius: 50%;
    background: currentColor; opacity: .45; flex: none;
}
.adm-nav a:hover { background: rgba(255, 255, 255, .07); color: #fff; text-decoration: none; }
.adm-nav a.on { background: var(--brand-600); color: #fff; font-weight: 650; }
.adm-nav a.on .dot { opacity: 1; background: #7ee3b0; }

.adm-side-foot {
    border-top: 1px solid rgba(255, 255, 255, .10);
    padding-top: 12px;
    margin-top: 12px;
    color: #8ba3c4;
    font-size: 11.5px;
    line-height: 1.55;
}

/* ---- 右侧内容 ---- */
.adm-main { display: flex; flex-direction: column; min-width: 0; }

.adm-topbar {
    background: var(--panel);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 15;
}
.adm-topbar-in {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
    padding: 12px 28px;
    min-height: 60px;
}
.adm-title { font-size: 16px; font-weight: 650; letter-spacing: -.01em; flex: 1; min-width: 0; }

/* 「全平台」状态条做成 pill，不再是贴左边的裸文本 */
.adm-scope {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 11.5px;
    font-weight: 650;
    letter-spacing: .05em;
    text-transform: uppercase;
    color: #a4232a;
    background: #fdecec;
    border: 1px solid #f6c9c9;
    border-radius: 999px;
    padding: 4px 12px;
    white-space: nowrap;
}
.adm-scope::before {
    content: "";
    width: 6px; height: 6px; border-radius: 50%;
    background: #d9414a;
    box-shadow: 0 0 0 3px rgba(217, 65, 74, .16);
}

.adm-who { display: flex; align-items: center; gap: 10px; white-space: nowrap; }
.adm-who .name { font-size: 13.5px; font-weight: 600; }
.adm-who .role {
    font-size: 11.5px;
    font-weight: 600;
    color: var(--brand-700);
    background: var(--brand-100);
    border-radius: 999px;
    padding: 3px 9px;
}

.adm-body { padding: 24px 28px 56px; }
.adm-body > h1 { font-size: 22px; }

.adm-foot {
    margin-top: auto;
    border-top: 1px solid var(--border);
    padding: 14px 28px 26px;
    color: var(--muted);
    font-size: 12.5px;
}

/* 后台表格：跨账套列多，字号收一号 */
.admin-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.admin-table th, .admin-table td {
    border-bottom: 1px solid var(--border);
    padding: 8px 10px;
    text-align: left;
    white-space: nowrap;
}
.admin-table th {
    color: var(--muted);
    font-weight: 600;
    font-size: 11.5px;
    letter-spacing: .03em;
    text-transform: uppercase;
    background: var(--panel-2);
}
.admin-table tbody tr:hover { background: var(--brand-050); }
.admin-table td.num, .admin-table th.num { text-align: right; font-variant-numeric: tabular-nums; }

/* 内部登录页 */
.adm-login {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 20px;
    background:
        radial-gradient(900px 420px at 50% -12%, rgba(31, 111, 235, .30), transparent 62%),
        linear-gradient(160deg, var(--brand-950), var(--brand-800));
}
.adm-login-card {
    width: 100%;
    max-width: 400px;
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px;
    box-shadow: var(--shadow-lg);
}

/* ============================================================
   响应式
   ============================================================ */

@media (max-width: 900px) {
    .adm-shell { grid-template-columns: minmax(0, 1fr); }
    .adm-side {
        position: static;
        height: auto;
        flex-direction: column;
        padding: 14px 18px;
    }
    .adm-brand { border-bottom: none; margin-bottom: 10px; padding-bottom: 10px; }
    .adm-nav { flex-direction: row; flex-wrap: wrap; gap: 4px; }
    .adm-nav a { padding: 7px 11px; }
    .adm-side-foot { display: none; }
    .adm-topbar-in, .adm-body, .adm-foot { padding-left: 18px; padding-right: 18px; }
}

@media (max-width: 720px) {
    body { font-size: 14.5px; }
    .wrap { padding: 0 16px; }
    .site-bar { padding: 8px 16px; gap: 10px; }
    .portal-nav { order: 3; width: 100%; }
    .who { order: 2; margin-left: auto; }

    .hero { padding: 26px 20px 24px; border-radius: var(--radius); }
    .hero h1 { font-size: 23px; }
    .hero-points { grid-template-columns: minmax(0, 1fr); }

    .upload-card { padding: 18px; border-radius: var(--radius); }
    .dropzone { padding: 30px 16px; }
    .upload-foot { flex-direction: column; align-items: stretch; }
    .upload-foot .btn { width: 100%; }
    .upload-foot .note { max-width: none; }

    .panel, .card { padding: 16px; }
    h1 { font-size: 21px; }

    .adm-title { flex: 1 0 100%; }
    .adm-who { width: 100%; justify-content: flex-start; flex-wrap: wrap; white-space: normal; }
}

/* ============================================================
   RC-4：统一导航 / 语言切换 / 账号菜单 / 批量补全
   ============================================================ */

.site-bar { justify-content: space-between; }
.site-right { display: flex; align-items: center; gap: 12px; margin-left: auto; }

/* 语言切换器：一组小按钮，当前语言高亮 */
.lang-switch { display: flex; align-items: center; gap: 2px; border: 1px solid var(--border); border-radius: 999px; padding: 2px; background: var(--panel-2); }
.lang-switch button, .lang-switch a, .lang-switch span {
    font: inherit; font-size: 12px; font-weight: 500; line-height: 1;
    padding: 5px 9px; border-radius: 999px; border: 0; background: transparent;
    color: var(--muted); cursor: pointer; text-decoration: none;
}
.lang-switch button:hover, .lang-switch a:hover { color: var(--brand-700); background: var(--brand-050); }
.lang-switch .on { color: var(--brand-700); background: var(--brand-100); font-weight: 650; cursor: default; }
.lang-switch.dark { border-color: rgba(255, 255, 255, .14); background: rgba(255, 255, 255, .06); }
.lang-switch.dark button, .lang-switch.dark span { color: #b7c8e2; }
.lang-switch.dark button:hover { color: #fff; background: rgba(255, 255, 255, .10); }
.lang-switch.dark .on { color: #fff; background: var(--brand-600); }
.adm-side-lang { padding: 10px 4px; }

/* 账号菜单：<details> 下拉，无需 JS */
.account-menu { position: relative; }
.account-menu summary {
    list-style: none; display: flex; align-items: center; gap: 8px; cursor: pointer;
    padding: 4px 8px 4px 4px; border-radius: 999px; border: 1px solid var(--border); background: var(--panel);
    font-size: 13px; color: var(--text-2); white-space: nowrap;
}
.account-menu summary::-webkit-details-marker { display: none; }
.account-menu summary:hover { border-color: var(--brand-300); }
.account-menu .avatar {
    width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, var(--brand-500), var(--brand-400)); color: #fff; font-weight: 700; font-size: 12px;
}
.account-panel {
    position: absolute; right: 0; top: calc(100% + 8px); min-width: 260px; z-index: 30;
    background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-lg);
    padding: 8px;
}
.account-meta { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; padding: 8px 10px 12px; border-bottom: 1px solid var(--border); margin-bottom: 6px; font-size: 13px; }
.account-meta .k { color: var(--muted); }
.account-meta .v { color: var(--text); font-weight: 500; word-break: break-all; }
.account-link {
    display: block; width: 100%; text-align: left; font: inherit; font-size: 14px;
    padding: 8px 10px; border-radius: var(--radius-sm); border: 0; background: transparent; color: var(--text-2);
    cursor: pointer; text-decoration: none;
}
.account-link:hover { background: var(--brand-050); color: var(--brand-700); text-decoration: none; }
.account-link.danger:hover { background: var(--err-soft); color: var(--err); }

.site-foot { margin-top: 40px; padding: 18px 0 28px; color: var(--muted); font-size: 12.5px; }
.site-foot .wrap { display: flex; gap: 8px; align-items: center; }
.site-foot a { color: inherit; }

/* 页头：标题 + 右侧动作 */
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.page-head .btn { margin-top: 6px; }

/* 独立整页（登录/注册） */
.auth-wrap { max-width: 420px; }
.auth-top { text-align: center; margin: 48px 0 24px; }
.auth-brand { font-size: 26px; font-weight: 700; }
.auth-brand .muted { font-weight: 400; font-size: 17px; }
.auth-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 18px; }

/* 补全科目：勾选 + 批量操作条 */
.group-head .pick { display: inline-flex; align-items: center; margin-right: 2px; }
.group-head .pick input { width: 16px; height: 16px; accent-color: var(--brand-500); cursor: pointer; }
.bulk-bar {
    position: sticky; top: 66px; z-index: 15; margin: 0 0 14px;
    background: var(--brand-900); color: #fff; border-radius: var(--radius); box-shadow: var(--shadow-lg);
}
.bulk-bar-in { display: flex; align-items: center; gap: 10px; padding: 10px 14px; flex-wrap: wrap; }
.bulk-bar .bulk-count { font-weight: 650; white-space: nowrap; }
.bulk-bar select, .bulk-bar input[type=text] { flex: 1 1 220px; min-width: 160px; }
.bulk-bar .btn.ghost { color: #dbe7fb; border-color: rgba(255, 255, 255, .35); }
.bulk-bar .btn.ghost:hover { background: rgba(255, 255, 255, .12); color: #fff; }

@media (max-width: 720px) {
    .site-right { width: 100%; justify-content: space-between; order: 2; }
    .portal-nav { order: 3; }
    .account-panel { right: auto; left: 0; }
    .bulk-bar { top: 0; }
}

/* RC-4 验收修正：窄屏不横向溢出；后台侧栏切换器不换行 */
html, body { max-width: 100%; overflow-x: hidden; }
.wrap, .panel, .group { min-width: 0; }
.group-head .row1 { flex-wrap: wrap; row-gap: 6px; }
.group-head .desc, .group-head .meta { min-width: 0; overflow-wrap: anywhere; }
.site-right { flex-wrap: wrap; }
.adm-side-lang .lang-switch { flex-wrap: nowrap; }
.adm-side-lang .lang-switch button, .adm-side-lang .lang-switch span { white-space: nowrap; padding: 5px 7px; font-size: 11.5px; }

/* .wrap 是 width:100% + padding，没有 border-box 会比视口宽 48px（RC-3.2 遗留） */
.wrap, .site-bar, .panel, .card, .stat, .group-body, .upload-card, .info-card { box-sizing: border-box; }
