/* Layout: one long valley walk — sky (hero) down through the village to the Story Wall at the bottom. Single soft-light theme by design: pastel, low-contrast backgrounds gentle on young eyes. */
:root {
  color-scheme: light;
  --frost: #eef5fb;        /* page ground, pale ice blue */
  --snow: #fbfdff;         /* cards */
  --ink: #3b3f5c;          /* text, soft navy, never pure black */
  --ink-soft: #6b6f8e;
  --lilac: #c9b8ec;        /* iceberry glow, the show's accent */
  --lilac-deep: #7b62b8;
  --mint: #cdeedd;
  --peach: #ffd9c7;
  --butter: #fff0b8;
  --sky: #cfe3f7;
  --honey: #d9a36a;
  --line: #dde6f1;
  --display: "Fredoka", "Baloo 2", "Arial Rounded MT Bold", "Trebuchet MS", sans-serif;
  --body: "Nunito", "Segoe UI", system-ui, -apple-system, sans-serif;
  --radius: 28px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
@media (max-width: 760px) { html { scroll-padding-top: 100px; } }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation: none !important; transition: none !important; } }
body { margin: 0; background: var(--frost); color: var(--ink); font-family: var(--body); font-size: 1.0625rem; line-height: 1.65; }
img { max-width: 100%; display: block; }
a { color: var(--lilac-deep); }
a:focus-visible, button:focus-visible { outline: 3px solid var(--lilac-deep); outline-offset: 3px; border-radius: 8px; }
h1, h2, h3 { font-family: var(--display); font-weight: 600; line-height: 1.15; text-wrap: balance; margin: 0; color: var(--ink); }
h2 { font-size: clamp(1.9rem, 4.5vw, 2.75rem); }
h3 { font-size: 1.35rem; }
p { margin: 0; }
.wrap { max-width: 1120px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.eyebrow { font-family: var(--display); font-weight: 600; font-size: .85rem; letter-spacing: .12em; text-transform: uppercase; color: var(--lilac-deep); }
.lede { color: var(--ink-soft); font-size: 1.15rem; max-width: 60ch; }
section { padding-block: clamp(56px, 9vw, 104px); }
.sec-head { display: grid; gap: 12px; margin-bottom: 40px; max-width: 720px; }

/* NAV */
.nav { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: rgba(238,245,251,.88); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 30; background: var(--frost); }
.nav .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 12px; }
.logo { font-family: var(--display); font-weight: 700; font-size: 1.45rem; color: var(--ink); text-decoration: none; display: flex; align-items: center; gap: 8px; }
.logo img { height: 44px; width: auto; }
.nav ul { display: flex; gap: 22px; list-style: none; margin: 0; padding: 0; font-weight: 700; font-size: .95rem; }
.nav ul a { color: var(--ink-soft); text-decoration: none; }
.nav ul a:hover { color: var(--lilac-deep); }
@media (max-width: 760px) {
  .nav .wrap { flex-wrap: wrap; gap: 6px; padding-block: 8px 6px; }
  .logo img { height: 36px; }
  .nav ul { width: 100%; gap: 18px; overflow-x: auto; white-space: nowrap; font-size: .88rem; padding-bottom: 4px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .nav ul::-webkit-scrollbar { display: none; }
  .nav ul li { flex: none; }
}

/* HERO */
.hero { position: relative; overflow: hidden; background: linear-gradient(180deg, #dcd3f5 0%, #d6e8f8 45%, var(--frost) 100%); padding-block: clamp(48px, 8vw, 96px) 0; }
.aurora { position: absolute; inset: -20% -10% auto; height: 70%; pointer-events: none; opacity: .7;
  background: radial-gradient(60% 40% at 25% 40%, rgba(186,238,215,.8), transparent 70%), radial-gradient(50% 35% at 70% 30%, rgba(255,214,232,.75), transparent 70%), radial-gradient(40% 30% at 50% 60%, rgba(201,184,236,.7), transparent 70%);
  animation: drift 18s ease-in-out infinite alternate; }
@keyframes drift { from { transform: translateX(-3%) } to { transform: translateX(3%) } }
.hero-grid { position: relative; display: grid; grid-template-columns: 1.05fr 1fr; gap: 32px; align-items: end; }
.hero-copy { display: grid; gap: 22px; padding-bottom: clamp(40px, 7vw, 96px); min-width: 0; }
.hero h1 { font-size: clamp(3rem, 9vw, 6rem); font-weight: 700; letter-spacing: -.01em; color: #4a3f7a; }
.hero h1 img { width: min(560px, 100%); height: auto; margin-top: 6px; }
.hero h1 span { display: block; font-size: .38em; font-weight: 600; color: var(--lilac-deep); letter-spacing: .02em; margin-bottom: 4px; }
.hero .lede { color: #4f5478; font-size: clamp(1.1rem, 2vw, 1.3rem); }
.badges { display: flex; flex-wrap: wrap; gap: 10px; }
.badge { background: rgba(255,255,255,.75); border: 1px solid rgba(255,255,255,.9); border-radius: 999px; padding: 8px 16px; font-weight: 700; font-size: .92rem; color: var(--ink); }
.badge.soon { background: var(--ink); color: var(--snow); border-color: var(--ink); }
.hero-cast { display: flex; align-items: flex-end; justify-content: center; min-width: 0; max-width: 600px; justify-self: center; width: 100%; filter: drop-shadow(0 18px 24px rgba(91,74,150,.18)); }
.hero-cast img { height: auto; }
.hero-cast .c-juni { width: 30%; margin-right: -3%; }
.hero-cast .c-ama { width: 39%; position: relative; z-index: 1; }
.hero-cast .c-tobo { width: 34%; margin-left: -3%; position: relative; z-index: 2; }
.hills { position: relative; display: block; width: 100%; height: 70px; margin-top: -2px; }
@media (max-width: 820px) { .hero-grid { grid-template-columns: 1fr; } .hero-copy { padding-bottom: 8px; } .hero-cast { max-width: 440px; } }

/* VALLEY GALLERY */
.places { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 48px; }
.place { position: relative; margin: 0; border-radius: 20px; overflow: hidden; aspect-ratio: 16 / 9; background: var(--sky); }
.place img { width: 100%; height: 100%; object-fit: cover; display: block; }
.place.big { grid-column: span 2; grid-row: span 2; aspect-ratio: auto; border-radius: var(--radius); }
.place figcaption { position: absolute; left: 10px; bottom: 10px; background: rgba(255,255,255,.88); color: var(--ink); border-radius: 999px; padding: 4px 12px; font-weight: 700; font-size: .82rem; }
.place.big figcaption { left: 16px; bottom: 16px; font-size: 1rem; padding: 6px 16px; }
@media (max-width: 760px) { .places { grid-template-columns: 1fr 1fr; gap: 10px; } .place.big { aspect-ratio: 16 / 9; grid-row: span 1; } .place figcaption { font-size: .7rem; padding: 3px 9px; left: 7px; bottom: 7px; } }

/* WORLD */
.seasons { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.season { border-radius: var(--radius); padding: 28px; display: grid; gap: 10px; align-content: start; }
.season .icon { width: 56px; height: 56px; }
.season.frost { background: var(--sky); }
.season.drip { background: var(--mint); }
.season.glow { background: #e6dcf8; }
.world-rules { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px 40px; margin-top: 40px; }
.rule { display: grid; grid-template-columns: 14px 1fr; gap: 14px; align-items: start; }
.rule::before { content: ""; width: 14px; height: 14px; margin-top: 7px; border-radius: 50%; background: var(--lilac); box-shadow: 0 0 10px var(--lilac); }
.rule strong { font-family: var(--display); font-weight: 600; font-size: 1.1rem; display: block; }
.rule p { color: var(--ink-soft); }
@media (max-width: 760px) { .seasons, .world-rules { grid-template-columns: 1fr; } }

/* CAST */
.family { background: var(--snow); border-block: 1px solid var(--line); }
.cast { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.member { display: grid; grid-template-rows: auto 1fr; border-radius: var(--radius); overflow: hidden; background: var(--frost); border: 1px solid var(--line); }
.portrait { aspect-ratio: 4 / 5; overflow: hidden; position: relative; background: #ddd4d0; }
.portrait img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 8%; }
.portrait .tag { position: absolute; left: 12px; bottom: 12px; background: rgba(255,255,255,.85); border-radius: 999px; padding: 4px 12px; font-size: .78rem; font-weight: 700; color: var(--ink-soft); }
.portrait.soon { display: grid; place-items: center; }
.portrait.soon svg { width: 58%; height: auto; }
.m-body { padding: 22px 24px 26px; display: grid; gap: 8px; align-content: start; }
.m-name { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.m-name h3 { font-size: 1.6rem; }
.m-role { font-weight: 700; color: var(--lilac-deep); font-size: .95rem; }
.m-body p { color: var(--ink-soft); }
.m-item { font-size: .92rem; color: var(--ink); }
.m-item b { font-family: var(--display); font-weight: 600; }
@media (max-width: 900px) { .cast { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .cast { grid-template-columns: 1fr; } }

/* NEIGHBOURS */
.neighbours { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.nb { background: var(--snow); border-radius: 22px; padding: 18px; display: grid; grid-template-columns: 104px 1fr; gap: 18px; align-items: start; border: 1px solid var(--line); }
.nb .av { width: 104px; aspect-ratio: 4 / 5; border-radius: 16px; overflow: hidden; background: #ddd4d0; }
.nb .av img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; }
.nb .av.soon { display: grid; place-items: center; background: var(--butter); }
.nb .tx { display: grid; gap: 6px; min-width: 0; padding-top: 4px; }
.nb .sp { font-size: .85rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-soft); }
.nb h3 { font-size: 1.25rem; }
.nb p { color: var(--ink-soft); font-size: .98rem; }
.grownups { margin-top: 22px; display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.grownups .nb { background: var(--butter); border-color: transparent; }
.lineup { margin: 48px 0 0; display: grid; gap: 14px; }
.lineup-scroll { overflow-x: auto; border-radius: var(--radius); background: #ebe7e4; border: 1px solid var(--line); }
.lineup-scroll img { width: 100%; min-width: 760px; height: auto; }
.lineup p { color: var(--ink-soft); font-size: .95rem; }
@media (max-width: 900px) { .neighbours { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .neighbours, .grownups { grid-template-columns: 1fr; } }

/* STORY WALL */
.wall { background: linear-gradient(180deg, var(--frost), #f3ecfb); }
.wall-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 48px; align-items: center; }
.steps { display: grid; gap: 14px; list-style: none; margin: 0; padding: 0; counter-reset: s; }
.steps li { counter-increment: s; display: grid; grid-template-columns: 48px 1fr; gap: 16px; align-items: start; background: var(--snow); border-radius: 20px; padding: 16px 20px; border: 1px solid var(--line); }
.steps li::before { content: counter(s); width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; font-family: var(--display); font-weight: 700; font-size: 1.3rem; background: var(--peach); color: var(--ink); }
.steps li:last-child::before { background: var(--lilac); }
.steps b { font-family: var(--display); font-weight: 600; font-size: 1.1rem; display: block; }
.steps .t { color: var(--ink-soft); font-size: .95rem; }
.steps .min { font-size: .8rem; font-weight: 700; color: var(--lilac-deep); letter-spacing: .06em; text-transform: uppercase; }
.wall-art { border-radius: var(--radius); background: #8a6e5c; padding: 22px; box-shadow: inset 0 0 40px rgba(0,0,0,.25); }
.wall-art svg { width: 100%; height: auto; display: block; }
@media (max-width: 860px) { .wall-grid { grid-template-columns: 1fr; } }

/* EPISODES */
.eps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.ep { background: var(--snow); border-radius: 22px; padding: 22px 24px; border: 1px solid var(--line); display: grid; gap: 6px; align-content: start; }
.ep .n { font-family: var(--display); font-weight: 600; color: var(--lilac-deep); font-size: .9rem; font-variant-numeric: tabular-nums; }
.ep h3 { font-size: 1.2rem; }
.ep p { color: var(--ink-soft); font-size: .96rem; }
.ep .lesson { font-size: .85rem; font-weight: 700; color: var(--ink); background: var(--mint); border-radius: 999px; padding: 3px 12px; justify-self: start; margin-top: 6px; }
@media (max-width: 900px) { .eps { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .eps { grid-template-columns: 1fr; } }

/* PARENTS */
.story { background: linear-gradient(180deg, #fff7f1, var(--frost)); }
.story-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; counter-reset: st; }
.story-step { background: var(--snow); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px 26px; display: grid; gap: 10px; align-content: start; position: relative; }
.story-step .ic { width: 56px; height: 56px; border-radius: 18px; display: grid; place-items: center; font-size: 1.6rem; }
.story-step:nth-child(1) .ic { background: var(--peach); }
.story-step:nth-child(2) .ic { background: var(--lilac); }
.story-step:nth-child(3) .ic { background: var(--mint); }
.story-step .when { font-family: var(--display); font-weight: 600; font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft); }
.story-quote { margin-top: 28px; text-align: center; font-family: var(--display); font-weight: 500; font-size: clamp(1.2rem, 2.6vw, 1.55rem); color: var(--lilac-deep); max-width: 48ch; margin-inline: auto; }
@media (max-width: 860px) { .story-steps { grid-template-columns: 1fr; } }
.parents { background: var(--snow); border-block: 1px solid var(--line); }
.promise { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.pr { border-radius: 22px; padding: 22px; display: grid; gap: 8px; align-content: start; }
.pr:nth-child(1) { background: var(--sky); }
.pr:nth-child(2) { background: var(--mint); }
.pr:nth-child(3) { background: var(--peach); }
.pr:nth-child(4) { background: #e6dcf8; }
.pr h3 { font-size: 1.15rem; }
.pr p { font-size: .96rem; color: #4f5478; }
@media (max-width: 900px) { .promise { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .promise { grid-template-columns: 1fr; } }

/* CONTACT */
.contact-card { background: linear-gradient(135deg, #e6dcf8, #d6e8f8); border-radius: 36px; padding: clamp(28px, 5vw, 56px); display: grid; grid-template-columns: 1.3fr 1fr; gap: 32px; align-items: center; }
.contact-card .mail { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.mail code { font-family: var(--display); font-weight: 600; font-size: clamp(1.2rem, 3vw, 1.6rem); background: var(--snow); border-radius: 14px; padding: 10px 18px; color: var(--ink); user-select: all; word-break: break-all; }
.copy { font: 700 .95rem var(--body); background: var(--ink); color: var(--snow); border: 0; border-radius: 999px; padding: 12px 20px; cursor: pointer; }
.copy:hover { background: var(--lilac-deep); }
.contact-card ul { margin: 0; padding-left: 1.1em; color: #4f5478; display: grid; gap: 6px; }
@media (max-width: 820px) { .contact-card { grid-template-columns: 1fr; } }

footer { padding-block: 40px 56px; color: var(--ink-soft); font-size: .92rem; }
footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; }

/* EPISODES PAGE */
.ep-hero { padding-block: clamp(48px, 8vw, 88px) 24px; background: linear-gradient(180deg, #f3ecfb, var(--frost)); }
.ep-hero h1 { font-size: clamp(2.2rem, 6vw, 3.4rem); }
.strands { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; }
.strand-btn { font: 700 .92rem var(--body); border: 1px solid var(--line); background: var(--snow); color: var(--ink); border-radius: 999px; padding: 8px 16px; cursor: pointer; }
.strand-btn[aria-pressed="true"] { background: var(--ink); color: var(--snow); border-color: var(--ink); }
.strand-btn .c { opacity: .7; font-weight: 600; }
.ep .meta { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.ep .tag { font-size: .78rem; font-weight: 700; border-radius: 999px; padding: 2px 10px; color: var(--ink); }
.ep[data-strand="feelings"] .tag { background: var(--peach); }
.ep[data-strand="everyday"] .tag { background: var(--sky); }
.ep[data-strand="maths"] .tag { background: var(--butter); }
.ep[data-strand="science"] .tag { background: var(--mint); }
.ep .lesson { background: #f1ecfb; }
.ep.finale { border-color: var(--lilac); box-shadow: 0 0 0 3px #efe8fb; }
.ep[hidden] { display: none; }
.eps-note { margin-top: 28px; color: var(--ink-soft); font-size: .95rem; }
.ep-cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; background: var(--snow); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 28px; }
.ep-cta p { color: var(--ink-soft); max-width: 52ch; }
.btn { display: inline-block; font: 700 1rem var(--body); background: var(--ink); color: var(--snow); border-radius: 999px; padding: 12px 22px; text-decoration: none; }
.btn:hover { background: var(--lilac-deep); }
.ep-mini { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.ep-mini span { background: var(--frost); border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; font-size: .88rem; font-weight: 600; }
.nav ul a[aria-current="page"] { color: var(--lilac-deep); }
