/* Suricode v2 home. Light paper, ink type, pen doodles, dark code windows.
   Bricolage Grotesque (Mathieu Triay) and Caveat (Impallari Type) are used
   under the SIL Open Font License and served from this site.
   The app's own colours (the brand orange, the status tones) appear only
   where the page shows the app or its findings. */

@font-face {
  font-family: "Bricolage Grotesque";
  src: url("/static/v2/bricolage-latin.woff2") format("woff2");
  font-weight: 200 800;
  font-stretch: 75% 100%;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: Caveat;
  src: url("/static/v2/caveat-latin.woff2") format("woff2");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  --display: "Bricolage Grotesque", "Avenir Next", system-ui, sans-serif;
  --ui: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  --hand: Caveat, "Bradley Hand", "Segoe Print", cursive;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --paper: #fbfaf7;
  --paper-2: #f3f1ea;
  --card: #ffffff;
  --ink: #141416;
  --ink-2: #2a2a30;
  --muted: #5d5d66;
  --faint: #8b8b94;
  --line: #e7e4dc;
  --line-strong: #d6d2c6;
  --pen: #3550ff;
  --pen-soft: #e8ecff;
  --marker: #ffe58a;

  /* From the app, used sparingly. */
  --app-accent: #ee8105;
  --app-accent-quiet: #ffedd5;
  --tone-red-bg: #ffe4e6;
  --tone-red-fg: #9f1239;
  --tone-orange-bg: #ffedd5;
  --tone-orange-fg: #9a3412;
  --tone-amber-bg: #fef3c7;
  --tone-amber-fg: #92400e;
  --tone-sky-bg: #e0f2fe;
  --tone-sky-fg: #075985;

  --code-bg: #111114;
  --code-bar: #18181c;
  --code-line: #26262c;
  --code-text: #d7d7de;
  --code-dim: #7c7c88;

  --gutter: 16px;
  --radius: 18px;
  --radius-small: 10px;
  --shadow: 0 1px 2px rgba(20, 20, 22, 0.04), 0 10px 30px rgba(20, 20, 22, 0.06);
  --shadow-lift: 0 2px 4px rgba(20, 20, 22, 0.05), 0 30px 60px -20px rgba(20, 20, 22, 0.22);
  --mark-hole: var(--paper);
}

*, *::before, *::after { box-sizing: border-box; }

html {
  background: var(--paper);
  color: var(--ink);
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 84px;
  overflow-x: clip;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--ui);
  font-size: 1rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { margin: 0; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
a { color: inherit; }
code, pre { font-family: var(--mono); }
img, svg { display: block; }

:focus-visible { outline: 2px solid var(--pen); outline-offset: 3px; border-radius: 6px; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip {
  position: absolute; left: var(--gutter); top: -60px; z-index: 50;
  background: var(--ink); color: var(--paper); padding: 8px 14px; border-radius: 999px;
  text-decoration: none;
}
.skip:focus { top: 12px; }

.wrap { width: 100%; max-width: 1160px; margin: 0 auto; padding-inline: var(--gutter); }

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

/* Type */

.headline {
  font-family: var(--display);
  font-weight: 700;
  font-stretch: 92%;
  letter-spacing: -0.035em;
  line-height: 1.02;
  font-size: clamp(2.1rem, 7vw, 3.6rem);
  text-wrap: balance;
}
h1.headline { font-size: clamp(2.7rem, 10.5vw, 5.75rem); letter-spacing: -0.045em; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 14px;
}
.eyebrow::before {
  content: "";
  width: 18px; height: 2px; border-radius: 2px;
  background: var(--pen);
}

.lede { color: var(--muted); font-size: 1.075rem; line-height: 1.6; max-width: 40rem; margin-top: 18px; text-wrap: pretty; }
@media (min-width: 720px) { .lede { font-size: 1.2rem; } }

.note {
  font-family: var(--hand);
  font-weight: 600;
  font-size: 1.45rem;
  line-height: 1.05;
  color: var(--pen);
}

.hl {
  background: linear-gradient(transparent 58%, var(--marker) 58%, var(--marker) 92%, transparent 92%);
  padding: 0 0.08em;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

.mark-word, .circled { position: relative; display: inline-block; white-space: nowrap; }
.mark-word .doodle-underline {
  position: absolute; left: -2%; bottom: -0.18em; width: 104%; height: 0.32em;
  color: var(--pen); stroke-width: 3;
  overflow: visible;
}
.circled .doodle-circle {
  position: absolute; left: -6%; top: -24%; width: 116%; height: 150%;
  color: var(--pen); stroke-width: 2;
  overflow: visible; pointer-events: none;
}

.label {
  font-size: 0.78rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--faint); margin-bottom: 10px;
}

/* Pen strokes draw in once they come into view. */
.pen .doodle .draw { stroke-dasharray: var(--len); stroke-dashoffset: var(--len); transition: stroke-dashoffset 1.1s cubic-bezier(.6, .1, .3, 1); }
.pen .doodle.drawn .draw { stroke-dashoffset: 0; }
.pen .doodle.drawn .draw:nth-child(2) { transition-delay: .35s; }
.pen .doodle.drawn .draw:nth-child(n+3) { transition-delay: .55s; }

/* Buttons */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 42px; padding: 0 18px;
  border-radius: 999px; border: 1px solid transparent;
  font: 600 0.95rem/1 var(--ui);
  text-decoration: none; white-space: nowrap;
  transition: transform .15s ease, background .15s ease, box-shadow .15s ease;
}
.btn-large { min-height: 52px; padding: 0 26px; font-size: 1rem; }
.btn-ink { background: var(--ink); color: #fff; box-shadow: 0 1px 0 rgba(255,255,255,.15) inset, 0 6px 16px -6px rgba(20,20,22,.5); }
.btn-ink:hover { background: #000; transform: translateY(-1px); }
.btn-line { background: var(--card); color: var(--ink); border-color: var(--line-strong); }
.btn-line:hover { border-color: var(--ink); }
.text-link { color: var(--ink); font-weight: 600; text-underline-offset: 4px; }

/* Header */

.top {
  position: sticky; top: 0; z-index: 20;
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent;
}
.top-row { display: flex; align-items: center; gap: 16px; min-height: 64px; }

.wordmark {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--display); font-weight: 700; font-size: 1.2rem; letter-spacing: -0.03em;
  text-decoration: none; color: var(--ink);
}
.wordmark .mark {
  width: 28px;
  height: 28px;
  display: block;
  flex: none;
  object-fit: contain;
}

.top-nav { display: none; }
.top-nav a, .menu-panel a { text-decoration: none; color: var(--muted); font-weight: 500; font-size: 0.95rem; }
.top-nav a:hover { color: var(--ink); }

.top-actions { margin-left: auto; display: flex; align-items: center; gap: 14px; }
.top-actions .btn { min-height: 38px; padding: 0 14px; font-size: 0.875rem; }
.theme-toggle {
  display: grid; place-items: center;
  width: 40px; height: 40px; flex: 0 0 auto;
  border-radius: 999px; border: 1px solid var(--line-strong);
  color: var(--ink); text-decoration: none; background: var(--card);
}
.theme-toggle:hover { border-color: var(--ink); }
.sign-in { display: none; text-decoration: none; font-weight: 600; font-size: 0.95rem; }

.menu { position: relative; }
.menu summary {
  list-style: none; cursor: pointer;
  width: 40px; height: 40px; border-radius: 999px; border: 1px solid var(--line-strong);
  display: grid; place-content: center; gap: 5px; background: var(--card);
}
.menu summary::-webkit-details-marker { display: none; }
.menu summary span { width: 16px; height: 2px; border-radius: 2px; background: var(--ink); transition: transform .2s ease; }
.menu[open] summary span:first-child { transform: translateY(3.5px) rotate(45deg); }
.menu[open] summary span:last-child { transform: translateY(-3.5px) rotate(-45deg); }
.menu-panel {
  position: absolute; right: 0; top: calc(100% + 10px);
  width: min(78vw, 280px);
  display: grid; padding: 8px;
  background: var(--card); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow-lift);
}
.menu-panel a { padding: 12px 14px; border-radius: 10px; color: var(--ink); }
.menu-panel a:hover { background: var(--paper-2); }

@media (min-width: 560px) { .sign-in { display: inline; } }
@media (min-width: 960px) {
  .top-nav { display: flex; gap: 26px; margin-left: 28px; }
  .menu { display: none; }
}

/* Hero */

.hero { position: relative; padding: 44px 0 40px; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background-image: radial-gradient(var(--line-strong) 1px, transparent 1px);
  background-size: 22px 22px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 20%, transparent 75%);
  opacity: .7;
}
.hero-inner { position: relative; text-align: center; display: flex; flex-direction: column; align-items: center; }
.hero .lede { margin-inline: auto; }

.badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 14px 6px 10px; margin-bottom: 22px;
  border: 1px solid var(--line); border-radius: 999px; background: var(--card);
  font-size: 0.85rem; font-weight: 500; color: var(--muted);
  box-shadow: var(--shadow);
}
.badge-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--app-accent); box-shadow: 0 0 0 4px var(--app-accent-quiet); }

.actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 12px; margin-top: 30px; }
.hero .actions { flex-direction: column; width: 100%; }
.hero .actions .btn { width: 100%; max-width: 340px; }

.hero-note { display: inline-flex; align-items: center; gap: 4px; }
.hero-note .doodle { display: none; width: 54px; height: 32px; color: var(--pen); }

.proof {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 20px;
  margin-top: 28px; font-size: 0.9rem; color: var(--muted);
}
.proof li { display: inline-block; }
.proof li::before {
  content: ""; display: inline-block; vertical-align: middle; width: 14px; height: 8px; margin: -6px 10px 0 0;
  border-left: 2px solid var(--app-accent); border-bottom: 2px solid var(--app-accent);
  transform: rotate(-45deg);
}
.proof b { color: var(--ink); font-weight: 600; }

.hero-meerkat, .hero-spark { display: none; }

@media (min-width: 640px) {
  .hero { padding: 72px 0 56px; }
  .hero .actions { flex-direction: row; width: auto; }
  .hero .actions .btn { width: auto; }
}

@media (min-width: 1000px) {
  .hero { padding: 96px 0 64px; }
  .hero-note { position: absolute; left: calc(50% + 250px); margin-top: 26px; flex-direction: column-reverse; align-items: flex-start; }
  .hero-note .note { transform: rotate(-4deg); }
  .hero-note .doodle { display: block; transform: rotate(160deg) scaleY(-1); width: 70px; height: 40px; margin-left: -30px; }
  .hero-meerkat {
    display: block; position: absolute; left: 2%; bottom: -10px;
    width: 110px; transform: rotate(-4deg);
  }
  .hero-meerkat .doodle-meerkat { width: 110px; height: auto; display: block; }
  .hero-spark { display: block; position: absolute; right: 8%; top: 10px; width: 36px; color: var(--pen); }
}

/* Ticker */

.ticker {
  display: flex; overflow: hidden; gap: 0;
  border-block: 1px solid var(--line);
  background: var(--card);
  mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}
.ticker ul { display: flex; flex: none; gap: 40px; padding: 14px 20px; animation: tick 38s linear infinite; }
.ticker li {
  display: inline-flex; align-items: center; gap: 40px; white-space: nowrap;
  font-family: var(--display); font-weight: 600; font-size: 1rem; color: var(--muted);
}
.ticker li::after { content: "✳"; color: var(--pen); font-size: .8rem; }
@keyframes tick { to { transform: translateX(-100%); } }

/* Tour video */

.tour { padding: 56px 0 8px; }
.tour-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 16px; margin-bottom: 24px; }
.tour .headline { font-size: clamp(1.7rem, 5vw, 2.6rem); }
.note-tour { transform: rotate(-4deg); }
.tour-frame { margin: 0; }
.tour-frame video {
  display: block; width: 100%; height: auto; aspect-ratio: 16 / 9;
  border-radius: 16px; background: #0a0a0c;
  box-shadow: var(--shadow-lift), 0 0 0 1px var(--line);
}
.tour-frame figcaption { margin-top: 14px; text-align: center; color: var(--faint); font-size: 0.9rem; }
@media (min-width: 1100px) { .tour .wrap { max-width: 1020px; } }

/* App preview: the same Home still as the dark marketing page, in light. */

.example { padding: 56px 0 24px; }
.preview { margin: 0; }
.preview-stage { position: relative; }
.preview .note, .preview-arrow { display: none; }
.preview .shot-frame figcaption {
  margin-top: 16px; text-align: center; color: var(--faint); font-size: 0.9rem;
  max-width: none;
}

.pill {
  display: inline-flex; align-items: center; flex: none;
  padding: 3px 10px; border-radius: 999px;
  font-size: 0.75rem; font-weight: 600; line-height: 1.4;
}
.pill-orange { background: var(--tone-orange-bg); color: var(--tone-orange-fg); }
.pill-plain { background: #f4f4f5; color: #3f3f46; }

@media (min-width: 1100px) {
  .example { padding-top: 72px; }
  .preview-stage { margin-inline: 48px; }
  .preview .note, .preview-arrow { display: block; position: absolute; }
  .note-score { left: -64px; top: -46px; transform: rotate(-6deg); }
  .preview-arrow-score { left: -40px; top: 8px; width: 52px; color: var(--pen); }
  .preview-arrow-score .doodle { width: 52px; height: 64px; }
  .note-list { right: -78px; bottom: 28%; width: 120px; text-align: center; transform: rotate(5deg); }
  .preview-arrow-list { right: -46px; bottom: 22%; color: var(--pen); }
  .preview-arrow-list .doodle { width: 90px; height: 50px; }
}

/* Sections */

section.plain, section.finds, section.how, section.agent, section.patch, section.savings, section.faq { padding: 72px 0; }
@media (min-width: 960px) {
  section.plain, section.finds, section.how, section.agent, section.patch, section.savings, section.faq { padding: 112px 0; }
}
.section-head { max-width: 46rem; }

/* Plain words */

.plain-grid { display: grid; gap: 18px; margin-top: 40px; align-items: center; }
.plain-grid > *, .agent-grid > *, .patch-grid > *, .faq-grid > * { min-width: 0; }
.term {
  margin: 0; padding: 18px; border-radius: var(--radius-small);
  background: var(--code-bg); color: var(--code-dim);
  font-size: 0.8rem; line-height: 1.8;
  overflow-x: auto;
}
.plain-turn { display: flex; align-items: center; justify-content: center; gap: 4px; color: var(--pen); }
.plain-turn .doodle { width: 70px; height: 36px; transform: rotate(90deg); }
.fix {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px; box-shadow: var(--shadow);
  border-left: 4px solid var(--tone-orange-fg);
}
.fix-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.fix h3 { font-family: var(--display); font-size: 1.25rem; letter-spacing: -0.02em; line-height: 1.2; }
.fix p { color: var(--muted); margin-top: 8px; }
.fix-file { font-size: 0.85rem; }
.fix-file code { color: var(--ink); background: var(--paper-2); padding: 2px 6px; border-radius: 6px; }

@media (min-width: 900px) {
  .plain-grid { grid-template-columns: 1fr 120px 1fr; gap: 12px; }
  .plain-turn { flex-direction: column-reverse; padding-top: 30px; }
  .plain-turn .doodle { width: 110px; height: 56px; transform: none; }
}

/* Risks */

.finds { background: var(--card); border-block: 1px solid var(--line); }
.risks { display: grid; gap: 14px; margin-top: 44px; }
.risk {
  position: relative;
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px;
  transition: transform .2s ease, box-shadow .2s ease;
}
.risk:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.risk-art {
  display: grid; place-items: center;
  width: 64px; height: 64px; margin-bottom: 18px;
  border-radius: 20px 26px 18px 24px;
  background: var(--tone-bg); color: var(--tone-fg);
}
.risk-art .doodle { width: 42px; height: 42px; }
.risk h3 { font-family: var(--display); font-size: 1.3rem; letter-spacing: -0.02em; }
.risk p { margin-top: 6px; color: var(--muted); font-size: 0.95rem; }
.tone-red { --tone-bg: var(--tone-red-bg); --tone-fg: var(--tone-red-fg); }
.tone-orange { --tone-bg: var(--tone-orange-bg); --tone-fg: var(--tone-orange-fg); }
.tone-amber { --tone-bg: var(--tone-amber-bg); --tone-fg: var(--tone-amber-fg); }
.tone-sky { --tone-bg: var(--tone-sky-bg); --tone-fg: var(--tone-sky-fg); }

@media (min-width: 640px) { .risks { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .risks { grid-template-columns: repeat(4, 1fr); } }

/* Steps */

.steps { display: grid; gap: 14px; margin-top: 44px; counter-reset: step; }
.step {
  position: relative;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; box-shadow: var(--shadow);
}
.step-art { display: block; width: 56px; height: 56px; color: var(--pen); margin-bottom: 14px; }
.step-art .doodle { width: 56px; height: 56px; }
.step-num { font-family: var(--hand); font-size: 1.4rem; color: var(--pen); line-height: 1; }
.step h3 { font-family: var(--display); font-size: 1.5rem; letter-spacing: -0.025em; margin-top: 4px; }
.step p:last-child { margin-top: 8px; color: var(--muted); }

.flow {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 4px 6px;
  margin-top: 32px; font-family: var(--hand); font-size: 1.4rem; color: var(--ink-2);
}
.flow span { padding: 2px 10px; }
.flow .doodle { width: 44px; height: 22px; color: var(--pen); }

@media (min-width: 760px) {
  .steps { grid-template-columns: 1fr 1fr; gap: 20px; }
  .step { padding: 32px; }
  .flow { font-size: 1.6rem; gap: 6px 10px; }
  .flow .doodle { width: 64px; height: 32px; }
}

/* Agent */

.agent { background: var(--paper-2); }
.agent-grid { display: grid; gap: 40px; align-items: center; }
.tools { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 26px; }
.tools a {
  display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px;
  background: var(--card); border: 1px solid var(--line-strong); border-radius: 999px;
  text-decoration: none; font-weight: 600; font-size: 0.92rem;
  transition: border-color .15s ease, transform .15s ease;
}
.tools a:hover { border-color: var(--ink); transform: translateY(-1px); }
.note-tools { margin-top: 12px; transform: rotate(-2deg); transform-origin: left; }

@media (min-width: 980px) { .agent-grid { grid-template-columns: 0.85fr 1.15fr; gap: 56px; } }

/* Code window */

.code-window {
  margin: 0; min-width: 0;
  border-radius: 16px; overflow: hidden;
  background: var(--code-bg); color: var(--code-text);
  box-shadow: var(--shadow-lift), 0 0 0 1px rgba(20,20,22,.9);
}
.code-bar {
  display: flex; align-items: center; gap: 12px;
  padding: 0 10px 0 14px; background: var(--code-bar); border-bottom: 1px solid var(--code-line);
}
.code-lights { display: none; gap: 6px; }
.code-lights i { width: 10px; height: 10px; border-radius: 50%; background: #3a3a42; }
.code-tabs { display: flex; overflow-x: auto; scrollbar-width: none; min-width: 0; flex: 1; }
.code-tabs::-webkit-scrollbar { display: none; }
.code-tabs button {
  flex: none; appearance: none; border: 0; background: none; cursor: pointer;
  font: 500 0.8rem var(--mono); color: var(--code-dim);
  padding: 14px 12px 12px; border-bottom: 2px solid transparent;
}
.code-tabs button:hover { color: var(--code-text); }
.code-tabs button[aria-selected="true"] { color: #fff; border-bottom-color: #fff; }
.code-copy {
  flex: none; appearance: none; cursor: pointer;
  border: 1px solid var(--code-line); background: transparent; color: var(--code-dim);
  font: 500 0.75rem var(--ui); padding: 5px 10px; border-radius: 8px;
}
.code-copy:hover { color: #fff; border-color: #44444c; }
.code-panel { padding: 18px 0 20px; }
.code-panel:focus-visible { outline-offset: -3px; }
.code-caption { padding: 0 18px 12px; font-size: 0.8rem; color: var(--code-dim); font-family: var(--ui); }
.code-panel pre { margin: 0; overflow-x: auto; font-size: 0.8rem; line-height: 1.75; counter-reset: line; }
.code-panel code { display: block; min-width: max-content; padding-right: 18px; }
.code-line { display: block; padding-left: 18px; }
.code-wrap code { min-width: 0; }
.code-wrap .code-line { white-space: pre-wrap; padding-left: calc(18px + 2ch + 16px); text-indent: calc(-2ch - 16px); }
.code-line::before {
  counter-increment: line; content: counter(line);
  display: inline-block; width: 2ch; margin-right: 16px; text-align: right;
  color: #45454e; user-select: none; -webkit-user-select: none;
}
.code-note { padding: 0 18px 16px; font-size: 0.8rem; color: var(--code-dim); }
.tok-key { color: #9cc4ff; }
.tok-str { color: #b9e28c; }
.tok-num { color: #f5b38a; }
.tok-word { color: #d4a5f5; }
.tok-comment { color: #6c6c78; font-style: italic; }
.tok-cmd { color: #fff; font-weight: 600; }
.tok-flag { color: #9cc4ff; }
.tok-env { color: #f5b38a; }

@media (min-width: 720px) {
  .code-lights { display: inline-flex; }
  .code-panel pre { font-size: 0.85rem; }
}

/* Patched packages */

.patch-grid { display: grid; gap: 20px; margin-top: 44px; align-items: start; }
.patch-compare { display: grid; gap: 14px; }
.patch-card {
  position: relative;
  background: var(--card); border: 1px dashed var(--line-strong); border-radius: var(--radius);
  padding: 22px;
}
.patch-card h3 { font-family: var(--display); font-size: 1.3rem; letter-spacing: -0.02em; }
.patch-card p:last-of-type { margin-top: 6px; color: var(--muted); }
.patch-card:not(.patch-card-on) h3 { text-decoration: line-through; text-decoration-color: var(--tone-red-fg); text-decoration-thickness: 2px; }
.patch-card-on { border: 1px solid var(--line); box-shadow: var(--shadow); background: linear-gradient(180deg, var(--app-accent-quiet), var(--card) 60%); }
.patch-card-on .label { color: var(--app-accent); }
.patch-shield { position: absolute; right: 16px; top: 14px; width: 44px; color: var(--app-accent); }
.patch-shield .doodle { width: 44px; height: 44px; }

.points { display: grid; gap: 20px; margin-top: 40px; }
.points li { padding-top: 16px; border-top: 2px solid var(--ink); }
.points h3 { font-family: var(--display); font-size: 1.15rem; letter-spacing: -0.02em; }
.points p { color: var(--muted); margin-top: 4px; font-size: 0.95rem; }

@media (min-width: 720px) { .points { grid-template-columns: repeat(3, 1fr); gap: 28px; } }
@media (min-width: 1000px) { .patch-grid { grid-template-columns: 0.9fr 1.1fr; gap: 28px; } }

/* Savings */

.savings { background: var(--card); border-block: 1px solid var(--line); }
.savings-grid { display: grid; gap: 14px; margin-top: 44px; }
.saving { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.saving-art { display: block; width: 52px; height: 52px; color: var(--pen); margin-bottom: 14px; }
.saving-art .doodle { width: 52px; height: 52px; }
.saving h3 { font-family: var(--display); font-size: 1.5rem; letter-spacing: -0.025em; }
.saving p { color: var(--muted); margin-top: 8px; }
@media (min-width: 720px) { .savings-grid { grid-template-columns: 1fr 1fr; gap: 20px; } }

/* FAQ */

.faq-grid { display: grid; gap: 32px; }
.note-faq { margin-top: 18px; transform: rotate(-3deg); transform-origin: left; }
.faq-list { display: grid; border-top: 1px solid var(--line-strong); }
.qa { border-bottom: 1px solid var(--line-strong); }
.qa summary {
  list-style: none; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 20px 0;
  font-family: var(--display); font-weight: 600; font-size: 1.1rem; letter-spacing: -0.015em; line-height: 1.3;
}
.qa summary::-webkit-details-marker { display: none; }
.qa summary i {
  position: relative; flex: none; width: 28px; height: 28px; border-radius: 50%;
  border: 1px solid var(--line-strong); background: var(--card);
}
.qa summary i::before, .qa summary i::after {
  content: ""; position: absolute; left: 50%; top: 50%; width: 10px; height: 2px; margin: -1px 0 0 -5px;
  background: var(--ink); border-radius: 2px; transition: transform .2s ease;
}
.qa summary i::after { transform: rotate(90deg); }
.qa[open] summary i::after { transform: rotate(0deg); }
.qa summary:hover i { border-color: var(--ink); }
.qa-body { padding: 0 44px 22px 0; color: var(--muted); }
.qa-body ul { display: grid; gap: 6px; }
.qa-body li { position: relative; padding-left: 20px; }
.qa-body li::before { content: "–"; position: absolute; left: 0; color: var(--pen); font-weight: 700; }

@media (min-width: 960px) {
  .faq-grid { grid-template-columns: 0.8fr 1.2fr; gap: 64px; }
  .faq-side { position: sticky; top: 110px; align-self: start; }
}

/* Close */

.close { padding: 24px 0 88px; }
.close-card {
  position: relative; overflow: hidden; text-align: center;
  padding: 56px 20px 48px; border-radius: 28px;
  background: var(--ink); color: #fff;
}
.close-card::before {
  content: ""; position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255,255,255,.12) 1px, transparent 1px);
  background-size: 22px 22px;
  mask-image: radial-gradient(ellipse 60% 70% at 50% 40%, #000, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse 60% 70% at 50% 40%, #000, transparent 80%);
}
.close-card > * { position: relative; }
.close-card .lede { color: #b4b4bd; margin-inline: auto; }
.close-card .mark-word .doodle-underline { color: var(--marker); }
.close-card .btn-ink { background: #fff; color: var(--ink); }
.close-card .btn-ink:hover { background: var(--marker); }
.close-card .text-link { color: #fff; }
.close-meerkat { display: block; width: 72px; margin: 0 auto 18px; }
.close-meerkat .doodle-meerkat {
  width: 72px;
  height: auto;
  display: block;
  background: #fbfaf7;
  border-radius: 18px;
  padding: 6px;
  box-sizing: border-box;
}
@media (min-width: 720px) {
  .close-card { padding: 88px 40px 80px; }
  .close-meerkat { position: absolute; left: 6%; bottom: 16px; width: 108px; margin: 0; }
  .close-meerkat .doodle-meerkat { width: 108px; }
}

/* Footer */

.foot { border-top: 1px solid var(--line); padding: 40px 0 48px; }
.foot-primary {
  display: grid;
  grid-template-columns: 1fr;
  justify-items: start;
  align-items: center;
  gap: 16px 28px;
}
.foot .wordmark { text-transform: uppercase; }
.foot-tag { margin: 0; justify-self: start; text-align: left; color: var(--muted); font-size: 0.9rem; }
.foot-nav { display: flex; flex-wrap: wrap; justify-content: flex-start; gap: 10px 22px; font-size: 0.92rem; }
.foot-nav a { color: var(--muted); text-decoration: none; }
.foot-nav a:hover { color: var(--ink); }
.foot-resources {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid rgba(20, 20, 22, 0.12);
}
.foot-resources-label {
  margin: 0 0 14px;
  color: #71717a;
  font-size: 0.75rem;
  font-weight: 650;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.foot-guides {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 22px;
}
.foot-guides a { color: #71717a; font-size: 0.75rem; font-weight: 500; line-height: 1.4; text-decoration: none; }
.foot-guides a:hover { color: #3f3f46; }
@media (min-width: 861px) {
  .foot-primary { grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); }
  .foot-nav { justify-content: center; }
  .foot-tag { justify-self: end; text-align: right; }
  .foot-guides { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .ticker ul { animation: none; }
  .risk, .btn, .tools a { transition: none; }
}
