/* WhatIff home-loan registry — design tokens taken verbatim from the prototype. */
:root {
  --page:   #F4F2F7;
  --surface:#EDEAF3;
  --lav:    #C9C2DD;
  --lav2:   #B4AACF;
  --ink:    #2B2644;
  --text:   #14121F;
  --muted:  #5A5570;
  --line:   #DDD8E8;
  --good:   #2f7a52;
  --good-bg:#e7f2ec;
  --warn:   #9b6a12;
  --card:   #FBFAFD;
  --shadow: 0 1px 2px rgba(43,38,68,.04), 0 6px 20px rgba(43,38,68,.06);
  --shadow-lg: 0 2px 6px rgba(43,38,68,.06), 0 18px 44px rgba(43,38,68,.12);
  --r: 20px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  background:
    radial-gradient(1200px 600px at 50% -300px, #EFEBF7 0%, rgba(239,235,247,0) 60%),
    var(--page);
  color: var(--text);
  font-family: 'DM Sans', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  line-height: 1.5;
  min-height: 100vh;
  padding: 22px 0 72px;
  -webkit-font-smoothing: antialiased;
}
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px); }

input, select, button, textarea { font-family: inherit; font-size: 16px; }

/* ---- header (brand) ---- */
.masthead { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 2px 0 18px; }
.brand { display: inline-flex; align-items: center; gap: 10px; }
.brandmark {
  width: 34px; height: 34px; border-radius: 10px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(155deg, #35304f, var(--ink)); color: #fff;
  font-weight: 800; font-size: 17px; box-shadow: var(--shadow);
}
.brandword { font-size: 19px; font-weight: 800; letter-spacing: -.01em; color: var(--ink); }
.brandword b { color: var(--lav2); }
.mast-right { display: flex; align-items: center; gap: 14px; }
.masthead .tally {
  font-size: 12.5px; color: var(--muted);
  padding: 6px 13px; border-radius: 999px; white-space: nowrap;
  background: rgba(255,255,255,.7); border: 1px solid var(--line);
}
.masthead .tally b { color: var(--ink); font-weight: 700; }
.nav-cta { width: auto; margin-top: 0; padding: 9px 16px; border-radius: 999px; font-size: 13px; }
@media (max-width: 560px) { .masthead .tally { display: none; } }

/* ---- wide layout grids ---- */
.landing-grid {
  display: grid; grid-template-columns: 1.05fr .95fr; gap: 22px; align-items: start;
}
.landing-grid > .card { margin-bottom: 0; }
.landing-grid #addrate { position: sticky; top: 20px; }

.result-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; align-items: start; }
.result-col { display: flex; flex-direction: column; }
.result-col > .card { margin-bottom: 16px; }
.result-col > .card:last-child { margin-bottom: 0; }
.result-grid + .btn { margin-top: 18px; }

@media (max-width: 820px) {
  .landing-grid, .result-grid { grid-template-columns: 1fr; }
  .landing-grid #addrate { position: static; }
  .landing-grid > .card:first-child { margin-bottom: 16px; }
}

/* ---- hero card (self-contained, brand style) ---- */
.hero-card {
  position: relative; overflow: hidden;
  display: grid; grid-template-columns: 1.15fr .85fr; gap: 16px; align-items: center;
  border-radius: 26px; padding: 34px 30px; margin-bottom: 20px;
  background:
    radial-gradient(120% 120% at 12% 0%, #FBFAFD 0%, #EFEAF7 42%, #DED6EE 100%);
  border: 1px solid #E3DDEF;
  box-shadow: var(--shadow-lg);
}
.hero-copy { position: relative; z-index: 2; }
.hero-copy h1 {
  font-size: 30px; line-height: 1.12; font-weight: 800; letter-spacing: -0.025em; color: var(--text);
}
.hero-copy p {
  margin-top: 14px; font-size: 14.5px; color: var(--muted); max-width: 34ch; line-height: 1.55;
}
.btn.hero-cta {
  width: auto; display: inline-flex; align-items: center; gap: 8px;
  margin-top: 20px; padding: 10px 18px; border-radius: 999px; font-size: 13.5px;
}
.hero-cta .arr {
  display: inline-flex; align-items: center; justify-content: center;
  width: 19px; height: 19px; border-radius: 50%; background: rgba(255,255,255,.18); font-size: 12px;
}
.hero-note { margin-top: 12px; font-size: 12.5px; color: var(--muted); }
.hero-note b { color: var(--good); font-weight: 700; }

/* coin cluster */
.hero-coins { position: relative; z-index: 1; align-self: stretch; min-height: 240px; }
.hero-coins .glow {
  position: absolute; left: 46%; top: 52%; width: 60%; height: 55%; transform: translate(-50%,-50%);
  background: radial-gradient(circle, rgba(255,255,255,.85), rgba(255,255,255,0) 70%); pointer-events: none;
}
.coin {
  position: absolute; filter: drop-shadow(0 8px 12px rgba(43,38,68,.22));
  will-change: transform;
  animation-name: coinFloat; animation-timing-function: ease-in-out; animation-iteration-count: infinite;
}
.coin svg { display: block; width: 100%; height: 100%; }
@keyframes coinFloat {
  0%   { transform: translateY(5px) rotate(-5deg); }
  50%  { transform: translateY(-13px) rotate(5deg); }
  100% { transform: translateY(5px) rotate(-5deg); }
}
@media (prefers-reduced-motion: reduce) { .coin { animation: none !important; } }

@media (min-width: 900px) {
  .hero-card { padding: 52px 48px; gap: 24px; }
  .hero-copy h1 { font-size: 42px; }
  .hero-copy p { font-size: 16px; max-width: 40ch; }
  .hero-coins { min-height: 320px; }
}
@media (max-width: 560px) {
  .hero-card { grid-template-columns: 1fr; padding: 26px 22px; gap: 4px; }
  .hero-copy h1 { font-size: 26px; }
  .hero-copy p { max-width: 42ch; }
  .hero-coins { min-height: 170px; margin-top: 8px; order: 2; }
}

/* ---- card surface ---- */
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 24px;
  margin-bottom: 16px;
  box-shadow: var(--shadow);
}

/* ---- section headings ---- */
.section-title { font-size: 19px; font-weight: 800; letter-spacing: -.01em; color: var(--text); margin-bottom: 4px; }
.section-sub { font-size: 13px; color: var(--muted); margin-bottom: 18px; line-height: 1.5; }

/* ---- landing bank list ---- */
.bank-row {
  display: flex; gap: 14px; align-items: flex-start;
  padding: 15px 0; border-bottom: 1px solid var(--line);
}
.bank-row:first-of-type { padding-top: 2px; }
.bank-row:last-child { border-bottom: none; padding-bottom: 2px; }
.bank-row .rank {
  flex-shrink: 0; width: 26px; height: 26px; margin-top: 2px;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 800; color: var(--muted);
  background: var(--surface); border: 1px solid var(--line); border-radius: 8px;
}
.bank-row.best .rank { color: #fff; background: var(--ink); border-color: var(--ink); }
.bank-main { flex: 1; min-width: 0; }
.bank-row .top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.bank-row .name { font-size: 15.5px; font-weight: 700; color: var(--text); display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.tagpill {
  font-size: 9.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
  color: var(--good); background: var(--good-bg); padding: 2px 7px; border-radius: 999px;
}
.bank-row .emi { font-size: 15.5px; font-weight: 800; color: var(--ink); white-space: nowrap; }
.bank-row .emi span { font-size: 12px; font-weight: 500; color: var(--muted); }
.bank-row .bar-track {
  height: 9px; background: var(--surface); border-radius: 999px;
  margin-top: 10px; overflow: hidden;
}
.bank-row .bar-fill {
  height: 100%; border-radius: 999px;
  background: linear-gradient(90deg, var(--lav), var(--lav2));
}
.bank-row.best .bar-fill { background: linear-gradient(90deg, var(--lav2), var(--ink)); }
.bank-row .meta { font-size: 12px; color: var(--muted); margin-top: 8px; }
.list-takeaway {
  margin-top: 16px; padding-top: 14px; border-top: 1px dashed var(--line);
  font-size: 13.5px; color: var(--muted); line-height: 1.5;
}
.list-takeaway b { color: var(--ink); font-weight: 800; }

/* ---- thin / empty ---- */
.thin { text-align: center; font-size: 15px; color: var(--muted); line-height: 1.6; padding: 10px 4px; }
.thin b { color: var(--ink); font-weight: 700; }

/* ---- form ---- */
.form-title { font-size: 19px; font-weight: 800; letter-spacing: -.01em; margin-bottom: 4px; }
.form-sub { font-size: 13px; color: var(--muted); margin-bottom: 20px; }

.field { margin-bottom: 16px; }
.field label { display: block; font-size: 12.5px; font-weight: 700; color: var(--muted); margin-bottom: 7px; letter-spacing: .01em; }
.field input, .field select {
  width: 100%; padding: 13px 14px; background: #fff;
  border: 1px solid var(--line); border-radius: 12px; color: var(--text);
  appearance: none; -webkit-appearance: none; transition: border-color .12s, box-shadow .12s;
}
.field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%235A5570' stroke-width='1.6' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px;
}
.field input:focus, .field select:focus, .email-row input:focus, textarea:focus {
  outline: none; border-color: var(--lav2); box-shadow: 0 0 0 4px rgba(180,170,207,.28);
}

.seg { display: flex; gap: 10px; flex-wrap: wrap; }
.seg .opt {
  flex: 1 1 auto; min-width: 100px; padding: 12px 10px; text-align: center;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  color: var(--muted); font-weight: 700; cursor: pointer; user-select: none;
  transition: all .13s;
}
.seg .opt:hover { border-color: var(--lav2); }
.seg .opt.on { background: var(--ink); border-color: var(--ink); color: #fff; box-shadow: var(--shadow); }

.btn {
  display: block; width: 100%; padding: 15px; border: none; border-radius: 13px;
  background: linear-gradient(180deg, #35304f, var(--ink));
  color: #fff; font-weight: 700; font-size: 15.5px; cursor: pointer; margin-top: 8px;
  box-shadow: 0 8px 20px rgba(43,38,68,.22); transition: transform .1s, box-shadow .12s, opacity .12s;
}
.btn:hover { box-shadow: 0 10px 26px rgba(43,38,68,.28); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; box-shadow: none; }
.btn-ghost { background: #fff; color: var(--ink); border: 1px solid var(--line); box-shadow: var(--shadow); }
.btn-ghost:hover { border-color: var(--lav2); }
.btn-sm { padding: 12px 18px; width: auto; margin-top: 0; font-size: 14.5px; }
/* Landing form submit — smaller than the default full-size .btn */
#f-submit {
  display: block; width: fit-content; margin: 20px auto 0;
  padding: 11px 28px; border-radius: 999px; font-size: 13.5px; font-weight: 700;
}

.form-error { font-size: 13px; color: #9b2c3a; margin-top: 12px; text-align: center; font-weight: 600; }

/* ---- result ---- */
.result-lead { text-align: center; }
.result-lead .frame { font-size: 17px; color: var(--text); line-height: 1.45; font-weight: 600; }
.result-lead .frame b { color: var(--ink); font-weight: 800; font-size: 20px; }
.result-lead .caveat { font-size: 13.5px; color: var(--muted); margin-top: 12px; max-width: 46ch; margin-left: auto; margin-right: auto; line-height: 1.55; }

/* pictograph */
.picto { display: flex; gap: 6px; justify-content: center; flex-wrap: nowrap; margin: 14px 0 2px; }
.picto .pc { display: inline-flex; }
.picto .pc svg { width: 22px; height: 22px; }
.picto .pc.less svg { fill: var(--ink); }
.picto .pc.you svg { fill: var(--lav); }

.cohort-note { font-size: 12.5px; color: var(--muted); text-align: center; margin: 12px auto 0; max-width: 48ch; line-height: 1.5; }
.cohort-note.widen { color: var(--warn); background: #fbf3e2; border: 1px solid #efdcb2; padding: 9px 12px; border-radius: 10px; }

/* EMI comparison */
.emi-pair { display: flex; gap: 12px; align-items: stretch; position: relative; }
.emi-box {
  flex: 1; text-align: center; background: var(--surface);
  border: 1px solid var(--line); border-radius: 16px; padding: 16px 12px;
}
.emi-box.ach { background: var(--good-bg); border-color: #cfe6d8; }
.emi-box .lbl { font-size: 10.5px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 800; }
.emi-box .val { font-size: 26px; font-weight: 800; margin-top: 8px; color: var(--text); letter-spacing: -.02em; }
.emi-box.ach .val { color: var(--good); }
.emi-box .sub { font-size: 11.5px; color: var(--muted); margin-top: 5px; }
.emi-diff { text-align: center; margin-top: 16px; font-size: 14px; color: var(--muted); }
.emi-diff b { color: var(--ink); font-size: 30px; font-weight: 800; display: block; margin-top: 4px; letter-spacing: -.02em; }

.benchmark { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); text-align: center; line-height: 1.5; }
.benchmark b { color: var(--ink); font-weight: 700; }
.benchmark .src { display: block; font-size: 11px; margin-top: 5px; }
.benchmark .src a { color: var(--muted); }
/* Pricing context (repo markup): subordinate continuation, no second divider. */
.pricing-context { margin-top: 8px; padding-top: 0; border-top: none; font-size: 12px; }
.pricing-context b:first-child { display: inline-block; margin-bottom: 2px; letter-spacing: .01em; }
/* Door target provenance: subordinate, never competes with the saving/net figure. */
.door-basis { font-size: 12px; color: var(--muted); margin: 6px 0 2px; line-height: 1.45; }

/* Economic conclusion = the headline. 'act' is strong ink; 'neutral' is softer,
   so "nothing worth changing" reads as a calm conclusion, not an alarm. */
.result-headline { font-size: 22px; font-weight: 800; letter-spacing: -.015em; line-height: 1.25; margin: 2px 0 18px; }
.result-headline.act { color: var(--ink); }
.result-headline.neutral { color: var(--muted); }
/* Action = the money line. Prominent, positive, leads into the door detail. */
.action-lead { font-size: 16px; font-weight: 700; color: var(--good); background: var(--good-bg);
  border-radius: 12px; padding: 12px 14px; margin-bottom: 14px; line-height: 1.4; }
.action-lead b { color: var(--good); }

/* ---- doors ---- */
.doors-title { font-size: 17px; font-weight: 800; letter-spacing: -.01em; margin: 2px 0 16px; }
.door {
  position: relative; overflow: hidden;
  border: 1px solid var(--line); border-radius: 16px; padding: 18px; margin-bottom: 14px;
  background: #fff;
}
.door:last-child { margin-bottom: 0; }
.door.rec { border-color: var(--ink); background: var(--card); box-shadow: var(--shadow-lg); }
.door.rec::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: linear-gradient(180deg, var(--lav2), var(--ink)); }
.door .dtag {
  display: inline-block; font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em;
  color: #fff; background: var(--ink); padding: 4px 10px; border-radius: 999px; margin-bottom: 12px;
}
.door .dnum { font-size: 10.5px; font-weight: 800; color: var(--lav2); text-transform: uppercase; letter-spacing: .08em; }
.door h3 { font-size: 17px; font-weight: 800; letter-spacing: -.01em; margin: 4px 0 8px; color: var(--text); }
.door .dsub { font-size: 13px; color: var(--muted); line-height: 1.5; margin-bottom: 10px; }
.door .net { font-size: 15px; color: var(--text); line-height: 1.5; }
.door .net b { color: var(--good); font-weight: 800; }
.door .net.none { color: var(--muted); }
.door .net.none b { color: var(--muted); }
.door .cost { font-size: 12.5px; color: var(--muted); margin-top: 6px; line-height: 1.5; }
.door .dbody { margin-top: 14px; }

.template {
  background: var(--surface); border: 1px dashed var(--lav2); border-radius: 12px;
  padding: 14px; font-size: 13.5px; color: var(--text); line-height: 1.6; white-space: pre-wrap;
  margin: 12px 0; font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}
.warning {
  background: #fbf3e2; border: 1px solid #e6cf9a; border-radius: 12px;
  padding: 14px; font-size: 13px; color: #5c4409; line-height: 1.6; margin: 12px 0;
}
.warning b { color: #7a1f0f; }

.fee-disclaimer {
  margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line);
  font-size: 12px; color: var(--muted); line-height: 1.55;
}
.fee-disclaimer b { color: var(--ink); font-weight: 700; }

.email-row { display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap; }
.email-row input {
  flex: 1 1 180px; padding: 13px 14px; background: #fff;
  border: 1px solid var(--line); border-radius: 12px; color: var(--text);
}
.email-ok { font-size: 13.5px; color: var(--good); margin-top: 10px; font-weight: 700; }

/* ---- reveal (on-screen detail behind a high-intent click) ---- */
.reveal-btn {
  width: auto; margin-top: 14px; padding: 12px 20px; font-size: 14.5px;
  background: var(--ink); color: #fff; border: 0; border-radius: 12px;
  font-weight: 700; cursor: pointer;
}
.reveal-btn:hover { opacity: .92; }
.reveal { margin-top: 14px; }
.reveal-lead { font-size: 14px; color: var(--text); line-height: 1.55; margin: 0 0 6px; }
.reveal-list { margin: 8px 0 0; padding-left: 20px; }
.reveal-list li { font-size: 13.5px; color: var(--text); line-height: 1.6; margin: 7px 0; }
.reveal-list b { font-weight: 700; }
.calc-detail td { font-size: 13.5px; padding: 9px 0; }
.reveal-note { font-size: 12px; color: var(--muted); line-height: 1.55; margin: 10px 0 0; }

/* ---- dot plot ---- */
details.dotwrap { border: 1px solid var(--line); border-radius: 16px; background: var(--card); padding: 0 18px; box-shadow: var(--shadow); }
details.dotwrap > summary {
  list-style: none; cursor: pointer; padding: 16px 0; font-size: 14.5px; font-weight: 700;
  color: var(--ink); display: flex; justify-content: space-between; align-items: center;
}
details.dotwrap > summary::-webkit-details-marker { display: none; }
details.dotwrap > summary::after { content: '＋'; color: var(--muted); font-weight: 700; }
details.dotwrap[open] > summary::after { content: '－'; }
.dotplot { padding: 4px 0 20px; }
.dotplot .cap { font-size: 12px; color: var(--muted); margin-bottom: 8px; }

.foot { text-align: center; font-size: 11.5px; color: var(--muted); margin-top: 28px; line-height: 1.6; }
.foot a { color: var(--muted); }

@media (max-width: 400px) {
  .hero h1 { font-size: 24px; }
  .emi-box .val { font-size: 22px; }
  .emi-diff b { font-size: 25px; }
  .card { padding: 18px; }
  .picto .pc svg { width: 20px; height: 20px; }
  .picto { gap: 4px; }
}

/* ---------------------------------------------------------------------------
   Auth (sign-in gate for submitting only). Matches the lavender tokens above.
   The UI never renders a name/email back to any viewer — this is anti-spam only.
--------------------------------------------------------------------------- */
.auth-status { font-size: 12.5px; color: var(--muted); text-align: center; margin-top: 10px; }
.auth-status a { color: var(--ink); text-decoration: underline; }
.auth-panel {
  margin-top: 14px; padding: 16px; background: var(--surface);
  border: 1px solid var(--line); border-radius: 14px;
}
.auth-panel .auth-lead { font-size: 13px; color: var(--muted); line-height: 1.5; margin-bottom: 12px; }
.auth-panel .auth-lead b { color: var(--text); }
.auth-google { background: #fff; color: var(--ink); border: 1px solid var(--line); box-shadow: var(--shadow); }
.auth-google:hover { border-color: var(--lav2); }
.auth-or { display: flex; align-items: center; gap: 10px; margin: 12px 0; color: var(--muted); font-size: 12px; }
.auth-or::before, .auth-or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.auth-panel input {
  width: 100%; padding: 12px 13px; margin-bottom: 8px; font-size: 15px;
  background: #fff; border: 1px solid var(--line); border-radius: 12px; color: var(--text);
}
.auth-panel input:focus { outline: none; border-color: var(--lav2); }
.auth-btns { display: flex; gap: 8px; margin-top: 4px; }
.auth-btns .btn { margin-top: 0; }
.auth-msg { font-size: 12.5px; color: var(--muted); margin-top: 10px; text-align: center; min-height: 16px; }

/* Password show/hide toggle inside the auth field. */
.pass-wrap { position: relative; }
.pass-wrap input { padding-right: 44px; }
.pass-toggle {
  position: absolute; top: 0; right: 0; height: 44px; width: 42px;
  display: flex; align-items: center; justify-content: center;
  background: none; border: none; cursor: pointer; color: var(--muted); padding: 0;
}
.pass-toggle:hover { color: var(--ink); }

/* ===========================================================================
   Result page — editorial redesign (verdict hero → KPI band → action → evidence)
   Reuses the existing tokens, .door, .picto, .benchmark, .fee-disclaimer.
=========================================================================== */
.rgrid { display: block; }
.tnum { font-variant-numeric: tabular-nums; }
.reyebrow { font-size: 11.5px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }

/* Verdict hero */
.verdict { position: relative; overflow: hidden; border-radius: 26px; margin: 6px 0 26px;
  padding: 44px 40px 40px; border: 1px solid var(--line); color: var(--ink);
  background:
    radial-gradient(120% 140% at 88% 8%, rgba(180,170,207,.55) 0%, rgba(201,194,221,.16) 42%, rgba(201,194,221,0) 66%),
    linear-gradient(155deg, #F6F4FA 0%, #ECE8F4 58%, #E4DEF0 100%); }
.verdict h1 { margin: 14px 0 0; font-size: clamp(28px, 5vw, 44px); font-weight: 800;
  letter-spacing: -.02em; line-height: 1.08; text-wrap: balance; max-width: 16ch; }
.verdict.neutral h1 { color: var(--ink); }
.verdict .v-lead { margin-top: 16px; font-size: clamp(15px, 2.2vw, 19px); color: #3d3757; max-width: 46ch; line-height: 1.5; }
.verdict .v-lead b { color: var(--ink); font-weight: 800; }
.verdict .chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.verdict .chip { font-size: 12.5px; font-weight: 500; color: #4a4468; background: rgba(255,255,255,.66);
  border: 1px solid rgba(43,38,68,.08); padding: 6px 12px; border-radius: 999px; }
.v-coin { position: absolute; right: -38px; bottom: -46px; width: 220px; height: 220px; opacity: .48; pointer-events: none;
  background: radial-gradient(circle at 38% 34%, #EBC77E 0%, #D9A94E 44%, #B9863A 72%, #8f6528 100%); border-radius: 50%; }
.v-coin.two { right: 120px; bottom: -96px; width: 144px; height: 144px; opacity: .3; }

/* KPI band */
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; margin-bottom: 8px;
  background: var(--card); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; box-shadow: var(--shadow); }
.kpi { padding: 22px 24px; border-left: 1px solid var(--line); }
.kpi:first-child { border-left: none; }
.kpi .k-lbl { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.kpi .k-val { margin-top: 8px; font-size: 26px; font-weight: 800; letter-spacing: -.02em; color: var(--ink); }
.kpi .k-sub { margin-top: 3px; font-size: 12.5px; color: var(--muted); }
.kpi.flag .k-val { color: var(--warn); }

/* Section rhythm */
.rband { padding-block: 40px 4px; }
.rband + .rband { padding-top: 8px; }
.sec-head { display: flex; align-items: baseline; gap: 14px; margin-bottom: 20px; flex-wrap: wrap; }
.sec-head h2 { margin: 0; font-size: 22px; font-weight: 800; letter-spacing: -.015em; color: var(--ink); }

/* Recommended action — the .door(.rec) inside already renders as the card */
.action-wrap { display: block; }
.action-wrap .door { margin-bottom: 0; }
.action-wrap .door.rec { padding: 28px 30px; }

/* Evidence grid */
.evidence { display: grid; grid-template-columns: 1.35fr .95fr; gap: 22px; align-items: start; }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 26px 28px; box-shadow: var(--shadow); }
.panel h4 { margin: 0; font-size: 16px; font-weight: 800; color: var(--ink); }
.panel .p-note { margin-top: 8px; font-size: 13px; color: var(--muted); line-height: 1.55; }
.panel .p-note b { color: var(--ink); }
.panel .dotplot { padding: 18px 0 6px; }
.panel .picto { justify-content: flex-start; margin: 8px 0 4px; }

/* Context stack — reflow the reused .benchmark/.pricing-context to left-aligned items */
.ctx { display: flex; flex-direction: column; margin-top: 16px; }
.ctx > * { padding: 14px 0; border-bottom: 1px solid var(--line); }
.ctx > *:first-child { padding-top: 0; }
.ctx > *:last-child { border-bottom: none; padding-bottom: 0; }
.ctx .benchmark, .ctx .pricing-context { margin: 0; border-top: none; text-align: left; font-size: 13.5px; color: var(--text); }
.ctx .benchmark .src { text-align: left; }
.ctx .c-lbl { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.ctx .c-val { margin-top: 5px; font-size: 13.5px; color: var(--text); line-height: 1.5; }
.ctx .c-val b { color: var(--ink); }

/* Closing band */
.closing { border-radius: 24px; padding: 40px; text-align: center; margin: 34px 0 10px;
  background: linear-gradient(135deg, #ECE8F4 0%, #E0D9EE 100%); border: 1px solid var(--line); }
.closing h3 { margin: 0 auto; font-size: clamp(19px, 3vw, 25px); font-weight: 800; letter-spacing: -.015em;
  color: var(--ink); max-width: 26ch; text-wrap: balance; }
.c-btns { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 22px; }
.cbtn { width: auto; display: inline-flex; align-items: center; margin-top: 0; }
.r-footnote { text-align: center; color: var(--muted); font-size: 12.5px; padding-block: 8px 30px; line-height: 1.6; max-width: 60ch; margin: 0 auto; }

@media (max-width: 760px) {
  .verdict { padding: 34px 22px 30px; border-radius: 22px; }
  .kpis { grid-template-columns: 1fr 1fr; }
  .kpi { border-left: 1px solid var(--line); border-top: 1px solid var(--line); }
  .kpi:first-child, .kpi:nth-child(2) { border-top: none; }
  .kpi:nth-child(odd) { border-left: none; }
  .evidence { grid-template-columns: 1fr; }
}

/* Inline hint/optional tag inside a field label. */
.field label .opt-tag { font-weight: 500; color: var(--muted); font-size: 12px; letter-spacing: 0; text-transform: none; }

/* ===========================================================================
   Landing — editorial sections (eyebrow, trust strip, how-it-works, closing).
   Reuses the existing hero-card + animated coins unchanged.
=========================================================================== */
.hero-copy .eyebrow { font-size: 11.5px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: 12px; }
.hero-copy h1 { text-wrap: balance; }

/* Trust strip */
.trust { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; margin: -4px 0 26px;
  background: var(--card); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; box-shadow: var(--shadow); }
.trust .t { padding: 18px 24px; border-left: 1px solid var(--line); font-size: 13.5px; color: var(--muted); line-height: 1.45; }
.trust .t:first-child { border-left: none; }
.trust .t b { display: block; color: var(--ink); font-weight: 800; font-size: 22px; letter-spacing: -.02em; margin-bottom: 3px; }

/* Section head shared by landing sections */
.shead { display: flex; align-items: baseline; gap: 14px; margin-bottom: 18px; flex-wrap: wrap; }
.shead .eyebrow { font-size: 11.5px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.shead h2 { margin: 0; font-size: 22px; font-weight: 800; letter-spacing: -.015em; color: var(--ink); }

/* How it works */
.how { margin-top: 8px; margin-bottom: 8px; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.step { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 26px 24px; box-shadow: var(--shadow); }
.step .num { font-size: 12px; font-weight: 800; letter-spacing: .08em; color: var(--lav2); }
.step h3 { margin: 12px 0 8px; font-size: 17px; font-weight: 800; letter-spacing: -.01em; color: var(--ink); }
.step p { margin: 0; font-size: 14px; color: var(--muted); line-height: 1.55; }

/* Closing band */
.land-closing { border-radius: 24px; padding: 46px 40px; text-align: center; margin-top: 34px;
  background: linear-gradient(135deg, #ECE8F4 0%, #E0D9EE 100%); border: 1px solid var(--line); }
.land-closing h3 { margin: 0 auto; font-size: clamp(21px, 3vw, 28px); font-weight: 800; letter-spacing: -.015em; color: var(--ink); max-width: 22ch; text-wrap: balance; }
.land-closing p { margin: 12px auto 0; font-size: 14.5px; color: var(--muted); max-width: 46ch; line-height: 1.55; }
.land-closing .hero-cta { margin-top: 24px; }

@media (max-width: 820px) {
  .trust, .steps { grid-template-columns: 1fr; }
  .trust .t { border-left: none; border-top: 1px solid var(--line); }
  .trust .t:first-child { border-top: none; }
}

/* Landing with the leaderboard removed — the form spans the full content width,
   its borders aligned with the hero, trust strip and other sections. Fields lay
   out in two columns; the submit button and auth panel stay full width. */
.form-solo { width: 100%; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 22px; }
.form-grid .field { margin-bottom: 16px; }
@media (max-width: 620px) { .form-grid { grid-template-columns: 1fr; } }

/* Door 3 (balance transfer) — numbers as a compact table, prose trimmed to a
   couple of lines beneath it. */
.door-table { width: 100%; border-collapse: collapse; margin: 10px 0 14px; }
.door-table td { padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14px; color: var(--muted); line-height: 1.4; vertical-align: baseline; }
.door-table td:last-child { text-align: right; font-weight: 700; color: var(--text); white-space: nowrap; padding-left: 14px; }
.door-table td.cost-val { color: var(--warn); }
.door-table .net-row td { border-bottom: none; padding-top: 13px; color: var(--ink); font-weight: 800; font-size: 15px; }
.door-table .net-row td:last-child { color: var(--good); font-size: 21px; letter-spacing: -.01em; }
.door-line { font-size: 13px; color: var(--muted); line-height: 1.5; margin: 0 0 8px; }
.door-cta-prompt { font-size: 13.5px; color: var(--muted); line-height: 1.5; margin: 6px 0 8px; }

/* ===========================================================================
   Legal pages (privacy / terms), footer links, and the disclaimer modal.
=========================================================================== */
.legal { max-width: 720px; margin: 8px auto 40px; }
.legal h1 { font-size: 30px; font-weight: 800; letter-spacing: -.02em; color: var(--ink); margin-bottom: 6px; }
.legal .legal-meta { color: var(--muted); font-size: 13px; margin-bottom: 22px; }
.legal h2 { font-size: 18px; font-weight: 800; color: var(--ink); margin: 26px 0 8px; letter-spacing: -.01em; }
.legal p, .legal li { font-size: 15px; color: var(--text); line-height: 1.65; }
.legal p { margin-bottom: 12px; }
.legal ul { margin: 0 0 12px; padding-left: 20px; }
.legal li { margin-bottom: 8px; }
.legal a { color: var(--ink); }
.legal .legal-foot { margin-top: 28px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.legal-page-foot { margin-top: 20px; }

/* Footer links */
.foot-links { display: flex; gap: 18px; justify-content: center; flex-wrap: wrap; margin-bottom: 10px; }
.foot-links a { color: var(--muted); font-size: 13px; font-weight: 600; text-decoration: none; }
.foot-links a:hover { color: var(--ink); text-decoration: underline; }
.foot-note { font-size: 11.5px; color: var(--muted); text-align: center; line-height: 1.6; max-width: 68ch; margin: 0 auto; }

/* Disclaimer modal */
.modal-overlay { position: fixed; inset: 0; z-index: 100; display: flex; align-items: center; justify-content: center;
  padding: 20px; background: rgba(20,18,31,.55); }
.modal-overlay[hidden] { display: none; }
.modal { position: relative; width: 100%; max-width: 560px; max-height: 85vh; overflow-y: auto;
  background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 30px 32px; box-shadow: var(--shadow-lg); }
.modal h2 { font-size: 22px; font-weight: 800; color: var(--ink); margin-bottom: 14px; letter-spacing: -.015em; }
.modal-body p { font-size: 14px; color: var(--text); line-height: 1.6; margin-bottom: 12px; }
.modal-body p:last-child { margin-bottom: 0; }
.modal-body a { color: var(--ink); }
.modal-close { position: absolute; top: 14px; right: 16px; width: 32px; height: 32px; padding: 0;
  background: none; border: none; font-size: 26px; line-height: 1; color: var(--muted); cursor: pointer; }
.modal-close:hover { color: var(--ink); }
@media (max-width: 480px) { .modal { padding: 24px 20px; } }

/* Sign-in is a pop-up: the auth panel is now a modal box inside .modal-overlay.
   Overrides the old inline-panel box styling; the inner element styles
   (.auth-panel .auth-lead / input / .auth-or / .auth-btns / .auth-google) stay. */
.auth-panel.auth-modal {
  position: relative; margin: 0; width: 100%; max-width: 420px; max-height: 88vh; overflow-y: auto;
  padding: 30px 28px; background: var(--card); border: 1px solid var(--line);
  border-radius: 20px; box-shadow: var(--shadow-lg);
}
.auth-modal .auth-lead { margin-top: 2px; padding-right: 26px; }
