/* ============================================================
   home.css, Candela Learnings
   Home page only. Loads after css/site.css.
   ============================================================ */

/* ── hero ── */
.hero { padding-block: clamp(24px, 4vw, 48px); min-height: calc(100svh - var(--nav-h)); display: flex; align-items: center; }
.hero-grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: clamp(24px, 4vw, 64px); align-items: center; }
.hero-title { font-size: clamp(3rem, 7.4vw, 6.4rem); font-weight: 800; letter-spacing: -0.035em; line-height: 0.93; }
.hero-title em { font-style: normal; color: var(--flame-ink); }
html[lang="ml"] .hero-title { font-size: clamp(2.6rem, 6vw, 5rem); line-height: 1.12; }
.hero-sub { margin-top: 28px; font-size: 1.2rem; max-width: 30em; color: var(--ink-2); }
.hero-meta { margin-top: 26px; font-size: 0.92rem; color: var(--ink-2); }
.hero-art { position: relative; }


/* 3D kit (Three.js, see js/kit3d.js) */
.kit3d { position: relative; width: 100%; aspect-ratio: 1.12; max-height: calc(100svh - var(--nav-h) - 80px); margin-inline: auto; }
.kit3d canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; opacity: 0; transition: opacity .7s var(--ease-out); }
.kit3d.is-ready canvas { opacity: 1; }
/* The poster only shows if the 3D scene is slow to start, or cannot start. */
.kit-poster { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; opacity: 0; animation: posterIn .4s 1.4s forwards; }
@keyframes posterIn { to { opacity: 1; } }
.kit3d.is-ready .kit-poster { display: none; }
.kit3d.is-fallback .kit-poster { opacity: 1; animation: none; }
.kit3d.is-fallback canvas { display: none; }
.kit3d-labels { position: absolute; inset: 0; pointer-events: none; }
.kit3d-label {
  position: absolute; left: 0; top: 0; opacity: 0; white-space: nowrap;
  font-family: var(--f-display); font-size: 0.86rem; font-weight: 650; letter-spacing: 0;
  padding: 5px 10px; background: var(--paper); border: 1.5px solid var(--ink); border-radius: var(--r);
}
.kit-hint { margin-top: 6px; text-align: center; font-size: 0.88rem; color: var(--ink-2); visibility: hidden; }
.kit-anim .kit-hint { visibility: visible; }

/* ── inside the kit ── */
.inside { padding-block: clamp(64px, 9vw, 128px); border-top: var(--line); background: var(--paper); }
.inside-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 96px); }
.stage {
  position: sticky; top: calc(var(--nav-h) + 24px);
  height: min(560px, calc(100vh - var(--nav-h) - 48px));
  display: flex; flex-direction: column; gap: 14px;
}
.stage-box {
  position: relative; flex: 1;
  background: var(--kraft-lt); border: var(--line); border-radius: var(--r);
  overflow: hidden;
}
.prop {
  position: absolute; inset: 0; display: grid; place-items: center; padding: 24px;
  opacity: 0; transform: translateY(40px) rotate(-4deg);
  transition: opacity .45s var(--ease-out), transform .6s var(--ease-out);
  pointer-events: none;
}
.stage[data-active="0"] .prop-badge,
.stage[data-active="1"] .prop-week,
.stage[data-active="2"] .prop-book,
.stage[data-active="3"] .prop-parcel { opacity: 1; transform: none; }
.stage-count { display: flex; gap: 6px; font-size: 0.78rem; }
.stage-count li { position: relative; flex: 1; padding-top: 8px; border-top: 3px solid var(--ink-soft); color: var(--ink-2); transition: color .3s; }
.stage-count .bar { position: absolute; left: 0; right: 0; top: -3px; height: 3px; background: var(--flame); transform: scaleX(0); transform-origin: left; }
.no-motion .stage-count .bar { display: none; }
.stage[data-active="0"] .stage-count li:nth-child(1),
.stage[data-active="1"] .stage-count li:nth-child(2),
.stage[data-active="2"] .stage-count li:nth-child(3),
.stage[data-active="3"] .stage-count li:nth-child(4) { color: var(--ink); }
.no-motion .stage[data-active="0"] .stage-count li:nth-child(-n+1),
.no-motion .stage[data-active="1"] .stage-count li:nth-child(-n+2),
.no-motion .stage[data-active="2"] .stage-count li:nth-child(-n+3),
.no-motion .stage[data-active="3"] .stage-count li:nth-child(-n+4) { border-color: var(--flame); }

/* badge */
.prop-badge { align-content: start; padding-top: 0; }
.lanyard { width: 64px; height: 56px; border-inline: 6px solid var(--flame); margin-inline: auto; }
.badge {
  width: min(250px, 70%); background: var(--paper); border: var(--line); border-radius: 6px;
  overflow: hidden; transform: rotate(-3deg); transform-origin: top center;
}
.badge-top { background: var(--ink); color: var(--paper); text-align: center; font-size: 0.78rem; letter-spacing: 0.24em; padding: 10px 0; }
.badge img { width: 100%; aspect-ratio: 1; object-fit: cover; object-position: top; background: var(--kraft-lt); border-bottom: var(--line); }
.badge-foot { display: flex; justify-content: space-between; align-items: baseline; padding: 10px 14px 12px; font-family: var(--f-display); font-weight: 600; font-size: 0.95rem; }
.badge-foot .mono { font-size: 0.72rem; color: var(--flame-ink); }

/* week */
.week { width: min(340px, 90%); background: var(--paper); border: var(--line); border-radius: var(--r); transform: rotate(2deg); }
.week-head { padding: 12px 16px; border-bottom: var(--line); font-size: 0.78rem; letter-spacing: 0.2em; }
.week-days li { display: grid; grid-template-columns: 48px 1fr auto; align-items: center; gap: 10px; padding: 11px 16px; border-bottom: 1px solid var(--kraft); }
.week-days li:last-child { border-bottom: 0; }
.week-days span { font-size: 0.75rem; color: var(--ink-2); }
.week-days b { font-family: var(--f-display); font-weight: 600; }
.missed b { text-decoration: line-through; text-decoration-color: var(--ink-soft); }
.tag { font-style: normal; font-family: var(--f-mono); font-size: 0.68rem; font-weight: 600; letter-spacing: 0.1em; padding: 3px 7px; border: 1.5px solid var(--ink); border-radius: var(--r); }
.tag-live { background: var(--flame); }
.tag-rec { background: var(--ink); color: var(--paper); }

/* notebook */
.book { position: relative; transform: rotate(-4deg); }
.book-cover {
  position: relative; width: 230px; height: 300px; background: var(--ink); color: var(--paper);
  border-radius: 2px 6px 6px 2px;
  padding: 28px 22px 28px 40px; display: flex; flex-direction: column;
}
.book-cover::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 18px; background: var(--flame); border-radius: 2px 0 0 2px; }
.book-kicker { font-size: 0.7rem; letter-spacing: 0.3em; color: var(--flame); }
.book-title { font-family: var(--f-display); font-weight: 750; font-size: 2.1rem; line-height: 1; margin-top: 16px; }
.book-ch { margin-top: auto; font-size: 0.72rem; letter-spacing: 0.16em; color: var(--ink-soft); }
.book-tabs { position: absolute; right: -30px; top: 40px; display: flex; flex-direction: column; gap: 6px; }
.book-tabs li {
  writing-mode: vertical-rl; font-size: 0.62rem; letter-spacing: 0.14em; padding: 10px 5px;
  border: var(--line); border-left: 0; border-radius: 0 3px 3px 0; background: var(--paper);
}
.book-tabs li:nth-child(odd) { background: var(--flame); }

/* parcel: a render of the same 3D kit box, delivered */
.parcel { position: relative; width: min(490px, 100%); }
.parcel-img { width: 100%; height: auto; }
.parcel-tag {
  position: absolute; left: 2%; bottom: -4%;
  display: flex; flex-direction: column; gap: 4px;
  padding: 12px 16px 12px 30px; min-width: 190px;
  background: var(--paper); border: 1.5px solid var(--ink); border-radius: var(--r);
  transform: rotate(-4deg);
}
.parcel-tag::before {
  content: ""; position: absolute; left: 11px; top: 50%; width: 9px; height: 9px; margin-top: -4.5px;
  border: 1.5px solid var(--ink); border-radius: 50%; background: var(--kraft-lt);
}
.parcel-tag-k { font-size: 0.62rem; letter-spacing: 0.18em; color: var(--flame-ink); }
.parcel-tag-to { font-family: var(--f-display); font-weight: 700; font-size: 1.15rem; line-height: 1.1; }
.parcel-tag-from { font-size: 0.68rem; letter-spacing: 0.02em; color: var(--ink-2); }

/* steps */
.steps li { min-height: 72vh; display: flex; flex-direction: column; justify-content: center; padding-block: 24px; opacity: .3; transition: opacity .4s; }
.steps li.is-active { opacity: 1; }
.steps li:first-child { min-height: 56vh; justify-content: flex-start; padding-top: 24px; }
.step-term { font-weight: 600; color: var(--ink); }
.steps h3 { font-size: clamp(1.8rem, 3.2vw, 2.7rem); font-weight: 720; margin-bottom: 18px; }
.steps p:not(.step-num) { font-size: 1.15rem; color: var(--ink-2); max-width: 28em; }

/* ── video ── */
.film { padding-block: clamp(64px, 8vw, 112px); border-top: var(--line); background: var(--paper-2); }
.film-grid { display: grid; grid-template-columns: 1fr 1.5fr; gap: clamp(28px, 5vw, 72px); align-items: center; }
.film-copy p { margin-top: 20px; color: var(--ink-2); font-size: 1.1rem; }
.film-frame { aspect-ratio: 16 / 9; border: var(--line); border-radius: var(--r); overflow: hidden; background: var(--ink); }
.film-frame iframe { width: 100%; height: 100%; border: 0; display: block; }
.film-play { position: relative; width: 100%; height: 100%; padding: 0; border: 0; cursor: pointer; background: var(--ink); display: block; }
.film-play img { width: 100%; height: 100%; object-fit: cover; }
.film-btn {
  position: absolute; left: 20px; bottom: 20px;
  display: inline-flex; align-items: center; gap: 10px; min-height: 52px; padding: 0 20px 0 16px;
  background: var(--flame); color: var(--ink); border: var(--line); border-radius: var(--r);
  font-family: var(--f-display); font-weight: 650; transition: background-color .15s, color .15s;
}
.film-btn svg { width: 22px; height: 22px; fill: currentColor; }
.film-play:hover .film-btn { background: var(--paper); }

/* ── mock test ── */
.mock { padding-block: clamp(64px, 9vw, 128px); background: var(--ink); color: var(--paper); }
.mock-grid { display: grid; grid-template-columns: 1fr 1.35fr; gap: clamp(32px, 6vw, 88px); align-items: start; }
.mock-head { position: sticky; top: calc(var(--nav-h) + 32px); }
.mock .mock-head p:not(.mock-note) { margin-top: 20px; color: var(--ink-soft); font-size: 1.1rem; }
.mock-head p.mock-note { font-size: 0.88rem; margin-top: 28px; padding-top: 16px; border-top: 1px solid #3A3F5C; }
.sheet { position: relative; background: var(--paper); color: var(--ink); border-radius: var(--r); padding: 0 clamp(18px, 3vw, 36px) clamp(18px, 3vw, 32px); }
.sheet-top { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 16px 0; border-bottom: 2px solid var(--ink); font-size: 0.75rem; letter-spacing: 0.05em; }
.q { padding: 26px 0; border-bottom: 1.5px dashed var(--kraft-dk); }
.q legend { padding: 0; float: left; width: 100%; }
.q .opts { clear: both; margin-top: 0; padding-top: 16px; }
.q-sec { display: block; font-size: 0.75rem; color: var(--flame-ink); margin-bottom: 8px; }
.q-text { display: block; font-family: var(--f-display); font-weight: 600; font-size: 1.25rem; line-height: 1.3; }
.opts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; }
.opts label {
  position: relative; display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 8px 14px;
  border: 1.5px solid var(--kraft); border-radius: var(--r); cursor: pointer; font-weight: 500;
  transition: border-color .15s, background-color .15s;
}
.opts label:hover { border-color: var(--ink); }
.opts input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.opts label:has(input:focus-visible) { outline: 3px solid var(--flame); outline-offset: 2px; }
.bubble {
  position: relative; flex-shrink: 0; width: 30px; height: 30px; border-radius: 50%; border: 1.5px solid var(--ink);
  display: grid; place-items: center; font-family: var(--f-mono); font-size: 0.8rem; font-weight: 600;
  transition: background-color .2s, color .2s, transform .25s var(--ease-out);
}
.q.is-done .opts label { cursor: default; }
.q.is-done .opts label:hover { border-color: var(--kraft); }
.opts label.is-right { border-color: var(--ink); }
.opts label.is-wrong { color: var(--ink-2); }
.opts label.is-wrong > span:last-child { text-decoration: line-through; }
.q-why { margin-top: 14px; color: var(--ink-2); }
.q-verdict { color: var(--ink); }
.result { position: relative; padding-top: 28px; }
.result-score { font-family: var(--f-display); font-weight: 750; font-size: clamp(1.8rem, 3.4vw, 2.6rem); line-height: 1.1; margin-bottom: 12px; padding-right: 120px; }
.result-score:focus { outline: none; }
.result > p:not(.result-score) { color: var(--ink-2); max-width: 32em; }
.result-cta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 24px; }
.stamp {
  position: absolute; right: 0; top: 18px;
  border: 3px solid var(--flame-ink); color: var(--flame-ink); border-radius: var(--r);
  padding: 8px 12px; font-size: 0.95rem; font-weight: 600; letter-spacing: 0.2em;
  transform: rotate(-9deg);
}
.result.is-shown .stamp { animation: stamp .5s var(--ease-out) both; }
@keyframes stamp {
  0% { opacity: 0; transform: rotate(-9deg) scale(1.8); }
  60% { opacity: 1; transform: rotate(-9deg) scale(.94); }
  100% { opacity: 1; transform: rotate(-9deg) scale(1); }
}

/* ── tutor wall ── */
.tutors { padding-top: clamp(64px, 9vw, 128px); background: var(--paper); overflow: hidden; }
.shelf { position: relative; max-width: 1320px; margin-inline: auto; padding-inline: 24px; }
.shelf-edge { height: 22px; background: var(--kraft); border-top: 2px solid var(--ink); border-bottom: 2px solid var(--ink); transform-origin: left center; }
.shelf-row { display: flex; align-items: flex-end; justify-content: center; overflow: hidden; padding-top: 5%; }
.shelf-row li { flex: 1 1 0; min-width: 0; margin-inline: -1.4%; }
.shelf-row li:nth-child(even) { margin-bottom: 0; }
.shelf-row li:nth-child(2) { transform: scale(1.04); transform-origin: bottom; z-index: 1; }
.shelf-row li:nth-child(5) { transform: scale(1.03); transform-origin: bottom; z-index: 1; }
.shelf-row img { width: 100%; height: auto; }

/* ── app ── */
.app { padding-block: clamp(64px, 9vw, 128px); background: var(--paper-2); border-top: var(--line); }
.app-grid { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: clamp(28px, 6vw, 96px); align-items: center; }
.phone {
  width: min(320px, 80%); margin-inline: auto; aspect-ratio: 132 / 270;
  background: var(--ink); border-radius: 46px; padding: 13px; position: relative;
}
.phone::before, .phone::after { content: ""; position: absolute; background: var(--ink); border-radius: 2px; width: 4px; }
.phone::before { left: -4px; top: 22%; height: 9%; }
.phone::after { right: -4px; top: 26%; height: 12%; }
.phone-screen { width: 100%; height: 100%; border-radius: 34px; overflow: hidden; background: #fbfbfb; }
.phone-screen img { width: 100%; height: 100%; object-fit: cover; }
.app-copy > p { margin-top: 20px; font-size: 1.15rem; color: var(--ink-2); max-width: 30em; }
.app-list { display: grid; grid-template-columns: 1fr 1fr; column-gap: 28px; margin-top: 32px; }
.app-list li { padding: 14px 0; border-top: var(--line); font-family: var(--f-display); font-weight: 600; font-size: 1.1rem; }
.stores { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.store {
  display: inline-flex; align-items: center; gap: 12px; min-height: 56px; padding: 0 20px 0 16px;
  background: var(--ink); color: var(--paper); text-decoration: none; border: var(--line); border-radius: var(--r);
  font-family: var(--f-display); font-weight: 650; font-size: 1.05rem; line-height: 1.1;
  transition: background-color .15s, color .15s;
}
.store small { display: block; font-family: var(--f-body); font-weight: 400; font-size: 0.72rem; opacity: .8; }
.store svg { width: 24px; height: 24px; fill: currentColor; }
.store:hover { background: var(--flame); color: var(--ink); }

/* ── words ── */
.words { padding-block: clamp(64px, 9vw, 128px); background: var(--paper-2); border-top: var(--line); }
.words-grid { display: grid; grid-template-columns: 1.25fr 1fr; grid-template-rows: auto auto; column-gap: clamp(28px, 5vw, 72px); }
.quote { margin: 0; padding-block: 28px; border-top: var(--line); }
.quote blockquote { margin: 0; font-size: 1.1rem; }
.quote-lead { grid-row: span 2; }
.quote-lead blockquote { font-family: var(--f-display); font-weight: 550; font-size: clamp(1.45rem, 2.5vw, 2rem); line-height: 1.3; letter-spacing: -0.01em; }
.quote figcaption { margin-top: 18px; display: flex; gap: 10px; flex-wrap: wrap; align-items: baseline; }
.quote figcaption b { font-family: var(--f-display); }
.quote figcaption span { font-size: 0.9rem; color: var(--ink-2); }

/* ── streak candles (daily teaser) ── */
.candle-wax { fill: var(--paper); stroke: var(--ink); stroke-width: 1.4; }
.candle-wick { stroke: var(--ink); stroke-width: 1.4; stroke-linecap: round; }
.fl-out { fill: var(--flame); }
.fl-in { fill: #FFC94D; }
.candle-flame { transform-origin: 12px 17px; transition: transform .7s cubic-bezier(.16, 1, .3, 1); }
.streak-days .is-on .fl-out { transform-origin: 12px 17px; animation: flicker 2.6s ease-in-out infinite; }
@keyframes flicker { 0%, 100% { transform: scale(1, 1) skewX(0); } 30% { transform: scale(.96, 1.04) skewX(-2deg); } 60% { transform: scale(1.03, .97) skewX(1.5deg); } }

/* ── share ── */
.btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.btn-ink { background: var(--ink); color: var(--paper); }
.btn-ink:hover { background: var(--flame); color: var(--ink); }
.btn:disabled { opacity: .55; cursor: progress; }
.share { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; margin-top: 22px; padding-top: 20px; border-top: 1.5px dashed var(--kraft-dk); }
.share-note { font-size: 0.92rem; color: var(--ink-2); max-width: 34em; }
.share-note:empty { display: none; }

/* ── daily teaser ── */
.teaser { padding-block: clamp(64px, 9vw, 120px); border-top: var(--line); background: var(--paper); }
.teaser-grid { display: grid; grid-template-columns: 1fr 1.15fr; gap: clamp(32px, 6vw, 88px); align-items: start; }
.teaser-head .lede { margin-top: 18px; }
.streak { margin-top: 32px; }
.streak-days { display: flex; gap: 12px; }
.streak-days svg { width: 22px; height: 37px; overflow: visible; }
.streak-days li { display: grid; justify-items: center; gap: 6px; font-size: 0.78rem; color: var(--ink-2); }
.streak-days .candle-flame { transform: scale(0); }
.streak-days .is-on .candle-flame { transform: scale(1); }
.streak-days .is-today .candle-wax { stroke: var(--flame-ink); stroke-width: 2; }
.streak-days .is-today span { color: var(--ink); font-weight: 600; }
.streak-days .is-lighting .candle-flame { animation: lightUp .9s cubic-bezier(.16, 1, .3, 1) both; }
@keyframes lightUp { from { transform: scale(0); } }
.streak-text { margin-top: 14px; font-weight: 500; }
.teaser-card { background: #FBF8F1; border: var(--line); border-radius: var(--r); padding: 0 clamp(18px, 3vw, 32px) clamp(18px, 3vw, 28px); }
.teaser-top { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 14px 0; border-bottom: 2px solid var(--ink); font-size: 0.78rem; letter-spacing: 0.02em; }
.tq { padding: 22px 0 4px; border-bottom: 0; }
.teaser-next { margin-top: 16px; padding-top: 14px; border-top: 1.5px dashed var(--kraft-dk); font-size: 0.92rem; color: var(--ink-2); }

/* ── example progress report ── */
.report { padding-block: clamp(64px, 9vw, 128px); background: var(--paper-2); border-top: var(--line); }
.report-grid { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: clamp(32px, 6vw, 88px); align-items: start; }
.report-head .lede { margin-top: 18px; }
.rcard { background: #FBF8F1; border: var(--line); border-radius: var(--r); padding: clamp(18px, 3vw, 32px); }
.rcard-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; padding-bottom: 16px; border-bottom: 2px solid var(--ink); }
.rcard-top h3 { font-size: 1.45rem; font-weight: 750; }
.rcard-who { display: block; margin-top: 6px; font-family: var(--f-body); font-size: 0.95rem; font-weight: 400; letter-spacing: 0; color: var(--ink-2); }
.rcard-stamp { flex-shrink: 0; padding: 6px 10px; border: 2px solid var(--red); border-radius: var(--r); color: var(--red); font-size: 0.82rem; font-weight: 600; transform: rotate(-3deg); }
.chart { margin: 20px 0 0; }
.chart-cap { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 8px 16px; font-size: 0.92rem; color: var(--ink-2); }
.legend { display: inline-flex; flex-wrap: wrap; gap: 6px 16px; }
.legend .key { display: inline-flex; align-items: center; gap: 7px; color: var(--ink); font-weight: 500; }
.legend i { width: 18px; height: 3px; border-radius: 2px; }
.chart-plot { position: relative; margin-top: 10px; }
.chart-plot svg { display: block; width: 100%; height: auto; overflow: visible; touch-action: pan-y; }
.chart-plot .grid { stroke: #DDD2BE; stroke-width: 1; }
.chart-plot .tick { fill: var(--ink-2); font-family: var(--f-body); font-size: 13px; }
.chart-plot .line { fill: none; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset 1.3s cubic-bezier(.3, .7, .2, 1); transition-delay: calc(var(--k) * .15s); }
.chart-plot .is-drawn .line { stroke-dashoffset: 0; }
.chart-plot .dot { stroke: #FBF8F1; stroke-width: 2; opacity: 0; transform-box: fill-box; transform-origin: center; transition: opacity .3s, transform .2s; transition-delay: var(--d), 0s; }
.chart-plot .is-drawn .dot { opacity: 1; }
.chart-plot .dot.is-hot { transform: scale(1.45); }
.chart-plot .end { fill: var(--ink); font-family: var(--f-body); font-size: 14px; font-weight: 500; opacity: 0; transition: opacity .4s 1.2s; }
.chart-plot .is-drawn .end { opacity: 1; }
.chart-plot .end-v { font-weight: 700; }
.chart-plot .crosshair { stroke: var(--ink-2); stroke-width: 1; stroke-dasharray: 3 3; }
.chart-plot .hit { fill: transparent; }
.chart-tip {
  position: absolute; top: 4px; display: grid; gap: 3px; min-width: 150px;
  padding: 8px 10px; background: var(--paper); border: 1.5px solid var(--ink); border-radius: var(--r);
  font-size: 0.86rem; pointer-events: none;
}
.chart-tip span { display: flex; align-items: center; gap: 7px; }
.chart-tip i { width: 10px; height: 10px; border-radius: 2px; }
.chart-tip span b { margin-left: auto; padding-left: 12px; }
.chart-table { margin-top: 12px; font-size: 0.9rem; }
.chart-table summary { cursor: pointer; color: var(--ink-2); text-decoration: underline; text-underline-offset: 3px; width: fit-content; }
.chart-table table { margin-top: 10px; width: 100%; border-collapse: collapse; }
.chart-table th, .chart-table td { padding: 6px 10px; border-bottom: 1px solid var(--kraft); text-align: right; }
.chart-table th:first-child { text-align: left; }
.rcard-foot { display: grid; grid-template-columns: 1fr 1.4fr; gap: 24px; margin-top: 22px; padding-top: 20px; border-top: 1.5px dashed var(--kraft-dk); }
.attend-label { font-size: 0.92rem; color: var(--ink-2); }
.attend-val { margin-top: 2px; }
.attend-val b { font-family: var(--f-display); font-size: 2.4rem; font-weight: 750; line-height: 1; }
.attend-val span { color: var(--ink-2); font-size: 1.1rem; }
.meter { margin-top: 10px; height: 10px; background: var(--kraft-lt); border: 1px solid var(--ink); border-radius: var(--r); overflow: hidden; }
.meter i { display: block; height: 100%; background: var(--ink); transform: scaleX(0); transform-origin: left; transition: transform 1.3s cubic-bezier(.3, .7, .2, 1) .3s; }
.tnote { margin: 0; }
.tnote p { font-size: 1.05rem; }
.tnote footer { margin-top: 8px; font-size: 0.86rem; color: var(--ink-2); }

/* ── find your class ── */
.find { padding-block: clamp(64px, 9vw, 128px); border-top: var(--line); background: var(--paper); }
.find-grid { display: grid; grid-template-columns: 1fr 1.15fr; gap: clamp(32px, 6vw, 88px); align-items: start; }
.find-head .lede { margin-top: 18px; }
.seg { margin-top: 28px; }
.seg + .seg { margin-top: 22px; }
.seg legend { padding: 0; margin-bottom: 10px; font-weight: 600; }
.seg-row { display: flex; flex-wrap: wrap; gap: 8px; }
.seg-row label { position: relative; cursor: pointer; }
.seg-row input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.seg-row span {
  display: grid; place-items: center; min-width: 50px; height: 50px; padding: 0 12px;
  border: 1.5px solid var(--ink); border-radius: var(--r);
  font-family: var(--f-display); font-weight: 650; font-size: 1.1rem;
  transition: background-color .15s, color .15s;
}
.seg-row label:hover span { background: var(--paper-2); }
.seg-row input:checked + span { background: var(--ink); color: var(--paper); }
.seg-row label:has(input:focus-visible) span { outline: 3px solid var(--flame); outline-offset: 2px; }
.seg-wide span { min-width: 130px; padding: 0 18px; }
.find-out { background: #FBF8F1; border: var(--line); border-radius: var(--r); padding: clamp(20px, 3vw, 36px); }
.find-out h3 { font-size: clamp(1.8rem, 3vw, 2.5rem); font-weight: 760; }
.find-desc { margin-top: 14px; font-size: 1.08rem; color: var(--ink-2); max-width: 36em; }
.find-feats { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.find-feats li { padding: 6px 11px; border: 1.5px solid var(--kraft-dk); border-radius: var(--r); font-size: 0.92rem; }
.find-meta { margin-top: 18px; font-size: 0.9rem; color: var(--ink-2); }
.find-extra { margin-top: 8px; font-size: 0.95rem; }
.find-extra.is-full { padding: 10px 12px; border: 1.5px solid var(--red); border-radius: var(--r); color: var(--red); font-weight: 500; }
.find-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.find-out.is-swap > * { animation: swapIn .5s cubic-bezier(.2, .8, .2, 1) both; }
.find-out.is-swap > :nth-child(2) { animation-delay: .04s; }
.find-out.is-swap > :nth-child(3) { animation-delay: .08s; }
.find-out.is-swap > :nth-child(n+4) { animation-delay: .12s; }
@keyframes swapIn { from { opacity: 0; transform: translateY(10px); } }

/* ── 3D kit: tap to inspect ── */
.kit3d canvas { touch-action: pan-y; cursor: grab; }
.kit3d canvas.is-dragging { cursor: grabbing; }
.kit3d-info {
  position: absolute; left: 0; top: 0; z-index: 2; display: grid; gap: 3px; width: max-content; max-width: 250px;
  padding: 10px 12px; background: var(--paper); border: 1.5px solid var(--ink); border-radius: var(--r);
  pointer-events: none;
}
.kit3d-info b { font-family: var(--f-display); font-size: 1.05rem; font-weight: 700; }
.kit3d-info span { font-size: 0.88rem; color: var(--ink-2); }

/* ── tutor cards (active once names are filled in) ── */
.tutor { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: pointer; perspective: 900px; position: relative; }
.tutor-face, .tutor-back { display: block; backface-visibility: hidden; transition: transform .7s cubic-bezier(.3, .7, .2, 1); }
.tutor-back {
  position: absolute; inset: 14% 8% 0; display: grid; align-content: center; gap: 6px; padding: 14px; text-align: center;
  background: var(--paper); border: var(--line); border-radius: var(--r); transform: rotateY(180deg);
}
.tutor[aria-pressed="true"] .tutor-face { transform: rotateY(-180deg); }
.tutor[aria-pressed="true"] .tutor-back { transform: rotateY(0); }
.tutor-back b { font-family: var(--f-display); font-size: 1.1rem; }
.tutor-subj { color: var(--flame-ink); font-weight: 600; font-size: 0.9rem; }
.tutor-hello { font-size: 0.86rem; color: var(--ink-2); }

/* ── scroll motion ── */
/* Tilted or zoomed pieces must never create sideways scroll. clip, unlike
   hidden, keeps position: sticky working inside these sections. */
.hero, .inside, .film, .mock, .tutors, .app, .join, .words { overflow-x: clip; }




.js .q .bubble { transform: scale(0); }
.js .q.is-in .bubble { animation: pop .45s var(--ease-out) forwards; }
.js .q.is-in label:nth-child(2) .bubble { animation-delay: .07s; }
.js .q.is-in label:nth-child(3) .bubble { animation-delay: .14s; }
.js .q.is-in label:nth-child(4) .bubble { animation-delay: .21s; }
@keyframes pop { 0% { transform: scale(0); } 70% { transform: scale(1.15); } 100% { transform: scale(1); } }
.opts input:checked + .bubble { animation: none; }

.lead-w { transition: none; }

/* ── responsive ── */

@media (max-width: 900px) {

  .hero-grid { grid-template-columns: 1fr; }
  .hero-art { max-width: 520px; margin-inline: auto; width: 100%; order: -1; margin-bottom: -8px; }
  .hero { padding-top: 16px; min-height: 0; }

  .inside-grid { grid-template-columns: 1fr; gap: 0; }
  .stage {
    top: calc(var(--nav-h) + 8px); z-index: 2;
    height: 46vh; min-height: 330px;
    background: var(--paper); padding-bottom: 12px;
  }
  .prop { padding: 12px; }
  .badge { width: min(140px, 46%); }
  .badge-top { font-size: 0.62rem; padding: 6px 0; }
  .badge-foot { font-size: 0.78rem; padding: 6px 10px 8px; }
  .lanyard { height: 18px; width: 44px; border-inline-width: 4px; }
  .book-cover { width: 170px; height: 220px; padding: 20px 16px 20px 32px; }
  .book-cover::before { width: 14px; }
  .book-title { font-size: 1.6rem; }
  .week { transform: rotate(1deg) scale(.86); }
  .parcel-tag { min-width: 0; padding: 7px 10px 7px 24px; bottom: -8%; }
  .parcel-tag::before { left: 8px; width: 7px; height: 7px; margin-top: -3.5px; }
  .parcel-tag-to { font-size: 0.9rem; }
  .parcel-tag-from { font-size: 0.58rem; }
  .parcel-tag-k { font-size: 0.52rem; }
  .steps li, .steps li:first-child { min-height: 52vh; justify-content: center; padding-top: 24px; }

  .film-grid, .mock-grid, .app-grid { grid-template-columns: 1fr; }
  .mock-head { position: static; }
  .teaser-grid, .report-grid, .find-grid { grid-template-columns: 1fr; }
  .app-shot { order: 1; }
  .app-shot img { max-width: 280px; }

  .shelf { padding-inline: 0; }
  .shelf-row { overflow-x: auto; justify-content: flex-start; scroll-snap-type: x mandatory; padding-inline: 16px; scrollbar-width: none; }
  .shelf-row::-webkit-scrollbar { display: none; }
  .shelf-row li { flex: 0 0 42%; margin-inline: -2%; scroll-snap-align: center; }


  .words-grid { grid-template-columns: 1fr; }
  .quote-lead { grid-row: auto; }
}

@media (max-width: 560px) {
  .opts { grid-template-columns: 1fr; }
  .rcard-foot { grid-template-columns: 1fr; }
  .seg-row span { min-width: 44px; height: 46px; }
  .seg-wide span { min-width: 0; }
  .result-score { padding-right: 0; padding-top: 48px; }
}

@media (prefers-reduced-motion: reduce) {
    .js .q .bubble { transform: none; }
  .candle-flame, .fl-out { animation: none !important; }
  .chart-plot .line { stroke-dashoffset: 0; }
  .chart-plot .dot, .chart-plot .end { opacity: 1; }
  .meter i { transition: none; }
  .prop { transform: none; }
}
