/* A股监控总控台 —— dark-glass 视觉系统（黑底 · 青青光 · 红涨绿跌） */
:root {
  --bg: #06090a;
  --bg-2: #0a0f10;
  --panel: rgba(255, 255, 255, .045);
  --panel-strong: rgba(255, 255, 255, .07);
  --line: rgba(153, 255, 237, .14);
  --line-soft: rgba(255, 255, 255, .07);
  --text: #eef7f4;
  --text-dim: #9db4ad;
  --text-faint: #66796f;
  --accent: #00e7d2;
  --accent-2: #3cc8ff;
  --up: #ff5a6a;      /* 涨 · 红 */
  --down: #2fe6a7;    /* 跌 · 绿 */
  --amber: #ffb84d;
  --radius: 18px;
  --mono: 'JetBrains Mono', 'SFMono-Regular', Consolas, 'Courier New', monospace;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, 'PingFang SC', 'Microsoft YaHei', 'Segoe UI', sans-serif;
  font-size: 14px;
  overflow: hidden;
}
body::before {
  content: '';
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 60% 45% at 85% -5%, rgba(0, 231, 210, .07), transparent 60%),
    radial-gradient(ellipse 50% 40% at 8% 105%, rgba(60, 200, 255, .05), transparent 60%),
    radial-gradient(ellipse 40% 35% at 50% 50%, rgba(255, 90, 106, .025), transparent 65%);
}
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .1); border-radius: 4px; }
::-webkit-scrollbar-track { background: transparent; }

.up, .c-up { color: var(--up); }
.down, .c-down { color: var(--down); }
.flat { color: var(--text-dim); }
.num { font-family: var(--mono); font-variant-numeric: tabular-nums; }

/* ================= 应用骨架 ================= */
.app { position: relative; z-index: 1; display: flex; height: 100vh; }

/* 左侧导航（v4：品牌 + 7 视图 + 预警提醒流） */
.nav {
  width: 216px; flex: none; display: flex; flex-direction: column;
  border-right: 1px solid var(--line-soft);
  background: linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,0) 30%);
  padding: 22px 0 16px;
}
.nav-brand { padding: 0 20px 16px; border-bottom: 1px solid var(--line-soft); }
.nav-brand .b-kicker { font-size: 9px; letter-spacing: .22em; color: var(--accent); font-weight: 700; }
.nav-brand .b-name { font-size: 17px; font-weight: 700; margin-top: 6px; letter-spacing: .02em; }
.nav-brand .b-sub { font-size: 10px; color: var(--text-faint); margin-top: 4px; }
.nav-menu { flex: none; padding: 14px 12px 0; display: flex; flex-direction: column; gap: 4px; }
.nav-item {
  display: flex; align-items: center; gap: 10px; padding: 11px 12px;
  border-radius: 12px; border: 1px solid transparent; background: none;
  color: var(--text-dim); font-size: 13px; cursor: pointer; text-align: left;
  transition: all .18s ease; font-family: inherit;
}
.nav-item:hover { color: var(--text); background: rgba(255,255,255,.04); }
.nav-item.active {
  color: var(--text); background: rgba(0, 231, 210, .08);
  border-color: rgba(0, 231, 210, .22);
  box-shadow: 0 0 24px rgba(0, 231, 210, .06) inset;
}
.nav-item .ni-ico { width: 17px; height: 17px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.nav-foot { padding: 12px 20px 0; border-top: 1px solid var(--line-soft); font-size: 10px; color: var(--text-faint); line-height: 1.8; flex: none; }
.nav-foot .dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--down); margin-right: 6px; box-shadow: 0 0 8px currentColor; }
.nav-foot .dot.err { background: var(--up); }

/* 主区 */
.main { flex: 1; min-width: 0; display: flex; flex-direction: column; overflow: hidden; }
.view { display: none; flex: 1; min-height: 0; flex-direction: column; overflow: hidden; }
.view.active { display: flex; }
.view-head { display: flex; align-items: baseline; gap: 14px; padding: 18px 24px 0; flex: none; }
.view-head h1 { font-size: 19px; font-weight: 700; letter-spacing: .02em; }
.view-head .vh-sub { font-size: 11px; color: var(--text-faint); }
.view-head .vh-right { margin-left: auto; display: flex; gap: 8px; align-items: center; }

/* ================= 通用组件 ================= */
.panel {
  background: var(--panel); border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  display: flex; flex-direction: column; min-height: 0; min-width: 0;
}
.panel-head {
  display: flex; align-items: center; gap: 10px; padding: 13px 16px 11px;
  border-bottom: 1px solid var(--line-soft); flex: none;
}
.panel-head h3 { font-size: 13px; font-weight: 600; }
.panel-head .ph-kicker { font-size: 9px; letter-spacing: .16em; color: var(--text-faint); font-weight: 600; }
.panel-head .ph-right { margin-left: auto; display: flex; gap: 6px; align-items: center; }
.panel-body { flex: 1; min-height: 0; overflow: auto; }

.btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 14px; border-radius: 10px; font-size: 12px; font-family: inherit;
  border: 1px solid rgba(0, 231, 210, .3); background: rgba(0, 231, 210, .09);
  color: #affff2; cursor: pointer; transition: all .16s ease; white-space: nowrap;
}
.btn:hover { background: rgba(0, 231, 210, .16); box-shadow: 0 0 18px rgba(0, 231, 210, .12); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn.ghost { border-color: var(--line-soft); background: rgba(255,255,255,.04); color: var(--text-dim); }
.btn.ghost:hover { color: var(--text); background: rgba(255,255,255,.08); box-shadow: none; }
.btn.danger { border-color: rgba(255, 90, 106, .3); background: rgba(255, 90, 106, .08); color: #ffb9c0; }
.btn.primary { border-color: rgba(0, 231, 210, .55); background: rgba(0, 231, 210, .22); color: #cffff2; font-weight: 600; }
.btn.sm { padding: 4px 10px; font-size: 11px; border-radius: 8px; }
.btn.xs { padding: 2px 8px; font-size: 10px; border-radius: 7px; }

input[type=text], input[type=number], select, textarea {
  background: rgba(0, 0, 0, .3); border: 1px solid var(--line-soft);
  border-radius: 10px; color: var(--text); padding: 8px 11px;
  font-size: 13px; font-family: inherit; outline: none; transition: border-color .15s ease;
}
input:focus, select:focus, textarea:focus { border-color: rgba(0, 231, 210, .45); }
input::placeholder { color: var(--text-faint); }
select option { background: #0c1213; }

.badge {
  display: inline-block; padding: 2px 8px; border-radius: 20px;
  font-size: 10px; font-weight: 600; border: 1px solid var(--line-soft); color: var(--text-dim);
}
.badge.up { color: var(--up); border-color: rgba(255, 90, 106, .35); background: rgba(255, 90, 106, .08); }
.badge.down { color: var(--down); border-color: rgba(47, 230, 167, .35); background: rgba(47, 230, 167, .08); }
.badge.mid { color: var(--amber); border-color: rgba(255, 184, 77, .35); background: rgba(255, 184, 77, .08); }
.badge.info { color: var(--accent-2); border-color: rgba(60, 200, 255, .35); background: rgba(60, 200, 255, .08); }

/* ================= 指数磁带 ================= */
.tape {
  flex: none; display: flex; gap: 10px; padding: 14px 24px 0; overflow-x: auto;
}
.tape-item {
  flex: 1; min-width: 148px; display: flex; flex-direction: column; gap: 3px;
  padding: 10px 14px; border-radius: 14px;
  background: var(--panel); border: 1px solid var(--line-soft);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.tape-item .t-name { font-size: 11px; color: var(--text-dim); }
.tape-item .t-row { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.tape-item .t-val { font-family: var(--mono); font-size: 16px; font-weight: 600; }
.tape-item .t-pct { font-family: var(--mono); font-size: 12px; font-weight: 600; }

/* ================= 流体统计卡（WebGL，复用驾驶舱 v1 材质） ================= */
.fluid-stats { flex: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; padding: 14px 24px 0; overflow: visible; }
.fluid-stat {
  --fluid-a: #00e7d2; --fluid-b: #3cc8ff; --fluid-c: #075f68;
  position: relative; min-width: 0; height: 128px; padding: 0;
  border: 1px solid rgba(153, 255, 237, .18); border-radius: 26px;
  overflow: hidden; isolation: isolate; color: #eefcf8;
  background-color: rgba(255, 255, 255, .08);
  -webkit-backdrop-filter: blur(16px) saturate(118%); backdrop-filter: blur(16px) saturate(118%);
  box-shadow: 0 16px 34px rgba(0,0,0,.28), 0 2px 8px rgba(0,0,0,.16),
    inset 0 1px 0 rgba(222,255,248,.10), inset 0 -1px 0 rgba(0,0,0,.24);
  transition: transform .28s cubic-bezier(.2,.8,.2,1), box-shadow .28s ease, border-color .28s ease;
}
.fluid-stat:hover {
  transform: translateY(-3px);
  border-color: rgba(111, 255, 228, .38);
  box-shadow: 0 23px 42px rgba(0,0,0,.36), 0 3px 9px rgba(0,0,0,.18),
    inset 0 1px 0 rgba(226,255,249,.15), 0 0 32px rgba(0,231,210,.10);
}
.fluid-stat[data-palette="red"] { --fluid-a: #ff5a6a; --fluid-b: #ff9d7a; --fluid-c: #6e1522; }
.fluid-stat[data-palette="green"] { --fluid-a: #2fe6a7; --fluid-b: #7af0c8; --fluid-c: #0a5b40; }
.fluid-stat[data-palette="amber"] { --fluid-a: #ffb84d; --fluid-b: #ffd88a; --fluid-c: #6b4a10; }
.fluid-canvas, .fluid-fallback { position: absolute; inset: 0; width: 100%; height: 100%; border-radius: inherit; pointer-events: none; }
.fluid-canvas { z-index: 0; display: block; opacity: .96; filter: saturate(1.12) contrast(1.04) blur(1.6px); }
.fluid-fallback {
  z-index: -1; opacity: 0;
  background:
    radial-gradient(ellipse at 82% 18%, color-mix(in srgb, var(--fluid-a), transparent 10%) 0 8%, transparent 42%),
    radial-gradient(ellipse at 62% 88%, color-mix(in srgb, var(--fluid-b), transparent 18%) 0 13%, transparent 52%),
    radial-gradient(ellipse at 98% 58%, color-mix(in srgb, var(--fluid-c), transparent 8%) 0 10%, transparent 48%);
  animation: fluidFallbackDrift 9s ease-in-out infinite alternate;
}
.fluid-stat.is-fallback .fluid-canvas { display: none; }
.fluid-stat.is-fallback .fluid-fallback { z-index: 0; opacity: .92; }
@keyframes fluidFallbackDrift {
  0% { background-position: 100% 0, 70% 100%, 100% 50%; }
  100% { background-position: 100% 30%, 58% 84%, 94% 70%; }
}
.fluid-stat::before {
  content: ''; position: absolute; z-index: 1; inset: 0; border-radius: inherit; pointer-events: none;
  background:
    linear-gradient(90deg, rgba(2,10,8,.43) 0%, rgba(3,13,11,.31) 28%, rgba(3,14,12,.14) 50%, transparent 76%),
    linear-gradient(180deg, rgba(208,255,246,.032), transparent 34%, rgba(0,0,0,.092));
}
.fluid-stat::after {
  content: ''; position: absolute; z-index: 4; inset: 1px; border-radius: inherit; pointer-events: none;
  box-shadow: inset 0 1px 1px rgba(255,255,255,.12), inset 0 -1px 2px rgba(0,0,0,.26);
}
.fluid-noise {
  position: absolute; z-index: 2; inset: 0; border-radius: inherit; pointer-events: none;
  opacity: .075; mix-blend-mode: soft-light;
  background-image:
    radial-gradient(circle at 20% 30%, rgba(220,255,248,.70) 0 .42px, transparent .78px),
    radial-gradient(circle at 70% 65%, rgba(0,40,34,.78) 0 .4px, transparent .75px);
  background-size: 4px 4px, 5px 5px;
}
.stat-content { position: relative; z-index: 3; height: 100%; padding: 16px 18px 14px 20px; display: flex; flex-direction: column; text-shadow: 0 1px 10px rgba(0,0,0,.34); }
.stat-content .stat-eyebrow { margin: 0 0 3px; color: #82a69d; font-size: 10px; font-weight: 600; letter-spacing: .065em; }
.stat-content .stat-title { margin: 0 0 4px; color: #d8eee8; font-size: 14px; font-weight: 600; }
.stat-content .stat-value { color: #f3fffb; font-size: 34px; line-height: .98; font-weight: 500; letter-spacing: -.035em; font-family: var(--mono); }
.stat-content .stat-unit { color: #8fa9a2; font-size: 11px; margin-left: 5px; text-shadow: none; }
.stat-content .stat-change { margin-top: 5px; color: #819b94; font-size: 10px; line-height: 1.35; }

/* ================= 监控总览布局（v3：板块榜 ⇄ K线 双态主视觉） ================= */
.monitor-main {
  flex: 1; min-height: 0; padding: 14px 24px 20px; display: flex; flex-direction: column;
}
#board-zone, #kline-zone { flex: 1; min-height: 0; display: flex; flex-direction: column; }
#board-zone[hidden], #kline-zone[hidden] { display: none; }

/* 板块榜：行业+概念 并排两组 */
.board-cols { flex: 1; min-height: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.board-panel { min-height: 0; }
.board-list { flex: 1; min-height: 0; overflow-y: auto; padding: 6px 0; }
.board-list-down { flex: none; max-height: 218px; border-top: 1px dashed var(--line-soft); }
.board-row {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 10px;
  padding: 8px 16px; cursor: pointer; border-left: 2px solid transparent;
  transition: background .12s ease; align-items: center;
}
.board-row:hover { background: rgba(255, 255, 255, .035); border-left-color: var(--accent); }
.board-row .br-name { font-size: 13px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.board-row .br-leader { font-size: 10px; color: var(--text-faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.board-row .br-leader b { font-weight: 500; }
.board-row .br-pct { font-family: var(--mono); font-size: 14px; font-weight: 600; text-align: right; grid-row: span 2; align-self: center; }
.board-row .br-p5 { font-size: 9px; color: var(--text-faint); font-family: var(--mono); }
.board-down-toggle {
  flex: none; padding: 8px 16px; font-size: 11px; color: var(--text-faint); cursor: pointer;
  border-top: 1px solid var(--line-soft); user-select: none;
}
.board-down-toggle:hover { color: var(--text); }
.board-down-toggle .bd-arr { display: inline-block; transition: transform .2s ease; }
.board-down-toggle.open .bd-arr { transform: rotate(180deg); }

/* 板块成分股下钻抽屉（右侧滑出） */
#board-drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 700;
  width: min(560px, 92vw); display: flex; flex-direction: column;
  background: rgba(8, 13, 14, .97); border-left: 1px solid var(--line);
  -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px);
  transform: translateX(102%); transition: transform .32s cubic-bezier(.2,.8,.2,1);
  box-shadow: -24px 0 70px rgba(0,0,0,.55);
}
#board-drawer.open { transform: translateX(0); }
#board-drawer-mask {
  position: fixed; inset: 0; z-index: 650; background: rgba(2, 5, 6, .45);
}
.bd-head { display: flex; align-items: flex-start; justify-content: space-between; padding: 18px 16px 12px; flex: none; }
.bd-title { font-size: 17px; font-weight: 700; }
.bd-sub { font-size: 11px; color: var(--text-faint); margin-top: 4px; }
.bd-body { flex: 1; min-height: 0; overflow: auto; padding: 10px 6px 16px; }
.bd-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.bd-table th {
  position: sticky; top: 0; z-index: 2; background: #0b1112; text-align: right;
  padding: 8px 10px; font-size: 10px; color: var(--text-faint); font-weight: 600;
  border-bottom: 1px solid var(--line-soft); white-space: nowrap;
}
.bd-table th:first-child, .bd-table td:first-child { text-align: left; }
.bd-table td { padding: 7px 10px; text-align: right; border-bottom: 1px solid rgba(255,255,255,.04); font-family: var(--mono); white-space: nowrap; }
.bd-table td.td-name { font-family: inherit; }
.bd-table tr[data-code] { cursor: pointer; }
.bd-table tr[data-code]:hover td { background: rgba(0, 231, 210, .05); }
.bd-leader-tag { font-size: 9px; color: var(--amber); border: 1px solid rgba(255,184,77,.4); border-radius: 8px; padding: 0 5px; margin-left: 6px; }
/* 自选股列表 */
.watch-add { display: flex; gap: 8px; padding: 12px 14px; border-bottom: 1px solid var(--line-soft); flex: none; position: relative; }
.watch-add input { flex: 1; min-width: 0; }
.search-pop {
  position: absolute; top: calc(100% - 4px); left: 14px; right: 14px; z-index: 30;
  background: #0d1415; border: 1px solid var(--line); border-radius: 12px;
  max-height: 260px; overflow: auto; box-shadow: 0 18px 50px rgba(0,0,0,.6);
  display: none;
}
.search-pop.open { display: block; }
.search-hit { display: flex; align-items: center; gap: 8px; padding: 9px 12px; cursor: pointer; font-size: 12px; }
.search-hit:hover { background: rgba(0, 231, 210, .08); }
.search-hit .s-code { font-family: var(--mono); color: var(--text-faint); font-size: 11px; }
.search-hit .s-name { flex: 1; }
.watch-list { flex: 1; min-height: 0; overflow: auto; }
.watch-row {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 8px;
  padding: 9px 14px; cursor: pointer; border-left: 2px solid transparent;
  transition: background .12s ease;
}
.watch-row:hover { background: rgba(255, 255, 255, .035); }
.watch-row.active { background: rgba(0, 231, 210, .07); border-left-color: var(--accent); }
.watch-row .w-name { font-size: 13px; font-weight: 500; display: flex; align-items: center; gap: 6px; min-width: 0; }
.watch-row .w-name .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.watch-row .w-code { font-family: var(--mono); font-size: 10px; color: var(--text-faint); }
.watch-row .w-price { font-family: var(--mono); font-size: 13px; text-align: right; }
.watch-row .w-pct { font-family: var(--mono); font-size: 11px; text-align: right; font-weight: 600; }
.watch-row .w-del {
  visibility: hidden; border: none; background: none; color: var(--text-faint);
  cursor: pointer; font-size: 14px; padding: 0 2px; line-height: 1;
}
.watch-row:hover .w-del { visibility: visible; }
.watch-row .w-del:hover { color: var(--up); }
.watch-empty { padding: 30px 16px; text-align: center; color: var(--text-faint); font-size: 12px; line-height: 2; }

/* K线区 */
.kline-wrap { display: flex; flex-direction: column; min-height: 0; flex: 1; }
.kline-toolbar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; border-bottom: 1px solid var(--line-soft); flex: none; flex-wrap: wrap; }
.seg { display: inline-flex; border: 1px solid var(--line-soft); border-radius: 9px; overflow: hidden; }
.seg button {
  border: none; background: none; color: var(--text-dim); font-size: 11px;
  padding: 5px 11px; cursor: pointer; font-family: inherit;
}
.seg button.active { background: rgba(0, 231, 210, .14); color: #c9fff5; }
.kline-title { font-size: 14px; font-weight: 600; margin-right: auto; display: flex; align-items: baseline; gap: 10px; }
.kline-title .kt-code { font-family: var(--mono); font-size: 11px; color: var(--text-faint); }
.kline-canvas-box { flex: 1; min-height: 0; position: relative; }
.kline-canvas-box canvas { position: absolute; inset: 0; width: 100%; height: 100%; }

/* 详情面板 */
.detail-quote { padding: 14px 16px; border-bottom: 1px solid var(--line-soft); flex: none; }
.detail-quote .dq-top { display: flex; align-items: baseline; justify-content: space-between; }
.detail-quote .dq-price { font-family: var(--mono); font-size: 28px; font-weight: 600; }
.detail-quote .dq-pct { font-family: var(--mono); font-size: 14px; font-weight: 600; }
.detail-quote .dq-sub { display: grid; grid-template-columns: 1fr 1fr; gap: 5px 12px; margin-top: 10px; font-size: 11px; color: var(--text-dim); }
.detail-quote .dq-sub b { color: var(--text); font-family: var(--mono); font-weight: 500; margin-left: 6px; }
.health-sec { padding: 12px 16px; border-bottom: 1px solid var(--line-soft); flex: none; }
.health-head { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.health-score { font-family: var(--mono); font-size: 30px; font-weight: 600; }
.health-dims { display: flex; flex-direction: column; gap: 7px; }
.dim-row { display: grid; grid-template-columns: 74px minmax(0, 1fr) 44px; align-items: center; gap: 8px; font-size: 11px; }
.dim-row .d-name { color: var(--text-dim); white-space: nowrap; overflow: hidden; }
.dim-bar { height: 5px; border-radius: 3px; background: rgba(255, 255, 255, .07); overflow: hidden; }
.dim-bar i { display: block; height: 100%; border-radius: 3px; background: linear-gradient(90deg, var(--accent), var(--accent-2)); transition: width .5s ease; }
.dim-bar i.na { background: rgba(255, 255, 255, .12); }
.dim-row .d-score { font-family: var(--mono); text-align: right; color: var(--text-dim); }
.dim-detail { grid-column: 1 / -1; font-size: 10px; color: var(--text-faint); line-height: 1.5; margin-top: -3px; }
.advice-sec { padding: 12px 16px; flex: none; }
.advice-line { font-size: 11px; color: var(--text-dim); line-height: 1.7; }
.advice-line li { margin-left: 16px; }
.zone-row { display: flex; gap: 8px; margin-top: 9px; flex-wrap: wrap; }

/* ================= 选股视图 ================= */
.screener-grid { flex: 1; min-height: 0; display: grid; grid-template-columns: 380px minmax(0, 1fr); gap: 14px; padding: 14px 24px 20px; }
.cond-group { padding: 12px 16px; border-bottom: 1px solid var(--line-soft); }
.cond-group .cg-title { font-size: 11px; font-weight: 700; color: var(--accent); letter-spacing: .06em; margin-bottom: 10px; }
.cond-group .cg-title.warn { color: var(--amber); }
.cond-row { display: grid; grid-template-columns: 118px minmax(0, 1fr); align-items: center; gap: 8px; margin-bottom: 8px; }
.cond-row label { font-size: 12px; color: var(--text-dim); }
.cond-row input { width: 100%; padding: 6px 10px; font-size: 12px; }
.cond-row input:disabled { opacity: .4; }
.cond-row .c-hint { grid-column: 2; font-size: 10px; color: var(--text-faint); margin-top: -4px; }
.cond-row .c-check { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--text-dim); }
.scheme-chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 12px 16px; border-bottom: 1px solid var(--line-soft); }
.scheme-chip {
  padding: 5px 11px; border-radius: 20px; font-size: 11px; cursor: pointer;
  border: 1px solid var(--line-soft); background: rgba(255,255,255,.03); color: var(--text-dim);
  transition: all .15s ease;
}
.scheme-chip:hover { border-color: rgba(0, 231, 210, .4); color: var(--text); }
.scheme-desc { padding: 0 16px 10px; font-size: 10px; color: var(--text-faint); line-height: 1.6; min-height: 16px; }
.result-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.result-table th {
  position: sticky; top: 0; z-index: 2; background: #0b1112; text-align: right;
  padding: 9px 10px; font-size: 10px; color: var(--text-faint); font-weight: 600;
  border-bottom: 1px solid var(--line-soft); white-space: nowrap; cursor: pointer; user-select: none;
}
.result-table th:first-child, .result-table td:first-child { text-align: left; }
.result-table th:nth-child(2), .result-table td:nth-child(2) { text-align: left; }
.result-table td { padding: 8px 10px; text-align: right; border-bottom: 1px solid rgba(255,255,255,.04); font-family: var(--mono); white-space: nowrap; }
.result-table tr:hover td { background: rgba(0, 231, 210, .04); }
.result-table tr { cursor: pointer; }
.log-box { font-family: var(--mono); font-size: 11px; line-height: 1.8; color: var(--text-dim); padding: 10px 16px; white-space: pre-wrap; }

/* ================= 回测视图 ================= */
.bt-controls { flex: none; display: flex; gap: 10px; align-items: flex-end; padding: 14px 24px 0; flex-wrap: wrap; }
.bt-field { display: flex; flex-direction: column; gap: 5px; }
.bt-field label { font-size: 10px; color: var(--text-faint); }
.bt-field select, .bt-field input { min-width: 130px; }
.bt-grid { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: 14px; padding: 14px 24px 20px; }
.metric-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; padding: 12px 14px; flex: none; }
.metric-card { background: rgba(0,0,0,.25); border: 1px solid var(--line-soft); border-radius: 12px; padding: 10px 12px; }
.metric-card .m-label { font-size: 10px; color: var(--text-faint); }
.metric-card .m-val { font-family: var(--mono); font-size: 18px; font-weight: 600; margin-top: 3px; }
.equity-box { flex: 1; min-height: 0; position: relative; }
.equity-box canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.trade-table { width: 100%; border-collapse: collapse; font-size: 11px; }
.trade-table th { position: sticky; top: 0; background: #0b1112; padding: 8px 10px; text-align: left; font-size: 10px; color: var(--text-faint); border-bottom: 1px solid var(--line-soft); }
.trade-table td { padding: 7px 10px; border-bottom: 1px solid rgba(255,255,255,.04); font-family: var(--mono); }
.trade-table .t-reason { font-family: inherit; color: var(--text-faint); font-size: 10px; }
.param-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.param-grid .bt-field input { min-width: 0; width: 100%; }

/* ================= AI 顾问视图 ================= */
.ai-grid { flex: 1; min-height: 0; display: grid; grid-template-columns: 330px minmax(0, 1fr); gap: 14px; padding: 14px 24px 20px; }
.dash-hero { display: flex; gap: 18px; align-items: center; padding: 16px 18px; border-bottom: 1px solid var(--line-soft); flex: none; flex-wrap: wrap; }
.dash-score-ring { position: relative; width: 92px; height: 92px; flex: none; }
.dash-score-ring svg { transform: rotate(-90deg); }
.dash-score-ring .sr-val { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.dash-score-ring .sr-num { font-family: var(--mono); font-size: 26px; font-weight: 700; }
.dash-score-ring .sr-cap { font-size: 9px; color: var(--text-faint); }
.dash-tags { display: flex; gap: 8px; flex-wrap: wrap; }
.dash-block { padding: 14px 18px; border-bottom: 1px solid var(--line-soft); }
.dash-block h4 { font-size: 12px; color: var(--accent); letter-spacing: .08em; margin-bottom: 10px; }
.bp-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 8px; }
.bp-item { background: rgba(0,0,0,.25); border: 1px solid var(--line-soft); border-radius: 10px; padding: 8px 11px; }
.bp-item .bp-label { font-size: 10px; color: var(--text-faint); }
.bp-item .bp-val { font-family: var(--mono); font-size: 15px; font-weight: 600; margin-top: 2px; }
.check-item { display: flex; gap: 8px; align-items: baseline; padding: 5px 0; font-size: 12px; }
.check-item .ck-ico { flex: none; width: 16px; text-align: center; }
.check-item .ck-note { color: var(--text-faint); font-size: 11px; }
.risk-list li { margin: 4px 0 4px 18px; font-size: 12px; color: #ffb9c0; line-height: 1.6; }
.pos-list li { margin: 4px 0 4px 18px; font-size: 12px; color: #a9f0d4; line-height: 1.6; }
.ai-summary { font-size: 13px; line-height: 1.9; color: var(--text); white-space: pre-wrap; }
.ai-meta { font-size: 10px; color: var(--text-faint); padding: 10px 18px; }

/* 加载与占位 */
.spinner { display: inline-block; width: 13px; height: 13px; border: 2px solid rgba(0,231,210,.2); border-top-color: var(--accent); border-radius: 50%; animation: spin .7s linear infinite; vertical-align: -2px; }
@keyframes spin { to { transform: rotate(360deg); } }
.empty-hint { display: flex; flex-direction: column; align-items: center; justify-content: center; height: 100%; color: var(--text-faint); font-size: 12px; gap: 8px; text-align: center; line-height: 2; padding: 20px; }
.progress-line { font-size: 11px; color: var(--text-dim); font-family: var(--mono); }

/* 响应式 */
@media (max-width: 1460px) {
  .nav { width: 306px; }
}
@media (max-width: 1240px) {
  .bt-grid { grid-template-columns: 1fr; overflow: auto; }
  .screener-grid { grid-template-columns: 330px minmax(0, 1fr); }
  .board-cols { grid-template-columns: 1fr; overflow-y: auto; }
  .board-panel { min-height: 380px; }
}

/* ================= v2 追加：可用性与布局修复 ================= */

/* 术语悬浮解释 */
.term { border-bottom: 1px dashed rgba(0, 231, 210, .45); cursor: help; }
.term-dot {
  display: inline-block; width: 12px; height: 12px; line-height: 12px; text-align: center;
  border-radius: 50%; border: 1px solid rgba(0, 231, 210, .4); color: var(--accent);
  font-size: 9px; vertical-align: 1px; cursor: help;
}

/* 红涨绿跌图例 */
.legend { font-size: 10px; color: var(--text-faint); display: inline-flex; align-items: center; gap: 4px; }
.legend i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-left: 6px; }
.legend .lg-up { background: var(--up); }
.legend .lg-down { background: var(--down); }

/* toast 提示 */
.toast {
  position: fixed; top: 20px; left: 50%; transform: translate(-50%, -16px); z-index: 2000;
  padding: 10px 18px; border-radius: 12px; font-size: 13px;
  background: rgba(13, 20, 21, .95); border: 1px solid var(--line);
  color: var(--text); box-shadow: 0 18px 50px rgba(0,0,0,.5);
  opacity: 0; transition: all .3s ease; max-width: 70vw;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast-alert { border-color: rgba(255, 184, 77, .5); color: #ffd9a0; }

/* 自选股分组 chips */
.group-chips { display: flex; gap: 6px; padding: 9px 14px 0; flex-wrap: wrap; flex: none; }
.group-chip {
  padding: 3px 10px; border-radius: 14px; font-size: 10px; cursor: pointer;
  border: 1px solid var(--line-soft); color: var(--text-faint); background: rgba(255,255,255,.02);
  transition: all .15s ease;
}
.group-chip:hover { color: var(--text); }
.group-chip.active { border-color: rgba(0, 231, 210, .45); color: #c9fff5; background: rgba(0, 231, 210, .1); }

/* 删除/分组按钮常显淡色 */
.watch-row .w-del { visibility: visible; opacity: .3; }
.watch-row:hover .w-del { opacity: 1; }

/* 价格预警 */
.alert-sec { padding: 12px 16px; border-bottom: 1px solid var(--line-soft); flex: none; }
.alert-add { display: flex; gap: 6px; }
.alert-add select { flex: none; width: 86px; font-size: 11px; padding: 6px 6px; }
.alert-add input { flex: 1; min-width: 0; padding: 6px 10px; font-size: 12px; }
.alert-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 6px 2px; font-size: 12px; color: var(--amber);
  border-bottom: 1px dashed rgba(255,255,255,.06);
}

/* K线标题区现价 */
.kt-price { font-size: 13px; font-weight: 600; }

/* 买卖点主结论高亮 */
.advice-line li.primary { color: var(--text); font-weight: 600; list-style: none; margin-left: 0; padding-top: 4px; border-top: 1px dashed rgba(255,255,255,.08); }

/* AI 卖出风险横幅 */
.risk-banner {
  margin: 12px 18px 0; padding: 10px 14px; border-radius: 12px;
  background: rgba(255, 90, 106, .1); border: 1px solid rgba(255, 90, 106, .35);
  color: #ffc3ca; font-size: 12px; line-height: 1.6;
}

/* 指数磁带右侧渐隐（提示可横滑） */
.tape { mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent); -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent); }

/* 选股结果名称列防挤压 */
.result-table .td-name { max-width: 110px; overflow: hidden; text-overflow: ellipsis; }

/* 流体卡大数字窄屏防溢出 */
@media (max-width: 1500px) {
  .stat-content .stat-value { font-size: 29px; }
}

/* 窄屏：左侧功能栏变抽屉（左缘把手） */
#btn-nav-toggle {
  display: none; position: fixed; left: 0; top: 42%; z-index: 500;
  writing-mode: vertical-rl; padding: 14px 7px; border-radius: 0 10px 10px 0;
  border: 1px solid rgba(0, 231, 210, .35); border-left: none;
  background: rgba(13, 20, 21, .92); color: var(--accent); font-size: 11px;
  cursor: pointer; letter-spacing: .2em;
}
/* 导航抽屉遮罩（窄屏打开时点击空白处关闭） */
#nav-mask { display: none; position: fixed; inset: 0; z-index: 590; background: rgba(2, 5, 6, .45); }
#nav-mask.show { display: block; }
@media (max-width: 1240px) {
  .nav {
    position: fixed; left: 0; top: 0; bottom: 0; z-index: 600;
    width: 340px; max-width: 88vw; background: rgba(8, 13, 14, .97);
    transform: translateX(-102%); transition: transform .3s cubic-bezier(.2,.8,.2,1);
    box-shadow: 20px 0 60px rgba(0,0,0,.5);
  }
  .nav.open { transform: translateX(0); }
  .nav-menu { flex: 1; min-height: 0; overflow-y: auto; }
  .nav-alerts { flex: none; max-height: 160px; }
  #btn-nav-toggle { display: block; }
}

/* 回测控制栏紧凑化 */
.bt-field input[type=date] { min-width: 130px; font-size: 11px; padding: 7px 8px; }
@media (max-width: 1600px) {
  .bt-field select, .bt-field input { min-width: 104px; }
}

/* 选股面板收窄 */
@media (min-width: 1241px) {
  .screener-grid { grid-template-columns: 340px minmax(0, 1fr); }
}

/* ================= v3 追加：左侧功能栏分区 ================= */
.nav-scroll {
  flex: 1; min-height: 0; overflow-y: auto; margin-top: 12px;
  display: flex; flex-direction: column;
}
.side-sec { flex: none; border-top: 1px solid var(--line-soft); padding: 10px 0 12px; display: flex; flex-direction: column; }
.side-sec .sec-head {
  display: flex; align-items: center; gap: 8px; padding: 4px 24px 10px;
}
.side-sec .sec-head h3 { font-size: 13px; font-weight: 600; }
.side-sec .sec-head .badge { margin-left: auto; }
.side-sec .sec-head .btn { margin-left: auto; }
.side-sec .sec-sub { font-size: 10px; color: var(--text-faint); margin-left: auto; }
.side-sec .group-chips { padding: 0 24px 8px; }
.side-sec .watch-add { padding: 0 24px 10px; border-bottom: none; }
.side-sec .search-pop { left: 24px; right: 24px; }
/* 自选股列表限高，保证下方预警/详情可达 */
.side-sec .watch-list { flex: none; max-height: 264px; min-height: 60px; overflow-y: auto; }
#view-advisor .watch-list, .ai-grid .watch-list { max-height: none; min-height: 0; }
.side-sec .watch-row { padding: 8px 24px; }
.side-sec .alert-add { padding: 0 24px; }
.side-sec #alert-list { padding: 4px 24px 0; }
.side-sec .detail-quote { padding: 4px 24px 12px; border-bottom: none; }
.side-sec .health-sec { padding: 0 24px 12px; border-bottom: none; }
.side-sec .advice-sec { padding: 0 24px 4px; }
.side-sec .detail-quote .dq-price { font-size: 24px; }
.side-sec .empty-hint { height: auto; padding: 16px 24px; }

/* 分时 seg 激活时禁用叠加/副图选择（仅日线级别有意义） */
.seg.disabled { opacity: .35; pointer-events: none; }

/* K线/分时 画布切换 */
#minute-canvas[hidden] { display: none; }

/* ================= v4 追加：工作台化 7 视图 ================= */

/* 导航预警提醒流 */
.nav-alerts {
  flex: 1; min-height: 0; margin-top: 14px; padding: 10px 12px 0;
  border-top: 1px solid var(--line-soft); display: flex; flex-direction: column;
}
.nav-alerts .na-head { font-size: 10px; letter-spacing: .14em; color: var(--text-faint); font-weight: 600; padding: 0 8px 8px; flex: none; }
.nav-alerts .na-list { flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: 6px; }
.na-item {
  padding: 8px 10px; border-radius: 10px; font-size: 11px; line-height: 1.5;
  background: rgba(255, 184, 77, .07); border: 1px solid rgba(255, 184, 77, .22); color: #ffd9a0;
}
.na-item .na-time { display: block; font-size: 9px; color: var(--text-faint); margin-top: 3px; font-family: var(--mono); }
.na-empty { font-size: 11px; color: var(--text-faint); padding: 8px; }

/* ---------- 系统状态视图 ---------- */
.status-grid {
  flex: 1; min-height: 0; display: grid; gap: 14px; padding: 14px 24px 20px;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr);
}
.src-row {
  display: grid; grid-template-columns: 10px minmax(0, 1fr) auto; gap: 4px 10px;
  padding: 10px 16px; border-bottom: 1px solid rgba(255,255,255,.04); align-items: center;
}
.src-row .src-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--text-faint); }
.src-row.ok .src-dot { background: var(--down); box-shadow: 0 0 8px rgba(47,230,167,.7); }
.src-row.bad .src-dot { background: var(--up); box-shadow: 0 0 8px rgba(255,90,106,.7); }
.src-row .src-name { font-size: 13px; font-weight: 500; }
.src-row .src-ms { font-family: var(--mono); font-size: 11px; color: var(--text-faint); }
.src-row .src-detail { grid-column: 2 / -1; font-size: 11px; color: var(--text-faint); }
.src-row.bad .src-detail { color: #ffb9c0; }
.metric-row {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  padding: 10px 16px; border-bottom: 1px solid rgba(255,255,255,.04); font-size: 12px;
}
.metric-row .mr-label { color: var(--text-dim); }
.metric-row .mr-val { font-family: var(--mono); font-weight: 600; }
.log-row { padding: 8px 16px; border-bottom: 1px solid rgba(255,255,255,.04); font-size: 11px; line-height: 1.6; }
.log-row .lr-time { font-family: var(--mono); color: var(--text-faint); margin-right: 8px; font-size: 10px; }
.log-row .lr-msg { color: #ffb9c0; word-break: break-all; }

/* ---------- 自选列表视图（左表右图） ---------- */
.wl-grid {
  flex: 1; min-height: 0; display: grid; gap: 14px; padding: 14px 24px 20px;
  grid-template-columns: minmax(430px, 480px) minmax(0, 1fr);
}
.wl-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.wl-table th {
  position: sticky; top: 0; z-index: 2; background: #0b1112; text-align: right;
  padding: 8px 8px; font-size: 10px; color: var(--text-faint); font-weight: 600;
  border-bottom: 1px solid var(--line-soft); white-space: nowrap; cursor: pointer; user-select: none;
}
.wl-table th:first-child, .wl-table td:first-child { text-align: left; padding-left: 14px; }
.wl-table td { padding: 7px 8px; text-align: right; border-bottom: 1px solid rgba(255,255,255,.04); font-family: var(--mono); white-space: nowrap; }
.wl-table td.td-name { font-family: inherit; }
.wl-table tr[data-code] { cursor: pointer; }
.wl-table tr[data-code]:hover td { background: rgba(0, 231, 210, .04); }
.wl-table tr.active td { background: rgba(0, 231, 210, .08); }
.wl-table .wl-ops { white-space: nowrap; }
.wl-table .wl-ops button {
  border: none; background: none; color: var(--text-faint); cursor: pointer;
  font-size: 13px; padding: 0 3px; line-height: 1;
}
.wl-table .wl-ops button:hover { color: var(--accent); }
.wl-table .wl-group-tag { font-size: 9px; color: var(--accent-2); border: 1px solid rgba(60,200,255,.3); border-radius: 8px; padding: 0 5px; margin-left: 5px; }
.wl-health-cell { font-weight: 700; }

/* 个股工作台：上图下坞 */
#ws-panel { min-height: 0; }
.stock-dock {
  flex: none; max-height: 44%; overflow-y: auto;
  border-top: 1px solid var(--line-soft);
}
.dock-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 0; }
.dock-col { padding: 14px 18px; border-bottom: 1px solid rgba(255,255,255,.05); }
.dock-col + .dock-col { border-left: 1px solid rgba(255,255,255,.05); }
.dock-col h4 { font-size: 11px; color: var(--accent); letter-spacing: .08em; margin-bottom: 10px; }
.dock-quote .dq-top { display: flex; align-items: baseline; gap: 12px; }
.dock-quote .dq-price { font-family: var(--mono); font-size: 26px; font-weight: 600; }
.dock-quote .dq-pct { font-family: var(--mono); font-size: 14px; font-weight: 600; }
.dock-quote .dq-sub { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 12px; margin-top: 10px; font-size: 11px; color: var(--text-dim); }
.dock-quote .dq-sub b { color: var(--text); font-family: var(--mono); font-weight: 500; margin-left: 5px; }
.dock-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.dock-actions .btn { flex: 1; justify-content: center; min-width: 108px; }
.alert-inline { display: flex; gap: 6px; margin-top: 12px; }
.alert-inline select { flex: none; width: 86px; font-size: 11px; padding: 6px; }
.alert-inline input { flex: 1; min-width: 0; padding: 6px 10px; font-size: 12px; }
.action-badge-hero { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.action-badge-hero .ab-badge { font-size: 14px; padding: 5px 14px; }

/* ---------- 板块行情三列 ---------- */
.fluid-stats-6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.fluid-stats-6 .fluid-stat { height: 108px; }
.fluid-stats-6 .stat-content .stat-value { font-size: 26px; }
.fluid-stats-6 .stat-content { padding: 12px 14px 10px 16px; }
.board-zone-3 {
  flex: 1; min-height: 0; display: grid; gap: 14px; padding: 14px 24px 20px;
  grid-template-columns: 1fr 1fr 1fr;
}

/* ---------- AI 设置 ---------- */
.settings-wrap { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 14px; padding: 14px 24px 20px; align-items: start; }
.settings-form { padding: 16px 18px; }
.sf-row { margin-bottom: 14px; }
.sf-row label { display: block; font-size: 11px; color: var(--text-faint); margin-bottom: 6px; }
.sf-row input { width: 100%; }
.sf-hint { font-size: 10px; color: var(--text-faint); margin-top: 5px; }
.sf-actions { display: flex; gap: 10px; margin-top: 18px; }
.sf-result { margin-top: 14px; font-size: 12px; line-height: 1.8; }

/* ---------- 响应式 ---------- */
@media (max-width: 1560px) {
  .fluid-stats-6 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .board-zone-3 { grid-template-columns: 1fr 1fr; overflow-y: auto; }
  .board-zone-3 .board-panel { min-height: 400px; }
  .status-grid { grid-template-columns: 1fr 1fr; overflow-y: auto; }
  .status-grid .panel { min-height: 300px; }
}
@media (max-width: 1240px) {
  .wl-grid { grid-template-columns: 1fr; overflow-y: auto; }
  .wl-grid .panel { min-height: 420px; }
  .settings-wrap { grid-template-columns: 1fr; overflow-y: auto; }
  .board-zone-3 { grid-template-columns: 1fr; }
  .status-grid { grid-template-columns: 1fr; }
  .dock-grid { grid-template-columns: 1fr; }
  .dock-col + .dock-col { border-left: none; }
}

/* ============================================================
   情绪日报（视图 3.5）：概览条 + 三栏 SVG 图表
   ============================================================ */
.mood-date {
  background: rgba(255, 255, 255, .05);
  border: 1px solid var(--line-soft);
  border-radius: 9px;
  color: var(--text);
  font-family: var(--mono);
  font-size: 12px;
  padding: 5px 10px;
  outline: none;
  color-scheme: dark;
}
.mood-date:focus { border-color: var(--accent); }

/* 概览条：6 张紧凑卡 */
.mood-summary {
  display: grid; grid-template-columns: repeat(7, 1fr); gap: 10px;
  padding: 14px 24px 10px; flex: none;
}
.ms-card {
  background: var(--panel); border: 1px solid var(--line-soft);
  border-radius: 12px; padding: 10px 13px; min-width: 0;
}
.ms-k {
  font-size: 8.5px; letter-spacing: .18em; color: var(--text-faint);
  font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.ms-v {
  font-family: var(--mono); font-size: 19px; font-weight: 700; margin-top: 5px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.ms-s {
  font-size: 10px; color: var(--text-faint); margin-top: 3px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* 三栏主体 */
.mood-grid {
  flex: 1; min-height: 0; display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 14px; padding: 4px 24px 10px;
}
.mood-grid .panel { min-height: 0; }
.mood-grid .panel-body { padding: 10px 0 14px; }

/* SVG 图表容器 */
.mood-chart { padding: 4px 14px 12px; }
.mood-chart svg { display: block; width: 100%; height: auto; }
.mood-chart .mc-title {
  font-size: 10px; letter-spacing: .12em; color: var(--text-faint);
  font-weight: 700; margin: 0 0 6px;
}

/* 题材标签行（图下方明细） */
.theme-row {
  display: grid; grid-template-columns: 20px 1fr auto auto; gap: 8px;
  align-items: center; padding: 5px 14px; font-size: 12px;
  border-left: 2px solid transparent;
}
.theme-row:hover { background: rgba(255, 255, 255, .03); border-left-color: var(--accent); }
.theme-row .tr-rank { font-family: var(--mono); font-size: 10px; color: var(--text-faint); text-align: right; }
.theme-row .tr-name { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.theme-row .tr-bar { height: 5px; border-radius: 3px; background: linear-gradient(90deg, var(--accent), var(--accent-2)); min-width: 2px; }
.theme-row .tr-n { font-family: var(--mono); font-size: 12px; font-weight: 600; color: var(--accent); }
.theme-row .tr-pct { font-family: var(--mono); font-size: 11px; width: 58px; text-align: right; }
.theme-row .tr-stocks { font-size: 10px; color: var(--text-faint); grid-column: 2 / -1; margin-top: -2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* 行业轮动行 */
.ind-row {
  display: grid; grid-template-columns: 1fr 62px 92px; gap: 8px;
  align-items: center; padding: 5px 14px; font-size: 12px;
  border-left: 2px solid transparent;
}
.ind-row:hover { background: rgba(255, 255, 255, .03); border-left-color: var(--accent); }
.ind-row .ir-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.ind-row .ir-sub { font-size: 10px; color: var(--text-faint); }
.ind-row .ir-pct { font-family: var(--mono); font-size: 13px; font-weight: 600; text-align: right; }
.ind-row .ir-breadth { font-family: var(--mono); font-size: 10px; color: var(--text-faint); text-align: right; }

.ind-split {
  font-size: 9px; letter-spacing: .16em; color: var(--text-faint); font-weight: 700;
  padding: 8px 14px 4px; border-top: 1px solid var(--line-soft); margin-top: 6px;
}

/* 龙虎榜表格 */
.lhb-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.lhb-table th {
  position: sticky; top: 0; z-index: 1;
  background: #0c1214; text-align: right; font-weight: 600; font-size: 10px;
  color: var(--text-faint); letter-spacing: .06em;
  padding: 7px 8px; border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
.lhb-table th:nth-child(1), .lhb-table th:nth-child(2) { text-align: left; }
.lhb-table td {
  padding: 5px 8px; border-bottom: 1px solid var(--line-soft);
  text-align: right; font-family: var(--mono); font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.lhb-table td:nth-child(1) { text-align: left; font-family: var(--mono); font-size: 10.5px; color: var(--text-faint); }
.lhb-table td:nth-child(2) {
  text-align: left; font-family: inherit; font-weight: 500;
  max-width: 92px; overflow: hidden; text-overflow: ellipsis;
}
.lhb-table tbody tr:hover { background: rgba(255, 255, 255, .03); }
.lhb-reason {
  display: block; font-size: 10px; color: var(--text-faint);
  overflow: hidden; text-overflow: ellipsis; max-width: 200px;
}

/* 口径说明条 */
.mood-note {
  flex: none; padding: 9px 24px 12px; display: flex; flex-wrap: wrap; gap: 6px 16px;
  align-items: baseline; font-size: 10.5px; color: var(--text-faint); line-height: 1.7;
  border-top: 1px solid var(--line-soft);
}
.mood-note b { color: var(--text-dim); font-weight: 600; }
.mood-note b.warn { color: var(--amber); }
.mood-note .src-line { color: var(--accent); opacity: .75; }

/* 加载进度条 */
.mood-loading {
  display: flex; align-items: center; justify-content: center; gap: 9px;
  padding: 26px 14px; color: var(--text-dim); font-size: 12px;
}

@media (max-width: 1600px) {
  .mood-summary { grid-template-columns: repeat(4, 1fr); }
  .mood-grid { grid-template-columns: 1fr 1fr; }
  .mood-grid .panel:last-child { grid-column: span 2; }
}
@media (max-width: 1100px) {
  .mood-summary { grid-template-columns: repeat(2, 1fr); }
  .mood-grid { grid-template-columns: 1fr; }
  .mood-grid .panel:last-child { grid-column: span 1; }
}

/* ============================================================
   导航分组（5 组 18 项）
   ============================================================ */
.nav-group { display: flex; flex-direction: column; gap: 2px; }
.nav-group + .nav-group { margin-top: 12px; }
.nav-group .ng-title {
  font-size: 9px; letter-spacing: .18em; color: var(--text-faint); font-weight: 700;
  padding: 0 10px 5px; opacity: .85;
}
.nav-group .ng-title::before {
  content: ''; display: inline-block; width: 3px; height: 3px; border-radius: 50%;
  background: var(--accent); margin-right: 6px; vertical-align: 2px; opacity: .6;
}
.nav-item .ni-tag {
  margin-left: auto; font-size: 8px; letter-spacing: .08em; font-weight: 600;
  color: var(--text-faint); border: 1px solid var(--line-soft); border-radius: 5px;
  padding: 1px 4px; opacity: .8; white-space: nowrap;
}
.nav-item.active .ni-tag { color: var(--accent); border-color: rgba(0,231,210,.3); opacity: 1; }

/* ============================================================
   收盘复盘（样板页）
   ============================================================ */
.rv-date {
  background: rgba(255,255,255,.05); border: 1px solid var(--line-soft); color: var(--text);
  border-radius: 8px; padding: 4px 8px; font-size: 11px; font-family: var(--mono);
  color-scheme: dark;
}
.rv-date:focus { outline: none; border-color: rgba(0,231,210,.4); }

.rv-wrap { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 12px; padding: 14px 24px 20px; overflow: hidden; }

/* 数据快照条：纯真实数据，AI 不参与，给结论做对照 */
.rv-strip {
  flex: none; display: flex; gap: 10px; overflow-x: auto; padding-bottom: 2px;
}
.rv-strip .empty-hint { width: 100%; }
.rv-cell {
  flex: 1 1 0; min-width: 112px; background: var(--panel); border: 1px solid var(--line-soft);
  border-radius: 12px; padding: 10px 12px; position: relative; overflow: hidden;
}
.rv-cell::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse 90% 60% at 50% -20%, rgba(0,231,210,.07), transparent 70%);
}
.rv-cell .rc-k { font-size: 9px; letter-spacing: .12em; color: var(--text-faint); font-weight: 600; }
.rv-cell .rc-v { font-size: 19px; font-weight: 600; font-family: var(--mono); margin-top: 3px; letter-spacing: -.02em; }
.rv-cell .rc-s { font-size: 10px; color: var(--text-dim); margin-top: 2px; }
.rv-cell.alert { border-color: rgba(255,90,106,.28); }
.rv-cell.alert .rc-v { color: var(--up); }
.rv-cell.good { border-color: rgba(47,230,167,.24); }
.rv-cell.good .rc-v { color: var(--down); }

/* AI 复盘主体 */
.rv-body { flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: 12px; padding-right: 4px; }

.rv-summary {
  background: linear-gradient(135deg, rgba(0,231,210,.09), rgba(60,200,255,.05));
  border: 1px solid rgba(0,231,210,.2); border-radius: 14px; padding: 14px 18px;
  font-size: 15px; line-height: 1.6; font-weight: 500;
}
.rv-summary .rs-kicker { font-size: 9px; letter-spacing: .18em; color: var(--accent); font-weight: 700; margin-bottom: 6px; }

/* 情绪仪表：阶段 + 分数条 */
.rv-emotion {
  display: grid; grid-template-columns: 190px 1fr; gap: 18px; align-items: center;
  background: var(--panel); border: 1px solid var(--line-soft); border-radius: 14px; padding: 14px 18px;
}
.rv-emotion .re-score { text-align: center; }
.rv-emotion .re-stage { font-size: 22px; font-weight: 700; letter-spacing: .04em; }
.rv-emotion .re-num { font-size: 11px; color: var(--text-faint); margin-top: 2px; }
.rv-emotion .re-bar { height: 6px; border-radius: 3px; background: rgba(255,255,255,.07); margin-top: 10px; overflow: hidden; }
.rv-emotion .re-bar i { display: block; height: 100%; border-radius: 3px; background: linear-gradient(90deg, var(--down), var(--amber), var(--up)); }
.rv-emotion .re-txt { font-size: 12px; line-height: 1.85; color: var(--text-dim); }
.rv-emotion .re-txt b { color: var(--text); font-weight: 600; }
.rv-emotion .re-next { margin-top: 6px; padding-top: 8px; border-top: 1px dashed var(--line-soft); font-size: 11px; color: var(--accent); }

/* 四宫格 / 通用网格 */
.rv-grid { display: grid; gap: 12px; }
.rv-grid.g2 { grid-template-columns: 1fr 1fr; }
.rv-grid.g3 { grid-template-columns: repeat(3, 1fr); }
.rv-card {
  background: var(--panel); border: 1px solid var(--line-soft); border-radius: 14px; padding: 13px 16px;
}
.rv-card .rc-head { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.rv-card .rc-title { font-size: 12px; font-weight: 600; letter-spacing: .02em; }
.rv-card .rc-body { font-size: 12px; line-height: 1.85; color: var(--text-dim); }
.rv-card .rc-body b { color: var(--text); font-weight: 600; }

/* 结论徽章 */
.badge {
  display: inline-block; font-size: 10px; font-weight: 600; padding: 2px 8px; border-radius: 6px;
  border: 1px solid var(--line-soft); color: var(--text-dim); white-space: nowrap;
}
.badge.strong { color: var(--up); border-color: rgba(255,90,106,.3); background: rgba(255,90,106,.08); }
.badge.neutral { color: var(--amber); border-color: rgba(255,184,77,.3); background: rgba(255,184,77,.08); }
.badge.weak { color: var(--down); border-color: rgba(47,230,167,.3); background: rgba(47,230,167,.08); }
.badge.attack { color: var(--up); border-color: rgba(255,90,106,.3); background: rgba(255,90,106,.08); }
.badge.balanced { color: var(--accent-2); border-color: rgba(60,200,255,.3); background: rgba(60,200,255,.08); }
.badge.defend { color: var(--amber); border-color: rgba(255,184,77,.3); background: rgba(255,184,77,.08); }
.badge.rest { color: var(--down); border-color: rgba(47,230,167,.3); background: rgba(47,230,167,.08); }
.badge.na { color: var(--text-faint); }

/* 方向列表 */
.rv-sector { display: flex; flex-direction: column; gap: 8px; }
.rv-sector .rs-row {
  display: flex; gap: 10px; align-items: flex-start; padding: 9px 12px; border-radius: 10px;
  background: rgba(255,255,255,.03); border-left: 2px solid var(--line-soft);
}
.rv-sector .rs-row.strong { border-left-color: var(--up); }
.rv-sector .rs-row.mid { border-left-color: var(--amber); }
.rv-sector .rs-row.weak { border-left-color: var(--text-faint); }
.rv-sector .rs-name { font-size: 12px; font-weight: 600; flex: none; width: 86px; }
.rv-sector .rs-logic { font-size: 11px; color: var(--text-dim); line-height: 1.7; flex: 1; }
.rv-sector .rs-ev { font-size: 10px; color: var(--text-faint); margin-top: 3px; }

/* 明日策略 */
.rv-plan { display: flex; flex-direction: column; gap: 9px; }
.rv-plan .rp-stance { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.rv-plan .rp-item { display: flex; gap: 8px; font-size: 12px; line-height: 1.8; }
.rv-plan .rp-k { color: var(--text-faint); flex: none; width: 62px; font-size: 11px; }
.rv-plan .rp-v { color: var(--text-dim); flex: 1; }
.rv-plan .rp-v b { color: var(--text); }
.rv-watch { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.rv-watch span {
  font-size: 11px; padding: 3px 9px; border-radius: 7px; background: rgba(0,231,210,.08);
  border: 1px solid rgba(0,231,210,.18); color: #a8f5ea;
}

/* 缺失数据声明（铁律十：宁可说不全，不许编） */
.rv-missing {
  display: flex; flex-wrap: wrap; gap: 6px; align-items: center;
  font-size: 11px; color: var(--amber); background: rgba(255,184,77,.06);
  border: 1px dashed rgba(255,184,77,.28); border-radius: 10px; padding: 8px 12px;
}
.rv-missing b { font-weight: 600; }
.rv-missing span { padding: 2px 8px; border-radius: 6px; background: rgba(255,184,77,.1); }

/* 原始数据折叠 */
.rv-raw { font-size: 11px; }
.rv-raw summary { cursor: pointer; color: var(--text-faint); font-size: 11px; padding: 6px 0; user-select: none; }
.rv-raw summary:hover { color: var(--text-dim); }
.rv-raw pre {
  background: rgba(0,0,0,.35); border: 1px solid var(--line-soft); border-radius: 10px;
  padding: 12px; overflow-x: auto; font-family: var(--mono); font-size: 10.5px;
  line-height: 1.65; color: var(--text-dim); max-height: 320px; overflow-y: auto;
}
.rv-meta { font-size: 10px; color: var(--text-faint); text-align: right; padding-bottom: 4px; }

/* 加载态 */
.rv-loading {
  display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 40px 0; color: var(--text-dim); font-size: 12px;
}
.spinner {
  display: inline-block; width: 15px; height: 15px; border-radius: 50%;
  border: 2px solid rgba(0,231,210,.2); border-top-color: var(--accent);
  animation: rv-spin .7s linear infinite; vertical-align: -3px;
}
@keyframes rv-spin { to { transform: rotate(360deg); } }

@media (max-width: 1400px) {
  .rv-grid.g3 { grid-template-columns: 1fr 1fr; }
  .rv-emotion { grid-template-columns: 150px 1fr; }
}
@media (max-width: 1000px) {
  .rv-grid.g2, .rv-grid.g3 { grid-template-columns: 1fr; }
  .rv-emotion { grid-template-columns: 1fr; }
}

/* ============================================================
   交易档案
   ============================================================ */
.arch-wrap { flex: 1; min-height: 0; display: grid; grid-template-columns: 200px 1fr; gap: 12px; padding: 14px 24px 20px; }
.arch-side .panel-body { padding: 8px; }
.arch-day {
  padding: 8px 10px; border-radius: 9px; cursor: pointer; font-size: 12px;
  display: flex; align-items: center; gap: 8px; color: var(--text-dim);
}
.arch-day:hover { background: rgba(255,255,255,.05); color: var(--text); }
.arch-day.active { background: rgba(0,231,210,.12); color: #c9fff5; }
.arch-day .ad-d { font-family: var(--mono); font-size: 11.5px; }
.arch-day .ad-n { margin-left: auto; font-size: 9px; color: var(--text-faint); }
.arch-main .panel-body { padding: 16px 18px; }
.arch-sec { margin-bottom: 18px; }
.arch-sec:last-child { margin-bottom: 0; }
.arch-sec .as-head {
  display: flex; align-items: center; gap: 8px; margin-bottom: 8px;
  padding-bottom: 6px; border-bottom: 1px solid var(--line-soft);
}
.arch-sec .as-title { font-size: 12.5px; font-weight: 600; }
.arch-sec .as-at { margin-left: auto; font-size: 10px; color: var(--text-faint); font-family: var(--mono); }
.arch-sec .as-body { font-size: 12px; line-height: 1.85; color: var(--text-dim); white-space: pre-wrap; }
.arch-note {
  background: rgba(255,255,255,.03); border-left: 2px solid var(--accent-2); border-radius: 8px;
  padding: 8px 12px; margin-bottom: 8px; font-size: 12px; line-height: 1.75;
}
.arch-note .an-at { font-size: 10px; color: var(--text-faint); font-family: var(--mono); margin-bottom: 3px; }

/* ============================================================
   交易知识库
   ============================================================ */
.know-wrap { flex: 1; min-height: 0; display: grid; grid-template-columns: 1fr 320px; gap: 12px; padding: 14px 24px 20px; }
#know-text {
  background: rgba(0,0,0,.3); border: 1px solid var(--line-soft); border-radius: 14px;
  color: var(--text); font-family: var(--mono); font-size: 12px; line-height: 1.9;
  padding: 16px 18px; resize: none; outline: none; min-height: 0;
}
#know-text:focus { border-color: rgba(0,231,210,.35); }
.know-side { display: flex; flex-direction: column; gap: 12px; min-height: 0; }
.know-side .panel-body { padding: 12px 14px; }
.know-tips p { font-size: 11.5px; line-height: 1.9; color: var(--text-dim); margin-bottom: 10px; }
.know-tips p:last-child { margin-bottom: 0; }
.know-tips b { color: var(--accent); font-weight: 600; }
#know-meta { font-size: 11px; line-height: 1.9; color: var(--text-dim); }
#know-meta .km-row { display: flex; justify-content: space-between; gap: 8px; padding: 3px 0; border-bottom: 1px dashed var(--line-soft); }
#know-meta .km-row:last-child { border-bottom: none; }
#know-meta .km-v { font-family: var(--mono); color: var(--text); }

/* ============================================================
   占位页（待建功能）
   ============================================================ */
.wip-wrap { flex: 1; min-height: 0; display: flex; align-items: flex-start; justify-content: center; padding: 24px; overflow: auto; }
.wip-card {
  max-width: 660px; width: 100%; background: var(--panel); border: 1px solid var(--line-soft);
  border-radius: 16px; padding: 26px 30px; position: relative; overflow: hidden;
}
.wip-card::before {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse 70% 50% at 100% 0%, rgba(0,231,210,.06), transparent 65%);
}
.wip-kicker { font-size: 9px; letter-spacing: .2em; color: var(--accent); font-weight: 700; }
.wip-title { font-size: 21px; font-weight: 700; margin-top: 6px; letter-spacing: .02em; }
.wip-desc { font-size: 12.5px; color: var(--text-dim); line-height: 1.85; margin-top: 10px; }
.wip-list { margin: 16px 0 0; padding-left: 18px; display: flex; flex-direction: column; gap: 7px; }
.wip-list li { font-size: 12px; color: var(--text-dim); line-height: 1.6; }
.wip-list li::marker { color: var(--accent); }
.wip-foot {
  margin-top: 20px; padding-top: 14px; border-top: 1px dashed var(--line-soft);
  font-size: 11px; color: var(--text-faint); line-height: 1.8;
}

/* ============================================================
   第 2 批页面：晨间简报 / 次日策略 / 趋势池 / 个股问诊
   ============================================================ */

/* 口径说明条：告诉用户「这些数据到底是什么时候的」—— 防止把昨收当今天 */
.rv-note {
  display: flex; align-items: flex-start; gap: 8px;
  font-size: 11px; line-height: 1.75; color: var(--text-dim);
  background: rgba(60,200,255,.05); border: 1px solid rgba(60,200,255,.16);
  border-radius: 10px; padding: 8px 12px;
}
.rv-note b { color: var(--accent-2); font-weight: 600; }
.rv-note.alert { background: rgba(255,184,77,.06); border-color: rgba(255,184,77,.24); }
.rv-note.alert b { color: var(--amber); }

/* ---------- 个股问诊：搜索条 ---------- */
.sk-bar {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap; flex: none;
  background: var(--panel); border: 1px solid var(--line-soft); border-radius: 12px; padding: 9px 12px;
}
.sk-input {
  flex: 1; min-width: 180px; background: rgba(0,0,0,.25); color: var(--text);
  border: 1px solid var(--line-soft); border-radius: 9px; padding: 7px 12px;
  font-size: 13px; font-family: inherit; outline: none;
}
.sk-input:focus { border-color: rgba(0,231,210,.45); }
.sk-input::placeholder { color: var(--text-faint); }
.sk-quick { display: flex; gap: 6px; flex-wrap: wrap; width: 100%; }
.sk-chip {
  font-size: 11px; padding: 3px 9px; border-radius: 7px; cursor: pointer;
  background: rgba(255,255,255,.04); border: 1px solid var(--line-soft); color: var(--text-dim);
  transition: .15s; white-space: nowrap;
}
.sk-chip:hover { color: var(--accent); border-color: rgba(0,231,210,.35); background: rgba(0,231,210,.08); }
.sk-chip .qk-code { font-family: var(--mono); font-size: 10px; color: var(--text-faint); margin-left: 4px; }

/* ---------- 持仓诊断 ---------- */
.hd-num { width: 110px; flex: none; }
.hd-list { display: flex; flex-direction: column; gap: 6px; }
.hd-list-head { font-size: 11px; color: var(--text-dim); display: flex; align-items: center; gap: 10px; }
.hd-list-head b { color: var(--text); }
.hd-item {
  display: flex; align-items: center; gap: 10px; padding: 8px 12px;
  border-radius: 10px; background: rgba(255,255,255,.03); border: 1px solid var(--line-soft);
}
.hd-name { font-size: 13px; font-weight: 600; }
.hd-name i { font-style: normal; font-family: var(--mono); font-size: 10px; color: var(--text-faint); margin-left: 6px; }
.hd-tag { font-size: 10px; color: var(--text-dim); background: rgba(255,255,255,.05); border: 1px solid var(--line-soft); padding: 2px 7px; border-radius: 6px; }
.hd-tag.dim { opacity: .55; }
.hd-del { margin-left: auto; border: none; background: none; color: var(--text-faint); cursor: pointer; font-size: 13px; padding: 2px 6px; border-radius: 6px; }
.hd-del:hover { color: #ff5a6a; background: rgba(255,90,106,.1); }
.hd-watch { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; }
.hd-watch li { font-size: 12px; color: var(--text-dim); line-height: 1.6; }
.hd-watch li::marker { color: var(--accent); }

/* ---------- 隔夜美股 → A股 映射表 ---------- */
.rv-map { display: flex; flex-direction: column; gap: 8px; }
.rv-map .rm-row {
  display: grid; grid-template-columns: 1fr 22px 1fr; gap: 10px; align-items: center;
  padding: 10px 12px; border-radius: 10px; background: rgba(255,255,255,.03);
  border: 1px solid var(--line-soft);
}
.rv-map .rm-us { font-size: 11px; line-height: 1.7; color: var(--text-dim); }
.rv-map .rm-us b { color: var(--text); font-weight: 600; display: block; font-size: 12px; margin-bottom: 2px; }
.rv-map .rm-arrow { text-align: center; color: var(--accent); font-size: 15px; }
.rv-map .rm-cn { font-size: 12px; font-weight: 600; line-height: 1.7; }
.rv-map .rm-row.strong { border-left: 2px solid var(--up); }
.rv-map .rm-row.mid { border-left: 2px solid var(--amber); }
.rv-map .rm-row.weak { border-left: 2px solid var(--text-faint); }
.rv-map .rm-logic {
  grid-column: 1 / -1; font-size: 11px; line-height: 1.75; color: var(--text-dim);
  padding-top: 8px; margin-top: 6px; border-top: 1px dashed var(--line-soft);
}
.rv-map .rm-confirm { grid-column: 1 / -1; font-size: 10px; color: var(--accent); margin-top: 2px; }

/* ---------- 今日催化 ---------- */
.rv-cat { display: flex; flex-direction: column; gap: 7px; }
.rv-cat .cat-row {
  display: flex; gap: 10px; align-items: flex-start; padding: 9px 12px; border-radius: 10px;
  background: rgba(255,255,255,.03); border-left: 2px solid var(--line-soft);
}
.rv-cat .cat-row.good { border-left-color: var(--up); }
.rv-cat .cat-row.bad { border-left-color: var(--down); }
.rv-cat .cat-row.neutral { border-left-color: var(--text-faint); }
.rv-cat .cat-tags { display: flex; flex-direction: column; gap: 4px; flex: none; width: 74px; }
.rv-cat .cat-main { flex: 1; min-width: 0; }
.rv-cat .cat-title { font-size: 12px; line-height: 1.7; color: var(--text); }
.rv-cat .cat-target { font-size: 11px; line-height: 1.7; color: var(--text-dim); margin-top: 3px; }
.rv-cat .cat-target b { color: var(--accent-2); font-weight: 600; }

/* ---------- 重点方向 / 策略卡 ---------- */
.rv-focus { display: flex; flex-direction: column; gap: 10px; }
.rf-card {
  background: var(--panel); border: 1px solid var(--line-soft); border-radius: 14px; padding: 13px 16px;
}
.rf-card .rf-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 9px; }
.rf-card .rf-dir { font-size: 14px; font-weight: 700; letter-spacing: .02em; }
.rf-card .rf-idx {
  font-size: 10px; font-family: var(--mono); color: var(--bg); background: var(--accent);
  border-radius: 5px; padding: 1px 6px; font-weight: 700;
}
.rf-card .rf-lines { display: flex; flex-direction: column; gap: 6px; }
.rf-card .rf-line { display: flex; gap: 8px; font-size: 12px; line-height: 1.8; }
.rf-card .rf-k {
  flex: none; width: 52px; font-size: 10px; color: var(--text-faint); padding-top: 2px; letter-spacing: .04em;
}
.rf-card .rf-v { flex: 1; color: var(--text-dim); }
.rf-card .rf-v b { color: var(--text); font-weight: 600; }
.rf-card .rf-cands { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.rf-card .rf-cands span {
  font-size: 11px; padding: 2px 9px; border-radius: 7px;
  background: rgba(255,90,106,.09); border: 1px solid rgba(255,90,106,.22); color: #ffb3bb;
}
.rf-card .rf-cands span i { font-family: var(--mono); font-style: normal; font-size: 10px; opacity: .65; margin-left: 4px; }

/* ---------- 趋势票 ---------- */
.rv-pick { display: flex; flex-direction: column; gap: 12px; }
.pk-card {
  background: var(--panel); border: 1px solid var(--line-soft); border-radius: 14px;
  padding: 14px 18px; border-left: 2px solid var(--accent);
}
.pk-card .pk-head { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 4px; }
.pk-card .pk-idx { font-size: 10px; font-family: var(--mono); color: var(--bg); background: var(--accent); border-radius: 5px; padding: 1px 6px; font-weight: 700; }
.pk-card .pk-name { font-size: 17px; font-weight: 700; letter-spacing: .02em; }
.pk-card .pk-code { font-size: 12px; font-family: var(--mono); color: var(--text-faint); }
.pk-card .pk-sector { font-size: 11px; color: var(--accent-2); }
.pk-card .pk-seg {
  font-size: 11px; color: var(--text-dim); margin: 6px 0 10px; padding: 5px 10px;
  background: rgba(255,255,255,.03); border-radius: 8px; display: inline-block;
}
.pk-card .pk-lines { display: flex; flex-direction: column; gap: 6px; }
.pk-card .pk-line { display: flex; gap: 8px; font-size: 12px; line-height: 1.8; }
.pk-card .pk-k { flex: none; width: 52px; font-size: 10px; color: var(--text-faint); padding-top: 2px; letter-spacing: .04em; }
.pk-card .pk-v { flex: 1; color: var(--text-dim); }
.pk-card .pk-v b { color: var(--text); font-weight: 600; }

/* ---------- 次日策略顶部取向条 ---------- */
.rv-stance {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  background: linear-gradient(135deg, rgba(0,231,210,.08), rgba(60,200,255,.04));
  border: 1px solid rgba(0,231,210,.2); border-radius: 14px; padding: 13px 18px;
}
.rv-stance .rst-main { font-size: 18px; font-weight: 700; letter-spacing: .04em; }
.rv-stance .rst-pos { font-size: 12px; color: var(--text-dim); }
.rv-stance .rst-note { font-size: 11px; color: var(--text-faint); flex: 1; min-width: 220px; line-height: 1.7; }

/* ---------- 分组小标题 ---------- */
.rv-h2 {
  display: flex; align-items: center; gap: 9px; font-size: 11px; font-weight: 700;
  letter-spacing: .14em; color: var(--accent); margin-top: 4px;
}
.rv-h2::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.rv-h2 .rv-h2-n { font-size: 10px; color: var(--text-faint); letter-spacing: 0; font-weight: 400; }

/* ---------- 快讯列表 ---------- */
.rv-news { display: flex; flex-direction: column; gap: 5px; max-height: 320px; overflow-y: auto; }
.rv-news .rn-row { display: flex; gap: 10px; font-size: 11px; line-height: 1.75; padding: 5px 8px; border-radius: 7px; }
.rv-news .rn-row:nth-child(odd) { background: rgba(255,255,255,.02); }
.rv-news .rn-t { flex: none; width: 82px; font-family: var(--mono); font-size: 10px; color: var(--text-faint); padding-top: 1px; }
.rv-news .rn-x { flex: 1; color: var(--text-dim); }

@media (max-width: 1000px) {
  .rv-map .rm-row { grid-template-columns: 1fr; }
  .rv-map .rm-arrow { display: none; }
}

/* ---------- 涨停复盘：连板梯队 / 个股 pill ----------
   梯队是涨停复盘的骨架：首板多少决定「有没有新血」，高位板多少决定「空间打没打开」，
   中间空档说明情绪断层。所以每档单独一行、连板越高越烫，一眼能看出断层在哪。 */
.lu-ladder { display: flex; flex-direction: column; gap: 7px; }
.lu-ladder .ll-row {
  display: flex; gap: 10px; padding: 8px 10px; border-radius: 8px;
  background: rgba(255, 255, 255, .025); border-left: 2px solid var(--line-soft);
}
.lu-ladder .ll-row.hot { border-left-color: var(--up); }
.lu-ladder .ll-row.mid { border-left-color: var(--amber); }
.lu-ladder .ll-lv { flex: none; width: 86px; font-size: 12px; font-weight: 600; padding-top: 2px; }
.lu-ladder .ll-lv .ll-n { font-size: 10px; color: var(--text-faint); font-weight: 400; margin-left: 4px; }
.lu-ladder .ll-list { flex: 1; display: flex; flex-wrap: wrap; gap: 5px 6px; align-content: flex-start; }
.lu-ladder .ll-item {
  font-size: 11px; color: var(--text-dim); padding: 2px 7px; border-radius: 5px;
  background: rgba(255, 255, 255, .04); white-space: nowrap;
}
.lu-ladder .ll-item b { color: var(--text); font-weight: 600; }
.lu-ladder .ll-item i { font-style: normal; color: var(--text-faint); font-family: var(--mono); }
/* 开板次数多 = 烂板 = 承接弱，单独标红 */
.lu-ladder .ll-item.bad { background: rgba(255, 90, 106, .1); }
.lu-ladder .ll-item.bad b { color: var(--up); }

/* 题材归因 / 炸板明细：同样的 pill 排布，只是不带左侧色条 */
.lu-pills { display: flex; flex-wrap: wrap; gap: 5px 6px; }
.lu-pills .lp-item {
  font-size: 11px; color: var(--text-dim); padding: 3px 8px; border-radius: 6px;
  background: rgba(255, 255, 255, .04); white-space: nowrap;
}
.lu-pills .lp-item b { color: var(--text); font-weight: 600; }
.lu-pills .lp-item i { font-style: normal; color: var(--text-faint); font-family: var(--mono); }
.lu-pills .lp-item.hot { background: rgba(255, 90, 106, .1); }
.lu-pills .lp-item.hot b { color: var(--up); }

/* 产业链分析里，pill 会被当成按钮用（热门板块芯片 / 候选板块），补个可点感 */
.lu-pills .lp-item[data-name],
.lu-pills button.lp-item { cursor: pointer; border: none; font-family: inherit; }
.lu-pills .lp-item[data-name]:hover,
.lu-pills button.lp-item:hover { background: rgba(0, 231, 210, .12); color: var(--text); }

/* ---------- 产业链分析：上/中/下游三列图谱 ---------- */
.ch-layers { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.ch-layer {
  background: rgba(255, 255, 255, .022); border: 1px solid var(--line-soft);
  border-radius: 12px; padding: 10px; display: flex; flex-direction: column; gap: 8px;
}
.ch-layer .cl-head {
  font-size: 13px; font-weight: 700; color: var(--accent);
  display: flex; align-items: baseline; justify-content: space-between;
}
.ch-layer .cl-head .cl-n { font-size: 10px; color: var(--text-faint); font-weight: 400; }
.ch-seg {
  background: rgba(255, 255, 255, .03); border: 1px solid var(--line-soft);
  border-radius: 9px; padding: 8px 9px;
}
.ch-seg .cs-top { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.ch-seg .cs-name { font-size: 12px; font-weight: 600; color: var(--text); }
.ch-seg .cs-barrier {
  font-size: 10px; padding: 1px 6px; border-radius: 4px; white-space: nowrap;
  font-weight: 600;
}
.ch-seg .cs-barrier.b-hi { background: rgba(255, 90, 106, .14); color: var(--up); }
.ch-seg .cs-barrier.b-mid { background: rgba(255, 184, 77, .14); color: var(--amber); }
.ch-seg .cs-barrier.b-lo { background: rgba(255, 255, 255, .07); color: var(--text-dim); }
.ch-seg .cs-desc { font-size: 11px; color: var(--text-dim); margin-top: 5px; line-height: 1.55; }
.ch-seg .cs-why { font-size: 11px; color: var(--text-faint); margin-top: 4px; line-height: 1.5; }
.ch-seg .cs-stocks { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.ch-seg .cs-stocks span {
  font-size: 10px; color: var(--text-dim); background: rgba(255, 255, 255, .05);
  padding: 2px 6px; border-radius: 5px;
}
.ch-seg .cs-stocks span b { color: var(--text); font-weight: 600; }
.ch-seg .cs-stocks span i { font-style: normal; color: var(--text-faint); font-family: var(--mono); margin-left: 3px; }
.ch-seg .cs-src { font-size: 9px; color: var(--text-faint); margin-top: 6px; opacity: .8; }
@media (max-width: 1000px) {
  .ch-layers { grid-template-columns: 1fr; }
}


/* ===== 学习中心（需求十一 · 画像提炼 + 教训沉淀） ===== */
.learn-wrap { flex: 1; min-height: 0; display: grid; grid-template-columns: 1.15fr 1fr; gap: 12px; padding: 14px 24px 20px; }
.learn-profile .panel-body, .learn-lessons .panel-body { padding: 14px 16px; }
.panel-foot { flex: none; padding: 10px 16px; border-top: 1px solid var(--line-soft); display: flex; justify-content: flex-end; gap: 8px; }

.ln-summary { font-size: 13px; line-height: 1.8; color: var(--text); padding: 4px 6px 12px; border-bottom: 1px dashed var(--line-soft); margin-bottom: 8px; }
.ln-row { display: flex; gap: 12px; padding: 8px 6px; border-bottom: 1px dashed var(--line-soft); }
.ln-row:last-child { border-bottom: none; }
.ln-k { flex: none; width: 96px; font-size: 11px; color: var(--text-faint); padding-top: 3px; }
.ln-v { flex: 1; font-size: 12px; line-height: 1.9; color: var(--text-dim); display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.ln-tag { display: inline-block; padding: 2px 9px; border-radius: 20px; font-size: 11px; background: rgba(0, 231, 210, .08); border: 1px solid rgba(0, 231, 210, .22); color: var(--text); }
.ln-missing { margin-top: 10px; padding: 8px 10px; font-size: 11px; color: #ffb877; background: rgba(255, 184, 77, .07); border: 1px dashed rgba(255, 184, 77, .3); border-radius: 8px; line-height: 1.7; }

.ln-lesson { display: flex; align-items: flex-start; gap: 10px; padding: 8px 10px; border: 1px solid var(--line-soft); border-radius: 9px; margin-bottom: 8px; }
.ln-lesson:last-child { margin-bottom: 0; }
.ln-lesson.done { opacity: .6; }
.ln-l-text { flex: 1; font-size: 12px; line-height: 1.7; color: var(--text); }
.ln-l-btn { flex: none; }
.ln-l-done { flex: none; font-size: 11px; color: var(--down); }

@media (max-width: 1000px) {
  .learn-wrap { grid-template-columns: 1fr; }
}

/* ================= 访问口令登录遮罩（上云部署时显示） ================= */
.login-overlay {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(4, 8, 9, .78);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: none;
  align-items: center; justify-content: center;
  padding: 20px;
}
.login-overlay.show { display: flex; }
.login-card {
  width: 340px; max-width: 92vw;
  background: var(--bg-2);
  border: 1px solid var(--line-soft);
  border-radius: 18px;
  padding: 30px 26px;
  display: flex; flex-direction: column; gap: 14px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .55);
}
.login-logo { font-size: 20px; font-weight: 700; color: var(--text); text-align: center; }
.login-sub { font-size: 12px; color: var(--text-dim); text-align: center; }
#login-password {
  width: 100%; box-sizing: border-box;
  padding: 11px 14px; border-radius: 10px;
  border: 1px solid var(--line-soft);
  background: rgba(255, 255, 255, .04);
  color: var(--text); font-size: 14px; outline: none;
  transition: border-color .2s;
}
#login-password:focus { border-color: var(--accent); }
.login-err { font-size: 12px; color: var(--up); min-height: 16px; text-align: center; }

/* ================= 移动端适配（≤640px，手机 / APK） ================= */
@media (max-width: 640px) {
  body { -webkit-tap-highlight-color: transparent; }

  /* 视图标题：换行 + 精简留白，副标题隐藏省空间 */
  .view-head { flex-wrap: wrap; gap: 6px 10px; padding: 12px 12px 0; }
  .view-head h1 { font-size: 17px; }
  .view-head .vh-sub { display: none; }
  .view-head .vh-right { width: 100%; }

  /* 各视图内容区 padding 统一收窄 */
  .fluid-stats, .tape,
  .status-grid, .wl-grid, .ai-grid, .dock-grid, .screener-grid, .bt-grid,
  .settings-wrap, .board-zone-3, .board-cols,
  .rv-wrap, .mood-summary, .mood-grid, .review-wrap, .tail-wrap, .limitup-wrap {
    padding-left: 12px !important; padding-right: 12px !important;
  }

  /* 顶部指标卡：4 列 → 2 列 */
  .fluid-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .stat-content .stat-value { font-size: 24px; }

  /* 个股问诊 / AI 顾问：侧栏 + 主区 → 单列（原 330px 侧栏在手机太宽） */
  .ai-grid { grid-template-columns: 1fr; overflow-y: auto; }
  .ai-grid .panel { min-height: 0; }

  /* 面板头部精简：隐藏 kicker 说明 */
  .panel-head { padding: 10px 12px 9px; }
  .panel-head .ph-kicker { display: none; }

  /* 自选股工作台：图表高度适配 */
  .kline-canvas-box { height: 200px; }
  .kline-toolbar { flex-wrap: wrap; gap: 6px; }

  /* 表格类横向滚动，避免窄屏溢出 */
  .result-table, .watch-table, .rv-body { overflow-x: auto; }

  /* 按钮在小屏别挤 */
  .sf-actions { flex-wrap: wrap; }

  /* 智能选股：侧栏(条件) + 主区(结果) → 单列整页滚动 */
  .screener-grid { grid-template-columns: 1fr; overflow-y: auto; }
  .screener-grid .panel { min-height: 0; }
  .screener-grid .panel-body { overflow: visible; }

  /* 交易档案：左侧日期栏 + 右侧详情 → 单列整页滚动 */
  .arch-wrap { grid-template-columns: 1fr; overflow-y: auto; }
  .arch-wrap .arch-side { min-height: 170px; }
  .arch-wrap .arch-main { min-height: 420px; }

  /* 交易知识库：正文 + 右侧说明 → 单列，正文给足高度 */
  .know-wrap { grid-template-columns: 1fr; overflow-y: auto; }
  #know-text { min-height: 300px; }

  /* 情绪日报 / 学习中心：多面板单列后整页滚动 */
  .mood-grid { overflow-y: auto; }
  .mood-grid .panel { min-height: 340px; }
  .learn-wrap { overflow-y: auto; }
  .learn-wrap .panel { min-height: 340px; }

  /* 回测指标卡 4 列 → 2 列 */
  .metric-cards { grid-template-columns: repeat(2, 1fr); }

  /* 标题区操作按钮（日期 + 读取/生成）可换行，避免横向溢出 */
  .view-head .vh-right { flex-wrap: wrap; justify-content: flex-end; }

  /* 回测控制栏：运行按钮整行更易点 */
  .bt-controls .btn { flex: 1 1 100%; justify-content: center; }

  /* 持仓诊断输入窄屏弹性伸缩 */
  .sk-bar .sk-input { min-width: 0; }
  .sk-bar .hd-num { width: auto; flex: 1 1 40%; }

  /* 底部抽屉把手在手机上的字号更醒目 */
  #btn-nav-toggle { top: 45%; }
}



