/* ==========================================================================
   Biolink Brain Training — site styles
   Visual language: taken from the Biolink robot mascot. Rounded type, the
   mascot's cyan + pink, the original brand yellow, ink outlines and "sticker"
   cards, hand-written notes, speech bubbles, sticky notes and wavy edges.
   ========================================================================== */

:root {
  /* Ink — the mascot's outline colour, used for text, borders and hard shadows */
  --ink: #0b3d4e;
  --ink-soft: #3f5f6b;
  --ink-mute: #6a8490;
  --brand: #034a5e;        /* logo square */

  /* Play colours (strong) + tints */
  --sky: #4fcfe3;   --sky-100: #dcf5fa;
  --sun: #ffcb05;   --sun-100: #fff2bf;
  --pink: #ff5c9d;  --pink-100: #ffe1ed;
  --mint: #62d09a;  --mint-100: #dcf4e7;
  --tang: #ff9150;  --tang-100: #ffe5d4;

  --cream: #fff8ec;
  --paper: #ffffff;

  /* Page accent (overridden per page by .theme-*) */
  --accent: var(--sun);
  --accent-100: var(--sun-100);

  --font-display: "Fredoka", "Baloo 2", "Trebuchet MS", system-ui, sans-serif;
  --font-body: "Lexend", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-hand: "Patrick Hand", "Comic Neue", "Segoe Print", cursive;

  --step--1: clamp(.86rem, .83rem + .15vw, .94rem);
  --step-0: clamp(1rem, .97rem + .2vw, 1.09rem);
  --step-1: clamp(1.15rem, 1.08rem + .35vw, 1.32rem);
  --step-2: clamp(1.4rem, 1.25rem + .7vw, 1.8rem);
  --step-3: clamp(1.8rem, 1.5rem + 1.4vw, 2.6rem);
  --step-4: clamp(2.2rem, 1.7rem + 2.4vw, 3.5rem);
  --step-5: clamp(2.6rem, 1.9rem + 3.4vw, 4.6rem);

  --gutter: clamp(1rem, .6rem + 2vw, 2rem);
  --section: clamp(4rem, 3rem + 5vw, 7rem);
  --max: 1200px;
  --header-h: 78px;

  --bw: 2.5px;                      /* border width */
  --border: var(--bw) solid var(--ink);
  --r-sm: 12px;
  --r: 22px;
  --r-lg: 32px;
  --pop: 5px 5px 0 var(--ink);      /* hard "sticker" shadow */
  --pop-sm: 3px 3px 0 var(--ink);
  --ease: cubic-bezier(.34, 1.4, .64, 1);   /* slightly bouncy */
}

.theme-sun  { --accent: var(--sun);  --accent-100: var(--sun-100); }
.theme-sky  { --accent: var(--sky);  --accent-100: var(--sky-100); }
.theme-pink { --accent: var(--pink); --accent-100: var(--pink-100); }
.theme-mint { --accent: var(--mint); --accent-100: var(--mint-100); }
.theme-tang { --accent: var(--tang); --accent-100: var(--tang-100); }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
body {
  margin: 0; font-family: var(--font-body); font-size: var(--step-0); line-height: 1.7; font-weight: 400;
  color: var(--ink); background: var(--cream); -webkit-font-smoothing: antialiased;
}
img, svg, video { display: block; max-width: 100%; height: auto; }
a { color: var(--ink); text-decoration-color: var(--pink); text-decoration-thickness: 2px; text-underline-offset: 4px; }
a:hover { text-decoration-style: wavy; }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 600; line-height: 1.08; letter-spacing: -.01em; margin: 0 0 .5em; color: var(--ink); text-wrap: balance; }
h1 { font-size: var(--step-5); font-weight: 700; }
h2 { font-size: var(--step-4); }
h3 { font-size: var(--step-1); line-height: 1.2; }
p { margin: 0 0 1em; text-wrap: pretty; }
strong { font-weight: 600; }
:focus-visible { outline: 3px solid var(--pink); outline-offset: 3px; border-radius: 8px; }
::selection { background: var(--sun); color: var(--ink); }

/* Highlighter-pen emphasis (from *text* in content) */
mark {
  color: inherit; padding: 0 .12em; margin: 0 -.04em; border-radius: .2em;
  background: linear-gradient(100deg, transparent .1em, var(--hl, var(--accent)) .1em, var(--hl, var(--accent)) calc(100% - .15em), transparent calc(100% - .15em)) 0 72% / 100% 42% no-repeat;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
.section--ink mark { background: none; color: var(--sun); padding: 0; margin: 0; }
.hand { font-family: var(--font-hand); font-weight: 400; letter-spacing: 0; }

.skip-link { position: absolute; left: 1rem; top: -100px; z-index: 100; background: var(--sun); color: var(--ink); padding: .7rem 1rem; border: var(--border); border-radius: var(--r-sm); font-weight: 600; }
.skip-link:focus { top: 1rem; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.narrow { max-width: 780px; }
.section { padding-block: var(--section); position: relative; }
.section--tight { padding-block: calc(var(--section) * .55); }
.section--paper { background: var(--paper); }
.section--tint { background: var(--accent-100); }
.section--sky { background: var(--sky-100); }
.section--sun { background: var(--sun-100); }
.section--pink { background: var(--pink-100); }
.section--mint { background: var(--mint-100); }
.section--ink { background: var(--ink); color: #d5e8ee; }
.section--ink h2, .section--ink h3 { color: #fff; }
.section--ink a:not(.btn) { color: #fff; }

/* Wavy top edge: the section paints a wave over the one above it */
.wave::before {
  content: ""; position: absolute; left: 0; right: 0; top: -21px; height: 22px; background: inherit; pointer-events: none;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 22' preserveAspectRatio='none'%3E%3Cpath d='M0 22V11C15 11 15 1 30 1s15 10 30 10 15-10 30-10 15 10 30 10v11z'/%3E%3C/svg%3E") 0 0 / 120px 22px repeat-x;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 22' preserveAspectRatio='none'%3E%3Cpath d='M0 22V11C15 11 15 1 30 1s15 10 30 10 15-10 30-10 15 10 30 10v11z'/%3E%3C/svg%3E") 0 0 / 120px 22px repeat-x;
}

.grid { display: grid; gap: clamp(1.1rem, .7rem + 1.2vw, 1.75rem); }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 400px), 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 290px), 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); }
.split { display: grid; gap: clamp(2rem, 1rem + 4vw, 5rem); align-items: center; }
@media (min-width: 900px) { .split { grid-template-columns: 1fr 1fr; } .split--top { align-items: start; } }

/* Section heading with a hand-written note in place of an eyebrow */
.section-head { max-width: 760px; margin-bottom: clamp(2rem, 1.5rem + 2vw, 3.25rem); position: relative; }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head > p:not(.scribble) { font-size: var(--step-1); color: var(--ink-soft); }
.section--ink .section-head > p:not(.scribble) { color: #a9c9d2; }
.scribble {
  display: inline-flex; align-items: flex-end; gap: .35rem; margin: 0 0 .6rem;
  font-family: var(--font-hand); font-size: clamp(1.25rem, 1.1rem + .5vw, 1.5rem); line-height: 1; color: #d6246e;
  transform: rotate(-2.5deg); transform-origin: left bottom;
}
.scribble svg { width: 38px; height: 30px; flex: none; margin-bottom: -.6rem; }
.section--ink .scribble { color: var(--sun); }
.section-head--center .scribble { transform-origin: center; }

/* ---------- Buttons: chunky, press-able ---------- */
.btn {
  --bg: var(--sun); --fg: var(--ink);
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
  min-height: 52px; padding: .7rem 1.4rem .75rem;
  font: 600 1.08rem/1.1 var(--font-display); letter-spacing: .005em;
  color: var(--fg); background: var(--bg); border: var(--border); border-radius: 16px;
  box-shadow: 0 4px 0 var(--ink); text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: transform .15s var(--ease), box-shadow .15s var(--ease), background-color .15s;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 6px 0 var(--ink); color: var(--fg); text-decoration: none; }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--ink); }
.btn svg { width: 20px; height: 20px; flex: none; stroke-width: 2.6; }
.btn--pink { --bg: var(--pink); }
.btn--sky { --bg: var(--sky); }
.btn--white { --bg: var(--paper); }
.btn--sm { min-height: 44px; padding: .5rem 1rem .55rem; font-size: 1rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: .9rem; align-items: center; }

.link-arrow { display: inline-flex; align-items: center; gap: .4rem; font: 600 1.02rem var(--font-display); color: var(--ink); text-decoration: none; }
.link-arrow svg { width: 18px; height: 18px; stroke-width: 2.6; transition: transform .2s var(--ease); }
a:hover .link-arrow svg, .link-arrow:hover svg { transform: translateX(4px); }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--cream); border-bottom: var(--bw) solid transparent; transition: border-color .2s; }
.site-header.is-scrolled { border-bottom-color: var(--ink); }
.site-header__inner { display: flex; align-items: center; gap: 1.25rem; height: var(--header-h); }
.brand img { height: 44px; width: auto; }
.nav { margin-left: auto; display: none; }
.nav__list { display: flex; align-items: center; gap: .2rem; list-style: none; margin: 0; padding: 0; }
.nav__item { position: relative; }
.nav__link, .nav__trigger {
  display: inline-flex; align-items: center; gap: .25rem; padding: .5rem .7rem;
  font: 500 1.04rem/1 var(--font-display); color: var(--ink); text-decoration: none; background: none; border: 0; cursor: pointer;
  text-decoration-line: underline; text-decoration-color: transparent; text-decoration-thickness: 2px; text-underline-offset: 8px;
}
.nav__link:hover, .nav__trigger:hover, .nav__link[aria-current="page"], .nav__item.is-active > .nav__trigger {
  text-decoration-color: var(--pink); text-decoration-style: wavy;
}
.nav__trigger svg { width: 16px; height: 16px; stroke-width: 2.6; transition: transform .2s; }
.nav__trigger[aria-expanded="true"] svg { transform: rotate(180deg); }
.nav__menu {
  position: absolute; top: calc(100% + 12px); left: 50%; min-width: 320px; padding: .6rem; margin: 0; list-style: none;
  background: var(--paper); border: var(--border); border-radius: var(--r); box-shadow: var(--pop);
  opacity: 0; visibility: hidden; transform: translate(-50%, 8px); transition: opacity .15s, transform .2s var(--ease), visibility .15s;
}
.nav__menu::before { content: ""; position: absolute; inset: -14px 0 auto; height: 14px; }
.nav__item.is-open > .nav__menu, .nav__item:hover > .nav__menu { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.nav__menu a { display: grid; grid-template-columns: 40px 1fr; gap: .75rem; align-items: center; padding: .55rem .6rem; border-radius: 14px; text-decoration: none; color: var(--ink); }
.nav__menu a:hover, .nav__menu a:focus-visible, .nav__menu a[aria-current="page"] { background: var(--sun-100); }
.nav__menu strong { display: block; font: 600 1rem/1.2 var(--font-display); }
.nav__menu small { display: block; font-size: .8rem; color: var(--ink-mute); line-height: 1.35; margin-top: .1rem; }
.nav__menu .bubble { width: 40px; height: 40px; border-radius: 12px; }
.nav__menu .bubble svg { width: 20px; height: 20px; }
.nav__menu--wide { min-width: 600px; display: grid; grid-template-columns: 1fr 1fr; gap: .15rem; }
.header-cta { display: none; }
.menu-toggle {
  margin-left: auto; display: inline-grid; place-items: center; width: 50px; height: 50px; border-radius: 14px;
  border: var(--border); background: var(--sun); box-shadow: 0 3px 0 var(--ink); cursor: pointer; color: var(--ink);
}
.menu-toggle svg { width: 24px; height: 24px; stroke-width: 2.6; }
@media (min-width: 1100px) { .nav { display: block; } .header-cta { display: inline-flex; } .menu-toggle { display: none; } }

.drawer { position: fixed; inset: 0; z-index: 60; }
.drawer__backdrop { position: absolute; inset: 0; background: rgba(11, 61, 78, .5); animation: fade .2s ease; }
.drawer__panel { position: absolute; inset: 0 0 0 auto; width: min(420px, 100%); background: var(--cream); border-left: var(--border); overflow-y: auto; padding: 1rem var(--gutter) 2rem; animation: slide .3s var(--ease); }
.drawer__top { display: flex; align-items: center; justify-content: space-between; height: 62px; margin-bottom: .5rem; }
.drawer__top img { height: 38px; width: auto; }
.drawer nav > a, .drawer summary { display: flex; justify-content: space-between; align-items: center; padding: .9rem .2rem; font: 600 1.2rem var(--font-display); color: var(--ink); text-decoration: none; border-bottom: 2px dashed rgba(11, 61, 78, .25); cursor: pointer; list-style: none; }
.drawer summary::-webkit-details-marker { display: none; }
.drawer summary svg { width: 20px; height: 20px; stroke-width: 2.6; transition: transform .2s; }
.drawer details[open] summary svg { transform: rotate(180deg); }
.drawer details a { display: block; padding: .6rem .2rem .6rem 1rem; font-size: 1.02rem; color: var(--ink-soft); text-decoration: none; }
.drawer .btn { margin-top: 1.5rem; width: 100%; }
@keyframes fade { from { opacity: 0; } }
@keyframes slide { from { transform: translateX(60px); opacity: 0; } }
body.no-scroll { overflow: hidden; }

/* ---------- Icon bubbles ---------- */
.bubble { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 18px; border: var(--border); background: var(--b, var(--sky)); color: var(--ink); flex: none; }
.bubble svg { width: 26px; height: 26px; stroke-width: 2.2; }
.c-sky { --b: var(--sky); --t: var(--sky-100); }
.c-sun { --b: var(--sun); --t: var(--sun-100); }
.c-pink { --b: var(--pink); --t: var(--pink-100); }
.c-mint { --b: var(--mint); --t: var(--mint-100); }
.c-tang { --b: var(--tang); --t: var(--tang-100); }

/* ---------- Doodles (decorative) ---------- */
.doodle { position: absolute; pointer-events: none; color: var(--ink); z-index: 0; }
.doodle svg { width: 100%; height: 100%; }
.doodle--float { animation: float 6s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-8px) rotate(6deg); } }
@media (max-width: 700px) { .doodle--hide-sm { display: none; } }

/* ---------- Home hero ---------- */
.hero { position: relative; overflow: hidden; padding-block: clamp(2.5rem, 1.5rem + 4vw, 5rem) clamp(4rem, 3rem + 4vw, 6.5rem); }
.hero > .container { position: relative; z-index: 1; }
.hero__grid { display: grid; gap: clamp(3rem, 2rem + 4vw, 4.5rem); align-items: center; }
@media (min-width: 980px) { .hero__grid { grid-template-columns: 1.05fr .95fr; } }
.hero h1 { margin-bottom: 1.25rem; }
.hero h1 .sub { display: block; color: var(--brand); font-weight: 600; font-size: .62em; margin-top: .35em; }
.squiggle { position: relative; white-space: nowrap; }
.squiggle svg { position: absolute; left: -2%; bottom: -.22em; width: 104%; height: .35em; color: var(--pink); overflow: visible; }
.hero__lede { font-size: var(--step-1); color: var(--ink-soft); max-width: 34rem; margin-bottom: 2rem; }
.hero__media { position: relative; max-width: 560px; justify-self: center; width: 100%; }
.hero__photo { border: var(--border); border-radius: var(--r-lg); box-shadow: 8px 8px 0 var(--ink); transform: rotate(2deg); overflow: hidden; background: var(--sky-100); }
.hero__photo img { width: 100%; aspect-ratio: 770 / 592; object-fit: cover; }
.hero__mascot { position: absolute; left: -9%; bottom: -14%; width: 34%; filter: drop-shadow(4px 4px 0 rgba(11, 61, 78, .18)); animation: wave-bot 4s ease-in-out infinite; transform-origin: 50% 90%; }
@keyframes wave-bot { 0%, 100% { transform: rotate(-4deg); } 50% { transform: rotate(4deg) translateY(-6px); } }
.sticker {
  position: absolute; z-index: 2; display: grid; place-items: center; text-align: center;
  font: 600 1rem/1.1 var(--font-display); color: var(--ink); border: var(--border); box-shadow: var(--pop-sm);
}
.sticker b { display: block; font-size: 1.9rem; line-height: 1; font-weight: 700; }
.sticker--round { width: 118px; height: 118px; border-radius: 50%; background: var(--sun); right: -4%; top: -9%; transform: rotate(10deg); }
.sticker--tag { padding: .6rem 1rem; border-radius: 14px; background: var(--pink); right: 6%; bottom: -7%; transform: rotate(-4deg); font-size: .95rem; }
@media (max-width: 560px) { .sticker--round { width: 92px; height: 92px; font-size: .82rem; } .sticker b { font-size: 1.45rem; } }

/* "Who are we helping?" tiles */
.picker { margin-top: clamp(3rem, 2rem + 3vw, 4.5rem); position: relative; z-index: 1; }
.picker__title { font: 600 var(--step-2) var(--font-display); margin-bottom: 1.25rem; display: flex; align-items: center; gap: .75rem; flex-wrap: wrap; }
.picker__title .scribble { margin: 0; }
.tiles { display: grid; gap: .9rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr)); list-style: none; margin: 0; padding: 0; }
.tile {
  display: flex; flex-direction: column; gap: .75rem; height: 100%; padding: 1rem 1rem 1.1rem;
  background: var(--t); border: var(--border); border-radius: var(--r); color: var(--ink); text-decoration: none;
  font: 600 1.05rem/1.2 var(--font-display); transition: transform .2s var(--ease), box-shadow .2s var(--ease);
}
@media (min-width: 1100px) { .tiles { grid-template-columns: repeat(7, 1fr); } }
.tile .bubble { width: 46px; height: 46px; border-radius: 14px; }
.tile .bubble svg { width: 22px; height: 22px; }
.tile:hover { transform: translate(-3px, -3px) rotate(-1deg); box-shadow: var(--pop); text-decoration: none; }

/* ---------- Sub-page hero ---------- */
.page-hero { position: relative; overflow: hidden; background: var(--accent-100); padding-block: clamp(2.5rem, 2rem + 3vw, 4.5rem) clamp(3.5rem, 2.5rem + 4vw, 5.5rem); }
.page-hero .container { position: relative; z-index: 1; }
.page-hero h1 { max-width: 17ch; }
.page-hero__lede { font-size: var(--step-1); color: var(--ink-soft); max-width: 40rem; margin-bottom: 2rem; }
.page-hero__grid { display: grid; gap: 2rem; align-items: center; }
@media (min-width: 980px) { .page-hero__grid { grid-template-columns: 1.4fr .6fr; } }
.page-hero__art { justify-self: center; width: min(280px, 60%); animation: wave-bot 4s ease-in-out infinite; transform-origin: 50% 90%; }
.page-hero__badge { justify-self: center; display: grid; place-items: center; align-content: center; width: 240px; aspect-ratio: 1; border-radius: 50%; background: var(--paper); border: var(--border); box-shadow: var(--pop); transform: rotate(-6deg); text-align: center; padding: 1.5rem; }
.page-hero__badge .bubble { width: 84px; height: 84px; border-radius: 26px; margin: 0 auto .6rem; }
.page-hero__badge .bubble svg { width: 42px; height: 42px; }
.page-hero__badge span { font: 400 1.35rem/1.1 var(--font-hand); }
@media (max-width: 979px) { .page-hero__badge { display: none; } }
.breadcrumb { display: flex; gap: .5rem; flex-wrap: wrap; font-size: .9rem; color: var(--ink-soft); margin: 0 0 1.25rem; list-style: none; padding: 0; }
.breadcrumb a { color: var(--ink-soft); text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline wavy var(--pink); }
.breadcrumb li + li::before { content: "›"; margin-right: .5rem; }

/* ---------- Cards ---------- */
.card { position: relative; background: var(--paper); border: var(--border); border-radius: var(--r); padding: clamp(1.4rem, 1.1rem + 1vw, 1.9rem); }
.card h3 { margin-bottom: .45rem; }
.card p { color: var(--ink-soft); margin-bottom: 0; }
.card p + p { margin-top: .75rem; }
.card .bubble { margin-bottom: 1.1rem; }
.card__num { font: 700 2.4rem/1 var(--font-display); color: var(--pink); margin-bottom: .6rem; }
a.card { display: flex; flex-direction: column; text-decoration: none; color: inherit; transition: transform .2s var(--ease), box-shadow .2s var(--ease); }
a.card:hover { transform: translate(-3px, -3px); box-shadow: var(--pop); }
a.card .link-arrow { margin-top: auto; padding-top: 1.25rem; }
.section--ink .card { background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .25); }
.section--ink .card p { color: #b6d3db; }

/* Home programme cards alternate tints */
.programme-card { background: var(--t); }
.programme-card__tag { font: 400 1.15rem/1 var(--font-hand); color: var(--ink-soft) !important; margin-bottom: .35rem !important; }
.programme-card--feature { background: var(--ink); border-color: var(--ink); color: #fff; }
.programme-card--feature h3, .programme-card--feature .link-arrow { color: #fff; }
.programme-card--feature p { color: #c6dde4 !important; }
.programme-card--feature .programme-card__tag { color: var(--sun) !important; }
a.programme-card--feature:hover { box-shadow: 5px 5px 0 var(--pink); }

/* Speech-bubble list ("Does this sound familiar?") */
.bubbles { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.1rem; }
.bubbles li {
  position: relative; max-width: 92%; padding: .85rem 1.2rem; background: var(--paper); border: var(--border); border-radius: 22px;
  font-weight: 500; line-height: 1.45; color: var(--ink);
}
.bubbles li::after {
  content: ""; position: absolute; bottom: -9px; left: 26px; width: 16px; height: 16px; background: inherit;
  border-right: var(--border); border-bottom: var(--border); transform: rotate(45deg); border-bottom-right-radius: 4px;
}
.bubbles li:nth-child(even) { justify-self: end; background: var(--accent-100); }
.bubbles li:nth-child(even)::after { left: auto; right: 26px; }
.bubbles li:nth-child(3n) { background: var(--sky-100); }

/* Sticky note */
.note-card {
  position: relative; background: var(--sun-100); border: var(--border); border-radius: 6px 6px 6px 30px; padding: 2.4rem 2rem 2rem;
  box-shadow: var(--pop); transform: rotate(1.5deg); color: var(--ink);
}
.note-card::before { /* tape */
  content: ""; position: absolute; top: -16px; left: 50%; width: 120px; height: 32px; transform: translateX(-50%) rotate(-3deg);
  background: rgba(79, 207, 227, .55); border: 2px solid rgba(11, 61, 78, .25); border-radius: 3px;
}
.note-card p:last-child { margin-bottom: 0; }
.note-card .big { font: 600 var(--step-2)/1.2 var(--font-display); color: var(--ink); }
.section--ink .note-card, .note-card--pink { background: var(--pink-100); }

/* Checklist */
.checklist { list-style: none; padding: 0; margin: 0; display: grid; gap: .85rem; }
.checklist li { position: relative; padding-left: 2.7rem; min-height: 30px; font-weight: 500; }
.checklist li::before {
  content: ""; position: absolute; left: 0; top: -.05rem; width: 30px; height: 30px; border-radius: 10px; border: var(--border);
  background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230b3d4e' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 16px no-repeat;
}
.section--ink .checklist li { color: #e3f1f5; }

/* Steps — a board-game path */
.steps { list-style: none; margin: 0; padding: 1.5rem 0 0; display: grid; gap: 2.5rem; counter-reset: step; }
@media (min-width: 900px) { .steps--row { grid-template-columns: repeat(var(--cols, 4), 1fr); gap: 2rem; } }
.step { position: relative; background: var(--paper); border: var(--border); border-radius: var(--r); padding: 1.6rem 1.5rem; counter-increment: step; }
.step::before {
  content: counter(step); display: grid; place-items: center; width: 56px; height: 56px; margin: -3rem 0 1rem;
  border: var(--border); border-radius: 50%; background: var(--sky); font: 700 1.6rem/1 var(--font-display); color: var(--ink);
}
.step:nth-child(4n+2)::before { background: var(--sun); }
.step:nth-child(4n+3)::before { background: var(--pink); }
.step:nth-child(4n+4)::before { background: var(--mint); }
.step p { color: var(--ink-soft); margin: 0; }
@media (min-width: 900px) {
  .steps--row .step:nth-child(odd) { transform: rotate(-1deg); }
  .steps--row .step:nth-child(even) { transform: rotate(1deg) translateY(.75rem); }
  .steps--row .step:not(:last-child)::after {
    content: ""; position: absolute; top: .2rem; right: -2.1rem; width: 2.2rem; height: 24px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 24' fill='none' stroke='%230b3d4e' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='M2 16c8-10 20-12 32-4' stroke-dasharray='3 5'/%3E%3Cpath d='M28 6l7 6-8 3'/%3E%3C/svg%3E") center / contain no-repeat;
  }
}

/* Stats */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 1.1rem; }
.stat { padding: 1.5rem; border: var(--border); border-radius: var(--r); background: var(--t, var(--paper)); color: var(--ink); }
.stat:nth-child(odd) { transform: rotate(-1.2deg); } .stat:nth-child(even) { transform: rotate(1deg); }
.stat__num { font: 700 clamp(2.8rem, 2rem + 3vw, 4rem)/1 var(--font-display); margin-bottom: .45rem; }
.stat__label { font-size: .95rem; line-height: 1.45; color: var(--ink-soft); }

/* Trust strip */
.trust { display: flex; flex-wrap: wrap; justify-content: center; gap: 1rem 2.5rem; font: 500 1.05rem var(--font-display); }
.trust b { font-size: 2rem; margin-right: .35rem; color: var(--brand); }

/* Press logos */
.press { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 1.4rem clamp(1.5rem, .5rem + 2vw, 2.75rem); }
.press img { height: 24px; width: auto; opacity: .7; }
.press img.tall { height: 36px; }
.press-label { text-align: center; margin-bottom: 1.5rem; }
.press-label .scribble { color: var(--ink-soft); }

/* Founders as polaroids */
.polaroids { display: flex; justify-content: center; gap: 1rem; padding: 1rem 0 2rem; }
.polaroid { margin: 0; background: var(--paper); border: var(--border); border-radius: 6px; padding: 12px 12px 0; width: min(46%, 260px); box-shadow: var(--pop); position: relative; }
.polaroid:first-child { transform: rotate(-4deg); }
.polaroid:last-child { transform: rotate(3deg) translateY(2rem); }
.polaroid::before { content: ""; position: absolute; top: -14px; left: 50%; width: 90px; height: 26px; transform: translateX(-50%) rotate(4deg); background: rgba(255, 203, 5, .7); border: 2px solid rgba(11, 61, 78, .2); }
.polaroid img { width: 100%; aspect-ratio: 1; object-fit: cover; border: 2px solid var(--ink); border-radius: 3px; }
.polaroid figcaption { padding: .6rem .2rem .9rem; font-family: var(--font-hand); font-size: 1.4rem; line-height: 1.1; text-align: center; }
.polaroid figcaption small { display: block; font-family: var(--font-body); font-size: .75rem; color: var(--ink-mute); margin-top: .3rem; line-height: 1.35; }
@media (min-width: 900px) { .polaroids-col { position: sticky; top: calc(var(--header-h) + 2rem); } }
.story p { font-size: 1.05rem; color: var(--ink-soft); }
.said {
  position: relative; margin: 1.5rem 0 1.75rem; padding: 1rem 1.4rem; background: var(--pink-100); border: var(--border); border-radius: 22px;
  font: 600 var(--step-2)/1.25 var(--font-display); color: var(--ink) !important; max-width: 28rem;
}
.said::after { content: ""; position: absolute; bottom: -10px; left: 30px; width: 18px; height: 18px; background: inherit; border-right: var(--border); border-bottom: var(--border); transform: rotate(45deg); }

/* Quotes (speech bubbles with a name under) */
.quote { display: flex; flex-direction: column; margin: 0; }
.quote blockquote { position: relative; margin: 0 0 1.4rem; padding: 1.4rem 1.5rem; background: var(--t, var(--paper)); border: var(--border); border-radius: 24px; font-size: 1.02rem; line-height: 1.6; flex: 1; }
.quote blockquote::after { content: ""; position: absolute; bottom: -11px; left: 34px; width: 20px; height: 20px; background: inherit; border-right: var(--border); border-bottom: var(--border); transform: rotate(45deg); }
.quote cite { font: 600 1.05rem var(--font-display); font-style: normal; padding-left: 1rem; }
.quote cite span { display: block; font: 400 1.1rem var(--font-hand); color: var(--ink-mute); }

.video-card { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.video-card__frame { position: relative; aspect-ratio: 16 / 10; display: grid; place-items: center; background: var(--b); border-bottom: var(--border); color: var(--ink); text-decoration: none; }
.video-card__frame .play { display: grid; place-items: center; width: 76px; height: 76px; border-radius: 50%; background: var(--paper); border: var(--border); box-shadow: var(--pop-sm); transition: transform .2s var(--ease); }
.video-card__frame .play svg { width: 30px; height: 30px; margin-left: 4px; }
.video-card__frame:hover .play { transform: scale(1.08) rotate(-4deg); }
.video-card__frame .lbl { position: absolute; left: 1rem; bottom: .8rem; font: 400 1.25rem var(--font-hand); }
.video-card__body { padding: 1.4rem 1.5rem 1.6rem; }
.tag { display: inline-block; font: 400 1.15rem/1 var(--font-hand); padding: .3rem .6rem; border: 2px solid var(--ink); border-radius: 8px; background: var(--t, var(--sun-100)); margin-bottom: .8rem; transform: rotate(-2deg); }

/* CTA band with the mascot peeking over the edge */
.cta-band {
  position: relative; display: grid; gap: 1.75rem; align-items: center; margin-top: 3rem;
  padding: clamp(2rem, 1.5rem + 3vw, 3.5rem);
  background: var(--sky); border: var(--border); border-radius: var(--r-lg); box-shadow: 8px 8px 0 var(--ink); color: var(--ink);
}
@media (min-width: 900px) { .cta-band { grid-template-columns: 1.4fr auto; padding-right: clamp(2rem, 1rem + 4vw, 4rem); } }
.cta-band h2 { font-size: var(--step-3); margin-bottom: .5rem; }
.cta-band p:not(.scribble):not(.price) { margin: 0; font-size: var(--step-1); max-width: 38rem; }
.cta-band__bot { position: absolute; right: clamp(1rem, 4vw, 4rem); bottom: 100%; margin-bottom: -40px; width: clamp(84px, 9vw, 120px); transform: rotate(8deg); }
.cta-band--sun { background: var(--sun); }

.disclaimer { display: grid; grid-template-columns: 26px 1fr; gap: .9rem; padding: 1.25rem 1.4rem; border: 2px dashed var(--ink-mute); border-radius: var(--r); font-size: .92rem; color: var(--ink-soft); background: var(--paper); }
.disclaimer svg { width: 24px; height: 24px; color: var(--ink); }
.disclaimer strong { display: block; font-family: var(--font-display); font-size: 1rem; margin-bottom: .2rem; color: var(--ink); }

/* Prose */
.prose { font-size: 1.07rem; color: var(--ink-soft); }
.prose p { margin-bottom: 1.1em; }
.prose .big { font: 600 var(--step-2)/1.25 var(--font-display); color: var(--ink); }
.section--ink .prose { color: #c4dde4; }
.section--ink .prose .big { color: #fff; }

/* FOCUS: who-it-explains list */
.facets { display: grid; gap: .45rem; margin-top: 1.1rem; }
.facet { display: grid; grid-template-columns: 7.5rem 1fr; gap: .75rem; font-size: .92rem; padding-top: .5rem; border-top: 2px dashed rgba(11, 61, 78, .18); }
.facet dt { font: 600 .98rem var(--font-display); }
.facet dd { margin: 0; color: var(--ink-soft); }
@media (max-width: 560px) { .facet { grid-template-columns: 1fr; gap: .1rem; } }

/* Attention meter illustration (a little "game screen") */
.meter { position: relative; background: var(--ink); border: var(--border); border-radius: var(--r-lg); padding: 1.5rem 1.6rem 1.6rem; color: #cfe7ee; box-shadow: 8px 8px 0 var(--sky); }
.section--ink .meter { box-shadow: 8px 8px 0 var(--pink); border-color: #fff; }
.meter__label { display: flex; justify-content: space-between; align-items: center; font: 500 1rem var(--font-display); margin-bottom: .75rem; color: #fff; }
.meter__label .live { display: inline-flex; align-items: center; gap: .4rem; font-size: .85rem; color: var(--sun); }
.meter__label .live::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--pink); animation: blink 1.4s infinite; }
@keyframes blink { 50% { opacity: .2; } }
.meter__track { height: 26px; background: rgba(255, 255, 255, .1); border: 2px solid rgba(255, 255, 255, .35); border-radius: 12px; overflow: hidden; padding: 3px; }
.meter__fill { height: 100%; width: 72%; border-radius: 8px; background: repeating-linear-gradient(-45deg, var(--sun) 0 10px, #ffd83d 10px 20px); animation: focus 6s ease-in-out infinite; }
@keyframes focus { 0%, 100% { width: 38%; } 35% { width: 82%; } 55% { width: 64%; } 75% { width: 93%; } }
.meter__scene { position: relative; height: 130px; margin-top: 1.1rem; border-radius: 14px; background: #0f4c61; border: 2px solid rgba(255, 255, 255, .2); overflow: hidden; }
.meter__scene .stars { position: absolute; inset: 0; width: 100%; height: 100%; }
.meter__rocket { position: absolute; left: 14%; width: 58px; animation: rocket 6s ease-in-out infinite; }
@keyframes rocket { 0%, 100% { bottom: 6%; } 35% { bottom: 48%; } 55% { bottom: 30%; } 75% { bottom: 56%; } }
.meter__foot { display: flex; gap: 1.5rem; margin-top: 1rem; font-size: .88rem; }
.meter__foot b { display: block; font: 600 1.2rem var(--font-display); color: #fff; }

/* Studies */
.study { display: flex; flex-direction: column; }
.study__source { font: 600 1.05rem/1.25 var(--font-display); margin-bottom: .6rem !important; color: var(--ink) !important; }
.study .link-arrow { margin-top: auto; padding-top: 1.25rem; }

/* Grades (Focus Formula) */
.grades { display: grid; gap: 1.2rem; }
@media (min-width: 800px) { .grades { grid-template-columns: repeat(3, 1fr); } }
.grade { padding: 1.5rem; border: var(--border); border-radius: var(--r); background: var(--t); }
.grade:nth-child(1) { transform: rotate(-1.5deg); } .grade:nth-child(3) { transform: rotate(1.5deg); }
.grade strong { display: block; font: 700 2rem/1 var(--font-display); margin-bottom: .5rem; }
.grade p { margin: 0; color: var(--ink-soft); }

.price { font: 700 var(--step-4)/1 var(--font-display); margin: .2rem 0 .75rem; }

/* ---------- Agent finder ---------- */
.finder-map { display: grid; gap: 1.5rem; align-items: start; }
@media (min-width: 960px) { .finder-map { grid-template-columns: 1.45fr 1fr; } }
.map-card { position: relative; background: var(--paper); border: var(--border); border-radius: var(--r-lg); box-shadow: var(--pop); padding: .75rem; }
.map { width: 100%; height: auto; aspect-ratio: 625 / 544; display: block; background: #e3f6fa; border-radius: 22px; touch-action: manipulation; user-select: none; }
.map .ctx { fill: #f1eadc; stroke: #cdbfa6; stroke-width: 1; vector-effect: non-scaling-stroke; }
.map .region { fill: #fff; stroke: var(--ink); stroke-width: 1.5; vector-effect: non-scaling-stroke; cursor: pointer; transition: fill .2s; outline: none; }
.map .region.is-country { fill: #faf6ec; }
.map .region:hover, .map .region:focus-visible { fill: var(--sun-100); }
.map .region:focus-visible { stroke: var(--pink); stroke-width: 3; }
.map .region.is-active { fill: var(--sun); }
.map.has-active .region:not(.is-active) { fill: #f3f6f6; }
.map.has-active .region:not(.is-active):hover { fill: var(--sun-100); }
.map .badge { cursor: pointer; transition: opacity .25s; }
.map .badge circle { fill: var(--pink); stroke: var(--ink); stroke-width: 2.5; vector-effect: non-scaling-stroke; }
.map .badge text { font: 700 14px var(--font-display); fill: var(--ink); text-anchor: middle; dominant-baseline: central; pointer-events: none; }
.map.has-active .badge { opacity: 0; pointer-events: none; }
.map .city { opacity: 0; pointer-events: none; transition: opacity .3s; cursor: pointer; outline: none; }
.map .city.is-shown { opacity: 1; pointer-events: auto; }
.map .city circle { fill: var(--pink); stroke: var(--ink); vector-effect: non-scaling-stroke; stroke-width: 2; }
.map .city text { font-family: var(--font-display); font-weight: 600; fill: var(--ink); paint-order: stroke; stroke: #fff; stroke-width: 4px; stroke-linejoin: round; opacity: 0; transition: opacity .15s; pointer-events: none; }
.map .city:hover text, .map .city:focus-visible text, .map .city.is-picked text, .map.few-cities .city text { opacity: 1; }
.map .city.is-picked circle, .map .city:hover circle { fill: var(--sun); }
.map-hint { position: absolute; left: 1.6rem; top: 1.4rem; font: 400 1.3rem/1 var(--font-hand); color: var(--ink-soft); pointer-events: none; transform: rotate(-3deg); }
.map-zoomout { position: absolute; right: 1.4rem; top: 1.4rem; }

.panel { background: var(--paper); border: var(--border); border-radius: var(--r-lg); padding: 1.4rem; }
.panel h2 { font-size: var(--step-2); margin-bottom: .25rem; }
.panel__sub { color: var(--ink-soft); font-size: .95rem; margin-bottom: 1rem; }
.place-list { list-style: none; margin: 0; padding: 0 .3rem 0 0; display: grid; gap: .5rem; max-height: 460px; overflow-y: auto; }
.place {
  width: 100%; display: flex; justify-content: space-between; align-items: center; gap: .75rem; text-align: left;
  padding: .65rem .9rem; border: 2px solid var(--ink); border-radius: 14px; background: var(--cream); color: var(--ink);
  font: 500 1.02rem/1.2 var(--font-display); cursor: pointer; transition: background-color .15s, transform .15s var(--ease);
}
.place:hover { background: var(--sun-100); transform: translateX(3px); }
.place[aria-pressed="true"] { background: var(--sun); }
.place .count { flex: none; display: grid; place-items: center; min-width: 30px; height: 30px; padding: 0 .4rem; border: 2px solid var(--ink); border-radius: 10px; background: var(--paper); font-weight: 600; font-size: .9rem; }
.back { display: inline-flex; align-items: center; gap: .35rem; margin-bottom: .9rem; padding: 0; border: 0; background: none; font: 500 1rem var(--font-display); color: var(--ink-soft); cursor: pointer; }
.back svg { width: 18px; height: 18px; transform: rotate(180deg); stroke-width: 2.6; }
.back:hover { color: var(--ink); text-decoration: underline wavy var(--pink); }

.results-bar { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between; margin: 3.5rem 0 1.75rem; }
.results-bar h2 { font-size: var(--step-3); margin: 0; }
.search { position: relative; flex: 0 1 380px; }
.search svg { position: absolute; left: 1rem; top: 50%; translate: 0 -50%; width: 20px; height: 20px; stroke-width: 2.5; pointer-events: none; }
.search input { width: 100%; min-height: 52px; padding: .7rem 1rem .7rem 2.9rem; border: var(--border); border-radius: 16px; background: var(--paper); font: 400 1rem var(--font-body); color: var(--ink); box-shadow: 0 3px 0 var(--ink); }
.search input:focus { outline: none; box-shadow: 0 3px 0 var(--ink), 0 0 0 4px var(--sun); }
.region-group { margin-bottom: 2.75rem; }
.region-group__title { font-size: var(--step-2); margin-bottom: 1.1rem; display: flex; align-items: baseline; gap: .6rem; }
.region-group__title small { font: 400 1.25rem var(--font-hand); color: var(--ink-mute); }
.agents { display: grid; gap: 1.2rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 330px), 1fr)); }
.agent { display: flex; flex-direction: column; gap: 1rem; padding: 1.3rem 1.4rem; }
.agent.is-flash { animation: flash 1.4s ease; }
@keyframes flash { 25%, 60% { box-shadow: var(--pop); transform: translate(-3px, -3px); background: var(--sun-100); } }
.agent__area { display: flex; align-items: center; gap: .5rem; font-size: 1.25rem; margin: 0; }
.agent__area svg { width: 20px; height: 20px; color: #d6246e; stroke-width: 2.6; flex: none; }
.agent__people { display: grid; gap: 1rem; }
.person { display: grid; grid-template-columns: 46px 1fr; gap: .8rem; align-items: start; }
.avatar { width: 46px; height: 46px; border-radius: 50%; border: var(--border); display: grid; place-items: center; font: 600 .95rem var(--font-display); background: var(--b, var(--sky)); }
.person__name { font: 600 1.05rem/1.25 var(--font-display); }
.person__contact { display: flex; flex-direction: column; align-items: flex-start; gap: .25rem; margin-top: .3rem; font-size: .9rem; }
.person__contact a { display: inline-flex; gap: .4rem; text-decoration: none; color: var(--ink-soft); }
.person__contact a:hover { color: var(--ink); text-decoration: underline wavy var(--pink); }
.person__contact svg { width: 16px; height: 16px; flex: none; margin-top: .2em; stroke-width: 2.3; }
.agent details { margin-top: auto; border-top: 2px dashed rgba(11, 61, 78, .2); padding-top: .8rem; }
.agent summary { cursor: pointer; list-style: none; display: inline-flex; align-items: center; gap: .3rem; font: 600 1rem var(--font-display); }
.agent summary::-webkit-details-marker { display: none; }
.agent summary svg { width: 16px; height: 16px; stroke-width: 2.6; transition: transform .2s; }
.agent details[open] summary svg { transform: rotate(180deg); }
.agent__bio { font-size: .92rem; color: var(--ink-soft); margin-top: .75rem; }
.agent__bio h4 { font-size: 1rem; margin: 1rem 0 .3rem; }
.agent__bio p { margin-bottom: .75em; }
.empty { text-align: center; padding: 3rem 1rem; }
.empty img { width: 110px; margin: 0 auto 1rem; }

/* ---------- Footer ---------- */
.site-footer { position: relative; background: var(--ink); color: #a9c9d2; padding-block: 4.5rem 2rem; font-size: .95rem; margin-top: 22px; }
.site-footer a { color: #e6f3f6; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline wavy var(--pink); }
.footer__grid { display: grid; gap: 2.5rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr)); }
.footer__brand { grid-column: 1 / -1; max-width: 380px; }
@media (min-width: 1000px) { .footer__grid { grid-template-columns: 1.6fr repeat(4, 1fr); } .footer__brand { grid-column: auto; } }
.footer__brand img.logo { height: 46px; width: auto; margin-bottom: 1.1rem; }
.site-footer h2 { font: 400 1.45rem var(--font-hand); color: var(--sun); margin-bottom: .75rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.footer__bottom { margin-top: 3.5rem; padding-top: 1.5rem; border-top: 2px dashed rgba(255, 255, 255, .2); display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; align-items: center; font-size: .85rem; }
.flags { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: 1rem; }
.flags span { font-size: .8rem; padding: .2rem .6rem; border: 2px solid rgba(255, 255, 255, .3); border-radius: 8px; color: #e6f3f6; }

/* ---------- Motion: pop in on scroll ---------- */
.js .reveal { opacity: 0; transform: translateY(16px) scale(.98); transition: opacity .5s ease, transform .6s var(--ease); }
.js .reveal.is-in { opacity: 1; transform: none; }
.js .stat.reveal.is-in:nth-child(odd) { transform: rotate(-1.2deg); }
.js .stat.reveal.is-in:nth-child(even) { transform: rotate(1deg); }
.js .grade.reveal.is-in:nth-child(1) { transform: rotate(-1.5deg); }
.js .grade.reveal.is-in:nth-child(3) { transform: rotate(1.5deg); }
@media (min-width: 900px) {
  .js .steps--row .step.reveal.is-in:nth-child(odd) { transform: rotate(-1deg); }
  .js .steps--row .step.reveal.is-in:nth-child(even) { transform: rotate(1deg) translateY(.75rem); }
}
.js .note-card.reveal.is-in { transform: rotate(1.5deg); }

/* ---------- Utilities ---------- */
.mt-2 { margin-top: 2rem; } .mt-3 { margin-top: 3rem; } .mb-0 { margin-bottom: 0; }
.center { text-align: center; }
.lede { font-size: var(--step-1); color: var(--ink-soft); }

/* ---------- I-Listen registration form ---------- */
.reg { --pen: #1d3f94; --err: #b3104f; display: grid; gap: 2rem; align-items: start; }
@media (min-width: 1000px) { .reg { grid-template-columns: minmax(0, 1fr) 280px; gap: 3rem; } }
.reg__form { display: grid; gap: 2rem; min-width: 0; }
.reg-part { background: var(--paper); border: var(--border); border-radius: var(--r-lg); padding: clamp(1.25rem, .8rem + 2vw, 2.25rem); scroll-margin-top: calc(var(--header-h) + 1rem); }
.reg-part__head { display: grid; grid-template-columns: auto 1fr; gap: 1rem; align-items: center; margin-bottom: 1.5rem; }
.reg-part__head h2 { font-size: var(--step-2); margin: 0 0 .15rem; }
.reg-part__head p { margin: 0; color: var(--ink-soft); font-size: .95rem; line-height: 1.5; }
.reg-part__num { display: grid; place-items: center; width: 52px; height: 52px; border: var(--border); border-radius: 50%; background: var(--b); font: 700 1.5rem/1 var(--font-display); transform: rotate(-6deg); }
.reg-grid { display: grid; gap: 1.25rem 1.1rem; }
@media (min-width: 640px) { .reg-grid { grid-template-columns: 1fr 1fr; } .field--wide { grid-column: 1 / -1; } }

.field { min-width: 0; margin: 0; }
.field > label:not(.tick), .field .label, .field legend { display: block; font: 600 1.02rem/1.3 var(--font-display); margin-bottom: .4rem; padding: 0; }
.field__opt { font: 400 1.05rem var(--font-hand); color: var(--ink-mute); }
.field__hint { font-size: .86rem; line-height: 1.4; color: var(--ink-mute); margin: -.2rem 0 .5rem; }
.field__error { margin: .4rem 0 0; font-size: .88rem; font-weight: 500; line-height: 1.4; color: var(--err); }
.field__error:empty { display: none; }
.reg input:not([type="radio"]):not([type="checkbox"]), .reg select, .reg textarea {
  width: 100%; min-height: 52px; padding: .7rem .9rem; border: var(--border); border-radius: 14px; background: var(--cream);
  font: 400 1rem/1.4 var(--font-body); color: var(--ink); box-shadow: 0 3px 0 var(--ink); transition: background-color .15s, box-shadow .15s;
}
.reg textarea { resize: vertical; min-height: 80px; }
.reg select { appearance: none; padding-right: 2.6rem; cursor: pointer; text-overflow: ellipsis;
  background: var(--cream) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230b3d4e' stroke-width='2.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") right .85rem center / 20px no-repeat; }
.reg input:focus, .reg select:focus, .reg textarea:focus { outline: none; background-color: var(--paper); box-shadow: 0 3px 0 var(--ink), 0 0 0 4px var(--sun); }
.reg input::placeholder, .reg textarea::placeholder { color: var(--ink-mute); opacity: 1; }
.reg :is(input, select, textarea)[aria-invalid="true"] { border-color: var(--err) !important; box-shadow: 0 3px 0 var(--err) !important; }
.reg input[readonly] { background: var(--mint-100); }
.dob { display: grid; grid-template-columns: 4.4rem minmax(0, 1fr) 5.6rem; gap: .5rem; }
.dob input { text-align: center; }

/* Big tap-target choices (radio) */
.choices { border: 0; padding: 0; }
.choices__row { display: flex; flex-wrap: wrap; gap: .6rem; }
.choices--3 .choices__row { display: grid; grid-template-columns: repeat(3, 1fr); }
.choice { position: relative; flex: 1 1 7rem; }
.choice input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.choice span {
  display: flex; flex-direction: column; justify-content: center; align-items: center; min-height: 52px; padding: .5rem .8rem; text-align: center;
  border: var(--border); border-radius: 14px; background: var(--cream); font: 600 1.05rem/1.15 var(--font-display);
  box-shadow: 0 3px 0 var(--ink); transition: transform .15s var(--ease), background-color .15s, box-shadow .15s;
}
.choice span small { font: 400 .78rem var(--font-body); color: var(--ink-soft); margin-top: .1rem; }
.choice:hover span { background: var(--accent-100); }
.choice input:checked + span { background: var(--accent); transform: translateY(2px); box-shadow: 0 1px 0 var(--ink); }
.choice input:checked + span small { color: var(--ink); }
.choice input:focus-visible + span { outline: 3px solid var(--pink); outline-offset: 3px; }
.choices[aria-invalid="true"] .choice span { border-color: var(--err); }

/* Checkbox rows */
.tick { display: flex; gap: .8rem; align-items: flex-start; cursor: pointer; font-weight: 500; line-height: 1.5; }
.tick input {
  appearance: none; flex: none; width: 30px; height: 30px; margin: -.05rem 0 0; border: var(--border); border-radius: 9px; background: var(--cream); cursor: pointer;
  transition: background-color .15s, transform .15s var(--ease);
}
.tick input:checked { transform: rotate(-4deg);
  background: var(--mint) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230b3d4e' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 20px no-repeat; }
.tick input:focus-visible { outline: 3px solid var(--pink); outline-offset: 3px; }
.tick--agree { padding: 1rem 1.1rem; border: var(--border); border-radius: var(--r); background: var(--mint-100); }
.tick--agree:has(input[aria-invalid="true"]) { border-color: var(--err); }

/* Payment plan: a little price card */
.plan { border: var(--border); border-radius: var(--r); background: var(--sun-100); padding: .6rem 1.2rem 1rem; }
.plan__row { display: flex; justify-content: space-between; gap: 1rem; align-items: baseline; padding: .6rem 0; border-bottom: 2px dashed rgba(11, 61, 78, .2); font-size: .95rem; }
.plan__row span { color: var(--ink-soft); }
.plan__row b { font: 600 1.05rem var(--font-display); text-align: right; }
.plan__row--big b { font-size: 1.6rem; line-height: 1.1; }
.plan__row b small { font-size: .95rem; font-weight: 500; }
.plan__note { margin: .8rem 0 0; font: 400 1.25rem/1.25 var(--font-hand); }
.plan__note strong { font-weight: 400; text-decoration: underline wavy var(--pink); text-decoration-thickness: 2px; text-underline-offset: 5px; }

/* Terms, with the parent's answers written into the blanks */
.terms { max-height: 26rem; overflow-y: auto; padding: 1.25rem 1.4rem; border: 2px dashed var(--ink-mute); border-radius: var(--r); background: var(--cream); font-size: .9rem; line-height: 1.65; color: var(--ink-soft); }
.terms h3 { font-size: 1.15rem; margin-bottom: .75rem; }
.terms ol { padding-left: 1.4rem; margin: 0; display: grid; gap: .45rem; }
.terms:focus-visible { outline-offset: 2px; }
.blank { font: 400 1.18em/1 var(--font-hand); color: var(--pen); padding: 0 .25em; border-bottom: 2px solid var(--pen); white-space: nowrap; }
.blank:empty { border-bottom: 2px dotted var(--ink-mute); }
.blank:empty::before { content: attr(data-empty); color: var(--ink-mute); font-size: .85em; }

/* Signature pad */
.sig__top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; margin-bottom: .5rem; }
.sig__top .label { margin: 0; }
.sig__tabs { display: flex; gap: .4rem; }
.sig__tab { display: inline-flex; align-items: center; gap: .35rem; min-height: 40px; padding: .35rem .8rem; border: 2px solid var(--ink); border-radius: 11px; background: var(--paper); font: 600 .95rem var(--font-display); color: var(--ink); cursor: pointer; }
.sig__tab svg { width: 16px; height: 16px; stroke-width: 2.6; }
.sig__tab[aria-pressed="true"] { background: var(--sun); }
.sig__pad { position: relative; height: 190px; border: var(--border); border-radius: var(--r); background: var(--paper); box-shadow: 0 3px 0 var(--ink); overflow: hidden; }
.sig__pad::after { content: ""; position: absolute; left: 2.6rem; right: 1.2rem; bottom: 46px; border-bottom: 2px dashed var(--ink-mute); pointer-events: none; }
.sig__pad canvas { position: absolute; inset: 0; width: 100%; height: 100%; touch-action: none; cursor: crosshair; z-index: 1; }
.sig__x { position: absolute; left: 1.1rem; bottom: 44px; font: 600 1.2rem var(--font-display); color: var(--ink-mute); }
.sig__hint { position: absolute; left: 0; right: 0; top: 38%; padding: 0 1rem; text-align: center; font: 400 clamp(1.15rem, 1rem + .8vw, 1.45rem) var(--font-hand); color: var(--ink-mute); pointer-events: none; }
.sig__pad.is-signed .sig__hint { display: none; }
.sig__clear { position: absolute; top: .6rem; right: .6rem; z-index: 2; min-height: 36px; padding: .25rem .8rem; border: 2px solid var(--ink); border-radius: 10px; background: var(--paper); font: 600 .9rem var(--font-display); color: var(--ink); cursor: pointer; }
.sig__clear:hover { background: var(--pink-100); }
.sig.is-invalid .sig__pad { border-color: var(--err); box-shadow: 0 3px 0 var(--err); }
.sig__preview { min-height: 4.2rem; margin: .6rem 0 0; padding: .2rem 1rem 0; border-bottom: 2px dashed var(--ink-mute); font: 400 2.6rem/1.5 var(--font-hand); color: var(--pen); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.sig .field__hint { margin: .6rem 0 0; }

/* Submit + result */
.reg-submit { padding: clamp(1.5rem, 1rem + 2vw, 2.5rem); border: var(--border); border-radius: var(--r-lg); background: var(--accent-100); box-shadow: var(--pop); }
.reg-submit h2 { font-size: var(--step-3); margin-bottom: .4rem; }
.reg-submit > p { color: var(--ink-soft); margin-bottom: 1.4rem; }
.btn[disabled] { opacity: .65; cursor: progress; transform: none; }
.reg-alert { margin-top: 1.4rem; padding: 1rem 1.2rem; border: var(--bw) solid var(--err); border-radius: var(--r-sm); background: var(--paper); font-size: .95rem; }
.reg-alert p { margin: 0 0 .6rem; } .reg-alert p:last-child { margin: 0; }
.reg-alert strong { font-family: var(--font-display); }
.reg-alert .btn-row { margin-top: .9rem; }

.reg__aside { display: grid; gap: 1.75rem; order: -1; }
@media (min-width: 1000px) { .reg__aside { order: 0; position: sticky; top: calc(var(--header-h) + 1.75rem); } }
.reg-note { padding: 2rem 1.5rem 1.4rem; }
.reg-note__hand { font: 400 1.5rem/1.2 var(--font-hand); margin-bottom: .9rem; }
.reg-note .checklist li { font-size: .95rem; }
.reg-note .checklist li::before { width: 26px; height: 26px; background-size: 17px; }
.reg-note__time { margin: 1rem 0 0; font: 400 1.2rem var(--font-hand); color: var(--ink-soft); }
.reg-progress { display: none; }
@media (min-width: 1000px) { .reg-progress { display: block; } }
.reg-progress ol { list-style: none; margin: 0; padding: 0; display: grid; gap: .15rem; }
.reg-progress a { display: flex; align-items: center; gap: .7rem; padding: .45rem .5rem; border-radius: 12px; color: var(--ink-soft); text-decoration: none; font: 500 1rem var(--font-display); }
.reg-progress a:hover { background: var(--paper); color: var(--ink); }
.reg-progress .dot { flex: none; width: 24px; height: 24px; border: 2px solid var(--ink); border-radius: 50%; background: var(--paper); transition: background-color .2s, transform .2s var(--ease); }
.reg-progress a.is-done { color: var(--ink); }
.reg-progress a.is-done .dot { transform: rotate(-8deg);
  background: var(--mint) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230b3d4e' stroke-width='3.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 15px no-repeat; }
.reg-paper { margin: 0; font-size: .92rem; color: var(--ink-soft); }

.reg-done { display: grid; gap: 1.5rem 2.5rem; align-items: center; max-width: 900px; margin-inline: auto; padding: clamp(1.75rem, 1rem + 3vw, 3rem); background: var(--paper); border: var(--border); border-radius: var(--r-lg); box-shadow: 8px 8px 0 var(--ink); }
.reg-done:focus { outline: none; }
.reg-done img { width: 130px; justify-self: center; animation: wave-bot 4s ease-in-out infinite; transform-origin: 50% 90%; }
@media (min-width: 700px) { .reg-done { grid-template-columns: auto 1fr; } .reg-done img { width: 170px; } }
.reg-done h2 { font-size: var(--step-4); }
.reg-done__ref { font-size: .95rem; color: var(--ink-soft); }
.reg-done__ref b { font: 600 1.15rem var(--font-display); color: var(--ink); letter-spacing: .04em; }
