/* 啄木鸟分析 — Web 端设计变量 */
:root {
    --bg: #f4f6f9;
    --surface: #ffffff;
    --nav: #0f172a;
    --nav-hover: #1e293b;
    --text: #0f172a;
    --muted: #64748b;
    --accent: #0d9488;
    --accent-dim: #ccfbf1;
    --border: #e2e8f0;
    --danger: #dc2626;
    --radius: 12px;
    --shadow: 0 4px 24px rgba(15, 23, 42, 0.06);
    --font: "DM Sans", "Noto Sans SC", system-ui, sans-serif;
    /* 侧栏原 240px 的 80% */
    --app-nav-width: 192px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    font-size: 16px;
}

/* 应用壳：与 admin_manager 一致，侧栏 + 主区占满视口剩余宽度，主内容在 .app-main-scroll 内滚动 */
html.app-html-root,
body.app-body {
    height: 100%;
    overflow: hidden;
}

body.app-body {
    margin: 0;
    font-family: var(--font);
    color: var(--text);
    background: var(--bg);
    line-height: 1.55;
}

body.auth-body {
    margin: 0;
    font-family: var(--font);
    color: var(--text);
    background: var(--bg);
    line-height: 1.55;
    min-height: 100vh;
}

.app-shell {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    justify-content: flex-start;
    height: 100vh;
    min-height: 0;
    width: 100%;
    max-width: none;
    overflow: hidden;
}

.app-shell--no-nav .app-workspace {
    flex: 1 1 100%;
    width: 100%;
}

.app-nav {
    width: var(--app-nav-width);
    flex-shrink: 0;
    background: var(--nav);
    color: #e2e8f0;
    display: flex;
    flex-direction: column;
    padding: 1.15rem 0.55rem;
    min-height: 0;
    overflow-x: hidden;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
}

.app-workspace {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    align-self: stretch;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
}

.app-nav-top {
    flex-shrink: 0;
    padding-bottom: 1rem;
    margin-bottom: 0.5rem;
    border-bottom: 1px solid rgba(148, 163, 184, 0.15);
}

.app-nav-bottom {
    flex-shrink: 0;
    margin-top: auto;
    padding-top: 1rem;
    width: 100%;
    box-sizing: border-box;
}

.app-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 0.55rem;
    padding: 0 0.5rem 1rem;
    margin: 0;
    width: 100%;
    box-sizing: border-box;
}

.app-brand-logo {
    display: block;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    object-fit: contain;
    flex-shrink: 0;
    background: rgba(255, 255, 255, 0.06);
}

.app-brand-logo--lg {
    width: 48px;
    height: 48px;
    border-radius: 12px;
}

.app-brand-title {
    font-weight: 700;
    font-size: 1rem;
    letter-spacing: 0.02em;
}

.app-brand-sub {
    font-size: 0.7rem;
    color: #94a3b8;
    margin-top: 0;
    letter-spacing: 0.02em;
}

.app-user-pill {
    margin: 0 0.25rem;
    padding: 0.5rem 0.65rem;
    background: var(--nav-hover);
    border-radius: 8px;
    font-size: 0.8rem;
    text-align: center;
}

.app-user-name {
    font-weight: 600;
    color: #f8fafc;
    word-break: break-all;
}

.app-nav-user-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    margin: 0 0.25rem;
    text-decoration: none;
    color: inherit;
    border-radius: 10px;
    padding: 0.2rem 0.15rem 0;
    transition: background 0.15s ease;
}

.app-nav-user-block:hover {
    background: rgba(255, 255, 255, 0.06);
}

.app-nav-user-avatar-wrap {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 2px rgba(148, 163, 184, 0.25);
}

.app-nav-user-avatar {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.app-nav-links {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.app-nav-link {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.35rem;
    padding: 0.55rem 0.45rem;
    color: #cbd5e1;
    text-decoration: none;
    border-radius: 8px;
    font-size: 0.86rem;
    font-weight: 500;
    text-align: left;
    transition: background 0.15s, color 0.15s;
    box-sizing: border-box;
}

.app-nav-link-icon {
    flex: 0 0 1.25rem;
    width: 1.25rem;
    height: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.app-nav-link-icon svg {
    display: block;
    width: 1.125rem;
    height: 1.125rem;
    flex-shrink: 0;
    opacity: 0.92;
}

.app-nav-link-text {
    flex: 1 1 auto;
    min-width: 0;
    text-align: center;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.app-nav-link-logout {
    width: 100%;
    box-sizing: border-box;
}

.app-nav-link:hover {
    background: var(--nav-hover);
    color: #fff;
}

.app-nav-link.is-active {
    background: rgba(13, 148, 136, 0.25);
    color: #5eead4;
}

.app-nav-link-muted {
    color: #94a3b8;
    font-size: 0.85rem;
}

.app-nav-foot {
    padding-top: 0.75rem;
    margin: 0;
    border-top: 1px solid rgba(148, 163, 184, 0.15);
}

.app-main {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    align-self: stretch;
    min-width: 0;
    min-height: 0;
    padding: 0;
    overflow: hidden;
}

.app-main-head {
    flex-shrink: 0;
    margin: 0;
    padding: 1.35rem 2rem 0.75rem;
    border-bottom: 1px solid var(--border);
    background: var(--bg);
}

.app-main .app-flash {
    flex-shrink: 0;
    margin: 0.75rem 2rem;
}

.app-main-scroll {
    flex: 1 1 auto;
    min-height: 0;
    min-width: 0;
    align-self: stretch;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 1rem 2rem 2.5rem;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
}

.app-main-head ~ .app-main-scroll {
    padding-top: 0.65rem;
}

.app-main-scroll .indicators-page,
.app-main-scroll .indicators-key-page,
.app-main-scroll .dashboard-page,
.app-main-scroll .news-dash-page,
.app-main-scroll .news-live-page,
.app-main-scroll .settings-page,
.app-main-scroll .knowledge-page,
.app-main-scroll .pc-download-page,
.app-main-scroll .industry-news-page,
.app-main-scroll .blackboard-page,
.app-main-scroll .english-practice-page,
.app-main-scroll .knowledge-ai-window-page {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: none;
}

.app-main-scroll .grid-2 {
    width: 100%;
    max-width: none;
}

/* 滚动区内主块：允许在 flex 列中横向拉满，避免 min-width:auto 把主区挤成窄条 */
.app-main-scroll > * {
    box-sizing: border-box;
    min-width: 0;
    max-width: 100%;
    align-self: stretch;
}

.app-main-scroll > section,
.app-main-scroll > article,
.app-main-scroll > div.dashboard-page,
.app-main-scroll > div.indicators-page,
.app-main-scroll > div.indicators-key-page,
.app-main-scroll > div.news-dash-page,
.app-main-scroll > div.settings-page,
.app-main-scroll > div.industry-news-page,
.app-main-scroll > div.blackboard-page,
.app-main-scroll > div.english-practice-page,
.app-main-scroll > div.pc-download-page,
.app-main-scroll > div.grid-2 {
    width: 100%;
}

.app-main-scroll .narrow-form {
    max-width: 420px;
    width: 100%;
    align-self: flex-start;
}

.app-page-title {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.app-flash {
    padding: 0.75rem 1rem;
    border-radius: var(--radius);
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.app-flash-ok {
    background: #ecfdf5;
    color: #047857;
    border: 1px solid #a7f3d0;
}

.app-flash-err {
    background: #fef2f2;
    color: #b91c1c;
    border: 1px solid #fecaca;
}

.app-toast {
    position: fixed;
    z-index: 140;
    top: calc(1rem + env(safe-area-inset-top, 0px));
    right: max(1rem, env(safe-area-inset-right, 0px));
    min-width: 260px;
    max-width: min(520px, calc(100vw - 2rem));
    padding: 0.7rem 0.95rem;
    border-radius: 10px;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.22);
    font-size: 0.88rem;
    line-height: 1.45;
    pointer-events: none;
    animation: app-toast-slide-in 0.18s ease-out;
}

.app-toast--ok {
    background: #ecfdf5;
    color: #047857;
    border: 1px solid #a7f3d0;
}

@keyframes app-toast-slide-in {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.panel {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 1.25rem 1.5rem;
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
}

.panel-accent {
    border-color: rgba(13, 148, 136, 0.25);
    background: linear-gradient(180deg, #ffffff 0%, #f0fdfa 100%);
}

.panel-spaced {
    margin-top: 1.5rem;
}

.panel-title {
    margin: 0 0 1rem;
    font-size: 1.05rem;
    font-weight: 700;
}

.sub-title {
    margin: 1.25rem 0 0.5rem;
    font-size: 0.95rem;
    font-weight: 600;
}

.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

/* 研究报告页：顶栏与分页对齐行业资讯；左列表 6、右仅文件预览 4；主区高度与视口对齐 */
.app-main.app-main--knowledge {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.app-main--knowledge .knowledge-page {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    /* 与 .app-main-scroll .settings-page 一致用 0 作 basis，否则子项 height:100% / 1fr 常无法得到确定高度 */
    flex: 1 1 0;
    min-height: 0;
}

.app-main--knowledge .knowledge-page > .grid-2--knowledge {
    flex: 1 1 0;
    min-height: 0;
    min-width: 0;
    align-self: stretch;
}

.app-main--knowledge .knowledge-page > .settings-subnav {
    flex-shrink: 0;
}

/* 左栏白卡片：与 .app-main--industry-news .industry-news-panel 同构（主区铺满 + 表格外层可纵向滚动） */
.app-main--knowledge .knowledge-reports-panel {
    flex: 1 1 auto;
    min-height: 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: none;
    align-self: stretch;
    box-sizing: border-box;
}

/* 有数据时：表单 + 表格区 + 分页，与行业资讯「面板 > table-wrap + pager」同一套伸缩规则 */
.app-main--knowledge .knowledge-reports-stack {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: none;
}

.app-main--knowledge .knowledge-reports-stack > .knowledge-title-filter--reports {
    flex-shrink: 0;
}

.app-main--knowledge .knowledge-reports-stack > .knowledge-reports-table-wrap {
    flex: 1 1 auto;
    min-height: 0;
    min-width: 0;
    width: 100%;
    overflow-x: hidden;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.app-main--knowledge .knowledge-reports-table-wrap .knowledge-reports-table {
    width: 100%;
}

.app-main--knowledge .knowledge-reports-panel > .industry-news-empty-hint,
.app-main--knowledge .knowledge-reports-panel > .app-flash,
.app-main--knowledge .knowledge-reports-panel > p.muted {
    flex-shrink: 0;
}

.app-main--knowledge .knowledge-reports-stack > .industry-news-pager {
    flex-shrink: 0;
}

.knowledge-title-filter {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem 0.5rem;
    flex-shrink: 0;
    margin-left: auto;
}

.knowledge-title-filter-input {
    max-width: 100%;
    box-sizing: border-box;
}

.knowledge-title-filter--reports {
    display: block;
    margin: 0 0 0.45rem;
    margin-left: 0;
    width: 100%;
    box-sizing: border-box;
}

.knowledge-title-filter--reports .knowledge-title-filter-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem 0.75rem;
    width: 100%;
}

.knowledge-title-filter--reports .knowledge-title-filter-search {
    flex: 0 1 auto;
    min-width: 0;
}

.knowledge-title-filter--reports .knowledge-title-filter-actions {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.35rem 0.45rem;
    flex-shrink: 0;
    margin-left: auto;
}

.knowledge-title-filter--reports .knowledge-title-filter-input {
    width: min(13.5rem, 36vw);
    min-width: 8.5rem;
    max-width: 100%;
    box-sizing: border-box;
}

.grid-2--knowledge {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-rows: minmax(0, 1fr);
    align-items: stretch;
    /* 双栏行高至少贴近视口，使右侧预览区与可视高度对齐（已扣约顶栏+子导航+主区内边距） */
    min-height: calc(100dvh - 10.5rem);
    min-height: calc(100svh - 10.5rem);
}

.grid-2--knowledge > .knowledge-reports-panel,
.grid-2--knowledge > .knowledge-right-column {
    min-height: 0;
    align-self: stretch;
}

.grid-2--knowledge > .knowledge-right-column {
    display: flex;
    flex-direction: column;
    gap: 0;
    flex: 1 1 auto;
    min-height: 0;
    min-width: 0;
    align-self: stretch;
}

.knowledge-preview-panel {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.knowledge-preview-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem 0.75rem;
    margin-bottom: 0.65rem;
}

.knowledge-preview-toolbar-title {
    margin: 0;
}

.knowledge-preview-toolbar-actions {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.knowledge-preview-frame-wrap {
    flex: 1 1 auto;
    min-height: 0;
    position: relative;
    background: #e8eaed;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--border, #e5e7eb);
}

.knowledge-preview-iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    background: #fff;
}

.knowledge-preview-iframe.is-hidden {
    visibility: hidden;
    pointer-events: none;
}

.knowledge-preview-empty {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 1rem 1.25rem;
    box-sizing: border-box;
}

.knowledge-preview-empty.is-hidden {
    display: none;
}

/* 研究报告表：序号 : 标题 : 关键词 = 1 : 8 : 4 */
.knowledge-reports-table col.industry-news-col-seq {
    width: 7.692308%;
}

.knowledge-reports-table col.industry-news-col-title {
    width: 61.538462%;
}

.knowledge-reports-table col.knowledge-col-keywords {
    width: 30.769231%;
}

.knowledge-reports-table .industry-news-th-title,
.knowledge-reports-table .industry-news-td-title {
    text-align: left;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 行高与行业资讯 .data-table + .industry-news-table 一致，不再单独压扁 padding */

.knowledge-reports-table .industry-news-td-title .knowledge-title-link,
.knowledge-reports-table .industry-news-td-title .industry-news-title-text {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    min-width: 0;
}

.knowledge-reports-table .industry-news-th-seq,
.knowledge-reports-table .industry-news-td-seq {
    text-align: center;
}

.knowledge-th-keywords {
    text-align: center;
}

.knowledge-td-keywords {
    text-align: center;
    vertical-align: middle;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.knowledge-kw-tag {
    display: inline-flex;
    align-items: center;
    max-width: 100%;
    padding: 0.12rem 0.45rem;
    margin: 0;
    border: 1px solid rgba(13, 148, 136, 0.28);
    border-radius: 999px;
    background: rgba(13, 148, 136, 0.08);
    color: #0f766e;
    font-size: 0.78rem;
    line-height: 1.35;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    vertical-align: middle;
}

.knowledge-report-row {
    cursor: pointer;
}

a.knowledge-title-link {
    cursor: pointer;
}

.knowledge-report-row:hover {
    background: rgba(13, 148, 136, 0.04);
}

.knowledge-report-row--selected {
    background: rgba(13, 148, 136, 0.07);
    box-shadow: inset 3px 0 0 #0d9488;
}

.knowledge-article-attach-preview {
    padding: 0;
    margin-bottom: 1rem;
    overflow: hidden;
    background: #e8eaed;
    border: 1px solid var(--border, #e5e7eb);
    border-radius: var(--radius, 8px);
}

.knowledge-article-attach-iframe {
    display: block;
    width: 100%;
    height: min(72vh, 720px);
    min-height: 360px;
    border: 0;
    background: #fff;
}

/* 研究报告 · AI 搜索独立页（window.open） */
.app-main.app-main--knowledge-ai-window {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.app-main--knowledge-ai-window .app-main-scroll {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.app-main--knowledge-ai-window .knowledge-ai-window-page {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 0;
    max-width: 48rem;
    width: 100%;
    margin: 0 auto;
    box-sizing: border-box;
}

.app-main--knowledge-ai-window .knowledge-ai-window-chat {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.app-main--knowledge-ai-window .knowledge-ai-window-chat .ds-chat {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    max-height: none;
}

.app-main--knowledge-ai-window .knowledge-ai-window-chat .ds-msgs {
    flex: 1 1 auto;
    min-height: 12rem;
    max-height: calc(100dvh - 15rem);
    max-height: calc(100svh - 15rem);
    overflow-y: auto;
}

.panel--ds-chat {
    display: flex;
    flex-direction: column;
    min-height: 0;
    min-width: 0;
}

.panel--ds-chat .ds-chat {
    flex: 1 1 auto;
    min-height: 420px;
}

.app-main--knowledge .knowledge-doc-pager {
    flex-shrink: 0;
    margin-top: 1rem;
}

/* 系统设置：与宏观数据等页一致占满主区高度，宽屏双栏 */
.app-main.app-main--settings {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.app-main--settings .settings-page {
    gap: 1.25rem;
}

@media (min-width: 960px) {
    .app-main--settings .settings-page {
        display: grid;
        grid-template-columns: minmax(260px, 380px) minmax(0, 1fr);
        grid-template-rows: auto minmax(0, 1fr);
        align-items: start;
        column-gap: 1.5rem;
        row-gap: 1rem;
    }

    .app-main--settings .settings-subnav {
        grid-column: 1 / -1;
        grid-row: 1;
    }

    .app-main--settings .settings-profile-card {
        grid-column: 1;
        grid-row: 2;
        align-self: stretch;
    }

    .app-main--settings .settings-page > section.panel-spaced {
        grid-column: 2;
        grid-row: 2;
        margin-top: 0;
        align-self: stretch;
    }

    .app-main--settings .settings-subscribe-panel {
        grid-column: 1 / -1;
        grid-row: 2;
        align-self: stretch;
    }

    /* 分类订阅页：顶栏全宽，下方左申请区 : 右列表 = 4:6（不用设置页默认双栏网格） */
    .app-main--settings .settings-page.settings-page--class-subscribe {
        display: flex;
        flex-direction: column;
        align-items: stretch;
    }
}

/* 分类订阅：左 4 / 右 6，窄屏单列 */
.settings-class-subscribe-workspace {
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: minmax(0, 1fr) minmax(0, 1fr);
    gap: 1.25rem;
    align-items: stretch;
    width: 100%;
    min-width: 0;
}

@media (min-width: 960px) {
    .settings-class-subscribe-workspace {
        grid-template-columns: 4fr 6fr;
        grid-template-rows: minmax(0, 1fr);
        gap: 1.5rem;
    }
}

.settings-class-subscribe-workspace > .settings-class-subscribe-section {
    min-width: 0;
}

/* 分类订阅：双栏铺满主区剩余高度，底部显示操作结果提示 */
.app-main-scroll.app-main-scroll--flash-bottom {
    justify-content: flex-start;
}

.app-main-scroll.app-main-scroll--flash-bottom > .settings-page.settings-page--class-subscribe {
    flex: 1 1 auto;
    min-height: 0;
}

.app-main-flash-bottom {
    flex-shrink: 0;
    width: 100%;
    box-sizing: border-box;
    margin-top: auto;
    padding-top: 0.35rem;
}

.app-main-flash-bottom .app-flash {
    margin: 0 0 0.5rem;
    width: 100%;
    box-sizing: border-box;
}

.app-main-flash-bottom .app-flash:last-child {
    margin-bottom: 0;
}

.app-main-scroll .settings-page.settings-page--class-subscribe {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-height: 0;
}

.settings-page--class-subscribe .settings-subnav {
    flex-shrink: 0;
}

.settings-page--class-subscribe .settings-class-subscribe-workspace {
    flex: 1 1 auto;
    min-height: 0;
    align-items: stretch;
}

.settings-class-subscribe-section {
    display: flex;
    flex-direction: column;
    min-height: 0;
    height: 100%;
}

.settings-class-subscribe-section > .panel-title {
    flex-shrink: 0;
    margin-bottom: 0.65rem;
}

.settings-class-section-frame {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.settings-class-apply-form,
.settings-class-my-enable-form {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.settings-class-section-scroll {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
}

.settings-class-section-empty {
    margin: 0.35rem 0.15rem 0.5rem;
}

.settings-class-section-foot {
    flex-shrink: 0;
    padding-top: 0.75rem;
    margin-top: 0.5rem;
    border-top: 1px solid var(--border);
}

/* 下载 PC 版：主区全宽铺高 */
.app-main.app-main--pc-download {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.app-main--pc-download .pc-download-columns {
    flex: 1 1 auto;
    min-height: 0;
}

.app-main.app-main--english-practice {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.app-main--english-practice .app-main-scroll {
    padding: 0;
}

.english-practice-frame {
    flex: 1 1 auto;
    width: 100%;
    min-height: 0;
    height: 100%;
    border: 0;
    background: var(--bg);
}

.english-practice-config-hint {
    margin: 1.5rem 2rem;
    max-width: 42rem;
}

.english-practice-config-hint-title {
    font-weight: 600;
    margin: 0 0 0.5rem;
}

/* 下载 PC 版：独立落地页风格 */
.pc-download-page {
    width: 100%;
    max-width: none;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.pc-download-hero {
    position: relative;
    border-radius: var(--radius);
    border: 1px solid rgba(13, 148, 136, 0.22);
    background: linear-gradient(145deg, #ffffff 0%, #f0fdfa 42%, #ecfdf5 100%);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.pc-download-hero-glow {
    position: absolute;
    inset: -40% -20% auto auto;
    width: min(420px, 70vw);
    height: min(420px, 70vw);
    border-radius: 50%;
    background: radial-gradient(circle, rgba(45, 212, 191, 0.35) 0%, transparent 68%);
    pointer-events: none;
}

.pc-download-hero-inner {
    position: relative;
    padding: 2rem 1.75rem 1.85rem;
    z-index: 1;
}

.pc-download-brand {
    margin-bottom: 1rem;
}

.pc-download-brand-logo {
    display: block;
    width: 3.25rem;
    height: 3.25rem;
    border-radius: 14px;
    object-fit: contain;
    box-shadow: 0 8px 24px rgba(13, 148, 136, 0.35);
    background: rgba(255, 255, 255, 0.92);
}

.pc-download-eyebrow {
    margin: 0 0 0.35rem;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--accent);
}

.pc-download-title {
    margin: 0 0 0.5rem;
    font-size: clamp(1.65rem, 4vw, 2.15rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.2;
    color: var(--text);
}

.pc-download-lead {
    margin: 0 0 1.35rem;
    max-width: 38rem;
    font-size: 1.02rem;
    color: var(--muted);
    line-height: 1.6;
}

.pc-download-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.65rem 0.75rem;
    margin-bottom: 0.85rem;
}

.pc-download-btn-main {
    padding: 0.8rem 1.6rem;
    font-size: 1.05rem;
    font-weight: 600;
    box-shadow: 0 4px 14px rgba(13, 148, 136, 0.35);
}

.pc-download-btn-main:hover {
    box-shadow: 0 6px 20px rgba(13, 148, 136, 0.4);
}

.pc-download-copy-tip {
    margin: 0.5rem 0 0;
    color: var(--accent);
    font-weight: 500;
}

.pc-download-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    align-items: stretch;
}

.pc-download-card {
    display: flex;
    flex-direction: column;
    min-height: 0;
    height: 100%;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem 1.35rem;
    box-shadow: 0 2px 12px rgba(15, 23, 42, 0.04);
    box-sizing: border-box;
}

.pc-download-card-title {
    margin: 0 0 0.85rem;
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
}

.pc-download-steps {
    margin: 0;
    padding-left: 1.2rem;
    color: var(--muted);
    font-size: 0.92rem;
    line-height: 1.65;
    flex: 1 1 auto;
}

.pc-download-steps li {
    margin-bottom: 0.5rem;
}

.pc-download-steps li:last-child {
    margin-bottom: 0;
}

.pc-download-bullets {
    margin: 0;
    padding-left: 1.1rem;
    color: var(--muted);
    font-size: 0.92rem;
    line-height: 1.65;
    flex: 1 1 auto;
}

.pc-download-bullets li {
    margin-bottom: 0.5rem;
}

.pc-download-bullets li:last-child {
    margin-bottom: 0;
}

@media (max-width: 720px) {
    .pc-download-hero-inner {
        padding: 1.5rem 1.15rem 1.4rem;
    }

    .pc-download-columns {
        grid-template-columns: 1fr;
    }

    .pc-download-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .pc-download-btn-main,
    .pc-download-copy {
        width: 100%;
        justify-content: center;
    }
}

/* 指标体系：主区与底部外链区纵向高度约 9:1（grid）、工作台左右分栏、表区分页、底部横向 Logo 外链 */
.app-main.app-main--indicators {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.app-main--indicators .indicators-page {
    flex: 1;
    display: grid;
    grid-template-rows: auto 9fr 1fr;
    gap: 1rem;
    min-height: 0;
    align-content: stretch;
}

.app-main--indicators .indicators-page > .settings-subnav {
    min-height: 0;
    flex-shrink: 0;
}

.app-main--indicators .indicators-page > .indicators-workspace,
.app-main--indicators .indicators-page > .indicators-links-panel {
    min-height: 0;
}

/* 宏观数据：周期查询 + 左右分栏 + 柱形图 */
.app-main.app-main--dashboard {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.app-main--dashboard .dashboard-page {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-height: 0;
}

.app-main--dashboard .dashboard-page > .settings-subnav {
    flex-shrink: 0;
}

/* 宏观经济关键指标：2 行 3 列的六区看板 */
.app-main.app-main--indicators-key {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.app-main--indicators-key .indicators-key-page {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-height: 0;
}

.app-main--indicators-key .indicators-key-page > .settings-subnav {
    flex-shrink: 0;
}

.app-main--indicators-key .indicators-key-layout {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    gap: 0.85rem;
    align-items: stretch;
}

.app-main--indicators-key .indicators-key-zone {
    min-height: 0;
    display: flex;
    flex-direction: column;
    padding: 0.9rem 1rem;
}

.app-main--indicators-key .indicators-key-zone--left {
    flex: 1 1 0;
}

.app-main--indicators-key .indicators-key-stack {
    flex: 1 1 0;
    min-width: 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.app-main--indicators-key .indicators-key-zone--top3 {
    flex: 3 1 0;
}

.app-main--indicators-key .indicators-key-zone--bottom2 {
    flex: 2 1 0;
}

.app-main--indicators-key .indicators-key-zone-title {
    margin: 0 0 0.6rem;
    font-size: 1rem;
}

.app-main--indicators-key .indicators-key-items {
    min-height: 0;
    overflow: auto;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.app-main--indicators-key .indicators-key-item {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #f8fafc;
    padding: 0.72rem 0.82rem;
    min-height: 96px;
    box-sizing: border-box;
    position: relative;
    overflow: hidden;
}

.app-main--indicators-key .indicators-key-item--key {
    background: linear-gradient(180deg, #fffaf3 0%, #fff7ed 100%);
    border-color: #fdba74;
    box-shadow: inset 3px 0 0 #f59e0b;
}

.app-main--indicators-key .indicators-key-item--high {
    background: #e0f2fe;
    border-color: #7dd3fc;
}

.app-main--indicators-key .indicators-key-item--check {
    background: #f1f5f9;
    border-color: #cbd5e1;
}

.app-main--indicators-key .indicators-key-item-name {
    margin: 0;
    font-size: 0.92rem;
    font-weight: 600;
}

.app-main--indicators-key .indicators-key-item-head {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.app-main--indicators-key .indicators-key-item-period {
    margin: 0;
    font-size: 0.76rem;
    color: var(--muted);
    text-align: left;
    white-space: nowrap;
}

.app-main--indicators-key .indicators-key-item-meta {
    margin: 0.35rem 0 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.18rem 0.35rem;
    font-size: 0.78rem;
    color: var(--muted);
}

.app-main--indicators-key .indicators-key-item-k {
    color: var(--muted);
    font-size: 0.76rem;
}

.app-main--indicators-key .indicators-key-item-v {
    font-size: 1.32rem;
    font-weight: 800;
    letter-spacing: -0.01em;
    line-height: 1.2;
    color: #0f172a;
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum" 1;
}

.app-main--indicators-key .indicators-key-item-v.is-up {
    color: #15803d;
}

.app-main--indicators-key .indicators-key-item-v.is-down {
    color: #b91c1c;
}

.app-main--indicators-key .indicators-key-item-v.is-neutral {
    color: #0f172a;
}

.app-main--indicators-key .indicators-key-item-meta em {
    font-style: normal;
    color: #94a3b8;
    margin: 0 0.32rem;
}

.app-main--indicators-key .indicators-key-item-desc {
    margin: 0.35rem 0 0;
    font-size: 0.75rem;
    line-height: 1.35;
    color: #334155;
}

.app-main--indicators-key .indicators-key-item--key .indicators-key-item-name,
.app-main--indicators-key .indicators-key-item--key .indicators-key-item-period,
.app-main--indicators-key .indicators-key-item--key .indicators-key-item-k,
.app-main--indicators-key .indicators-key-item--key .indicators-key-item-desc {
    color: #7c2d12;
}

.app-main--indicators-key .indicators-key-item--key .indicators-key-item-v.is-up {
    color: #15803d;
}

.app-main--indicators-key .indicators-key-item--key .indicators-key-item-v.is-down {
    color: #b91c1c;
}

.app-main--indicators-key .indicators-key-item--key .indicators-key-item-v.is-neutral {
    color: #7c2d12;
}

.app-main--indicators-key .indicators-key-item--key .indicators-key-item-meta em {
    color: #f59e0b;
}

.app-main--indicators-key .indicators-key-item--high .indicators-key-item-meta em {
    color: #7dd3fc;
}

.app-main--indicators-key .indicators-key-item--key::after {
    content: "重点关注";
    position: absolute;
    top: 0.42rem;
    right: 0.52rem;
    font-size: 0.66rem;
    line-height: 1;
    padding: 0.18rem 0.35rem;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.16);
    color: #92400e;
    border: 1px solid rgba(245, 158, 11, 0.42);
    pointer-events: none;
}

@media (max-width: 1200px) {
    .app-main--indicators-key .indicators-key-layout {
        flex-wrap: wrap;
    }

    .app-main--indicators-key .indicators-key-zone--left,
    .app-main--indicators-key .indicators-key-stack {
        flex: 1 1 calc(50% - 0.425rem);
    }
}

@media (max-width: 760px) {
    .app-main--indicators-key .indicators-key-layout {
        display: block;
        height: auto !important;
    }

    .app-main--indicators-key .indicators-key-zone--left,
    .app-main--indicators-key .indicators-key-stack {
        width: 100%;
        margin-bottom: 0.85rem;
    }

    .app-main--indicators-key .indicators-key-item-period {
        white-space: normal;
    }
}

.app-main.app-main--business-metrics {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.app-main--business-metrics .business-metrics-page {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-height: 0;
    flex: 1 1 auto;
}

.app-main--business-metrics .business-metrics-page > .settings-subnav {
    flex-shrink: 0;
}

.business-metrics-stock-layout {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) minmax(0, 2.4fr);
    gap: 0.9rem;
    min-height: 0;
}

.business-metrics-stock-left,
.business-metrics-stock-right {
    min-width: 0;
}

.business-metrics-stock-left {
    border: 1px solid var(--border);
    border-radius: 10px;
    background: #f8fafc;
    padding: 0.75rem 0.85rem;
    overflow: auto;
}

.business-metrics-stock-right .table-wrap {
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: auto;
    height: 100%;
}

.business-metrics-stock-right {
    display: grid;
    grid-template-rows: minmax(0, 1fr) minmax(0, 1fr);
    gap: 0.8rem;
    min-height: 0;
}

.business-metrics-stock-right-top,
.business-metrics-stock-right-bottom {
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.bm-section-title {
    margin-top: 0;
    margin-bottom: 0.45rem;
}

.bm-kpi-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.bm-kpi-plain-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
    margin-bottom: 0.65rem;
    font-size: 0.9rem;
    color: var(--text);
}

.bm-kpi-plain-meta em {
    font-style: normal;
    color: var(--muted);
}

.bm-kpi-cards {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem;
}

.bm-kpi-card {
    border: 1px solid rgba(148, 163, 184, 0.35);
    border-radius: 10px;
    background: #fff;
    padding: 0.5rem 0.6rem;
}

.bm-kpi-card-label {
    margin: 0;
    font-size: 0.78rem;
    color: var(--muted);
}

.bm-kpi-card-value {
    margin: 0.28rem 0 0;
    font-size: 1.28rem;
    line-height: 1.12;
    font-weight: 700;
    letter-spacing: 0.01em;
}

.bm-kpi-card--full {
    grid-column: 1 / -1;
}

.bm-kpi-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.28rem 0.45rem;
    border: 1px solid rgba(148, 163, 184, 0.35);
    border-radius: 999px;
    background: #fff;
}

.bm-kpi-tag em {
    font-style: normal;
    font-size: 0.76rem;
    color: var(--muted);
}

.bm-kpi-tag strong {
    font-size: 1.08rem;
    line-height: 1.15;
    font-weight: 700;
}

.business-metrics-history-table thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    background: #fff;
    cursor: pointer;
}

.business-metrics-history-table thead th:hover {
    background: #f8fafc;
}

.bm-chart-wrap {
    flex: 1 1 auto;
    min-height: 0;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    padding: 0.45rem;
}

.bm-chart-wrap canvas {
    width: 100% !important;
    height: 100% !important;
}

.bm-industry-chart-wrap {
    height: min(72vh, calc(100dvh - 16rem));
    min-height: 420px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: #fff;
    padding: 0.55rem;
}

.bm-industry-chart-wrap canvas {
    width: 100% !important;
    height: 100% !important;
}

.bm-fin-kpi-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: 0.35rem;
}

.bm-fin-kpi-row .bm-kpi-card {
    flex: 1 1 140px;
    min-width: 120px;
}

.bm-financial-chart-wrap {
    position: relative;
    height: min(52vh, 420px);
    min-height: 300px;
    margin-top: 0.35rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    padding: 0.45rem;
}

.bm-financial-chart-wrap canvas {
    width: 100% !important;
    height: 100% !important;
}

/* 财报三页：筛选 + KPI + 图在上，表格在底部且表头 sticky */
.app-main--business-metrics .business-metrics-page > .panel.bm-financial-panel {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.app-main--business-metrics .bm-financial-panel .bm-financial-filters {
    margin-bottom: 0;
    flex-shrink: 0;
}

.app-main--business-metrics .bm-financial-panel .bm-fin-kpi-row {
    margin-top: 0;
    flex-shrink: 0;
}

.app-main--business-metrics .bm-financial-panel .bm-financial-chart-wrap {
    flex-shrink: 0;
    margin-top: 0;
}

.app-main--business-metrics .bm-financial-panel .bm-financial-table-wrap {
    margin-top: auto;
    flex: 1 1 auto;
    min-height: 140px;
    max-height: min(52vh, 600px);
    overflow: auto;
    -webkit-overflow-scrolling: touch;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.app-main--business-metrics .bm-financial-table-wrap .data-table thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    background: #f8fafc;
    box-shadow: 0 1px 0 rgba(15, 23, 42, 0.1);
}

/* 利润表/资产负债表：左关键指标 + 右图表/表格（固定 3:7） */
.app-main--business-metrics .bm-financial-panel--split .bm-fin-split-layout {
    flex: 1 1 auto;
    min-height: 0;
    height: 100%;
    display: grid;
    grid-template-columns: minmax(220px, 3fr) minmax(0, 7fr);
    gap: 0.9rem;
}

.app-main--business-metrics .bm-financial-panel--split .bm-fin-split-left {
    min-width: 0;
    min-height: 0;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: #f8fafc;
    padding: 0.75rem 0.85rem;
    overflow: auto;
}

.app-main--business-metrics .bm-financial-panel--split .bm-fin-split-left .bm-fin-kpi-row {
    margin-top: 0;
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.55rem;
}

.app-main--business-metrics .bm-financial-panel--split .bm-fin-split-left .bm-fin-report-text {
    margin: 0 0 0.65rem;
    font-size: 0.9rem;
    color: var(--text);
}

.app-main--business-metrics .bm-financial-panel--split .bm-fin-split-left .bm-fin-report-text strong {
    font-weight: 700;
}

.app-main--business-metrics .bm-financial-panel--split .bm-fin-split-left .bm-kpi-card {
    min-width: 0;
}

/* 右侧：可选顶部工具条 + 下图表区（图与表固定 1:1 高度，避免复选框参与 fr 分配导致挤压） */
.app-main--business-metrics .bm-financial-panel--split .bm-fin-split-right {
    min-width: 0;
    min-height: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.app-main--business-metrics .bm-financial-panel--split .bm-fin-split-right--income .bm-income-chart-controls,
.app-main--business-metrics .bm-financial-panel--split .bm-fin-split-right--cashflow .bm-cashflow-chart-controls {
    flex-shrink: 0;
}

.app-main--business-metrics .bm-financial-panel--split .bm-fin-split-right-stack {
    flex: 1 1 auto;
    min-height: 0;
    display: grid;
    grid-template-rows: minmax(0, 1fr) minmax(0, 1fr);
    gap: 0.8rem;
}

/* 现金流量表：右侧图:表 = 6:4 */
.app-main--business-metrics .bm-financial-panel--split .bm-fin-split-right-stack.bm-fin-split-right-stack--chart-6-4 {
    grid-template-rows: minmax(0, 6fr) minmax(0, 4fr);
}

.app-main--business-metrics .bm-financial-panel--split .bm-fin-split-right-stack .bm-financial-chart-wrap,
.app-main--business-metrics .bm-financial-panel--split .bm-fin-split-right-stack .bm-financial-table-wrap {
    min-height: 0;
    margin-top: 0;
    height: 100%;
    max-height: none;
}

.app-main--business-metrics .bm-financial-panel--split .bm-fin-split-right-stack .bm-financial-table-wrap {
    overflow: auto;
    -webkit-overflow-scrolling: touch;
}

.app-main--business-metrics .bm-financial-panel--split .bm-financial-table-wrap td.bm-fin-negative {
    color: #b91c1c;
    font-weight: 600;
}

.app-main--business-metrics .bm-financial-panel--split .bm-fin-split-left .bm-kpi-card-value.bm-fin-negative {
    color: #b91c1c;
    font-weight: 600;
}

.app-main--business-metrics .bm-financial-panel--split .bm-income-chart-controls,
.app-main--business-metrics .bm-financial-panel--split .bm-cashflow-chart-controls {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    align-items: center;
    gap: 0.4rem 0.75rem;
    margin: 0;
    font-size: 0.8rem;
    line-height: 1.2;
    color: var(--muted);
}

.app-main--business-metrics .bm-financial-panel--split .bm-income-chart-controls label,
.app-main--business-metrics .bm-financial-panel--split .bm-cashflow-chart-controls label {
    display: inline-flex;
    align-items: center;
    gap: 0.28rem;
    white-space: nowrap;
    user-select: none;
}

.app-main--business-metrics .bm-financial-panel--split .bm-income-chart-controls input[type="checkbox"],
.app-main--business-metrics .bm-financial-panel--split .bm-cashflow-chart-controls input[type="checkbox"] {
    width: 0.85rem;
    height: 0.85rem;
    margin: 0;
}

.app-main--business-metrics .business-metrics-page--health {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.app-main--business-metrics .bm-health-panel {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.app-main--business-metrics .bm-health-panel .bm-financial-filters {
    flex-shrink: 0;
}

.app-main--business-metrics .bm-health-split {
    display: grid;
    grid-template-columns: 3fr 7fr;
    gap: 1rem 1.25rem;
    align-items: stretch;
    min-height: 0;
    flex: 1 1 auto;
}

.app-main--business-metrics .bm-health-split-left {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    min-width: 0;
    min-height: 0;
    overflow: auto;
}

.app-main--business-metrics .bm-health-split-right {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    min-width: 0;
    min-height: 0;
}

.app-main--business-metrics .bm-health-radar-section {
    flex: 7 1 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.app-main--business-metrics .bm-health-table-section {
    flex: 3 1 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.app-main--business-metrics .bm-health-radar-wrap {
    position: relative;
    flex: 1 1 auto;
    min-height: 0;
    border-radius: var(--radius, 10px);
    border: 1px solid var(--border, rgba(15, 23, 42, 0.08));
    padding: 0.5rem;
    background: var(--panel, #fff);
}

.app-main--business-metrics .bm-health-radar-wrap canvas {
    display: block;
    width: 100% !important;
    height: 100% !important;
}

.app-main--business-metrics .bm-health-table-section .bm-financial-table-wrap {
    margin-top: 0;
    max-height: none;
    overflow: visible;
    border: none;
    background: transparent;
    box-shadow: none;
}

.app-main--business-metrics .bm-health-table-section .bm-health-table-wrap {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
    margin: 0;
}

.app-main--business-metrics .bm-health-table-scroll {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
    border-radius: var(--radius, 8px);
    border: 1px solid var(--border, rgba(15, 23, 42, 0.08));
}

.app-main--business-metrics .bm-health-table-scroll .data-table {
    margin: 0;
}

.app-main--business-metrics .bm-health-panel .bm-health-weight-hint {
    margin: auto 0 0;
    padding-top: 0.35rem;
    font-size: 0.78rem;
    line-height: 1.45;
}

.app-main--business-metrics .bm-health-panel .bm-health-note {
    margin: 0;
    font-size: 0.8rem;
}

.app-main--business-metrics .bm-health-total {
    flex-shrink: 0;
    padding: 1rem 1.1rem;
    border-radius: var(--radius, 10px);
    border: 1px solid var(--border, rgba(15, 23, 42, 0.08));
    background: var(--panel-2, rgba(248, 250, 252, 0.9));
}

.app-main--business-metrics .bm-health-total-label {
    margin: 0;
    font-size: 0.85rem;
    color: var(--muted);
}

.app-main--business-metrics .bm-health-total-value {
    margin: 0.35rem 0 0.25rem;
    font-size: 2.35rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.1;
    color: var(--text, #0f172a);
}

.app-main--business-metrics .bm-health-total-grade-row {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.35rem 0.65rem;
    margin: 0.35rem 0 0;
}

.app-main--business-metrics .bm-health-total-grade-label {
    flex-shrink: 0;
    font-size: 0.88rem;
}

.app-main--business-metrics .bm-health-total-grade-text {
    margin-left: auto;
    font-size: 1.15rem;
    font-weight: 700;
}

.app-main--business-metrics .bm-health-total-meta {
    flex: 1 0 100%;
    margin: 0;
    font-size: 0.82rem;
}

/* 等级文字颜色：优深绿 / 良浅绿 / 中黄 / 偏弱橙 / 弱红 */
.app-main--business-metrics .bm-health-tier--you {
    color: #166534;
}

.app-main--business-metrics .bm-health-tier--liang {
    color: #22c55e;
}

.app-main--business-metrics .bm-health-tier--zhong {
    color: #ca8a04;
}

.app-main--business-metrics .bm-health-tier--ruo-mid {
    color: #c2410c;
}

.app-main--business-metrics .bm-health-tier--ruo {
    color: #b91c1c;
}

.app-main--business-metrics .bm-health-tier--na {
    color: var(--muted);
}

.app-main--business-metrics .bm-health-dim-grid {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    flex: 0 1 auto;
}

.app-main--business-metrics .bm-health-dim-card {
    padding: 0.7rem 0.85rem;
    border-radius: var(--radius, 10px);
    border: 1px solid var(--border, rgba(15, 23, 42, 0.08));
    background: var(--panel, #fff);
}

.app-main--business-metrics .bm-health-dim-label {
    margin: 0 0 0.45rem;
    font-size: 0.8rem;
    color: var(--muted);
}

.app-main--business-metrics .bm-health-dim-row {
    display: flex;
    flex-direction: row;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.65rem;
}

.app-main--business-metrics .bm-health-dim-score {
    margin: 0;
    font-size: 1.65rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.15;
}

.app-main--business-metrics .bm-health-dim-grade {
    margin: 0;
    flex-shrink: 0;
    text-align: right;
    font-size: 1.1rem;
    font-weight: 700;
}

.app-main--business-metrics .bm-health-table-score {
    font-weight: 600;
}

.app-main--business-metrics .bm-health-table-grade {
    text-align: right;
    font-weight: 600;
}

.app-main--business-metrics .bm-health-table-grade span {
    font-weight: 700;
}

.app-main--business-metrics .bm-health-table-wrap .bm-health-table-title {
    margin: 0 0 0.45rem;
    font-size: 0.95rem;
    font-weight: 600;
    flex-shrink: 0;
}

/* 小屏：纵向堆叠，仍占满视口剩余高度（由脚本写入 #bm-health-split 高度）；上:下 = 3:7 */
@media (max-width: 960px) {
    .app-main--business-metrics .bm-health-split {
        grid-template-columns: 1fr;
        grid-template-rows: minmax(0, 3fr) minmax(0, 7fr);
    }

    .app-main--business-metrics .bm-health-split-left {
        order: 1;
    }

    .app-main--business-metrics .bm-health-split-right {
        order: 2;
        min-height: 0;
    }

    .app-main--business-metrics .bm-health-radar-section {
        flex: 7 1 0;
        min-height: 0;
    }

    .app-main--business-metrics .bm-health-table-section {
        flex: 3 1 0;
        min-height: 0;
    }
}

.bm-metric-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.bm-metric-tabs .btn.is-active {
    background: var(--accent-dim);
    color: #0f766e;
    border-color: rgba(13, 148, 136, 0.35);
}

.business-metrics-stock-left .bm-change-up {
    color: #b91c1c;
    font-weight: 700;
}

.business-metrics-stock-left .bm-change-down {
    color: #15803d;
    font-weight: 700;
}

.business-metrics-stock-left .bm-change-neutral {
    color: var(--muted);
    font-weight: 600;
}

.business-metrics-stock-right .bm-change-up {
    color: #b91c1c;
    font-weight: 700;
}

.business-metrics-stock-right .bm-change-down {
    color: #15803d;
    font-weight: 700;
}

.business-metrics-stock-right .bm-change-neutral {
    color: var(--muted);
    font-weight: 600;
}

.dashboard-query-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem 1.25rem;
    padding: 0.85rem 1.25rem;
    flex-shrink: 0;
}

.dashboard-query-label {
    font-weight: 600;
    font-size: 0.9rem;
}

.dashboard-period-radios {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem 1.25rem;
    align-items: center;
}

.dashboard-radio-label {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.9rem;
    cursor: pointer;
}

.dashboard-radio-label input {
    margin: 0;
    accent-color: var(--accent);
}

.dashboard-workspace {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    flex: 1;
    min-height: min(420px, 50vh);
    padding: 0;
    overflow: hidden;
}

.dashboard-sidebar {
    width: 272px;
    flex-shrink: 0;
    padding: 1rem 0.75rem 1rem 1rem;
    border-right: 1px solid var(--border);
    background: #fafbfc;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.dash-sidebar-title {
    margin: 0 0 0.65rem;
    font-size: 0.95rem;
    font-weight: 700;
    flex-shrink: 0;
}

.dash-sidebar-scroll {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
}

.dashboard-content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: var(--surface);
}

.dashboard-table-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    padding: 0.85rem 1.25rem 0.5rem;
}

.dashboard-table-scroll {
    flex: 1;
    min-height: 120px;
    overflow: auto;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.dash-tree .ind-tree-btn {
    font-size: 0.86rem;
}

.dash-row {
    cursor: pointer;
    transition: background 0.12s;
}

.dash-row:hover {
    background: #f0fdfa;
}

.dash-row-selected {
    background: #ccfbf1 !important;
    outline: 2px solid var(--accent);
    outline-offset: -2px;
}

.dashboard-chart-panel {
    flex-shrink: 0;
    padding: 1rem 1.25rem 1.25rem;
    border-top: 1px solid var(--border);
    background: #fafbfc;
}

.dashboard-chart-meta {
    margin: 0 0 0.75rem;
    font-size: 0.88rem;
    line-height: 1.45;
    color: var(--muted, #64748b);
}

.dashboard-chart-name {
    color: #2563eb;
    font-weight: 700;
}

.dashboard-chart-canvas-wrap {
    position: relative;
    height: min(320px, 40vh);
    min-height: 220px;
    width: 100%;
}

/* 资讯订阅：三栏热点看板 */
.app-main.app-main--news-dash {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    padding-bottom: env(safe-area-inset-bottom, 0px);
}

.news-dash-page {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-height: 0;
}

/* 订阅热搜模块：顶栏子导航 + 下方看板（对齐系统设置子导航样式） */
.app-main--news-dash .news-module-page {
    gap: 1.25rem;
}

.app-main--news-dash .news-module-page > .settings-subnav {
    flex-shrink: 0;
}

/* 订阅热搜：左 4 热搜列表 / 右 1 订阅申请 */
.news-dash-subscribed-workspace {
    flex: 1;
    display: flex;
    flex-direction: row;
    align-items: stretch;
    gap: 1rem;
    min-height: 0;
}

.news-dash-subscribed-main {
    flex: 4;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-height: 0;
}

.news-dash-subscribed-side {
    flex: 1;
    min-width: 0;
    max-width: 100%;
    align-self: stretch;
    overflow: auto;
}

.news-dash-subscribed-side-head {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.35rem;
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border);
}

.news-dash-tab-panel--subscribed {
    flex: 1;
    min-height: 0;
    min-width: 0;
    max-width: 100%;
    width: 100%;
    box-sizing: border-box;
}

/* 左侧热搜列表：占用标题区下方的剩余高度，为底部分页栏预留空间；溢出裁剪避免盖住「上一页/下一页」 */
.news-dash-tab-panel--subscribed .news-dash-pager {
    flex-shrink: 0;
    margin-top: 0.5rem;
}

.news-dash-subscribed-main .news-dash-table-wrap--main {
    flex: 1 1 0;
    min-height: 0;
    min-width: 0;
    max-width: 100%;
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
    overflow-y: auto;
}

@media (max-width: 960px) {
    .news-dash-subscribed-workspace {
        flex-direction: column;
        flex: 1 1 auto;
        min-height: 0;
    }

    .news-dash-subscribed-main {
        flex: 1 1 auto;
        min-height: 0;
    }

    .news-dash-subscribed-side {
        flex: none;
        width: 100%;
    }

    .news-dash-subscribed-main .news-dash-table-wrap--main {
        min-height: 12rem;
    }
}

/* 热门关键词：左词云 / 右关键词热度（数据均来自 hot_topics_positive_24h） */
.news-dash-page > .news-dash-cloud-heat-workspace {
    flex: 1 1 auto;
    min-height: 0;
}

.news-dash-cloud-heat-workspace {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    gap: 0.65rem;
    min-height: min(400px, 56vh);
}

.news-dash-cloud-main,
.news-dash-heat-side {
    display: flex;
    flex-direction: column;
    min-height: 0;
    min-width: 0;
}

.news-dash-cloud-main {
    flex: 3 1 0;
    align-self: stretch;
}

.news-dash-heat-side {
    flex: 2 1 0;
    overflow: hidden;
    align-self: stretch;
}

.news-dash-heat-side-head {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.35rem;
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}

.news-dash-cloud-heat-workspace .news-dash-heat-side-head {
    margin-bottom: 0.5rem;
    padding-bottom: 0.5rem;
}

.news-dash-heat-title-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.35rem 0.75rem;
    margin-bottom: 0.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}

.news-dash-cloud-title {
    margin-bottom: 0.25rem;
    flex-shrink: 0;
}

.news-dash-cloud-heat-workspace .news-dash-cloud-title.panel-title {
    margin: 0 0 0.25rem;
}

/* 热门关键词页：词云区域无面板内边距 */
.news-dash-cloud-heat-workspace .news-dash-cloud-main.panel,
.news-dash-cloud-heat-workspace .news-dash-heat-side.panel {
    padding: 0;
}

.news-dash-heat-side-title {
    flex-shrink: 0;
}

.news-dash-cloud-heat-workspace .news-dash-heat-side-title {
    margin: 0 0 0.4rem;
}

/* 热门关键词：底部操作栏（分页 + 刷新，刷新靠右） */
.news-heat-bottom-bar {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-top: 0.65rem;
}

.news-heat-bottom-bar > .news-heat-pager {
    margin-right: auto;
}

.news-dash-cloud-lead {
    margin: 0 0 0.75rem;
}

.news-wordcloud-wrap--split {
    flex: 1 1 0;
    min-height: min(260px, 34vh);
    height: auto;
    max-height: none;
    margin: 0;
    padding: 0;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: #fff;
    overflow: hidden;
    box-sizing: border-box;
}

.news-wordcloud-wrap--split canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.news-heat-page-wrap--split {
    flex: 1 1 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    overflow: hidden;
}

/* 热门关键词右侧列表：高度随面板拉伸，不设内部纵向滚动，由分页行数自适应；左右留白 */
.news-heat-list-wrap--split {
    flex: 1 1 0;
    min-height: 0;
    overflow: visible;
    padding: 0 1.25rem;
    box-sizing: border-box;
}

.news-heat-list-wrap--split #news-heat-list {
    min-height: 0;
}

.news-heat-page-wrap--split .news-heat-pager {
    flex-shrink: 0;
    margin-top: 0;
    padding: 0.45rem 1.25rem;
    border-top: 1px solid var(--border);
    background: #f8fafc;
}

@media (max-width: 960px) {
    .news-dash-cloud-heat-workspace {
        flex-direction: column;
        min-height: 0;
    }

    .news-dash-cloud-main,
    .news-dash-heat-side {
        flex: none;
        width: 100%;
    }

    .news-wordcloud-wrap--split {
        min-height: min(280px, 38vh);
        height: min(320px, 40vh);
    }
}

.news-dash-tab-panel {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.news-dash-tab-panel--cloud {
    min-height: min(480px, 56vh);
}

.news-dash-tab-panel--heat {
    min-height: min(400px, 50vh);
}

.news-wordcloud-wrap--page {
    flex: 1;
    min-height: 400px;
    height: min(560px, 52vh);
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    overflow: hidden;
}

.news-heat-page-wrap {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    overflow: hidden;
}

.news-heat-scroll--page {
    flex: 1;
    min-height: 10rem;
    max-height: min(400px, 48vh);
    overflow-x: hidden;
    overflow-y: auto;
    padding: 0.5rem 0.75rem 0.35rem;
    box-sizing: border-box;
}

.news-heat-pager {
    flex-shrink: 0;
    margin-top: 0;
    padding: 0.5rem 0.75rem;
    border-top: 1px solid var(--border);
    background: #f8fafc;
}

.news-dash-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    flex-shrink: 0;
}

.news-dash-heading {
    margin: 0 0 0.35rem;
    font-size: 1.35rem;
    font-weight: 700;
}

.news-dash-lead {
    margin: 0;
    max-width: none;
}

.news-dash-toolbar-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.35rem;
}

.news-dash-table-wrap {
    flex: 1;
    min-height: 120px;
    overflow: auto;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.news-subscribed-table {
    font-size: 0.88rem;
    table-layout: fixed;
    width: 100%;
    max-width: 100%;
}

.news-subscribed-table col.news-sub-col-title {
    width: auto;
}

.news-subscribed-table col.news-sub-col-time {
    width: 11rem;
}

.news-subscribed-table th,
.news-subscribed-table td {
    vertical-align: top;
}

/* 标题列：td 使用 max-width:0（fixed 表）让列宽由表宽约束，从而单行省略 */
.news-subscribed-table .news-sub-title-col {
    min-width: 0;
}

.news-subscribed-table .news-sub-title-cell {
    min-width: 0;
    max-width: 0;
}

.news-subscribed-table .news-sub-time-col,
.news-subscribed-table .news-sub-time-cell {
    width: 11rem;
    max-width: 11rem;
    white-space: nowrap;
    box-sizing: border-box;
    overflow: hidden;
    text-overflow: ellipsis;
}

.news-subscribed-table .news-sub-title-cell {
    overflow: hidden;
    word-break: normal;
}

.news-subscribed-table .news-sub-title-cell .news-sub-link,
.news-subscribed-table .news-sub-title-cell .news-sub-title-plain {
    display: block;
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.news-subscribed-table .news-sub-title-cell .news-sub-link .news-kw-hit,
.news-subscribed-table .news-sub-title-cell .news-sub-title-plain .news-kw-hit {
    white-space: nowrap;
}

.news-sub-link {
    color: inherit;
    text-decoration: none;
}

.news-sub-link:hover {
    text-decoration: underline;
    color: var(--accent);
}

.news-kw-hit {
    background: #dbeafe;
    color: #1e40af;
    font-weight: 600;
    padding: 0 0.1em;
    border-radius: 2px;
}

.news-dash-empty-cell {
    text-align: center;
    padding: 1.5rem 0.5rem;
}

.news-dash-pager {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 0.75rem;
    margin-top: 0.65rem;
    flex-shrink: 0;
}

.news-wordcloud-wrap {
    flex: 1;
    min-height: 220px;
    height: min(320px, 36vh);
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    overflow: hidden;
}

.news-wordcloud-wrap canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.news-heat-scroll {
    flex: 1;
    min-height: 160px;
    max-height: min(480px, 52vh);
    overflow-y: auto;
    padding-right: 0.25rem;
}

.news-heat-ul {
    list-style: none;
    margin: 0;
    padding: 0;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
}

.news-heat-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 2.2fr) auto;
    gap: 0.5rem 0.65rem;
    align-items: center;
    padding: 0.4rem 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.88rem;
    min-width: 0;
}

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

.news-heat-word {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 600;
}

.news-heat-bar-wrap {
    height: 8px;
    min-width: 0;
    width: 100%;
    background: #e2e8f0;
    border-radius: 4px;
    overflow: hidden;
}

.news-heat-bar {
    height: 100%;
    border-radius: 4px;
    background: linear-gradient(90deg, #60a5fa, #2563eb);
    min-width: 2px;
}

.news-heat-num {
    font-variant-numeric: tabular-nums;
    color: var(--muted);
    min-width: 2rem;
    text-align: right;
}

@media (max-width: 1100px) {
    .news-wordcloud-wrap--page {
        min-height: 300px;
        height: min(400px, 45vh);
    }
}

.indicators-workspace.panel {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    min-height: 0;
    padding: 0;
    overflow: hidden;
}

.indicators-sidebar {
    width: 272px;
    flex-shrink: 0;
    padding: 1rem 0.75rem 1rem 1rem;
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: #fafbfc;
}

.ind-sidebar-title {
    margin: 0 0 0.65rem;
    font-size: 0.95rem;
    font-weight: 700;
    flex-shrink: 0;
}

.ind-sidebar-head {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    flex-shrink: 0;
    margin-bottom: 0.4rem;
}

.ind-sidebar-head .ind-sidebar-title {
    margin: 0;
}

.ind-sidebar-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.ind-sidebar-controls .btn {
    padding: 0.28rem 0.55rem;
}

.ind-sidebar-scroll {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding-right: 0.25rem;
}

.indicators-content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: var(--surface);
}

.indicators-toolbar {
    flex-shrink: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.45rem 0.65rem;
    padding: 0.55rem 1rem 0.6rem;
    border-bottom: 1px solid var(--border);
    margin: 0;
    background: #f8fafc;
}

.indicators-stats {
    font-size: 0.88rem;
    white-space: nowrap;
    flex-shrink: 0;
}

.indicators-toolbar .indicators-pager {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.35rem 0.5rem;
    padding: 0;
    flex-shrink: 0;
}

.indicators-search-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.45rem;
    flex: 1 1 12rem;
    min-width: 0;
    justify-content: flex-end;
}

.indicators-search-input {
    flex: 0 1 200px;
    width: 12rem;
    max-width: min(220px, 38vw);
    min-width: 8.5rem;
}

.indicators-table-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    padding: 0.55rem 1rem 0.85rem;
}

.indicators-table-scroll {
    flex: 1 1 auto;
    min-height: 120px;
    min-width: 0;
    overflow-x: auto;
    overflow-y: hidden;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

/* 指标体系表：列宽比例 1:2:1:4:4:1（缺列时按比例合并）；单元格单行省略号 */
.indicators-data-table {
    table-layout: fixed;
    width: 100%;
    min-width: 0;
}

/* 六列：编码·名称·单位·计算逻辑·说明·类型 = 1:2:1:4:4:1（分母 13） */
.indicators-data-table.ind-cols-6 col.ind-col-code,
.indicators-data-table.ind-cols-6 col.ind-col-type {
    width: 7.692307692%;
}

.indicators-data-table.ind-cols-6 col.ind-col-name {
    width: 15.384615385%;
}

.indicators-data-table.ind-cols-6 col.ind-col-unit {
    width: 7.692307692%;
}

.indicators-data-table.ind-cols-6 col.ind-col-logic,
.indicators-data-table.ind-cols-6 col.ind-col-desc {
    width: 30.769230769%;
}

/* 五列无类型：1:2:1:4:4（分母 12） */
.indicators-data-table.ind-cols-5-notype col.ind-col-code,
.indicators-data-table.ind-cols-5-notype col.ind-col-unit {
    width: 8.333333333%;
}

.indicators-data-table.ind-cols-5-notype col.ind-col-name {
    width: 16.666666667%;
}

.indicators-data-table.ind-cols-5-notype col.ind-col-logic,
.indicators-data-table.ind-cols-5-notype col.ind-col-desc {
    width: 33.333333333%;
}

/* 五列无计算逻辑：说明合并双 4 → 1:2:1:8:1（分母 13） */
.indicators-data-table.ind-cols-5-nologic col.ind-col-code,
.indicators-data-table.ind-cols-5-nologic col.ind-col-unit,
.indicators-data-table.ind-cols-5-nologic col.ind-col-type {
    width: 7.692307692%;
}

.indicators-data-table.ind-cols-5-nologic col.ind-col-name {
    width: 15.384615385%;
}

.indicators-data-table.ind-cols-5-nologic col.ind-col-desc {
    width: 61.538461538%;
}

/* 四列：1:2:1:4（分母 8） */
.indicators-data-table.ind-cols-4 col.ind-col-code,
.indicators-data-table.ind-cols-4 col.ind-col-unit {
    width: 12.5%;
}

.indicators-data-table.ind-cols-4 col.ind-col-name {
    width: 25%;
}

.indicators-data-table.ind-cols-4 col.ind-col-desc {
    width: 50%;
}

.indicators-data-table thead th,
.indicators-data-table tbody td {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    vertical-align: middle;
    max-width: 0;
}

.indicators-data-table td.ind-col-code code {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 100%;
}

.indicators-toolbar .indicators-pager[hidden] {
    display: none !important;
}

.indicators-pager-info {
    font-size: 0.88rem;
}

.btn-sm {
    padding: 0.35rem 0.75rem;
    font-size: 0.85rem;
}

.indicators-pager .btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.indicators-empty {
    margin: 0;
}

.indicators-links-panel {
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
    /* 底部条较矮，缩小相对工作台 panel 的内边距 */
    padding: 0.4rem 0.55rem;
}

.ind-links-scroll {
    flex: 1 1 auto;
    min-height: 0;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 0.35rem 0.45rem;
    box-sizing: border-box;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fafbfc;
    container-type: size;
    container-name: ind-links;
}

.ind-links-strip {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 0.65rem;
    align-items: center;
    width: max-content;
    min-height: 0;
    height: 100%;
}

.ind-link-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.28rem;
    width: clamp(4.25rem, 10vw, 7.25rem);
    flex-shrink: 0;
    text-decoration: none;
    color: var(--text);
    text-align: center;
    font-size: 0.74rem;
    line-height: 1.35;
    min-height: 0;
}

.ind-link-card:hover .ind-link-title {
    color: var(--accent);
}

.ind-link-logo-wrap {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    aspect-ratio: 16 / 9;
    /* 随底部区域高度收缩，避免 9:1 布局下 logo 框过高；比例保持 16:9 */
    max-height: min(3.6rem, 9dvh);
    height: auto;
    border-radius: 6px;
    border: 1px solid var(--border);
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
    box-shadow: var(--shadow);
    margin-inline: auto;
}

@supports (height: 1cqh) {
    .ind-link-logo-wrap {
        max-height: min(3.75rem, 72cqh);
    }
}

.ind-link-logo {
    display: block;
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.ind-link-logo-placeholder {
    font-weight: 700;
    font-size: clamp(0.85rem, 2.8vw, 1.1rem);
    color: #0f766e;
    background: var(--accent-dim);
    border: none;
}

.ind-link-title {
    display: block;
    width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ind-tree,
.ind-tree-sub {
    list-style: none;
    margin: 0;
    padding: 0;
}

.ind-tree-sub {
    margin: 0.15rem 0 0.35rem 0.65rem;
    padding-left: 0.5rem;
    border-left: 1px solid var(--border);
}

.ind-tree-node {
    margin-bottom: 0.2rem;
}

.ind-tree-btn {
    display: block;
    width: 100%;
    text-align: left;
    padding: 0.45rem 0.55rem;
    border: none;
    border-radius: 8px;
    background: transparent;
    font: inherit;
    font-size: 0.88rem;
    color: var(--text);
    cursor: pointer;
    line-height: 1.35;
}

.ind-tree-btn:hover {
    background: #e2e8f0;
}

.ind-tree-btn.is-active {
    background: var(--accent-dim);
    color: #0f766e;
    font-weight: 600;
}

.ind-tree-node.is-branch > .ind-tree-btn::after {
    content: "▸";
    float: right;
    color: #94a3b8;
}

.ind-tree-node.is-expanded > .ind-tree-btn::after {
    content: "▾";
}

@media (max-width: 960px) {
    html.app-html-root,
    body.app-body {
        height: auto;
        min-height: 100%;
        overflow-x: hidden;
        overflow-y: auto;
    }

    .app-shell {
        flex-direction: column;
        height: auto;
        min-height: 100vh;
        max-height: none;
        overflow: visible;
    }

    .app-workspace {
        flex: 1 1 auto;
        min-height: 0;
        width: 100%;
        max-width: none;
        overflow: visible;
    }

    .app-main {
        overflow: visible;
        min-height: 0;
    }

    .app-main-scroll {
        overflow: visible;
        flex: 1 1 auto;
        min-height: 0;
    }

    .app-nav {
        width: 100%;
        flex-direction: column;
        flex-wrap: nowrap;
        align-items: stretch;
        height: auto;
        max-height: none;
        overflow-y: visible;
    }

    .app-nav-top {
        display: flex;
        justify-content: center;
    }

    .app-user-pill {
        max-width: 100%;
    }

    .app-nav-links {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        align-content: flex-start;
        width: 100%;
        overflow-y: visible;
        min-height: 0;
    }

    .app-nav-link {
        flex: 0 1 auto;
        min-width: 6.5rem;
    }

    .app-nav-bottom {
        margin-top: 0.75rem;
        padding-top: 0.85rem;
    }

    .app-brand {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        padding-bottom: 0.75rem;
    }

    .app-nav-foot {
        width: 100%;
        padding-top: 0.65rem;
    }

    /* 窄屏：主区通栏，访客条仍贴底 */
    .app-guest-banner {
        left: 0;
        right: 0;
    }

    .grid-2 {
        grid-template-columns: 1fr;
    }

    .grid-2--knowledge {
        grid-template-columns: 1fr;
    }

    .panel--ds-chat .ds-chat {
        min-height: 320px;
    }

    .knowledge-preview-frame-wrap {
        min-height: 12rem;
    }

    .indicators-workspace.panel {
        flex-direction: column;
        min-height: auto;
    }

    .indicators-sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid var(--border);
        max-height: 260px;
    }

    .ind-sidebar-scroll {
        max-height: 200px;
    }

    .dashboard-workspace {
        flex-direction: column;
        min-height: auto;
    }

    .dashboard-sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid var(--border);
        max-height: 240px;
    }

    .dash-sidebar-scroll {
        max-height: 180px;
    }

    .xwlb-day-layout {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto 1fr;
        min-height: auto;
    }

    .xwlb-list-card {
        grid-column: 1;
        grid-row: 1;
    }

    .xwlb-kw-cloud-card {
        grid-column: 1;
        grid-row: 2;
        position: relative;
        height: calc(100vh - var(--xwlb-kw-top-offset, 0px));
        height: calc(100svh - var(--xwlb-kw-top-offset, 0px));
        max-height: calc(100vh - var(--xwlb-kw-top-offset, 0px));
        max-height: calc(100svh - var(--xwlb-kw-top-offset, 0px));
    }

    .xwlb-detail-card {
        grid-column: 1;
        grid-row: 3;
    }

    .xwlb-list-card {
        height: 50vh;
        max-height: 50vh;
    }

    .xwlb-detail-body {
        max-height: min(360px, 48vh);
    }
}

.muted {
    color: var(--muted);
}

.small {
    font-size: 0.85rem;
}

.content-list {
    margin: 0;
    padding-left: 1.1rem;
}

.content-list li {
    margin-bottom: 0.65rem;
}

.carousel {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    background: #e2e8f0;
    min-height: 200px;
}

.carousel-slide {
    display: none;
}

.carousel-slide.is-active {
    display: block;
}

.carousel-slide img {
    width: 100%;
    height: auto;
    max-height: 280px;
    object-fit: cover;
    display: block;
    vertical-align: middle;
}

/* 首页案例轮播：16:9，宽度随主内容区拉满 */
.carousel.carousel-cases {
    min-height: 0;
    width: 100%;
    max-width: 100%;
    aspect-ratio: 16 / 9;
    background: #0f172a;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.carousel-cases .carousel-slide {
    position: absolute;
    inset: 0;
    margin: 0;
}

.carousel-cases .carousel-slide.is-active {
    display: block;
}

.carousel-cases .carousel-slide img {
    width: 100%;
    height: 100%;
    min-height: 0;
    max-height: none;
    object-fit: cover;
    display: block;
}

.carousel-cases .carousel-case-hit {
    display: block;
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    min-height: 0;
    max-height: none;
    color: inherit;
    text-decoration: none;
    outline: none;
}

.carousel-case-hit:focus-visible {
    box-shadow: inset 0 0 0 3px rgba(94, 234, 212, 0.8);
}

.carousel-case-hit:hover .carousel-case-caption {
    background: linear-gradient(transparent, rgba(15, 23, 42, 0.92));
}

.carousel-case-hit-static {
    cursor: default;
}

.carousel-case-caption {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 2.25rem 1.25rem 1rem;
    font-size: 1.05rem;
    font-weight: 600;
    color: #f8fafc;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.65);
    background: linear-gradient(transparent, rgba(15, 23, 42, 0.85));
    pointer-events: none;
}

.carousel-case-no-link {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    font-size: 0.75rem;
    padding: 0.2rem 0.5rem;
    border-radius: 6px;
    background: rgba(15, 23, 42, 0.55);
    pointer-events: none;
}

.carousel-dots {
    display: flex;
    gap: 6px;
    justify-content: center;
    margin-top: 0.75rem;
}

.carousel-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #cbd5e1;
    border: none;
    padding: 0;
    cursor: pointer;
}

.carousel-dot.is-active {
    background: var(--accent);
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1rem;
}

.card {
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 1rem;
    background: #fafbfc;
}

.card-title {
    margin: 0 0 0.35rem;
    font-size: 1rem;
}

.card-desc {
    margin: 0;
    font-size: 0.88rem;
    color: var(--muted);
}

.tag {
    display: inline-block;
    font-size: 0.72rem;
    padding: 2px 8px;
    border-radius: 6px;
    background: var(--accent-dim);
    color: #0f766e;
    margin-bottom: 0.35rem;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
}

.data-table th,
.data-table td {
    text-align: left;
    padding: 0.55rem 0.65rem;
    border-bottom: 1px solid var(--border);
}

.data-table th {
    font-weight: 600;
    color: var(--muted);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.data-table-compact td {
    font-size: 0.85rem;
}

/* 研究报告页文档列表（旧版三列）；当前表格见 .knowledge-reports-table col 1:8:5 */
.knowledge-list-table {
    table-layout: fixed;
    width: 100%;
}

.knowledge-list-table col.knowledge-col-title {
    width: 75%;
}

.knowledge-list-table col.knowledge-col-status {
    width: 12.5%;
}

.knowledge-list-table col.knowledge-col-views {
    width: 12.5%;
}

.knowledge-list-table thead th {
    text-align: center;
}

.knowledge-list-table td:nth-child(2),
.knowledge-list-table td:nth-child(3) {
    text-align: center;
    white-space: nowrap;
}

.table-wrap {
    overflow-x: auto;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* 行业资讯：主区铺满；表格外层不单独出现横/纵滚动条（随整页 app-main-scroll 滚动） */
.app-main.app-main--industry-news {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.app-main--industry-news .industry-news-panel {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: none;
}

.app-main--industry-news .industry-news-toolbar {
    flex-shrink: 0;
    width: 100%;
    min-width: 0;
}

.app-main--industry-news .industry-news-panel > .app-flash {
    flex-shrink: 0;
}

.app-main--industry-news .industry-news-page {
    gap: 1.25rem;
}

/* 行业资讯顶栏：左侧子页签 + 右侧「切换」+ 固定宽度下拉（对齐单个导航按钮约宽） */
.settings-subnav.industry-news-topnav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem 0.75rem;
}

.industry-news-subnav-links {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 0.5rem;
    flex: 1 1 auto;
    min-width: 0;
}

.industry-news-subnav-switch {
    display: inline-flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.4rem 0.5rem;
    flex-shrink: 0;
    margin-left: auto;
}

.industry-news-switch-text {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--muted);
    white-space: nowrap;
}

/* 与 .settings-subnav-link 视觉高度接近，宽度固定为单颗导航按钮量级 */
.industry-news-ctx-select {
    width: var(--industry-news-nav-select-width, 9.75rem);
    min-width: var(--industry-news-nav-select-width, 9.75rem);
    max-width: var(--industry-news-nav-select-width, 9.75rem);
    box-sizing: border-box;
    margin: 0;
    padding: 0.42rem 0.55rem;
    font-size: 0.9rem;
    line-height: 1.25;
    font-family: inherit;
    color: var(--text);
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 8px;
    cursor: pointer;
    overflow: hidden;
    text-overflow: ellipsis;
}

.industry-news-ctx-select:focus {
    outline: none;
    border-color: rgba(13, 148, 136, 0.55);
    box-shadow: 0 0 0 2px rgba(13, 148, 136, 0.15);
}

.app-main--industry-news .industry-news-page > .settings-subnav,
.app-main--industry-news .industry-news-page > .industry-news-subnav {
    flex-shrink: 0;
}

.industry-news-empty-hint {
    margin: 0 0 0.5rem;
    line-height: 1.6;
    max-width: 42rem;
}

.app-main--industry-news .industry-news-table-wrap {
    flex: 1 1 auto;
    min-height: 0;
    min-width: 0;
    width: 100%;
    overflow-x: hidden;
    overflow-y: auto;
}

.app-main--industry-news .industry-news-pager {
    flex-shrink: 0;
}

.industry-news-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 0.65rem;
    margin-bottom: 1rem;
}

.industry-news-search-input {
    flex: 1 1 8rem;
    min-width: 0;
}

.industry-news-pager {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 0.75rem;
    margin-top: 1rem;
}

.industry-news-title-link {
    color: #0f766e;
    font-weight: 600;
    text-decoration: none;
}

.industry-news-title-link:hover {
    text-decoration: underline;
    color: #0d9488;
}

/* 行业资讯表：固定布局；时间列定宽；标题列占剩余宽度并单行省略 */
.industry-news-table {
    table-layout: fixed;
    width: 100%;
    min-width: 0;
}

.industry-news-col-title {
    width: 58.0645%;
}

.industry-news-col-keywords {
    width: 29.0323%;
}

.industry-news-col-time {
    width: 9.6774%;
}

.industry-news-col-seq {
    width: 3.2258%;
}

.industry-news-table thead th {
    text-align: center;
}

.industry-news-td-seq,
.industry-news-td-keywords,
.industry-news-td-time {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    vertical-align: middle;
}

.industry-news-td-seq {
    text-align: center;
}

.industry-news-td-title {
    vertical-align: middle;
    min-width: 0;
}

.industry-news-td-title {
    overflow: hidden;
}

.industry-news-td-title .industry-news-title-link,
.industry-news-td-title .industry-news-title-text {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    min-width: 0;
}

.industry-news-keyword-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem 0.3rem;
    align-items: center;
}

.industry-news-keyword-chip {
    display: inline-flex;
    align-items: center;
    max-width: 100%;
    padding: 0.12rem 0.45rem;
    border: 1px solid rgba(13, 148, 136, 0.28);
    border-radius: 999px;
    background: rgba(13, 148, 136, 0.08);
    color: #0f766e;
    font-size: 0.78rem;
    line-height: 1.35;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 分析黑板报 */
.app-main.app-main--blackboard {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.blackboard-page {
    gap: 1.1rem;
}

.blackboard-workspace {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 3fr);
    gap: 1rem;
    flex: 1;
    min-height: 0;
}

.blackboard-tags-panel {
    min-width: 0;
    overflow: auto;
}

.blackboard-tag-list {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    min-width: 0;
}

.blackboard-tag-link {
    display: block;
    max-width: 100%;
    padding: 0.35rem 0.5rem;
    border-radius: 6px;
    color: var(--text);
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.blackboard-tag-link:hover {
    background: #f1f5f9;
}

.blackboard-tag-link.is-active {
    background: var(--accent-dim);
    color: #0f766e;
    font-weight: 600;
}

.blackboard-card-panel {
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.blackboard-card-controls {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.55rem 0.75rem;
}

.blackboard-card-actions {
    display: inline-flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.25rem;
    flex-shrink: 0;
}

/* 导出卡片：下拉两种 PDF 模式（由浏览器打印对话框另存为 PDF） */
.blackboard-export-menu {
    position: relative;
    flex-shrink: 0;
}

.blackboard-export-menu__summary {
    list-style: none;
    cursor: pointer;
}

.blackboard-export-menu__summary::-webkit-details-marker {
    display: none;
}

.blackboard-export-menu__panel {
    position: absolute;
    top: calc(100% + 4px);
    right: 0;
    z-index: 20;
    min-width: 15.5rem;
    padding: 0.35rem 0;
    margin: 0;
    background: var(--panel, #fff);
    border: 1px solid var(--border, rgba(148, 163, 184, 0.35));
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
}

.blackboard-export-menu:not([open]) .blackboard-export-menu__panel {
    display: none;
}

.blackboard-export-menu__item {
    display: block;
    width: 100%;
    padding: 0.45rem 0.75rem;
    border: 0;
    background: transparent;
    font: inherit;
    font-size: 0.875rem;
    text-align: left;
    color: var(--text, #334155);
    cursor: pointer;
}

.blackboard-export-menu__item:hover:not(:disabled) {
    background: rgba(15, 23, 42, 0.06);
}

.blackboard-export-menu__item:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.blackboard-export-menu.is-pdf-exporting .blackboard-export-menu__summary {
    cursor: wait;
    opacity: 0.75;
    pointer-events: none;
}

.bb-category-export-bar {
    margin-top: 0.65rem;
    padding: 0.55rem 0.65rem;
    border-radius: 10px;
    border: 1px solid rgba(251, 146, 60, 0.28);
    background: rgba(255, 252, 248, 0.92);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.75) inset;
}

.bb-category-export-bar__inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.45rem 0.65rem;
}

.bb-category-export-meter {
    flex: 1 1 120px;
    min-width: 80px;
    height: 8px;
    border-radius: 999px;
    background: rgba(251, 146, 60, 0.18);
    overflow: hidden;
}

.bb-category-export-meter--busy .bb-category-export-meter-fill {
    animation: bb-category-export-fill-busy 1s ease-in-out infinite;
}

@keyframes bb-category-export-fill-busy {
    0%,
    100% {
        opacity: 1;
        filter: brightness(1);
    }

    50% {
        opacity: 0.88;
        filter: brightness(1.15);
    }
}

.bb-category-export-meter-fill {
    height: 100%;
    width: 0%;
    border-radius: inherit;
    background: linear-gradient(90deg, #ea580c 0%, #fb923c 55%, #fdba74 100%);
    transition: width 0.18s ease;
}

.bb-category-export-bar__status {
    flex: 1 1 180px;
    margin: 0;
    min-width: 0;
    font-size: 0.8rem;
    font-weight: 600;
    line-height: 1.35;
    color: #c2410c;
}

.bb-category-export-bar__cancel {
    flex: 0 0 auto;
    margin-left: auto;
}

.blackboard-card-print {
    flex-shrink: 0;
}

.blackboard-card-copy {
    flex-shrink: 0;
}

.blackboard-card-delete {
    flex-shrink: 0;
    color: #b91c1c;
}

/* 非「我的读书笔记」时脚本会加 [hidden]；用 !important 防止 .btn 等把按钮重新显示出来 */
button.blackboard-card-delete[hidden],
#bb-delete-highlight[hidden] {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

.blackboard-card-delete:hover:not(:disabled) {
    color: #991b1b;
    background: rgba(185, 28, 28, 0.08);
}

.blackboard-card-delete:disabled {
    color: inherit;
    opacity: 0.45;
}

.blackboard-mode-switch {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.6rem 0.8rem;
}

.blackboard-mode-switch input[type="range"] {
    width: 8.5rem;
    vertical-align: middle;
    margin: 0 0.35rem;
}

.blackboard-pager {
    display: inline-flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.45rem 0.6rem;
}

.blackboard-auto-progress {
    flex: 1 1 100%;
    height: 0.28rem;
    border-radius: 999px;
    background: rgba(148, 163, 184, 0.25);
    overflow: hidden;
    display: none;
}

.blackboard-auto-progress.is-active {
    display: block;
}

.blackboard-auto-progress-bar {
    --bb-auto-progress: 0%;
    display: block;
    width: var(--bb-auto-progress);
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #f97316 0%, #fb923c 45%, #fdba74 100%);
    transition: width 0.08s linear;
}

.blackboard-card-stack {
    position: relative;
    flex: 1 1 auto;
    min-height: 280px;
    min-width: 0;
    display: flex;
    flex-direction: column;
    perspective: min(1400px, 98vw);
    perspective-origin: 52% 78%;
}

.blackboard-card-stack.is-empty .blackboard-card-arrow-layer {
    display: none;
}

.blackboard-book-scene {
    position: relative;
    flex: 1 1 auto;
    min-height: 300px;
    min-width: 0;
    transform-style: preserve-3d;
}

.blackboard-book-under {
    position: absolute;
    inset: 0;
    border-radius: 14px;
    background: linear-gradient(
        165deg,
        rgba(255, 247, 237, 0.96) 0%,
        rgba(254, 215, 170, 0.55) 42%,
        rgba(251, 146, 60, 0.35) 72%,
        rgba(234, 88, 12, 0.2) 100%
    );
    transform: translateZ(-38px) translateY(16px) scale(0.92);
    box-shadow:
        0 3px 0 rgba(255, 255, 255, 0.5) inset,
        0 26px 52px rgba(154, 52, 18, 0.14),
        0 10px 28px rgba(234, 88, 12, 0.1);
    pointer-events: none;
}

.blackboard-card-stack.is-empty .blackboard-book-under {
    opacity: 0.45;
    transform: translateZ(-20px) translateY(8px) scale(0.96);
}

@keyframes bb-card-silk-breathe {
    0% {
        filter: saturate(1) brightness(1);
    }

    40% {
        filter: saturate(1.14) brightness(1.06);
    }

    100% {
        filter: saturate(1.04) brightness(1.02);
    }
}

.blackboard-card-pivot {
    position: relative;
    height: 100%;
    min-height: 300px;
    transform-style: preserve-3d;
    transition: transform 0.24s cubic-bezier(0.22, 0.78, 0.24, 1), opacity 0.24s ease;
    will-change: transform;
}

.blackboard-card-pivot.bb-fly-out-left {
    transform: translateX(-8%) scale(0.986);
}

.blackboard-card-pivot.bb-fly-out-right {
    transform: translateX(8%) scale(0.986);
}

.blackboard-card-pivot.bb-fly-in-left {
    transform: translateX(-5%) scale(0.992);
    opacity: 0.45;
}

.blackboard-card-pivot.bb-fly-in-right {
    transform: translateX(5%) scale(0.992);
    opacity: 0.45;
}

.blackboard-card-pivot.bb-fly-out-left .blackboard-card,
.blackboard-card-pivot.bb-fly-out-right .blackboard-card {
    filter: saturate(1.04) brightness(1.04);
}

.blackboard-card-pivot.bb-fly-out-left .blackboard-card-curl,
.blackboard-card-pivot.bb-fly-out-right .blackboard-card-curl,
.blackboard-card-pivot.bb-fly-in-left .blackboard-card-curl,
.blackboard-card-pivot.bb-fly-in-right .blackboard-card-curl {
    opacity: 0 !important;
}

/* 整体随右下角为轴轻微带起，主视觉交给 .blackboard-card-curl 的 3D 卷角 */
.blackboard-card-pivot.bb-flip-out-next {
    transform-origin: 100% 100%;
    transform: rotate3d(1, 0.72, 0.1, -11deg) translate3d(-0.4%, -0.6%, -8px) scale(0.997);
}

.blackboard-card-pivot.bb-flip-out-prev {
    transform-origin: 0% 100%;
    transform: rotate3d(-1, 0.72, 0.1, 11deg) translate3d(0.4%, -0.6%, -8px) scale(0.997);
}

.blackboard-card-pivot.bb-start-next {
    transform-origin: 100% 100%;
    transform: rotate3d(0.82, 0.58, 0.08, 9deg) translate3d(-0.2%, -0.35%, -4px) scale(0.9985);
    transition: none !important;
}

.blackboard-card-pivot.bb-start-prev {
    transform-origin: 0% 100%;
    transform: rotate3d(-0.82, 0.58, 0.08, -9deg) translate3d(0.2%, -0.35%, -4px) scale(0.9985);
    transition: none !important;
}

/* 翻页全程：丝绸光泽 + 柔边高光，整体偏柔、偏透 */
.blackboard-card-pivot.bb-flip-active .blackboard-card:not(.blackboard-card--placeholder) {
    animation: bb-card-silk-breathe 0.88s cubic-bezier(0.28, 0.82, 0.32, 1) 1;
    opacity: 0.97;
    background:
        radial-gradient(ellipse 125% 85% at 28% 18%, rgba(255, 255, 255, 0.72), transparent 58%),
        radial-gradient(ellipse 100% 70% at 92% 88%, rgba(254, 215, 170, 0.45), transparent 52%),
        linear-gradient(
            158deg,
            rgba(255, 255, 255, 0.94) 0%,
            rgba(255, 248, 240, 0.9) 38%,
            rgba(254, 231, 208, 0.82) 72%,
            rgba(254, 200, 154, 0.45) 100%
        );
    border-color: rgba(251, 146, 60, 0.2);
    box-shadow:
        0 2px 0 rgba(255, 255, 255, 0.92) inset,
        0 6px 28px rgba(251, 146, 60, 0.09),
        0 22px 56px rgba(234, 88, 12, 0.07);
}

.blackboard-card-pivot.bb-flip-no-transition {
    transition: none !important;
}

.blackboard-card {
    flex: 1 1 auto;
    min-height: 300px;
    height: 100%;
    min-width: 0;
    display: grid;
    align-content: center;
    justify-items: stretch;
    border: 1px solid rgba(251, 146, 60, 0.22);
    border-radius: 14px;
    background: linear-gradient(
        156deg,
        rgba(255, 255, 255, 0.97) 0%,
        rgba(255, 247, 237, 0.94) 35%,
        rgba(254, 231, 208, 0.88) 70%,
        rgba(254, 215, 170, 0.55) 100%
    );
    /* 预留两侧安全区，避免被翻页按钮遮挡文本 */
    padding: 1.75rem clamp(3.6rem, 7vw, 5.2rem);
    line-height: 1.6;
    font-size: clamp(2.05rem, 4.5vw, 3.25rem);
    font-weight: 600;
    color: #c2410c;
    text-align: justify;
    text-justify: inter-ideograph;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    word-break: break-word;
    overflow: auto;
    cursor: pointer;
    opacity: 1;
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.88) inset,
        0 2px 6px rgba(154, 52, 18, 0.06),
        0 14px 36px rgba(234, 88, 12, 0.1);
    transition:
        box-shadow 0.45s cubic-bezier(0.26, 0.85, 0.32, 1),
        opacity 0.5s cubic-bezier(0.26, 0.85, 0.32, 1),
        background 0.5s cubic-bezier(0.26, 0.85, 0.32, 1),
        border-color 0.4s ease,
        filter 0.5s cubic-bezier(0.26, 0.85, 0.32, 1);
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    position: relative;
    transform-style: preserve-3d;
}

.blackboard-card-pivot.bb-flip-active .blackboard-card:not(.blackboard-card--placeholder) {
    overflow: visible;
}

/* 翻页时的纸背遮挡层：在页间切换时提供连续视觉过渡 */
.blackboard-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    opacity: 0;
    z-index: 3;
    background:
        linear-gradient(130deg, rgba(255, 255, 255, 0.18) 0%, rgba(251, 146, 60, 0.16) 48%, rgba(154, 52, 18, 0.2) 100%),
        radial-gradient(ellipse 110% 70% at 70% 110%, rgba(125, 32, 9, 0.22), transparent 64%);
    transition: opacity 0.28s ease;
}

.blackboard-card-pivot.bb-flip-active .blackboard-card:not(.blackboard-card--placeholder)::before {
    opacity: 0.24;
}

.blackboard-card-pivot.bb-start-next .blackboard-card:not(.blackboard-card--placeholder)::before,
.blackboard-card-pivot.bb-start-prev .blackboard-card:not(.blackboard-card--placeholder)::before {
    opacity: 0.56;
}

.blackboard-card-text {
    grid-column: 1;
    grid-row: 1;
    min-width: 0;
    align-self: stretch;
    justify-self: stretch;
    position: relative;
    z-index: 1;
}

.blackboard-card.blackboard-card--book-highlight {
    display: flex;
    align-items: stretch;
    align-content: start;
    text-align: left;
    color: #9a3412;
}

.blackboard-card--book-highlight .blackboard-card-text {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
    gap: 0.35rem;
    white-space: normal;
    height: auto;
}

.blackboard-card-note-meta-line {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.6rem;
    flex-wrap: nowrap;
    min-width: 0;
}

.blackboard-card-note-head {
    display: inline-flex;
    align-self: flex-start;
    padding: 0.1rem 0.55rem;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 700;
    color: #0f766e;
    background: rgba(13, 148, 136, 0.12);
}

.blackboard-card-note-book {
    min-width: 0;
    flex: 1 1 auto;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 0.8rem;
    font-weight: 700;
    color: #7c2d12;
}

.blackboard-card-note-time {
    flex-shrink: 0;
    font-size: 0.8rem;
    color: #64748b;
}

.blackboard-card-note-body {
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.blackboard-card-note-content-wrap {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    align-items: center;
}

/* 右下角（或左下）三角卷角：3D 向左上掀起，丝绸叠光 */
.blackboard-card-curl {
    position: absolute;
    right: 0;
    left: auto;
    bottom: 0;
    width: 46%;
    height: 46%;
    z-index: 4;
    pointer-events: none;
    transform-origin: 100% 100%;
    transform-style: preserve-3d;
    border-bottom-right-radius: 14px;
    clip-path: polygon(100% 0, 100% 100%, 0 100%);
    opacity: 0;
    transform: perspective(560px) rotateX(0deg) rotateY(0deg) translateZ(0) scale(1);
    transition:
        transform 0.88s cubic-bezier(0.26, 0.88, 0.29, 1),
        opacity 0.55s cubic-bezier(0.33, 1, 0.53, 1),
        filter 0.65s cubic-bezier(0.28, 0.82, 0.32, 1);
    background:
        linear-gradient(122deg, rgba(255, 255, 255, 0.75) 0%, rgba(255, 243, 230, 0.25) 38%, transparent 55%),
        linear-gradient(298deg, rgba(251, 146, 60, 0.18) 0%, rgba(254, 215, 170, 0.62) 42%, rgba(255, 255, 255, 0.82) 76%);
    box-shadow:
        -10px -8px 36px rgba(234, 88, 12, 0.12),
        -4px -2px 16px rgba(255, 255, 255, 0.45) inset,
        0 0 28px rgba(255, 237, 213, 0.35) inset;
    filter: saturate(1.05) brightness(1);
}

.blackboard-card-pivot.bb-flip-no-transition .blackboard-card-curl {
    transition: none !important;
}

.blackboard-card-pivot.bb-flip-active.bb-flip-out-next .blackboard-card:not(.blackboard-card--placeholder) .blackboard-card-curl {
    opacity: 1;
    transform: perspective(560px) rotateX(28deg) rotateY(-56deg) translateZ(36px) scale(1.03);
    filter: saturate(1.18) brightness(1.08);
}

.blackboard-card-pivot.bb-flip-active.bb-flip-out-prev .blackboard-card:not(.blackboard-card--placeholder) .blackboard-card-curl {
    right: auto;
    left: 0;
    transform-origin: 0% 100%;
    border-bottom-right-radius: 0;
    border-bottom-left-radius: 14px;
    clip-path: polygon(0 0, 100% 100%, 0 100%);
    opacity: 1;
    transform: perspective(560px) rotateX(28deg) rotateY(56deg) translateZ(36px) scale(1.03);
    filter: saturate(1.18) brightness(1.08);
}

.blackboard-card-pivot.bb-start-next .blackboard-card:not(.blackboard-card--placeholder) .blackboard-card-curl {
    opacity: 1;
    transform: perspective(560px) rotateX(20deg) rotateY(42deg) translateZ(18px) scale(1.015);
    filter: saturate(1.12) brightness(1.05);
}

.blackboard-card-pivot.bb-start-prev .blackboard-card:not(.blackboard-card--placeholder) .blackboard-card-curl {
    right: auto;
    left: 0;
    transform-origin: 0% 100%;
    border-bottom-right-radius: 0;
    border-bottom-left-radius: 14px;
    clip-path: polygon(0 0, 100% 100%, 0 100%);
    opacity: 1;
    transform: perspective(560px) rotateX(20deg) rotateY(-42deg) translateZ(18px) scale(1.015);
    filter: saturate(1.12) brightness(1.05);
}

.blackboard-card--placeholder .blackboard-card-curl {
    display: none;
}

@supports (align-content: safe center) {
    .blackboard-card {
        align-content: safe center;
    }
}

.blackboard-card--placeholder {
    color: #64748b !important;
    font-size: clamp(1rem, 2.2vw, 1.2rem);
    font-weight: 500;
    text-align: center;
    text-justify: auto;
    opacity: 1 !important;
    background: linear-gradient(160deg, #f8fafc 0%, #f1f5f9 100%) !important;
    border-color: rgba(148, 163, 184, 0.35) !important;
}

.blackboard-book-scene:hover .blackboard-card:not(.blackboard-card--placeholder) {
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.92) inset,
        0 4px 10px rgba(154, 52, 18, 0.07),
        0 20px 44px rgba(234, 88, 12, 0.12);
}

.blackboard-card:focus {
    outline: none;
    border-color: rgba(234, 88, 12, 0.45);
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.85) inset,
        0 0 0 2px rgba(251, 146, 60, 0.28),
        0 14px 36px rgba(234, 88, 12, 0.12);
}

.blackboard-card-arrow-layer {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 0.45rem;
    z-index: 2;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.2s ease;
}

@media (max-width: 640px) {
    .blackboard-card {
        padding: 1.35rem 2.9rem;
    }
}

.blackboard-card-stack:hover .blackboard-card-arrow-layer {
    opacity: 1;
}

.blackboard-card-arrow {
    pointer-events: auto;
    width: 2.75rem;
    height: 2.75rem;
    border: none;
    border-radius: 50%;
    font-size: 1.85rem;
    line-height: 1;
    color: #ea580c;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 2px 12px rgba(234, 88, 12, 0.15);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease, transform 0.15s ease;
}

.blackboard-card-arrow:hover:not(:disabled) {
    background: #fff;
    transform: scale(1.06);
}

.blackboard-card-arrow:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

@media (prefers-reduced-motion: reduce) {
    .blackboard-card-pivot {
        transition: none !important;
    }

    .blackboard-card-pivot.bb-flip-active .blackboard-card:not(.blackboard-card--placeholder) {
        animation: none !important;
    }

    .blackboard-card-curl {
        transition: none !important;
    }

    .blackboard-auto-progress-bar {
        transition: none !important;
    }
}

@media (max-width: 960px) {
    .blackboard-workspace {
        grid-template-columns: 1fr;
    }
}

/* 实时舆情：左分类 / 右列表 */
.news-live-page {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-height: 0;
}

.news-live-workspace {
    flex: 1;
    display: flex;
    flex-direction: row;
    align-items: stretch;
    gap: 1rem;
    min-height: 0;
}

.news-live-cats {
    flex: 0 0 12.5rem;
    max-width: 100%;
    align-self: stretch;
    overflow: auto;
}

.news-live-cats-head {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text);
}

.news-live-cat-list {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.news-live-cat {
    display: block;
    padding: 0.35rem 0.5rem;
    border-radius: 6px;
    color: var(--text);
    text-decoration: none;
    font-size: 0.9rem;
}

.news-live-cat:hover {
    background: var(--surface-hover, rgba(0, 0, 0, 0.04));
}

.news-live-cat.is-active {
    background: rgba(15, 118, 110, 0.12);
    color: #0f766e;
    font-weight: 600;
}

.news-live-main {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.news-live-table-wrap {
    flex: 1;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.news-live-table {
    table-layout: fixed;
    width: 100%;
    flex: 0 0 auto;
}

.news-live-table thead th {
    text-align: center;
}

/* 序号 : 关键词 : 综合热度 : 快照时间 = 1 : 12 : 3 : 3 */
.news-live-table col.news-live-col-seq {
    width: 5.2631579%;
}

.news-live-table col.news-live-col-kw {
    width: 63.1578947%;
}

.news-live-table col.news-live-col-heat {
    width: 15.7894737%;
}

.news-live-table col.news-live-col-snap {
    width: 15.7894737%;
}

.news-live-td-seq {
    text-align: center;
    white-space: nowrap;
}

.news-live-td-kw {
    max-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.news-live-td-heat {
    vertical-align: middle;
}

/* 快照时间：单元格内横向居中（覆盖 .data-table 默认左对齐） */
.news-live-table thead th:nth-child(4),
.news-live-table tbody td.news-live-td-snap {
    text-align: center;
    vertical-align: middle;
    white-space: nowrap;
}

.news-live-heat-bar-wrap {
    height: 0.5rem;
    border-radius: 4px;
    background: var(--border, rgba(0, 0, 0, 0.08));
    overflow: hidden;
    min-width: 4rem;
}

.news-live-heat-bar {
    height: 100%;
    border-radius: 4px;
    background: linear-gradient(90deg, #14b8a6, #0d9488);
    min-width: 0;
    transition: width 0.2s ease;
}

.news-live-pager {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem 0.75rem;
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border);
    flex-shrink: 0;
}

.news-live-pager-actions {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.news-live-kw-link {
    color: #0f766e;
    font-weight: 500;
    text-decoration: none;
}

.news-live-kw-link:hover {
    text-decoration: underline;
}

@media (max-width: 960px) {
    .news-live-workspace {
        flex-direction: column;
    }

    .news-live-cats {
        flex: none;
        width: 100%;
    }
}

.news-live-table td {
    vertical-align: top;
}

.link-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.link-list li {
    margin-bottom: 0.5rem;
}

.link-list a {
    color: #0f766e;
    font-weight: 500;
}

.tabs-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.tab-pill {
    padding: 0.45rem 0.9rem;
    border-radius: 999px;
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text);
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 500;
}

.tab-pill.is-active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.inline-form {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
    align-items: center;
}

.news-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.news-item {
    display: flex;
    gap: 0.75rem;
    padding: 0.65rem 0;
    border-bottom: 1px solid var(--border);
}

.news-rank {
    font-weight: 700;
    color: var(--accent);
    min-width: 1.5rem;
    font-size: 0.9rem;
}

.news-link {
    color: #0f172a;
    font-weight: 500;
    text-decoration: none;
}

.news-link:hover {
    color: var(--accent);
}

.pager {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 1rem;
    flex-wrap: wrap;
}

.stack-form {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.narrow-form {
    max-width: 420px;
}

.field-label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--muted);
}

.field-input {
    width: 100%;
    padding: 0.55rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.95rem;
}

.field-input-inline {
    width: auto;
    min-width: 200px;
    flex: 1;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    text-decoration: none;
}

.btn-primary {
    background: var(--accent);
    color: #fff;
}

.btn-primary:hover {
    filter: brightness(1.05);
}

.btn-secondary {
    background: #e2e8f0;
    color: var(--text);
}

.btn-ghost {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text);
}

.btn-block {
    width: 100%;
    margin-top: 0.5rem;
}

.kw-chips {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.kw-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.65rem;
    background: #f1f5f9;
    border-radius: 999px;
    font-size: 0.85rem;
}

.link-btn {
    background: none;
    border: none;
    color: var(--danger);
    cursor: pointer;
    font-size: 1.1rem;
    line-height: 1;
    padding: 0 0.15rem;
}

form.inline {
    display: inline;
}

.xwlb-filter-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 0.75rem 1rem;
    margin-bottom: 1rem;
}

.xwlb-filter-field {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    min-width: 0;
}

.xwlb-date-input {
    min-width: 11rem;
}

.xwlb-search-inline {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.5rem 0.65rem;
    flex: 0 0 auto;
    min-width: 0;
}

.xwlb-q-input {
    flex: 0 1 11rem;
    min-width: 9rem;
}

.xwlb-list-topbar {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0;
    padding: 0.65rem 0.75rem;
    border-bottom: 1px solid var(--border);
    background: #f8fafc;
    flex-shrink: 0;
}

.xwlb-list-topbar .xwlb-list-status {
    padding: 0;
    border-bottom: none;
    background: transparent;
}

.xwlb-search-out--inline {
    margin-bottom: 0.75rem;
}

.xwlb-search-out--inline:empty {
    display: none;
}

/* 第一行：左「列表卡」与右「词云卡」整体均为 50vh（含状态条/标题/按钮等），底部对齐；第二行：文稿详情通栏 */
.xwlb-day-layout {
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
    grid-template-rows: auto 1fr;
    gap: 1rem;
    align-items: start;
    min-height: 0;
}

.xwlb-list-card {
    grid-column: 1;
    grid-row: 1;
    min-width: 0;
    min-height: 0;
    height: 50vh;
    max-height: 50vh;
    overflow: hidden;
    box-sizing: border-box;
}

.xwlb-kw-cloud-card {
    grid-column: 2;
    grid-row: 1 / span 2;
    align-self: start;
    display: flex;
    flex-direction: column;
    min-width: 0;
    min-height: 0;
    position: relative;
    height: calc(100vh - var(--xwlb-kw-top-offset, 0px));
    height: calc(100svh - var(--xwlb-kw-top-offset, 0px));
    max-height: calc(100vh - var(--xwlb-kw-top-offset, 0px));
    max-height: calc(100svh - var(--xwlb-kw-top-offset, 0px));
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    padding: 0.85rem 1rem 1rem;
    box-sizing: border-box;
    overflow: hidden;
}

.xwlb-detail-card {
    grid-column: 1;
    grid-row: 2;
    min-width: 0;
    min-height: min(320px, 45vh);
}

.xwlb-kw-mode-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: 0.45rem;
    flex-shrink: 0;
}

.xwlb-kw-cloud-hint {
    margin: 0 0 0.5rem;
    min-height: 1.25em;
    flex-shrink: 0;
}

/* 词云绘图区：占满词云卡片内标题/模式/提示之下的剩余空间（整张卡为 50vh） */
.xwlb-kw-cloud-card .xwlb-wordcloud-wrap {
    flex: 1 1 0;
    min-height: 0;
    width: 100%;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #f8fafc;
    overflow: hidden;
}

.xwlb-kw-cloud-card .xwlb-wordcloud-wrap canvas {
    display: block;
    width: 100%;
    flex: 1 1 auto;
    min-height: 0;
}

.xwlb-kw-trend {
    flex: 1 1 0;
    margin-top: 0.75rem;
    min-width: 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.xwlb-kw-trend-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.5rem 0.75rem;
    margin: 0 0 0.45rem;
}

.xwlb-kw-trend-title {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text);
}

.xwlb-kw-trend-wrap {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #f8fafc;
    overflow: hidden;
    flex: 1 1 0;
    min-height: 0;
    height: auto;
}

.xwlb-kw-trend-wrap canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.xwlb-list-card,
.xwlb-detail-card {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    display: flex;
    flex-direction: column;
    min-height: 0;
    min-width: 0;
}

.xwlb-list-status {
    flex-shrink: 0;
    padding: 0.65rem 0.75rem;
    border-bottom: 1px solid var(--border);
    background: #f8fafc;
}

/* 列表滚动区：占满列表卡片内状态条之下的剩余空间（整张卡为 50vh） */
.xwlb-news-list {
    list-style: none;
    margin: 0;
    padding: 0.35rem 0;
    overflow-y: auto;
    flex: 1 1 auto;
    min-height: 0;
    box-sizing: border-box;
}

.xwlb-news-item {
    display: flex;
    width: 100%;
    text-align: left;
    align-items: flex-start;
    gap: 0.5rem 0.65rem;
    padding: 0.55rem 0.75rem;
    border: none;
    border-bottom: 1px solid var(--border);
    background: #fff;
    cursor: pointer;
    font: inherit;
    font-size: 0.88rem;
    line-height: 1.45;
    color: var(--text);
    transition: background 0.12s;
}

.xwlb-news-item:hover {
    background: #f1f5f9;
}

.xwlb-news-item.is-active {
    background: #e0f2fe;
    box-shadow: inset 3px 0 0 0 var(--accent);
}

.xwlb-news-item-idx {
    flex-shrink: 0;
    font-variant-numeric: tabular-nums;
    font-weight: 600;
    color: var(--muted);
    min-width: 1.75rem;
}

.xwlb-news-item-title {
    flex: 1;
    display: block;
    min-width: 0;
    padding-left: 0.12rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.xwlb-detail-placeholder {
    margin: 0;
    padding: 1.5rem 1rem;
    text-align: center;
}

.xwlb-detail {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    padding: 0.85rem 1rem 1rem;
}

.xwlb-detail-head {
    flex-shrink: 0;
    margin-bottom: 0.75rem;
    padding-bottom: 0.65rem;
    border-bottom: 1px solid var(--border);
}

.xwlb-detail-title-row {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.35rem 1rem;
}

.xwlb-detail-title {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.4;
    flex: 1 1 12rem;
    min-width: 0;
}

.xwlb-detail-head-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.5rem 0.75rem;
    flex: 0 1 auto;
    max-width: 100%;
}

.xwlb-detail-head-actions[hidden] {
    display: none !important;
}

.xwlb-detail-meta {
    margin: 0;
}

.xwlb-detail-meta[hidden] {
    display: none !important;
}

.xwlb-detail-link {
    flex-shrink: 0;
    white-space: nowrap;
}

.xwlb-detail-body {
    flex: 1;
    min-height: 120px;
    overflow-y: auto;
    font-size: 0.92rem;
    line-height: 1.75;
    white-space: pre-wrap;
    word-break: break-word;
    color: var(--text);
    cursor: text;
    user-select: text;
    -webkit-user-select: text;
}

.xwlb-detail-body .xwlb-kw-hit {
    font-weight: 700;
    background-color: rgba(37, 99, 235, 0.28);
    color: inherit;
    border-radius: 2px;
    padding: 0 0.12em;
}

.xwlb-body-ctx-menu {
    position: fixed;
    z-index: 1200;
    padding: 0.35rem;
    background: var(--panel, #fff);
    border: 1px solid var(--border);
    border-radius: var(--radius, 8px);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
}

.xwlb-body-ctx-menu[hidden] {
    display: none !important;
}

.xwlb-detail-kw-hint {
    margin-top: 0.65rem;
    margin-bottom: 0;
}

.xwlb-out {
    min-height: 120px;
    max-height: 480px;
    overflow-y: auto;
}

.prose-box {
    font-size: 0.92rem;
    line-height: 1.65;
}

.prose-box .seg {
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px dashed var(--border);
}

.prose-box .seg-title {
    font-weight: 600;
    margin-bottom: 0.35rem;
}

.ds-chat {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.ds-msgs {
    flex: 1 1 auto;
    min-height: 200px;
    max-height: none;
    overflow-y: auto;
    padding: 0.75rem;
    background: #f8fafc;
    border-radius: 8px;
    border: 1px solid var(--border);
    font-size: 0.88rem;
}

.panel--ds-chat .ds-input-row {
    flex-shrink: 0;
}

.ds-msg {
    margin-bottom: 0.65rem;
    padding: 0.5rem 0.65rem;
    border-radius: 8px;
}

.ds-msg-user {
    background: #e0f2fe;
    margin-left: 1rem;
}

.ds-msg-bot {
    background: #fff;
    border: 1px solid var(--border);
    margin-right: 1rem;
}

.ds-input-row {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.def-list {
    display: grid;
    grid-template-columns: 100px 1fr;
    gap: 0.5rem 1rem;
    margin: 0;
}

.def-list dt {
    margin: 0;
    color: var(--muted);
    font-size: 0.88rem;
}

.def-list dd {
    margin: 0;
    font-weight: 500;
}

/* 系统设置（宽度由 .app-main--settings 网格控制，此处仅排版） */
.settings-page {
    width: 100%;
    max-width: none;
    margin: 0;
}

.settings-subnav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 0.5rem;
    padding-bottom: 0.85rem;
    margin-bottom: 0.15rem;
    border-bottom: 1px solid var(--border);
}

.settings-subnav-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.45rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--muted);
    text-decoration: none;
    border: 1px solid transparent;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.settings-subnav-link:hover {
    color: var(--text);
    background: #f1f5f9;
}

.settings-subnav-link.is-active {
    color: #0f766e;
    background: var(--accent-dim);
    border-color: rgba(13, 148, 136, 0.35);
    font-weight: 600;
}

.settings-subscribe-panel .panel-title {
    margin-bottom: 0.75rem;
}

.settings-subscribe-panel--error-only {
    padding: 0.85rem 1rem;
}

.settings-subscribe-panel--error-only .app-flash {
    margin: 0;
}

.settings-class-apply-form {
    margin-top: 0;
}

.settings-class-pick-list {
    list-style: none;
    margin: 0;
    padding: 0;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: #fff;
}

.settings-class-pick-item {
    border-bottom: 1px solid var(--border);
}

.settings-class-pick-item:last-child {
    border-bottom: none;
}

.settings-class-pick-item--locked {
    background: #f8fafc;
    color: var(--muted);
}

.settings-class-pick-label {
    display: flex;
    align-items: center;
    gap: 0.5rem 0.75rem;
    padding: 0.55rem 0.75rem;
    margin: 0;
    cursor: pointer;
    font-size: 0.9rem;
    line-height: 1.4;
}

.settings-class-pick-item--locked .settings-class-pick-label {
    cursor: default;
}

.settings-class-pick-cb {
    flex-shrink: 0;
    width: 1rem;
    height: 1rem;
    accent-color: #0d9488;
}

.settings-class-pick-item--locked .settings-class-pick-cb {
    cursor: not-allowed;
    opacity: 0.65;
}

.settings-class-pick-text {
    flex: 1;
    min-width: 0;
    word-break: break-word;
}

.settings-class-pick-tag {
    flex-shrink: 0;
    font-size: 0.78rem;
    padding: 0.12rem 0.45rem;
    border-radius: 6px;
    background: #e2e8f0;
    color: #64748b;
}

.settings-class-apply-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.65rem 1rem;
}

.settings-class-my-enable-form {
    margin-top: 0;
}

.settings-class-my-list {
    list-style: none;
    margin: 0;
    padding: 0;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    background: #fff;
}

.settings-class-my-list--grouped {
    overflow: hidden;
}

.settings-class-my-list--grouped > .settings-class-my-group {
    margin: 0;
    padding: 0;
    border-bottom: 1px solid var(--border);
}

.settings-class-my-list--grouped > .settings-class-my-group:last-child {
    border-bottom: none;
}

.settings-class-my-group-head {
    padding: 0.5rem 0.75rem;
    font-size: 0.86rem;
    font-weight: 600;
    color: #0f766e;
    background: #f0fdfa;
    border-bottom: 1px solid rgba(13, 148, 136, 0.18);
}

.settings-class-my-sublist {
    list-style: none;
    margin: 0;
    padding: 0;
}

.settings-class-my-subrow {
    border-bottom: 1px solid var(--border);
}

.settings-class-my-sublist > .settings-class-my-subrow:last-child {
    border-bottom: none;
}

.settings-class-my-path--l1 {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.12rem;
}

.settings-class-my-path-hint {
    font-size: 0.72rem;
    line-height: 1.2;
}

.settings-class-my-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 0.5rem 1rem;
    align-items: center;
    padding: 0.55rem 0.75rem;
    border-bottom: 1px solid var(--border);
    font-size: 0.9rem;
}

.settings-class-my-row:last-child {
    border-bottom: none;
}

.settings-class-my-row--locked {
    background: #fafafa;
    color: var(--muted);
}

.settings-class-my-path {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.2rem 0.35rem;
    min-width: 0;
    line-height: 1.35;
}

.settings-class-my-seg {
    word-break: break-word;
}

.settings-class-my-sep {
    color: var(--muted);
    font-size: 0.8rem;
    user-select: none;
}

.settings-class-my-audit {
    flex-shrink: 0;
    font-size: 0.82rem;
    color: var(--muted);
    white-space: nowrap;
}

.settings-class-my-enable {
    flex-shrink: 0;
    justify-self: end;
}

.settings-class-my-enable-label {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin: 0;
    font-size: 0.88rem;
    cursor: pointer;
    user-select: none;
}

.settings-class-my-enable-label--disabled {
    cursor: default;
    opacity: 0.65;
}

.settings-class-my-enable-cb {
    width: 1rem;
    height: 1rem;
    accent-color: #0d9488;
}

.settings-class-my-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

@media (max-width: 640px) {
    .settings-class-my-row {
        grid-template-columns: 1fr;
        gap: 0.35rem;
    }

    .settings-class-my-enable {
        justify-self: start;
    }
}

.settings-avatar-block {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.85rem 1rem;
    margin-bottom: 1.25rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--border, rgba(148, 163, 184, 0.2));
}

/* 避免表单占满 flex 行导致百分比/继承宽度参照异常 */
.settings-avatar-upload-form {
    flex-shrink: 0;
    width: fit-content;
    max-width: 100%;
    margin: 0;
}

/* 系统设置：圆形头像预览（原 52px，放大 0.5 倍 → 78px） */
.settings-profile-card .settings-avatar-preview-wrap {
    flex-shrink: 0;
    width: 78px;
    height: 78px;
    min-width: 78px;
    min-height: 78px;
    max-width: 78px;
    max-height: 78px;
    border-radius: 50%;
    overflow: hidden;
    background: var(--panel-muted, #f1f5f9);
    box-shadow: 0 0 0 1.5px rgba(148, 163, 184, 0.28);
    box-sizing: border-box;
}

.settings-profile-card .settings-avatar-preview {
    display: block;
    width: 78px !important;
    height: 78px !important;
    max-width: 78px !important;
    max-height: 78px !important;
    min-width: 0;
    box-sizing: border-box;
    border-radius: 50%;
    object-fit: cover;
    object-position: center;
    vertical-align: top;
}

/* 使用系统默认图时多为宽 Logo，contain 避免裁切；自定义头像仍为 cover */
.settings-profile-card .settings-avatar-preview--default {
    object-fit: contain;
    padding: 5px;
    background: var(--panel-muted, #f1f5f9);
}

.settings-avatar-hitarea {
    display: inline-block;
    cursor: pointer;
    border-radius: 50%;
    line-height: 0;
    max-width: 78px;
}

.settings-avatar-hitarea:focus-within .settings-avatar-preview-wrap {
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.45);
}

.settings-avatar-actions {
    flex: 1 1 220px;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.5rem;
}

.settings-avatar-clear-form {
    margin-top: 0;
}

.settings-profile-card .panel-title {
    margin-bottom: 0.85rem;
}

.def-list--settings-profile {
    grid-template-columns: minmax(5.5rem, 7rem) 1fr;
    gap: 0.65rem 1.25rem;
}

@media (max-width: 480px) {
    .def-list--settings-profile {
        grid-template-columns: 1fr;
    }

    .def-list--settings-profile dt {
        font-weight: 600;
        color: var(--text);
    }

    .def-list--settings-profile dd {
        margin-bottom: 0.35rem;
    }
}

.settings-form-hint {
    font-size: 0.86rem;
    line-height: 1.55;
    color: var(--muted);
    margin: 0 0 1.1rem;
    padding: 0.75rem 0.85rem;
    background: #f8fafc;
    border-radius: 8px;
    border: 1px solid var(--border);
    border-left: 3px solid #0d9488;
}

.settings-profile-form .sub-title {
    margin-top: 0.25rem;
}

.tag-row {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.lead {
    font-size: 1rem;
    color: #334155;
}

.article-title {
    margin: 0 0 0.5rem;
    font-size: 1.35rem;
}

.article-body {
    margin-top: 1rem;
}

.chapter-block {
    margin-top: 1.25rem;
}

.chapter-block h4 {
    margin: 0 0 0.5rem;
    font-size: 1rem;
}

.link-back {
    color: var(--accent);
    font-weight: 600;
    text-decoration: none;
}

/* Auth */
.auth-body {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    background: linear-gradient(160deg, #0f172a 0%, #134e4a 50%, #f4f6f9 50%);
    min-height: 100vh;
}

.auth-wrap {
    width: 100%;
    max-width: 420px;
}

.auth-card {
    background: var(--surface);
    border-radius: 16px;
    padding: 2rem 1.75rem;
    box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.25);
}

.auth-brand {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.auth-brand-title {
    font-size: 1.25rem;
    font-weight: 700;
}

.auth-brand-sub {
    font-size: 0.8rem;
    color: var(--muted);
}

.auth-heading {
    margin: 0 0 1.25rem;
    font-size: 1.35rem;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.auth-switch {
    text-align: center;
    margin-top: 1.25rem;
    font-size: 0.9rem;
    color: var(--muted);
}

.auth-switch a {
    color: var(--accent);
    font-weight: 600;
}

.auth-hint {
    font-size: 0.78rem;
    color: var(--muted);
    margin-top: 1rem;
    line-height: 1.5;
}

.auth-mode-tabs {
    display: flex;
    gap: 0.35rem;
    margin-bottom: 1rem;
    padding: 0.2rem;
    background: var(--surface-2, #f1f5f9);
    border-radius: 10px;
}

.auth-mode-tab {
    flex: 1;
    border: none;
    background: transparent;
    padding: 0.45rem 0.65rem;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--muted);
    border-radius: 8px;
    cursor: pointer;
}

.auth-mode-tab.is-active {
    background: var(--panel, #fff);
    color: var(--text);
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
}

.auth-mode-panel {
    margin-bottom: 0.25rem;
}

.auth-sms-code-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.auth-sms-code-row .field-input {
    flex: 1 1 140px;
    min-width: 0;
}

.auth-sms-code-row .btn {
    flex-shrink: 0;
    white-space: nowrap;
}

.auth-sms-send-hint {
    margin: 0.35rem 0 0;
    min-height: 1.25em;
}

.auth-sms-send-hint--err {
    color: var(--danger, #b91c1c);
}

.auth-foot {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.75rem;
    color: #94a3b8;
}

.auth-beian {
    margin-top: 0.4rem;
}

.auth-beian a {
    color: #94a3b8;
    text-decoration: none;
}

.auth-beian a:hover,
.auth-beian a:focus-visible {
    text-decoration: underline;
}

.auth-guest-form {
    margin-top: 1.25rem;
}

/* 访客试用：贴主工作区底部（不盖侧栏），文案靠左；与 .app-main-head 左右内边距对齐 */
.app-guest-banner {
    position: fixed;
    z-index: 80;
    top: auto;
    bottom: calc(0.5rem + env(safe-area-inset-bottom, 0px));
    left: var(--app-nav-width);
    right: 0;
    width: auto;
    box-sizing: border-box;
    margin: 0;
    padding: 0.5rem max(2rem, env(safe-area-inset-right, 0px)) 0.5rem max(2rem, env(safe-area-inset-left, 0px));
    font-size: 0.8125rem;
    line-height: 1.45;
    text-align: left;
    color: #92400e;
    background: #fffbeb;
    border: none;
    border-top: 1px solid #fde68a;
    border-radius: 0;
    box-shadow: 0 -4px 18px rgba(15, 23, 42, 0.08);
    pointer-events: none;
}

/* 首页 — 案例与作品（轮播，16:9，随视口缩放避免裁切） */
.app-main--home .app-main-scroll {
    padding-top: 0.75rem;
}
.home-carousel-fit {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: flex-start;
}
.home-carousel-fit .carousel.carousel-cases {
    width: min(100%, calc((100dvh - 8rem) * 16 / 9));
    max-width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
}
