/* ============================================================
   留学ROI计算器 — 样式
   移动优先。主要运行环境是微信内置浏览器（Android X5 / iOS WKWebView），
   所以刻意避开了较新的 CSS 特性，只用广泛支持的写法。
   ============================================================ */

:root {
  --ink:        #0f1720;
  --ink-2:      #1c2733;
  --paper:      #ffffff;
  --bg:         #f4f6f8;
  --line:       #e3e8ee;
  --text:       #16202b;
  --text-2:     #5a6b7d;
  --text-3:     #8a9aa9;
  --accent:     #1f6feb;
  --good:       #0f8a5f;
  --warn:       #b8730a;
  --bad:        #c1352b;
  --gold:       #b8860b;
  --r:          14px;
  --safe-b:     env(safe-area-inset-bottom, 0px);
  --safe-t:     env(safe-area-inset-top, 0px);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html {
  -webkit-text-size-adjust: 100%;   /* 阻止微信/iOS 自作主张放大字号 */
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue",
               "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* 屏幕切换 */
.screen { display: none; min-height: 100vh; }
.screen.active { display: block; }

/* ---------- 首屏 ---------- */
.hero {
  background:
    radial-gradient(1100px 620px at 82% -8%, rgba(224,180,92,.20), transparent 62%),
    radial-gradient(900px 520px at 8% 12%, rgba(31,111,235,.24), transparent 60%),
    linear-gradient(168deg, #0d151d 0%, #16283a 58%, #0d151d 100%);
  color: #fff;
  min-height: 100vh;
  padding: calc(var(--safe-t) + 30px) 22px calc(var(--safe-b) + 24px);
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.hero-top { flex: 1; display: flex; flex-direction: column; }

.hero-tag {
  display: inline-block;
  align-self: flex-start;
  font-size: 12.5px;
  letter-spacing: .5px;
  color: #8fbcff;
  border: 1px solid rgba(143,188,255,.32);
  background: rgba(143,188,255,.07);
  border-radius: 100px;
  padding: 5px 13px;
  margin-bottom: 20px;
}

.hero-title {
  font-size: 40px;
  line-height: 1.2;
  font-weight: 800;
  margin: 0 0 14px;
  letter-spacing: -1.2px;
}
.hero-title .hl {
  background: linear-gradient(100deg, #ffd27a, #e0b45c);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

.hero-sub {
  font-size: 15.5px;
  line-height: 1.8;
  color: #a3b8cc;
  margin: 0 0 22px;
}
.hero-sub b { color: #fff; font-weight: 600; }

/* 类型滚动条：制造「我是哪个」的好奇 */
.ticker {
  overflow: hidden;
  margin: 0 -22px 8px;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.ticker-track {
  display: flex;
  gap: 9px;
  width: max-content;
  animation: slide 26s linear infinite;
}
.ticker-track span {
  flex: none;
  font-size: 13px;
  color: #cfe0f2;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.11);
  border-radius: 100px;
  padding: 7px 14px;
  white-space: nowrap;
}
@keyframes slide { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
  .ticker-track { animation: none; }
}
.ticker-cap {
  font-size: 12.5px; color: #7089a0;
  margin: 0; padding-left: 2px;
}

/* 统计条 */
.hero-stats { display: flex; gap: 8px; }
.hstat {
  flex: 1;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.085);
  border-radius: 12px;
  padding: 12px 6px;
  text-align: center;
}
.hstat-num {
  font-size: 21px;
  font-weight: 700;
  color: #fff;
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
  letter-spacing: -.5px;
}
.hstat-num span { font-size: 12px; font-weight: 500; margin-left: 1px; }
.hstat-lbl {
  font-size: 10.5px;
  color: #8ea4b9;
  line-height: 1.45;
  margin-top: 6px;
}
.hstat-lbl em { font-style: normal; color: #62778b; font-size: 9.5px; }

.hero-foot {
  text-align: center;
  font-size: 11.5px;
  color: #62778b;
  line-height: 1.9;
  margin: 0;
}
.src-badges { color: #4e6377; font-size: 10.5px; letter-spacing: .3px; }

/* 首屏双入口 */
.entry-row { display: flex; flex-direction: column; gap: 11px; }
.entry {
  position: relative;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 16px;
  padding: 17px 18px;
  text-align: left;
  font-family: inherit;
  color: #fff;
  cursor: pointer;
  display: flex; flex-direction: column; gap: 4px;
  transition: background .15s, transform .12s, border-color .15s;
}
.entry:active { transform: scale(.985); background: rgba(255,255,255,.10); }
.entry-alt {
  background: linear-gradient(150deg, rgba(224,180,92,.17), rgba(224,180,92,.07));
  border-color: rgba(224,180,92,.36);
}
.entry-badge {
  position: absolute; top: -9px; right: 16px;
  font-size: 10.5px; font-weight: 700; letter-spacing: .4px;
  background: linear-gradient(135deg,#e0b45c,#c8963c);
  color: #241a08;
  border-radius: 100px; padding: 3px 10px;
}
.entry-tag {
  font-size: 11px; letter-spacing: 1.1px; color: #7fb3ff;
  font-weight: 600; margin-bottom: 1px;
}
.entry-alt .entry-tag { color: #e5bb68; }
.entry-title { font-size: 21px; font-weight: 700; letter-spacing: -.4px; }
.entry-sub { font-size: 12.5px; color: #9db2c7; line-height: 1.6; margin-top: 2px; }
.entry-go { font-size: 13.5px; color: #7fb3ff; font-weight: 600; margin-top: 7px; }
.entry-alt .entry-go { color: #e5bb68; }

/* ---------- 按钮 ---------- */
.btn {
  display: block;
  width: 100%;
  border: none;
  border-radius: 12px;
  font-size: 17px;
  font-weight: 600;
  font-family: inherit;
  padding: 16px;
  cursor: pointer;
  transition: transform .12s, opacity .12s;
}
.btn:active { transform: scale(.985); opacity: .9; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-lg { padding: 18px; font-size: 17px; }
.btn-ghost {
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--line);
}

/* ---------- 顶栏 / 进度 ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--bg);
  display: flex;
  align-items: center;
  gap: 13px;
  padding: calc(var(--safe-t) + 12px) 18px 12px;
}
.topbar-back {
  background: none; border: none;
  font-size: 30px; line-height: 1;
  color: var(--text-2);
  padding: 0 4px; cursor: pointer;
  font-family: inherit;
}
.progress {
  flex: 1; height: 3px;
  background: var(--line);
  border-radius: 2px; overflow: hidden;
}
.progress-fill {
  height: 100%; width: 20%;
  background: var(--accent);
  border-radius: 2px;
  transition: width .3s cubic-bezier(.4,0,.2,1);
}
.topbar-step {
  font-size: 13px;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
  min-width: 30px;
}

/* ---------- 问卷 ---------- */
.quiz-body { padding: 14px 18px calc(var(--safe-b) + 40px); }
.q { display: none; }
.q.active { display: block; animation: slideIn .28s ease; }
@keyframes slideIn {
  from { opacity: 0; transform: translateY(9px); }
  to   { opacity: 1; transform: none; }
}

.q h2 {
  font-size: 23px;
  font-weight: 700;
  margin: 12px 0 8px;
  letter-spacing: -.3px;
}
.q-hint {
  font-size: 13.5px;
  color: var(--text-2);
  margin: 0 0 22px;
  line-height: 1.6;
}
.q h2 + .opts { margin-top: 22px; }

.opts { display: flex; flex-direction: column; gap: 10px; }
.opts-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.opt {
  background: var(--paper);
  border: 1.5px solid var(--line);
  border-radius: var(--r);
  padding: 15px 16px;
  text-align: left;
  font-family: inherit;
  font-size: 16px;
  color: var(--text);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 3px;
  position: relative;
  transition: border-color .15s, background .15s;
}
.opt:active { background: #f0f4f9; }
.opt.sel { border-color: var(--accent); background: #f2f7ff; }
.opt.sel::after {
  content: "✓";
  position: absolute;
  right: 15px; top: 50%;
  transform: translateY(-50%);
  color: var(--accent);
  font-weight: 700;
  font-size: 17px;
}
.opt-flag { font-size: 21px; line-height: 1; margin-bottom: 3px; }
.opt-main { font-weight: 600; font-size: 16.5px; }
.opt-sub  { font-size: 12.5px; color: var(--text-2); line-height: 1.5; }
.opts-grid .opt { padding: 14px 13px; }
.opts-grid .opt-main { font-size: 15px; }
.opts-grid .opt.sel::after { right: 11px; top: 13px; transform: none; font-size: 14px; }

/* STEM 标记 */
.stem-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 600;
  color: var(--good);
  background: #e6f5ef;
  border-radius: 4px;
  padding: 1px 5px;
  margin-top: 4px;
  align-self: flex-start;
}
.stem-badge.no { color: var(--text-3); background: #eef1f4; }

/* ---------- 计算中 ---------- */
.calc-wrap {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 22px;
  color: var(--text-2);
  font-size: 15px;
  padding: 24px;
  text-align: center;
}
.spinner {
  width: 34px; height: 34px;
  border: 3px solid var(--line);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- 结果 ---------- */
.result-body { padding: calc(var(--safe-t) + 20px) 16px calc(var(--safe-b) + 40px); }

/* 类型标题 */
.type-intro { text-align: center; padding: 6px 0 18px; }
.type-intro-lbl {
  font-size: 12.5px; color: var(--text-3);
  letter-spacing: 2.5px; margin-bottom: 8px;
}
.type-intro-name {
  font-size: 31px; font-weight: 800;
  letter-spacing: -.5px; line-height: 1.25;
  margin-bottom: 11px;
}
.type-intro-rarity {
  display: inline-block;
  font-size: 12px; font-weight: 600;
  padding: 5px 13px; border-radius: 100px;
  letter-spacing: .3px;
}
.rarity-SSR { background: linear-gradient(135deg,#f7e2a0,#e8c45f); color: #4a3600; }
.rarity-SR  { background: linear-gradient(135deg,#e0d0f7,#c9a7f5); color: #35155a; }
.rarity-R   { background: linear-gradient(135deg,#d3e8fa,#a5cdf0); color: #123a5c; }
.rarity-N   { background: #e8edf2; color: #4d5c6b; }

/* 卡片舞台 */
.card-stage { text-align: center; margin-bottom: 14px; }
.card-stage img {
  width: 100%; max-width: 380px;
  border-radius: 16px;
  box-shadow: 0 10px 34px rgba(15,23,32,.22);
  display: block; margin: 0 auto;
  background: var(--ink);
  aspect-ratio: 1 / 1;
}
.card-hint {
  font-size: 13px; color: var(--text-3);
  margin-top: 11px; line-height: 1.6;
}
.card-hint.hl { color: var(--accent); font-weight: 500; }

.share-row { display: flex; gap: 10px; margin-bottom: 20px; }
.share-row .btn { flex: 1; font-size: 15.5px; padding: 14px 8px; }
.share-row .btn-ghost { background: var(--paper); flex: 0 0 108px; }

.wx-warn {
  background: rgba(255,180,80,.13);
  border-left: 3px solid #d6ab55;
  border-radius: 0 7px 7px 0;
  padding: 10px 12px;
  font-size: 13px; color: #e8c98a;
  margin-bottom: 12px; line-height: 1.6;
}

.verdict {
  border-radius: 16px;
  padding: 24px 20px;
  color: #fff;
  margin-bottom: 16px;
}
.verdict.good { background: linear-gradient(160deg,#0f8a5f,#0b6e4b); }
.verdict.ok   { background: linear-gradient(160deg,#b8730a,#965c06); }
.verdict.bad  { background: linear-gradient(160deg,#c1352b,#9c2a22); }
.verdict-label { font-size: 12.5px; opacity: .82; letter-spacing: .6px; margin-bottom: 9px; }
.verdict-num {
  font-size: 40px; font-weight: 700; line-height: 1.1;
  font-variant-numeric: tabular-nums; letter-spacing: -1px;
}
.verdict-num small { font-size: 17px; font-weight: 500; opacity: .85; }
.verdict-txt { font-size: 14.5px; line-height: 1.65; margin-top: 11px; opacity: .95; }

.card {
  background: var(--paper);
  border-radius: var(--r);
  padding: 19px 18px;
  margin-bottom: 13px;
  border: 1px solid var(--line);
}
.card-h {
  font-size: 12px; font-weight: 600;
  color: var(--text-3);
  letter-spacing: 1px;
  margin: 0 0 14px;
}
.card-title { font-size: 18px; font-weight: 700; margin: 0 0 5px; }

/* 数值行 */
.row {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 10px 0;
  border-bottom: 1px solid #f0f3f6;
  gap: 14px;
}
.row:last-child { border-bottom: none; }
.row-k { font-size: 14.5px; color: var(--text-2); flex-shrink: 0; }
.row-v { font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; text-align: right; }
.row-v.big { font-size: 21px; }
.row-v.bad { color: var(--bad); }
.row-v.good { color: var(--good); }
.row-note { font-size: 12px; color: var(--text-3); margin-top: -4px; padding-bottom: 9px; line-height: 1.55; }

/* 漏斗 */
.funnel-step { margin-bottom: 15px; }
.funnel-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 6px; gap: 10px; }
.funnel-lbl { font-size: 14.5px; font-weight: 500; }
.funnel-pct { font-size: 16px; font-weight: 700; font-variant-numeric: tabular-nums; flex-shrink: 0; }
.funnel-bar { height: 7px; background: #eef1f5; border-radius: 4px; overflow: hidden; }
.funnel-bar i { display: block; height: 100%; background: var(--accent); border-radius: 4px; transition: width .5s ease; }
.funnel-note { font-size: 12px; color: var(--text-3); line-height: 1.6; margin-top: 7px; }

.tier-tag {
  display: inline-block; font-size: 10px; font-weight: 600;
  padding: 1.5px 5px; border-radius: 4px; margin-left: 6px;
  vertical-align: 1.5px;
}
.tier-official { background: #e7f0fd; color: #1a5fc4; }
.tier-survey   { background: #fdf3e0; color: #94640a; }
.tier-estimate { background: #f0f2f5; color: #6b7987; }

.funnel-result {
  margin-top: 20px; padding-top: 17px;
  border-top: 2px solid var(--ink);
  display: flex; justify-content: space-between; align-items: baseline;
}
.funnel-result-k { font-size: 15px; font-weight: 600; }
.funnel-result-v { font-size: 30px; font-weight: 700; font-variant-numeric: tabular-nums; }

/* 对照条 */
.versus { display: flex; gap: 11px; margin-top: 6px; }
.versus-col {
  flex: 1; background: #f7f9fb;
  border: 1px solid var(--line);
  border-radius: 11px; padding: 14px 12px; text-align: center;
}
.versus-col.hl { background: #fff6f5; border-color: #f3c9c5; }
.versus-lbl { font-size: 11.5px; color: var(--text-2); margin-bottom: 7px; line-height: 1.45; }
.versus-num { font-size: 23px; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: -.5px; }
.versus-num.bad { color: var(--bad); }
.versus-sub { font-size: 11px; color: var(--text-3); margin-top: 4px; }

.callout {
  background: #fff8e6;
  border-left: 3px solid var(--gold);
  border-radius: 0 9px 9px 0;
  padding: 13px 15px;
  font-size: 13.5px;
  line-height: 1.7;
  color: #6b5410;
  margin-top: 15px;
}
.callout b { color: #4a3a08; }

.warn-box {
  background: #fff1f0;
  border-left: 3px solid var(--bad);
  border-radius: 0 9px 9px 0;
  padding: 13px 15px;
  font-size: 13.5px;
  line-height: 1.7;
  color: #8c2b23;
  margin-top: 13px;
}

/* ---------- 付费墙 ---------- */
.paywall {
  background: linear-gradient(165deg,#12202f,#0c1620);
  border-radius: 16px;
  padding: 27px 21px;
  color: #fff;
  margin: 22px 0 13px;
  position: relative;
  overflow: hidden;
}
.paywall::before {
  content: "";
  position: absolute; top: -60px; left: 0; right: 0; height: 60px;
  background: linear-gradient(180deg, transparent, rgba(12,22,32,.06));
}
.pw-tag {
  font-size: 11px; letter-spacing: 1.4px; color: #d6ab55;
  margin-bottom: 11px; font-weight: 600;
}
.paywall h3 { font-size: 21px; font-weight: 700; margin: 0 0 8px; letter-spacing: -.3px; }
.pw-lead { font-size: 14px; color: #9fb4c8; line-height: 1.7; margin: 0 0 19px; }

.pw-list { list-style: none; padding: 0; margin: 0 0 22px; }
.pw-list li {
  font-size: 14px; color: #cfdcea;
  padding: 9px 0 9px 25px;
  position: relative;
  border-bottom: 1px solid rgba(255,255,255,.06);
  line-height: 1.6;
}
.pw-list li:last-child { border-bottom: none; }
.pw-list li::before {
  content: "→"; position: absolute; left: 0; top: 9px;
  color: #d6ab55; font-weight: 700;
}
.pw-list li b { color: #fff; font-weight: 600; }

.pw-price {
  display: flex; align-items: baseline; gap: 9px;
  margin-bottom: 17px; padding-top: 6px;
}
.pw-price-now { font-size: 37px; font-weight: 700; color: #fff; letter-spacing: -1px; }
.pw-price-now small { font-size: 19px; font-weight: 500; }
.pw-price-was { font-size: 16px; color: #6d8299; text-decoration: line-through; }
.pw-price-tip { font-size: 12px; color: #d6ab55; margin-left: auto; text-align: right; line-height: 1.4; }

.btn-buy {
  background: linear-gradient(135deg,#e0b45c,#c8963c);
  color: #24190a;
  font-weight: 700;
}

.pay-panel { display: none; margin-top: 19px; }
.pay-panel.open { display: block; }
.pay-steps {
  background: rgba(255,255,255,.05);
  border-radius: 11px; padding: 16px;
  font-size: 13.5px; color: #c3d3e2; line-height: 1.85;
}
.pay-steps ol { margin: 0; padding-left: 19px; }
.pay-steps li { margin-bottom: 5px; }
.pay-steps b { color: #fff; }
.qr-wrap { text-align: center; margin: 17px 0; }
.qr-wrap img {
  width: 190px; height: 190px;
  border-radius: 11px; background: #fff; padding: 8px;
  display: inline-block;
  box-sizing: border-box;
  object-fit: contain;   /* 收款码换成非正方图也不会被拉伸，拉伸会导致扫不出来 */
}
.qr-tip { font-size: 12px; color: #8fa4b8; margin-top: 9px; line-height: 1.6; }

.code-row { display: flex; gap: 9px; margin-top: 15px; }
.code-row input {
  flex: 1; min-width: 0;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 10px;
  padding: 13px 14px;
  color: #fff; font-size: 16px;
  font-family: inherit;
  letter-spacing: 1px;
}
.code-row input::placeholder { color: #6d8299; letter-spacing: 0; }
.code-row button {
  background: #fff; color: var(--ink);
  border: none; border-radius: 10px;
  padding: 0 21px; font-size: 15px; font-weight: 600;
  font-family: inherit; cursor: pointer; flex-shrink: 0;
}
.code-msg { font-size: 13px; margin-top: 11px; min-height: 18px; line-height: 1.5; }
.code-msg.err { color: #ff9b93; }
.code-msg.ok  { color: #6ee7b7; }

/* ---------- 完整报告（解锁后） ---------- */
.locked { display: none; }
.locked.unlocked { display: block; animation: slideIn .4s ease; }

table.matrix {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
table.matrix th, table.matrix td {
  padding: 10px 7px;
  text-align: right;
  border-bottom: 1px solid #f0f3f6;
  white-space: nowrap;
}
table.matrix th {
  font-size: 11.5px; color: var(--text-3);
  font-weight: 600; letter-spacing: .3px;
}
table.matrix td:first-child, table.matrix th:first-child { text-align: left; }
table.matrix tr.me { background: #f2f7ff; font-weight: 600; }
table.matrix tr.me td:first-child::after {
  content: "你"; font-size: 10px; background: var(--accent); color: #fff;
  border-radius: 3px; padding: 1px 4px; margin-left: 5px; font-weight: 600;
}
.table-scroll { overflow-x: auto; margin: 0 -18px; padding: 0 18px; }

/* 滑块 */
.slider-row { margin-bottom: 21px; }
.slider-top {
  display: flex; justify-content: space-between; align-items: baseline;
  margin-bottom: 4px; gap: 12px;
}
.slider-lbl { font-size: 14.5px; font-weight: 500; }
.slider-val {
  font-size: 15px; font-weight: 700; color: var(--accent);
  font-variant-numeric: tabular-nums; flex-shrink: 0;
}
.slider-note { font-size: 12px; color: var(--text-3); line-height: 1.6; margin-bottom: 9px; }
input[type=range] {
  width: 100%; -webkit-appearance: none; appearance: none;
  height: 4px; border-radius: 3px; background: var(--line); outline: none;
}
input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 25px; height: 25px; border-radius: 50%;
  background: var(--accent); cursor: pointer;
  border: 3px solid #fff;
  box-shadow: 0 1px 5px rgba(0,0,0,.28);
}

.timeline-item {
  position: relative;
  padding: 0 0 19px 21px;
  border-left: 2px solid var(--line);
}
.timeline-item:last-child { border-left-color: transparent; padding-bottom: 0; }
.timeline-item::before {
  content: ""; position: absolute; left: -6px; top: 5px;
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--accent); border: 2px solid #fff;
}
.timeline-item.danger::before { background: var(--bad); }
.timeline-date { font-size: 12px; color: var(--text-3); font-weight: 600; letter-spacing: .3px; }
.timeline-txt { font-size: 14px; line-height: 1.65; margin-top: 3px; }

/* 页脚 */
.foot {
  font-size: 11.5px; color: var(--text-3);
  line-height: 1.8; padding: 26px 4px 0;
  border-top: 1px solid var(--line);
  margin-top: 26px;
}
.foot b { color: var(--text-2); }
.foot a { color: var(--text-2); }

.restart {
  text-align: center; margin-top: 22px;
  font-size: 14px; color: var(--accent);
  cursor: pointer;
}

@media (min-width: 640px) {
  .hero, .quiz-body, .result-body, .topbar {
    max-width: 560px; margin-left: auto; margin-right: auto;
  }
  .hero h1 { font-size: 38px; }
}

/* ---------- 表单 ---------- */
.topbar-title { font-size: 16px; font-weight: 600; }
.form-h1 { font-size: 24px; font-weight: 700; margin: 12px 0 8px; letter-spacing: -.3px; }

.field { margin-bottom: 26px; }
.field label {
  display: block; font-size: 15.5px; font-weight: 600;
  margin-bottom: 10px; line-height: 1.55;
}
.field label em {
  display: block; font-style: normal; font-weight: 400;
  font-size: 12.5px; color: var(--text-2); margin-top: 3px; line-height: 1.55;
}
.field-key { background: #fff8e6; border-radius: var(--r); padding: 16px 15px; border: 1px solid #f0e0b8; }
.field-note { font-size: 12px; color: var(--text-2); line-height: 1.65; margin: 9px 0 0; }

.num-wrap { position: relative; }
.num-wrap input {
  width: 100%; box-sizing: border-box;
  background: var(--paper);
  border: 1.5px solid var(--line);
  border-radius: 12px;
  padding: 14px 46px 14px 15px;
  font-size: 20px; font-weight: 600;
  font-family: inherit; color: var(--text);
  font-variant-numeric: tabular-nums;
  -webkit-appearance: none; appearance: none;
}
.num-wrap input:focus { outline: none; border-color: var(--accent); }
.num-wrap input::-webkit-outer-spin-button,
.num-wrap input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.num-unit {
  position: absolute; right: 15px; top: 50%; transform: translateY(-50%);
  font-size: 15px; color: var(--text-3); pointer-events: none;
}

.chips { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 9px; }
.chips button {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 100px;
  padding: 7px 13px;
  font-size: 13px; font-family: inherit;
  color: var(--text-2); cursor: pointer;
}
.chips button.on { background: #f2f7ff; border-color: var(--accent); color: var(--accent); font-weight: 600; }

/* ---------- 回本进度条 ---------- */
.pb-wrap { margin-bottom: 16px; }
.pb-bar {
  height: 15px; background: #eef1f5;
  border-radius: 8px; overflow: hidden;
}
.pb-bar i {
  display: block; height: 100%;
  background: linear-gradient(90deg, var(--accent), #4a9bff);
  border-radius: 8px;
  transition: width .7s cubic-bezier(.4,0,.2,1);
  min-width: 4px;
}
.pb-labels {
  display: flex; justify-content: space-between;
  font-size: 12.5px; color: var(--text-2); margin-top: 8px;
  font-variant-numeric: tabular-nums;
}

/* ---------- 恶搞换算网格 ---------- */
.conv-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.conv-item {
  background: #f7f9fb; border: 1px solid var(--line);
  border-radius: 12px; padding: 13px 6px; text-align: center;
}
.conv-emoji { font-size: 24px; line-height: 1; margin-bottom: 6px; }
.conv-num {
  font-size: 17px; font-weight: 700;
  font-variant-numeric: tabular-nums; letter-spacing: -.3px;
}
.conv-name { font-size: 11px; color: var(--text-2); margin-top: 3px; line-height: 1.4; }
