/* Part 107 Test website. The app's "magenta line" tokens (src/constants/theme.ts, docs/design.md):
   chart paper and graphite neutrals, one magenta accent for the route, Mona Sans and B612 Mono. */

@font-face { font-family: 'Mona Display'; src: url('/assets/fonts/MonaSansDisplayExpanded-Bold.woff2') format('woff2'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Mona Expanded'; src: url('/assets/fonts/MonaSansExpanded-SemiBold.woff2') format('woff2'); font-weight: 600; font-display: swap; }
@font-face { font-family: 'Mona Sans'; src: url('/assets/fonts/MonaSans-Regular.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Mona Sans'; src: url('/assets/fonts/MonaSans-Medium.woff2') format('woff2'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'Mona Sans'; src: url('/assets/fonts/MonaSans-SemiBold.woff2') format('woff2'); font-weight: 600; font-display: swap; }
@font-face { font-family: 'B612 Mono'; src: url('/assets/fonts/B612Mono-Regular.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'B612 Mono'; src: url('/assets/fonts/B612Mono-Bold.woff2') format('woff2'); font-weight: 700; font-display: swap; }

:root {
  --bg: #f2f3f0;
  --surface: #ffffff;
  --surface-muted: #e9ebe7;
  --stroke: rgba(21, 23, 27, 0.1);
  --stroke-strong: rgba(21, 23, 27, 0.18);
  --contour: rgba(21, 23, 27, 0.13);
  --text: #15171b;
  --text-2: #5b616b;
  --text-3: #6a707a;
  --inverse: #15171b;
  --on-inverse: #f7f8f5;
  --accent: #c4166a;
  --accent-text: #c4166a;
  --accent-soft: rgba(196, 22, 106, 0.1);
  --on-accent: #ffffff;
  --success: #0b7a48;
  --warning: #8a5a00;
  --wind: #0a7480;
  --cloud: #1f57b8;
  --shadow: 0 1px 2px rgba(27, 42, 31, 0.06), 0 12px 32px rgba(27, 42, 31, 0.08);
  --phone-shadow: 0 30px 60px -20px rgba(27, 42, 31, 0.35);

  --display: 'Mona Display', 'Mona Sans', system-ui, sans-serif;
  --expanded: 'Mona Expanded', 'Mona Sans', system-ui, sans-serif;
  --sans: 'Mona Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'B612 Mono', ui-monospace, 'SF Mono', Menlo, monospace;

  /* Shape lock, same as the app: capsule buttons, 22 for panels, 14 for inputs, 12 for tiles. */
  --r-panel: 22px;
  --r-input: 14px;
  --r-tile: 12px;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --gutter: 16px;
  --max: 1180px;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0c0d0f;
    --surface: #15171a;
    --surface-muted: #1c1f23;
    --stroke: rgba(236, 237, 239, 0.08);
    --stroke-strong: rgba(236, 237, 239, 0.16);
    --contour: rgba(236, 237, 239, 0.1);
    --text: #ecedef;
    --text-2: #a0a5ae;
    --text-3: #7a808a;
    --inverse: #ecedef;
    --on-inverse: #0c0d0f;
    --accent: #ff5ca8;
    --accent-text: #ff78b8;
    --accent-soft: rgba(255, 92, 168, 0.14);
    --on-accent: #140a10;
    --success: #37d68a;
    --warning: #f4b942;
    --wind: #3cc8d6;
    --cloud: #7aa7ff;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 12px 32px rgba(0, 0, 0, 0.35);
    --phone-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.8);
  }
}

@media (min-width: 720px) {
  :root { --gutter: 32px; }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-weight: 700; text-wrap: balance; }
::selection { background: var(--accent); color: var(--on-accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.icon { width: 1.15em; height: 1.15em; flex: none; }
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: -999px; top: 8px; z-index: 30; background: var(--inverse); color: var(--on-inverse); padding: 8px 14px; border-radius: 999px; }
.skip:focus { left: 12px; }

/* ---------- Buttons ---------- */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 24px;
  border-radius: 999px;
  border: 0;
  background: var(--inverse);
  color: var(--on-inverse);
  font: 600 16px/1 var(--sans);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: transform 120ms var(--ease-out), background-color 160ms var(--ease-out);
}
.button:active { transform: scale(0.97); }
.button.secondary { background: var(--surface-muted); color: var(--text); }
.button.accent { background: var(--accent); color: var(--on-accent); }
.button.small { min-height: 38px; padding: 0 16px; font-size: 14px; }
.button .icon { width: 20px; height: 20px; }
@media (hover: hover) {
  .button:hover { background: color-mix(in srgb, var(--inverse) 88%, var(--accent)); }
  .button.secondary:hover { background: color-mix(in srgb, var(--surface-muted) 80%, var(--text) 8%); }
}
.soon {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 22px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--stroke);
  color: var(--text-2);
  font-weight: 500;
  font-size: 15px;
}
.text-link { color: var(--accent-text); font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.text-link:hover { text-decoration: underline; text-underline-offset: 4px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 200ms;
}
.site-header.scrolled { border-bottom-color: var(--stroke); }
.nav { display: flex; align-items: center; gap: 24px; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font: 600 16px/1 var(--expanded); letter-spacing: -0.01em; white-space: nowrap; }
.brand img { border-radius: 8px; }
.nav-links { display: none; gap: 28px; margin-left: auto; font-size: 15px; color: var(--text-2); }
.nav-links a { text-decoration: none; }
.nav-links a:hover { color: var(--text); }
.nav .button { margin-left: auto; }
@media (min-width: 860px) {
  .nav-links { display: flex; }
  .nav .button { margin-left: 8px; }
}

/* ---------- Hero ---------- */
.hero { position: relative; isolation: isolate; overflow: hidden; }
.hero-terrain {
  position: absolute; left: -50%; right: -60vw; bottom: -60px; height: 80%; z-index: -1; pointer-events: none;
  -webkit-mask-image: radial-gradient(ellipse 60% 75% at 55% 70%, #000 55%, transparent 100%);
  mask-image: radial-gradient(ellipse 60% 75% at 55% 70%, #000 55%, transparent 100%);
}
.hero-terrain canvas { width: 100%; height: 100%; display: block; }
.hero-grid { display: grid; gap: 48px; padding-top: 40px; padding-bottom: 56px; align-items: center; }
.hero-copy { display: grid; gap: 22px; max-width: 700px; }
.label { font: 600 14px/1.2 var(--expanded); color: var(--accent-text); letter-spacing: 0; }
.hero h1 { font-family: var(--display); font-size: clamp(40px, 4.6vw, 64px); line-height: 1.04; letter-spacing: -0.035em; }
.hero h1 .nowrap { white-space: nowrap; }
.lede { font-size: clamp(18px, 2vw, 20px); color: var(--text-2); max-width: 32ch; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.hero-visual { position: relative; isolation: isolate; display: grid; place-items: center; min-height: 520px; }
@media (min-width: 960px) {
  .hero-grid { grid-template-columns: 1.4fr 0.8fr; min-height: min(calc(100dvh - 64px), 820px); padding-top: 24px; padding-bottom: 48px; }
}

/* A phone: the real app screenshots, in a device frame. */
.phone {
  position: relative;
  width: min(300px, 74vw);
  aspect-ratio: 390 / 844;
  border-radius: 46px;
  padding: 9px;
  background: #0b0c0e;
  box-shadow: var(--phone-shadow), inset 0 0 0 1.5px rgba(255, 255, 255, 0.08);
}
.phone::before {
  content: '';
  position: absolute;
  top: 19px;
  left: 50%;
  width: 84px;
  height: 24px;
  border-radius: 999px;
  background: #0b0c0e;
  transform: translateX(-50%);
  z-index: 1;
}
.phone picture, .phone img { width: 100%; height: 100%; }
.phone img { border-radius: 38px; object-fit: cover; object-position: top; }
.hero .phone { transform: rotate(-2deg); }

/* ---------- Facts band ---------- */
.facts { border-top: 1px solid var(--stroke); border-bottom: 1px solid var(--stroke); }
.facts-grid { display: grid; grid-template-columns: repeat(2, 1fr); }
.fact { padding: 28px 0; display: grid; gap: 4px; }
.fact b { font: 700 clamp(30px, 4vw, 44px)/1 var(--display); letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.fact span { color: var(--text-2); font-size: 15px; max-width: 22ch; }
.fact:nth-child(odd) { padding-right: 16px; }
.fact:nth-child(even) { padding-left: 16px; border-left: 1px solid var(--stroke); }
.fact:nth-child(n + 3) { border-top: 1px solid var(--stroke); }
@media (min-width: 860px) {
  .facts-grid { grid-template-columns: repeat(4, 1fr); }
  .fact { padding: 36px 24px; border-top: 0 !important; }
  .fact:first-child { padding-left: 0; }
  .fact + .fact { border-left: 1px solid var(--stroke); }
}

/* ---------- Sections ---------- */
.section { padding: 88px 0; }
@media (min-width: 960px) { .section { padding: 120px 0; } }
.section-head { display: grid; gap: 14px; max-width: 700px; margin-bottom: 48px; }
.section-head h2, .closing h2 { font-family: var(--display); font-size: clamp(32px, 4.6vw, 52px); line-height: 1.05; letter-spacing: -0.03em; }
.section-head p { color: var(--text-2); font-size: 18px; max-width: 58ch; }

/* Complaints from other apps, and the fix for each: a two-column ledger, not cards. */
.ledger { display: grid; gap: 0; border-top: 1px solid var(--stroke-strong); }
.ledger-row { display: grid; gap: 10px; padding: 26px 0; border-bottom: 1px solid var(--stroke); }
.ledger-row h3 { font: 600 19px/1.3 var(--expanded); letter-spacing: -0.01em; display: flex; gap: 12px; align-items: baseline; }
.ledger-row h3 .icon { color: var(--accent-text); transform: translateY(3px); }
.complaint { color: var(--text-3); font-size: 16px; }
.complaint q { quotes: '\201C' '\201D'; font-style: italic; }
.ledger-row p.fix { color: var(--text-2); }
@media (min-width: 860px) {
  .ledger-row { grid-template-columns: 0.9fr 1.1fr; column-gap: 48px; padding: 30px 0; }
  .ledger-row .complaint { grid-column: 1; grid-row: 1 / span 2; font-size: 18px; color: var(--text-2); }
  .ledger-row h3 { grid-column: 2; }
  .ledger-row .fix { grid-column: 2; }
}

/* ---------- Bento ---------- */
.bento { display: grid; gap: 16px; }
.tile {
  position: relative;
  overflow: hidden;
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 28px;
  border-radius: var(--r-panel);
  background: var(--surface);
  border: 1px solid var(--stroke);
  min-height: 340px;
}
.tile h3 { font: 600 22px/1.2 var(--expanded); letter-spacing: -0.015em; }
.tile p { color: var(--text-2); font-size: 16px; max-width: 40ch; }
.tile .shot {
  position: relative;
  margin-top: 18px;
  align-self: end;
  justify-self: center;
  width: min(270px, 80%);
  aspect-ratio: 390 / 560;
  border-radius: 28px 28px 0 0;
  overflow: hidden;
  border: 7px solid #0b0c0e;
  border-bottom: 0;
  margin-bottom: -28px;
  box-shadow: var(--phone-shadow);
}
.tile .shot img { width: 100%; height: auto; }
.tile.chart { background: #0e1013; color: #ecedef; border-color: transparent; }
.tile.chart p { color: #a0a5ae; }
.tile.chart .shot { width: min(330px, 86%); aspect-ratio: 390 / 700; border-color: #26292e; }
.tile.review { background: var(--accent-soft); border-color: transparent; }
.tile.exam { background: var(--surface-muted); border-color: transparent; }
.tile .shot.bottom img { transform: translateY(-33%); }
.tile-terrain { position: absolute; inset: auto 0 0 0; height: 55%; pointer-events: none; }
.tile > :not(.tile-terrain) { position: relative; z-index: 1; }
.tile.exam .shot + .shot { display: none; }
@media (min-width: 760px) {
  .bento { grid-template-columns: repeat(2, 1fr); }
  .tile.chart { grid-row: span 2; }
  .tile.exam { grid-column: 1 / -1; }
}
@media (min-width: 1080px) {
  /* Four tiles: the chart runs down the left, two tiles sit beside it, mock exams span beneath them. */
  .bento { grid-template-columns: 1.2fr 1fr 1fr; }
  .tile.chart { grid-column: 1; grid-row: 1 / span 2; grid-template-rows: auto auto 1fr; }
  .tile.chart .shot { width: min(370px, 94%); aspect-ratio: 390 / 844; }
  .tile.review { grid-column: 2; grid-row: 1; }
  .tile.syllabus { grid-column: 3; grid-row: 1; }
  .tile.exam { grid-column: 2 / span 2; grid-row: 2; grid-template-columns: 1.15fr 1fr 1fr; align-items: end; column-gap: 20px; padding: 32px 28px 0; }
  .tile.exam > h3, .tile.exam > p, .tile.exam > .exam-stats { grid-column: 1; align-self: start; }
  .tile.exam > p { grid-row: 2; }
  .tile.exam > .exam-stats { grid-row: 3; padding-bottom: 32px; }
  .tile.exam .shot { grid-row: 1 / span 3; grid-column: 2; margin-top: 0; width: 100%; }
  .tile.exam .shot + .shot { display: block; grid-column: 3; }
}
.tile .points { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 10px; font-size: 15px; color: var(--text-2); }
.tile .points li { display: flex; gap: 10px; align-items: flex-start; }
.tile .points .icon { color: var(--accent-text); margin-top: 3px; }
.exam-stats { display: grid; grid-template-columns: repeat(3, auto); justify-content: start; gap: 18px; margin-top: 14px; }
.exam-stats div { display: grid; gap: 2px; }
.exam-stats b { font: 700 26px/1 var(--display); letter-spacing: -0.03em; white-space: nowrap; }
.exam-stats span { color: var(--text-2); font-size: 14px; white-space: nowrap; }

/* ---------- METAR decoder ---------- */
.decoder { position: relative; }
.decoder-panel {
  display: grid;
  gap: 0;
  border-radius: var(--r-panel);
  background: var(--surface);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.decoder-input { display: grid; gap: 10px; padding: 24px; border-bottom: 1px solid var(--stroke); }
.decoder-input label { font-weight: 600; font-size: 15px; color: var(--text-2); }
.decoder-input textarea {
  width: 100%;
  min-height: 84px;
  resize: vertical;
  padding: 14px 16px;
  border-radius: var(--r-input);
  border: 1.5px solid var(--stroke-strong);
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.6 var(--mono);
  text-transform: uppercase;
}
.decoder-input textarea:focus { outline: none; border-color: var(--accent); }
.decoder-input .hint { font-size: 14px; color: var(--text-3); }
.samples { display: flex; flex-wrap: wrap; gap: 8px; }
.samples button {
  min-height: 34px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid var(--stroke-strong);
  background: transparent;
  color: var(--text-2);
  font: 500 14px/1 var(--sans);
  cursor: pointer;
  transition: transform 120ms var(--ease-out), background-color 160ms;
}
.samples button:active { transform: scale(0.96); }
.samples button[aria-pressed='true'] { background: var(--inverse); color: var(--on-inverse); border-color: var(--inverse); }
.decoder-out { display: grid; gap: 0; }
.tokens { padding: 22px 24px; display: flex; flex-wrap: wrap; gap: 6px 8px; font: 400 clamp(17px, 2.2vw, 22px)/1.5 var(--mono); border-bottom: 1px solid var(--stroke); }
.token {
  appearance: none;
  border: 0;
  background: transparent;
  font: inherit;
  color: var(--text);
  padding: 2px 6px;
  margin: -2px -2px;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 140ms;
}
.token[data-kind='station'] { color: var(--accent-text); font-weight: 700; }
.token[data-kind='time'], .token[data-kind='type'], .token[data-kind='remark'], .token[data-kind='auto'] { color: var(--text-3); }
.token[data-kind='wind'] { color: var(--wind); }
.token[data-kind='visibility'], .token[data-kind='rvr'] { color: var(--success); }
.token[data-kind='weather'] { color: var(--warning); }
.token[data-kind='clouds'] { color: var(--cloud); }
.token[data-kind='unknown'] { color: var(--text-3); text-decoration: underline dotted; }
.token.active, .token:hover { background: var(--accent-soft); }
.decoded { list-style: none; margin: 0; padding: 12px 12px 16px; display: grid; gap: 2px; }
.decoded li {
  display: grid;
  grid-template-columns: minmax(96px, 30%) 1fr;
  gap: 16px;
  padding: 10px 12px;
  border-radius: var(--r-tile);
  transition: background-color 140ms;
}
.decoded li.active { background: var(--accent-soft); }
.decoded code { font: 400 15px/1.5 var(--mono); color: var(--text-2); word-break: break-all; }
.decoded span { font-size: 16px; }
.decoded .empty { grid-template-columns: 1fr; color: var(--text-3); }
.legend { display: flex; flex-wrap: wrap; gap: 16px; padding: 0 24px 20px; font-size: 13px; color: var(--text-2); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 9px; height: 9px; border-radius: 3px; display: inline-block; }
@media (min-width: 960px) {
  .decoder-grid { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: 56px; align-items: start; }
  .decoder-grid .section-head { position: sticky; top: 110px; margin-bottom: 0; }
}

/* ---------- Pricing ---------- */
.plans { display: grid; gap: 16px; max-width: 920px; }
.plan { display: grid; align-content: start; gap: 16px; padding: 32px; border-radius: var(--r-panel); border: 1px solid var(--stroke); background: var(--surface); }
.plan h3 { font: 600 20px/1.2 var(--expanded); }
.plan .price { font: 700 44px/1 var(--display); letter-spacing: -0.03em; }
.plan .price small { font: 500 16px/1 var(--sans); color: var(--text-2); letter-spacing: 0; }
.plan .note { color: var(--text-2); font-size: 15px; }
.plan.featured { background: var(--inverse); color: var(--on-inverse); border-color: transparent; }
.plan.featured .note, .plan.featured .price small { color: color-mix(in srgb, var(--on-inverse) 70%, transparent); }
.plan.featured .checks .icon { color: var(--accent); }
.checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.checks li { display: flex; gap: 12px; align-items: flex-start; }
.checks .icon { color: var(--accent-text); margin-top: 4px; }
@media (min-width: 760px) { .plans { grid-template-columns: 1fr 1fr; } }

/* ---------- FAQ ---------- */
.faq-grid { display: grid; gap: 8px; max-width: 860px; }
.faq { border-top: 1px solid var(--stroke-strong); }
.faq details { border-bottom: 1px solid var(--stroke); }
.faq summary {
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 0;
  font: 600 18px/1.35 var(--sans);
  cursor: pointer;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary .icon { color: var(--text-3); margin-top: 4px; transition: transform 200ms var(--ease-out); }
.faq details[open] summary .icon { transform: rotate(180deg); }
.faq details > div { padding: 0 0 22px; color: var(--text-2); max-width: 68ch; }


/* ---------- Closing ---------- */
.closing { position: relative; isolation: isolate; overflow: hidden; border-top: 1px solid var(--stroke); }
.closing-inner { display: grid; gap: 22px; justify-items: start; padding: 96px var(--gutter) 280px; max-width: var(--max); margin: 0 auto; }
.closing p { color: var(--text-2); font-size: 18px; max-width: 46ch; }
.closing .closing-terrain { position: absolute; inset: auto 0 0 0; height: 300px; z-index: -1; pointer-events: none; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--stroke); padding: 48px 0 40px; font-size: 14px; color: var(--text-2); }
.footer-grid { display: grid; gap: 28px; padding-bottom: 28px; }
.footer-brand { display: grid; gap: 12px; max-width: 46ch; }
.footer-brand .brand { color: var(--text); }
.footer-links { display: grid; gap: 10px; align-content: start; }
.footer-links a { text-decoration: none; }
.footer-links a:hover { color: var(--text); }
.footer-fine { display: grid; gap: 10px; color: var(--text-3); font-size: 13px; }
.footer-fine a { color: inherit; }
@media (min-width: 760px) {
  .footer-grid { grid-template-columns: 1fr auto; }
  .footer-links { grid-template-columns: repeat(2, auto); column-gap: 40px; }
}

/* ---------- Documents (legal, support) ---------- */
.page { padding: 56px 0 96px; }
.prose { max-width: 760px; }
.prose h1 { font-family: var(--display); font-size: clamp(34px, 5vw, 50px); line-height: 1.06; letter-spacing: -0.03em; margin-bottom: 10px; }
.prose .updated { color: var(--text-3); margin-bottom: 36px; }
.prose h2 { font: 600 22px/1.3 var(--expanded); letter-spacing: -0.01em; margin: 48px 0 12px; }
.prose h3 { font: 600 17px/1.4 var(--sans); margin: 28px 0 6px; }
.prose p, .prose ul, .prose ol { color: var(--text-2); margin: 0 0 14px; }
.prose ul, .prose ol { padding-left: 22px; }
.prose li { margin: 6px 0; }
.prose strong { color: var(--text); font-weight: 600; }
.prose a { color: var(--accent-text); text-underline-offset: 3px; }
.summary-box, .steps, .contact-card { border-radius: var(--r-panel); background: var(--surface); border: 1px solid var(--stroke); padding: 24px 26px; margin: 0 0 20px; }
.summary-box ul, .steps ol { margin-bottom: 0; }
.contact-card { display: grid; gap: 16px; }
.contact-card p { margin: 4px 0 0; }
.contact-card .button { justify-self: start; }
@media (min-width: 720px) { .contact-card { grid-template-columns: 1fr auto; align-items: center; } }
.table-wrap { overflow-x: auto; margin: 8px 0 18px; border-radius: var(--r-tile); border: 1px solid var(--stroke); }
.prose table { width: 100%; border-collapse: collapse; font-size: 15px; }
.prose th, .prose td { text-align: left; vertical-align: top; padding: 12px 14px; border-bottom: 1px solid var(--stroke); color: var(--text-2); }
.prose th { background: var(--surface-muted); color: var(--text); font-weight: 600; }
.prose tr:last-child td { border-bottom: 0; }
.not-found { display: grid; gap: 18px; justify-items: start; padding: 40px 0 80px; }

/* ---------- Motion: reveal on scroll, only when motion is welcome ---------- */
@media (prefers-reduced-motion: no-preference) {
  .js .reveal { opacity: 0; transform: translateY(18px); transition: opacity 600ms var(--ease-out), transform 600ms var(--ease-out); transition-delay: calc(var(--i, 0) * 70ms); }
  .js .reveal.in { opacity: 1; transform: none; }
  .js .hero-copy > * { animation: rise 700ms var(--ease-out) both; animation-delay: calc(var(--i, 0) * 80ms + 60ms); }
  .js .hero .phone { animation: float-in 900ms var(--ease-out) 180ms both; }
}
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes float-in { from { opacity: 0; transform: translateY(28px) rotate(-2deg); } to { opacity: 1; transform: rotate(-2deg); } }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}

/* ---------------- Flag, hero proof and count-up ---------------- */
.flag { display: inline-block; vertical-align: -2px; border-radius: 3px; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.12); }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; }
.made { display: inline-flex; align-items: center; gap: 8px; color: var(--text-2); margin-right: 6px; }

.hero-float { position: absolute; z-index: 2; pointer-events: none; }
.hero-float.cert {
  width: clamp(140px, 17vw, 210px); aspect-ratio: 1.414; overflow: hidden; border-radius: 10px;
  left: 0; bottom: 14%; transform: rotate(-7deg); box-shadow: var(--phone-shadow);
}
.hero-float.cert img { width: 100%; height: auto; margin-top: -26.5%; display: block; }
.hero-float.chip {
  right: -10px; bottom: 30%; display: flex; align-items: center; gap: 8px; padding: 11px 16px 11px 12px;
  background: var(--success); color: #fff; border-radius: 999px; font: 600 15px/1 var(--sans);
  box-shadow: var(--phone-shadow); transform: rotate(4deg);
}
.hero-float.chip .icon { width: 18px; height: 18px; }
@media (prefers-reduced-motion: no-preference) {
  .js .hero-float.cert { animation: floatIn 0.9s var(--ease-out) 0.55s backwards; }
  .js .hero-float.chip { animation: floatIn 0.9s var(--ease-out) 0.75s backwards; }
  @keyframes floatIn { from { opacity: 0; translate: 0 26px; } to { opacity: 1; translate: 0 0; } }
}
@media (prefers-color-scheme: dark) { .hero-float.chip { color: #06140d; } }
@media (max-width: 959px) {
  .hero-float.cert { left: 2%; bottom: 8%; }
  .hero-float.chip { right: 2%; bottom: 34%; }
}

/* ---------------- More than a question bank ---------------- */
.trio { display: grid; gap: 20px; }
@media (min-width: 860px) { .trio { grid-template-columns: repeat(3, 1fr); } }
.trio-card { background: var(--surface); border-radius: var(--r-panel); padding: 22px 22px 26px; display: grid; gap: 12px; align-content: start; box-shadow: var(--shadow); min-width: 0; }
.trio-card .shot { aspect-ratio: 4 / 3.3; overflow: hidden; border-radius: 16px; background: var(--surface-muted); }
.trio-card .shot img { width: 100%; height: auto; display: block; }
.trio-card h3 { display: flex; align-items: center; gap: 10px; font: 600 18px/1.3 var(--expanded); }
.trio-card h3 .icon { width: 20px; height: 20px; color: var(--accent-text); flex: none; }
.trio-card p { color: var(--text-2); }

/* ---------------- Guides ---------------- */
.guide .crumbs { font-size: 14px; color: var(--text-3); margin-bottom: 14px; }
.guide .crumbs a { color: var(--text-2); text-decoration: none; }
.answer-box { background: var(--accent-soft); border-radius: var(--r-panel); padding: 18px 22px; margin: 8px 0 28px; }
.answer-box p { color: var(--text); margin: 0; font-size: 17px; line-height: 1.55; }
.guide .table-wrap { overflow-x: auto; margin: 0 0 18px; }
.guide table th[scope="row"] { color: var(--text); font-weight: 600; white-space: nowrap; }
.guide table.cheat th[scope="row"] { white-space: normal; min-width: 150px; }
.guide table .src { color: var(--text-3); font-size: 13px; min-width: 120px; }
.guide-cta { background: var(--surface); border-radius: var(--r-panel); padding: 22px; margin: 36px 0 22px; display: grid; gap: 14px; box-shadow: var(--shadow); }
.guide-cta p { margin: 0; }
.guide .fine, .guide .sources { font-size: 14px; color: var(--text-3); }

.practice { display: grid; gap: 18px; }
.pq { background: var(--surface); border-radius: var(--r-panel); padding: 20px 22px; box-shadow: var(--shadow); }
.pq-meta { font: 600 13px/1.2 var(--expanded); color: var(--accent-text) !important; margin: 0 0 8px !important; }
.prose .pq-stem { font: 600 19px/1.4 var(--sans); margin: 0 0 14px; letter-spacing: -0.01em; color: var(--text); }
.pq-choices { list-style: none; padding: 0 !important; display: grid; gap: 8px; margin: 0 0 12px !important; }
.pq-choices li { display: flex; gap: 12px; align-items: baseline; padding: 10px 14px; border: 1.5px solid var(--stroke); border-radius: var(--r-input); color: var(--text) !important; margin: 0 !important; }
.pq-key { font: 600 13px/1 var(--expanded); color: var(--text-3); }
.pq-answer summary { cursor: pointer; font-weight: 600; color: var(--accent-text); list-style: none; }
.pq-answer summary::-webkit-details-marker { display: none; }
.pq-answer[open] summary { margin-bottom: 10px; }
.pq-correct strong { color: var(--success) !important; }
.pq-source { font-size: 14px; color: var(--text-3) !important; }

.steps-list { counter-reset: step; list-style: none; padding: 0 !important; display: grid; gap: 4px; }
.steps-list li { counter-increment: step; position: relative; padding: 0 0 22px 52px; margin: 0 !important; }
.steps-list li::before {
  content: counter(step); position: absolute; left: 0; top: 2px; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; background: var(--inverse); color: var(--on-inverse); font: 600 15px/1 var(--expanded);
}
.steps-list li:nth-child(4)::before { background: var(--accent); color: var(--on-accent); }
.steps-list li:not(:last-child)::after { content: ''; position: absolute; left: 16px; top: 42px; bottom: 6px; width: 2px; background: var(--stroke-strong); }
.prose .steps-list h2 { margin: 6px 0 6px; font-size: 19px; }
