/* ============================================================
 * LoopSeek 全站统一导航样式（后台页面不引用）
 * - 一级导航：胶囊按钮风（与会员按钮一致）
 * - 二级导航：股票详情页「基础信息/财务指标」按钮组风，固定在顶栏下方
 * - 所有页面顶栏/二级导航宽度、高度、位置完全一致
 * 该文件在各页面内联样式之后加载，同优先级规则以此文件为准
 * ============================================================ */
:root {
    --ls-nav-h: 64px;
    --ls-subnav-h: 50px;
    --ls-nav-maxw: 1400px;
    --ls-nav-side: 20px;
    --ls-brand: #E1523D;
    --ls-header-bg: #363432;
}

/* ---------- 一级顶栏 ---------- */
header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    height: var(--ls-nav-h);
    padding: 0 !important;
    background-color: var(--ls-header-bg);
    border-bottom: 1px solid rgba(255, 255, 255, .08);
    box-sizing: border-box;
}
header .header-content {
    max-width: var(--ls-nav-maxw) !important;
    height: 100%;
    margin: 0 auto;
    padding: 0 var(--ls-nav-side);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    box-sizing: border-box;
}
header .logo {
    font-size: 22px;
    font-weight: bold;
    color: #fff;
    text-decoration: none;
    white-space: nowrap;
    line-height: 1;
}
/* 中间搜索/占位区：宽度在所有页面一致 */
header .header-search,
header .header-placeholder {
    flex: 1 1 auto;
    max-width: 420px;
    min-width: 0;
}
header .nav {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 0 0 auto;
}
header .nav a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 20px;
    background: rgba(255, 255, 255, .12);
    color: #fff;
    font-size: 13px;
    letter-spacing: .5px;
    text-decoration: none;
    white-space: nowrap;
    transition: background .2s, color .2s;
}
header .nav a:hover {
    background: rgba(255, 255, 255, .22);
    color: #fff;
    font-weight: 500;
}
header .nav a.active {
    background: var(--ls-brand);
    color: #fff;
    font-weight: 500;
}
header .nav a.active:hover {
    background: #c9442f;
}
/* member-modal.js 会以 ID 选择器注入会员按钮样式，这里统一其额外间距 */
header .nav a#member-nav-btn {
    margin-left: 0;
}

/* ---------- 二级导航（发现频道） ---------- */
.sub-nav {
    position: fixed;
    top: var(--ls-nav-h);
    left: 0;
    right: 0;
    z-index: 99;
    height: var(--ls-subnav-h);
    background: #fff;
    border-bottom: 1px solid #e7e8eb;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .05);
    box-sizing: border-box;
}
.sub-nav-inner {
    max-width: var(--ls-nav-maxw);
    height: 100%;
    margin: 0 auto;
    padding: 0 var(--ls-nav-side);
    display: flex;
    align-items: center;
    gap: 10px;
    overflow-x: auto;
    overflow-y: hidden;
    box-sizing: border-box;
    scrollbar-width: none;
}
.sub-nav-inner::-webkit-scrollbar { display: none; }
/* 按钮组样式与股票详情页 .toggle-btn 完全一致 */
.sub-nav a {
    flex: 0 0 auto;
    padding: 7px 16px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    background: #fff;
    color: #666;
    font-size: 13px;
    line-height: 1.2;
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
    transition: all .3s;
}
.sub-nav a:hover {
    border-color: var(--ls-header-bg);
    color: #333;
}
.sub-nav a.active {
    background: var(--ls-header-bg);
    color: #fff;
    border-color: var(--ls-header-bg);
}

/* ---------- 主体留白：固定导航高度 ---------- */
body { padding-top: var(--ls-nav-h) !important; }
body.has-subnav { padding-top: calc(var(--ls-nav-h) + var(--ls-subnav-h)) !important; }

/* ---------- 移动端 ---------- */
@media (max-width: 768px) {
    :root { --ls-nav-h: 56px; --ls-subnav-h: 46px; --ls-nav-side: 12px; }
    header .header-content {
        gap: 10px;
        /* 顶部导航横向可滑：各项不压缩不换行，避免 logo/搜索图标与菜单重叠 */
        flex-wrap: nowrap;
        overflow-x: auto;
        overflow-y: hidden;
        scrollbar-width: none;
    }
    header .header-content::-webkit-scrollbar { display: none; }
    header .header-content > * { flex-shrink: 0; }
    header .logo { font-size: 16px; white-space: nowrap; }
    header .header-search,
    header .header-placeholder { max-width: none; }
    header .nav {
        gap: 6px;
        flex-wrap: nowrap;
        margin-left: auto;
    }
    header .nav a { padding: 5px 10px; font-size: 12px; letter-spacing: 0; white-space: nowrap; }
    .sub-nav a { padding: 6px 12px; font-size: 12px; }
}
@media (max-width: 480px) {
    header .logo { font-size: 15px; }
}

/* ============================================================
 * 顶部搜索：股票详情页 / 研报详情页
 * 小屏下搜索表单收起为放大镜图标，点击后表单以下拉浮层展开
 * ============================================================ */
.header-search-mobile-toggle {
    display: none;
    background: transparent;
    border: none;
    color: #ddd;
    font-size: 15px;
    padding: 6px 8px;
    cursor: pointer;
    align-items: center;
    justify-content: center;
}
.header-search-mobile-toggle:active { color: #E1523D; }
@media (max-width: 768px) {
    .header-search-mobile-toggle {
        display: inline-flex;
    }
    .header-search-form { display: none; }
    /* 展开：表单固定钉在导航下方整行铺开（用 fixed 避开研报页 .header-content
       overflow-x:auto 造成的定位上下文，防止浮层覆盖导航） */
    .header-search.open .header-search-form {
        display: block;
        position: fixed;
        top: var(--ls-nav-h, 56px);
        left: 0;
        right: 0;
        padding: 10px 12px;
        background: #363432;
        box-shadow: 0 8px 18px rgba(0, 0, 0, 0.25);
        z-index: 90;
    }
    /* 搜索结果列表（两页均为 #headerSearchResults）跟随固定在表单下方 */
    .header-search.open #headerSearchResults {
        position: fixed;
        top: calc(var(--ls-nav-h, 56px) + 56px);
        left: 12px;
        right: 12px;
        margin-top: 0;
        z-index: 90;
    }
}

/* ============================================================
 * 大屏宽屏方案
 * - ≥1600px 启动宽流体：内容 94% 宽、2200px 封顶；<1600 维持原 1400 布局
 * - ≥1920px：首页 AI 点评 2 列变 3 列
 * - ≥2200px：首页最新研报轮播继续放大
 * ============================================================ */
@media (min-width: 1600px) {
    /* 变量新值自动作用于 header .header-content(!important) 与 .sub-nav-inner 的 max-width */
    :root { --ls-nav-maxw: 2200px; }
    header .header-content,
    .ht-market,
    .sub-nav-inner,
    .container {
        width: 94%;
        margin-left: auto;
        margin-right: auto;
    }
    /* 各页内联 .container 限宽 1400/1200，同特异性、本文件后加载，以此覆盖 */
    .container { max-width: 2200px; }
    /* 长文正文（研报页/盘前速览）限宽居中：外壳变宽、正文保持可读行宽 */
    .markdown-content {
        max-width: 900px;
        margin-left: auto;
        margin-right: auto;
    }
    /* 五页 footer（stock/ranking/portfolio/market/report）为内联 style 限宽，需 !important 覆盖 */
    footer > div {
        width: 94% !important;
        max-width: 2200px !important;
    }
}
@media (min-width: 1920px) {
    .ai-comment-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 2200px) {
    .report-card-image { width: 972px; }
    .report-stack-container { min-height: 576px; }
}

/* ============================================================
 * 全站行情导航条（market-ticker.js 注入）
 * 宽屏 ≥1200px 且有数据（body.has-ticker）时：
 *   header 变为两行——上行行情条 40px，下行原导航 64px（共 104px）
 * 窄屏 / 无数据时 .ht-market 不占位，导航维持普通单行
 * ============================================================ */

/* ---- 行情条元素基础样式（深底） ---- */
.ms-indices { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.ms-index { display: inline-flex; align-items: baseline; gap: 5px; white-space: nowrap; }
a.ms-index { text-decoration: none; color: inherit; }
a.ms-index:hover .ms-i-name { text-decoration: underline; }
.ms-index .ms-i-name { color: #aaa; font-size: 12px; }
.ms-index .ms-i-close { color: #ddd; font-weight: 600; font-variant-numeric: tabular-nums; }
.ms-index .ms-i-pct { font-weight: 600; font-variant-numeric: tabular-nums; }
.ms-divider { width: 1px; height: 18px; background: rgba(255,255,255,.12); flex: 0 0 auto; }
.ms-block { display: inline-flex; align-items: baseline; gap: 6px; white-space: nowrap; flex: 0 0 auto; }
/* 涨跌数据（上涨比）模块：可点击跳转全市场情绪图 sentiment.html */
.ms-breadth-link { cursor: pointer; }
.ms-breadth-link:hover .ms-label, .ms-breadth-link:hover .ms-val { color: #fff; }
.ms-label { color: #aaa; font-size: 12px; }
.ms-val { font-variant-numeric: tabular-nums; color: #ddd; font-weight: 600; }
.ms-val.up, .ms-index .ms-i-pct.up, .ms-sector .ms-s-pct.up { color: #E1523D; }
.ms-val.down, .ms-index .ms-i-pct.down, .ms-sector .ms-s-pct.down { color: #10B981; }

/* 值变动闪烁：A 股口径红涨绿跌；新值放大到 1.25× 再缩回 1×（2s 呼吸节奏，ease-in-out 缓入缓出），叠加背景高亮淡出。
   作用范围：指数涨跌幅、涨跌家数、上涨比、涨停/炸板数值；行业名称变化走中性琥珀色 flashNew（无涨跌方向含义） */
@keyframes flashUp {
    0%   { transform: scale(1); }
    50%  { transform: scale(1.25); background: rgba(225, 82, 61, .42); }
    100% { transform: scale(1); background: transparent; }
}
@keyframes flashDown {
    0%   { transform: scale(1); }
    50%  { transform: scale(1.25); background: rgba(16, 185, 129, .42); }
    100% { transform: scale(1); background: transparent; }
}
@keyframes flashNew {
    0%   { transform: scale(1); }
    50%  { transform: scale(1.2); background: rgba(245, 158, 11, .45); }
    100% { transform: scale(1); background: transparent; }
}
.flash-up { animation: flashUp 2s ease-in-out; transform-origin: center; }
.flash-down { animation: flashDown 2s ease-in-out; transform-origin: center; }
/* 股票详情页右上角涨跌幅的方向徽标：静态色块（涨红底/跌绿底白箭头），无动画 */
.price-change .ms-arr {
    display: inline-block;
    width: auto;
    min-width: 15px;
    height: 15px;
    line-height: 15px;
    font-size: 9px;
    text-align: center;
    border-radius: 3px;
    vertical-align: 2px;
    padding: 0 2px;
    margin-left: 3px;
    color: #fff;
}
.price-change .ms-arr.up { background: #E1523D; color: #fff; }
.price-change .ms-arr.down { background: #10B981; color: #fff; }
.ms-s-name.flash-new { animation: flashNew 2s ease-in-out; transform-origin: center; }

/* 变动方向箭头：数值右侧固定宽度槽位，预留空间避免箭头出现时跑马灯抖动 */
.ms-arr { display: inline-block; width: 10px; text-align: center; font-size: 8px; line-height: 1; vertical-align: middle; }
.ms-arr.up { color: #E1523D; }
.ms-arr.down { color: #10B981; }
/* 涨跌比矢量胶囊：底层绿色胶囊 + 上层红色胶囊叠加，红胶囊宽度=上涨比（JS 写宽度）。
   100% 上涨时红胶囊完全覆盖绿胶囊；红=首页搜索按钮纯色 #E1523D，绿=详情页成交量柱 rgba 配色 */
.ms-ratio-bar {
    width: 66px; height: 10px;
    display: inline-block; flex: 0 0 auto; align-self: center;
}
.ms-ratio-bar svg { display: block; width: 100%; height: 100%; }
.ms-rb-down { fill: rgba(0, 212, 170, .7); }
.ms-rb-up {
    fill: #E1523D;
    /* SVG 几何属性在现代 Chrome/Edge 可过渡；不支持的浏览器退化为瞬切 */
    transition: width .6s ease-out;
}

/* ============================================================
 * 通用表头吸顶浮层（sticky-thead.js）：克隆 thead 的 fixed 副本
 * - pointer-events:none 不拦截下方表格点击
 * - 列宽/横滚偏移/宽度由 JS 实时同步自原表格
 * ============================================================ */
.sticky-thead-wrap {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 50;
    overflow: hidden;
    pointer-events: none;
    display: none;
    box-shadow: 0 4px 14px rgba(54, 52, 50, 0.10);
}
.sticky-thead-wrap.active { display: block; }
.sticky-thead-wrap table {
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 13px;
    margin: 0;
}
.sticky-thead-wrap table thead th {
    background: linear-gradient(135deg, #363432 0%, #4a4846 100%);
    color: #fff; font-weight: 600; font-size: 13px; text-align: left;
    padding: 14px 12px; white-space: nowrap;
    box-sizing: border-box;
}
/* 居中列（th.c）与原表对齐 */
.sticky-thead-wrap table thead th.c { text-align: center; }
/* 右侧冻结操作列（自选页 .col-action） */
.sticky-thead-wrap table thead th.col-action {
    position: sticky; right: 0; z-index: 3;
    box-shadow: -6px 0 8px -6px rgba(0,0,0,0.12);
}
.ms-sectors span, .ms-sector { display: inline-flex; align-items: baseline; gap: 4px; }
.ms-sector { margin-right: 10px; }
.ms-sector:last-child { margin-right: 0; }
/* 行业名称突出（亮色加粗），涨跌幅次要 */
.ms-sector .ms-s-name { color: #f2f2f2; font-weight: 600; font-size: 12px; }
.ms-sector .ms-s-pct { font-weight: 400; font-size: 11px; font-variant-numeric: tabular-nums; }
.ms-date { color: #888; font-size: 12px; margin-left: auto; flex: 0 0 auto; }

/* ---- 结构容器：行情条是 header 直接子元素，与 .header-content 同宽居中 ---- */
.ht-market {
    display: none;
    align-items: center;
    min-width: 0;
    width: 100%;
    max-width: var(--ls-nav-maxw);
    margin: 0 auto;
    padding: 0 var(--ls-nav-side);
    box-sizing: border-box;
}

/* ---- ≥1200px 且有行情：header 双行（首屏即预留空间，数据到达只填文字不引发布局抖动） ---- */
@media (min-width: 1200px) {
    /* 行情条高度独立变量（不覆盖 --ls-nav-h，避免 logo 导航行被一起撑高）。
       吸顶元素 top = 导航行高 + 行情条高，见各页 calc(var(--ls-nav-h) + var(--ls-ticker-h)) */
    body.has-ticker { --ls-ticker-h: 40px; }
    body.has-ticker { padding-top: 104px !important; }
    body.has-ticker header {
        /* 固定双行总高：即使行情条元素尚未由 JS 注入（非首页 defer 时序），
           header 也保持 104px，导航行靠 margin-top:auto 沉底，绝不发生位移 */
        height: calc(var(--ls-nav-h) + var(--ls-ticker-h));
        display: flex;
        flex-direction: column;
    }
    /* .header-content 维持原 flex 横排（基础规则），双行模式下显式锁定导航行高并沉底。
       必须显式 width:100%：flex 列容器中交叉轴存在 margin:0 auto 时 stretch 会失效，
       缺宽度导航行会塌缩为内容宽并整体居中（logo 与导航挤在中间）；≥1600px 的 94%
       流体宽在本区块之后另行覆盖。 */
    body.has-ticker header .header-content {
        height: var(--ls-nav-h);
        flex: 0 0 var(--ls-nav-h);
        margin-top: auto;
        width: 100%;
    }
    body.has-ticker .ht-market {
        display: flex;
        flex: 0 0 40px;
        height: 40px;
        border-bottom: 1px solid rgba(255,255,255,.08);
    }
    .ht-row {
        display: flex; align-items: center; gap: 10px;
        flex-wrap: nowrap; min-width: 0; overflow: hidden;
        width: 100%;
    }
    /* 有二级导航的页面：sub-nav 下移到行情条之下 */
    body.has-ticker.has-subnav { padding-top: calc(104px + var(--ls-subnav-h)) !important; }
    body.has-ticker.has-subnav .sub-nav { top: 104px; }
}

/* ---- 右侧整体跑马灯（涨跌情绪+热门行业）：溢出才滚，悬停暂停 ---- */
.mq {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
}
.mq-track {
    display: inline-flex;
    align-items: center;
    width: max-content;
    will-change: transform;
}
.mq-item {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
    flex: 0 0 auto;
    padding-right: 40px;
}
.mq.marquee-on .mq-track {
    animation: mqScroll var(--mq-dur, 20s) linear infinite;
}
.mq:hover .mq-track { animation-play-state: paused; }
@keyframes mqScroll {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}

/* ---- 1200~1700 紧凑档 ---- */
@media (max-width: 1700px) and (min-width: 1200px) {
    .ht-row { gap: 7px; }
    .ms-indices { gap: 8px; }
    .ms-index .ms-i-close { display: none; }
    .ms-block { gap: 4px; }
    .ms-sector { margin-right: 7px; }
    .ms-ratio-bar { width: 48px; }
    .ms-index .ms-i-name,
    .ms-label { font-size: 11px; }
}
/* ---- 1200~1450：隐藏红绿胶囊腾空间，其余交给跑马灯 ---- */
@media (max-width: 1450px) and (min-width: 1200px) {
    .ms-ratio-bar { display: none; }
}
/* ---- ≥1600px：导航行跟随宽屏流体宽（覆盖前面双行模式的 width:100%，
   同特异性下本规则位置更靠后而胜出；max-width 仍由基础规则的 2200 封顶） ---- */
@media (min-width: 1600px) {
    body.has-ticker header .header-content { width: 94%; }
}

/* ============================================================
 * 热门行业悬停浮层：该行业规模 Top3 ETF
 * 深底（与行情条同源 #363432），表格5列，行可点击跳东方财富
 * ============================================================ */
.ms-sector.has-etfs { cursor: default; }
.ms-limitup-hover, .ms-broken-hover { cursor: pointer; }

/* 用 body 前缀提升特异性，防止页面全局 table/th/td 选择器覆盖浮层样式 */
body .sector-etf-pop {
    position: fixed;
    z-index: 200;
    min-width: 620px;
    background: #363432 !important;
    color: #ddd;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .45);
    padding: 12px 14px 10px;
    opacity: 0;
    transform: translateY(-4px);
    pointer-events: none;
    transition: opacity .18s ease, transform .18s ease;
    /* 显式重置字体，防止页面继承 */
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    font-size: 12px;
    line-height: 1.5;
}
body .sector-etf-pop.active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}
body .sector-etf-pop .sep-title {
    color: #f5f5f5 !important;
    font-size: 13px;
    font-weight: 600;
    padding: 2px 2px 8px;
    background: transparent;
}
body .sector-etf-pop .sep-title i { color: #E1523D; margin-right: 6px; }
body .sector-etf-pop table,
body .sector-etf-pop thead,
body .sector-etf-pop tbody,
body .sector-etf-pop tr,
body .sector-etf-pop th,
body .sector-etf-pop td {
    /* 显式重置表格元素背景为透明，防止页面全局 table td{background:#fff} 把浮层变白底 */
    background: transparent !important;
    border: none;
    margin: 0;
}
body .sector-etf-pop table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}
body .sector-etf-pop thead th {
    color: #b8b8b8 !important;
    font-weight: 500;
    text-align: left;
    padding: 6px 8px;
    border-bottom: 1px solid rgba(255, 255, 255, .14) !important;
    white-space: nowrap;
}
body .sector-etf-pop tbody td {
    color: #e0e0e0 !important;
    padding: 7px 8px;
    border-bottom: 1px solid rgba(255, 255, 255, .07) !important;
    white-space: nowrap;
}
body .sector-etf-pop tbody tr { cursor: pointer; transition: background .15s; }
body .sector-etf-pop tbody tr:hover {
    background: rgba(225, 82, 61, .18) !important;
}
body .sector-etf-pop tbody tr:hover td.sep-code { color: #ff6b4a !important; }
body .sector-etf-pop tbody tr:hover td.sep-name { color: #fff !important; }
body .sector-etf-pop .sep-code {
    color: #E1523D !important;
    font-family: "Consolas", "Menlo", monospace;
    font-weight: 600;
}
body .sector-etf-pop .sep-name {
    color: #f5f5f5 !important;
    font-weight: 600;
}
body .sector-etf-pop .sep-index { color: #c5c5c5 !important; }
body .sector-etf-pop .sep-scale {
    color: #e8c45a !important;
    text-align: right;
    font-variant-numeric: tabular-nums;
    font-weight: 600;
}
body .sector-etf-pop .sep-price,
body .sector-etf-pop .sep-pct {
    text-align: right;
    font-variant-numeric: tabular-nums;
    font-weight: 600;
}
/* 涨跌着色遵循 A 股惯例：涨红跌绿平默认 */
body .sector-etf-pop .sep-price.up,
body .sector-etf-pop .sep-pct.up { color: #ff6b4a !important; }
body .sector-etf-pop .sep-price.down,
body .sector-etf-pop .sep-pct.down { color: #2ecc8f !important; }
body .sector-etf-pop .sep-price:not(.up):not(.down),
body .sector-etf-pop .sep-pct:not(.up):not(.down) { color: #e0e0e0 !important; }
body .sector-etf-pop thead th:nth-child(4),
body .sector-etf-pop thead th:nth-child(5),
body .sector-etf-pop thead th:nth-child(6) { text-align: right; }
body .sector-etf-pop .sep-foot {
    color: #8a8a8a !important;
    font-size: 11px;
    padding: 8px 2px 2px;
    background: transparent;
}
/* ---------- 涨停/炸板浮层：家数多时表头固定、表体滚动查看 ---------- */
body .limit-up-pop {
    min-width: 420px;
    max-height: 62vh;
    display: flex;
    flex-direction: column;
}
body .limit-up-pop table {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
}
body .limit-up-pop thead { display: block; flex: 0 0 auto; }
body .limit-up-pop tbody {
    display: block;
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, .28) transparent;
}
body .limit-up-pop tbody::-webkit-scrollbar { width: 8px; }
body .limit-up-pop tbody::-webkit-scrollbar-track { background: transparent; }
body .limit-up-pop tbody::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, .25);
    border-radius: 4px;
}
body .limit-up-pop tbody::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, .4); }
/* 行内 flex 布局：名称自适应，其余列定宽，保证表头与表体列对齐 */
body .limit-up-pop thead tr,
body .limit-up-pop tbody tr { display: flex; align-items: center; }
body .limit-up-pop th, body .limit-up-pop td { display: block; flex: 0 0 auto; }
body .limit-up-pop th:nth-child(1), body .limit-up-pop td:nth-child(1) {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}
body .limit-up-pop th:nth-child(2), body .limit-up-pop td:nth-child(2) { width: 104px; }
body .limit-up-pop th:nth-child(3), body .limit-up-pop td:nth-child(3) { width: 60px; }
body .limit-up-pop th:nth-child(4), body .limit-up-pop td:nth-child(4) { width: 64px; }
/* ---------- 指数悬浮分时图弹层 ---------- */
body .index-chart-pop {
    min-width: 0;
    width: 452px;
    padding: 10px 12px 8px;
}
body .index-chart-pop .icp-head {
    display: flex;
    align-items: baseline;
    gap: 8px;
    padding-bottom: 6px;
}
body .index-chart-pop .icp-name { color: #f5f5f5; font-size: 13px; font-weight: 600; }
body .index-chart-pop .icp-code {
    color: #8a8a8a;
    font-size: 11px;
    font-family: "Consolas", "Menlo", monospace;
}
body .index-chart-pop .icp-price {
    margin-left: auto;
    font-size: 14px;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    color: #f5f5f5 !important;
}
body .index-chart-pop .icp-pct {
    font-size: 13px;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}
body .index-chart-pop .icp-pct.up { color: #E1523D !important; }
body .index-chart-pop .icp-pct.down { color: #00D4AA !important; }
body .index-chart-pop .icp-pct:not(.up):not(.down) { color: #ddd !important; }
/* 个股弹层：名称/代码/股价/涨跌幅同一行居中 */
body .index-chart-pop .icp-head-stock { justify-content: center; gap: 10px; }
body .index-chart-pop .icp-head-stock .icp-price { margin-left: 0; }
body .index-chart-pop canvas { display: block; }
body .index-chart-pop .icp-loading {
    color: #8a8a8a;
    font-size: 12px;
    padding: 26px 0;
    text-align: center;
}
body .index-chart-pop .icp-chart { cursor: pointer; }
body .index-chart-pop .icp-date { color: #8a8a8a; font-size: 11px; padding-top: 4px; text-align: right; }
/* 个股弹层底部指标行：二级行业/基本面/PB/PE/净流入/量比 */
body .index-chart-pop .icp-meta {
    display: flex; flex-wrap: wrap; gap: 3px 12px;
    padding-top: 6px; margin-top: 2px;
    border-top: 1px solid rgba(255,255,255,0.08);
    font-size: 11px; color: #8a8a8a; line-height: 1.5;
}
body .index-chart-pop .icp-meta .icp-mi b { color: #d8d8d8; font-weight: 600; }
body .index-chart-pop .icp-meta .icp-mi b.up { color: #E1523D; }
body .index-chart-pop .icp-meta .icp-mi b.down { color: #00D4AA; }
/* 研报图 stock_card.go 同款配色（深底提亮版） */
body .index-chart-pop .icp-meta .icp-mi b.c-red { color: #FF5A36; }
body .index-chart-pop .icp-meta .icp-mi b.c-green { color: #00D4AA; }
body .index-chart-pop .icp-meta .icp-mi b.c-gold { color: #FDD835; }
body .index-chart-pop .icp-meta .icp-mi b.c-blue { color: #1976D2; }
body .index-chart-pop .icp-meta .icp-mi b.c-gray { color: #C3C9D2; }
/* 宽屏下画布分档放大，头部文字同步放大以保持协调 */
@media (min-width: 1600px) {
    body .index-chart-pop .icp-name { font-size: 15px; }
    body .index-chart-pop .icp-code { font-size: 12px; }
    body .index-chart-pop .icp-price { font-size: 16px; }
    body .index-chart-pop .icp-pct { font-size: 15px; }
    body .index-chart-pop .icp-date { font-size: 12px; }
}
@media (min-width: 1920px) {
    body .index-chart-pop .icp-name { font-size: 17px; }
    body .index-chart-pop .icp-price { font-size: 19px; }
    body .index-chart-pop .icp-pct { font-size: 17px; }
}

@media (max-width: 1200px) {
    /* 窄屏行情条隐藏，浮层无触发入口，同步禁用 */
    body .sector-etf-pop { display: none !important; }
}
