/* Readout — 样式（V4 精品版 · 原创换皮，不使用原品素材）
 * 视觉基调：对标高端金融 SaaS —— 深蓝黑底 / 金·青点缀 / 毛玻璃卡片 /
 * 渐变描边 / 柔和阴影 / 等宽数字 / 克制微动效
 */

:root {
  --bg: #0b0f1a;
  --bg-glow-1: rgba(232, 182, 76, 0.05);
  --bg-glow-2: rgba(53, 208, 197, 0.045);
  --panel: rgba(21, 28, 46, 0.62);
  --panel-solid: #131a2b;
  --panel-deep: rgba(11, 15, 26, 0.55);
  --border: rgba(148, 163, 196, 0.14);
  --border-strong: rgba(148, 163, 196, 0.30);
  --text: #e9edf6;
  --text-dim: #8b94ab;
  --text-faint: #5d667d;
  --gold: #e8b64c;
  --gold-2: #f5d27a;
  --teal: #35d0c5;
  /* V11.1：原版品牌系统校准色（艾玛实测规范）——玫红点缀 + 暖浅灰分区底 */
  --brand: #E8105E;
  --brand-2: #F0127E;
  --bg-warm: #F6F5F2;
  --up: #e5484d;      /* 默认A股语境：红涨 */
  --down: #2fbf71;    /* 绿跌 */
  /* V12：圆角/缓动改由 css/tokens.css 供值（保留旧值兜底） */
  --radius: var(--stcn-r-14, 14px);
  --radius-sm: var(--stcn-r-10, 10px);
  --shadow-1: 0 10px 32px rgba(3, 6, 14, 0.45);
  --shadow-2: 0 16px 48px rgba(3, 6, 14, 0.55);
  --glass-blur: blur(18px) saturate(150%);
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", "JetBrains Mono", Consolas, "Courier New", monospace;
  --ease-out: var(--stcn-ease-main, cubic-bezier(0.22, 0.61, 0.36, 1));
}
body[data-market="us"] {
  --up: #2fbf71;      /* 美股语境：绿涨 */
  --down: #e5484d;
}

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

html { scroll-behavior: smooth; }

body {
  background:
    radial-gradient(1100px 520px at 15% -5%, var(--bg-glow-1), transparent 60%),
    radial-gradient(900px 480px at 90% 8%, var(--bg-glow-2), transparent 62%),
    var(--bg);
  background-attachment: fixed;
  color: var(--text);
  font-family: "PingFang SC", "HarmonyOS Sans SC", "Microsoft YaHei", "Segoe UI", sans-serif;
  font-size: 15px;
  line-height: 1.65;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* 数字统一等宽对齐（价格/置信度/百分比等关键数值） */
.cc-value, .cc-conf-num, .battle-num, .lv-table td, .plan-amount,
.hist-line1 b, .mode-badge, .cc-badge, .report-meta, .hist-count {
  font-variant-numeric: tabular-nums;
}

/* ============ 顶栏 ============ */
.topbar {
  display: flex; justify-content: space-between; align-items: center;
  padding: 13px 26px;
  border-bottom: 1px solid var(--border);
  background: rgba(13, 18, 32, 0.72);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  position: sticky; top: 0; z-index: 10;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand-logo {
  width: 34px; height: 34px; display: flex; align-items: center; justify-content: center;
  border-radius: 10px; color: var(--gold);
  background: linear-gradient(135deg, rgba(232,182,76,.16), rgba(53,208,197,.10));
  border: 1px solid rgba(232, 182, 76, 0.30);
  box-shadow: 0 0 18px rgba(232, 182, 76, 0.10);
}
.brand-logo svg { width: 20px; height: 20px; }
.brand-name {
  font-size: 19px; font-weight: 800; letter-spacing: 0.5px;
  background: linear-gradient(100deg, var(--gold-2), var(--gold) 55%, #c98f2e);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: var(--gold);
}
.brand-slogan { font-size: 12px; color: var(--text-dim); padding-left: 10px; border-left: 1px solid var(--border); }
.topbar-right { display: flex; gap: 12px; align-items: center; font-size: 13px; }
.topbar-right label { display: flex; align-items: center; gap: 6px; color: var(--text-dim); }
.topbar-right label svg { width: 15px; height: 15px; opacity: .75; }
.topbar-right select {
  background: rgba(11, 15, 26, 0.7); color: var(--text);
  border: 1px solid var(--border); border-radius: 8px; padding: 5px 9px;
  font-size: 13px; cursor: pointer; transition: border-color .2s;
}
.topbar-right select:hover { border-color: var(--border-strong); }

/* ============ 容器 / 面板 ============ */
.container { max-width: 880px; margin: 0 auto; padding: 28px 16px 56px; }

.panel {
  background: var(--panel);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px 26px 24px;
  margin-top: 22px;
  box-shadow: var(--shadow-1), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  animation: pageIn .45s var(--ease-out) both;
}
@keyframes pageIn {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}
.panel h2 {
  font-size: 16px; font-weight: 700; margin-bottom: 18px;
  color: var(--text); letter-spacing: .3px;
  display: flex; align-items: center; gap: 8px;
}
.panel h2::before {
  content: ""; width: 4px; height: 16px; border-radius: 2px;
  background: linear-gradient(180deg, var(--gold-2), var(--gold));
  box-shadow: 0 0 10px rgba(232, 182, 76, 0.35);
}

/* ============ 上传区（呼吸动效） ============ */
.dropzone {
  border: 1.5px dashed var(--border-strong); border-radius: var(--radius);
  padding: 52px 24px; text-align: center; cursor: pointer;
  background: var(--panel-deep);
  transition: border-color .25s, background .25s, transform .25s;
  animation: breathe 2.8s ease-in-out infinite;
}
@keyframes breathe {
  0%, 100% { box-shadow: 0 0 0 0 rgba(232, 182, 76, 0), border-color: var(--border-strong); }
  50% { box-shadow: 0 0 26px 2px rgba(232, 182, 76, 0.07), border-color: rgba(232, 182, 76, 0.38); }
}
.dropzone:hover, .dropzone.drag {
  border-color: var(--gold);
  background: rgba(232, 182, 76, 0.05);
  transform: translateY(-1px);
  animation: none;
}
.dropzone:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.dropzone-icon {
  width: 56px; height: 56px; margin: 0 auto 14px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 16px; color: var(--gold);
  background: linear-gradient(135deg, rgba(232,182,76,.14), rgba(232,182,76,.04));
  border: 1px solid rgba(232, 182, 76, 0.28);
}
.dropzone-icon svg { width: 28px; height: 28px; }
.dropzone p { color: var(--text-dim); font-size: 14px; }
.drop-sub { font-size: 12px !important; margin-top: 6px; color: var(--text-faint) !important; }

.preview-wrap { margin-top: 16px; text-align: center; }
.preview-wrap img {
  max-width: 100%; max-height: 420px; border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong);
  box-shadow: var(--shadow-1);
}
.preview-wrap .btn-ghost { margin-top: 14px; }

/* ============ 按钮 ============ */
.btn-primary {
  display: block; width: 100%; margin-top: 20px;
  padding: 13px; font-size: 15px; font-weight: 700; letter-spacing: 1px;
  background: linear-gradient(135deg, var(--gold-2), var(--gold) 60%, #cf9430);
  color: #161509; border: none;
  border-radius: var(--radius-sm); cursor: pointer;
  box-shadow: 0 6px 22px rgba(232, 182, 76, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.35);
  transition: transform .15s var(--ease-out), box-shadow .2s, filter .2s;
}
.btn-primary:disabled { opacity: .32; cursor: not-allowed; box-shadow: none; }
/* V11.1：主按钮 hover 玫红点缀（对齐原版品牌系统主 CTA） */
.btn-primary:not(:disabled):hover {
  filter: brightness(1.06);
  box-shadow: 0 8px 28px rgba(232, 16, 94, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.35);
  transform: translateY(-1px);
}
.btn-primary:not(:disabled):active { transform: scale(0.975); }

.btn-ghost {
  background: rgba(148, 163, 196, 0.05); color: var(--text-dim);
  border: 1px solid var(--border); border-radius: 9px;
  padding: 7px 15px; cursor: pointer; font-size: 13px;
  transition: color .2s, border-color .2s, background .2s, transform .12s;
}
.btn-ghost:hover { color: var(--text); border-color: var(--border-strong); background: rgba(148, 163, 196, 0.10); }
.btn-ghost:active { transform: scale(0.96); }

/* ============ 加载：5 阶段推进 ============ */
.loader { display: flex; flex-direction: column; align-items: center; padding: 26px 0 18px; }
.loader-progress {
  width: min(420px, 92%); height: 5px; border-radius: 999px;
  background: rgba(148, 163, 196, 0.12); overflow: hidden; margin-bottom: 26px;
}
.loader-progress i {
  display: block; height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--brand), var(--brand-2));
  border-radius: 999px;
  box-shadow: 0 0 12px rgba(232, 16, 94, 0.45);
  transition: width .6s var(--ease-out);
}
.loader-steps { display: flex; flex-direction: column; gap: 12px; font-size: 14px; width: min(420px, 92%); }
.loader-step {
  display: flex; align-items: center; gap: 11px;
  color: var(--text-faint); transition: color .3s;
}
.ls-icon { position: relative; width: 20px; height: 20px; flex-shrink: 0; }
.ls-dot {
  position: absolute; inset: 3px; border-radius: 50%;
  border: 2px solid var(--border-strong);
  transition: border-color .3s, background .3s;
}
.ls-check {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  opacity: 0; transform: scale(0.4); transition: opacity .25s, transform .3s var(--ease-out);
  color: var(--brand);
}
.ls-check svg { width: 14px; height: 14px; }
.loader-step.active { color: var(--brand-2); font-weight: 600; }
.loader-step.active .ls-dot {
  border-color: var(--brand);
  animation: dotPulse 1.1s ease-in-out infinite;
}
@keyframes dotPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(232, 16, 94, 0.35); }
  50% { box-shadow: 0 0 0 6px rgba(232, 16, 94, 0); }
}
.loader-step.done { color: var(--text-dim); }
.loader-step.done .ls-dot { border-color: var(--brand); background: rgba(232, 16, 94, 0.2); }
.loader-step.done .ls-check { opacity: 1; transform: scale(1); }

/* ============ 逐条弹出（stagger 入场） ============ */
.reveal {
  animation: revealUp .55s var(--ease-out) both;
  animation-delay: var(--d, 0ms);
}
@keyframes revealUp {
  from { opacity: 0; transform: translateY(16px) scale(0.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* ============ 作战卡三件套 ============ */
.battle-block { margin-bottom: 20px; }
.battle-head {
  display: flex; align-items: center; gap: 8px; margin-bottom: 12px;
  font-size: 14px; font-weight: 700; color: var(--gold);
  letter-spacing: 1px;
}
.battle-head svg { width: 17px; height: 17px; }
.battle-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px;
}
.battle-cell {
  position: relative; overflow: hidden;
  background: var(--panel-deep);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px 16px 14px;
  display: flex; flex-direction: column; gap: 6px;
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  transition: transform .2s var(--ease-out), border-color .2s;
}
.battle-cell:hover { transform: translateY(-2px); }
.battle-cell::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 2px;
}
.battle-entry::before { background: linear-gradient(90deg, var(--gold), rgba(232,182,76,0)); }
.battle-risk::before  { background: linear-gradient(90deg, #ff5a5f, rgba(255,90,95,0)); }
.battle-target::before{ background: linear-gradient(90deg, var(--teal), rgba(53,208,197,0)); }
.battle-label {
  display: flex; align-items: center; gap: 6px;
  font-size: 12px; color: var(--text-dim); letter-spacing: 1px;
}
.battle-label svg { width: 14px; height: 14px; }
.battle-entry .battle-label svg { color: var(--gold); }
.battle-risk .battle-label svg { color: #ff5a5f; }
.battle-target .battle-label svg { color: var(--teal); }
.battle-num {
  font-family: var(--mono);
  font-size: clamp(20px, 3.4vw, 27px);
  font-weight: 700; letter-spacing: 0.5px; line-height: 1.2;
}
.battle-entry .battle-num { color: var(--gold-2); text-shadow: 0 0 18px rgba(232, 182, 76, 0.25); }
.battle-risk .battle-num { color: #ff7b80; }
.battle-target .battle-num { color: var(--teal); }
.battle-note { margin-top: 10px; font-size: 12px; color: var(--text-faint); }

/* ============ 报告头 ============ */
.report-head { display: flex; align-items: center; gap: 8px 10px; flex-wrap: wrap; margin-bottom: 16px; }
/* V19：报告编号/时间/语境那串小字原来挤在 200px 宽的一格里，折成两行还把「语境」拆断。
 * 现在它独占一整行做安静的说明行，徽章与按钮各归其位。 */
.report-meta {
  flex: 1 0 100%; order: 10; font-size: 11.5px; line-height: 1.6;
  color: var(--text-faint); letter-spacing: .01em;
}
.report-head #againBtn { margin-left: auto; }

/* 模式徽章 */
.mode-badge {
  font-size: 12px; font-weight: 600; padding: 4px 12px;
  border-radius: 999px; white-space: nowrap; letter-spacing: .5px;
}
.mode-ai { color: #4ade80; border: 1px solid rgba(74, 222, 128, 0.45); background: rgba(74, 222, 128, 0.10); box-shadow: 0 0 14px rgba(74, 222, 128, 0.10); }
.mode-demo { color: var(--gold-2); border: 1px solid rgba(232, 182, 76, 0.45); background: rgba(232, 182, 76, 0.10); }

/* ============ 结论卡 ============ */
.conclusion-card {
  border: 1px solid var(--border); border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(232, 182, 76, 0.07), rgba(53, 208, 197, 0.04) 55%, rgba(19, 26, 43, 0.35));
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  padding: 18px 20px; margin-bottom: 20px;
  box-shadow: var(--shadow-1), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.cc-main { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
.cc-badge {
  font-size: 16px; font-weight: 800; padding: 7px 20px;
  border-radius: 999px; letter-spacing: 3px;
}
.bias-bull { color: var(--up); border: 1.5px solid var(--up); background: rgba(229, 72, 77, 0.12); box-shadow: 0 0 18px rgba(229, 72, 77, 0.14); }
.bias-bear { color: var(--down); border: 1.5px solid var(--down); background: rgba(47, 191, 113, 0.12); box-shadow: 0 0 18px rgba(47, 191, 113, 0.14); }
.bias-neutral { color: var(--text-dim); border: 1.5px solid var(--text-dim); background: rgba(154, 160, 176, 0.10); }

/* V9：方向倾向徽章（多头=var(--up)、空头=var(--down)：A股语境红涨绿跌，美股语境自动翻转） */
.dir-badge {
  display: inline-flex; flex-direction: column; gap: 3px;
  padding: 8px 18px;
  border-radius: var(--radius-sm);
  background: rgba(127, 132, 156, 0.10);
}
.dir-badge .dir-main { font-size: 17px; font-weight: 800; letter-spacing: 1px; line-height: 1.3; }
.dir-badge .dir-sub { font-size: 11px; font-weight: 500; opacity: 0.72; line-height: 1.4; }
.dir-long {
  color: var(--up);
  border: 1.5px solid var(--up);
  box-shadow: 0 0 16px rgba(229, 72, 77, 0.12);
}
.dir-short {
  color: var(--down);
  border: 1.5px solid var(--down);
  box-shadow: 0 0 16px rgba(47, 191, 113, 0.12);
}
.dir-neutral { color: var(--text-dim); border: 1.5px solid var(--text-dim); }
.cc-conf { flex: 1; min-width: 180px; display: flex; align-items: center; gap: 10px; }
.cc-conf-bar { flex: 1; height: 7px; border-radius: 999px; overflow: hidden; background: rgba(148, 163, 196, 0.12); }
.cc-conf-bar i {
  display: block; height: 100%; border-radius: 999px;
  background: linear-gradient(90deg, var(--gold), var(--gold-2));
  box-shadow: 0 0 10px rgba(232, 182, 76, 0.4);
  animation: barGrow .9s var(--ease-out) both;
}
@keyframes barGrow { from { width: 0 !important; } }
.cc-conf-num { font-size: 12px; color: var(--text-dim); white-space: nowrap; }
.cc-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.cc-cell {
  display: flex; flex-direction: column; gap: 4px;
  background: rgba(11, 15, 26, 0.55); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 10px 13px;
  transition: border-color .2s, transform .2s var(--ease-out);
}
.cc-cell:hover { border-color: var(--border-strong); transform: translateY(-1px); }
.cc-label { font-size: 11px; color: var(--text-faint); letter-spacing: 1px; }
.cc-value { font-size: 13px; font-weight: 600; color: var(--text); line-height: 1.5; }

/* ============ 标注层（双层 Canvas + 扫描线） ============ */
.anno-block { margin-bottom: 20px; }
.anno-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.anno-head h3, .lv-table-block h3, .report-sec h3 {
  font-size: 14px; color: var(--brand); letter-spacing: .5px;
}
.anno-wrap { line-height: 0; }
.anno-stack {
  position: relative; display: inline-block; max-width: 100%;
  border-radius: var(--radius-sm); overflow: hidden;
  border: 1px solid var(--border-strong); box-shadow: var(--shadow-1);
}
.anno-stack canvas { display: block; max-width: 100%; height: auto; }
.anno-stack canvas + canvas { position: absolute; inset: 0; width: 100% !important; height: 100% !important; }
/* 扫描线绘制时的横向高光扫过 */
.anno-stack.anno-drawing::after {
  content: ""; position: absolute; top: 0; bottom: 0; width: 70px;
  background: linear-gradient(90deg, transparent, rgba(232, 182, 76, 0.10), transparent);
  animation: scanSweep 1.5s var(--ease-out) both;
  pointer-events: none;
}
@keyframes scanSweep { from { left: -80px; } to { left: 100%; } }
.anno-none { font-size: 13px; color: var(--text-dim); padding: 14px 0; text-align: center; }

/* ============ 关键位表格 ============ */
.lv-table-block { margin-bottom: 20px; }
.lv-table-block h3 { margin-bottom: 10px; }
.lv-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.lv-table th, .lv-table td {
  text-align: left; padding: 9px 13px;
  border-bottom: 1px solid var(--border);
}
.lv-table th { color: var(--text-faint); font-weight: 500; font-size: 12px; letter-spacing: 1px; }
.lv-table td { font-family: var(--mono); color: var(--text); }
.lv-table tr { transition: background .15s; }
.lv-table tbody tr:hover { background: rgba(148, 163, 196, 0.05); }
.lv-tag {
  display: inline-block; padding: 2px 11px; border-radius: 999px;
  font-size: 12px; font-weight: 700; color: #10131a;
  font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
}
.lv-support { background: #22c55e; }
.lv-resistance { background: #ef4444; color: #fff; }
.lv-entry { background: var(--gold); }
.lv-stop { background: #ff4d4d; color: #fff; }
.lv-target { background: var(--teal); }
.lv-note { margin-top: 8px; font-size: 12px; color: var(--text-faint); }

/* ============ 报告正文 ============ */
.report-sec { margin-bottom: 18px; }
.report-sec h3 { margin-bottom: 8px; }
.report-sec p { font-size: 14px; line-height: 1.85; color: var(--text); }
.report-sec p + p { margin-top: 4px; }

/* ============ 免责声明 ============ */
.disclaimer {
  margin-top: 22px; padding: 14px 16px; font-size: 13px; line-height: 1.75;
  display: flex; gap: 10px; align-items: flex-start;
  background: rgba(232, 182, 76, 0.07);
  border: 1px solid rgba(232, 182, 76, 0.30);
  border-radius: var(--radius-sm); color: var(--gold-2);
}
.disclaimer svg { width: 16px; height: 16px; flex-shrink: 0; margin-top: 3px; }

.footer { text-align: center; margin-top: 30px; font-size: 12px; color: var(--text-faint); }
.hidden { display: none !important; }

/* ============ 弹窗（毛玻璃） ============ */
.modal-mask {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(5, 8, 16, 0.66);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex; align-items: center; justify-content: center; padding: 16px;
  animation: maskIn .25s ease both;
}
@keyframes maskIn { from { opacity: 0; } }
.modal {
  background: linear-gradient(160deg, rgba(26, 34, 54, 0.92), rgba(15, 21, 36, 0.94));
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius); padding: 26px; width: 100%; max-width: 480px;
  box-shadow: var(--shadow-2), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  animation: modalIn .32s var(--ease-out) both;
}
@keyframes modalIn {
  from { opacity: 0; transform: translateY(18px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.modal h2 {
  font-size: 16px; color: var(--gold-2); margin-bottom: 16px; letter-spacing: .5px;
}
.cfg-field { display: block; margin-bottom: 14px; font-size: 13px; color: var(--text-dim); }
.cfg-field span { display: block; margin-bottom: 6px; }
.cfg-field input {
  width: 100%; padding: 10px 13px; font-size: 14px;
  background: rgba(11, 15, 26, 0.7); color: var(--text);
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  font-family: var(--mono);
  transition: border-color .2s, box-shadow .2s;
}
.cfg-field input:focus {
  outline: none; border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(232, 182, 76, 0.12);
}
.cfg-note { font-size: 12px; line-height: 1.7; color: var(--text-faint); margin: 8px 0 16px; }
.cfg-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.cfg-actions .btn-primary { width: auto; margin-top: 0; padding: 10px 22px; white-space: nowrap; }

/* V7：设置面板连接自检 */
.cfg-test-row { display: flex; gap: 10px; margin-bottom: 12px; }
.cfg-test-row .btn-ghost { flex: 1; padding: 9px 14px; }
.cfg-test-result {
  font-size: 13px; line-height: 1.7; border-radius: 10px;
  padding: 10px 14px; margin-bottom: 14px;
  border: 1px solid transparent; word-break: break-all;
}
.cfg-test-result.hidden { display: none; }
.cfg-test-info { color: var(--text-dim); border-color: rgba(255,255,255,.12); background: rgba(255,255,255,.04); }
.cfg-test-ok { color: #4ADE80; border-color: rgba(74,222,128,.35); background: rgba(74,222,128,.08); }
.cfg-test-err { color: #F87171; border-color: rgba(248,113,113,.35); background: rgba(248,113,113,.08); }
.cfg-test-hint { display: block; margin-top: 4px; font-size: 12px; color: var(--text-faint); }

/* V8：配置来源状态行 + Key 掩码行 */
.cfg-source {
  font-size: 13px; line-height: 1.7; border-radius: 10px;
  padding: 9px 14px; margin-bottom: 8px;
  border: 1px solid transparent; word-break: break-all;
}
.cfg-source.hidden { display: none; }
.cfg-source-saved { color: #E8B64C; border-color: rgba(232,182,76,.35); background: rgba(232,182,76,.08); }
.cfg-source-default { color: #4ADE80; border-color: rgba(74,222,128,.35); background: rgba(74,222,128,.08); }
.cfg-source-demo { color: var(--text-dim); border-color: rgba(255,255,255,.12); background: rgba(255,255,255,.04); }
.cfg-source-hint { display: block; margin-top: 4px; font-size: 12px; color: var(--text-faint); }
.cfg-keymask { font-size: 12px; color: var(--text-dim); margin: -2px 0 12px; font-family: var(--mono, monospace); letter-spacing: .3px; }
.cfg-keymask.hidden { display: none; }

/* ============ 弹窗扩展 ============ */
.modal-wide { max-width: 780px; max-height: 86vh; overflow-y: auto; }
.modal-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.modal-head h2 { flex: 1; margin-bottom: 0; }
.btn-danger { color: #ff6b6b; border-color: rgba(255, 107, 107, 0.4); }
.btn-danger:hover { color: #ff4d4d; border-color: #ff4d4d; background: rgba(255, 77, 77, 0.07); }

/* ============ 历史记录 ============ */
.hist-count { font-size: 12px; color: var(--text-dim); }
.hist-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 16px; max-height: 52vh; overflow-y: auto; }
.hist-item {
  display: flex; align-items: center; gap: 12px;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 10px 13px; background: rgba(11, 15, 26, 0.45);
  transition: border-color .2s, transform .2s var(--ease-out), background .2s;
}
.hist-item:hover {
  border-color: var(--border-strong); transform: translateY(-1px);
  background: rgba(21, 28, 46, 0.55);
}
.hist-thumb {
  width: 76px; height: 52px; object-fit: cover;
  border-radius: 7px; border: 1px solid var(--border); flex-shrink: 0;
  background: #0b0f1a;
}
.hist-info { flex: 1; min-width: 0; }
.hist-line1 { display: flex; gap: 10px; align-items: baseline; font-size: 13px; }
.hist-line1 b { color: var(--text); }
.hist-line1 span { color: var(--text-faint); font-size: 12px; }
.hist-line2 {
  margin-top: 3px; font-size: 12px; color: var(--text-dim);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.hist-btns { display: flex; gap: 8px; flex-shrink: 0; }
.hist-empty { text-align: center; color: var(--text-dim); font-size: 13px; padding: 24px 0; }

/* ============ 定价页 ============ */
.pricing-sub { font-size: 12px; color: var(--text-dim); margin-bottom: 18px; }
.pricing-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 14px;
}
.plan-card {
  position: relative; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 22px 18px;
  background: linear-gradient(165deg, rgba(21, 28, 46, 0.6), rgba(11, 15, 26, 0.5));
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  display: flex; flex-direction: column; gap: 12px;
  transition: transform .22s var(--ease-out), border-color .22s, box-shadow .22s;
}
.plan-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-2);
}
.plan-popular {
  border-color: rgba(232, 182, 76, 0.55);
  box-shadow: 0 0 0 1px rgba(232, 182, 76, 0.30), 0 12px 34px rgba(232, 182, 76, 0.10);
}
.plan-popular:hover { border-color: var(--gold); }
.plan-popular-badge {
  position: absolute; top: -11px; left: 50%; transform: translateX(-50%);
  background: linear-gradient(135deg, var(--brand-2), var(--brand)); color: #fff;
  font-size: 11px; font-weight: 800; padding: 3px 13px;
  border-radius: 999px; white-space: nowrap; letter-spacing: 1px;
  box-shadow: 0 4px 14px rgba(232, 16, 94, 0.35);
}
.plan-name { font-size: 15px; font-weight: 700; color: var(--text); }
.plan-price { display: flex; align-items: baseline; gap: 4px; }
.plan-amount {
  font-family: var(--mono);
  font-size: 31px; font-weight: 800; color: var(--gold-2);
  text-shadow: 0 0 20px rgba(232, 182, 76, 0.2);
}
.plan-unit { font-size: 12px; color: var(--text-dim); }
.plan-feats { list-style: none; display: flex; flex-direction: column; gap: 7px; flex: 1; }
.plan-feats li { font-size: 13px; color: var(--text); line-height: 1.5; padding-left: 18px; position: relative; }
.plan-feats li::before {
  content: ""; position: absolute; left: 0; top: 7px;
  width: 7px; height: 7px; border-radius: 2px;
  background: linear-gradient(135deg, var(--gold-2), var(--gold));
  transform: rotate(45deg);
}
.plan-btn { width: 100%; text-align: center; }
.plan-choose.btn-primary { width: 100%; margin-top: 0; padding: 10px; }

/* ============ V5：周期回显与纠正 ============ */
.tf-echo { margin-bottom: 18px; }

/* ============ V6：模式横幅（演示=橙色大警示 / 真实解读=绿色确认条） ============ */
.mode-banner {
  display: flex; align-items: center; gap: 10px;
  padding: 13px 16px; margin-bottom: 18px;
  border-radius: var(--radius-sm);
  font-size: 14px; font-weight: 700; line-height: 1.5;
}
.mode-banner .mb-icon { font-size: 18px; flex: none; }
.mode-banner-demo {
  color: #ffb27a;
  background: linear-gradient(135deg, rgba(255, 138, 76, 0.16), rgba(255, 138, 76, 0.07));
  border: 1.5px solid rgba(255, 138, 76, 0.55);
  box-shadow: 0 0 18px rgba(255, 138, 76, 0.15);
  animation: demo-pulse 2.4s ease-in-out infinite;
}
.mode-banner-ai {
  color: #4ade80;
  background: rgba(74, 222, 128, 0.08);
  border: 1px solid rgba(74, 222, 128, 0.35);
  font-weight: 600;
}
@keyframes demo-pulse {
  0%, 100% { box-shadow: 0 0 14px rgba(255, 138, 76, 0.12); }
  50% { box-shadow: 0 0 26px rgba(255, 138, 76, 0.28); }
}
/* V6：周期条内标的输入框 */
.sym-input {
  width: 150px;
  background: rgba(11, 15, 26, 0.7); color: var(--text);
  border: 1px solid var(--border-strong); border-radius: 8px;
  padding: 5px 9px; font-size: 12px;
  transition: border-color .2s;
}
.sym-input:focus { outline: none; border-color: var(--teal); }

.tf-row {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 11px 15px; font-size: 13px;
  background: rgba(53, 208, 197, 0.06);
  border: 1px solid rgba(53, 208, 197, 0.28);
  border-radius: var(--radius-sm);
}
.tf-row.tf-warn {
  background: rgba(255, 138, 76, 0.07);
  border-color: rgba(255, 138, 76, 0.38);
}
.tf-label { color: var(--text-dim); letter-spacing: .5px; }
.tf-value {
  font-weight: 700; color: var(--teal); font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.tf-row.tf-warn .tf-value { color: #ffb27a; }
.tf-basis { color: var(--text-faint); font-size: 12px; flex: 1; min-width: 180px; }
.tf-correct { display: flex; align-items: center; gap: 7px; color: var(--text-dim); font-size: 12px; margin-left: auto; }
.tf-correct select {
  background: rgba(11, 15, 26, 0.7); color: var(--text);
  border: 1px solid var(--border-strong); border-radius: 8px;
  padding: 5px 9px; font-size: 12px; cursor: pointer;
  transition: border-color .2s;
}
.tf-correct select:hover, .tf-correct select:focus { border-color: var(--gold); outline: none; }
.tf-correct select:disabled { opacity: .45; cursor: not-allowed; }
.tf-guide {
  margin-top: 8px; font-size: 13px; line-height: 1.7; color: #ffb27a;
  padding: 10px 14px; border-radius: var(--radius-sm);
  background: rgba(255, 138, 76, 0.06);
  border: 1px dashed rgba(255, 138, 76, 0.35);
}

/* ============ V5：档位徽章（替代置信度条/伪概率） ============ */
.grade-strip {
  display: flex; align-items: center; gap: 13px;
  padding: 12px 15px; margin-bottom: 12px;
  background: rgba(11, 15, 26, 0.5);
  border: 1px solid var(--border); border-radius: var(--radius-sm);
}
.grade-badge {
  width: 46px; height: 46px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--mono); font-size: 24px; font-weight: 800;
  border-radius: 12px;
}
.grade-badge.grade-sm { width: 30px; height: 30px; font-size: 16px; border-radius: 8px; }
.grade-A {
  color: #35d97a; background: rgba(53, 217, 122, 0.12);
  border: 1.5px solid rgba(53, 217, 122, 0.55);
  box-shadow: 0 0 16px rgba(53, 217, 122, 0.18);
}
.grade-B {
  color: var(--gold-2); background: rgba(232, 182, 76, 0.12);
  border: 1.5px solid rgba(232, 182, 76, 0.55);
  box-shadow: 0 0 16px rgba(232, 182, 76, 0.16);
}
.grade-C {
  color: #a7aec2; background: rgba(154, 160, 176, 0.10);
  border: 1.5px solid rgba(154, 160, 176, 0.45);
}
.grade-texts { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.grade-name { font-size: 14px; font-weight: 700; color: var(--text); }
.grade-desc { font-size: 12px; color: var(--text-dim); line-height: 1.6; }
.grade-note { font-size: 11px; color: var(--text-faint); }
.cc-grade {
  display: flex; align-items: center; gap: 9px; flex-wrap: wrap;
  flex: 1; min-width: 220px;
}
.cc-grade-name { font-size: 13px; font-weight: 700; color: var(--text); }
.cc-grade-note { font-size: 11px; color: var(--text-faint); }

/* ============ V5：暂无 setup 徽章 ============ */
.nosetup-badge {
  margin-left: auto; font-size: 12px; font-weight: 700; letter-spacing: 1px;
  color: #ffb27a; padding: 3px 12px; border-radius: 999px;
  border: 1px solid rgba(255, 138, 76, 0.45);
  background: rgba(255, 138, 76, 0.08);
}

/* ============ V5：IF/THEN 条件卡 ============ */
.ifthen-block, .scen-block { margin-bottom: 20px; }
.block-head h3 { font-size: 14px; color: var(--brand); letter-spacing: .5px; }
.ifthen-grid { display: flex; flex-direction: column; gap: 9px; margin-top: 10px; }
.ifthen-card {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 12px 15px; font-size: 13px; line-height: 1.7;
  background: var(--panel-deep); border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: border-color .2s, transform .2s var(--ease-out);
}
.ifthen-card:hover { border-color: var(--border-strong); transform: translateY(-1px); }
.ifthen-card .if-part { color: var(--text); flex: 1.1; }
.ifthen-card .if-part::before {
  content: "IF"; font-family: var(--mono); font-size: 10px; font-weight: 800;
  color: var(--teal); display: block; letter-spacing: 1.5px; margin-bottom: 2px;
}
.ifthen-card .then-arrow { color: var(--gold); font-size: 15px; align-self: center; flex-shrink: 0; }
.ifthen-card .then-part { color: var(--text-dim); flex: 1; }
.ifthen-card .then-part::before {
  content: "THEN"; font-family: var(--mono); font-size: 10px; font-weight: 800;
  color: var(--gold); display: block; letter-spacing: 1.5px; margin-bottom: 2px;
}

/* ============ V5：三情景价位表 + 仓位换算器 ============ */
.sc-pos-row {
  display: flex; align-items: center; gap: 10px; margin-top: 12px;
  font-size: 13px; color: var(--text-dim);
}
.sc-pos-row input {
  width: 130px; padding: 7px 11px; font-size: 14px;
  font-family: var(--mono); font-variant-numeric: tabular-nums;
  background: rgba(11, 15, 26, 0.7); color: var(--gold-2);
  border: 1px solid var(--border-strong); border-radius: 8px;
  transition: border-color .2s, box-shadow .2s;
}
.sc-pos-row input:focus {
  outline: none; border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(232, 182, 76, 0.12);
}
.sc-table { width: 100%; border-collapse: collapse; font-size: 13px; margin-top: 10px; }
.sc-table th, .sc-table td {
  text-align: left; padding: 9px 13px;
  border-bottom: 1px solid var(--border);
}
.sc-table th { color: var(--text-faint); font-weight: 500; font-size: 12px; letter-spacing: 1px; }
.sc-table td { font-family: var(--mono); font-variant-numeric: tabular-nums; color: var(--text); }
.sc-table .sc-note-row td {
  font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 12px; color: var(--text-faint); padding-top: 0;
}
.sc-tag {
  display: inline-block; padding: 2px 11px; border-radius: 999px;
  font-size: 12px; font-weight: 700; font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
}
.sc-opt { background: rgba(53, 217, 122, 0.16); color: #35d97a; }
.sc-neu { background: rgba(154, 160, 176, 0.14); color: #a7aec2; }
.sc-inv { background: rgba(255, 90, 95, 0.16); color: #ff7b80; }
.sc-pnl.sc-pos { color: #35d97a; font-weight: 700; }
.sc-pnl.sc-neg { color: #ff7b80; font-weight: 700; }
.sc-noentry {
  margin-top: 12px; font-size: 13px; color: #ffb27a;
  padding: 11px 14px; border-radius: var(--radius-sm);
  background: rgba(255, 138, 76, 0.06);
  border: 1px dashed rgba(255, 138, 76, 0.35);
}

/* ============ V10：Onboarding 画像问卷 ============ */
.onb-modal { max-width: 460px; }
.onb-sub { font-size: 13px; color: var(--text-dim); margin: 6px 0 14px; line-height: 1.6; }
.onb-dots { display: flex; gap: 8px; margin-bottom: 16px; }
.onb-dots i {
  width: 26px; height: 4px; border-radius: 2px;
  background: rgba(255, 255, 255, 0.12); transition: background .25s;
}
.onb-dots i.on { background: var(--gold); }
.onb-step { display: flex; flex-direction: column; gap: 16px; }
.onb-q { display: flex; flex-direction: column; gap: 8px; }
.onb-qlabel { font-size: 13px; color: var(--text-faint); letter-spacing: 1px; }
.onb-opts { display: flex; flex-wrap: wrap; gap: 8px; }
.onb-opts button {
  padding: 9px 16px; border-radius: 999px; cursor: pointer;
  font-size: 13px; color: var(--text-dim);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  transition: all .18s;
}
.onb-opts button:hover { border-color: var(--gold); color: var(--text); transform: translateY(-1px); }
.onb-opts button.on {
  background: rgba(232, 182, 76, 0.14);
  border-color: var(--gold); color: var(--gold); font-weight: 700;
  box-shadow: 0 0 0 3px rgba(232, 182, 76, 0.10);
}
.onb-optional { font-size: 12px; color: var(--text-faint); }
.onb-actions {
  display: flex; gap: 10px; margin-top: 20px; align-items: center;
}
.onb-actions #onbNext { flex: 1; }
.onb-actions #onbSkip { margin-left: auto; font-size: 12px; color: var(--text-faint); }
.onb-actions #onbSkip:hover { color: var(--text); }

/* ============ V10：画像徽章（报告页） ============ */
.prof-badge {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 3px 12px 3px 10px; border-radius: 999px;
  background: rgba(53, 208, 197, 0.10);
  border: 1px solid rgba(53, 208, 197, 0.35);
  font-size: 12px; white-space: nowrap;
}
.prof-badge .prof-label {
  color: #35d0c5; font-weight: 700; letter-spacing: 1px;
}
.prof-badge .prof-text { color: var(--text); font-weight: 600; }

/* ============ V10：Wait 信号状态卡 ============ */
.wait-badge {
  margin-left: auto; padding: 3px 14px; border-radius: 999px;
  background: rgba(154, 160, 176, 0.16);
  border: 1px solid rgba(154, 160, 176, 0.45);
  color: #a7aec2; font-size: 12px; font-weight: 800; letter-spacing: 2px;
  font-family: var(--mono);
}
.wait-card {
  margin-top: 14px; padding: 26px 22px; border-radius: var(--radius-sm);
  background: rgba(154, 160, 176, 0.06);
  border: 1px dashed rgba(154, 160, 176, 0.45);
  text-align: center;
}
.wait-card .wait-big {
  font-size: 44px; font-weight: 800; letter-spacing: 3px;
  color: #a7aec2; font-family: var(--mono);
  text-shadow: 0 0 24px rgba(154, 160, 176, 0.35);
}
.wait-card .wait-reason {
  margin-top: 10px; font-size: 14px; color: var(--text); font-weight: 600;
}
.wait-card .wait-tip {
  margin-top: 8px; font-size: 12px; color: var(--text-faint); line-height: 1.6;
}

/* ============ V10：五步研判流程卡 ============ */
.flow-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 12px; margin-top: 4px;
}
.flow-step {
  position: relative; padding: 16px 14px 13px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  transition: transform .2s, border-color .2s, box-shadow .2s;
}
.flow-step:hover {
  transform: translateY(-3px);
  border-color: rgba(232, 182, 76, 0.5);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.35);
}
.flow-num {
  position: absolute; top: 10px; right: 12px;
  font-size: 22px; font-weight: 800; line-height: 1;
  color: rgba(232, 182, 76, 0.28); font-family: var(--mono);
}
.flow-icon { display: block; color: var(--gold); margin-bottom: 9px; }
.flow-icon svg { width: 22px; height: 22px; }
.flow-tname {
  display: block; font-size: 14px; font-weight: 700; color: var(--text);
  margin-bottom: 5px;
}
.flow-desc {
  display: block; font-size: 12px; color: var(--text-dim); line-height: 1.65;
}

/* ============ V11：Game Plan 方案头 + 关键价位卡 + 观察位提示卡 ============ */
/* 说明：色带/药丸语义色固定国际情绪色（获利=绿 / 风险=红），与 K 线红涨绿跌解耦，
   因此关键价位卡目标价固定用绿色 #4ade80，不随市场语境翻转。 */
.plan-hero-block { margin-bottom: 18px; }
.plan-hero {
  padding: 18px 20px 16px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, rgba(232, 182, 76, 0.10), rgba(53, 208, 197, 0.05));
  border: 1px solid rgba(232, 182, 76, 0.35);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.30);
}
/* V11.1：标题行单行排布（对标 ref08）：⧉ 图标 + 标题 + 标的徽章 */
.plan-hero-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.plan-hero-icon { display: inline-flex; color: var(--brand); flex: none; }
.plan-hero-icon svg { width: 18px; height: 18px; }
.plan-hero-title {
  font-size: 17px; font-weight: 800; letter-spacing: .5px; line-height: 1.3;
  color: var(--text);
}
.hero-sym-badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 16px; border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(232, 182, 76, 0.45);
  color: var(--text); font-size: 16px; font-weight: 700;
}
.hero-sym-badge svg { width: 17px; height: 17px; color: var(--gold); flex: none; }
.hero-sym-code { letter-spacing: 0.5px; }
.hero-sym-price {
  font-family: var(--mono); font-size: 16px; font-weight: 800;
  color: var(--gold-2); tabular-nums;
}
.plan-hero-sub { font-size: 12px; color: var(--text-faint); margin-top: 9px; }

/* ============ V11.1：Pick 卡（对标 ref03/ref08：小标题行 → 大字主文案 → 灰说明 → 底部小指标列） ============ */
.pick-head {
  display: flex; align-items: center; gap: 8px; margin-bottom: 12px;
  font-size: 13px; font-weight: 500; color: var(--text-dim);
}
.pick-head svg { width: 16px; height: 16px; color: var(--brand); flex: none; }
.pick-main {
  font-size: 21px; font-weight: 800; color: var(--text);
  letter-spacing: .3px; line-height: 1.35; margin-bottom: 6px;
  font-variant-numeric: tabular-nums;
}
.pick-sub { font-size: 13px; color: var(--text-dim); line-height: 1.65; }
.pick-stats {
  /* V19：4~5 个统计格自适应（盈亏比并入后是 5 个），窄屏自动折行不留空洞 */
  display: grid; grid-template-columns: repeat(auto-fit, minmax(104px, 1fr)); gap: 10px;
  margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--border);
}
.pick-stat { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.pick-stat .pick-stat-label {
  font-size: 11px; color: var(--text-faint); letter-spacing: .5px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.pick-stat .pick-stat-value {
  font-family: var(--mono); font-size: 15px; font-weight: 700;
  color: var(--text); font-variant-numeric: tabular-nums; line-height: 1.3;
}
.pick-stat .pick-stat-note {
  font-size: 10px; color: var(--text-faint); font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
}
.pick-stat-green .pick-stat-value { color: var(--stcn-profit, #2FA356); }
.pick-stat-red .pick-stat-value { color: var(--stcn-loss, #E0444B); }
.pick-stat-neutral .pick-stat-value { color: var(--text); }   /* V19：盈亏比用中性色，不暗示好坏 */

.key-card-block { margin-bottom: 20px; }
/* V11.1：纵排关键价位行（对标 ref05：灰小标签在上 + 大 Bold 数值在下） */
.key-rows { display: flex; flex-direction: column; }
.key-row {
  display: flex; flex-direction: column; gap: 3px;
  padding: 12px 2px 11px;
  border-bottom: 1px solid var(--border);
}
.key-row:last-child { border-bottom: none; }
.key-label {
  font-size: 12px; font-weight: 600; color: var(--text-dim);
  letter-spacing: .5px;
  display: inline-flex; align-items: center; gap: 6px;
}
.key-label svg { width: 14px; height: 14px; }
.key-num {
  font-family: var(--mono); font-size: 24px; font-weight: 800;
  color: var(--text); tabular-nums; line-height: 1.15;
}
/* Target 绿数字（校准绿 #2FA356，色带语义色与 K 线涨跌色解耦，不随市场翻转） */
.key-row-target .key-num {
  color: var(--stcn-profit, #2FA356);
  text-shadow: 0 0 18px rgba(47, 163, 86, 0.22);
}

.watch-card-block { margin-bottom: 20px; }
.watch-card {
  padding: 26px 22px 22px; border-radius: var(--radius-sm);
  text-align: center;
  background: linear-gradient(135deg, rgba(232, 182, 76, 0.08), rgba(232, 182, 76, 0.03));
  border: 1px dashed rgba(232, 182, 76, 0.5);
}
.watch-card .watch-big {
  font-size: 36px; font-weight: 800; letter-spacing: 1px;
  color: var(--gold-2); font-family: var(--mono); tabular-nums;
  text-shadow: 0 0 26px rgba(232, 182, 76, 0.30);
}
.watch-card .watch-cond {
  margin-top: 12px; font-size: 13px; color: var(--text-dim); line-height: 1.7;
}
.watch-card .watch-cond-label { color: var(--gold); font-weight: 700; }
/* Wait 态（图不可读）：灰调，不给价位 */
.watch-card-wait {
  background: rgba(154, 160, 176, 0.06);
  border-color: rgba(154, 160, 176, 0.45);
}
.watch-card-wait .watch-big {
  color: #a7aec2; letter-spacing: 3px;
  text-shadow: 0 0 24px rgba(154, 160, 176, 0.35);
}
.watch-card-wait .watch-cond { color: var(--text); font-weight: 600; }
.watch-card .watch-tip { margin-top: 8px; font-size: 12px; color: var(--text-faint); line-height: 1.6; }

/* ============ V12：合成 K 线演示 + 真实价格刻度开关 ============ */
/* 说明：这两块是 V12 新增，颜色/圆角/动效全部走 css/tokens.css 的 --stcn-* 变量，
   不再写死取值 —— 设计规范改动只需改 tokens.css。 */

/* 上传区次级入口（不抢主按钮） */
.upload-alt {
  display: flex; align-items: center; justify-content: center;
  gap: 10px; margin-top: 12px; flex-wrap: wrap;
}
.upload-alt .btn-ghost { margin-top: 0; }
.upload-alt-hint {
  font-size: 11px; color: var(--text-faint); letter-spacing: .2px;
}

/* 预览图上的"合成演示"徽章 */
.synth-badge {
  display: inline-block; margin-top: 10px; padding: 5px 12px;
  border-radius: var(--stcn-r-pill, 999px);
  font-size: 11px; font-weight: 700; letter-spacing: .4px;
  color: var(--stcn-brand-soft, #f5d8e4);
  background: rgba(221, 20, 94, 0.16);
  border: 1px solid rgba(221, 20, 94, 0.42);
}

/* 标注图工具栏（标题 + 开关 + 下载） */
.anno-tools { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }

/* 真实价格刻度开关：胶囊轨道 + 滑块，克制的描边款 */
.scale-toggle {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 12px; color: var(--text-dim); cursor: pointer;
  user-select: none; -webkit-user-select: none;
  padding: 5px 10px 5px 8px; border-radius: var(--stcn-r-pill, 999px);
  border: 1px solid var(--border);
  background: rgba(148, 163, 196, 0.06);
  transition: border-color var(--stcn-dur-ui, 180ms) ease, background var(--stcn-dur-ui, 180ms) ease;
}
.scale-toggle:hover { border-color: var(--border-strong); }
.scale-toggle input { position: absolute; opacity: 0; width: 0; height: 0; }
.scale-track {
  position: relative; width: 30px; height: 17px; flex: none;
  border-radius: var(--stcn-r-pill, 999px);
  background: rgba(148, 163, 196, 0.22);
  border: 1px solid rgba(148, 163, 196, 0.26);
  transition: background var(--stcn-dur-ui, 180ms) ease, border-color var(--stcn-dur-ui, 180ms) ease;
}
.scale-track i {
  position: absolute; top: 2px; left: 2px; width: 11px; height: 11px;
  border-radius: 50%; background: #cdd4e4;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.45);
  transition: transform var(--stcn-dur-ui, 180ms) var(--stcn-ease-main, cubic-bezier(.16,1,.3,1)),
              background var(--stcn-dur-ui, 180ms) ease;
}
.scale-toggle input:checked ~ .scale-track {
  background: rgba(221, 20, 94, 0.34);
  border-color: rgba(221, 20, 94, 0.62);
}
.scale-toggle input:checked ~ .scale-track i { transform: translateX(13px); background: #fff; }
.scale-toggle input:focus-visible ~ .scale-track { outline: 2px solid var(--stcn-brand, #dd145e); outline-offset: 2px; }
.scale-label { white-space: nowrap; }
.scale-toggle input:checked ~ .scale-label { color: var(--text); }

@media (max-width: 640px) {
  .anno-tools { gap: 8px; }
  .upload-alt { flex-direction: column; gap: 6px; }
}

/* ============ 响应式 ============ */
@media (max-width: 640px) {
  .topbar { flex-direction: column; gap: 10px; padding: 12px 14px; }
  .brand-slogan { display: none; }
  .topbar-right { flex-wrap: wrap; justify-content: center; }
  .panel { padding: 20px 16px; }
  .battle-grid { grid-template-columns: 1fr; }
  .battle-cell { padding: 13px 15px 11px; }
  .ifthen-card { flex-direction: column; gap: 6px; }
  .ifthen-card .then-arrow { transform: rotate(90deg); align-self: flex-start; }
  .flow-grid { grid-template-columns: 1fr; }
  .prof-badge { white-space: normal; }
  /* V11 */
  .plan-hero-title { font-size: 15px; }
  .pick-stats { grid-template-columns: repeat(2, 1fr); }
  .key-num { font-size: 21px; }
  .watch-card .watch-big { font-size: 30px; }
}
/* V14：老板实测"读图没有动态效果"的根因之一 ——
   这里原本用 * 通配把所有 animation / transition 一刀切掉，
   Windows 一旦开启"设置 → 辅助功能 → 视觉效果 → 动画效果"关闭（即 prefers-reduced-motion: reduce），
   整站就变成静态图，用户以为没做动效。
   现在收窄为"只关大幅位移/缩放类装饰动效，保留进度条 + 勾选点亮 + 淡入 stagger"：
   过程信息不再依赖位移动画，且加载器另有文字进度（#loaderNow）。 */
@media (prefers-reduced-motion: reduce) {
  .panel,
  .dropzone,
  .modal { animation: none !important; }
  .reveal {
    animation: fadeInOnly .32s ease both !important;
    animation-delay: var(--d, 0ms) !important;
  }
  .cc-conf-bar i,
  .loader-step.active .ls-dot,
  .demo-pulse { animation: none !important; }
  .btn-primary:active,
  .btn-ghost:active,
  .battle-cell:hover,
  .cc-cell:hover,
  .dropzone:hover,
  .dropzone.drag { transform: none !important; }
  /* 进度条宽度过渡与勾选点亮/透明过渡保持默认（属于"状态变化"，不是大幅位移） */

  /* V15（老板实测问题二）：扫描线在任何系统设置下都必须看得见。
     旧版这里写的是 .anno-scan { animation: none !important; } —— 而 .anno-scan 当时
     根本没有任何元素（死规则），真正被牺牲的是"扫描过程"这个信息本身。
     具体降级样式写在文件末尾（必须排在 V15 基础规则之后，否则被 width:2px 覆盖）。 */
  .anno-stack.anno-drawing::after { animation: scanSweep 1.5s var(--ease-out) both !important; }
}
@keyframes fadeInOnly { from { opacity: .001; } to { opacity: 1; } }

/* ============ V14：加载文字进度（不依赖 CSS 动效） ============ */
/* 老板反馈"读图没有动态效果"：即便系统开了减少动画，这行文字也会逐阶段替换，
   用户始终能看到"正在识别 K 线结构…"这类过程信息。 */
.loader-now {
  font-size: 13px; font-weight: 600; letter-spacing: .5px;
  color: var(--brand-2); text-align: center;
  min-height: 19px; margin-bottom: 12px;
}

/* ============ V14：同图结果缓存提示条 ============ */
.cache-bar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  margin-bottom: 14px; padding: 10px 14px;
  border: 1px dashed var(--border-strong); border-radius: var(--radius-sm);
  background: rgba(148, 163, 196, 0.07);
  font-size: 12.5px; color: var(--text-dim); line-height: 1.5;
}
.cache-bar .cache-ico { font-size: 14px; color: var(--brand-2); }
.cache-bar .cache-text { flex: 1; min-width: 190px; }
.cache-bar .cache-rerun { padding: 5px 12px; font-size: 12px; }

/* ============ V14：方向大字卡（报告最顶部：站哪边 / 依据 / 作废价） ============ */
/* 老板反馈"看完报告不知道买多还是买空"：把方向结论提到最顶部，放大到 22-30px，
   颜色跟市场语境走（--up / --down 已按 A股红涨 / 美股绿涨在 body[data-market] 里切换）。 */
.dir-card {
  --dc: var(--text-dim);
  position: relative; overflow: hidden;
  border: 1.5px solid var(--dc); border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(127, 132, 156, 0.13), rgba(127, 132, 156, 0.03));
  padding: 18px 20px 15px; margin-bottom: 18px;
  box-shadow: var(--shadow-1), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.dir-card.dc-long { --dc: var(--up); }
.dir-card.dc-short { --dc: var(--down); }
.dir-card::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px;
  background: var(--dc); opacity: .9;
}
.dir-card .dc-main {
  font-size: clamp(21px, 4.4vw, 30px); font-weight: 900;
  letter-spacing: 1.2px; line-height: 1.28; color: var(--dc);
}
.dir-card .dc-tag {
  margin-bottom: 3px; font-size: 10px; font-weight: 700;
  letter-spacing: 3px; color: var(--text-faint); text-transform: uppercase;
}
.dir-card .dc-row {
  display: flex; gap: 12px; margin-top: 14px; padding-top: 12px;
  border-top: 1px solid rgba(148, 163, 196, 0.14);
}
.dir-card .dc-k {
  flex: none; width: 76px; padding-top: 2px;
  font-size: 11.5px; color: var(--text-faint); letter-spacing: 1px;
}
.dir-card .dc-v { font-size: 13.5px; font-weight: 600; color: var(--text); line-height: 1.6; }
.dir-card .dc-ev { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 7px; }
.dir-card .dc-ev li { display: flex; gap: 8px; font-size: 13px; color: var(--text); line-height: 1.55; }
.dir-card .dc-check { flex: none; width: 15px; height: 15px; margin-top: 3px; color: var(--dc); }
.dir-card .dc-check svg { width: 13px; height: 13px; display: block; }
.dir-card .dc-note { margin: 12px 0 0; font-size: 11px; color: var(--text-faint); }

@media (max-width: 640px) {
  .dir-card { padding: 15px 15px 13px; }
  .dir-card .dc-row { flex-direction: column; gap: 5px; }
  .dir-card .dc-k { width: auto; }
}

/* ==========================================================================
   V15（2026-10-25 老板实测三项整改）
   --------------------------------------------------------------------------
   1) 模型调用失败错误卡 + 上传图压缩状态（失败不再静默降级演示）
   2) 研判图视觉升级：图表卡 / 标题行 / 报告卡标题条 / 全局等宽数字
   3) 真实扫描线（任何系统动效设置下都能看到）+ 点击放大 lightbox
   设计口径：白卡、圆角 20、阴影 0 4px 24px rgba(0,0,0,.06)、内边距 16。
   ========================================================================== */

/* ---------- 1) 全局数字等宽（修复价格/百分比字宽抖动） ---------- */
body { font-variant-numeric: tabular-nums; }
.cc-now, .cc-chg, .key-num, .watch-card .watch-big, .plan-amount, .battle-num,
.hero-sym-code, .lv-table td, .report-meta, .hist-line1 b, .aie-diag dd {
  font-variant-numeric: tabular-nums;
  letter-spacing: 0;
}
.cc-now, .cc-chg, .key-num, .watch-card .watch-big, .plan-amount, .battle-num, .hero-sym-code {
  font-family: var(--mono);
}

/* ---------- 2) 上传图压缩状态 ---------- */
.prep-status {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 10px; padding: 4px 11px;
  font-size: 12px; line-height: 1.4; letter-spacing: .2px;
  color: var(--text-dim); background: rgba(148, 163, 196, 0.10);
  border: 1px solid var(--border); border-radius: 999px;
  font-variant-numeric: tabular-nums;
}
.prep-status.ok { color: #1f8a4c; background: rgba(47, 163, 86, 0.10); border-color: rgba(47, 163, 86, 0.28); }
.prep-status.warn { color: #b26a00; background: rgba(240, 160, 0, 0.12); border-color: rgba(240, 160, 0, 0.34); }
.prep-status.working { color: var(--brand-2); }
.prep-status.hidden { display: none; }

/* ---------- 3) 模型调用失败错误卡 ---------- */
.ai-error-card {
  margin-top: 16px; padding: 16px;
  border: 1px solid rgba(224, 68, 75, 0.28);
  background: rgba(224, 68, 75, 0.055);
  border-radius: 16px;
}
.ai-error-card.hidden { display: none; }
.aie-head { display: flex; align-items: flex-start; gap: 10px; }
.aie-ico {
  flex: 0 0 auto; width: 22px; height: 22px; margin-top: 1px;
  border-radius: 50%; background: #E0444B; color: #fff;
  font-size: 13px; font-weight: 800; line-height: 22px; text-align: center;
}
.aie-title { font-size: 14px; font-weight: 700; color: var(--text); letter-spacing: .1px; }
.aie-kept { margin-top: 3px; font-size: 12px; line-height: 1.5; color: var(--text-dim); }
.aie-reason {
  margin: 11px 0 13px; padding-left: 32px;
  font-size: 13.5px; line-height: 1.65; color: var(--text);
}
.aie-actions { display: flex; flex-wrap: wrap; gap: 10px; padding-left: 32px; }
.aie-actions .btn-primary { width: auto; margin: 0; padding: 9px 22px; font-size: 13px; letter-spacing: .5px; }
.aie-actions .btn-ghost { padding: 9px 16px; font-size: 13px; }
.aie-diag { margin-top: 12px; padding-top: 11px; border-top: 1px dashed var(--border-strong); }
.aie-diag.hidden { display: none; }
.aie-diag dl {
  display: grid; grid-template-columns: 76px 1fr; gap: 7px 14px;
  margin: 0; font-size: 12px;
}
.aie-diag dt { color: var(--text-faint); }
.aie-diag dd { margin: 0; color: var(--text-dim); word-break: break-all; }

/* ---------- 4) 研判图图表卡（白底 / 圆角 20 / 轻阴影 / 内边距 16） ---------- */
.chart-card {
  background: var(--panel-solid, #ffffff);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
  padding: 16px;
  margin-bottom: 16px;
}
.chart-card-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; margin-bottom: 12px;
}
.chart-card-head.hidden { display: none; }
.cc-head-left { display: flex; align-items: center; gap: 8px; min-width: 0; }
.cc-sym {
  font-size: 15px; font-weight: 800; letter-spacing: -.01em; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.cc-tf {
  flex: 0 0 auto; font-size: 11px; font-weight: 700; letter-spacing: .06em;
  color: var(--text-dim); border: 1px solid var(--border-strong);
  border-radius: 6px; padding: 1px 6px; text-transform: uppercase;
}
/* V19：趋势 chip（结论卡取消后趋势的唯一归属，与「标的 · 周期」同一行） */
.cc-trend {
  flex: 0 0 auto; font-size: 11px; font-weight: 700; letter-spacing: .02em;
  color: var(--text-faint); border: 1px dashed var(--border-strong);
  border-radius: 6px; padding: 1px 7px; white-space: nowrap;
}
.cc-head-right { display: flex; align-items: center; gap: 10px; }
.cc-now { font-size: 22px; font-weight: 800; color: var(--text); letter-spacing: -.02em; }
.cc-chg {
  font-size: 11.5px; font-weight: 700; white-space: nowrap;
  padding: 3px 9px; border-radius: 999px;
  color: #2FA356; background: rgba(47, 163, 86, 0.12);
  border: 1px solid rgba(47, 163, 86, 0.26);
}
.chart-card .anno-head { margin-bottom: 10px; }
.chart-card .anno-head h3 {
  display: flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--text-faint);
}
.chart-card .anno-head h3::before {
  content: ""; width: 3px; height: 12px; border-radius: 2px;
  background: var(--brand); display: inline-block;
}
.chart-card .anno-wrap { background: transparent; border: 0; padding: 0; }
.anno-zoomhint {
  margin-top: 8px; text-align: center;
  font-size: 11.5px; letter-spacing: .02em; color: var(--text-faint);
}
.anno-wrap.hidden { display: none; }

/* 标注层：V15 画布按原图像素渲染，CSS 铺满卡片宽度 */
.anno-stack { display: block; width: 100%; max-width: 100%; cursor: zoom-in; outline: none; }
.anno-stack:focus-visible { outline: 2px solid var(--brand-2); outline-offset: 3px; }
.anno-stack canvas { display: block; width: 100%; height: auto; }
.anno-stack canvas + canvas {
  position: absolute; inset: 0; width: 100% !important; height: 100% !important;
}

/* ---------- 5) 真实扫描线（V15） ----------
   旧版只有一个 1.5s 的柔光条，且 css 里 .anno-scan 是"死规则"（JS 从未创建该元素）；
   现在由 annotate.js 真的插入 <i class="anno-scan">，正常动效下是一条带辉光的竖线扫过。 */
.anno-scan {
  position: absolute; top: 0; bottom: 0; left: 0; width: 2px;
  background: linear-gradient(180deg,
    rgba(240, 180, 41, 0) 0%, rgba(240, 180, 41, .95) 12%,
    #F0B429 50%, rgba(240, 180, 41, .95) 88%, rgba(240, 180, 41, 0) 100%);
  box-shadow: 0 0 18px rgba(240, 180, 41, .55), 0 0 1px rgba(0, 0, 0, .12);
  opacity: 0; pointer-events: none;
  animation: annoScan 1.7s cubic-bezier(.35, 0, .35, 1) .05s both;
}
.anno-scan::after {
  content: ""; position: absolute; top: 0; bottom: 0; right: 2px; width: 72px;
  background: linear-gradient(270deg, rgba(240, 180, 41, 0.22), rgba(240, 180, 41, 0));
}
@keyframes annoScan {
  0%   { left: 0; opacity: 0; }
  10%  { opacity: 1; }
  82%  { opacity: 1; }
  100% { left: 100%; opacity: 0; }
}

/* ---------- 6) 点击放大 Lightbox ---------- */
.lb-mask {
  position: fixed; inset: 0; z-index: 1400;
  display: flex; flex-direction: column;
  background: rgba(12, 11, 15, 0.86);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  opacity: 0; transition: opacity .16s ease;
}
.lb-mask.lb-in { opacity: 1; }
.lb-bar {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px; color: #fff;
}
.lb-title { font-size: 13px; font-weight: 700; letter-spacing: .01em; }
.lb-tip { flex: 1; min-width: 0; font-size: 11.5px; color: rgba(255, 255, 255, .62); }
.lb-tools { display: flex; gap: 6px; }
.lb-btn {
  min-width: 34px; height: 30px; padding: 0 10px;
  border-radius: 8px; border: 1px solid rgba(255, 255, 255, .24);
  background: rgba(255, 255, 255, .08); color: #fff;
  font-size: 13px; font-weight: 600; cursor: pointer;
  transition: background .15s;
}
.lb-btn:hover { background: rgba(255, 255, 255, .18); }
.lb-stage {
  position: relative; flex: 1; overflow: hidden; cursor: grab;
  display: flex; align-items: center; justify-content: center;
  touch-action: none;
}
.lb-stage.lb-grabbing { cursor: grabbing; }
.lb-canvas {
  max-width: none; transform-origin: center center;
  border-radius: 6px; background: #fff;
  box-shadow: 0 22px 64px rgba(0, 0, 0, .55);
  will-change: transform;
}

/* ---------- 7) 报告卡：标题 12px 大写灰字 + 左侧 3px 短色条 ---------- */
.report-sec {
  background: var(--panel-solid, #ffffff);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 16px 18px;
  margin-bottom: 16px;
  box-shadow: 0 2px 14px rgba(0, 0, 0, 0.04);
}
.report-sec h3 {
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 8px;
  font-size: 12px; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--text-faint);
}
.report-sec h3::before {
  content: ""; width: 3px; height: 12px; border-radius: 2px;
  background: var(--brand); display: inline-block;
}
.report-sec p { margin: 0; }
.report-sec p + p { margin-top: 6px; }
.report-body { margin-bottom: 0; }

@media (max-width: 640px) {
  .chart-card { border-radius: 16px; padding: 12px; }
  .cc-now { font-size: 19px; }
  .aie-actions, .aie-reason { padding-left: 0; }
  .aie-head { gap: 8px; }
}

/* ---------- 8) V15：减少动画 → 扫描线降级为「从左到右渐显填充」 ----------
   必须放在 .anno-scan 基础规则之后：同优先级下后者生效。
   不位移、不缩放，只做 clip-path 揭示，前庭敏感用户也安全，但"正在扫描"看得见。 */
@media (prefers-reduced-motion: reduce) {
  .anno-scan {
    left: 0 !important; width: 100% !important;
    background: linear-gradient(90deg, rgba(240, 180, 41, 0.30), rgba(240, 180, 41, 0.06)) !important;
    box-shadow: none !important;
    animation: annoScanFill 1.3s ease-out both !important;
  }
  .anno-scan::after { display: none !important; }
}
@keyframes annoScanFill {
  0%   { clip-path: inset(0 100% 0 0); opacity: 0; }
  18%  { opacity: .95; }
  75%  { opacity: .80; }
  100% { clip-path: inset(0 0 0 0); opacity: 0; }
}

/* ==========================================================================
   V16 · 扫描现场（step-loading）
   —— 老板原话："这个扫描动画不是为了体现我们的响应速度，而是给消费者一种感觉，
      我们背后有一整个团队 / 整套 AI 在给他更新。"

   所以这一版把「进度条」彻底删掉，换成原版那套「图 + 上下往复扫描光带」：
   客户看到的是自己那张图正在被一束光上下来回读，而不是一根百分比条在爬。

   几何与节奏全部来自原版 CSS 实测，不是估的：
     @keyframes scanMove { 0%,to{top:-54px} 50%{top:calc(100% - 52px)} }
     光带高 54px · 4.2s 一个完整往复 · cubic-bezier(.55,0,.24,1)
     drop-shadow(0 0 18px rgba(255,55,95,.72)) · mix-blend-mode:screen · z-index:7
   原版在 2.9s 时挂 scan-paused 并弹摘要，也就是说它认为 2.9~4.2s 是「读完了」的可信区间；
   我们保底等满一个完整往复（4.2s），模型更慢就继续扫 —— 计时器如实走，绝不假装完成。
   ========================================================================== */

/* 关键帧：从画面上方外侧进入，落到下方外侧，再回到起点（上下一个来回） */
@keyframes scanMove {
  0%, 100% { top: -42px; }
  50%      { top: calc(100% - 38px); }
}
/* 减少动画时的替身：不位移、只呼吸，但仍然「看得见在扫」 */
@keyframes scanBreathe {
  0%, 100% { opacity: .28; }
  50%      { opacity: .95; }
}

.scan-stage {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(258px, .7fr);
  gap: 24px;
  align-items: start;
  padding: 6px 0 20px;
}

/* ---------- 左：被扫描的画面 ---------- */
.scan-frame {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  background: #0a0b10;
  border: 1px solid rgba(148, 163, 196, 0.22);
  box-shadow:
    0 18px 46px rgba(0, 0, 0, 0.34),
    inset 0 0 0 1px rgba(255, 255, 255, 0.04);
  isolation: isolate;
}
.scan-frame img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 60vh;
  object-fit: contain;
  background: #0a0b10;
}

/* 读片遮罩：复刻原版 .upload-scan-overlay 的渐变，但额外压暗一档。
   ⚠️ V16 实测教训：原版光带用 mix-blend-mode:screen（只加亮），那是因为原版 UI 与图都偏暗。
   我们客户的截图大量是「白底 K 线图」——screen 叠白底 = 白 + 白 = 完全隐身。
   所以这里先把画面压暗，光带才能跳出来；扫完 .done 时遮罩淡出，形成「读亮了」的收尾。 */
.scan-shade {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 3;
  background:
    radial-gradient(125% 92% at 50% 38%, rgba(0, 0, 0, 0) 34%, rgba(0, 0, 0, 0.18) 100%),
    rgba(8, 10, 18, 0.10);
  transition: opacity .38s ease;
}
.scan-frame.done .scan-shade { opacity: 0; }

/* ---------- 核心：上下往复扫描光带 ---------- */
/* 不依赖混合模式的实体光带：一束锐利白芯 + 玫红渐隐 + 克制辉光。
   无论底图是白底、暗底还是花底，都能看到它在上下刷。 */
.scan-beam {
  position: absolute;
  left: 0;
  right: 0;
  height: 40px;
  z-index: 7;
  pointer-events: none;
  animation: scanMove 4.2s cubic-bezier(.55, 0, .24, 1) infinite;
  will-change: top;
  box-shadow:
    0 0 12px rgba(255, 45, 111, 0.34),
    0 0 30px rgba(255, 45, 111, 0.13);
  background:
    linear-gradient(
      180deg,
      rgba(255, 45, 111, 0) 0%,
      rgba(255, 45, 111, 0.05) 31%,
      rgba(255, 45, 111, 0.40) 44%,
      rgba(255, 255, 255, 0.99) 49.2%,
      #ffffff 49.8%,
      #ffffff 50.2%,
      rgba(255, 255, 255, 0.99) 50.8%,
      rgba(255, 45, 111, 0.40) 56%,
      rgba(255, 45, 111, 0.05) 69%,
      rgba(255, 45, 111, 0) 100%
    );
}
/* 极亮的 1px 核心线：这是「扫描」的视觉锚点，白底暗底都刺得出来 */
.scan-beam::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 1px;
  margin-top: -0.5px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0) 0%, #fff 10%, #fff 90%, rgba(255, 255, 255, 0) 100%);
  box-shadow: 0 0 0 1px rgba(178, 0, 58, 0.30), 0 0 6px #fff, 0 0 16px rgba(255, 45, 111, 0.85);
}

/* ---------- 取景四角 ---------- */
.scan-corner {
  position: absolute;
  width: 16px;
  height: 16px;
  z-index: 8;
  pointer-events: none;
  opacity: .78;
  border: 0 solid var(--brand-2, #f12a75);
  filter: drop-shadow(0 0 6px rgba(232, 16, 94, .6));
}
.scan-corner.c-tl { top: 9px; left: 9px; border-top-width: 2px; border-left-width: 2px; border-top-left-radius: 3px; }
.scan-corner.c-tr { top: 9px; right: 9px; border-top-width: 2px; border-right-width: 2px; border-top-right-radius: 3px; }
.scan-corner.c-bl { bottom: 9px; left: 9px; border-bottom-width: 2px; border-left-width: 2px; border-bottom-left-radius: 3px; }
.scan-corner.c-br { bottom: 9px; right: 9px; border-bottom-width: 2px; border-right-width: 2px; border-bottom-right-radius: 3px; }

/* ---------- 图外状态条（左：状态药丸 / 右：真实耗时） ---------- */
.scan-left { min-width: 0; display: flex; flex-direction: column; }
.scan-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 13px;
  min-height: 30px;
}
.scan-tag {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .2px;
  color: var(--brand-2, #f12a75);
  white-space: nowrap;
  max-width: 72%;
  overflow: hidden;
  text-overflow: ellipsis;
  background: rgba(232, 16, 94, 0.08);
  border: 1px solid rgba(232, 16, 94, 0.22);
  /* 原版同款：文字呼吸 1.7s，让状态「活着」而不是一条死文案 */
  animation: scanTextFade 1.7s ease-in-out infinite;
}
.scan-tag-ico { color: var(--brand-2, #f12a75); flex-shrink: 0; }
@keyframes scanTextFade {
  0%, 100% { opacity: .92; }
  45%      { opacity: .66; }
}

/* ---------- 真实耗时（状态条右侧，等宽数字不跳动） ---------- */
.scan-elapsed {
  display: inline-flex;
  align-items: baseline;
  gap: 1px;
  flex-shrink: 0;
  font-family: var(--mono, ui-monospace, SFMono-Regular, Menlo, monospace);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  color: var(--text-faint);
}
.scan-elapsed i { font-style: normal; opacity: .55; font-size: 10px; }

/* ---------- 右：读图阶段 ---------- */
.scan-side {
  display: flex;
  flex-direction: column;
  padding-top: 4px;
  min-width: 0;
}
.scan-side .loader-now {
  text-align: left;
  margin-bottom: 16px;
  font-size: 13.5px;
  line-height: 1.5;
  min-height: 20px;
}
.scan-side .loader-steps { width: 100%; font-size: 13.5px; gap: 13px; }
.scan-note {
  margin: 18px 0 0;
  padding-top: 14px;
  border-top: 1px dashed rgba(148, 163, 196, 0.22);
  font-size: 11.5px;
  line-height: 1.6;
  color: var(--text-faint);
}

/* 结束态：光带淡出、药丸换成完成（由 JS 加 .done） */
.scan-frame.done .scan-beam { animation: none; opacity: 0; transition: opacity .3s ease; }
.scan-frame.done .scan-tag { animation: none; opacity: .96; }

/* ---------- 响应式 ---------- */
@media (max-width: 860px) {
  .scan-stage { grid-template-columns: 1fr; gap: 18px; }
  .scan-frame img { max-height: 46vh; }
  .scan-side { padding-top: 0; }
  .scan-note { display: none; }
}

/* ---------- 减少动画：不位移，但仍然可见（换呼吸，不是关掉） ---------- */
@media (prefers-reduced-motion: reduce) {
  .scan-beam {
    top: 42%;
    height: 56px;
    animation: scanBreathe 2.4s ease-in-out infinite;
    filter: drop-shadow(0 0 14px rgba(255, 55, 95, 0.6));
  }
  .scan-tag { animation: none; }
  .scan-corner { opacity: .6; }
}

/* ============ 返回营销站入口（Readout 落地页） ============ */
/* 顶栏里的 a.btn-ghost：抹掉链接默认样式，视觉与隔壁按钮一致 */
a.back-link {
  text-decoration: none; display: inline-flex; align-items: center;
  white-space: nowrap;
}
a.back-link::before { content: "\2190"; margin-right: 6px; opacity: .6; }
