/* ==========================================================================
   小计算 · 全局样式
   设计基调：HeroUI 气质（大圆角、轻阴影、柔和控件）+ 暖双色品牌（墨 + 橙粉）
   ========================================================================== */

:root {
    --ink: #11181c;
    --ink-2: #3f3f46;
    --muted: #71717a;
    --orange: #f7971e;
    --pink: #e8368b;
    --accent: #e8357f;
    --accent-deep: #c81e66;
    --grad: linear-gradient(135deg, #f7971e 0%, #e8368b 100%);
    --gold: var(--orange);
    --bg: #fafafa;
    --header-h: 67px;
    /* 顶栏固定高度：sticky-head 吸顶偏移与此绑定，防缝隙漏内容 */
    --card: #ffffff;
    --line: rgba(0, 0, 0, .06);
    --radius: 18px;
    --radius-sm: 12px;
    /* 白底抬升：无重边框，靠阴影浮起 */
    --shadow: 0 1px 3px rgba(0, 0, 0, .04), 0 8px 24px -6px rgba(0, 0, 0, .1);
    --shadow-hover: 0 2px 6px rgba(0, 0, 0, .05), 0 16px 32px -8px rgba(0, 0, 0, .14);
    --focus-ring: 0 0 0 3px rgba(232, 53, 127, .22);
}

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

/* ---- Lucide 图标 ---- */
.icon {
    display: inline-block;
    width: 1em;
    height: 1em;
    vertical-align: -0.15em;
    flex-shrink: 0;
    stroke-width: 2;
}

.icon-filled {
    fill: currentColor;
}

.icon-sm {
    width: 14px;
    height: 14px;
}

.icon-md {
    width: 16px;
    height: 16px;
}

.icon-lg {
    width: 18px;
    height: 18px;
}

.btn .icon,
.btn-ghost .icon,
.ghost-btn .icon,
.tool-actions .btn .icon,
.fav-toggle .icon,
.empty-cta-btn .icon,
.btn svg.lucide,
.btn-ghost svg.lucide,
.ghost-btn svg.lucide {
    margin: 0;
    flex-shrink: 0;
    display: block;
    line-height: 0;
}

.empty-cta-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.tool-stats {
    display: inline-flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 14px;
}

.tool-stats .stat {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
}

.tool-stats .stat .icon {
    width: 13px;
    height: 13px;
    opacity: .85;
}

.user-dropdown a .icon,
.user-dropdown button .icon {
    width: 14px;
    height: 14px;
    margin-right: 8px;
    opacity: .85;
}

.fold-toggle .icon.chev,
.fold-toggle .chev.icon {
    width: 14px;
    height: 14px;
    transition: transform .3s ease;
}

.fold.open>.fold-toggle .icon.chev,
.fold.open>.fold-toggle .chev.icon {
    transform: rotate(180deg);
}

html {
    -webkit-text-size-adjust: 100%;
    overflow-x: clip;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
        "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    background: var(--bg);
    color: var(--ink);
    line-height: 1.65;
    font-size: 14.5px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    -webkit-font-smoothing: antialiased;
    overflow-x: clip;
}

.wrap {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
    width: 100%;
}

@media (min-width: 1500px) {
    .wrap {
        max-width: 1340px;
    }
}

@media (min-width: 1900px) {
    .wrap {
        max-width: 1580px;
    }
}

main.wrap {
    flex: 1;
    padding-top: 28px;
    padding-bottom: 96px;
}

a {
    color: var(--accent);
    text-decoration: none;
}

a:hover {
    color: var(--accent-deep);
}

.muted {
    color: var(--muted);
    font-size: 13px;
}

.mono {
    font-family: ui-monospace, Consolas, "Courier New", monospace;
    font-size: 13px;
}

/* ---- 顶栏：白底 + 轻边 ---- */
.site-header {
    background: #fff;
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    z-index: 50;
    height: var(--header-h);
    box-sizing: border-box;
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 0 24px;
    height: 100%;
    flex-wrap: nowrap;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.brand:hover {
    text-decoration: none;
}

.brand-logo {
    width: 44px;
    height: 44px;
    display: block;
    border-radius: 14px;
    box-shadow: 0 4px 14px -4px rgba(232, 54, 139, .4);
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.25;
}

.brand-name {
    font-size: 20px;
    font-weight: 800;
    letter-spacing: .14em;
    white-space: nowrap;
    background: linear-gradient(120deg, #f7971e 10%, #e8368b 90%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.brand-tag {
    font-size: 11px;
    color: var(--muted);
    letter-spacing: .18em;
    margin-top: 2px;
    white-space: nowrap;
}

.site-nav {
    display: flex;
    gap: 4px;
    margin-left: auto;
    flex-wrap: nowrap;
}

.site-nav a {
    color: var(--ink-2);
    padding: 8px 14px;
    border-radius: 999px;
    font-size: 14px;
    transition: background .2s ease, color .2s ease;
    white-space: nowrap;
}

.site-nav a:hover {
    background: rgba(244, 244, 245, .95);
    text-decoration: none;
    color: var(--ink);
}

.site-nav a.active {
    color: var(--accent-deep);
    font-weight: 600;
    background: rgba(253, 242, 247, .9);
}

.user-area {
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    flex-shrink: 0;
}

.user-area .hello {
    font-size: 13px;
    color: var(--ink-2);
}

.user-link {
    white-space: nowrap;
    font-size: 13.5px;
}

.badge-admin {
    background: #f4e8cf;
    color: #7a5b16;
    font-size: 11px;
    border-radius: 5px;
    padding: 1px 7px;
    margin-left: 7px;
    font-style: normal;
}

.logout-form {
    display: inline;
}

/* 汉堡：大屏隐藏，仅 ≤720 显示 */
.nav-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    margin-left: auto;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    color: var(--ink-2);
    cursor: pointer;
    flex-shrink: 0;
    font-family: inherit;
}

.nav-toggle:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.nav-toggle .icon,
.nav-toggle svg {
    width: 22px;
    height: 22px;
    display: block;
}

.nav-mask {
    /* 须低于 .site-header(50)：nav 在 header 内，否则遮罩会挡住抽屉链接 */
    display: none;
    position: fixed;
    inset: 0;
    top: var(--header-h);
    z-index: 40;
    background: rgba(22, 27, 36, .35);
}

.nav-mask[hidden] {
    display: none !important;
}

@media (max-width: 1180px) {
    .brand-tag {
        display: none;
    }

    .site-nav a {
        padding: 6px 9px;
        font-size: 13.5px;
    }

    .header-inner {
        gap: 12px;
        padding: 0 16px;
    }
}

@media (max-width: 860px) {
    .brand-text {
        display: none;
    }

    .site-nav a {
        padding: 6px 7px;
    }
}

/* ---- 首页 hero：极简 ---- */
.hero-compact {
    text-align: center;
    padding: 46px 20px 4px;
}

.hero-compact .hero-search {
    margin-bottom: 22px;
}

.hero-meta {
    font-size: 12px;
    letter-spacing: .06em;
    margin: 18px 0 0;
    color: var(--muted);
}

.hero {
    text-align: center;
    padding: 72px 20px 40px;
}

/* ---- 首页统一搜索区：搜索框 + 筛选项同一表单，整体吸顶 ---- */
.home-searchbox {
    max-width: 720px;
    margin: 0 auto;
    width: 100%;
    min-width: 0;
}

@media (min-width: 1500px) {
    .home-searchbox {
        max-width: 840px;
    }
}

.home-searchbox .hero-search {
    margin-bottom: 4px;
    max-width: 100%;
    width: 100%;
}

.home-searchbox .hero-search input {
    min-width: 0;
}

.home-searchbox .hero-filter {
    margin-bottom: 0;
    padding: 10px 14px;
    gap: 8px;
    box-shadow: none;
    border-style: dashed;
    flex-wrap: nowrap;
}

.hero-filter .total-hint {
    margin-left: auto;
    white-space: nowrap;
    font-size: 12px;
    flex-shrink: 0;
}

.nl-hint {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    font-size: 12.5px;
    color: var(--muted);
    margin: 2px 0 12px;
}

.hero-filter select {
    padding: 6px 8px;
    font-size: 12.5px;
}

.hero-filter button {
    padding: 6px 14px;
    font-size: 13px;
}

@media (max-width: 720px) {
    .home-searchbox .hero-filter {
        flex-wrap: wrap;
    }

    .hero-filter .total-hint {
        margin-left: 0;
        width: 100%;
    }
}

.hero-chips-wrap {
    padding: 18px 0 4px;
}

.hero h1 {
    font-size: 40px;
    font-weight: 700;
    letter-spacing: .18em;
    text-indent: .18em;
    color: var(--ink);
    margin-bottom: 10px;
}

.hero-sub {
    color: var(--muted);
    font-size: 14px;
    letter-spacing: .04em;
    margin-bottom: 36px;
}

.hero-search {
    display: flex;
    max-width: 620px;
    margin: 0 auto;
    gap: 12px;
}

.hero-search input {
    flex: 1;
    padding: 13px 20px;
    border: 1px solid rgba(0, 0, 0, .06);
    border-radius: 999px;
    font-size: 14px;
    background: #fff;
    box-shadow: var(--shadow);
    height: 46px;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.hero-search input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: var(--focus-ring), var(--shadow);
}

.hero-search button {
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: 999px;
    padding: 12px 28px;
    font-size: 14.5px;
    cursor: pointer;
    letter-spacing: .06em;
    box-shadow: 0 4px 14px -4px rgba(232, 54, 139, .45);
    transition: background .2s ease, box-shadow .2s ease;
}

.hero-search button:hover {
    background: var(--accent-deep);
    box-shadow: 0 6px 18px -4px rgba(232, 54, 139, .5);
}

.hero-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    justify-content: center;
    margin-top: 26px;
}

.home-stats {
    display: flex;
    gap: 40px;
    justify-content: center;
    color: var(--muted);
    font-size: 13px;
    letter-spacing: .04em;
    padding: 34px 0 8px;
    border-top: 1px solid var(--line);
    margin-top: 40px;
}

.home-stats strong {
    color: var(--ink);
    font-size: 17px;
    font-weight: 650;
    margin: 0 2px;
}

/* ---- 区块 ---- */
.section-head {
    display: flex;
    align-items: baseline;
    gap: 12px;
    margin: 48px 0 20px;
}

.section-head .head-action {
    margin-left: auto;
    align-self: center;
}

.section-head h2 {
    font-size: 17.5px;
    font-weight: 650;
    letter-spacing: .02em;
}

.more-link {
    margin-left: auto;
    font-size: 13px;
}

.page-title {
    font-size: 23px;
    font-weight: 700;
    letter-spacing: .02em;
    margin-bottom: 18px;
}

/* 页头：标题与描述紧挨，与下方筛选/列表拉开 */
.page-head {
    margin: 4px 0 40px;
}

.page-head .page-title {
    margin: 0 0 8px;
    font-size: 26px;
    letter-spacing: .03em;
}

.page-head .page-desc {
    margin: 0;
    font-size: 14px;
    line-height: 1.75;
    max-width: 52em;
}

/* ---- 标签：描边（安静、不抢按钮） ---- */
.chip {
    display: inline-block;
    background: transparent;
    color: #71717a;
    border: 1px solid rgba(0, 0, 0, .12);
    border-radius: 999px;
    padding: 1px 9px;
    font-size: 12px;
    white-space: nowrap;
    letter-spacing: .02em;
    font-weight: 500;
    line-height: 1.6;
}

/* 科目：粉描边 */
.chip-fee {
    color: #e8357f;
    border-color: rgba(232, 53, 127, .35);
    background: transparent;
}

/* 领域：琥珀描边 */
.chip-ind {
    color: #b45309;
    border-color: rgba(180, 83, 9, .3);
    background: transparent;
}

.chip-link:hover {
    text-decoration: none;
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

/* 状态 */
.chip-现行 {
    color: #059669;
    border-color: rgba(5, 150, 105, .35);
    background: transparent;
}

.chip-试行 {
    color: #b45309;
    border-color: rgba(180, 83, 9, .3);
    background: transparent;
}

.chip-征求意见稿,
.chip-报批稿 {
    color: #71717a;
    border-color: rgba(0, 0, 0, .12);
    background: transparent;
}

.chip-废止 {
    color: #dc2626;
    border-color: rgba(220, 38, 38, .35);
    background: transparent;
}

/* ---- 卡片 ---- */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 18px;
}

.card {
    background: var(--card);
    border: 1px solid rgba(0, 0, 0, .05);
    border-radius: var(--radius);
    padding: 20px;
    box-shadow: var(--shadow);
    color: var(--ink);
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}

.card:hover {
    text-decoration: none;
    border-color: rgba(0, 0, 0, .08);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.card h3 {
    font-size: 15px;
    font-weight: 650;
    line-height: 1.5;
}

.card-summary {
    color: var(--muted);
    font-size: 13px;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-top {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.card-meta {
    display: flex;
    gap: 16px;
    font-size: 12px;
    color: var(--muted);
    border-top: 1px solid var(--line);
    padding-top: 10px;
}

/* ---- 筛选栏 ---- */
.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    background: var(--card);
    border: 1px solid rgba(0, 0, 0, .05);
    border-radius: var(--radius);
    padding: 14px 18px;
    margin-bottom: 20px;
    box-shadow: var(--shadow);
}

.filter-bar input,
.filter-bar select {
    padding: 9px 14px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    font-size: 13.5px;
    background: #fafafa;
    color: var(--ink);
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}

.filter-bar input:focus,
.filter-bar select:focus {
    outline: none;
    border-color: var(--accent);
    background: #fff;
    box-shadow: var(--focus-ring);
}

.filter-bar button {
    white-space: nowrap;
    flex-shrink: 0;
}

.filter-bar .btn,
.filter-bar .btn-ghost {
    padding: 8px 18px;
    font-size: 13.5px;
    border-radius: var(--radius-sm);
}

.total-hint {
    margin-left: auto;
}

/* ---- 按钮 ---- */
.btn,
.filter-bar button,
.hero-search button {
    font-family: inherit;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    padding: 10px 22px;
    font-size: 14px;
    cursor: pointer;
    font-weight: 600;
    letter-spacing: .02em;
    box-shadow: 0 2px 10px -3px rgba(232, 54, 139, .35);
    transition: background .2s ease, box-shadow .2s ease, transform .15s ease;
    white-space: nowrap;
    flex-shrink: 0;
}

.btn:hover {
    background: var(--accent-deep);
    color: #fff;
    text-decoration: none;
    box-shadow: 0 4px 14px -3px rgba(232, 54, 139, .45);
}

.btn:active {
    transform: scale(.98);
}

.btn-ghost {
    background: #fff;
    color: var(--accent);
    border: 1px solid var(--line);
    box-shadow: none;
    font-weight: 550;
}

.btn-ghost:hover {
    background: #fafafa;
    color: var(--accent-deep);
    filter: none;
    box-shadow: none;
}

.btn-sm {
    padding: 6px 14px;
    font-size: 13px;
    border-radius: 10px;
}

.btn-mini {
    padding: 5px 12px;
    font-size: 12.5px;
    border-radius: 9px;
}

/* ---- 工具库：行式列表 + 快速运行 ---- */
.tool-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.tool-row {
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--card);
    border: 1px solid rgba(0, 0, 0, .05);
    border-radius: var(--radius);
    padding: 16px 20px;
    box-shadow: var(--shadow);
    transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

/* 刚创建的工具行：一次性柔和高亮，引导用户定位 */
.row-flash {
    animation: rowFlash 2s ease-out;
}

@keyframes rowFlash {
    0% {
        background: #fdf2f7;
        border-color: #e8368b;
        box-shadow: 0 0 0 3px rgba(232, 54, 139, .12);
    }

    100% {
        background: var(--card);
        border-color: var(--line);
        box-shadow: var(--shadow);
    }
}

.tool-row:hover {
    border-color: rgba(228, 228, 231, .95);
    box-shadow: var(--shadow-hover);
    transform: translateY(-1px);
}

.tool-main {
    flex: 1;
    min-width: 0;
    color: var(--ink);
}

.tool-main:hover {
    text-decoration: none;
    color: var(--ink);
}

.tool-head {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 4px;
}

.tool-head h3 {
    font-size: 15.5px;
    font-weight: 650;
    margin-right: 4px;
}

.tool-summary {
    color: var(--muted);
    font-size: 12.5px;
    margin-bottom: 6px;
}

.tool-meta {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
    font-size: 12px;
}

.tool-stats {
    color: var(--ink-2);
}

.tool-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

/* ---- 表格（HeroUI 气质：白卡、柔和表头、宽松行距、轻分割） ---- */
.table-wrap {
    background: var(--card);
    border: 1px solid rgba(0, 0, 0, .05);
    border-radius: var(--radius);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    box-shadow: var(--shadow);
}

.std-table {
    width: 100%;
    border-collapse: collapse;
    border-spacing: 0;
    font-size: 14px;
    font-variant-numeric: tabular-nums;
}

.std-table th,
.std-table td {
    text-align: left;
    padding: 18px 24px;
    border-bottom: 1px solid rgba(0, 0, 0, .05);
    vertical-align: middle;
}

.std-table th {
    background: #fafafa;
    color: var(--muted);
    font-weight: 600;
    font-size: 12px;
    letter-spacing: .04em;
    white-space: nowrap;
    position: relative;
}

.std-table td {
    color: var(--ink);
    line-height: 1.55;
}

.std-table td a {
    font-weight: 550;
}

.au-name {
    font-weight: 600;
    color: var(--ink);
}

.au-mail {
    font-size: 12px;
}

.au-active {
    font-weight: 600;
}

.nowrap {
    white-space: nowrap;
}

.std-table tbody tr:last-child td {
    border-bottom: none;
}

.std-table tbody tr {
    transition: background .15s ease;
}

.std-table tbody tr:hover {
    background: #f4f4f5;
}

.row-废止 td {
    color: var(--muted);
}

.row-废止 td a {
    color: var(--muted);
}

/* 标准库列表：文号 / 层级 / 地区 留足宽度，避免被标题列挤扁 */
.std-lib-table {
    table-layout: fixed;
}

.std-lib-table .col-title {
    width: auto;
}

.std-lib-table .col-docno {
    width: 18%;
}

.std-lib-table .col-level {
    width: 12%;
}

.std-lib-table .col-region {
    width: 7%;
}

.std-lib-table .col-status {
    width: 88px;
}

.std-lib-table th,
.std-lib-table td {
    overflow: hidden;
}

.std-lib-table th {
    text-overflow: clip;
    white-space: nowrap;
}

.std-lib-table td {
    text-overflow: ellipsis;
}

.std-lib-table th:nth-child(2),
.std-lib-table td:nth-child(2),
.std-lib-table th:nth-child(3),
.std-lib-table td:nth-child(3),
.std-lib-table th:nth-child(4),
.std-lib-table td:nth-child(4),
.std-lib-table th:nth-child(5),
.std-lib-table td:nth-child(5) {
    white-space: nowrap;
    padding-left: 16px;
    padding-right: 16px;
}

.std-lib-table td:nth-child(1) {
    white-space: nowrap;
}

.std-lib-table td:nth-child(2) {
    font-size: 13px;
}

/* ---- 详情页：吸顶头部块（标题/统计/依据） ---- */
.detail-sticky {
    position: sticky;
    top: 70px;
    z-index: 40;
    background: var(--bg);
    padding-bottom: 12px;
    box-shadow: 0 12px 14px -14px rgba(22, 27, 36, .3);
}

.detail-title {
    font-size: 21px;
    font-weight: 700;
    letter-spacing: .01em;
    margin: 8px 0 4px;
    line-height: 1.4;
}

.meta-stats {
    display: flex;
    gap: 14px;
    font-size: 12.5px;
    color: var(--muted);
    margin: 2px 0 6px;
    flex-wrap: wrap;
}

.meta-stats span {
    white-space: nowrap;
}

.detail-summary {
    font-size: 13px;
    margin: 0;
}

.detail-head {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.stat-boxes {
    display: flex;
    gap: 12px;
}

.stat-box {
    background: var(--card);
    border: 1px solid rgba(0, 0, 0, .05);
    border-radius: var(--radius-sm);
    padding: 10px 18px;
    text-align: center;
    min-width: 74px;
    box-shadow: var(--shadow);
}

.stat-box strong {
    display: block;
    font-size: 17px;
    color: var(--accent-deep);
    font-weight: 700;
}

.stat-box span {
    font-size: 11.5px;
    color: var(--muted);
}

.standard-binding {
    background: #f2f6fc;
    border: 1px solid #dde7f5;
    border-radius: var(--radius);
    padding: 13px 18px;
    margin-bottom: 16px;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.binding-actions {
    margin-left: auto;
}

.runtime-wrap {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.runtime-frame {
    width: 100%;
    height: 780px;
    border: none;
    display: block;
    background: #fff;
}

.disclaimer {
    background: #fdf8ec;
    border: 1px solid #efe3c2;
    color: #7a5b16;
    border-radius: var(--radius-sm);
    padding: 11px 16px;
    font-size: 13px;
    margin: 16px 0;
}

.version-list {
    margin-top: 8px;
}

.version-list ul {
    list-style: none;
    margin-top: 8px;
}

.version-list li {
    display: flex;
    gap: 16px;
    align-items: baseline;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 11px 16px;
    margin-bottom: 8px;
    font-size: 14px;
}

.std-detail {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 24px 28px 18px;
    box-shadow: var(--shadow);
    margin-bottom: 18px;
}

.std-back {
    margin: -2px 0 14px;
}

.std-detail .std-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-bottom: 13px;
}

.std-detail .std-title {
    font-size: 20px;
    font-weight: 700;
    line-height: 1.5;
    letter-spacing: .01em;
    margin: 0 0 16px;
}

.std-detail .std-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 30px;
    padding: 12px 0 2px;
    border-top: 1px solid var(--line);
    font-size: 13.5px;
    color: var(--ink);
}

.std-detail .std-meta label {
    color: var(--muted);
    margin-right: 10px;
    font-weight: 400;
}

.std-detail .std-note {
    margin: 10px 0 0;
    padding-top: 11px;
    border-top: 1px dashed var(--line);
    font-size: 12.5px;
}

.sec-tight {
    margin: 30px 0 16px;
}

.message-box {
    text-align: center;
    padding: 70px 0;
}

.message-box h1 {
    margin-bottom: 14px;
}

.btn {
    margin-top: 0;
}

.message-box .btn {
    margin-top: 20px;
}

.prose {
    max-width: 760px;
}

.prose h2 {
    margin: 26px 0 10px;
    font-size: 18px;
    font-weight: 650;
}

.prose ul {
    padding-left: 22px;
    margin: 8px 0;
}

.prose li {
    margin-bottom: 7px;
}

.pager {
    display: flex;
    gap: 18px;
    justify-content: center;
    align-items: center;
    margin: 16px 0 6px;
    font-size: 13.5px;
}

.pager-disabled {
    color: #c3c9d2;
    cursor: not-allowed;
}

.empty {
    text-align: center;
    color: var(--muted);
    padding: 48px 0;
}

/* 空列表引导：说明 + 直达创建按钮 */
.empty-cta {
    text-align: center;
    padding: 44px 20px;
    border: 1px dashed var(--line);
    border-radius: var(--radius);
    background: #fbfcfe;
}

.empty-cta p {
    margin: 0 0 16px;
    font-size: 13.5px;
}

/* ---- 快速运行弹窗 ---- */
.qr-modal {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qr-modal[hidden] {
    display: none;
}

.qr-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(22, 27, 36, .45);
    backdrop-filter: blur(3px);
}

/* 提交错误 / 游客登录弹窗 */
.modal-mask {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    max-width: 100vw;
    max-height: 100dvh;
    z-index: 120;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(22, 27, 36, .45);
    backdrop-filter: blur(3px);
    animation: maskIn .16s ease-out;
    box-sizing: border-box;
    padding: 16px;
}

@keyframes maskIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.modal-card {
    width: min(480px, calc(100vw - 40px));
    max-height: min(90dvh, 640px);
    overflow-y: auto;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: 0 18px 50px rgba(22, 27, 36, .18);
    padding: 22px 24px 18px;
    animation: cardIn .2s ease-out;
}

@keyframes cardIn {
    from {
        transform: translateY(10px) scale(.98);
        opacity: 0;
    }

    to {
        transform: none;
        opacity: 1;
    }
}

.modal-card h3 {
    margin: 0 0 12px;
    font-size: 16px;
    font-weight: 700;
    color: var(--ink);
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 16px;
    gap: 8px;
    flex-wrap: wrap;
}

.modal-actions-guest {
    justify-content: space-between;
    align-items: center;
}

.modal-actions-right {
    display: inline-flex;
    gap: 8px;
    flex-wrap: wrap;
}

.modal-mask.hidden {
    display: none !important;
}

.guest-benefits {
    margin: 0 0 4px;
    padding-left: 18px;
    font-size: 13px;
    color: var(--ink-2);
    line-height: 2;
}

/* 游客预览提示条（创建页等） */
.guest-banner {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
    background: #fdf8ec;
    border: 1px solid #efe3c2;
    color: #7a5b16;
    border-radius: var(--radius-sm);
    padding: 10px 16px;
    font-size: 13px;
    margin-bottom: 14px;
}

.guest-banner p {
    margin: 0;
    flex: 1 1 320px;
    line-height: 1.7;
}

.guest-banner span {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

.qr-modal-box {
    position: relative;
    width: min(960px, 94vw);
    height: min(86vh, 860px);
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 30px 80px -20px rgba(22, 27, 36, .45);
    display: flex;
    flex-direction: column;
    animation: qrPop .18s ease-out;
}

@keyframes qrPop {
    from {
        transform: scale(.96) translateY(8px);
        opacity: 0;
    }

    to {
        transform: none;
        opacity: 1;
    }
}

.qr-modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 18px;
    border-bottom: 1px solid var(--line);
    background: #fafbfd;
    flex-shrink: 0;
}

.qr-modal-head strong {
    font-size: 14.5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.qr-modal-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.qr-open-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 15px;
    font-size: 13px;
    border-radius: 9px;
    letter-spacing: .03em;
}

.qr-open-btn svg {
    display: block;
}

.qr-modal-x {
    width: 30px;
    height: 30px;
    border-radius: 8px;
    border: 1px solid var(--line);
    background: #fff;
    color: var(--ink-2);
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .15s, color .15s;
}

.qr-modal-x:hover {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.qr-modal-box iframe {
    flex: 1;
    width: 100%;
    border: none;
    display: block;
    background: #fff;
}

/* ---- 吸顶头部：长列表页固定 标题/筛选/表头 ---- */
.sticky-head {
    position: sticky;
    top: var(--header-h);
    z-index: 40;
    background: rgba(250, 250, 250, .96);
    backdrop-filter: saturate(1.6) blur(16px);
    -webkit-backdrop-filter: saturate(1.6) blur(16px);
    /* 负边距盖住 .wrap gutter；不用 width:calc，避免撑大滚动宽 */
    margin-left: -24px;
    margin-right: -24px;
    padding: 4px 24px 12px;
    min-width: 0;
    box-sizing: border-box;
    overflow-x: clip;
    box-shadow: none;
    border-bottom: none;
}

.sticky-head .filter-bar {
    margin-bottom: 8px;
}

/* 窄屏收起：桌面不出现。文字链，不是按钮 */
.filter-fold-row {
    display: none;
}

.filter-fold {
    display: none;
    border: 0;
    background: none;
    padding: 0;
    margin: 0;
    font: inherit;
    font-size: 13px;
    font-weight: 500;
    color: var(--accent);
    cursor: pointer;
}

.filter-fold:hover {
    color: var(--accent-deep);
    text-decoration: underline;
}

.filter-fold:focus-visible {
    outline: none;
    text-decoration: underline;
}

.sticky-title {
    display: flex;
    align-items: baseline;
    gap: 14px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.sticky-title .page-title {
    margin-bottom: 0;
    font-size: 22px;
}

/* ---- 管理页：网格行列（表头吸顶于 sticky-head 内） ---- */
.admin-grid {
    display: grid;
    grid-template-columns: 28px 52px minmax(0, 2.2fr) minmax(0, 1.6fr) 84px 92px 86px 52px 176px;
    column-gap: 12px;
    align-items: center;
}

.batch-bar {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 8px;
    margin: 0 0 12px;
}

.batch-bar .btn {
    flex-shrink: 0;
}

.batch-all {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    cursor: pointer;
}

.batch-count {
    font-size: 13px;
    color: var(--muted);
    margin-right: 4px;
}

.batch-bar button:disabled {
    opacity: .45;
    cursor: not-allowed;
}

.admin-check {
    display: flex;
    align-items: center;
}

.admin-check input {
    width: 16px;
    height: 16px;
    accent-color: var(--accent);
}

.admin-colhead {
    padding: 6px 14px 2px;
    font-size: 12px;
    color: var(--muted);
    font-weight: 600;
}

.admin-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 12px;
}

.admin-row {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 12px 14px;
    box-shadow: var(--shadow);
}

.admin-row .admin-tool strong {
    font-size: 14px;
}

.admin-row .tool-actions {
    flex-wrap: wrap;
    gap: 6px;
}

@media (max-width: 900px) {
    .admin-colhead {
        display: none;
    }

    .admin-grid {
        display: block;
    }

    .admin-row>span {
        display: inline-block;
        margin: 2px 10px 2px 0;
        vertical-align: top;
    }

    .admin-row .admin-tool {
        display: block;
        margin-bottom: 4px;
    }
}

/* ---- 运营统计：KPI 卡 / SVG 趋势图 / 排行榜 / 科目分布 ---- */
.kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 14px;
    margin: 6px 0 8px;
}

.kpi {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 16px 14px 12px;
    text-align: center;
    box-shadow: var(--shadow);
}

.kpi em {
    font-style: normal;
    font-size: 20px;
    display: block;
    margin-bottom: 4px;
}

.kpi strong {
    display: block;
    font-size: 24px;
    font-weight: 750;
    color: var(--ink);
}

.kpi span {
    font-size: 12px;
    color: var(--muted);
}

.chart-card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 18px 18px 10px;
    box-shadow: var(--shadow);
}

.trend-chart {
    width: 100%;
    height: auto;
    display: block;
}

.chart-grid {
    stroke: #eef0f4;
    stroke-width: 1;
}

.chart-tick {
    font-size: 10px;
    fill: #a0a8b4;
}

.chart-note {
    font-size: 12px;
    padding: 6px 4px 8px;
}

.chart-legend {
    margin-left: auto;
    font-size: 12px;
    color: var(--ink-2);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    display: inline-block;
    margin-left: 8px;
}

.dot-pink {
    background: #e8368b;
}

.dot-orange {
    background: #f7971e;
}

.chart-empty {
    padding: 60px 0;
    text-align: center;
    color: var(--muted);
    font-size: 14px;
}

.rank-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.rank-row {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 10px 14px;
    box-shadow: var(--shadow);
    color: var(--ink);
}

a.rank-row:hover {
    text-decoration: none;
    border-color: #f2b8d2;
}

.rank-no {
    width: 26px;
    height: 26px;
    border-radius: 8px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    color: var(--muted);
    background: #f0f2f6;
}

.rank-no.r1 {
    background: var(--accent);
    color: #fff;
}

.rank-no.r2 {
    background: #f2b8d2;
    color: #8f1d56;
}

.rank-no.r3 {
    background: #f6dfc2;
    color: #8a5a10;
}

.rank-main {
    flex: 1;
    min-width: 0;
}

.rank-title {
    display: block;
    font-size: 13.5px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.rank-sub {
    display: block;
    font-size: 11.5px;
    margin: 1px 0 5px;
}

.rank-bar {
    display: block;
    height: 5px;
    border-radius: 4px;
    background: #f0f2f6;
    overflow: hidden;
}

.rank-bar i {
    display: block;
    height: 100%;
    border-radius: 4px;
    background: linear-gradient(90deg, #f7971e, #e8368b);
}

.rank-bar i.alt {
    background: linear-gradient(90deg, #e8b25a, #f7971e);
}

.rank-num {
    font-size: 17px;
    font-weight: 750;
    color: var(--accent);
    text-align: right;
    min-width: 44px;
}

.rank-num small {
    display: block;
    font-size: 10px;
    color: var(--muted);
    font-weight: 400;
}

.cat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 12px;
}

.cat-card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 14px 16px;
    box-shadow: var(--shadow);
}

.cat-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 10px;
}

.cat-head strong {
    font-size: 14.5px;
}

.cat-head span {
    font-size: 11.5px;
}

.cat-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 6px;
}

.cat-label {
    font-size: 11px;
    color: var(--muted);
    width: 26px;
    flex-shrink: 0;
}

.cat-track {
    flex: 1;
    height: 8px;
    border-radius: 5px;
    background: #f0f2f6;
    overflow: hidden;
}

.cat-track i {
    display: block;
    height: 100%;
    border-radius: 5px;
    background: linear-gradient(90deg, #f7971e, #e8368b);
    min-width: 0;
}

.cat-track i.alt {
    background: linear-gradient(90deg, #e8b25a, #f7971e);
}

.cat-val {
    font-size: 11px;
    color: var(--ink-2);
    width: 40px;
    text-align: right;
    flex-shrink: 0;
}


.form-sec {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 22px 26px;
    margin-bottom: 16px;
    box-shadow: var(--shadow);
}

.sec-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 18px;
}

.sec-no {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fdeef5;
    color: var(--accent-deep);
    font-weight: 700;
    font-size: 13px;
}

.sec-head h2 {
    font-size: 16.5px;
    font-weight: 700;
}

.sec-head p {
    font-size: 12px;
    margin-top: 1px;
}

.submit-form label {
    display: block;
    font-weight: 600;
    font-size: 13.5px;
    color: var(--ink-2);
}

.submit-form label .muted {
    font-weight: 400;
    font-size: 12px;
    margin-left: 4px;
}

/* ---- 创建页：制作指引 ---- */
.howto {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    margin-bottom: 20px;
}

.howto summary {
    display: flex;
    align-items: baseline;
    gap: 10px;
    padding: 13px 18px;
    cursor: pointer;
    list-style: none;
    flex-wrap: wrap;
}

.howto summary::-webkit-details-marker {
    display: none;
}

.howto summary::before {
    content: "";
    display: inline-block;
    width: 14px;
    height: 14px;
    margin-right: 4px;
    vertical-align: -2px;
    background: currentColor;
    color: var(--accent);
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m9 18 6-6-6-6'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m9 18 6-6-6-6'/%3E%3C/svg%3E") center / contain no-repeat;
    transition: transform .15s;
}

.howto[open] summary::before {
    transform: rotate(90deg);
}

.howto-title {
    font-weight: 650;
    font-size: 14.5px;
}

.howto-body {
    padding: 2px 18px 16px;
    border-top: 1px solid var(--line);
}

.howto-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(215px, 1fr));
    gap: 10px;
    margin: 14px 0 4px;
}

.hstep {
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    font-size: 12.5px;
    color: var(--ink-2);
    line-height: 1.65;
}

.hstep b {
    display: block;
    color: var(--ink);
    font-size: 13px;
    margin-bottom: 3px;
}

.hno {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 6px;
    background: #f0f2f6;
    color: var(--ink-2);
    font-size: 11px;
    font-weight: 700;
    font-style: normal;
    margin-right: 6px;
}

.howto-sec {
    margin-top: 14px;
}

.howto-sec h3 {
    font-size: 14px;
    font-weight: 650;
    margin-bottom: 8px;
}

.tool-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-bottom: 6px;
}

.tool-chips span {
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 3px 12px;
    font-size: 12.5px;
    color: var(--ink-2);
    background: #fff;
}

.prompt-box {
    width: 100%;
    min-height: 200px;
    resize: vertical;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    font-size: 12.5px;
    line-height: 1.7;
    font-family: inherit;
    color: var(--ink);
    background: #f8fafd;
    margin-bottom: 8px;
}

.check-list {
    list-style: none;
    font-size: 12.5px;
    color: var(--ink-2);
    line-height: 1.9;
}

.check-list li {
    padding-left: 18px;
    position: relative;
}

.check-list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.2em;
    width: 14px;
    height: 14px;
    background: #177245;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* ---- 工作台：我的上传行内管理 ---- */
.tool-row {
    flex-wrap: wrap;
}

.me-share {
    flex-basis: 100%;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    padding: 8px 12px;
    background: #f8fafd;
    border: 1px dashed var(--line);
    border-radius: var(--radius-sm);
    font-size: 12.5px;
    color: var(--ink-2);
}

.share-tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 2px 6px 2px 10px;
    font-size: 12.5px;
}

.share-x {
    border: none;
    background: none;
    color: var(--muted);
    cursor: pointer;
    font-size: 12px;
    padding: 0 2px;
    line-height: 1;
}

.share-x:hover {
    color: #b3261e;
}

.me-share form.inline {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0 0 0 auto;
}

.me-share .share-add input {
    padding: 4px 10px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    font-size: 12.5px;
    width: 120px;
}

/* ---- 创建页：两步单屏向导 ---- */
.submit-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 18px;
    flex-wrap: wrap;
}

.step-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 18px;
}

.step-dot {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 13px;
    color: var(--muted);
    transition: color .2s;
}

.step-dot i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #eef1f6;
    color: var(--ink-2);
    font-size: 11.5px;
    font-style: normal;
    font-weight: 700;
    transition: all .2s;
}

.step-dot.on {
    color: var(--ink);
    font-weight: 650;
}

.step-dot.on i {
    background: var(--accent);
    color: #fff;
}

.step-line {
    flex: 1;
    max-width: 90px;
    height: 1px;
    background: var(--line);
}

.step {
    animation: none;
}

.step.fade-in {
    animation: stepFade .22s ease-out;
}

@keyframes stepFade {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

.drop-zone .drop-label {
    padding: 44px 16px;
}

.drop-zone .drop-label svg {
    color: #cbd5e1;
    margin-bottom: 8px;
    transition: transform .18s, color .18s;
}

.drop-zone.dragover .drop-label svg {
    transform: translateY(-4px) scale(1.12);
    color: var(--accent);
}

.file-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: -4px 0 14px;
    padding: 7px 12px;
    background: #fdf2f7;
    border: 1px solid #f5c6dd;
    border-radius: 999px;
    font-size: 13px;
    color: var(--ink);
    animation: stepFade .2s ease-out;
}

.file-chip[hidden] {
    display: none;
}

.file-chip svg {
    color: var(--accent);
    flex-shrink: 0;
}

.paste-box {
    margin-bottom: 14px;
}

.paste-box textarea {
    margin-top: 8px;
}

.step-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 14px;
    flex-wrap: wrap;
    padding-top: 6px;
}

.step-actions .muted {
    margin-right: auto;
    font-size: 12.5px;
}

#step2 .step-actions {
    padding-top: 18px;
}

#step2 .step-actions .muted {
    margin-right: 0;
    margin-left: auto;
}

.submit-form input:not([type="radio"]),
.submit-form select,
.submit-form textarea {
    width: 100%;
    margin-top: 6px;
    padding: 10px 14px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-family: inherit;
    color: var(--ink);
    background: #fff;
    transition: border-color .15s, box-shadow .15s;
}

.submit-form input:focus,
.submit-form select:focus,
.submit-form textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 4px rgba(232, 54, 139, .1);
}

.submit-form textarea {
    resize: vertical;
    line-height: 1.6;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}

.form-grid .span-3 {
    grid-column: span 3;
}

@media (max-width: 720px) {
    .form-grid {
        grid-template-columns: 1fr;
    }

    .form-grid .span-3 {
        grid-column: span 1;
    }
}

.vis-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-top: 18px;
}

@media (max-width: 720px) {
    .vis-cards {
        grid-template-columns: 1fr;
    }
}

.vis-card {
    border: 1.5px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 14px 16px;
    cursor: pointer;
    transition: border-color .15s, background .15s;
}

/* 压过 .submit-form label { display:block }，否则标题和说明会挤在同一行 */
.submit-form label.vis-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
}

.vis-card:hover {
    border-color: #f2b8d2;
}

.vis-card input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.vis-card strong {
    display: block;
    font-size: 14.5px;
    letter-spacing: 0;
    line-height: 1.4;
}

.vis-card span {
    display: block;
    font-size: 12px;
    color: var(--muted);
    font-weight: 400;
    line-height: 1.55;
    letter-spacing: 0;
    text-wrap: balance;
}

.vis-card:has(input:checked) {
    border-color: var(--accent);
    background: linear-gradient(135deg, #fff7ef, #fdeef5);
    box-shadow: 0 0 0 3px rgba(232, 54, 139, .1);
}

.vis-card:has(input:checked) strong {
    color: var(--accent-deep);
}

.drop-zone {
    border: 1.5px dashed #d8dde5;
    border-radius: var(--radius-sm);
    background: #fbfcfe;
    transition: border-color .15s, background .15s;
    margin-bottom: 14px;
    position: relative;
}

.drop-zone:hover,
.drop-zone.dragover {
    border-color: var(--accent);
    background: #fdf3f8;
}

.drop-input {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}

.drop-label {
    display: block;
    text-align: center;
    padding: 26px 16px;
    cursor: pointer;
}

.drop-label strong {
    display: block;
    font-size: 14.5px;
    color: var(--accent-deep);
    margin-bottom: 4px;
}

.drop-label span {
    font-size: 12px;
    color: var(--muted);
    font-weight: 400;
}

.submit-bar {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    padding: 4px 2px 10px;
}

.btn-lg {
    padding: 13px 34px;
    font-size: 15.5px;
    border-radius: var(--radius-sm);
    letter-spacing: .06em;
}


/* ---- 生态产品：真实 logo + 品牌色发光标签 ---- */
/* inline-flex 默认 baseline 会相对旁侧文字偏上；middle 与「生态产品 / 小计算」齐平 */
.eco-product {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
    vertical-align: middle;
}

.eco-product img {
    height: 18px;
    width: auto;
    border-radius: 4px;
    display: block;
    border: 1px solid var(--line);
    background: #fff;
    object-fit: contain;
}

.eco-inline-logo {
    height: 20px;
    width: auto;
    border-radius: 4px;
    display: inline-block;
    border: 1px solid var(--line);
    background: #fff;
    object-fit: contain;
    vertical-align: -4px;
    padding: 1px 2px;
}

.chip-product {
    font-weight: 650;
    letter-spacing: .02em;
    transition: transform .15s, box-shadow .15s, background .15s;
}

.chip-product:hover {
    text-decoration: none;
    transform: translateY(-1px);
}

.chip-zj {
    background: transparent;
    color: #2563eb;
    border-color: rgba(37, 99, 235, .35);
}

.chip-zj:hover {
    background: rgba(37, 99, 235, .06);
    color: #1d4ed8;
}

.chip-xj {
    background: transparent;
    color: #e8357f;
    border-color: rgba(232, 53, 127, .35);
}

.chip-xj:hover {
    background: rgba(232, 53, 127, .06);
    color: #c81e66;
}

/* ---- 首页"为你推荐"横排小卡 ---- */
.rec-section {
    margin-top: 6px;
}

.rec-section .section-head {
    margin: 8px 0 12px;
}

.rec-row {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
    gap: 10px;
}

.rec-card {
    display: flex;
    flex-direction: column;
    gap: 6px;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 12px 14px;
    color: var(--ink);
    box-shadow: var(--shadow);
    transition: transform .15s, border-color .15s;
}

.rec-card:hover {
    text-decoration: none;
    transform: translateY(-2px);
    border-color: #f2b8d2;
}

.rec-card strong {
    font-size: 13px;
    font-weight: 600;
    line-height: 1.45;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ---- 工作台 ---- */
.me-hero {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

.me-title {
    font-size: 23px;
    font-weight: 750;
    letter-spacing: .01em;
}

.me-hero p {
    font-size: 13px;
    margin-top: 3px;
}

.me-nums {
    display: flex;
    gap: 22px;
}

.me-nums span {
    font-size: 12px;
    color: var(--muted);
    text-align: center;
}

.me-nums strong {
    display: block;
    font-size: 20px;
    color: var(--ink);
    font-weight: 750;
}

/* ---- 统一折叠组件：就地展开/收起（平滑动效） ---- */
.fold-body {
    display: grid;
    grid-template-rows: 0fr;
    opacity: 0;
    transition: grid-template-rows .3s ease, opacity .24s ease;
}

.fold-body>.fold-inner {
    overflow: hidden;
    min-height: 0;
}

.fold.open>.fold-body {
    grid-template-rows: 1fr;
    opacity: 1;
}

.recent-list .fold-inner,
.rank-list .fold-inner {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.fold-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    width: 100%;
    padding: 9px 0 2px;
    border: 0;
    background: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 13px;
    color: var(--accent-deep);
    user-select: none;
}

.fold-toggle:hover {
    text-decoration: underline;
}

.fold-toggle .chev {
    font-style: normal;
    font-size: 11px;
    line-height: 1;
    transition: transform .3s ease;
}

.fold.open>.fold-toggle .chev {
    transform: rotate(180deg);
}

.fold-toggle .fold-less {
    display: none;
}

.fold.open>.fold-toggle .fold-more {
    display: none;
}

.fold.open>.fold-toggle .fold-less {
    display: inline;
}

/* 触发在上的披露式折叠（历史版本、粘贴代码等） */
.fold-up>.fold-toggle {
    justify-content: flex-start;
    padding: 6px 0;
    font-size: 14px;
    color: var(--ink-2);
}

.fold-up>.fold-toggle:hover {
    color: var(--accent);
}

.paste-box>.fold-toggle {
    font-size: 13px;
    color: var(--muted);
    padding: 6px 0;
}

.paste-box>.fold-toggle:hover {
    color: var(--accent);
}

/* ---- 科目分布：分组横向条形图 ---- */
.cat-chart {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.cat-line {
    display: grid;
    grid-template-columns: 88px 1fr 64px;
    gap: 12px;
    align-items: center;
}

.cat-name {
    font-size: 12.5px;
    font-weight: 600;
    color: var(--ink-2);
    text-align: right;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cat-bars2 {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.cb-track {
    display: block;
    height: 9px;
    border-radius: 5px;
    background: #f0f2f6;
    overflow: hidden;
}

.cb-track i {
    display: block;
    height: 100%;
    border-radius: 5px;
    background: linear-gradient(90deg, #f7971e, #e8368b);
}

.cb-track.alt i {
    background: linear-gradient(90deg, #e8b25a, #f7971e);
}

.cat-vals {
    font-size: 11.5px;
    color: var(--muted);
    white-space: nowrap;
}

.cat-vals b {
    color: var(--ink);
    font-weight: 650;
}

.admin-hint {
    margin-left: auto;
    font-size: 12px;
    cursor: help;
}

/* 操作旁向上弹出的说明（避免吸顶/页顶 title，底部行也能看见） */
.has-tip {
    position: relative;
}

.has-tip::after {
    content: attr(data-tip);
    position: absolute;
    left: 50%;
    bottom: calc(100% + 8px);
    transform: translateX(-50%) translateY(4px);
    background: rgba(22, 27, 36, .94);
    color: #fff;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.55;
    padding: 8px 11px;
    border-radius: 8px;
    white-space: normal;
    width: max-content;
    max-width: 240px;
    text-align: left;
    opacity: 0;
    pointer-events: none;
    transition: opacity .14s ease, transform .14s ease;
    z-index: 80;
    box-shadow: 0 8px 22px -8px rgba(22, 27, 36, .45);
}

.has-tip::before {
    content: "";
    position: absolute;
    left: 50%;
    bottom: calc(100% + 2px);
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: rgba(22, 27, 36, .94);
    opacity: 0;
    pointer-events: none;
    transition: opacity .14s ease;
    z-index: 81;
}

.has-tip:hover::after,
.has-tip:focus-visible::after,
.has-tip:hover::before,
.has-tip:focus-visible::before {
    opacity: 1;
}

.has-tip:hover::after,
.has-tip:focus-visible::after {
    transform: translateX(-50%) translateY(0);
}

/* 操作列靠右：提示左对齐，避免溢出视口 */
.admin-row .tool-actions .has-tip::after {
    left: auto;
    right: 0;
    transform: translateY(4px);
}

.admin-row .tool-actions .has-tip:hover::after,
.admin-row .tool-actions .has-tip:focus-visible::after {
    transform: translateY(0);
}

.admin-row .tool-actions .has-tip::before {
    left: auto;
    right: 14px;
    transform: none;
}

/* ---- 首页左右布局（科目导航已上移至搜索框下横排，主区单列） ---- */
.home-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
    align-items: start;
    min-width: 0;
    width: 100%;
}

.home-side {
    position: sticky;
    top: 196px;
    max-height: calc(100vh - 212px);
    overflow-y: auto;
    scrollbar-width: thin;
}

.side-title {
    font-size: 13.5px;
    font-weight: 700;
    margin-bottom: 10px;
}

.side-cats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
}

.chip-side {
    font-size: 11.5px;
    padding: 2px 8px;
    text-align: center;
}

.rec-banner {
    font-size: 12px;
    color: var(--muted);
    margin: 0 0 12px;
    padding: 8px 14px;
    background: #fdf6ec;
    border: 1px solid #f0e3bd;
    border-radius: var(--radius-sm);
}

@media (max-width: 980px) {
    .home-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .home-side {
        position: static;
        max-height: none;
        overflow: visible;
    }

    .side-cats {
        grid-template-columns: repeat(auto-fill, minmax(88px, 1fr));
    }
}

/* ---- 工作台等：行式压缩（首页 .tool-grid 自行覆盖） ---- */
.tool-list:not(.tool-grid) .tool-row {
    padding: 9px 16px;
    gap: 12px;
}

.tool-list:not(.tool-grid) .tool-head {
    margin-bottom: 2px;
}

.tool-list:not(.tool-grid) .tool-head h3 {
    font-size: 14px;
}

.tool-list:not(.tool-grid) .tool-head .chip {
    font-size: 11px;
    padding: 1px 9px;
}

.tool-sub {
    display: flex;
    align-items: baseline;
    gap: 14px;
    min-width: 0;
}

.tool-sub .tool-summary {
    flex: 1;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 12px;
    margin: 0;
}

.tool-sub .tool-stats {
    font-size: 11.5px;
    white-space: nowrap;
}

.tool-actions .btn {
    padding: 7px 15px;
    font-size: 13px;
}

.fav-toggle {
    white-space: nowrap;
}

/* ---- 首页 / 标准详情：两列卡片 ---- */
.home-main {
    padding-top: 6px;
    min-width: 0;
}

.tool-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
}

.tool-grid .tool-card {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    /* 内容区与操作行间距（统一，勿在各页单独写） */
    padding: 16px 18px 14px;
    min-width: 0;
    /* 覆盖 grid 默认 min-width:auto，禁止操作行撑破视窗 */
    min-height: 0;
    border: 1px solid rgba(0, 0, 0, .05);
    box-shadow: var(--shadow);
}

.tool-grid .tool-card:hover {
    border-color: rgba(0, 0, 0, .08);
    box-shadow: var(--shadow-hover);
}

.tool-grid .tool-main {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
    min-width: 0;
}

.tool-grid .tool-head {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    flex-wrap: wrap;
    margin-bottom: 0;
}

.tool-grid .tool-head h3 {
    flex: 1 1 100%;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.4;
    margin: 0 0 2px;
    letter-spacing: .01em;
}

.tool-grid .tool-head .chip {
    font-size: 11px;
    padding: 1px 8px;
}

.tool-grid .tool-summary {
    margin: 0;
    font-size: 12.5px;
    line-height: 1.65;
    color: var(--muted);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    white-space: normal;
    flex: 1;
}

/* 来源徽标（简介下）：单行；超宽省略，圆章不缩 */
.tool-main .tool-origin {
    display: inline-flex;
    flex-wrap: nowrap;
    align-items: center;
    align-self: flex-start;
    margin: 8px 0 0;
    max-width: 100%;
    min-width: 0;
    height: 22px;
    line-height: 1;
    white-space: nowrap;
}
.tool-main .tool-origin-icon {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    margin-right: -11px;
    box-shadow: 0 0 0 2px #fff;
    flex-shrink: 0;
}
.tool-main .tool-origin-icon .icon,
.tool-main .tool-origin-icon svg {
    width: 14px;
    height: 14px;
    opacity: 1;
    display: block;
    stroke-width: 2.25;
}
.tool-main .tool-origin-label {
    display: block;
    min-width: 0;
    flex: 1 1 auto;
    padding: 4px 10px 4px 16px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .02em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.35;
}
.tool-origin--platform .tool-origin-icon {
    background: #059669;
    color: #fff;
}
.tool-origin--platform .tool-origin-label {
    background: #d1fae5;
    color: #047857;
}
.tool-origin--user .tool-origin-icon {
    background: #64748b;
    color: #fff;
}
.tool-origin--user .tool-origin-label {
    background: #e2e8f0;
    color: #334155;
}

.tool-grid .tool-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid rgba(0, 0, 0, .05);
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
    flex-shrink: 1;
    /* 覆盖全局 .tool-actions{flex-shrink:0} */
}

.tool-grid .tool-actions .tool-stats {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 10px;
    margin: 0 auto 0 0;
    font-size: 12px;
    color: var(--muted);
    letter-spacing: .02em;
    min-width: 0;
    max-width: 100%;
}

.tool-grid .tool-actions .tool-stats .stat {
    color: var(--ink-2);
    min-width: 0;
}

.tool-grid .tool-actions .btn {
    padding: 7px 16px;
    font-size: 13px;
    flex-shrink: 0;
}

.tool-grid .tool-actions form {
    display: inline-flex;
    margin: 0;
}

@media (max-width: 860px) {

    /* 必须 minmax(0,1fr)：裸 1fr = minmax(auto,1fr)，操作行会撑破视窗 */
    .tool-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .tool-grid .tool-card {
        overflow-x: clip;
    }

    .tool-grid .tool-actions .tool-stats {
        flex: 1 1 100%;
        margin: 0;
        max-width: 100%;
    }

    .tool-grid .tool-actions {
        justify-content: flex-end;
    }
}

.toast {
    position: fixed;
    left: 50%;
    bottom: 32px;
    transform: translateX(-50%);
    background: rgba(22, 27, 36, .88);
    color: #fff;
    font-size: 13px;
    padding: 9px 18px;
    border-radius: 999px;
    z-index: 200;
    animation: toastIn .2s ease-out;
    white-space: nowrap;
}

@keyframes toastIn {
    from {
        opacity: 0;
        transform: translate(-50%, 8px);
    }

    to {
        opacity: 1;
        transform: translate(-50%, 0);
    }
}

/* ---- 创建小计算页：居中单列，全部对齐 ---- */
.submit-page {
    max-width: 760px;
    margin: 0 auto;
}

.submit-head {
    margin-bottom: 18px;
}

.submit-head h1 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 6px;
    color: var(--ink);
}

.submit-head p {
    font-size: 13.5px;
    color: var(--ink-2);
    max-width: 640px;
}

.link-btn {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    color: var(--accent-deep);
    font-size: inherit;
    font-weight: 600;
}

.link-btn:hover {
    text-decoration: underline;
}

.submit-page .form-sec {
    padding: 16px 20px;
    margin-bottom: 12px;
}

.submit-page .form-grid {
    gap: 10px;
}

/* ---- 共建说明弹窗内容 ---- */
.about-box {
    width: min(620px, 92vw);
    height: auto;
    max-height: 84vh;
}

.about-body {
    padding: 20px 26px;
    overflow-y: auto;
    font-size: 13.5px;
    color: var(--ink-2);
}

.about-body h3 {
    font-size: 14px;
    font-weight: 700;
    color: var(--ink);
    margin: 14px 0 4px;
}

.about-body h3:first-child {
    margin-top: 0;
}

.about-body p {
    line-height: 1.7;
}

.search-hint {
    font-size: 13px;
    color: #8a6410;
    background: #fdf6e3;
    border: 1px solid #f0e3bd;
    border-radius: var(--radius-sm);
    padding: 8px 14px;
    margin-bottom: 12px;
}

.product-tip {
    background: linear-gradient(135deg, #fff7ef, #fdeef5);
    border: 1px solid #f3d9e4;
    border-radius: var(--radius-sm);
    padding: 11px 16px;
    font-size: 13.5px;
    color: var(--ink-2);
    margin: 12px 0;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

/* ---- 看板对比表：固定列宽，长文本省略；仅对比页表头吸顶 ---- */
.dash-table {
    table-layout: fixed;
}

.dash-table th,
.dash-table td {
    overflow: hidden;
    text-overflow: ellipsis;
    overflow-wrap: break-word;
    vertical-align: top;
}

.dash-table .dash-doc,
.dash-table .dash-basis,
.dash-table .dash-anchor-txt {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.dash-table .dash-basis {
    -webkit-line-clamp: 2;
}

/* 仅宽桌面吸顶；≤1100 保留 .table-wrap 横滑，避免列被挤叠 */
@media (min-width: 1101px) {
    .dash-wrap {
        overflow: visible;
    }

    .dash-wrap .dash-table thead th {
        position: sticky;
        top: calc(var(--header-h) + 78px);
        z-index: 30;
        background: #fafafa;
        box-shadow: 0 1px 0 rgba(0, 0, 0, .05);
    }
}

.site-footer {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 30;
    border-top: none;
    padding: 9px 0;
    text-align: center;
    font-size: 12px;
    color: var(--muted);
    background: rgba(250, 250, 250, .78);
    backdrop-filter: saturate(1.6) blur(16px);
    -webkit-backdrop-filter: saturate(1.6) blur(16px);
    box-shadow: none;
}

.site-footer .footer-row {
    margin: 0;
    line-height: 1.7;
}

/* 首行含 logo 标签：flex 垂直居中，避免 inline-flex 相对旁侧文字偏上/偏下 */
.site-footer .footer-row:first-child {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    column-gap: 2px;
    row-gap: 4px;
}

.site-footer .footer-row+.footer-row {
    margin-top: 2px;
}

.site-footer .footer-row a {
    font-weight: 600;
}

.site-footer .footer-row.muted a {
    font-weight: 500;
    color: var(--muted);
}

.site-footer .footer-row.muted a:hover {
    color: var(--accent);
}

.site-footer .dot-sep {
    margin: 0 6px;
    color: #d4d9e0;
}

@media (max-width: 720px) {
    .hero {
        padding: 44px 16px 28px;
    }

    .hero h1 {
        font-size: 30px;
    }

    /* 首页搜索保持一行；其它页若需堆叠自行覆盖 */
    .runtime-frame {
        height: 600px;
    }

    .quick-run iframe {
        height: 520px;
    }

    .tool-row {
        flex-direction: column;
        align-items: stretch;
    }

    .tool-actions {
        justify-content: flex-end;
    }

    .header-inner {
        gap: 10px;
        padding: 0 12px;
    }

    .binding-actions {
        margin-left: 0;
    }

    .wrap {
        padding-left: 14px;
        padding-right: 14px;
    }

    main.wrap {
        padding-top: 18px;
        padding-bottom: 112px;
    }

    .sticky-head {
        margin-left: -14px;
        margin-right: -14px;
        padding-left: 14px;
        padding-right: 14px;
    }

    /* 标准库 / 工具管理：默认展开，点文字链才收起 */
    .sticky-head[data-filter-collapse] .filter-fold-row {
        display: flex;
        justify-content: flex-end;
        margin: 0 0 6px;
    }

    .sticky-head[data-filter-collapse] .filter-fold {
        display: inline;
    }

    .sticky-head[data-filter-collapse].is-collapsed .filter-bar {
        display: none;
    }

    .sticky-head[data-filter-collapse].is-collapsed .filter-fold-row {
        margin-bottom: 0;
    }

    .sticky-head[data-filter-collapse].is-collapsed .batch-bar {
        margin-top: 8px;
    }

    .batch-bar {
        gap: 6px;
    }

    .batch-all,
    .batch-count {
        font-size: 12.5px;
        white-space: nowrap;
        flex-shrink: 0;
    }

    .batch-count {
        margin-right: 0;
    }

    .batch-bar .btn-sm {
        padding: 6px 8px;
        font-size: 12.5px;
    }

    /* 顶栏：汉堡抽屉，大屏规则不变 */
    .nav-toggle {
        display: inline-flex;
    }

    .site-nav {
        display: none;
        position: fixed;
        top: var(--header-h);
        left: 0;
        right: 0;
        margin: 0;
        z-index: 60;
        flex-direction: column;
        align-items: stretch;
        gap: 4px;
        padding: 12px 14px 16px;
        background: #fff;
        border-bottom: 1px solid var(--line);
        box-shadow: 0 16px 28px -18px rgba(22, 27, 36, .35);
    }

    body.nav-open .site-nav {
        display: flex;
    }

    body.nav-open .nav-mask {
        display: block;
    }

    .site-nav a {
        padding: 12px 14px;
        font-size: 15px;
        border-radius: 10px;
    }

    .user-area .hello {
        display: none;
    }

    .user-trigger {
        padding-right: 8px;
    }

    .user-caret {
        display: none;
    }

    /* 页脚收紧 */
    .site-footer {
        font-size: 11px;
        padding: 8px 0 calc(8px + env(safe-area-inset-bottom, 0px));
    }

    .site-footer .footer-row {
        line-height: 1.55;
    }

    .site-footer .dot-sep {
        margin: 0 5px;
    }

    /* 弹框小屏 */
    .modal-card {
        padding: 18px 16px 14px;
        width: min(480px, calc(100vw - 28px));
    }

    .modal-actions-guest {
        flex-direction: column;
        align-items: stretch;
    }

    .modal-actions-guest>.btn,
    .modal-actions-right {
        width: 100%;
    }

    .modal-actions-right {
        justify-content: stretch;
    }

    .modal-actions-right .btn {
        flex: 1;
        text-align: center;
        justify-content: center;
    }

    .std-table th,
    .std-table td {
        padding: 12px 12px;
    }

    .stat-boxes {
        flex-wrap: wrap;
    }

    .filter-bar .total-hint {
        white-space: normal;
        margin-left: 0;
        width: 100%;
    }
}

/* 窄于桌面内容宽：表设底线宽度，容器内横滑（≥1101 桌面列宽不变） */
@media (max-width: 1100px) {
    .std-lib-table {
        table-layout: fixed;
        min-width: 860px;
        width: max(100%, 860px);
    }

    .dash-files-table {
        table-layout: fixed;
        /* 编号+文件+地区+状态+科目+工具 的自然底线，宁横滑不挤叠 */
        min-width: 1020px;
        width: max(100%, 1020px);
    }

    .dash-table {
        table-layout: fixed;
        min-width: 960px;
        width: max(100%, 960px);
    }

    /* 只约束 td：表头保持可读，避免「编…」「地…」；单元格禁止画出邻列 */
    .std-lib-table td,
    .dash-files-table td,
    .dash-table td {
        max-width: 0;
    }
}

/* ---- M3/M4：用户体系、提交与审核（续写，保持发丝线与墨蓝基调） ---- */
.user-area {
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-area .user-link {
    font-size: 13px;
    color: var(--ink-2);
    padding: 4px 8px;
    border-radius: 8px;
}

.user-area .user-link:hover {
    background: #f0f3f8;
    text-decoration: none;
    color: var(--accent-deep);
}

.logout-form {
    display: inline;
    margin: 0;
}

/* 表单卡片 */
.auth-box {
    max-width: 460px;
    margin: 30px auto;
}

.auth-box .page-title {
    text-align: center;
}

.auth-box>.muted {
    text-align: center;
    margin-bottom: 20px;
}

.auth-alt {
    text-align: center;
    margin-top: 16px;
}

/* 登录 / 注册 / 改密提交按钮：品牌主色 */
.auth-submit {
    width: 100%;
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: 10px;
    padding: 12px 0;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: .12em;
    cursor: pointer;
    font-family: inherit;
    transition: background .15s, box-shadow .15s;
    box-shadow: 0 2px 10px -3px rgba(232, 54, 139, .35);
}

.auth-submit:hover {
    background: var(--accent-deep);
    box-shadow: 0 4px 14px -3px rgba(232, 54, 139, .45);
}

.form-card {
    background: var(--card);
    border: 1px solid rgba(0, 0, 0, .05);
    border-radius: var(--radius);
    padding: 28px;
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-card label {
    display: flex;
    flex-direction: column;
    gap: 7px;
    font-size: 13.5px;
    font-weight: 550;
    color: var(--ink-2);
}

.form-card input,
.form-card select,
.form-card textarea {
    padding: 11px 14px;
    border: 2px solid var(--line);
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-family: inherit;
    background: #fafafa;
    color: var(--ink);
    width: 100%;
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}

/* 统一控件高度：原生 select 默认比 input 高，显式对齐 */
.form-card input:not([type="radio"]),
.form-card select {
    height: 44px;
}

.submit-form input:not([type="radio"]),
.submit-form select {
    height: 44px;
}

.form-card input:focus,
.form-card select:focus,
.form-card textarea:focus {
    outline: none;
    border-color: var(--accent);
    background: #fff;
    box-shadow: var(--focus-ring);
}

.form-card textarea {
    resize: vertical;
}

.form-card select[size] {
    height: auto;
    min-height: 176px;
}

.form-card .btn {
    align-self: flex-start;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 14px;
}

.submit-form {
    max-width: 720px;
}

/* 标准题录选择器：搜索 + 可滚动列表 */
.std-picker {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: #fafafa;
}

.std-picker .std-filter {
    margin: 0;
    height: 40px;
    background: #fff;
}

.std-picker-meta {
    font-size: 12px;
    color: var(--muted);
    line-height: 1.4;
}

.std-picker-meta.is-empty {
    color: #b45309;
}

.std-picker select {
    width: 100%;
    min-height: 0;
    height: auto !important;
    max-height: 280px;
    padding: 6px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    font-size: 13px;
    line-height: 1.45;
    overflow-y: auto;
    scrollbar-width: thin;
}

.std-picker select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: var(--focus-ring);
}

.std-picker select option {
    padding: 6px 8px;
    border-radius: 4px;
}

.std-picker select option:checked {
    background: linear-gradient(#fff7ed, #fff7ed);
    color: var(--ink);
}

.std-filter {
    margin-bottom: 8px;
}

.form-errors {
    list-style: none;
    background: #fdecea;
    border: 1px solid #f2c7c3;
    color: #b3261e;
    border-radius: var(--radius-sm);
    padding: 12px 16px;
    margin-bottom: 18px;
    font-size: 14px;
}

.form-errors li+li {
    margin-top: 4px;
}

/* 评分 */
.rating-form {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 14px 18px;
    margin-bottom: 16px;
    box-shadow: var(--shadow);
}

.rating-form input[name="comment"] {
    flex: 1;
    min-width: 220px;
    padding: 9px 13px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-family: inherit;
}

.rating-form input[name="comment"]:focus {
    outline: none;
    border-color: var(--accent);
}

.rating-stars {
    display: flex;
    gap: 2px;
}

.rating-stars label {
    cursor: pointer;
}

.rating-stars input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.rating-stars span {
    display: inline-block;
    padding: 4px 7px;
    border-radius: 8px;
    font-size: 13px;
    color: var(--muted);
    letter-spacing: .05em;
    transition: color .12s, background .12s;
}

.rating-stars label:hover span {
    color: var(--gold);
}

.rating-stars input:checked+span {
    background: #fdf3dd;
    color: var(--gold);
    font-weight: 600;
}

.rating-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.rating-row {
    display: flex;
    align-items: baseline;
    gap: 12px;
    flex-wrap: wrap;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 11px 16px;
    font-size: 14px;
}

.stars {
    color: var(--gold);
    letter-spacing: .08em;
    font-size: 13px;
    white-space: nowrap;
}

.rating-user {
    font-weight: 600;
    color: var(--ink-2);
}

.rating-comment {
    color: var(--ink-2);
    flex: 1;
    min-width: 120px;
}

.rating-time,
.recent-time {
    margin-left: auto;
    white-space: nowrap;
}

/* 个人中心 */
#uploads {
    scroll-margin-top: 72px;
}

.recent-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.recent-row {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 10px 16px;
    font-size: 14px;
    color: var(--ink);
}

a.recent-row:hover {
    text-decoration: none;
    border-color: #d3d9e3;
}

.recent-title {
    font-weight: 600;
}

.reject-reason {
    background: #fdecea;
    border: 1px solid #f2c7c3;
    color: #b3261e;
    border-radius: var(--radius-sm);
    padding: 8px 14px;
    font-size: 13px;
    margin-top: 10px;
}

.flash-note {
    background: #eef7ee;
    border: 1px solid #c8e6c9;
    color: #2e7d32;
    border-radius: var(--radius-sm);
    padding: 8px 14px;
    font-size: 13px;
    margin-bottom: 16px;
}

/* 可见性与共享 */
.visibility-box {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 18px 20px;
    margin: 18px 0;
    box-shadow: var(--shadow);
}

.visibility-form {
    display: flex;
    gap: 10px;
    align-items: center;
}

.visibility-form select {
    padding: 8px 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    font-size: 14px;
    background: #fff;
}

.share-list {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 14px;
}

.chip-share {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    color: #e8357f;
    border: 1px solid rgba(232, 53, 127, .35);
}

.share-remove {
    display: inline;
    margin: 0;
}

.share-remove button {
    border: none;
    background: none;
    color: #e8357f;
    cursor: pointer;
    font-size: 13px;
    padding: 0 2px;
    line-height: 1;
    opacity: .7;
}

.share-remove button:hover {
    opacity: 1;
    color: #c81e66;
}

.share-add {
    display: inline-flex;
    gap: 8px;
    margin-left: 4px;
}

.share-add input {
    padding: 6px 11px;
    border: 1px solid var(--line);
    border-radius: 8px;
    font-size: 13px;
    font-family: inherit;
    width: 200px;
}

/* 审核台 */
.scan-box {
    border-radius: var(--radius-sm);
    padding: 12px 16px;
    margin-bottom: 14px;
    font-size: 14px;
}

.scan-box ul {
    list-style: none;
    margin-top: 6px;
}

.scan-box li {
    font-size: 13px;
    margin-top: 3px;
}

.scan-fail {
    background: #fdecea;
    border: 1px solid #f2c7c3;
    color: #b3261e;
}

.scan-warn {
    background: #fdf8ec;
    border: 1px solid #efe3c2;
    color: #7a5b16;
}

.review-version {
    margin-top: 20px;
}

.review-actions {
    display: flex;
    gap: 18px;
    align-items: flex-start;
    flex-wrap: wrap;
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid var(--line);
}

.review-actions form {
    margin: 0;
}

.reject-form {
    display: flex;
    gap: 10px;
    flex: 1;
    min-width: 320px;
}

.reject-form input {
    flex: 1;
    padding: 9px 13px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-family: inherit;
}

.btn-danger {
    background: #b3261e;
    box-shadow: 0 2px 10px -3px rgba(179, 38, 30, .35);
}

.btn-danger:hover {
    background: #8f1d17;
    filter: none;
}

/* ---- 统计看板：大字数字 + 白卡片抬升（无硬分割线） ---- */
.dash-hero {
    text-align: center;
    padding: 40px 0 0;
}

.dash-hero h1 {
    font-size: 30px;
    font-weight: 700;
    letter-spacing: .16em;
    text-indent: .16em;
}

.dash-hero .muted {
    margin: 10px 0 0;
    letter-spacing: .04em;
}

.dash-stats {
    display: flex;
    justify-content: space-around;
    align-items: stretch;
    flex-wrap: wrap;
    gap: 8px 4px;
    margin: 28px auto 0;
    max-width: 920px;
    background: var(--card);
    border: 1px solid rgba(0, 0, 0, .05);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 22px 12px;
}

.dash-stat {
    flex: 1 1 0;
    min-width: 110px;
    padding: 6px 16px;
    text-align: center;
}

.dash-stat strong {
    display: block;
    font-size: 32px;
    font-weight: 700;
    color: var(--accent-deep);
    line-height: 1.15;
    font-variant-numeric: tabular-nums;
}

.dash-stat span {
    font-size: 12px;
    color: var(--muted);
    letter-spacing: .08em;
}

.dash-subhead {
    display: flex;
    align-items: center;
    gap: 14px;
    margin: 36px 0 16px;
    flex-wrap: wrap;
}

.dash-subhead h2 {
    font-size: 19px;
    font-weight: 650;
}

.dash-nav {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-left: auto;
    text-decoration: none;
    line-height: 1;
    padding: 10px 18px;
    font-size: 14px;
    border-radius: var(--radius-sm);
}

.dash-nav>span {
    line-height: 1.25;
}

.dash-nav .icon,
.dash-nav svg {
    width: 16px;
    height: 16px;
    margin: 0;
    display: block;
    flex-shrink: 0;
    position: relative;
    top: 0;
}

.dash-card-foot .icon,
.dash-card-foot svg {
    width: 12px;
    height: 12px;
    margin-left: 2px;
    display: inline-block;
    vertical-align: -1px;
}

.dash-back {
    margin-left: 0;
    margin-right: auto;
}

.dash-title {
    font-size: 26px;
    font-weight: 650;
    letter-spacing: .02em;
}

.dash-title-sub {
    font-size: 14px;
    font-weight: 400;
    margin-left: 14px;
    letter-spacing: .03em;
}

.dash-statboxes {
    margin: 18px 0 6px;
}

.dash-num-sm {
    font-size: 19px;
    font-weight: 700;
    color: var(--accent-deep);
    font-variant-numeric: tabular-nums;
}

.dash-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(248px, 1fr));
    gap: 16px;
}

.dash-card {
    background: var(--card);
    border: 1px solid rgba(0, 0, 0, .05);
    border-radius: var(--radius);
    padding: 20px 22px;
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: transform .18s, box-shadow .18s, border-color .18s;
}

.dash-card:hover {
    text-decoration: none;
    border-color: rgba(0, 0, 0, .08);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.dash-card-top {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 10px;
}

.dash-card h3 {
    font-size: 16.5px;
    font-weight: 650;
    color: var(--ink);
}

.dash-num {
    font-size: 30px;
    font-weight: 700;
    color: var(--accent-deep);
    font-variant-numeric: tabular-nums;
}

.dash-card-meta {
    font-size: 12.5px;
    color: var(--muted);
}

.dash-bar {
    height: 5px;
    background: #edf1f7;
    border-radius: 999px;
    overflow: hidden;
}

.dash-bar i {
    display: block;
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--accent), var(--accent-deep));
}

.dash-bar i.alt {
    background: linear-gradient(90deg, var(--orange), #e06c00);
}

.stat-cell {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 160px;
}

.stat-cell .stat-num {
    width: 42px;
    text-align: right;
    font-size: 13px;
    font-variant-numeric: tabular-nums;
    color: var(--ink-2);
}

.stat-cell .dash-bar {
    flex: 1;
}

.stats-two-col {
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: 28px;
    align-items: start;
}

@media (max-width: 860px) {
    .stats-two-col {
        grid-template-columns: 1fr;
    }
}

.dash-card-foot {
    font-size: 12px;
    margin-top: auto;
}

.dash-foot {
    margin-top: 26px;
    text-align: center;
}

.dash-scale {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: stretch;
    background: var(--card);
    border: 1px solid rgba(0, 0, 0, .05);
    border-radius: var(--radius);
    padding: 18px 20px;
    margin: 18px 0 22px;
    box-shadow: var(--shadow);
}

.dash-scale-intro {
    width: 100%;
    font-size: 13px;
    color: var(--ink-2);
    margin-bottom: 2px;
}

.dash-anchor {
    flex: 1;
    min-width: 128px;
    background: #fafafa;
    border-radius: var(--radius-sm);
    padding: 10px 14px;
}

.dash-anchor strong {
    display: block;
    font-size: 20px;
    font-weight: 700;
    color: var(--accent-deep);
    font-variant-numeric: tabular-nums;
}

.dash-anchor span {
    font-size: 12px;
    color: var(--muted);
}

.dash-table th[data-sort] {
    cursor: pointer;
    user-select: none;
    white-space: nowrap;
}

.dash-table th[data-sort]::after {
    content: "";
    display: inline-block;
    width: 12px;
    height: 12px;
    margin-left: 5px;
    vertical-align: -1px;
    background: #c7cdd8;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 15 5 5 5-5'/%3E%3Cpath d='m7 9 5-5 5 5'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 15 5 5 5-5'/%3E%3Cpath d='m7 9 5-5 5 5'/%3E%3C/svg%3E") center / contain no-repeat;
}

.dash-table th[data-sort].asc::after {
    background: var(--accent);
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m18 15-6-6-6 6'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m18 15-6-6-6 6'/%3E%3C/svg%3E") center / contain no-repeat;
}

.dash-table th[data-sort].desc::after {
    background: var(--accent);
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") center / contain no-repeat;
}

.dash-table td {
    font-size: 13.5px;
}

.dash-doc {
    font-weight: 600;
    color: var(--ink-2);
    max-width: 300px;
    line-height: 1.55;
}

/* 政策文件视角：政策文件列拉宽，覆盖科目收窄（芯片可换行） */
.dash-files-table {
    table-layout: fixed;
}

.dash-files-table .col-code {
    width: 96px;
}

.dash-files-table .col-doc {
    width: auto;
}

.dash-files-table .col-region {
    width: 100px;
}

.dash-files-table .col-status {
    width: 100px;
}

.dash-files-table .col-subjects {
    width: 240px;
}

.dash-files-table .col-tools {
    width: 88px;
}

.dash-files-table .dash-doc {
    max-width: none;
}

/* 本表列多，统一收紧左右内边距，避免 24px×2 把窄列裁成「工…」 */
.dash-files-table th,
.dash-files-table td {
    padding-left: 12px;
    padding-right: 12px;
    overflow: hidden;
    vertical-align: top;
}

.dash-files-table th {
    white-space: nowrap;
    text-overflow: clip;
}

.dash-files-table td {
    text-overflow: ellipsis;
}

.dash-files-table td:nth-child(3),
.dash-files-table td:nth-child(4),
.dash-files-table td:nth-child(6) {
    white-space: nowrap;
}

.dash-files-table td:nth-child(5) {
    white-space: normal;
    overflow: hidden;
}

.dash-files-table td:nth-child(5) .chip {
    margin: 2px 4px 2px 0;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dash-anchor-txt {
    font-family: ui-monospace, Consolas, "Courier New", monospace;
    font-size: 12.5px;
    color: var(--ink-2);
    line-height: 1.7;
}

.dash-badge {
    display: inline-block;
    background: #fdf3dd;
    color: #8a6410;
    border: 1px solid #efe3c2;
    border-radius: 6px;
    padding: 0 7px;
    font-size: 11px;
    margin-left: 6px;
    white-space: nowrap;
}

.dash-runs {
    font-size: 12px;
    margin-top: 3px;
}

.dash-empty td {
    text-align: center;
    color: var(--muted);
    padding: 40px 0;
}

@media (max-width: 720px) {
    .dash-stats {
        padding: 16px 8px;
        gap: 12px 0;
    }

    .dash-stat {
        min-width: 30%;
        padding: 4px 10px;
    }

    .dash-stat strong {
        font-size: 26px;
    }

    .dash-title-sub {
        display: block;
        margin: 6px 0 0;
    }
}

/* ---- M7 管理平台（独立后台外壳） ---- */
.adm-body {
    background: var(--bg);
}

.adm-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    background: #18181b;
    color: #f4f4f5;
    padding: 0 22px;
    height: 52px;
    position: sticky;
    top: 0;
    z-index: 50;
}

.adm-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #f4f4f5;
    font-size: 15px;
    min-width: 0;
}

.adm-brand:hover {
    text-decoration: none;
    color: #fff;
}

.adm-brand strong {
    white-space: nowrap;
}

.adm-logo {
    width: 24px;
    height: 24px;
    border-radius: 8px;
    flex-shrink: 0;
}

.adm-menu {
    display: none;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    margin-left: auto;
    border: 1px solid rgba(255, 255, 255, .18);
    border-radius: 10px;
    background: transparent;
    color: #f4f4f5;
    cursor: pointer;
    flex-shrink: 0;
    font-family: inherit;
}

.adm-menu:hover {
    border-color: #fff;
    color: #fff;
}

.adm-menu .icon,
.adm-menu svg {
    width: 22px;
    height: 22px;
    display: block;
}

.adm-nav-mask {
    display: none;
}

.adm-side-meta {
    display: none;
}

.adm-topnav {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 13px;
    flex-shrink: 0;
}

.adm-topnav a {
    color: #a1a1aa;
}

.adm-topnav a:hover {
    color: #fff;
    text-decoration: none;
}

.adm-who {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #d4d4d8;
}

.adm-layout {
    display: flex;
    min-height: calc(100vh - 52px);
}

.adm-side {
    width: 176px;
    flex-shrink: 0;
    background: #fff;
    border-right: 1px solid var(--line);
    padding: 18px 12px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: sticky;
    top: 52px;
    height: calc(100vh - 52px);
}

.adm-nav {
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    font-size: 13.5px;
    color: var(--ink-2);
    font-weight: 500;
    transition: background .2s ease, color .2s ease;
}

.adm-nav:hover {
    background: #f4f4f5;
    text-decoration: none;
    color: var(--ink);
}

.adm-nav.on {
    background: #fdf2f7;
    color: var(--accent-deep);
    font-weight: 600;
    position: relative;
}

.adm-nav.on::before {
    content: "";
    position: absolute;
    left: 5px;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 16px;
    border-radius: 999px;
    background: var(--accent);
}

.adm-main {
    flex: 1;
    padding: 26px 30px 60px;
    min-width: 0;
}

.adm-title {
    font-size: 21px;
    font-weight: 750;
    margin: 0 0 4px;
}

.adm-title+.muted {
    margin: 0 0 18px;
    font-size: 13px;
}

.adm-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 14px;
    margin-bottom: 26px;
}

.adm-card {
    background: #fff;
    border: 1px solid rgba(0, 0, 0, .05);
    border-radius: var(--radius);
    padding: 18px 20px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    color: var(--ink);
    box-shadow: var(--shadow);
    transition: box-shadow .2s ease, border-color .2s ease, transform .2s ease;
}

a.adm-card:hover {
    text-decoration: none;
    border-color: rgba(228, 228, 231, .95);
    box-shadow: var(--shadow-hover);
    transform: translateY(-1px);
}

.adm-card strong {
    font-size: 24px;
    font-weight: 750;
    font-variant-numeric: tabular-nums;
}

.adm-card span {
    font-size: 12px;
    color: var(--muted);
}

.adm-card.warn {
    border-color: #f5c6dd;
    background: #fdf2f7;
}

.adm-card.warn strong {
    color: var(--accent-deep);
}

/* 后台表格：与前台 std-table 同一套 HeroUI 气质 */
.adm-table-wrap {
    background: var(--card);
    border: 1px solid rgba(0, 0, 0, .05);
    border-radius: var(--radius);
    overflow-x: auto;
    box-shadow: var(--shadow);
}

.adm-table-wrap table.rt {
    width: 100%;
    border-collapse: collapse;
    border-spacing: 0;
    font-size: 14px;
    font-variant-numeric: tabular-nums;
}

.adm-table-wrap table.rt th {
    text-align: left;
    padding: 16px 22px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .04em;
    color: var(--muted);
    background: #fafafa;
    border-bottom: 1px solid rgba(0, 0, 0, .05);
    white-space: nowrap;
}

.adm-table-wrap table.rt td {
    padding: 14px 22px;
    border-bottom: 1px solid rgba(0, 0, 0, .05);
    white-space: nowrap;
    vertical-align: middle;
    color: var(--ink);
}

.adm-table-wrap table.rt td.nowrap {
    white-space: nowrap;
}
.adm-table-wrap table.rt td.wrap {
    white-space: normal;
    max-width: 420px;
    line-height: 1.5;
}
.adm-table-wrap table.rt td.wrap-wide {
    white-space: normal;
    min-width: 140px;
    max-width: 280px;
    line-height: 1.5;
}
/* 批量导入结果：标题很长，禁止再卡死列宽 */
.adm-table-wrap table.rt.bi-result {
    table-layout: fixed;
    width: 100%;
}
.adm-table-wrap table.rt.bi-result th,
.adm-table-wrap table.rt.bi-result td {
    white-space: normal;
    word-break: break-word;
    overflow-wrap: anywhere;
    line-height: 1.55;
    vertical-align: top;
}
.adm-table-wrap table.rt.bi-result td.col-id,
.adm-table-wrap table.rt.bi-result th.col-id {
    width: 4.5em;
    white-space: nowrap;
    word-break: normal;
    overflow-wrap: normal;
}
.adm-table-wrap table.rt.bi-result td.col-title,
.adm-table-wrap table.rt.bi-result th.col-title {
    width: 58%;
}
.adm-table-wrap table.rt.bi-result td.col-reason,
.adm-table-wrap table.rt.bi-result th.col-reason {
    width: auto;
}
.adm-table-wrap table.rt.bi-result td.col-time,
.adm-table-wrap table.rt.bi-result th.col-time {
    width: 11em;
    white-space: nowrap;
    word-break: normal;
}
.adm-table-wrap table.rt.bi-result td.col-actor,
.adm-table-wrap table.rt.bi-result th.col-actor {
    width: 6.5em;
    white-space: nowrap;
}
.adm-table-wrap table.rt.bi-result td.col-status,
.adm-table-wrap table.rt.bi-result th.col-status {
    width: 4em;
    white-space: nowrap;
}
.adm-ops-modal {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}
.adm-ops-modal[hidden] { display: none; }
.adm-ops-modal-bg {
    position: absolute;
    inset: 0;
    background: rgba(17, 24, 28, .45);
}
.adm-ops-modal-card {
    position: relative;
    z-index: 1;
    width: min(720px, 100%);
    max-height: min(80vh, 640px);
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 20px 48px -12px rgba(0, 0, 0, .28);
    overflow: hidden;
}
.adm-ops-modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 18px;
    border-bottom: 1px solid var(--line);
}
.adm-ops-modal-head strong { font-size: 15px; }
.adm-ops-modal-body {
    padding: 14px 18px 18px;
    overflow: auto;
    flex: 1;
    min-height: 0;
}
.adm-ops-modal-body pre {
    margin: 0;
    padding: 12px 14px;
    background: #fafafa;
    border: 1px solid var(--line);
    border-radius: 10px;
    font-size: 12.5px;
    line-height: 1.55;
    white-space: pre-wrap;
    word-break: break-word;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.adm-table-wrap table.rt td .mono {
    font-variant-numeric: tabular-nums;
}

.adm-table-wrap table.rt tbody tr:last-child td {
    border-bottom: none;
}

.adm-table-wrap table.rt tbody tr {
    transition: background .15s ease;
}

.adm-table-wrap table.rt tbody tr:hover {
    background: #f4f4f5;
}

.adm-table-wrap form.inline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0;
}

/* 后台 std-table 不再另起一套，沿用全局 */
.adm-main .std-table th {
    text-transform: none;
}

/* 工具管理操作列：三按钮紧凑尺寸同行不换行（覆盖上文 .admin-row .tool-actions 的 wrap） */
.admin-row .tool-actions {
    flex-wrap: nowrap;
    gap: 6px;
    white-space: nowrap;
}

.admin-row .tool-actions form {
    display: inline-flex;
    margin: 0;
}

.admin-row .tool-actions .btn {
    padding: 5px 12px;
    font-size: 13px;
}

/* 行为流水：垂直时间线（白卡 + 圆点细环 + 发丝线 + 右侧等宽数字时间） */
.tl {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 4px 20px;
}

.tl-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    font-size: 13px;
    border-bottom: 1px solid #f1f3f7;
}

.tl-row:last-child {
    border-bottom: none;
}

.tl-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    border: 2px solid #c9cfda;
    flex-shrink: 0;
}

.tl-tag {
    font-size: 11px;
    font-weight: 600;
    width: 54px;
    flex-shrink: 0;
    letter-spacing: .02em;
}

.tl-user {
    font-weight: 600;
    white-space: nowrap;
}

.tl-user .muted {
    font-size: 12px;
    font-weight: 400;
}

.tl-detail {
    flex: 1;
    min-width: 0;
    color: var(--ink-2);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tl-time {
    margin-left: auto;
    padding-left: 14px;
    flex-shrink: 0;
    color: var(--muted);
    font-size: 12px;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

@media (max-width: 720px) {
    .tl-row {
        flex-wrap: wrap;
    }

    .tl-detail {
        flex-basis: 100%;
        white-space: normal;
    }
}

/* 类型配色（低饱和度）：使用=灰蓝 注册=绿 收藏=粉 评分评价=琥珀 提交工具=靛蓝 审核=紫 */
.tl-d-use {
    border-color: #97a6c0;
}

.tl-t-use {
    color: #5e7392;
}

.tl-d-register {
    border-color: #7cc497;
}

.tl-t-register {
    color: #2f8f5b;
}

.tl-d-favorite {
    border-color: #e39ab9;
}

.tl-t-favorite {
    color: #c0528a;
}

.tl-d-rating {
    border-color: #e3b566;
}

.tl-t-rating {
    color: #a87e23;
}

.tl-d-submit {
    border-color: #8b96dd;
}

.tl-t-submit {
    color: #4f5fc0;
}

.tl-d-review {
    border-color: #ab92d3;
}

.tl-t-review {
    color: #7a5cb0;
}

/* 运营统计：趋势图压缩为 220px 高（覆盖上文图表旧值） */
.trend-chart {
    width: 100%;
    height: 220px;
    display: block;
}

.chart-card {
    padding: 14px 16px 6px;
}

.chart-grid {
    stroke: #eef1f5;
    stroke-width: .6;
}

.chart-tick {
    font-size: 9.5px;
    fill: #a7aebb;
}

.chart-legend {
    margin-left: auto;
    font-size: 11px;
    color: var(--muted);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.chart-note {
    padding: 8px 4px 6px;
}

/* 后台表单卡：提交按钮右对齐 */
.form-card .submit-bar {
    justify-content: flex-end;
    padding: 0 2px 2px;
}

/* 后台内错误提示页（不离开管理平台体系） */
.adm-error {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 40px 44px;
    max-width: 560px;
}

.adm-error .adm-title {
    margin-bottom: 10px;
}

.adm-error-actions {
    display: flex;
    gap: 10px;
    margin-top: 22px;
}

/* 审核台疑似重复检测 */
.dup-box {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 14px 18px;
    margin-top: 12px;
}

.dup-head {
    font-size: 13.5px;
    font-weight: 650;
    margin-bottom: 10px;
}

.dup-list {
    display: flex;
    flex-direction: column;
}

.dup-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 0;
    border-top: 1px solid #f1f3f7;
    font-size: 13px;
    flex-wrap: wrap;
}

.dup-row:first-child {
    border-top: 0;
}

.dup-badge {
    flex-shrink: 0;
    min-width: 52px;
    text-align: center;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 999px;
    background: #eef2f8;
    color: #51637f;
}

.dup-badge.hot {
    background: #fdf2f7;
    color: var(--accent-deep);
    font-weight: 600;
}

.dup-title {
    font-weight: 600;
    color: var(--ink);
}

.dup-title:hover {
    color: var(--accent-deep);
}

/* 审核页工具条 */
.review-tools {
    margin-left: auto;
    display: flex;
    gap: 8px;
}

/* 协议页标题/版本：桌面两列，窄屏由下方媒体查询收成一列 */
.doc-meta-grid {
    grid-template-columns: 2fr 1fr;
    gap: 12px;
}

/* 后台窄屏：侧栏抽屉 + 内容不整页横滑（≥721 规则不变） */
@media (max-width: 720px) {
    .adm-body {
        --header-h: 52px;
    }

    .adm-topbar {
        padding: 0 max(12px, env(safe-area-inset-right)) 0 max(12px, env(safe-area-inset-left));
        gap: 10px;
    }

    .adm-brand-sub {
        display: none;
    }

    .adm-menu {
        display: inline-flex;
    }

    .adm-topnav {
        gap: 0;
    }

    .adm-topnav .adm-front,
    .adm-topnav .adm-who {
        display: none;
    }

    .adm-nav-mask {
        position: fixed;
        inset: 0;
        top: 52px;
        z-index: 40;
        background: rgba(22, 27, 36, .35);
    }

    body.adm-nav-open .adm-nav-mask {
        display: block;
    }

    .adm-layout {
        display: block;
        min-height: 0;
    }

    .adm-side {
        position: fixed;
        top: 52px;
        left: 0;
        bottom: 0;
        width: min(280px, 86vw);
        height: auto;
        z-index: 45;
        transform: translateX(-105%);
        transition: transform .2s ease;
        box-shadow: 16px 0 28px -18px rgba(22, 27, 36, .45);
        overflow-y: auto;
        padding: 12px 12px calc(18px + env(safe-area-inset-bottom, 0px));
    }

    body.adm-nav-open .adm-side {
        transform: translateX(0);
    }

    .adm-side-meta {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
        padding: 4px 14px 12px;
        margin-bottom: 6px;
        border-bottom: 1px solid var(--line);
    }

    .adm-side-meta .adm-who {
        color: var(--ink);
        flex-wrap: wrap;
    }

    .adm-side-meta .adm-front {
        font-size: 13px;
    }

    .adm-nav {
        min-height: 44px;
        display: flex;
        align-items: center;
    }

    .adm-main {
        padding: 16px 14px 48px;
    }

    .adm-main .sticky-head {
        margin-left: -14px;
        margin-right: -14px;
        padding-left: 14px;
        padding-right: 14px;
    }

    .adm-main .filter-bar input,
    .adm-main .filter-bar select,
    .adm-main .filter-bar .adm-sel,
    .adm-main .filter-bar .adm-user-search {
        flex: 1 1 160px;
        min-width: 0;
        max-width: 100%;
    }

    .adm-main .stats-two-col {
        grid-template-columns: minmax(0, 1fr);
    }

    .adm-main .stats-two-col>*,
    .adm-main .rank-list,
    .adm-main .rank-row {
        min-width: 0;
        max-width: 100%;
    }

    .adm-main .admin-colhead {
        display: none;
    }

    .admin-row .tool-actions {
        flex-wrap: wrap;
        white-space: normal;
    }

    .adm-main .section-head {
        flex-wrap: wrap;
        align-items: center;
    }

    .adm-main .review-tools {
        margin-left: 0;
        flex-wrap: wrap;
    }

    .adm-main .reject-form {
        min-width: 0;
        flex: 1 1 100%;
        width: 100%;
    }

    .adm-main .reject-form input {
        min-width: 0;
    }

    .adm-error {
        padding: 24px 18px;
    }

    .doc-meta-grid {
        grid-template-columns: 1fr;
    }
}

/* ---- M9 分享闭环：状态徽标 / 邀请盒 / 站内通知 ---- */
.share-badge {
    font-style: normal;
    font-size: 11px;
    padding: 0 6px;
    border-radius: 999px;
    line-height: 16px;
}

.st-active {
    background: #e6f6ec;
    color: #1a7f37;
}

.st-pending {
    background: #fff4e0;
    color: #b26a00;
}

.st-declined {
    background: #fdecec;
    color: #b3261e;
}

.st-suspended {
    background: #eef1f5;
    color: #6b7280;
}

.share-op {
    border: none;
    background: none;
    color: var(--muted);
    cursor: pointer;
    font-size: 12px;
    padding: 0 1px;
    line-height: 1;
}

.share-op:hover {
    color: var(--accent);
}

.invite-box {
    border: 1px solid #f3d9a4;
    background: #fffaf0;
    border-radius: var(--radius-sm);
    padding: 12px 14px;
    margin-bottom: 14px;
}

.invite-title {
    margin: 0 0 8px;
    font-size: 13px;
    font-weight: 600;
    color: #8a5a00;
}

.invite-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 8px 10px;
    background: #fff;
    border: 1px solid #f0e2c0;
    border-radius: var(--radius-sm);
    margin-bottom: 6px;
    flex-wrap: wrap;
}

.invite-row:last-child {
    margin-bottom: 0;
}

.invite-main {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 13.5px;
}

.invite-actions {
    display: flex;
    gap: 8px;
}

.ntf-page {
    max-width: 860px;
    margin: 0 auto;
    padding: 28px 20px 60px;
}

.ntf-head {
    margin-bottom: 18px;
}

.ntf-head h1 {
    font-size: 22px;
    margin: 0 0 6px;
}

.ntf-sub {
    font-size: 13px;
    color: var(--muted);
}

.ntf-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ntf-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 12px 14px;
}

.ntf-item.unread {
    border-left: 3px solid var(--accent);
    background: #fff8fb;
}

.ntf-kind {
    flex: none;
    font-size: 11.5px;
    padding: 2px 8px;
    border-radius: 999px;
    background: #eef1f5;
    color: #55606e;
    margin-top: 2px;
    white-space: nowrap;
}

.kind-share_invite,
.kind-share_send {
    background: #e8f0fe;
    color: #1a56c4;
}

.kind-share_accept,
.kind-share_resume,
.kind-public_ok {
    background: #e6f6ec;
    color: #1a7f37;
}

.kind-share_decline,
.kind-share_suspend,
.kind-share_cancel,
.kind-public_no {
    background: #fdecec;
    color: #b3261e;
}

.ntf-main {
    flex: 1;
    min-width: 0;
}

.ntf-title {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--ink);
}

.ntf-body {
    margin: 3px 0 0;
    font-size: 13px;
    color: var(--ink-2);
    line-height: 1.55;
    word-break: break-all;
}

.ntf-side {
    flex: none;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
}

.ntf-time {
    font-size: 12px;
    color: var(--muted);
    white-space: nowrap;
}

.ntf-link {
    font-size: 12.5px;
    color: var(--accent);
    text-decoration: none;
    white-space: nowrap;
}

.ntf-link:hover {
    text-decoration: underline;
}

.ntf-empty {
    text-align: center;
    padding: 60px 20px;
    background: #fff;
    border: 1px dashed var(--line);
    border-radius: var(--radius-sm);
}

.ntf-empty p {
    margin: 0 0 6px;
    font-size: 15px;
    font-weight: 600;
}

.ntf-empty-sub {
    font-size: 13px !important;
    font-weight: 400 !important;
    color: var(--muted);
    margin-bottom: 16px !important;
}

/* ---- M9 可见性三态菜单 ---- */
.vis-menu {
    position: relative;
    display: inline-block;
}

.vis-menu>summary {
    list-style: none;
    cursor: pointer;
    user-select: none;
}

.vis-menu>summary::-webkit-details-marker {
    display: none;
}

.vis-menu[open]>summary {
    border-color: var(--accent);
    color: var(--accent);
}

.vis-opts {
    position: absolute;
    right: 0;
    top: calc(100% + 6px);
    z-index: 40;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    box-shadow: 0 8px 24px rgba(20, 30, 50, .12);
    padding: 6px;
    min-width: 210px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.vis-opts form {
    margin: 0;
}

.vis-opts button {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1px;
    width: 100%;
    text-align: left;
    border: none;
    background: none;
    padding: 7px 10px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    color: var(--ink);
    cursor: pointer;
    font-family: inherit;
}

.vis-opts button:hover {
    background: #f5f7fa;
}

.vis-opts button.cur {
    color: var(--accent);
    background: #fff5f9;
    cursor: default;
}

.vis-opts button small {
    font-size: 11.5px;
    font-weight: 400;
    color: var(--muted);
}

/* ---- 后台 Select 换皮 ---- */
.adm-sel {
    position: relative;
    display: inline-flex;
    vertical-align: middle;
    min-width: 140px;
}
.adm-sel-native {
    position: absolute !important;
    opacity: 0 !important;
    pointer-events: none !important;
    width: 1px !important;
    height: 1px !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    clip: rect(0, 0, 0, 0);
}
.adm-sel-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    min-height: 38px;
    padding: 8px 12px;
    border: 1px solid var(--line, #e2e8f0);
    border-radius: var(--radius-sm, 8px);
    background: #fafafa;
    color: var(--ink, #0f172a);
    font-size: 13.5px;
    font-family: inherit;
    cursor: pointer;
    text-align: left;
    transition: border-color .15s, box-shadow .15s, background .15s;
}
.adm-sel-btn:hover {
    background: #fff;
    border-color: #cbd5e1;
}
.adm-sel.open .adm-sel-btn,
.adm-sel-btn:focus {
    outline: none;
    border-color: var(--accent, #e8357f);
    background: #fff;
    box-shadow: var(--focus-ring, 0 0 0 3px rgba(232, 53, 127, .15));
}
.adm-sel-label {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.adm-sel.is-empty .adm-sel-label {
    color: #94a3b8;
}
.adm-sel-caret {
    width: 0;
    height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 5px solid #94a3b8;
    flex-shrink: 0;
}
.adm-sel.open .adm-sel-caret {
    transform: rotate(180deg);
}
.adm-sel-panel {
    position: absolute;
    z-index: 320;
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    min-width: 100%;
    max-width: min(360px, 92vw);
    background: #fff;
    border: 1px solid #e8edf5;
    border-radius: 10px;
    box-shadow: 0 14px 34px -14px rgba(30, 41, 59, .28);
    padding: 6px;
    max-height: 280px;
    display: flex;
    flex-direction: column;
}
.adm-sel-panel[hidden] {
    display: none !important;
}
.adm-sel-search {
    width: 100%;
    box-sizing: border-box;
    margin: 0 0 6px;
    padding: 8px 10px;
    border: 1px solid #e2e8f0;
    border-radius: 7px;
    font-size: 13px;
    font-family: inherit;
    background: #f8fafc;
}
.adm-sel-search:focus {
    outline: none;
    border-color: var(--accent, #e8357f);
    background: #fff;
}
.adm-sel-list {
    list-style: none;
    margin: 0;
    padding: 0;
    overflow: auto;
    max-height: 220px;
}
.adm-sel-opt {
    padding: 8px 10px;
    border-radius: 6px;
    font-size: 13.5px;
    color: #334155;
    cursor: pointer;
}
.adm-sel-opt:hover,
.adm-sel-opt.is-active {
    background: #fdf2f7;
    color: var(--accent, #e8357f);
}
.adm-sel-opt.is-selected {
    font-weight: 600;
    color: var(--accent, #e8357f);
}
.adm-sel-opt.is-disabled {
    opacity: .45;
    cursor: not-allowed;
}
.adm-sel-empty {
    padding: 10px;
    font-size: 12.5px;
    color: #94a3b8;
    text-align: center;
}
.filter-bar .adm-sel {
    flex: 0 1 auto;
    min-width: 148px;
    max-width: 220px;
}
.filter-bar .adm-sel-btn {
    background: #fafafa;
}

/* 作者远程 typeahead */
.adm-user-search {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-width: 180px;
    max-width: 260px;
    flex: 1 1 180px;
}
.adm-user-search .adm-user-q {
    width: 100%;
    min-width: 0;
}
.adm-user-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    max-width: 100%;
    padding: 7px 8px 7px 12px;
    border: 1px solid #fbcfe8;
    border-radius: var(--radius-sm, 8px);
    background: #fff5f9;
    font-size: 13.5px;
    color: #9d174d;
}
.adm-user-chip[hidden] {
    display: none !important;
}
.adm-user-chip-text {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.adm-user-clear {
    border: none;
    background: transparent;
    color: #be185d;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
    padding: 0 4px;
    font-family: inherit;
}
.adm-user-list {
    position: absolute;
    z-index: 330;
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    background: #fff;
    border: 1px solid #e8edf5;
    border-radius: 10px;
    box-shadow: 0 14px 34px -14px rgba(30, 41, 59, .28);
    padding: 6px;
    max-height: 240px;
    overflow: auto;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.adm-user-list[hidden] {
    display: none !important;
}
.adm-user-opt {
    display: block;
    width: 100%;
    text-align: left;
    border: none;
    background: none;
    padding: 8px 10px;
    border-radius: 6px;
    font-size: 13.5px;
    color: #334155;
    cursor: pointer;
    font-family: inherit;
}
.adm-user-opt:hover {
    background: #fdf2f7;
    color: var(--accent, #e8357f);
}