/* ==================================================================
   行情 · 策略分析  |  蓝白配色 · 响应式
   设计要点：深色渐变大卡做主视觉锚点、卡片内嵌迷你走势图、
   金融数字统一等宽数字、三档阴影建立层级、加大留白
   ================================================================== */

:root {
  /* ---- 品牌蓝：带渐变的深蓝，比单色更有质感 ---- */
  --brand: #1a6dff;
  --brand-600: #0d4fd4;
  --brand-700: #0a3ba8;
  --brand-grad: linear-gradient(135deg, #2f7dff 0%, #0d4fd4 100%);
  --brand-hero: linear-gradient(135deg, #08286e 0%, #0f47c0 52%, #2a72ff 100%);

  /* ---- 墨蓝中性色阶（偏蓝的灰比纯灰更耐看） ---- */
  --text: #0f2547;
  --text-2: #54688c;
  --text-3: #8698b8;
  --text-4: #b0bfd6;

  /* ---- 表面 ---- */
  --bg: #f5f8fe;
  --card: #ffffff;
  --tint: #f7fafe;
  --line: #e3ecfa;
  --line-2: #eef3fb;

  /* ---- 涨跌：国内习惯 涨红跌绿 ---- */
  --up: #e0393f;
  --down: #0f9d58;
  --warn: #d9870b;
  /* 深色底上用的提亮版 */
  --up-lt: #ff8388;
  --down-lt: #4ade9f;
  --warn-lt: #ffc861;

  --r-lg: 18px;
  --r: 14px;
  --r-sm: 10px;

  /* 三档阴影，用来区分层级 */
  --sh-1: 0 1px 2px rgba(10, 30, 61, .04), 0 2px 8px rgba(10, 30, 61, .04);
  --sh-2: 0 2px 4px rgba(10, 30, 61, .04), 0 12px 32px rgba(10, 30, 61, .07);
  --sh-3: 0 10px 24px rgba(10, 30, 61, .09), 0 28px 64px rgba(10, 30, 61, .13);
  --sh-brand: 0 10px 30px rgba(13, 79, 212, .30);

  --topbar-h: 68px;
  --tabbar-h: 64px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  background-image: linear-gradient(180deg, #eaf1fd 0%, #f5f8fe 320px, #f5f8fe 100%);
  background-attachment: fixed;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
               "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-text-size-adjust: 100%;
}

button, input, select { font-family: inherit; font-size: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--brand); text-decoration: none; }

/* 所有金融数字统一等宽，避免跳动 */
.num, .coin-price, .hero-score span, .hero-stats b, .quote-price .val,
.rank-table td, .reso-cell, .calc-cell b, .signal-item .px,
.level-row .px, .metric b, .ft-score, .coin-change {
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
}

.up { color: var(--up); }
.down { color: var(--down); }
.flat { color: var(--text-2); }
.warn { color: var(--warn); }
/* 深色底（Hero）上用的提亮版 */
.up-lt { color: var(--up-lt); }
.down-lt { color: var(--down-lt); }

/* ============================ 顶栏 ============================ */

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 0 26px;
  background: rgba(255, 255, 255, .86);
  backdrop-filter: saturate(180%) blur(16px);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow .25s, border-color .25s;
}
.topbar.scrolled {
  box-shadow: var(--sh-2);
  border-bottom-color: transparent;
}

.brand { display: flex; align-items: center; gap: 11px; flex-shrink: 0; }
.brand-mark {
  width: 36px; height: 36px;
  border-radius: 11px;
  background: var(--brand-grad);
  color: #fff;
  display: grid; place-items: center;
  font-weight: 700; font-size: 17px;
  box-shadow: 0 4px 14px rgba(26, 109, 255, .40), inset 0 1px 0 rgba(255, 255, 255, .35);
}
.brand-text { display: flex; flex-direction: column; line-height: 1.25; }
.brand-text b { font-size: 15.5px; font-weight: 700; letter-spacing: .2px; }
.brand-text span { font-size: 11px; color: var(--text-3); letter-spacing: .3px; }

.nav { display: flex; gap: 2px; margin-left: 14px; }
.nav button {
  position: relative;
  border: 0; background: transparent;
  padding: 8px 17px;
  border-radius: 999px;
  color: var(--text-2);
  font-size: 14px;
  font-weight: 500;
  transition: .18s;
}
.nav button:hover { background: var(--tint); color: var(--brand-600); }
.nav button.active {
  background: var(--brand-grad);
  color: #fff;
  font-weight: 600;
  box-shadow: 0 4px 14px rgba(26, 109, 255, .32);
}

.top-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }

.src-badge {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 6px 13px;
  border-radius: 999px;
  background: var(--tint);
  border: 1px solid var(--line);
  color: var(--text-2);
  font-size: 12px;
  white-space: nowrap;
}
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--down); flex-shrink: 0; }
.dot.busy { background: var(--warn); animation: pulse 1s infinite; }
@keyframes pulse { 50% { opacity: .3; } }

.btn {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--text-2);
  padding: 7px 16px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
  transition: .18s;
  white-space: nowrap;
}
.btn:hover { border-color: #c9dcfa; color: var(--brand-600); background: #f4f8ff; }
.btn.primary { background: var(--brand-grad); border-color: transparent; color: #fff; box-shadow: 0 4px 14px rgba(26, 109, 255, .30); }
.btn.primary:hover { filter: brightness(1.06); color: #fff; }
.btn:disabled { opacity: .5; cursor: not-allowed; box-shadow: none; }
.btn.small { padding: 5px 13px; font-size: 12px; }

.icon-btn {
  position: relative;
  width: 34px; height: 34px;
  display: grid; place-items: center;
  border: 1px solid var(--line);
  background: #fff; border-radius: 50%;
  color: var(--text-2); transition: .18s;
}
.icon-btn:hover { border-color: #c9dcfa; color: var(--brand-600); background: #f4f8ff; }
.icon-btn svg { width: 16px; height: 16px; }
.icon-btn .badge {
  position: absolute; top: -3px; right: -3px;
  min-width: 16px; height: 16px; padding: 0 4px;
  background: var(--up); color: #fff;
  border-radius: 999px; font-size: 10px; font-style: normal; font-weight: 600;
  display: grid; place-items: center; line-height: 1;
  border: 2px solid #fff; box-sizing: content-box;
}

/* ============================ 主体 ============================ */

.main {
  max-width: 1280px;
  margin: 0 auto;
  padding: 24px 26px 48px;
}

.page { display: none; }
.page.active { display: block; animation: rise .32s cubic-bezier(.22, .61, .36, 1); }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.panel {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-1);
  padding: 22px 24px;
  margin-bottom: 18px;
}
.panel-head {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 14px; margin-bottom: 16px;
}
.panel-head h2, .panel-head h3 {
  margin: 0; font-size: 16px; font-weight: 650; letter-spacing: .2px;
  position: relative; padding-left: 12px;
}
.panel-head h3 { font-size: 14.5px; }
/* 标题左侧的渐变竖条，建立层级感 */
.panel-head h2::before, .panel-head h3::before {
  content: ''; position: absolute; left: 0; top: 50%; transform: translateY(-50%);
  width: 3px; height: 15px; border-radius: 2px; background: var(--brand-grad);
}
.panel-head p { margin: 4px 0 0; padding-left: 12px; font-size: 12.5px; color: var(--text-3); }
.panel-head .sub { font-size: 12px; color: var(--text-3); white-space: nowrap; }

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

/* ============================ 主视觉 Hero ============================ */

.hero {
  position: relative;
  overflow: hidden;
  border-radius: var(--r-lg);
  background: var(--brand-hero);
  color: #fff;
  padding: 26px 30px;
  margin-bottom: 18px;
  box-shadow: var(--sh-brand);
  display: grid;
  grid-template-columns: minmax(240px, 1.25fr) minmax(260px, 1fr);
  gap: 28px;
  align-items: center;
}
/* 右上角的装饰光斑 */
.hero::after {
  content: ''; position: absolute; right: -70px; top: -140px;
  width: 360px; height: 360px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, .16), rgba(255, 255, 255, 0) 68%);
  pointer-events: none;
}

.hero-main { position: relative; z-index: 1; min-width: 0; }
.hero-label {
  font-size: 12px; letter-spacing: 1.2px; text-transform: uppercase;
  color: rgba(255, 255, 255, .68); margin-bottom: 8px;
}
.hero-score { display: flex; align-items: baseline; gap: 10px; }
.hero-score b { font-size: 30px; font-weight: 700; letter-spacing: 1px; }
.hero-score span { font-size: 46px; font-weight: 700; letter-spacing: -1.6px; line-height: 1; }
.hero-score em { font-style: normal; font-size: 14px; color: rgba(255, 255, 255, .62); }

.hero-bar {
  display: flex; height: 8px; border-radius: 999px; overflow: hidden;
  margin: 16px 0 9px; background: rgba(255, 255, 255, .16);
}
.hero-bar i { display: block; height: 100%; transition: width .6s cubic-bezier(.22,.61,.36,1); }
.hero-legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: 12px; color: rgba(255, 255, 255, .80); }
.hero-legend span { display: inline-flex; align-items: center; gap: 6px; }
.hero-legend i { width: 7px; height: 7px; border-radius: 2px; }

.hero-stats {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px;
}
.hero-stats div {
  background: rgba(255, 255, 255, .11);
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: var(--r-sm);
  padding: 11px 14px;
  backdrop-filter: blur(4px);
}
.hero-stats span { display: block; font-size: 11.5px; color: rgba(255, 255, 255, .66); }
.hero-stats b {
  display: block; font-size: 18px; font-weight: 700; margin-top: 2px;
  letter-spacing: -.2px; font-variant-numeric: tabular-nums;
}

/* ============================ 工具条 ============================ */

.toolbar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.search {
  flex: 1; min-width: 190px;
  display: flex; align-items: center; gap: 9px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 16px;
  transition: .18s;
}
.search:focus-within { border-color: #bcd4fb; box-shadow: 0 0 0 4px rgba(26, 109, 255, .10); }
.search input { border: 0; outline: 0; background: transparent; width: 100%; font-size: 13px; }
.search svg { flex-shrink: 0; opacity: .4; }

.seg { display: flex; background: var(--tint); border: 1px solid var(--line); border-radius: 999px; padding: 3px; gap: 2px; }
.seg button {
  border: 0; background: transparent; color: var(--text-2);
  padding: 6px 15px; border-radius: 999px; font-size: 12.5px; font-weight: 500;
  transition: .18s; white-space: nowrap;
}
.seg button:hover { color: var(--brand-600); }
.seg button.active {
  background: #fff; color: var(--brand-600); font-weight: 600;
  box-shadow: 0 1px 3px rgba(10, 30, 61, .10);
}

/* ============================ 币种卡片 ============================ */

.market-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(246px, 1fr)); gap: 14px; }

.coin-card {
  position: relative;
  overflow: hidden;
  text-align: left;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 19px 18px 12px;
  box-shadow: var(--sh-1);
  transition: transform .2s cubic-bezier(.22,.61,.36,1), box-shadow .2s, border-color .2s;
}
/* 顶部方向指示条：一眼看出这张卡偏多/偏空/中性 */
.coin-card::before {
  content: ''; position: absolute; left: 0; right: 0; top: 0; height: 3px;
  background: var(--text-4);
}
.coin-card.bullish::before { background: linear-gradient(90deg, var(--up), #ff8085); }
.coin-card.bearish::before { background: linear-gradient(90deg, var(--down), #4ade9f); }
.coin-card.neutral::before { background: linear-gradient(90deg, var(--warn), #ffc861); }
.coin-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--sh-3);
  border-color: #cfe0fb;
}

.coin-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.coin-sym { font-weight: 680; font-size: 15px; letter-spacing: .3px; }
.coin-sym small { color: var(--text-4); font-weight: 500; font-size: 11.5px; }
.coin-change {
  font-size: 12.5px; font-weight: 650; padding: 2px 9px; border-radius: 7px;
  font-variant-numeric: tabular-nums;
}
.coin-change.up { background: rgba(224, 57, 63, .10); color: var(--up); }
.coin-change.down { background: rgba(15, 157, 88, .10); color: var(--down); }

.coin-price { font-size: 25px; font-weight: 700; margin-top: 8px; letter-spacing: -.6px; }

/* 卡片内嵌迷你走势图 */
.spark { display: block; width: 100%; height: 36px; margin: 7px 0 3px; overflow: visible; }

.prob-bar { display: flex; height: 5px; border-radius: 999px; overflow: hidden; margin: 8px 0 10px; background: var(--line-2); }
.prob-bar i { display: block; height: 100%; transition: width .5s; }

.coin-meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 11.5px; color: var(--text-3); }
.tag {
  display: inline-block; padding: 3px 10px; border-radius: 7px;
  font-size: 11.5px; font-weight: 650; background: var(--tint); color: var(--text-2);
}
.tag.up { background: rgba(224, 57, 63, .10); color: var(--up); }
.tag.down { background: rgba(15, 157, 88, .10); color: var(--down); }
.tag.warn { background: rgba(217, 135, 11, .12); color: var(--warn); }
.tag.brand { background: rgba(26, 109, 255, .10); color: var(--brand-600); }

.coin-rec {
  margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--line);
  font-size: 11.5px; color: var(--text-2); line-height: 1.5;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

/* ============================ 信号流 ============================ */

.signal-feed { display: flex; flex-direction: column; gap: 8px; max-height: 340px; overflow-y: auto; }
.signal-item {
  display: flex; align-items: center; gap: 12px;
  padding: 9px 14px; border-radius: var(--r-sm);
  background: var(--tint); border: 1px solid var(--line-2);
  font-size: 13px; transition: .16s;
}
.signal-item:hover { background: #fff; box-shadow: var(--sh-1); }
.signal-item.bullish { border-left: 3px solid var(--up); }
.signal-item.bearish { border-left: 3px solid var(--down); }
.signal-item.neutral { border-left: 3px solid var(--warn); }
.signal-item .sym { font-weight: 650; min-width: 74px; }
.signal-item .txt { flex: 1; color: var(--text-2); }
.signal-item .px { color: var(--text); font-weight: 600; }
.signal-item .tm { font-size: 11px; color: var(--text-3); white-space: nowrap; }
.signal-item .go {
  border: 0; background: rgba(26, 109, 255, .10); color: var(--brand-600);
  padding: 4px 12px; border-radius: 7px; font-size: 11.5px; font-weight: 600;
  white-space: nowrap; transition: .16s;
}
.signal-item .go:hover { background: var(--brand); color: #fff; }

/* ============================ 研判页 ============================ */

.chip-row { display: flex; gap: 9px; overflow-x: auto; padding-bottom: 6px; margin-bottom: 16px; scrollbar-width: none; }
.chip-row::-webkit-scrollbar { display: none; }
.chip {
  flex-shrink: 0; border: 1px solid var(--line); background: #fff; color: var(--text-2);
  padding: 7px 17px; border-radius: 999px; font-size: 13px; font-weight: 500; transition: .18s;
}
.chip:hover { border-color: #c9dcfa; color: var(--brand-600); }
.chip.active {
  background: var(--brand-grad); border-color: transparent; color: #fff; font-weight: 600;
  box-shadow: 0 4px 14px rgba(26, 109, 255, .30);
}

/* 报价头部面板：极淡的蓝白渐变，让它从其他白卡里跳出来 */
.quote-panel { background: linear-gradient(135deg, #f4f8ff 0%, #ffffff 62%); }

.quote-head {
  display: grid;
  grid-template-columns: minmax(200px, 1.05fr) minmax(190px, 1fr) minmax(200px, 1.1fr);
  gap: 26px;
  align-items: center;
}
.quote-price .sym { font-size: 11.5px; color: var(--text-3); letter-spacing: .6px; }
.quote-price .val { font-size: 44px; font-weight: 700; letter-spacing: -1.8px; line-height: 1.1; margin: 2px 0 4px; }
.quote-price .chg { font-size: 14px; font-weight: 650; }

.score-box { display: flex; align-items: center; gap: 16px; }
.score-ring { width: 84px; height: 84px; flex-shrink: 0; }
.score-info b { display: block; font-size: 21px; font-weight: 700; }
.score-info span { font-size: 12px; color: var(--text-3); }

.plan-box { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.plan-item { background: var(--tint); border: 1px solid var(--line-2); border-radius: var(--r-sm); padding: 10px 14px; }
.plan-item span { display: block; font-size: 11px; color: var(--text-3); }
.plan-item b { font-size: 16px; font-weight: 700; }
.plan-item em { font-style: normal; font-size: 11px; color: var(--text-2); }
.plan-item .go {
  border: 0; background: var(--brand-grad); color: #fff;
  padding: 5px 12px; border-radius: 7px; font-size: 11.5px; font-weight: 600;
  box-shadow: 0 3px 10px rgba(26, 109, 255, .28);
}
.plan-item .go:hover { filter: brightness(1.07); }

.frame-tabs { display: flex; gap: 10px; margin-bottom: 18px; flex-wrap: wrap; }
.frame-tab {
  flex: 1; min-width: 150px; text-align: left;
  border: 1px solid var(--line); background: #fff; border-radius: var(--r);
  padding: 12px 16px; transition: .18s;
}
.frame-tab:hover { border-color: #cfe0fb; box-shadow: var(--sh-1); }
.frame-tab.active {
  border-color: var(--brand); background: #f4f8ff;
  box-shadow: 0 0 0 4px rgba(26, 109, 255, .09);
}
.frame-tab .ft-name { font-size: 12px; color: var(--text-3); display: flex; justify-content: space-between; gap: 8px; }
.frame-tab .ft-score { font-size: 19px; font-weight: 700; margin-top: 3px; letter-spacing: -.3px; }
.frame-tab .ft-sub { font-size: 11px; color: var(--text-3); }

/* K 线 */
.chart-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.chart-bar .seg button { padding: 5px 13px; font-size: 12px; }
.chart-toggle { display: flex; gap: 14px; margin-left: auto; flex-wrap: wrap; }
.chart-toggle label {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; color: var(--text-2); cursor: pointer; user-select: none;
}
.chart-toggle input { accent-color: var(--brand); width: 14px; height: 14px; }

.kline-box {
  position: relative; width: 100%;
  background: linear-gradient(180deg, #fbfcff 0%, #ffffff 100%);
  border: 1px solid var(--line-2);
  border-radius: var(--r-sm);
  padding: 4px;
}
.kline-box canvas { display: block; width: 100%; border-radius: 8px; touch-action: none; }
.kline-tip {
  position: absolute; pointer-events: none;
  background: rgba(10, 30, 61, .94); color: #fff;
  padding: 8px 12px; border-radius: 9px; font-size: 11.5px; line-height: 1.65;
  white-space: nowrap; z-index: 5; display: none;
  box-shadow: 0 8px 24px rgba(10, 30, 61, .30);
}
.kline-tip.show { display: block; }
.kline-legend { display: flex; gap: 16px; font-size: 11.5px; color: var(--text-3); margin-top: 10px; flex-wrap: wrap; }
.kline-legend i { display: inline-block; width: 13px; height: 2.5px; vertical-align: middle; margin-right: 5px; border-radius: 2px; }

/* 指标网格 */
.metric-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(196px, 1fr)); gap: 10px; }
.metric {
  border: 1px solid var(--line-2); border-radius: var(--r-sm);
  padding: 11px 14px; background: var(--tint);
  transition: .16s;
}
.metric:hover { background: #fff; box-shadow: var(--sh-1); }
.metric span { display: block; font-size: 11.5px; color: var(--text-3); }
.metric b { display: block; font-size: 13.5px; font-weight: 650; margin-top: 3px; word-break: break-all; }
.metric em { display: block; font-style: normal; font-size: 11px; color: var(--text-3); margin-top: 2px; }

/* 支撑阻力 */
.level-list { display: flex; flex-direction: column; gap: 7px; }
.level-row {
  display: grid; grid-template-columns: 1fr auto auto;
  gap: 12px; align-items: center;
  padding: 9px 14px; border-radius: var(--r-sm);
  background: var(--tint); border: 1px solid var(--line-2);
  font-size: 13px;
}
.level-row.r { border-left: 3px solid var(--up); }
.level-row.s { border-left: 3px solid var(--down); }
.level-row.now { border-left: 3px solid var(--brand); background: rgba(26, 109, 255, .07); font-weight: 650; border-color: rgba(26, 109, 255, .18); }
.level-row.fib { border-left: 3px solid var(--warn); }
.level-row .lbl { color: var(--text-2); font-size: 12px; }
.level-row .px { font-weight: 650; }
.level-row .pct { font-size: 11.5px; color: var(--text-3); min-width: 74px; text-align: right; }
.level-row .pct .act {
  border: 0; background: transparent; font-size: 12px; padding: 0 3px;
  line-height: 1; vertical-align: middle; transition: .15s;
}
.level-row .pct .act:hover { transform: scale(1.28); }

/* 理由列表 */
.reason-list { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; }
.reason-list li {
  display: flex; gap: 10px; align-items: flex-start;
  font-size: 13px; color: var(--text-2);
  padding: 8px 13px; background: var(--tint); border-radius: var(--r-sm);
  border: 1px solid var(--line-2);
}
.reason-list li i { font-style: normal; flex-shrink: 0; width: 16px; text-align: center; }

/* ============================ 策略页 ============================ */

.strategy-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(272px, 1fr)); gap: 14px; }
.strategy-card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r);
  padding: 18px; box-shadow: var(--sh-1); transition: .2s;
}
.strategy-card:hover { box-shadow: var(--sh-2); border-color: #cfe0fb; }
.strategy-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.strategy-head b { font-size: 15.5px; font-weight: 680; }
.strategy-score { text-align: right; }
.strategy-score strong { font-size: 27px; font-weight: 700; letter-spacing: -.8px; font-variant-numeric: tabular-nums; }
.strategy-score span { display: block; font-size: 11px; color: var(--text-3); margin-top: -5px; }
.strategy-desc { font-size: 12px; color: var(--text-3); margin: 9px 0 11px; line-height: 1.55; }
.score-track { height: 7px; border-radius: 999px; background: var(--line-2); overflow: hidden; }
.score-track i { display: block; height: 100%; border-radius: 999px; transition: width .6s cubic-bezier(.22,.61,.36,1); }
.strategy-tip {
  margin-top: 12px; padding: 10px 13px; border-radius: var(--r-sm);
  background: #f4f8ff; border: 1px solid var(--line-2);
  font-size: 12px; color: var(--brand-700); line-height: 1.55;
}

.rank-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.rank-table th {
  text-align: left; font-weight: 600; font-size: 11.5px; color: var(--text-3);
  letter-spacing: .4px; padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap;
}
.rank-table td { padding: 11px 12px; border-bottom: 1px solid var(--line-2); white-space: nowrap; }
.rank-table tbody tr { transition: background .16s; }
.rank-table tbody tr:hover { background: #f6faff; }
.rank-badge {
  display: inline-block; padding: 3px 10px; border-radius: 7px; font-size: 11.5px; font-weight: 650;
  font-variant-numeric: tabular-nums;
}
.rank-badge.bullish { background: rgba(224, 57, 63, .10); color: var(--up); }
.rank-badge.bearish { background: rgba(15, 157, 88, .10); color: var(--down); }
.rank-badge.neutral { background: var(--tint); color: var(--text-2); }

.mini-track { width: 80px; height: 6px; border-radius: 999px; background: var(--line-2); overflow: hidden; display: inline-block; vertical-align: middle; }
.mini-track i { display: block; height: 100%; border-radius: 999px; }

/* 共振矩阵 */
.reso-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.reso-table th {
  text-align: center; font-weight: 600; font-size: 11.5px; color: var(--text-3);
  letter-spacing: .4px; padding: 10px 10px; border-bottom: 1px solid var(--line); white-space: nowrap;
}
.reso-table th:first-child, .reso-table td:first-child { text-align: left; }
.reso-table td { padding: 10px; border-bottom: 1px solid var(--line-2); text-align: center; white-space: nowrap; }
.reso-table tbody tr { transition: background .16s; }
.reso-table tbody tr:hover { background: #f6faff; }
.reso-cell {
  display: inline-block; min-width: 56px; padding: 4px 11px;
  border-radius: 7px; font-weight: 650;
}
.reso-cell.bullish { background: rgba(224, 57, 63, .10); color: var(--up); }
.reso-cell.bearish { background: rgba(15, 157, 88, .10); color: var(--down); }
.reso-cell.neutral { background: var(--tint); color: var(--text-2); }
.reso-tag {
  display: inline-block; padding: 3px 10px; border-radius: 7px;
  font-size: 11px; font-weight: 650;
}
.reso-tag.syn-long { background: var(--up); color: #fff; box-shadow: 0 2px 8px rgba(224, 57, 63, .28); }
.reso-tag.syn-short { background: var(--down); color: #fff; box-shadow: 0 2px 8px rgba(15, 157, 88, .28); }
.reso-tag.diverge { background: rgba(217, 135, 11, .14); color: var(--warn); }

/* ============================ 表单 ============================ */

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; margin-bottom: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field span { font-size: 11.5px; color: var(--text-3); }
.field input, .field select {
  border: 1px solid var(--line); border-radius: var(--r-sm);
  padding: 9px 13px; font-size: 13px; outline: 0; background: #fff;
  transition: .18s; width: 100%;
}
.field input:focus, .field select:focus {
  border-color: #bcd4fb; box-shadow: 0 0 0 4px rgba(26, 109, 255, .10);
}
.actions { display: flex; gap: 9px; flex-wrap: wrap; margin-bottom: 16px; }

/* ============================ 计算结果 ============================ */

.calc-result {
  border-top: 1px dashed var(--line); padding-top: 16px;
  display: grid; grid-template-columns: 1fr 1fr; gap: 11px;
}
.calc-cell { background: var(--tint); border: 1px solid var(--line-2); border-radius: var(--r-sm); padding: 11px 14px; }
.calc-cell span { display: block; font-size: 11px; color: var(--text-3); }
.calc-cell b { font-size: 19px; font-weight: 700; letter-spacing: -.3px; }
.calc-cell em { display: block; font-style: normal; font-size: 11px; color: var(--text-2); margin-top: 1px; }
.calc-cell.hi { background: var(--brand-grad); border-color: transparent; box-shadow: 0 6px 18px rgba(26, 109, 255, .26); }
.calc-cell.hi span { color: rgba(255, 255, 255, .78); }
.calc-cell.hi b { color: #fff; }
.calc-cell.hi em { color: rgba(255, 255, 255, .82); }
.calc-warn { grid-column: 1 / -1; display: flex; flex-direction: column; gap: 7px; }
.calc-warn p { margin: 0; padding: 9px 13px; border-radius: var(--r-sm); font-size: 12px; line-height: 1.55; }
.calc-warn p.warn { background: #fdf7ec; border: 1px solid #f5e3c0; color: #8a5b06; }
.calc-warn p.bad { background: #fdf1f2; border: 1px solid #f7d0d3; color: #a02630; }
.calc-warn p.good { background: #eefaf4; border: 1px solid #c9ecdc; color: #0b7043; }

/* ============================ 预警 / 自选 ============================ */

.alert-item {
  display: flex; align-items: center; gap: 11px;
  padding: 11px 14px; border-radius: var(--r-sm);
  border: 1px solid var(--line-2); background: var(--tint); margin-bottom: 9px;
  transition: .16s;
}
.alert-item:hover { background: #fff; box-shadow: var(--sh-1); }
.alert-item.hit { background: #eefaf4; border-color: #c9ecdc; }
.alert-item.off { opacity: .55; }
.alert-main { flex: 1; min-width: 0; }
.alert-main b { font-size: 13.5px; }
.alert-main span { display: block; font-size: 11.5px; color: var(--text-3); margin-top: 1px; }
.alert-item .act {
  border: 0; background: transparent; color: var(--text-3);
  font-size: 12px; padding: 5px 9px; border-radius: 7px; white-space: nowrap; transition: .16s;
}
.alert-item .act:hover { background: #f0f6ff; color: var(--brand-600); }
.alert-item .act.del:hover { background: #fdf1f2; color: var(--up); }

.watch-list { display: flex; flex-wrap: wrap; gap: 9px; }
.watch-item {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 11px 7px 15px; border-radius: 999px;
  border: 1px solid var(--line); background: #fff; font-size: 13px;
  transition: .16s;
}
.watch-item:hover { border-color: #cfe0fb; box-shadow: var(--sh-1); }
.watch-item b { font-weight: 650; }
.watch-item button { border: 0; background: transparent; color: var(--text-4); font-size: 16px; line-height: 1; padding: 0 2px; }
.watch-item button:hover { color: var(--up); }

/* ============================ 状态 ============================ */

.empty { text-align: center; padding: 48px 20px; color: var(--text-3); font-size: 13px; }
.empty.sm { padding: 24px 16px; font-size: 12.5px; }
.spinner {
  width: 24px; height: 24px; margin: 0 auto 14px;
  border: 2.5px solid var(--line); border-top-color: var(--brand);
  border-radius: 50%; animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.notice {
  background: #fdf7ec; border: 1px solid #f5e3c0; color: #8a5b06;
  padding: 11px 15px; border-radius: var(--r-sm); font-size: 12.5px;
  margin-top: 14px; margin-bottom: 0; line-height: 1.55;
}

.foot-note { text-align: center; font-size: 11.5px; color: var(--text-4); padding: 10px 0 0; line-height: 1.75; }

.toast {
  position: fixed; left: 50%; bottom: calc(var(--tabbar-h) + 22px);
  transform: translate(-50%, 22px);
  background: rgba(10, 30, 61, .95); color: #fff;
  padding: 11px 22px; border-radius: 999px; font-size: 13px;
  opacity: 0; pointer-events: none; transition: .28s cubic-bezier(.22,.61,.36,1); z-index: 200;
  max-width: 86vw; text-align: center;
  box-shadow: 0 10px 30px rgba(10, 30, 61, .28);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ============================ 底部导航（移动端） ============================ */

.tabbar {
  display: none;
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
  height: var(--tabbar-h);
  background: rgba(255, 255, 255, .94);
  backdrop-filter: saturate(180%) blur(16px);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom);
  box-shadow: 0 -2px 16px rgba(10, 30, 61, .05);
}
.tabbar button {
  position: relative;
  flex: 1; border: 0; background: transparent;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  color: var(--text-3); font-size: 11px; padding: 8px 0;
  transition: .18s;
}
.tabbar button.active { color: var(--brand-600); font-weight: 600; }
/* 激活指示条 */
.tabbar button::before {
  content: ''; position: absolute; top: 0; left: 50%; transform: translateX(-50%) scaleX(0);
  width: 26px; height: 2.5px; border-radius: 0 0 3px 3px;
  background: var(--brand-grad); transition: transform .22s cubic-bezier(.22,.61,.36,1);
}
.tabbar button.active::before { transform: translateX(-50%) scaleX(1); }
.tabbar svg { width: 21px; height: 21px; }

/* ============================ 响应式 ============================ */

@media (max-width: 1100px) {
  .hero { grid-template-columns: 1fr; gap: 20px; }
  .hero-stats { grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 1000px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .quote-head { grid-template-columns: 1fr; gap: 18px; }
}

@media (max-width: 720px) {
  .topbar { padding: 0 15px; gap: 10px; }
  .brand-text { display: none; }
  .nav { display: none; }
  .main { padding: 16px 15px calc(var(--tabbar-h) + 26px); }
  .tabbar { display: flex; }
  .panel { padding: 17px 18px; border-radius: var(--r); }
  .market-grid { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 11px; }
  .coin-card { padding: 14px 15px 11px; }
  .coin-price { font-size: 21px; }
  .spark { height: 34px; }
  .quote-price .val { font-size: 38px; }
  .metric-grid { grid-template-columns: repeat(auto-fill, minmax(155px, 1fr)); }
  .frame-tab { min-width: calc(50% - 5px); }
  .strategy-grid { grid-template-columns: 1fr; }
  .toast { bottom: calc(var(--tabbar-h) + 18px); }
  .rank-table { font-size: 12px; }
  .rank-table th, .rank-table td { padding: 9px 8px; }
  .src-badge span.long { display: none; }
  .toolbar { gap: 9px; }

  .hero { padding: 22px 20px; margin-bottom: 16px; }
  .hero-stats { grid-template-columns: 1fr 1fr; }
  .hero-score span { font-size: 38px; }
  .hero-score b { font-size: 25px; }

  .form-grid { grid-template-columns: 1fr; }
  .calc-result { grid-template-columns: 1fr 1fr; }
  .signal-feed { max-height: 300px; }
  .signal-item { flex-wrap: wrap; gap: 6px 12px; }
  .signal-item .txt { flex: 1 1 100%; order: 3; }
  .signal-item .tm { order: 4; margin-left: auto; }
  .chart-toggle { margin-left: 0; width: 100%; }
  .chart-bar .seg { flex: 1; overflow-x: auto; }
  .reso-table { font-size: 12px; }
  .reso-table th, .reso-table td { padding: 9px 5px; }
  .reso-cell { min-width: 44px; padding: 4px 7px; }
  .alert-item { flex-wrap: wrap; }
  .alert-main { flex: 1 1 100%; }
}

@media (max-width: 420px) {
  .market-grid { grid-template-columns: 1fr 1fr; }
  .plan-box { grid-template-columns: 1fr; }
  .score-box { gap: 12px; }
  .calc-result { grid-template-columns: 1fr; }
  .seg button { padding: 5px 11px; font-size: 12px; }
  .form-grid { gap: 11px; }
  .hero-stats { grid-template-columns: 1fr 1fr; }
  .frame-tab { min-width: 100%; }
}
