@font-face { font-family:'ALONG Hand'; font-style:normal; font-weight:400; font-display:swap; src:url('assets/fonts/ComicNeue-Regular.ttf') format('truetype'); }
@font-face { font-family:'ALONG Hand'; font-style:normal; font-weight:700; font-display:swap; src:url('assets/fonts/ComicNeue-Bold.ttf') format('truetype'); }
:root { color-scheme:light; font-family:'Chalkboard SE','Chalkboard','ALONG Hand','Comic Sans MS',cursive; color:#3c391f; background:#e5f1f2; }
* { box-sizing:border-box; }
body { margin:0; }
button, a { -webkit-tap-highlight-color:transparent; }
button { font:inherit; }
button:focus-visible,a:focus-visible { outline:3px solid #8b912e; outline-offset:5px; }
.viewport { position:relative; width:100%; overflow:hidden; aspect-ratio:1586/992; }
.artboard { position:relative; width:1586px; height:992px; transform:scale(var(--scene-scale,1)); transform-origin:top left; isolation:isolate; }
.scene { position:absolute; inset:0; width:100%; height:100%; z-index:-2; }
.forest-wind { position:absolute; inset:0; width:100%; height:100%; z-index:-1; pointer-events:none; }
.logo { display:block; width:605px; aspect-ratio:1726/680; margin:0 0 -4px; }
.logo svg { display:block; width:100%; height:100%; }
.nav-brand { position:absolute; left:340px; top:28px; display:block; width:88px; height:88px; border-radius:20px; overflow:hidden; z-index:5; }
.nav-brand img { display:block; width:100%; height:100%; object-fit:contain; }
.navigation { position:absolute; left:483px; top:48px; transform:none; display:flex; align-items:center; gap:32px; font-size:21px; font-weight:400; line-height:1.3; white-space:nowrap; z-index:5; }
.film { display:inline-flex; align-items:center; justify-content:center; gap:9px; padding:10px 18px; min-width:196px; min-height:48px; border:1.5px solid #555c31; border-radius:30px; color:#47512d; background:rgba(251,249,232,.82); }
.film svg { flex:none; }
.menu-toggle { display:none; }
.hero { position:absolute; left:340px; top:124px; width:760px; transform:none; text-align:left; z-index:3; }
h1 { margin:0; font:inherit; font-size:57.2px; font-weight:700; line-height:1.24; letter-spacing:-.715px; }
h1 > span { display:block; white-space:nowrap; }
h1 .accent { color:#b84c28; }
.cta { margin-top:30.8px; display:inline-flex; align-items:center; justify-content:center; gap:28.6px; min-width:279px; height:67px; padding:0 31.9px; border:0; border-radius:38.5px; background:#b84624; color:#fff9e8; font-size:27.5px; font-weight:400; line-height:1; cursor:pointer; transition:background .2s,box-shadow .2s; }
.cta:hover { background:#a83e20; box-shadow:0 5px 16px #86412324; }
.cta svg { width:27.5px; height:22px; transition:transform .2s; }
.cta:hover svg { transform:translateX(4px); }
.lake { position:absolute; left:378px; top:615px; width:380px; height:95px; pointer-events:none; }
.glint { position:absolute; left:var(--x); top:var(--y); width:var(--w); height:2px; border-radius:50%; background:#fffee7; opacity:0; transform:scaleX(.4); animation:lake-light 6.8s ease-in-out var(--delay) infinite; }
.falling-leaves { display:none; }
.leaf-track { position:absolute; width:13px; opacity:0; animation:leaf-fall var(--duration) linear var(--delay) infinite; }
.leaf-turn { display:block; width:100%; height:auto; animation:leaf-turn 5.8s ease-in-out infinite alternate; }
.leaf-one { left:130px; top:170px; --duration:22s; --delay:-4s; --travel-x:110px; --travel-y:620px; }
.leaf-two { left:1375px; top:155px; width:11px; --duration:26s; --delay:-15s; --travel-x:-170px; --travel-y:610px; }
.leaf-three { left:1510px; top:280px; width:14px; --duration:29s; --delay:-8s; --travel-x:-110px; --travel-y:560px; }
.is-paused .motion { animation-play-state:paused; }
@keyframes lake-light { 0%,100% { opacity:0; transform:scaleX(.4); } 36% { opacity:.62; } 65% { opacity:.12; transform:scaleX(1.5); } }
@keyframes leaf-fall { 0% { opacity:0; transform:translate(0,0) rotate(-15deg); } 9%,70% { opacity:.8; } 88%,100% { opacity:0; transform:translate(var(--travel-x),var(--travel-y)) rotate(100deg); } }
@keyframes leaf-turn { 0% { transform:rotate(-25deg) scaleX(.6); } 100% { transform:rotate(30deg) scaleX(1); } }
@media (prefers-reduced-motion:reduce) { .motion { animation:none !important; } .cta,.cta svg { transition:none; } }
@media (max-width:700px) {
  .viewport { aspect-ratio:auto; height:calc(370px + 100vw * .6255); background:#e4f1f2; }
  .artboard { width:100%; height:100%; transform:none; }
  .scene { inset:auto 0 0; height:auto; width:100%; mask-image:linear-gradient(to bottom,transparent,#000 25%); }
  .forest-wind { inset:auto 0 0; height:auto; width:100%; aspect-ratio:1586/992; mask-image:linear-gradient(to bottom,transparent,#000 25%); }
  .logo { width:clamp(264px,87.12vw,375.1px); margin-bottom:22px; }
  .nav-brand { left:6%; top:14px; width:54px; height:54px; border-radius:13px; }
  .menu-toggle { position:absolute; display:flex; align-items:center; gap:8px; top:22px; right:20px; padding:9px 12px; border:1px solid #77825c; border-radius:24px; background:#fffbeaee; color:#46512d; font-size:16px; z-index:7; }
  .navigation { display:none; left:auto; right:20px; top:72px; transform:none; padding:18px 22px; gap:14px; border:1px solid #b4bf9b; border-radius:20px; background:#fffbea; font-size:20px; box-shadow:0 8px 24px #334a2820; }
  .menu-open .navigation { display:flex; flex-direction:column; align-items:flex-start; z-index:6; }
  .navigation .film { width:100%; min-width:0; font-size:18px; }
  .hero { left:6%; top:78px; width:88%; }
  h1 { font-size:clamp(21px,6.16vw,41.8px); letter-spacing:-.44px; line-height:1.25; }
  .cta { margin-top:26.4px; margin-left:0; min-width:224.4px; height:59.4px; font-size:24.2px; gap:24.2px; padding:0 26.4px; }
  .lake { left:24%; top:auto; bottom:calc(100vw * .18); width:23%; height:calc(100vw * .06); }
  .glint { width:calc(var(--w) * .4); height:1px; }
  .leaf-track { width:8px; }
  .leaf-one { left:1%; top:140px; --travel-x:35px; --travel-y:380px; }
  .leaf-two { left:94%; top:200px; --travel-x:-25px; --travel-y:340px; }
  .leaf-three { display:none; }
}

/* Storybook navigation: actual chapter links, original hero artwork. */
html { scroll-behavior:smooth; }
.navigation a { color:inherit; text-decoration:none; text-underline-offset:6px; }
.navigation a:hover { text-decoration:underline; }
a.cta { text-decoration:none; }
.skip-link { position:fixed; top:8px; left:8px; transform:translateY(-150%); z-index:50; padding:12px 20px; color:#3c391f; background:#fffbea; border:2px solid #59643a; border-radius:12px; }
.skip-link:focus-visible { transform:translateY(0); }
@media (prefers-reduced-motion:reduce) { html { scroll-behavior:auto; } }

/* Only the repaired treetop is displayed; the original scene and animals remain intact. */
.fox-paws-repair { position:absolute; inset:0; width:100%; height:100%; z-index:0; pointer-events:none; }
@media (max-width:700px) {
  .fox-paws-repair { inset:auto 0 0; width:100%; height:auto; aspect-ratio:1586/992; }
}
.tree-completion { position:absolute; inset:0; z-index:0; pointer-events:none; }
.forest-wind[data-tree-composite="true"] ~ .tree-completion { visibility:hidden; }
.tree-completion img { display:block; width:100%; height:100%; mask-image:linear-gradient(to right,#000 0%,#000 34%,transparent 37%),linear-gradient(to bottom,#000 0%,#000 23.5%,transparent 28%); mask-composite:intersect; }
@media (max-width:700px) {
  .tree-completion { inset:auto 0 0; width:100%; height:auto; aspect-ratio:1586/992; mask-image:linear-gradient(to bottom,transparent,#000 25%); }
}
