/* ===================================================
   HSK Prep — Onboarding funnel (/quiz/)
   onboarding.css — built on common.css design tokens.
   Loaded alongside /common.css. Mobile-first.
   =================================================== */

body.ob {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: 'DM Sans', system-ui, -apple-system, sans-serif;
  font-size: var(--fs-base);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

/* The site-wide floating dark-mode toggle (injected by build.js) would overlap
   funnel controls — the funnel respects the saved/OS theme but hides the button. */
body.ob .theme-toggle { display: none !important; }

.ob-app {
  height: 100vh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* ---- Top bar: back · brand · counter, with a full-width progress line ---- */
.ob-top { flex: 0 0 auto; width: 100%; }
.ob-top-row {
  max-width: 640px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  box-sizing: border-box;
}
.ob-back {
  grid-column: 1;
  justify-self: start;
  appearance: none;
  border: none;
  background: none;
  color: var(--stone);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
}
.ob-back:hover { background: var(--surface-sunken); color: var(--ink); }
.ob-back[hidden] { display: none; }
/* Explicit grid-column on every child keeps the brand pinned to the centre track
   even when the back button is display:none (screens flagged back:false, e.g. s14/s25). */
.ob-brand { grid-column: 2; justify-self: center; display: inline-flex; align-items: center; gap: 8px; }
.ob-brand[hidden] { display: none; }
.ob-brand-mark {
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: 28px;
  height: 28px;
  background: #c23b22;
  color: #fffdf9;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  line-height: 1;
  padding-right: 0.04em;
  padding-bottom: 0.16em; /* nudge 汉 to its optical (mass) centre in the tile */
  flex: 0 0 auto;
}
.ob-brand-name { font-weight: 600; font-size: 17px; letter-spacing: -.01em; color: var(--ink); }
.ob-step-count {
  grid-column: 3;
  justify-self: end;
  font-size: var(--fs-xs);
  color: var(--stone);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
/* Thin full-width progress line under the header — only on assessment steps. */
.ob-progress {
  height: 3px;
  width: 100%;
  background: var(--surface-sunken);
  overflow: hidden;
  visibility: hidden;
}
.ob-top.is-quiz .ob-progress { visibility: visible; }
.ob-progress-bar {
  height: 100%;
  width: 0;
  background: var(--accent);
  transition: width .4s cubic-bezier(.34, 1.4, .5, 1);
}

/* ---- Pinned bottom action ---- */
.ob-foot {
  flex: 0 0 auto;
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
  padding: 10px 18px calc(16px + env(safe-area-inset-bottom));
  box-sizing: border-box;
}
.ob-foot[hidden] { display: none; }
.ob-foot.is-wide { max-width: 720px; }
.ob-foot .ob-cta { margin-top: 0; width: 100%; }
/* ---- Screen container ----
   The stage is the single scroll area. Each screen uses margin:auto so it
   centers vertically + horizontally when it fits, and — unlike
   justify-content:center — collapses to a top-anchored scroll when the
   content is taller than the viewport, so nothing is ever clipped. */
.ob-stage {
  flex: 1 1 auto;
  min-height: 0;
  width: 100%;
  overflow-x: hidden;   /* the spinning wheel's square box would otherwise
                           expand past the width and add a horizontal scroll */
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  padding: 8px 18px 28px;
  box-sizing: border-box;
}
.ob-screen {
  width: 100%;
  max-width: 560px;
  margin: auto;
  display: flex;
  flex-direction: column;
}
.ob-screen[data-wide] { max-width: 720px; }
/* Fill the stage so inner content can anchor (title top) and center (body). */
.ob-screen[data-fill] { min-height: 100%; margin: 0 auto; }
/* Directional transitions: forward slides in from the right, back from the left. */
.ob-screen[data-anim="fwd"]  { animation: ob-slide-fwd .28s cubic-bezier(.22,.61,.36,1) both; }
.ob-screen[data-anim="back"] { animation: ob-slide-back .28s cubic-bezier(.22,.61,.36,1) both; }
@keyframes ob-slide-fwd  { from { opacity: 0; transform: translateX(26px); } to { opacity: 1; transform: none; } }
@keyframes ob-slide-back { from { opacity: 0; transform: translateX(-26px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .ob-screen { animation: none !important; }
  .ob-progress-bar { transition: none; }
}

/* ---- Typography ---- */
.ob-h1 {
  font-family: 'Noto Serif SC', 'DM Sans', serif;
  font-size: var(--fs-2xl);
  line-height: 1.25;
  margin: 8px 0 6px;
  color: var(--ink);
}
.ob-sub { color: var(--stone); margin: 0 0 18px; }
/* Programmatic per-step focus (a11y) should not paint a focus ring on the
   non-interactive heading; real keyboard focus rings on controls stay. */
.ob-h1:focus, [data-focus]:focus { outline: none; }
.ob-center { text-align: center; align-items: center; }
.ob-center .ob-sub { max-width: 460px; margin-left: auto; margin-right: auto; }

/* ---- Option cards ---- */
.ob-options { display: flex; flex-direction: column; gap: 10px; margin-top: 4px; }
.ob-opt {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: var(--tap);
  padding: 14px 16px;
  text-align: left;
  background: var(--surface);
  border: 1.5px solid var(--mist);
  border-radius: var(--radius);
  color: var(--ink);
  font-size: var(--fs-md);
  font-family: inherit;
  cursor: pointer;
  box-sizing: border-box;
  transition: border-color .15s, background .15s, transform .05s;
}
.ob-opt:hover { border-color: var(--accent); }
.ob-opt:active { transform: scale(.995); }
.ob-opt.is-selected {
  border-color: var(--accent);
  background: var(--accent-soft);
  font-weight: 600;
  animation: ob-pop .2s ease;
}
@keyframes ob-pop { 0% { transform: scale(1); } 45% { transform: scale(1.02); } 100% { transform: scale(1); } }
@media (prefers-reduced-motion: reduce) { .ob-opt.is-selected { animation: none; } }
.ob-opt-mark {
  flex: 0 0 auto;
  width: 22px; height: 22px;
  border: 1.5px solid var(--mist);
  border-radius: 6px;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 14px; color: #fff;
}
.ob-opt.is-selected .ob-opt-mark { background: var(--accent); border-color: var(--accent); }
.ob-opt[data-single] .ob-opt-mark { border-radius: 50%; }
.ob-badge-rec {
  margin-left: auto;
  font-size: var(--fs-xs);
  font-weight: 700;
  color: var(--jade);
  background: var(--jade-soft);
  padding: 3px 8px;
  border-radius: 999px;
}

/* ---- Buttons ---- */
.ob-cta {
  appearance: none;
  display: inline-flex; align-items: center; justify-content: center;
  width: 100%;
  min-height: var(--tap);
  margin-top: 20px;
  padding: 14px 22px;
  border: none;
  border-radius: var(--radius);
  background: var(--accent-btn);
  color: #fff;
  font-family: inherit;
  font-size: var(--fs-md);
  font-weight: 700;
  cursor: pointer;
  transition: background .15s, opacity .15s;
}
.ob-cta:hover { background: var(--accent-btn-hover); }
.ob-cta:disabled { opacity: .45; cursor: not-allowed; }
.ob-cta--lg { font-size: var(--fs-lg); padding: 16px 24px; }
.ob-ghost {
  background: none;
  border: 1.5px solid var(--mist);
  color: var(--ink);
}
.ob-ghost:hover { background: var(--surface-sunken); border-color: var(--stone); }
.ob-link {
  background: none; border: none; color: var(--stone);
  font: inherit; cursor: pointer; text-decoration: underline; padding: 8px;
}

/* ---- Welcome / badge ---- */
.ob-pill {
  display: inline-block;
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--gold);
  background: var(--gold-soft);
  border: 1px solid var(--gold-border);
  padding: 7px 14px;
  border-radius: 999px;
  margin-bottom: 16px;
}
/* Welcome (s0) hero brand — 汉 tile + wordmark, matching the landing/login lockup.
   Tile stays landing-red on both themes; the wordmark uses --ink so it's always legible. */
.ob-logo { display: inline-flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.ob-logo-mark {
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: #c23b22;
  color: #fffdf9;
  font-size: 27px;
  font-weight: 600;
  line-height: 1;
  padding-right: 0.04em;
  padding-bottom: 0.16em; /* nudge 汉 to its optical (mass) centre in the tile */
  flex: 0 0 auto;
}
.ob-logo-name { font-weight: 600; font-size: 26px; letter-spacing: -.01em; color: var(--ink); }

/* ---- Social proof cards ---- */
.ob-quote {
  background: var(--surface);
  border: 1px solid var(--mist);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 14px 16px;
  margin-bottom: 12px;
}
.ob-quote-text { margin: 0 0 6px; }
.ob-quote-name { font-size: var(--fs-sm); color: var(--stone); font-weight: 600; }
.ob-stars { color: var(--gold); letter-spacing: 2px; }
.ob-tail { text-align: center; color: var(--stone); margin: 8px 0 0; }

/* ---- Authority bullets ---- */
.ob-bullets { list-style: none; padding: 0; margin: 6px 0 0; display: flex; flex-direction: column; gap: 12px; }
.ob-bullets li {
  display: flex; gap: 10px; align-items: flex-start;
  background: var(--surface); border: 1px solid var(--mist);
  border-radius: var(--radius); padding: 14px 16px;
}
.ob-bullets li::before { content: "✓"; color: var(--jade); font-weight: 800; }
.ob-stat {
  margin-top: 14px; text-align: center;
  font-size: var(--fs-lg); font-weight: 700; color: var(--accent);
}
.ob-logos {
  margin-top: 14px; display: flex; flex-wrap: wrap; gap: 10px; justify-content: center;
}
.ob-logo-ph {
  font-size: var(--fs-xs); color: var(--stone);
  border: 1px dashed var(--mist); border-radius: var(--radius-sm);
  padding: 8px 14px; background: var(--surface);
}
.ob-trust-badges {
  margin-top: 16px; display: flex; flex-wrap: wrap; gap: 8px; justify-content: center;
}
.ob-trust-badge {
  font-size: var(--fs-xs); font-weight: 600; color: var(--stone);
  background: var(--surface); border: 1px solid var(--mist);
  border-radius: 999px; padding: 6px 12px;
}

/* ---- Diagnostic ---- */
.ob-dq-prog { font-size: var(--fs-sm); color: var(--stone); font-weight: 600; margin-bottom: 8px; }
/* The question stem must read as the prompt, not another pickable card:
   raised (surface-sunken) panel with an accent top rule and a clear gap. */
.ob-dq-text {
  font-family: 'Noto Serif SC', serif;
  font-size: var(--fs-xl);
  line-height: 1.9;
  background: var(--surface-sunken);
  border: 1px solid var(--border-subtle);
  border-top: 3px solid var(--accent);
  border-radius: 4px 4px 14px 14px;
  padding: 18px 20px;
  margin-bottom: 22px;
  color: var(--ink);
}
.ob-dq-audio { width: 100%; margin: 4px 0 14px; }
.ob-dq .ob-opt { font-family: 'Noto Serif SC', serif; }

/* ---- Processing ---- */
.ob-spinner {
  width: 54px; height: 54px; margin: 10px auto 18px;
  border: 4px solid var(--surface-sunken);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: ob-spin 0.9s linear infinite;
}
@keyframes ob-spin { to { transform: rotate(360deg); } }
.ob-proc-steps { list-style: none; padding: 0; margin: 6px auto 0; max-width: 300px; text-align: left; }
.ob-proc-step {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 0; font-size: var(--fs-sm); color: var(--stone);
  transition: color .3s ease;
}
.ob-proc-step.is-done { color: var(--ink); }
.ob-proc-dot {
  flex: 0 0 auto; width: 20px; height: 20px; border-radius: 50%;
  border: 2px solid var(--mist); position: relative; transition: border-color .3s, background .3s;
}
.ob-proc-step.is-done .ob-proc-dot { border-color: var(--jade); background: var(--jade); }
.ob-proc-step.is-done .ob-proc-dot::after {
  content: ""; position: absolute; left: 6px; top: 3px;
  width: 4px; height: 8px; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg);
}
@media (prefers-reduced-motion: reduce) { .ob-proc-step { transition: none; } }

/* ---- Mirror summary ---- */
.ob-summary {
  background: var(--surface);
  border: 1px solid var(--mist);
  border-radius: var(--radius);
  padding: 6px 18px;
  margin-bottom: 16px;
}
.ob-summary-row {
  display: flex; justify-content: space-between; gap: 12px;
  padding: 13px 0; border-bottom: 1px solid var(--border-subtle);
}
.ob-summary-row:last-child { border-bottom: none; }
.ob-summary-row dt { color: var(--stone); }
.ob-summary-row dd { margin: 0; font-weight: 700; text-align: right; }
.ob-result-hl { color: var(--accent); }

/* ---- Growth curve ---- */
.ob-growth {
  background: var(--surface); border: 1px solid var(--mist);
  border-radius: 16px; padding: 14px 14px 8px; margin: 6px 0 10px;
}
.ob-growth svg { width: 100%; height: auto; display: block; }
.ob-growth-cap { text-align: center; font-size: var(--fs-xs); color: var(--stone); margin-top: 4px; }
/* Draw the line in, then fade the area + dots + labels in sequence. */
.ob-growth-line { stroke-dasharray: 1; stroke-dashoffset: 1; animation: ob-draw 1.15s cubic-bezier(.5,0,.2,1) .25s forwards; }
@keyframes ob-draw { to { stroke-dashoffset: 0; } }
.ob-growth-area { opacity: 0; animation: ob-fade .8s ease .95s forwards; }
.ob-growth-dot, .ob-growth-lbl { opacity: 0; animation: ob-fade .45s ease forwards; }
@media (prefers-reduced-motion: reduce) {
  .ob-growth-line { animation: none; stroke-dashoffset: 0; }
  .ob-growth-area, .ob-growth-dot, .ob-growth-lbl { animation: none; opacity: 1; }
}

/* ---- Timeline ---- */
.ob-timeline { list-style: none; padding: 0; margin: 6px 0 0; }
/* In the fill layout, the day list centers vertically between title and CTA. */
.ob-screen[data-fill] .ob-timeline { margin: auto 0; }
.ob-tl-item { opacity: 0; animation: ob-tl-in .42s ease both; }
@keyframes ob-tl-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .ob-tl-item { animation: none; opacity: 1; } }
.ob-timeline li {
  position: relative; padding: 0 0 18px 26px; border-left: 2px solid var(--mist);
}
.ob-timeline li:last-child { border-left-color: transparent; padding-bottom: 0; }
.ob-timeline li::before {
  content: ""; position: absolute; left: -7px; top: 2px;
  width: 12px; height: 12px; border-radius: 50%;
  background: var(--accent); border: 2px solid var(--paper);
}
.ob-tl-when { font-weight: 700; color: var(--accent); font-size: var(--fs-sm); }
.ob-tl-title { font-weight: 700; }
.ob-tl-text { color: var(--stone); font-size: var(--fs-sm); }

/* ---- Value stack ---- */
.ob-vrow {
  display: flex; gap: 12px; align-items: flex-start;
  padding: 14px 0; border-bottom: 1px solid var(--border-subtle);
}
.ob-vrow:last-of-type { border-bottom: none; }
.ob-vrow .ob-check { color: var(--jade); font-weight: 800; flex: 0 0 auto; }
.ob-vrow-icon {
  flex: 0 0 auto; width: 34px; height: 34px; border-radius: 10px;
  background: var(--accent-soft); display: inline-flex; align-items: center; justify-content: center;
  font-size: 17px;
}
.ob-vrow-title { font-weight: 700; }
.ob-vrow-text { color: var(--stone); font-size: var(--fs-sm); }
.ob-guarantee {
  margin-top: 16px;
  background: var(--ok-bg); border: 1px solid var(--ok-border);
  border-radius: var(--radius); padding: 16px;
}
.ob-guarantee-title { font-weight: 800; color: var(--ok-ink); }
.ob-guarantee-terms { font-size: var(--fs-xs); color: var(--stone); margin-top: 6px; }
.ob-guarantee-terms summary { cursor: pointer; color: var(--ok-ink); }

/* ---- Wheel ---- */
.ob-wheel-wrap { position: relative; width: min(300px, 80vw); aspect-ratio: 1; margin: 14px auto; }
.ob-wheel {
  width: 100%; height: 100%; border-radius: 50%;
  filter: drop-shadow(0 12px 30px rgba(0,0,0,.28));
  transition: transform 4.6s cubic-bezier(.17,.67,.16,1);
}
/* Reduced motion: snap instead of the long spin (not `none` — that kills
   transitionend, so done() would wait the full 5.2s fallback). */
@media (prefers-reduced-motion: reduce) { .ob-wheel { transition-duration: .01s; } }
.ob-wheel-pointer {
  position: absolute; top: -6px; left: 50%; transform: translateX(-50%);
  width: 0; height: 0;
  border-left: 12px solid transparent; border-right: 12px solid transparent;
  border-top: 22px solid var(--ink); z-index: 2;
}
.ob-wheel-hub {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: 18%; height: 18%; border-radius: 50%;
  background: var(--surface); border: 4px solid var(--accent); z-index: 2;
}
.ob-win {
  text-align: center; margin-top: 10px;
  animation: ob-in .4s ease both;
}
.ob-win-big { font-size: var(--fs-2xl); font-weight: 800; color: var(--accent); }

/* ---- Paywall ---- */
.ob-headerbar {
  position: sticky;
  top: 0;
  z-index: 5;
  width: 100%; max-width: 720px;
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  background: var(--invert-bg); color: var(--invert-fg);
  padding: 10px 16px; border-radius: var(--radius);
  font-size: var(--fs-sm); font-weight: 600; margin-bottom: 14px;
}
.ob-timer { font-variant-numeric: tabular-nums; }
.ob-chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin: 4px 0 14px; }
.ob-chip {
  font-size: var(--fs-sm); font-weight: 600;
  background: var(--surface); border: 1px solid var(--mist);
  border-radius: 999px; padding: 6px 12px;
}
/* Faux HSK score-report certificate */
.ob-cert {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--mist);
  border-radius: 12px;
  overflow: hidden;
  margin: 24px 0 14px;
  box-shadow: var(--shadow);
}
.ob-cert-tag {
  position: absolute; top: 8px; right: 8px; z-index: 1;
  font-size: 9.5px; text-transform: uppercase; letter-spacing: .5px;
  color: var(--stone); background: var(--surface); border: 1px solid var(--mist);
  padding: 3px 7px; border-radius: 999px;
}
.ob-cert-head {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 16px; border-bottom: 1px solid var(--mist);
  background: var(--accent-soft);
}
.ob-cert-seal {
  flex: 0 0 auto; width: 40px; height: 40px; border-radius: 50%;
  background: var(--accent); color: #fff; font-weight: 800; font-size: 13px; letter-spacing: .5px;
  display: flex; align-items: center; justify-content: center;
}
.ob-cert-zh { font-family: 'Noto Serif SC', serif; font-weight: 700; font-size: 15px; color: var(--ink); }
.ob-cert-sub { font-size: 12px; color: var(--stone); margin-top: 2px; }
.ob-cert-scores { padding: 8px 16px 4px; }
.ob-cert-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 7px 0; border-bottom: 1px dashed var(--border-subtle);
  font-size: 13px; color: var(--stone);
}
.ob-cert-row b { color: var(--ink); font-variant-numeric: tabular-nums; }
.ob-cert-total {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 11px 16px; background: var(--surface-sunken);
}
.ob-cert-total > span:first-child { font-size: 13px; color: var(--stone); }
.ob-cert-total-num { font-size: 26px; font-weight: 800; color: var(--wrong); font-variant-numeric: tabular-nums; }
.ob-cert-total-num em { font-size: 14px; font-weight: 600; color: var(--stone); font-style: normal; }
.ob-cert-foot { padding: 8px 16px 12px; font-size: 11px; color: var(--stone); text-align: center; }
.ob-social { text-align: center; color: var(--stone); font-size: var(--fs-sm); margin-bottom: 12px; }

.ob-tiers { display: flex; flex-direction: column; gap: 10px; }
.ob-tier {
  position: relative;
  display: flex; align-items: center; gap: 12px;
  background: var(--surface); border: 2px solid var(--mist);
  border-radius: var(--radius); padding: 16px;
  cursor: pointer; text-align: left; width: 100%; font-family: inherit;
  box-sizing: border-box; color: var(--ink);
}
.ob-tier.is-selected { border-color: var(--accent); background: var(--accent-soft); }
.ob-tier.is-popular { border-color: var(--accent); }
.ob-tier-radio {
  flex: 0 0 auto; width: 20px; height: 20px; border-radius: 50%;
  border: 2px solid var(--mist); display: inline-flex; align-items: center; justify-content: center;
}
.ob-tier.is-selected .ob-tier-radio { border-color: var(--accent); }
.ob-tier.is-selected .ob-tier-radio::after { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); }
.ob-tier-main { flex: 1; }
.ob-tier-label { font-weight: 700; }
.ob-tier-base { color: var(--stone); text-decoration: line-through; font-size: var(--fs-sm); margin-right: 6px; }
.ob-tier-price { font-weight: 800; }
.ob-tier-perday { color: var(--stone); font-size: var(--fs-sm); }
.ob-tier-tag {
  position: absolute; top: -10px; left: 16px;
  font-size: 10px; font-weight: 800; letter-spacing: .5px; text-transform: uppercase;
  background: var(--accent); color: #fff; padding: 3px 8px; border-radius: 999px;
}
.ob-tier-best {
  font-size: var(--fs-xs); font-weight: 700; color: var(--jade);
}
.ob-trustrow { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 12px; color: var(--stone); font-size: var(--fs-xs); }
.ob-fineprint { font-size: var(--fs-xs); color: var(--stone); text-align: center; margin-top: 10px; }

/* ---- Modal (checkout / exit-intent) ---- */
.ob-modal-overlay {
  position: fixed; inset: 0; z-index: 50;
  background: rgba(20, 18, 16, .55);
  display: flex; align-items: flex-end; justify-content: center;
  padding: 0;
  animation: ob-fade .2s ease both;
}
@keyframes ob-fade { from { opacity: 0; } to { opacity: 1; } }
@media (min-width: 560px) { .ob-modal-overlay { align-items: center; padding: 20px; } }
.ob-modal {
  width: 100%; max-width: 480px;
  background: var(--paper); color: var(--ink);
  border-radius: 18px 18px 0 0;
  padding: 20px 20px 28px;
  box-sizing: border-box;
  max-height: 92vh; max-height: 92dvh; overflow-y: auto;
  animation: ob-sheet .28s ease both;
}
@media (min-width: 560px) { .ob-modal { border-radius: 18px; } }
@keyframes ob-sheet { from { transform: translateY(24px); opacity: .6; } to { transform: translateY(0); opacity: 1; } }
.ob-modal-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.ob-modal-title { font-weight: 800; font-size: var(--fs-lg); }
.ob-modal-x {
  appearance: none; border: none; background: none; font-size: 24px; line-height: 1;
  color: var(--stone); cursor: pointer; padding: 4px 8px;
}
.ob-co-line { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border-subtle); }
.ob-co-total { font-size: var(--fs-lg); font-weight: 800; }
.ob-field { display: block; margin: 14px 0 0; }
.ob-field span { display: block; font-size: var(--fs-sm); color: var(--stone); margin-bottom: 6px; }
.ob-input, .ob-select {
  width: 100%; box-sizing: border-box; min-height: var(--tap);
  padding: 12px 14px; border: 1.5px solid var(--mist); border-radius: var(--radius);
  background: var(--surface); color: var(--ink); font: inherit;
}
.ob-input:focus, .ob-select:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }
.ob-input.is-error { border-color: var(--wrong); }
.ob-error { color: var(--bad-ink); font-size: var(--fs-sm); margin-top: 6px; }
.ob-note { font-size: var(--fs-xs); color: var(--stone); margin-top: 10px; line-height: 1.5; }
.ob-disclosure {
  font-size: var(--fs-xs); color: var(--stone); line-height: 1.55;
  background: var(--surface-sunken); border-radius: var(--radius-sm);
  padding: 12px; margin-top: 14px;
}

/* ---- Email gate ---- */
.ob-or { display: flex; align-items: center; gap: 12px; color: var(--stone); font-size: var(--fs-sm); margin: 16px 0; }
.ob-or::before, .ob-or::after { content: ""; flex: 1; height: 1px; background: var(--mist); }
.ob-google {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; min-height: var(--tap); padding: 12px;
  border: 1.5px solid var(--mist); border-radius: var(--radius);
  background: var(--surface); color: var(--ink); font: inherit; font-weight: 600; cursor: pointer;
}
.ob-google:hover { border-color: var(--stone); }
.ob-google:disabled { opacity: .7; cursor: default; }
.ob-google-spin {
  display: inline-block; width: 17px; height: 17px; flex: none;
  border: 2px solid var(--mist); border-top-color: var(--ink);
  border-radius: 50%; animation: ob-spin 0.7s linear infinite;
}
.ob-bonus {
  margin-top: 16px; text-align: center; font-size: var(--fs-sm);
  color: var(--gold); background: var(--gold-soft); border: 1px solid var(--gold-border);
  border-radius: var(--radius); padding: 10px 14px;
}

/* ---- Success ---- */
.ob-success-mark {
  width: 64px; height: 64px; margin: 6px auto 16px;
  border-radius: 50%; background: var(--ok-bg); border: 2px solid var(--ok-border);
  color: var(--ok-ink); display: flex; align-items: center; justify-content: center;
  font-size: 32px;
}
