/* Layout concept: the whole site is Pip's playroom. Sky and park up top, then wooden shelves
   on warm walls where the game's own objects (clock, coins, ruler, scale, year wheel, star jar)
   stand next to paper cards that explain them. One look on purpose: light, sunny, toy-like. */
@font-face { font-family: "Fredoka"; font-weight: 600; font-style: normal; font-display: swap; src: url("fonts/fredoka-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Lexend"; font-weight: 400; font-style: normal; font-display: swap; src: url("fonts/lexend-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Lexend"; font-weight: 500; font-style: normal; font-display: swap; src: url("fonts/lexend-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Lexend"; font-weight: 600; font-style: normal; font-display: swap; src: url("fonts/lexend-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Fredoka"; font-weight: 700; font-style: normal; font-display: swap; src: url("fonts/fredoka-latin-700-normal.woff2") format("woff2"); }

:root {
  /* Pip design tokens (lib/ui/theme/ls_tokens.dart): linen page, cream plaques, maple and walnut wood,
     blue = "do this", green = correct only, world colours for accents only */
  --sky: #7db9e3;
  --sky-pale: #e6f2fb;
  --sky-top: #64b4ed;
  --wall: #f6efe3;
  --peg: #f1d3a2;
  --paper: #fff6e6;
  --card: #ffffff;
  --paper-edge: #e8d1a8;
  --ink: #23343b;
  --ink-soft: #5b6b72;
  --wood-light: #f1d3a2;
  --wood: #e2b97e;
  --wood-edge: #c8955a;
  --wood-dark: #9c6b3c;
  --wood-deep: #5e3a1c;
  --blue: #1f6fe5;
  --blue-dark: #1653b0;
  --teal: #14a89e;
  --purple: #6e4fe0;
  --pink: #c63f88;
  --orange: #f07a2a;
  --green: #1e8e3e;
  --gold: #f2b331;
  --gold-dark: #c98f12;
  --sunflower: #f4b63a;
  --white: #ffffff;
  --cream-text: #fff6e6;
  --f-display: "Fredoka", "Baloo 2", "Trebuchet MS", system-ui, sans-serif;
  --f-body: "Lexend", "Segoe UI", system-ui, -apple-system, sans-serif;
  --wrap: 1180px;
  --gutter: clamp(16px, 4vw, 40px);
  --r-card: 26px;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
body {
  margin: 0;
  background: var(--wall);
  color: var(--ink);
  font: 400 1.03rem/1.65 var(--f-body);
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue-dark); }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; border-radius: 8px; }
h1, h2, h3 { font-family: var(--f-display); font-weight: 700; line-height: 1.08; margin: 0; text-wrap: balance; letter-spacing: -0.01em; }
h2 { font-size: clamp(2rem, 4.2vw, 3.1rem); }
h3 { font-size: clamp(1.55rem, 2.6vw, 2rem); }
p { margin: 0; }
.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--white); padding: 8px 14px; border-radius: 10px; z-index: 100; }
.skip:focus { left: 8px; }
.eyebrow { font: 600 0.98rem/1.2 var(--f-body); color: var(--wood-dark); }
.lede { font-size: clamp(1.05rem, 1.6vw, 1.2rem); color: var(--ink-soft); max-width: 60ch; }
.sec-head { display: grid; gap: 14px; justify-items: center; text-align: center; margin-bottom: clamp(36px, 6vw, 64px); }
.sec-head .lede { text-align: center; }

/* ---------- Wood ---------- */
.woodtex {
  background-color: var(--wood);
  background-image: url("img/wood.webp");
  background-size: 1600px 100%;
  background-repeat: repeat-x;
}
.shelf {
  position: relative;
  height: 28px;
  border-radius: 4px 4px 8px 8px;
  background: url("img/wood.webp") center / 1600px 100% repeat-x, var(--wood);
  box-shadow: inset 0 -5px 0 rgba(94, 58, 28, 0.18), 0 14px 18px -10px rgba(94, 58, 28, 0.55);
  z-index: 0;
}
.shelf::before {
  content: "";
  position: absolute;
  left: 4px; right: 4px; top: -12px; height: 13px;
  border-radius: 6px 6px 1px 1px;
  background: linear-gradient(180deg, #fde6bd 0%, #f4cd93 70%, #e7b678 100%);
}
.shelf::after {
  content: "";
  position: absolute;
  top: 100%; left: 12%; right: 12%; height: 26px;
  background:
    linear-gradient(135deg, var(--wood-dark) 50%, transparent 50%) left top / 26px 26px no-repeat,
    linear-gradient(225deg, var(--wood-dark) 50%, transparent 50%) right top / 26px 26px no-repeat;
  opacity: 0.9;
}
.shelf.no-brackets::after { display: none; }
.stand {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: clamp(8px, 2vw, 22px);
  margin-bottom: -6px;
  padding-inline: 4%;
}
.stand img { filter: drop-shadow(0 10px 8px rgba(94, 58, 28, 0.28)); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font: 700 1.05rem/1 var(--f-display);
  text-decoration: none;
  color: var(--white);
  background: var(--blue);
  border-radius: 999px;
  padding: 14px 26px 15px;
  box-shadow: 0 5px 0 var(--blue-dark);
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 7px 0 var(--blue-dark); }
.btn:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--blue-dark); }
.stores { display: flex; flex-wrap: wrap; gap: 12px; }
.store {
  display: inline-flex; align-items: center; gap: 12px;
  min-width: 190px;
  padding: 10px 20px 11px 14px;
  border-radius: 14px;
  background: #111317;
  color: var(--white);
  text-decoration: none;
  box-shadow: 0 5px 0 #000;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}
.store:hover { transform: translateY(-2px); box-shadow: 0 7px 0 #000; }
.store svg { width: 28px; height: 28px; flex: none; }
.store span { display: grid; line-height: 1.1; }
.store small { font: 600 0.72rem/1.2 var(--f-body); opacity: 0.85; }
.store b { font: 600 1.25rem/1.1 var(--f-display); }

/* ---------- Header ---------- */
.top {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 50;
  border-bottom: 5px solid var(--wood-dark);
  box-shadow: 0 6px 14px -6px rgba(94, 58, 28, 0.5);
}
.top .wrap { display: flex; align-items: center; gap: 20px; min-height: 70px; }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.logo img { width: 46px; height: 46px; border-radius: 12px; box-shadow: 0 3px 0 var(--wood-dark); }
.logo b { font: 700 1.9rem/1 var(--f-display); color: var(--white); text-shadow: 0 2px 0 var(--wood-dark), 0 0 1px var(--wood-deep); }
.nav { display: flex; gap: 6px; margin-left: auto; }
.nav a {
  font: 500 0.98rem/1 var(--f-body); color: var(--wood-deep); text-decoration: none;
  padding: 10px 14px; border-radius: 999px;
}
.nav a:hover { background: rgba(255, 250, 240, 0.55); }
.top .btn { padding: 11px 20px 12px; font-size: 1rem; }
@media (max-width: 820px) { .nav { display: none; } .top .btn { margin-left: auto; } }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  background: url("img/sky.webp") center bottom / 100% auto no-repeat, var(--sky-top);
  padding-top: clamp(28px, 5vw, 56px);
}
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  align-items: end;
  gap: 24px;
}
.bubble {
  position: relative;
  background: var(--paper);
  border-radius: 34px;
  padding: clamp(24px, 3.4vw, 40px);
  box-shadow: 0 8px 0 var(--paper-edge), 0 24px 40px -18px rgba(31, 43, 69, 0.35);
  display: grid;
  gap: 18px;
  margin-bottom: 64px;
}
.bubble::after {
  content: "";
  position: absolute;
  right: -22px; bottom: 54px;
  border: 18px solid transparent;
  border-left: 26px solid var(--paper);
  border-right: 0;
}
.bubble h1 { font-size: clamp(2.3rem, 4.6vw, 3.85rem); color: var(--ink); }
.bubble h1 em { font-style: normal; color: var(--blue); }
.bubble .lede { color: var(--ink-soft); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 0; list-style: none; }
.chips li {
  font: 600 0.86rem/1 var(--f-body);
  padding: 9px 13px; border-radius: 999px;
  background: var(--sky-pale); color: var(--ink);
}
.stage { display: flex; align-items: flex-end; justify-content: center; gap: 0; position: relative; z-index: 1; margin-bottom: -8px; }
.stage .pip { width: clamp(120px, 15vw, 200px); margin-right: -18px; position: relative; z-index: 2; filter: drop-shadow(0 10px 8px rgba(31,43,69,.25)); }
.phone {
  position: relative;
  width: clamp(200px, 22vw, 278px);
  padding: 10px;
  border-radius: 42px;
  background: #1c2433;
  box-shadow: inset 0 0 0 2px #3a4559, 0 22px 30px -14px rgba(20, 25, 40, 0.55);
  flex: none;
}
.phone img, .phone video { display: block; border-radius: 33px; width: 100%; height: auto; aspect-ratio: 560 / 1095; object-fit: cover; background: #f6ead2; }
.hero .shelf { margin-top: -2px; }
.hero-foot { height: 34px; }
.hero .stand { padding-inline: 0; justify-content: space-between; align-items: flex-end; }
.mini { display: flex; align-items: flex-end; gap: 18px; padding-left: 4%; }
.mini .m-clock { width: clamp(90px, 10vw, 140px); }
.mini .m-money { width: clamp(120px, 13vw, 180px); }
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); }
  .bubble { margin-bottom: 20px; }
  .bubble::after { right: auto; left: 60%; bottom: -30px; border: 16px solid transparent; border-top: 28px solid var(--paper); border-bottom: 0; }
  .hero { background-image: url("img/sky_m.webp"); }
  .mini { display: none; }
  .hero .stand { justify-content: center; }
}

/* ---------- Worlds (shelves on a wall) ---------- */
.walls { background: var(--wall); padding-block: clamp(64px, 9vw, 120px); }
.world {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: center;
}
.world + .world { margin-top: clamp(70px, 10vw, 120px); }
.world:nth-of-type(even) .display { order: 2; }
.display .stand { min-height: 240px; }
.card {
  background: var(--paper);
  border-radius: var(--r-card);
  padding: clamp(24px, 3.4vw, 38px);
  box-shadow: 0 7px 0 var(--paper-edge), 0 20px 32px -20px rgba(94, 58, 28, 0.45);
  display: grid;
  gap: 14px;
  min-width: 0;
}
.tag {
  justify-self: start;
  display: inline-flex; align-items: center; gap: 8px;
  font: 600 0.8rem/1 var(--f-body);  
  color: var(--white); padding: 8px 12px 8px 9px; border-radius: 999px; background: var(--c, var(--teal));
}
.tag svg { width: 18px; height: 18px; }
.card .skills { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 4px 0 0; padding: 0; }
.card .skills li {
  font: 500 0.9rem/1 var(--f-body);
  padding: 9px 12px; border-radius: 12px;
  background: color-mix(in srgb, var(--c, var(--teal)) 12%, var(--paper));
  color: var(--ink);
}
.std { font: 500 0.85rem/1.4 var(--f-body); color: var(--ink-soft); font-variant-numeric: tabular-nums; }
.std b { color: var(--ink); }
@media (max-width: 820px) {
  .world { grid-template-columns: minmax(0, 1fr); }
  .world:nth-of-type(even) .display { order: 0; }
  .display .stand { min-height: 0; }
}

/* ---------- How a lesson works (boards on a long shelf, pegboard wall) ---------- */
.pegwall {
  background-color: var(--peg);
  background-image: radial-gradient(circle at center, rgba(120, 76, 32, 0.22) 0 3px, transparent 3.6px);
  background-size: 36px 36px;
  padding-block: clamp(64px, 9vw, 120px);
}
.boards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(16px, 3vw, 36px);
  align-items: end;
  padding-inline: 3%;
  position: relative; z-index: 1;
  margin-bottom: -4px;
}
.board {
  position: relative;
  padding: 11px;
  border-radius: 24px;
  box-shadow: inset 0 0 0 2px rgba(94, 58, 28, 0.25), 0 12px 16px -10px rgba(94, 58, 28, 0.6);
  margin-bottom: 16px;
}
.board::before, .board::after {
  content: ""; position: absolute; bottom: -16px; width: 22px; height: 18px;
  background: var(--wood-dark); border-radius: 0 0 6px 6px;
}
.board::before { left: 18%; }
.board::after { right: 18%; }
.board .paper {
  background: var(--paper);
  border-radius: 16px;
  padding: 22px 22px 26px;
  display: grid; gap: 10px;
  min-height: 100%;
}
.board .art { height: 128px; display: grid; place-items: center; }
.step-no {
  width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center;
  font: 700 1.25rem/1 var(--f-display); color: var(--white);
  background: var(--orange); box-shadow: 0 3px 0 #c76a19;
}
.board h3 { font-size: 1.5rem; }
.board p { color: var(--ink-soft); font-size: 1rem; }
.q-bubble {
  display: flex; align-items: center; gap: 10px;
  background: var(--white); border-radius: 18px; padding: 10px 12px 10px 16px;
  box-shadow: 0 4px 0 #e6d6bb;
  font: 500 0.95rem/1.15 var(--f-body);
}
.q-bubble small { display: block; font-weight: 600; color: var(--ink-soft); font-size: 0.78rem; }
.q-bubble b { font: 700 1.2rem/1.1 var(--f-display); }
.speaker {
  width: 40px; height: 40px; border-radius: 50%; flex: none;
  background: var(--gold); box-shadow: 0 3px 0 #d79b12;
  display: grid; place-items: center;
}
.speaker svg { width: 20px; height: 20px; }
.check-demo { display: grid; gap: 14px; justify-items: center; }
.check-demo .stars { display: flex; gap: 6px; }
.check-demo .stars svg { width: 34px; height: 34px; }
.check-demo .stars svg:nth-child(2) { transform: translateY(-8px); }
.check-pill {
  font: 700 1.1rem/1 var(--f-display); color: var(--white);
  background: var(--blue); box-shadow: 0 5px 0 var(--blue-dark);
  padding: 13px 54px 14px; border-radius: 16px;
}
.hand-demo { position: relative; width: 150px; height: 120px; }
.hand-demo .coin {
  position: absolute; left: 8px; top: 8px; width: 74px; height: 74px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #f3b98a, #c8723f 70%, #a85a2c);
  box-shadow: inset 0 0 0 5px rgba(255, 255, 255, 0.25), 0 4px 0 #8c4a22;
  display: grid; place-items: center; font: 700 1.2rem/1 var(--f-display); color: #6b3412;
}
.hand-demo img { position: absolute; left: 52px; top: 40px; width: 88px; }
@media (max-width: 820px) {
  .boards { grid-template-columns: minmax(0, 1fr); max-width: 440px; margin-inline: auto; }
  .board { margin-bottom: 30px; }
  .board:last-child { margin-bottom: 16px; }
}

/* ---------- Gallery (phones on a long shelf) ---------- */
.gallery-sec {
  background: linear-gradient(180deg, var(--sky-pale) 0%, var(--sky) 100%);
  padding-block: clamp(64px, 9vw, 110px) clamp(48px, 7vw, 80px);
}
.rail-wrap { position: relative; }
.rail {
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  padding-bottom: 18px;
  -webkit-overflow-scrolling: touch;
}
.track {
  --pw: clamp(170px, 19vw, 210px);
  position: relative;
  display: flex;
  gap: clamp(20px, 3vw, 36px);
  width: max-content;
  padding: 10px var(--gutter) 70px;
  margin-inline: auto;
  list-style: none;
}
.track::after {
  content: ""; position: absolute; left: 0; right: 0;
  bottom: 40px; height: 28px;
  background: url("img/wood.webp") center / 1600px 100% repeat-x, var(--wood);
  box-shadow: inset 0 -5px 0 rgba(94, 58, 28, 0.18), 0 14px 18px -10px rgba(31, 43, 69, 0.45);
  border-radius: 4px;
  z-index: 0;
}
.track::before {
  content: ""; position: absolute; left: 0; right: 0;
  bottom: 67px; height: 13px;
  background: linear-gradient(180deg, #fde6bd 0%, #f4cd93 70%, #e7b678 100%);
  border-radius: 6px 6px 0 0;
  z-index: 0;
}
.track li { position: relative; z-index: 1; scroll-snap-align: center; display: grid; justify-items: center; }
.track .phone { width: var(--pw); border-radius: 34px; padding: 8px; }
.track .phone img { border-radius: 27px; }
.track figcaption {
  position: absolute; top: calc(100% + 12px);
  white-space: nowrap;
  font: 600 0.86rem/1 var(--f-body); color: var(--wood-deep);
  background: var(--paper); padding: 6px 12px; border-radius: 8px;
  box-shadow: 0 2px 0 var(--paper-edge);
}
.rail-btns { display: flex; justify-content: center; gap: 12px; margin-top: 18px; }
.round {
  width: 50px; height: 50px; border-radius: 50%; border: 0; cursor: pointer;
  background: var(--paper); color: var(--ink);
  box-shadow: 0 4px 0 var(--paper-edge);
  display: grid; place-items: center;
}
.round svg { width: 22px; height: 22px; }
.round:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--paper-edge); }

/* ---------- Rewards ---------- */
.rewards .world { align-items: end; }
.rewards .display .stand { min-height: 0; }

/* ---------- Parents ---------- */
.parents { background: var(--paper); padding-block: clamp(64px, 9vw, 120px); }
.feat {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(26px, 3.5vw, 44px) clamp(20px, 3vw, 40px);
  list-style: none; margin: 0; padding: 0;
}
.feat li { display: grid; grid-template-columns: 54px minmax(0, 1fr); gap: 16px; align-items: start; }
.feat .ic {
  width: 54px; height: 54px; border-radius: 18px;
  display: grid; place-items: center;
  background: var(--c); box-shadow: 0 4px 0 color-mix(in srgb, var(--c) 70%, #000);
}
.feat .ic svg { width: 28px; height: 28px; }
.feat h3 { font-size: 1.3rem; margin-bottom: 4px; }
.feat p { color: var(--ink-soft); font-size: 1rem; }
@media (max-width: 900px) { .feat { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .feat { grid-template-columns: minmax(0, 1fr); } }

.standards {
  margin-top: clamp(56px, 8vw, 90px);
  padding: 12px;
  border-radius: 28px;
  box-shadow: 0 14px 22px -14px rgba(94, 58, 28, 0.6);
}
.standards .inner { background: var(--wall); border-radius: 18px; padding: clamp(22px, 3.4vw, 40px); display: grid; gap: 16px; }
.standards h3 { font-size: clamp(1.5rem, 2.6vw, 2rem); }
.tbl { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; min-width: 560px; font-size: 0.98rem; }
th, td { text-align: left; padding: 12px 14px; vertical-align: top; }
thead th { font: 600 0.78rem/1 var(--f-body);   color: var(--wood-dark); border-bottom: 3px solid var(--paper-edge); }
tbody tr + tr td { border-top: 1px dashed var(--paper-edge); }
td:first-child { font-weight: 800; white-space: nowrap; font-variant-numeric: tabular-nums; }
td:last-child { white-space: nowrap; color: var(--ink-soft); font-weight: 700; }
.fine { font-size: 0.86rem; color: var(--ink-soft); }

/* ---------- FAQ ---------- */
.faq { padding-block: clamp(64px, 9vw, 120px); }
.faq-list { display: grid; gap: 14px; max-width: 820px; margin-inline: auto; }
.faq details {
  background: var(--paper); border-radius: 20px;
  box-shadow: 0 5px 0 var(--paper-edge);
}
.faq summary {
  cursor: pointer; list-style: none;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 20px 24px;
  font: 700 1.2rem/1.25 var(--f-display);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; flex: none; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; font: 700 1.4rem/1 var(--f-display);
  background: var(--sky-pale); color: var(--blue-dark);
}
.faq details[open] summary::after { content: "\2212"; }
.faq details > div { padding: 0 24px 22px; color: var(--ink-soft); max-width: 68ch; }

/* ---------- Final CTA ---------- */
.cta {
  background: url("img/sky.webp") center bottom / 100% auto no-repeat, var(--sky-top);
  padding-top: clamp(56px, 8vw, 90px);
  text-align: center;
}
.cta .bubble { max-width: 720px; margin: 0 auto 20px; justify-items: center; }
.cta .bubble::after { right: auto; left: calc(50% - 18px); bottom: -30px; border: 18px solid transparent; border-top: 28px solid var(--paper); border-bottom: 0; }
.cta .stand { justify-content: center; }
.cta .stand .pip { width: clamp(130px, 14vw, 190px); }
.cta .stand .c-clock { width: clamp(100px, 11vw, 150px); }
.cta .stand .c-jar { width: clamp(90px, 10vw, 130px); }

/* ---------- Footer ---------- */
.foot {
  color: var(--cream-text);
  background: linear-gradient(rgba(70, 40, 15, 0.82), rgba(60, 34, 12, 0.92)), url("img/wood.webp") center / 1600px 70px repeat, var(--wood-deep);
  padding-block: 44px 36px;
  border-top: 6px solid var(--wood-dark);
}
.foot .wrap { display: grid; gap: 22px; }
.foot-row { display: flex; flex-wrap: wrap; gap: 18px 36px; align-items: center; justify-content: space-between; }
.foot nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.foot a { color: var(--cream-text); font-weight: 700; }
.foot .logo b { text-shadow: none; }
.foot small { opacity: 0.85; font-size: 0.85rem; line-height: 1.5; }

/* ---------- Plain pages (privacy, support) ---------- */
.page { padding-block: clamp(40px, 6vw, 72px) clamp(64px, 9vw, 110px); }
.doc {
  max-width: 780px; margin-inline: auto;
  background: var(--paper); border-radius: 28px;
  padding: clamp(24px, 5vw, 56px);
  box-shadow: 0 7px 0 var(--paper-edge);
  display: grid; gap: 16px;
}
.doc h1 { font-size: clamp(2.2rem, 5vw, 3.2rem); }
.doc h2 { font-size: clamp(1.4rem, 2.6vw, 1.75rem); margin-top: 18px; }
.doc ul { margin: 0; padding-left: 1.3em; display: grid; gap: 6px; }
.doc .meta { color: var(--ink-soft); font-weight: 700; }
.draft-note {
  background: #fff1b8; border: 2px dashed #d9a400; color: var(--ink);
  border-radius: 16px; padding: 14px 18px; font-weight: 700;
}
mark.confirm { background: #ffe680; color: var(--ink); padding: 0 4px; border-radius: 4px; }
.contact-card {
  display: grid; gap: 8px; padding: 22px; border-radius: 20px; background: var(--sky-pale);
}
.contact-card .addr { font: 700 1.35rem/1.2 var(--f-display); user-select: all; word-break: break-all; }

@media (max-width: 600px) {
  table { min-width: 0; }
  thead { display: none; }
  tbody tr { display: grid; grid-template-areas: "code grade" "desc desc" "pip pip"; grid-template-columns: 1fr auto; gap: 4px 12px; padding: 14px 0; }
  tbody tr + tr { border-top: 1px dashed var(--paper-edge); }
  tbody tr + tr td { border-top: 0; }
  td { padding: 0; }
  td:nth-child(1) { grid-area: code; }
  td:nth-child(2) { grid-area: desc; }
  td:nth-child(3) { grid-area: pip; font-size: 0.88rem; color: var(--wood-dark); font-weight: 800; }
  td:nth-child(4) { grid-area: grade; }
}
.cta .stores { justify-content: center; }


/* ---------- v2 additions ---------- */
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 18px; }
.btn-big { font-size: 1.2rem; padding: 17px 30px 18px; }
.price-note { font: 600 0.92rem/1.35 var(--f-body); color: var(--ink-soft); }
.ahead {
  display: inline-block; vertical-align: 1px; margin-left: 4px;
  font: 600 0.7rem/1 var(--f-body); letter-spacing: 0.06em; 
  padding: 4px 7px; border-radius: 6px; background: #fff0c2; color: #8a5a00; white-space: nowrap;
}
.store.soon { background: #2a2f38; box-shadow: 0 5px 0 #11141a; cursor: default; }
.store.soon:hover { transform: none; box-shadow: 0 5px 0 #11141a; }
.badge img { height: 54px; width: auto; }
.cta .fine { margin-top: 2px; }
.track figure { margin: 0; display: grid; justify-items: center; position: relative; }

/* rewards list */
.rw-list { list-style: none; margin: 4px 0 0; padding: 0; display: grid; gap: 14px; }
.rw-list li { display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 12px; align-items: start; }
.rw-star svg { width: 28px; height: 28px; }
.rw-list b { font: 700 1.12rem/1.2 var(--f-display); }
.rw-list p { color: var(--ink-soft); font-size: 0.98rem; margin-top: 2px; }

/* certificates pinned on the pegboard */
.certs {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: clamp(14px, 2.2vw, 28px);
}
.cert { margin: 0; display: grid; gap: 12px; justify-items: center; text-align: center; }
.cert > img, .cert-art {
  width: 100%; aspect-ratio: 11 / 8.5; border-radius: 6px;
  box-shadow: 0 12px 18px -10px rgba(94, 58, 28, 0.55);
  transform: rotate(var(--tilt, -1.5deg));
  position: relative;
}
.certs li:nth-child(even) .cert > img, .certs li:nth-child(even) .cert-art { --tilt: 1.5deg; }
.cert > img { object-fit: cover; background: var(--white); }
.cert-art {
  background: var(--white);
  border: 7px double var(--c);
  display: grid; align-content: center; justify-items: center; gap: 4px; padding: 10px 10px 14px;
}
.cert-art::before {
  content: ""; position: absolute; top: -9px; left: 50%; width: 16px; height: 16px; margin-left: -8px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #ff8a7a, #d8432f 70%); box-shadow: 0 2px 2px rgba(0, 0, 0, 0.3);
}
.cert-kicker { font: 600 0.6rem/1 var(--f-body);   color: var(--c); }
.cert-name { font: 700 clamp(0.95rem, 1.5vw, 1.2rem)/1.05 var(--f-display); color: var(--ink); text-wrap: balance; }
.cert-line { font: 600 0.62rem/1 var(--f-body); color: var(--ink-soft); border-top: 1.5px solid var(--paper-edge); padding-top: 4px; min-width: 60%; }
.cert-seal { position: absolute; right: 8px; bottom: 6px; width: 26px; height: 26px; }
.cert-seal svg { width: 100%; height: 100%; }
.cert figcaption { display: grid; gap: 2px; }
.cert figcaption b { font: 700 1.05rem/1.15 var(--f-display); }
.cert figcaption span { font-size: 0.88rem; color: var(--ink-soft); font-weight: 700; }
@media (max-width: 900px) { .certs { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 560px) { .certs { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* parents sub-blocks */
.sub-block { margin-top: clamp(48px, 7vw, 80px); padding-top: clamp(36px, 5vw, 56px); border-top: 2px dashed var(--paper-edge); }
.sub-title { text-align: center; margin-bottom: clamp(26px, 4vw, 40px); font-size: clamp(1.6rem, 3vw, 2.2rem); }
.feat-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1000px) { .feat-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .feat-4 { grid-template-columns: minmax(0, 1fr); } }
.teachers { background: var(--sky-pale); }
.teachers .standards .inner { background: var(--paper); }
tr.is-ahead { background: rgba(255, 240, 194, 0.45); }

/* price */
.price-sec { padding-block: clamp(64px, 9vw, 110px); }
.price-card {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: center;
  background: var(--paper); border-radius: 34px; padding: clamp(26px, 4.5vw, 56px);
  box-shadow: 0 8px 0 var(--paper-edge), 0 24px 40px -22px rgba(94, 58, 28, 0.45);
}
.price-copy { display: grid; gap: 14px; min-width: 0; }
.ticks { list-style: none; margin: 4px 0; padding: 0; display: grid; gap: 10px; }
.ticks li { display: flex; align-items: center; gap: 12px; font: 500 1.08rem/1.3 var(--f-body); }
.ticks svg { width: 26px; height: 26px; flex: none; padding: 4px; border-radius: 50%; background: var(--wood-dark); color: var(--white); }
.dots { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: clamp(8px, 1.2vw, 14px); max-width: 460px; margin-inline: auto; }
.dot {
  display: block; aspect-ratio: 1; border-radius: 50%;
  background: #f3dfba; box-shadow: inset 0 0 0 3px #d9b57c;
}
.dot.free { background: radial-gradient(circle at 35% 30%, #ffe08a, var(--gold) 60%, var(--gold-dark)); box-shadow: 0 3px 0 #b37d07; }
.dots-legend { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 22px; margin-top: 20px; font: 600 0.95rem/1.2 var(--f-body); color: var(--ink-soft); }
.dots-legend span { display: inline-flex; align-items: center; gap: 8px; }
.dots-legend .dot { width: 18px; }
@media (max-width: 820px) { .price-card { grid-template-columns: minmax(0, 1fr); } }

/* privacy */
.privacy-sec { background: var(--paper); padding-block: clamp(64px, 9vw, 110px); }
.privacy-sec .card { background: var(--wall); box-shadow: 0 7px 0 var(--paper-edge); }
.lockbox {
  width: clamp(130px, 15vw, 190px); aspect-ratio: 1; border-radius: 30px;
  display: grid; place-items: center; color: var(--white);
  background: linear-gradient(160deg, #3f86f2, var(--blue-dark));
  box-shadow: 0 8px 0 #163b93, 0 18px 24px -12px rgba(31, 43, 69, 0.5);
}
.lockbox svg { width: 58%; height: 58%; }
.privacy-sec .card a { font-weight: 800; }
.doc .q { font-size: 1.2rem; margin-top: 6px; }

/* v3: real certificates, policy chooser */
.cert-hero { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 56px); align-items: center; margin-bottom: clamp(40px, 6vw, 64px); }
.cert-big { --tilt: -1.5deg; }
.cert-big > img { aspect-ratio: auto; border-radius: 6px; }
.cert > img { aspect-ratio: 1650 / 1275; height: auto; }
.cert-hero .card { background: var(--paper); }
@media (max-width: 820px) { .cert-hero { grid-template-columns: minmax(0, 1fr); } }
.cert figure, .cert { position: relative; }
.certs .cert::before, .cert-big::before {
  content: ""; position: absolute; top: -8px; left: 50%; width: 16px; height: 16px; margin-left: -8px; border-radius: 50%; z-index: 2;
  background: radial-gradient(circle at 35% 35%, #ff8a7a, #d8432f 70%); box-shadow: 0 2px 2px rgba(0, 0, 0, 0.3);
}
.price-big { font: 700 1.3rem/1.3 var(--f-display); }
.price-big b { font-size: 2rem; color: var(--blue); }
.policy-links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.policy-link {
  display: grid; gap: 4px; padding: 20px 22px; border-radius: 20px; text-decoration: none;
  background: var(--sky-pale); color: var(--ink); box-shadow: 0 5px 0 #b9dcf5;
}
.policy-link b { font: 700 1.25rem/1.2 var(--f-display); }
.policy-link span { color: var(--blue-dark); font-weight: 800; }
.policy-link:hover { transform: translateY(-2px); }
@media (max-width: 560px) { .policy-links { grid-template-columns: minmax(0, 1fr); } }
section[id], article[id] { scroll-margin-top: 84px; }

.standards .inner p { max-width: 72ch; }
table.codes { min-width: 0; }

/* Kidz Tales company page */
.kidz-hero .stage .pip { width: clamp(150px, 18vw, 240px); margin-right: 0; }
.game-card {
  display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: clamp(20px, 4vw, 40px); align-items: center;
  max-width: 820px; margin-inline: auto; background: var(--paper); border-radius: 30px;
  padding: clamp(22px, 4vw, 40px); box-shadow: 0 7px 0 var(--paper-edge), 0 20px 32px -20px rgba(94, 58, 28, 0.45);
}
.game-card img { border-radius: 36px; box-shadow: 0 6px 0 var(--wood-edge); }
.game-card > div { display: grid; gap: 12px; justify-items: start; }
@media (max-width: 600px) { .game-card { grid-template-columns: minmax(0, 1fr); justify-items: center; text-align: center; } .game-card > div { justify-items: center; } }
