/* KnowIt promo site — tokens follow the app (src/theme/tokens.ts) and creative_design_rule.md */
:root {
  --green: #16a34a;
  --green-strong: #15803d;
  --green-deep: #14532d;
  --green-tint: #dcfce7;
  --brand-grad: linear-gradient(135deg, #2fcb68, #16a253 45%, #0b7d3e);
  --yellow: #ffd21f;
  --purple-ink: #2b2350;
  --purple-sub: #6b5f8f;
  --ink: #0f172a;
  --ink-2: #334155;
  --muted: #64748b;
  --line: #e2e8f0;
  --bg: #fffdf8;
  --surface: #ffffff;
  --cream: #fff7ec;
  --radius: 18px;
  --shadow: 0 10px 30px rgba(43, 35, 80, .10), 0 2px 6px rgba(43, 35, 80, .06);
  --shadow-lg: 0 30px 60px rgba(20, 17, 31, .25);
  --font: 'Baloo 2', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 18px;
  line-height: 1.55;
  color: var(--ink-2);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--green-strong); }
h1, h2, h3 { color: var(--ink); font-weight: 800; line-height: 1.05; letter-spacing: -.5px; margin: 0; }
h2 { font-size: clamp(32px, 4.6vw, 52px); }
h3 { font-size: 24px; letter-spacing: -.2px; }
p { margin: 0; }

.wrap { width: min(1160px, 100% - 32px); margin-inline: auto; }
.section { padding: clamp(72px, 9vw, 120px) 0; position: relative; }
.kicker {
  display: inline-block; font-weight: 700; font-size: 15px; letter-spacing: 1.2px;
  text-transform: uppercase; color: var(--green-strong); margin-bottom: 10px;
}
.kicker-light { color: var(--yellow); }
.section-lede { max-width: 620px; margin: 14px auto 0; font-size: 20px; color: var(--muted); }
.section-lede.left { margin-inline: 0; }
.hl { color: var(--yellow); }
.hl-green { color: var(--green); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: 700 18px/1 var(--font); border: 0; border-radius: 14px; padding: 14px 22px;
  cursor: pointer; text-decoration: none; transition: transform .15s, box-shadow .15s, background .15s;
}
.btn:active { transform: translateY(2px); }
.btn-primary { background: var(--green-strong); color: #fff; box-shadow: 0 4px 0 #0f5f2d; }
.btn-primary:hover { background: #12733a; }
.btn-sm { padding: 10px 16px; font-size: 16px; border-radius: 12px; }
.btn-yellow { background: var(--yellow); color: var(--purple-ink); box-shadow: 0 4px 0 #c9a200; }
.btn-ghost-light { background: rgba(255,255,255,.12); color: #fff; border: 2px solid rgba(255,255,255,.3); }
.btn-ghost-light:hover { background: rgba(255,255,255,.2); }
:focus-visible { outline: 3px solid var(--yellow); outline-offset: 3px; }

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 253, 248, .85); backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent; transition: border-color .2s, box-shadow .2s;
}
.nav.scrolled { border-color: var(--line); box-shadow: 0 4px 20px rgba(15,23,42,.05); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; gap: 20px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; font-size: 26px; color: var(--ink); letter-spacing: -.5px; }
.brand img { border-radius: 10px; }
.brand b { color: var(--green); }
.nav-links { display: flex; gap: 28px; }
.nav-links a { color: var(--ink-2); text-decoration: none; font-weight: 600; font-size: 17px; }
.nav-links a:hover { color: var(--green-strong); }

/* Hero */
.hero {
  position: relative; overflow: hidden; color: #fff;
  background: var(--brand-grad);
  padding: clamp(48px, 7vw, 96px) 0 clamp(64px, 8vw, 110px);
}
.blob { position: absolute; border-radius: 50%; background: rgba(255,255,255,.10); }
.blob-a { width: 520px; height: 520px; top: -200px; right: -120px; }
.blob-b { width: 380px; height: 380px; bottom: -180px; left: -120px; }
.hero-inner { position: relative; display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
.eyebrow {
  display: inline-block; background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.25);
  padding: 6px 14px; border-radius: 999px; font-weight: 700; font-size: 16px; margin-bottom: 18px;
}
.hero h1 { color: #fff; font-size: clamp(48px, 7.2vw, 88px); letter-spacing: -1.5px; line-height: .98; }
.lede { font-size: clamp(19px, 2vw, 22px); color: #dcf7e6; margin-top: 20px; max-width: 520px; font-weight: 500; }
.store-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.store-row.center { justify-content: center; }
.store-btn {
  display: inline-flex; align-items: center; gap: 10px; text-decoration: none;
  background: #0f0d18; color: #fff; padding: 10px 20px 10px 16px; border-radius: 14px;
  border: 1px solid rgba(255,255,255,.18); transition: transform .15s, box-shadow .15s;
  box-shadow: 0 8px 20px rgba(0,0,0,.18);
}
.store-btn:hover { transform: translateY(-2px); box-shadow: 0 12px 26px rgba(0,0,0,.24); }
.store-btn svg { width: 28px; height: 28px; flex: none; }
.store-btn span { display: flex; flex-direction: column; font-weight: 700; font-size: 20px; line-height: 1.05; }
.store-btn small { font-weight: 500; font-size: 12px; opacity: .8; }
.trust { margin-top: 22px; font-size: 16px; color: #dcf7e6; font-weight: 600; }

.hero-visual { position: relative; display: flex; justify-content: center; min-height: 560px; }
.glow { position: absolute; inset: 10% 5%; background: radial-gradient(circle, rgba(255,210,31,.55), transparent 65%); filter: blur(10px); }
.phone {
  position: relative; width: min(300px, 72vw); aspect-ratio: 958 / 2083;
  padding: 12px; border-radius: 52px; background: #14111f;
  box-shadow: var(--shadow-lg), 0 0 0 7px rgba(255,255,255,.18);
  transform: rotate(3deg); animation: float 6s ease-in-out infinite;
}
.phone img { width: 100%; height: 100%; object-fit: cover; border-radius: 41px; }
@keyframes float { 0%,100% { transform: rotate(3deg) translateY(0); } 50% { transform: rotate(3deg) translateY(-12px); } }
.chip {
  position: absolute; background: #fff; color: var(--purple-ink); font-weight: 700; font-size: 17px;
  padding: 10px 18px; border-radius: 999px; box-shadow: 0 12px 28px rgba(20,17,31,.22);
  white-space: nowrap; transform: rotate(-3deg);
}
.chip-1 { left: -4%; bottom: 3%; }
.chip-2 { right: -2%; top: 16%; transform: rotate(4deg); }
.badge-round {
  position: absolute; left: 6%; top: 8%; width: 104px; height: 104px; border-radius: 50%;
  background: var(--yellow); color: var(--purple-ink); display: grid; place-content: center; text-align: center;
  box-shadow: 0 12px 28px rgba(20,17,31,.25); transform: rotate(-10deg); line-height: 1;
}
.badge-round b { font-size: 34px; }
.badge-round span { font-weight: 700; font-size: 15px; text-transform: uppercase; letter-spacing: 1px; }
.spark { position: absolute; color: var(--yellow); font-size: 26px; animation: twinkle 3s ease-in-out infinite; }
.s1 { top: 4%; right: 22%; }
.s2 { bottom: 10%; right: 6%; font-size: 18px; animation-delay: .8s; }
.s3 { bottom: 24%; left: 2%; font-size: 20px; animation-delay: 1.6s; }
@keyframes twinkle { 0%,100% { opacity: 1; transform: scale(1); } 50% { opacity: .4; transform: scale(.7); } }

/* Stats */
.stats { background: var(--surface); border-bottom: 1px solid var(--line); }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { padding: 30px 16px; text-align: center; border-left: 1px solid var(--line); }
.stat:first-child { border-left: 0; }
.stat b { display: block; font-size: clamp(34px, 4vw, 48px); font-weight: 800; color: var(--green-strong); line-height: 1; font-variant-numeric: tabular-nums; }
.stat span { color: var(--muted); font-weight: 600; font-size: 16px; }

/* How */
.how { text-align: center; }
.steps { list-style: none; padding: 0; margin: 48px 0 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; counter-reset: s; }
.step {
  position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: 24px;
  padding: 40px 28px 32px; box-shadow: var(--shadow); text-align: center;
}
.step-num {
  position: absolute; top: -18px; left: 50%; transform: translateX(-50%);
  width: 36px; height: 36px; border-radius: 50%; background: var(--green); color: #fff;
  display: grid; place-items: center; font-weight: 800;
}
.step-emoji { font-size: 48px; line-height: 1; margin-bottom: 14px; }
.step p { margin-top: 8px; color: var(--muted); }

/* Try quiz */
.try { background: linear-gradient(165deg, #2a2160, #4b2f9e); color: #d6ccff; overflow: hidden; }
.try h2 { color: #fff; }
.try-inner { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.try-copy > p { margin-top: 14px; font-size: 20px; }
.ticks { list-style: none; padding: 0; margin: 22px 0 0; display: grid; gap: 10px; }
.ticks li { position: relative; padding-left: 32px; font-weight: 600; }
.ticks li::before {
  content: '✓'; position: absolute; left: 0; top: 2px; width: 22px; height: 22px; border-radius: 50%;
  background: var(--yellow); color: var(--purple-ink); font-size: 13px; font-weight: 800; display: grid; place-items: center;
}
.ticks-dark li { color: var(--ink-2); }
.ticks-dark li::before { background: var(--green-tint); color: var(--green-strong); }

.quiz-card {
  background: var(--cream); color: var(--ink-2); border-radius: 28px; padding: 26px;
  box-shadow: 0 30px 60px rgba(0,0,0,.3), 0 0 0 7px rgba(255,255,255,.12); min-height: 520px;
  display: flex; flex-direction: column;
}
.quiz-head { display: flex; justify-content: space-between; align-items: flex-end; }
.quiz-title { font-weight: 800; color: var(--ink); font-size: 22px; line-height: 1.1; }
.quiz-sub { color: var(--muted); font-size: 15px; }
.quiz-count { font-weight: 700; color: var(--ink-2); font-size: 18px; }
.bar { height: 8px; background: #fff; border-radius: 99px; margin: 12px 0 18px; overflow: hidden; }
.bar span { display: block; height: 100%; width: 20%; background: var(--green); border-radius: inherit; transition: width .4s; }
#quiz-body { display: flex; flex-direction: column; flex: 1; }
.q-box { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px; }
.q-label { font-size: 13px; letter-spacing: 1.2px; text-transform: uppercase; font-weight: 700; color: var(--muted); }
.q-text { font-weight: 700; color: var(--ink); font-size: 21px; line-height: 1.25; margin-top: 4px; }
.options { display: grid; gap: 10px; margin-top: 12px; }
.opt {
  display: flex; align-items: center; gap: 14px; width: 100%; text-align: left;
  background: #fff; border: 1.5px solid var(--line); border-radius: 16px; padding: 10px 14px;
  font: 600 18px/1.25 var(--font); color: var(--ink-2); cursor: pointer; transition: border-color .15s, background .15s, transform .1s;
}
.opt:hover:not(:disabled) { border-color: #86efac; transform: translateY(-1px); }
.opt:disabled { cursor: default; }
.opt .letter {
  flex: none; width: 34px; height: 34px; border-radius: 50%; background: #f1f5f9; display: grid; place-items: center;
  font-weight: 800; font-size: 15px; color: var(--ink-2);
}
.opt.correct { background: #dcfce7; border-color: var(--green); color: var(--green-deep); }
.opt.correct .letter { background: var(--green); color: #fff; }
.opt.wrong { background: #fee2e2; border-color: #ef4444; color: #991b1b; }
.opt.wrong .letter { background: #ef4444; color: #fff; }
.feedback { min-height: 28px; margin-top: 10px; font-weight: 700; font-size: 16px; }
.feedback.good { color: var(--green-strong); }
.feedback.bad { color: #b91c1c; }
.quiz-next { margin-top: auto; width: 100%; }
.quiz-next:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.result { text-align: center; display: flex; flex-direction: column; align-items: center; flex: 1; justify-content: center; gap: 8px; }
.ring {
  --p: 0; width: 150px; height: 150px; border-radius: 50%;
  background: conic-gradient(var(--green) calc(var(--p) * 1%), #e2e8f0 0);
  display: grid; place-items: center; margin-bottom: 8px;
}
.ring > div { width: 118px; height: 118px; border-radius: 50%; background: var(--cream); display: grid; place-content: center; }
.ring b { font-size: 36px; color: var(--ink); line-height: 1; }
.ring small { color: var(--green-strong); font-weight: 700; }
.result h3 { font-size: 28px; }
.points { background: var(--green-tint); color: var(--green-deep); font-weight: 800; padding: 8px 18px; border-radius: 12px; margin: 6px 0 12px; }
.result .store-hint { color: var(--muted); font-size: 16px; margin-bottom: 8px; }

/* Features */
.features { text-align: center; }
.feature {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 88px); align-items: center;
  margin-top: clamp(56px, 8vw, 96px); text-align: left;
}
.feature.reverse .feature-art { order: 2; }
.feature-art {
  border-radius: 32px; overflow: hidden; position: relative; box-shadow: var(--shadow);
  max-width: 380px; justify-self: center; width: 100%;
}
.feature-art img { width: 100%; height: auto; }
.art-green { background: linear-gradient(165deg, #22b35e, #148a43); }
.art-cream { background: linear-gradient(165deg, #fff7ec, #ffe9cc); }
.art-purple { background: linear-gradient(165deg, #2a2160, #4b2f9e); }
.art-sky { background: linear-gradient(165deg, #e3f3ff, #c4e4fb); }
.art-orange { background: linear-gradient(165deg, #ffb347, #ff8a3d); }
.feature-copy h3 { font-size: clamp(30px, 3.6vw, 44px); letter-spacing: -.8px; margin-top: 14px; }
.feature-copy > p { margin-top: 14px; font-size: 20px; color: var(--muted); }
.pill { display: inline-block; font-weight: 700; font-size: 15px; padding: 6px 14px; border-radius: 999px; }
.pill-green { background: #dcfce7; color: #15803d; }
.pill-orange { background: #ffedd5; color: #c2410c; }
.pill-purple { background: #f3e8ff; color: #6d28d9; }
.pill-blue { background: #e0f2fe; color: #035c8c; }
.pill-yellow { background: #fef9c3; color: #854d0e; }

/* Facts */
.facts { background: linear-gradient(165deg, #2a2160, #4b2f9e); color: #d6ccff; overflow: hidden; }
.facts h2 { color: #fff; }
.facts-inner { display: grid; grid-template-columns: .9fr 1.1fr; gap: 56px; align-items: center; position: relative; }
.facts-copy > p { margin-top: 14px; font-size: 20px; }
.fact-controls { display: flex; gap: 12px; margin-top: 26px; }
.f1 { top: 12%; left: 6%; } .f2 { top: 20%; right: 8%; animation-delay: 1s; } .f3 { bottom: 12%; left: 40%; animation-delay: 2s; font-size: 18px; }
.fact-card { background: #fff; border-radius: 28px; overflow: hidden; box-shadow: 0 30px 60px rgba(0,0,0,.3); transition: opacity .25s, transform .25s; }
.fact-card.swap { opacity: 0; transform: translateY(10px) scale(.98); }
.fact-img { aspect-ratio: 16 / 10; background: var(--cream); overflow: hidden; }
.fact-img img { width: 100%; height: 100%; object-fit: cover; }
.fact-body { padding: 22px 26px 28px; color: var(--ink-2); }
.fact-meta { display: flex; justify-content: space-between; align-items: center; color: var(--muted); font-size: 15px; }
.tag { background: #f3e8ff; color: #7e22ce; font-weight: 700; padding: 3px 12px; border-radius: 999px; }
.fact-title-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin: 12px 0 8px; }
.fact-title-row h3 { font-size: 30px; }
.fact-body p { font-size: 19px; }
.speak {
  flex: none; width: 56px; height: 56px; border-radius: 16px; border: 1px solid var(--line); background: #fff;
  box-shadow: 0 4px 0 #e5e0d8; color: var(--ink); cursor: pointer; display: grid; place-items: center;
}
.speak svg { width: 26px; height: 26px; }
.speak.on { background: #f3e8ff; color: #6d28d9; border-color: #d8b4fe; }

/* Subjects */
.subjects { text-align: center; }
.tabs { display: inline-flex; background: #f1f5f9; padding: 5px; border-radius: 16px; margin-top: 26px; gap: 4px; }
.tabs button {
  font: 700 17px/1 var(--font); border: 0; background: transparent; color: var(--muted);
  padding: 12px 22px; border-radius: 12px; cursor: pointer;
}
.tabs button[aria-selected="true"] { background: #fff; color: var(--ink); box-shadow: 0 2px 8px rgba(15,23,42,.08); }
.subject-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 36px; text-align: left; }
.subject {
  display: flex; align-items: center; gap: 16px; background: var(--tint); border-radius: 22px; padding: 16px;
  border: 1px solid color-mix(in srgb, var(--ink-c) 15%, transparent); transition: transform .15s, box-shadow .15s;
  animation: pop .35s ease both;
}
.subject:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.subject img { width: 88px; height: 88px; border-radius: 16px; object-fit: cover; background: #fff; flex: none; }
.subject h3 { color: var(--ink-c); font-size: 24px; }
.subject p { color: var(--ink-2); font-size: 16px; line-height: 1.35; margin-top: 4px; }
@keyframes pop { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* Parents */
.parents { background: var(--cream); text-align: center; }
.parent-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 44px; text-align: left; }
.parent-card { background: #fff; border-radius: 22px; padding: 26px; border: 1px solid #f1e6d6; }
.pc-icon { width: 54px; height: 54px; border-radius: 16px; background: var(--c); display: grid; place-items: center; font-size: 28px; margin-bottom: 14px; }
.parent-card p { margin-top: 8px; color: var(--muted); font-size: 17px; }

/* FAQ */
.faq-inner { display: grid; grid-template-columns: .8fr 1.2fr; gap: 56px; align-items: start; }
.faq-list { display: grid; gap: 12px; }
details { background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 0 22px; transition: box-shadow .2s; }
details[open] { box-shadow: var(--shadow); }
summary {
  list-style: none; cursor: pointer; padding: 18px 0; font-weight: 700; font-size: 20px; color: var(--ink);
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
summary::-webkit-details-marker { display: none; }
summary::after {
  content: '+'; flex: none; width: 32px; height: 32px; border-radius: 50%; background: var(--green-tint); color: var(--green-strong);
  display: grid; place-items: center; font-size: 22px; transition: transform .2s;
}
details[open] summary::after { transform: rotate(45deg); }
details p { padding-bottom: 20px; color: var(--muted); }

/* CTA */
.cta { background: var(--brand-grad); color: #dcf7e6; text-align: center; padding: clamp(72px, 9vw, 110px) 0; position: relative; overflow: hidden; }
.cta::before { content: ''; position: absolute; inset: auto -10% -60% auto; width: 600px; height: 600px; border-radius: 50%; background: rgba(255,255,255,.08); }
.cta-inner { position: relative; display: flex; flex-direction: column; align-items: center; }
.cta-icon { border-radius: 22px; box-shadow: 0 14px 30px rgba(0,0,0,.25); margin-bottom: 22px; }
.cta h2 { color: #fff; max-width: 720px; }
.cta p { margin-top: 14px; font-size: 20px; }

/* Footer */
.footer { background: #0f0d18; color: #a39fb8; padding: 40px 0; }
.footer .brand { color: #fff; font-size: 22px; }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; }
.footer nav { display: flex; flex-wrap: wrap; gap: 22px; }
.footer nav a { color: #d6d3e3; text-decoration: none; font-weight: 600; font-size: 16px; }
.footer nav a:hover { color: #fff; }
.copy { font-size: 15px; width: 100%; }

/* Scroll reveal */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }

/* Responsive */
@media (max-width: 960px) {
  .nav-links { display: none; }
  .hero-inner, .try-inner, .facts-inner, .faq-inner { grid-template-columns: 1fr; }
  .hero-copy { text-align: center; }
  .hero-copy .lede { margin-inline: auto; }
  .store-row { justify-content: center; }
  .hero-visual { min-height: 520px; margin-top: 20px; }
  .subject-grid, .parent-grid { grid-template-columns: repeat(2, 1fr); }
  .feature, .feature.reverse { grid-template-columns: 1fr; }
  .feature.reverse .feature-art { order: 0; }
  .feature-copy { text-align: center; }
  .feature-copy .ticks, .try-copy .ticks { width: fit-content; margin-inline: auto; text-align: left; }
  .try-copy, .facts-copy { text-align: center; }
  .fact-controls { justify-content: center; }
}
@media (max-width: 640px) {
  body { font-size: 17px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(3) { border-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
  .steps, .subject-grid, .parent-grid { grid-template-columns: 1fr; }
  .steps { gap: 36px; }
  .chip { font-size: 14px; padding: 8px 14px; }
  .chip-1 { left: 0; }
  .chip-2 { right: 0; }
  .badge-round { width: 84px; height: 84px; left: 2%; }
  .badge-round b { font-size: 26px; }
  .quiz-card { padding: 18px; min-height: 500px; }
  .fact-title-row h3 { font-size: 24px; }
  .nav .btn-sm { padding: 9px 14px; font-size: 15px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; }
}
