/* The homepage only, FR (index.html) and EN (en/index.html): the hero stage and
   its tablet mock, the crew marquee, the sticky portfolio story, the bento card
   pictures and the grades ruler.

   Linked after assets/design.css, which holds the tokens and every shared
   component (DESIGN.md 9.1); the header and footer are in assets/site.css.
   Anything another page could reuse belongs in design.css, not here. */

/* ----------------------------------------------------------------------------
   1. Hero
   ------------------------------------------------------------------------- */

/* The stage: a tablet running the app, and what happens around it. */
.stage { --px: 0; --py: 0; position: relative; width: 100%; max-width: 640px; margin: 0 auto; aspect-ratio: 1 / .9; }
/* Parallax rides on the independent translate property, so it composes with
   the transform-based entrances and loops instead of overriding them. */
.stage .depth { transition: translate .6s var(--ease-out); translate: calc(var(--px) * var(--dx, 0px)) calc(var(--py) * var(--dx, 0px)); }

.tablet {
  position: absolute; left: 3%; top: 13%; width: 86%;
  padding: 1.4%; border-radius: 30px; background: var(--ink);
  box-shadow: var(--shadow-deep), inset 0 0 0 1.5px #2a2d33;
  --dx: -8px;
}
@media (prefers-reduced-motion: no-preference) {
  .js .tablet { animation: rise 1s .15s var(--ease-out) both; }
}
.screen {
  container-type: inline-size;
  position: relative; display: grid; grid-template-columns: 9.5cqw 1fr;
  aspect-ratio: 16 / 11; border-radius: 20px; overflow: hidden; background: var(--paper);
}
/* App rail: the logo, then icons, the Portfolio one selected in an ink pill
   exactly as the app's sidebar does it. */
.rail { display: flex; flex-direction: column; align-items: center; gap: 2.4cqw; padding: 2.6cqw 0; border-right: 1px solid var(--line); background: var(--paper); }
.rail img { width: 5.4cqw; height: 5.4cqw; }
.rail i { display: grid; place-items: center; width: 6cqw; height: 6cqw; border-radius: 1.6cqw; color: var(--ink-muted); }
.rail i svg { width: 3.2cqw; height: 3.2cqw; }
.rail i.on { background: var(--ink); color: var(--paper); }
.app { padding: 3cqw 3.2cqw; min-width: 0; }
.app-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 2cqw; }
.app-title { font-size: 3.6cqw; font-weight: 800; letter-spacing: -0.02em; line-height: 1.1; }
.app-class { display: block; margin-top: .6cqw; font-size: 1.9cqw; font-weight: 500; color: var(--ink-muted); }
.app-btn { display: inline-flex; align-items: center; gap: .8cqw; padding: 1.3cqw 2.2cqw; border-radius: 999px; background: var(--brand); font-size: 1.9cqw; font-weight: 700; white-space: nowrap; box-shadow: 0 .6cqw 1.6cqw rgba(253, 221, 0, .45); }
.app-btn svg { width: 2.2cqw; height: 2.2cqw; }
.app-search { margin-top: 2.4cqw; display: flex; align-items: center; gap: 1.2cqw; height: 5.4cqw; padding: 0 2cqw; border: 1px solid var(--line); border-radius: 999px; font-size: 1.9cqw; color: var(--ink-muted); }
.app-search svg { width: 2.4cqw; height: 2.4cqw; }
.app-chips { display: flex; gap: 1.1cqw; margin-top: 2cqw; overflow: hidden; white-space: nowrap; }
.app-chip { display: inline-flex; align-items: center; gap: .8cqw; padding: .7cqw 1.6cqw .7cqw .7cqw; border-radius: 999px; background: var(--paper-soft); font-size: 1.8cqw; font-weight: 600; flex: 0 0 auto; }
.app-chip.on { background: var(--ink); color: var(--paper); padding-left: 1.8cqw; }
.app-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.8cqw; margin-top: 2.4cqw; }
.tile { position: relative; border-radius: 1.8cqw; overflow: hidden; background: var(--paper-soft); box-shadow: 0 0 0 1px var(--line); }
.tile img { width: 100%; aspect-ratio: 54 / 42; object-fit: cover; }
.tile figcaption { position: absolute; left: 1cqw; right: 1cqw; bottom: 1cqw; display: flex; align-items: center; gap: .8cqw; padding: .5cqw 1.2cqw .5cqw .5cqw; border-radius: 999px; background: rgba(255, 255, 255, .94); font-size: 1.6cqw; font-weight: 700; width: max-content; max-width: calc(100% - 2cqw); }
.tile figcaption .ini { width: 2.8cqw; height: 2.8cqw; font-size: 1.15cqw; }
.tile .new { position: absolute; top: 1cqw; right: 1cqw; padding: .5cqw 1.3cqw; border-radius: 999px; background: var(--brand); font-size: 1.5cqw; font-weight: 800; font-style: normal; opacity: 0; }
@media (prefers-reduced-motion: no-preference) {
  .tile.is-new { animation: land .9s var(--ease-spring) both; }
  .tile.is-new .new { animation: flash 3.6s ease both; }
  .tile.is-new::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 0 .5cqw var(--brand); animation: flash 3.6s ease both; }
}
@keyframes land { 0% { opacity: 0; transform: translate3d(0, -14%, 0) scale(.82) rotate(-4deg); } 60% { opacity: 1; } 100% { opacity: 1; transform: none; } }
@keyframes flash { 0% { opacity: 0; } 12%, 70% { opacity: 1; } 100% { opacity: 0; } }

/* Lino avatars burst up from behind the tablet's top-right corner, then bob. */
.burst { position: absolute; right: 0; top: 0; width: 46%; height: 36%; z-index: -1; --dx: 14px; }
.burst img { position: absolute; width: var(--w, 22%); height: auto; left: var(--x); top: var(--y); filter: drop-shadow(0 8px 14px rgba(15, 17, 19, .16)); }
@media (prefers-reduced-motion: no-preference) {
  .js .burst img { animation: pop .8s var(--ease-spring) both, bob var(--t, 4s) ease-in-out infinite; animation-delay: calc(.5s + var(--i) * .08s), calc(1.4s + var(--i) * .3s); }
}

/* Floating cards. */
.float { position: absolute; background: var(--card); border-radius: 18px; box-shadow: var(--shadow-float); border: 1px solid rgba(15, 17, 19, .06); }
.points { left: -1%; top: 4%; display: flex; align-items: center; gap: 10px; padding: 9px 16px 9px 9px; white-space: nowrap; --dx: 18px; }
.points img { width: 40px; height: 40px; }
.points b { display: block; font-size: 15px; font-weight: 800; letter-spacing: -0.01em; line-height: 1.2; }
.points div > span { display: block; font-size: 12px; font-weight: 600; color: var(--ink-muted); }
.points .plus { color: var(--kid-green); }
@media (prefers-reduced-motion: no-preference) {
  .js .points { animation: pop .8s 1.1s var(--ease-spring) both; }
}

.feed { left: -4%; bottom: 0; width: min(62%, 340px); height: 100px; background: transparent; border: 0; box-shadow: none; --dx: 22px; }
.note {
  position: absolute; left: 0; right: 0; bottom: 0;
  display: flex; align-items: center; gap: 12px; padding: 12px 14px;
  background: rgba(255, 255, 255, .96); border-radius: 18px; border: 1px solid rgba(15, 17, 19, .06);
  box-shadow: var(--shadow-float);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  transition: transform .7s var(--ease-out), opacity .7s var(--ease-out);
  transform-origin: 50% 100%;
}
.note > img { width: 44px; height: 44px; border-radius: 12px; object-fit: cover; flex: 0 0 auto; background: var(--paper-soft); }
.note .who { min-width: 0; font-size: 14px; line-height: 1.3; color: var(--ink-soft); }
.note .who b { color: var(--ink); font-weight: 700; }
.note small { display: flex; align-items: center; gap: 6px; margin-top: 3px; font-size: 12px; font-weight: 600; color: var(--ink-muted); }
.note small::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--tag, var(--kid-blue)); }
/* Stack positions, set by motion.js. Without JS the first note alone shows. */
.note[data-pos="0"] { transform: none; opacity: 1; z-index: 3; }
.note[data-pos="1"] { transform: translate3d(0, -14px, 0) scale(.94); opacity: .75; z-index: 2; }
.note[data-pos="2"] { transform: translate3d(0, -27px, 0) scale(.88); opacity: .4; z-index: 1; }
.note[data-pos="out"] { transform: translate3d(0, 26px, 0) scale(.96); opacity: 0; z-index: 0; }
/* The notes behind the newest read as blank sheets: a two-line note behind a
   one-line note would otherwise show a sliver of text above it. */
.note > * { transition: opacity .3s ease; }
.note[data-pos="1"] > *, .note[data-pos="2"] > * { opacity: 0; }
.note:not([data-pos]) { opacity: 0; }
.note:first-child:not([data-pos]) { opacity: 1; }

.stage-lino { position: absolute; right: 7%; bottom: 5%; width: 18%; z-index: 3; --dx: -16px; filter: drop-shadow(0 12px 18px rgba(15, 17, 19, .2)); }
@media (prefers-reduced-motion: no-preference) {
  .js .stage-lino { --r: 4deg; animation: pop .8s 1.3s var(--ease-spring) both, bob 4.6s 2.2s ease-in-out infinite; }
}

@media (max-width: 560px) {
  .stage { aspect-ratio: 1 / 1.02; }
  .tablet { left: 0; width: 100%; top: 16%; border-radius: 20px; padding: 1.6%; }
  .screen { border-radius: 14px; grid-template-columns: 1fr; }
  .rail { display: none; }
  .app { padding: 3.6cqw; }
  .burst { width: 54%; height: 30%; }
  .points { left: 0; top: 2%; padding: 7px 12px 7px 7px; gap: 8px; }
  .points img { width: 32px; height: 32px; }
  .points b { font-size: 13px; }
  .points div > span { font-size: 11px; }
  .feed { left: 0; bottom: 0; width: 86%; height: 84px; }
  .note { padding: 10px 11% 10px 12px; gap: 10px; border-radius: 16px; }
  .note small { white-space: nowrap; }
  .note > img { width: 38px; height: 38px; }
  .note .who { font-size: 13px; }
  .stage-lino { width: 20%; right: 2%; bottom: 3%; }
}

/* ----------------------------------------------------------------------------
   2. The class: every child wears a job. Three rows of the app's 30 Lino
   avatars drift in alternating directions behind one white card.
   ------------------------------------------------------------------------- */
.crew { position: relative; padding: 88px 0; background: var(--paper-soft); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); overflow: hidden; }
.crew-rows { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: center; gap: 18px; -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); }
.crew-row { overflow: hidden; }
.crew-track { display: flex; gap: 18px; width: max-content; }
.crew-track img { width: 96px; height: 96px; padding: 12px; border-radius: 28px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow-soft); flex: 0 0 auto; }
.crew-track img:nth-child(4n+1) { background: var(--kid-blue-soft); border-color: transparent; }
.crew-track img:nth-child(4n+3) { background: var(--kid-pink-soft); border-color: transparent; }
.crew-track img:nth-child(5n+2) { background: var(--kid-purple-soft); border-color: transparent; }
@media (prefers-reduced-motion: no-preference) {
  .crew-track { animation: drift var(--t, 50s) linear infinite; }
  .crew-row.rev .crew-track { animation-direction: reverse; }
}
@keyframes drift { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(calc(-50% - 9px), 0, 0); } }
.crew-card {
  position: relative; z-index: 1; max-width: 560px; margin: 0 auto; padding: 40px 40px 36px; text-align: center;
  background: rgba(255, 255, 255, .9); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
  border: 1px solid var(--line); border-radius: var(--radius-sheet); box-shadow: var(--shadow-deep);
}
.crew-card .h2 { font-size: clamp(28px, 3.4vw, 40px); }
.crew-card p { margin-top: 14px; font-size: 16.5px; line-height: 1.65; color: var(--ink-soft); }
.crew-card .more { margin-top: 20px; }
.crew-lino { width: 64px; height: 64px; margin: -76px auto 14px; filter: drop-shadow(0 10px 14px rgba(15, 17, 19, .18)); }
@media (prefers-reduced-motion: no-preference) {
  .js .crew-lino { animation: bob 4s ease-in-out infinite; --r: 5deg; }
}
@media (max-width: 560px) {
  .crew { padding: 56px 0; }
  .crew-card { padding: 32px 22px 28px; margin: 0 16px; }
  .crew-track img { width: 76px; height: 76px; padding: 9px; border-radius: 22px; }
}

/* ----------------------------------------------------------------------------
   3. The portfolio story. From 1000px the device sticks and the step nearest
   the middle of the screen owns it; below that each step shows its own
   picture and nothing sticks.
   ------------------------------------------------------------------------- */
.story { display: grid; grid-template-columns: 1fr; gap: 24px; }
.steps { list-style: none; display: grid; gap: 20px; counter-reset: step; }
.step { position: relative; padding: 28px 26px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-card); }
.step-n { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--brand); border: 2px solid var(--ink); font-size: 14px; font-weight: 800; }
.step h3 { margin-top: 16px; font-size: clamp(22px, 2.3vw, 28px); font-weight: 800; letter-spacing: -0.03em; line-height: 1.15; }
.step p { margin-top: 10px; font-size: 16.5px; line-height: 1.65; color: var(--ink-soft); }
.step ul { list-style: none; margin-top: 14px; display: grid; gap: 8px; }
.step li { position: relative; padding-left: 28px; font-size: 15px; line-height: 1.5; color: var(--ink-soft); }
.step li::before { content: ""; position: absolute; left: 0; top: 2px; width: 18px; height: 18px; border-radius: 50%; background: var(--sage-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%233a8259' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 12 4 4 8-8'/%3E%3C/svg%3E") center / 12px no-repeat; }
.step .more { margin-top: 16px; }
.story-stage { display: none; }

@media (min-width: 1000px) {
  .story { grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr); gap: 64px; align-items: start; }
  .steps { gap: 0; padding: 12vh 0; position: relative; }
  /* The rail the steps hang on. */
  .steps::before { content: ""; position: absolute; left: 19px; top: 12vh; bottom: 12vh; width: 2px; background: repeating-linear-gradient(var(--line) 0 8px, transparent 8px 14px); }
  .step { min-height: 64vh; display: flex; flex-direction: column; justify-content: center; padding: 0 0 0 64px; background: none; border: 0; border-radius: 0; transition: opacity .5s var(--ease-out); }
  .step-n { position: absolute; left: 0; top: calc(50% - 20px); background: var(--card); border-color: var(--line); color: var(--ink-muted); transition: background .3s ease, border-color .3s ease, color .3s ease, transform .4s var(--ease-spring); }
  .step h3 { margin-top: 0; }
  /* Steps not in view are dimmed by colour, not opacity, so their text keeps a readable contrast. */
  .js .step :is(h3, p, li) { transition: color .4s ease; }
  .js .step:not(.is-active) :is(h3, p, li) { color: var(--ink-muted); }
  .step.is-active .step-n { background: var(--brand); border-color: var(--ink); color: var(--ink); transform: scale(1.12); }
  .step-shot, .step-shot.mock { display: none; }
  /* Without JS nothing drives the device, so each step keeps its own picture. */
  html:not(.js) .step-shot { display: block; }
  html:not(.js) .step-shot.mock { display: grid; }
  html:not(.js) .story-stage { display: none; }
  .story-stage { display: block; position: sticky; top: calc(50vh - 250px); height: 500px; }
}
/* The screen takes the screenshots' own 16:10 shape, so nothing is cropped mid-button. */
.story-device {
  position: absolute; top: 7%; left: 0; right: 9%; padding: 12px; border-radius: 30px; background: var(--ink);
  box-shadow: var(--shadow-deep), inset 0 0 0 1.5px #2a2d33;
}
.story-screen { position: relative; width: 100%; aspect-ratio: 16 / 10; border-radius: 20px; overflow: hidden; background: var(--paper); }
.story-screen img, .story-screen video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top left; opacity: 0; transform: scale(1.03); transition: opacity .6s var(--ease-out), transform .9s var(--ease-out); }
.story-phone { position: absolute; right: 0; bottom: 0; width: 34%; aspect-ratio: 390 / 844; padding: 8px; border-radius: 34px; background: var(--ink); box-shadow: var(--shadow-deep); opacity: 0; transform: translate3d(40px, 30px, 0) rotate(4deg); transition: opacity .6s var(--ease-out), transform .8s var(--ease-spring); }
.story-phone img { width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 27px; }
.story-badge { position: absolute; left: -22px; top: 36px; display: flex; align-items: center; gap: 10px; padding: 10px 16px 10px 10px; background: var(--card); border-radius: 16px; box-shadow: var(--shadow-float); font-size: 14px; font-weight: 700; opacity: 0; transform: translate3d(-10px, 0, 0); transition: opacity .5s var(--ease-out), transform .6s var(--ease-spring); }
.story-badge img { width: 34px; height: 34px; }
.story-badge.is-card { top: auto; bottom: 30px; left: -30px; padding: 0; background: none; box-shadow: none; width: 300px; }
.story-badge.is-card .obs { width: 100%; }
.story[data-active="1"] [data-shot="1"],
.story[data-active="2"] [data-shot="2"],
.story[data-active="3"] [data-shot="3"],
.story[data-active="4"] [data-shot="4"] { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .story-screen img, .story-screen video, .story-phone, .story-badge, .step, .step-n { transition: none; }
}


/* Activities: a submission flips from waiting to approved. */
.subm { width: min(90%, 380px); padding: 10px; display: grid; gap: 8px; }
.subm-row { display: grid; grid-template-columns: 46px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 6px 8px 6px 6px; border-radius: 10px; background: var(--paper-soft); }
.subm-row img { width: 46px; height: 36px; object-fit: cover; border-radius: 8px; }
.subm-row b { display: block; font-size: 13.5px; line-height: 1.25; }
.subm-row small { display: block; font-size: 11.5px; color: var(--ink-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.flip { position: relative; display: grid; }
.flip > * { grid-area: 1 / 1; }
@media (prefers-reduced-motion: no-preference) {
  .flip .wait { animation: fadeOut 6s infinite; }
  .flip .ok { animation: fadeIn 6s infinite; }
}
.flip .ok { opacity: 1; }
@media (prefers-reduced-motion: no-preference) { .flip .ok { opacity: 0; } }
@keyframes fadeOut { 0%, 42% { opacity: 1; transform: none; } 50%, 92% { opacity: 0; transform: scale(.8); } 100% { opacity: 1; } }
@keyframes fadeIn { 0%, 42% { opacity: 0; transform: scale(.8); } 50%, 92% { opacity: 1; transform: none; } 100% { opacity: 0; } }

/* Points: badges orbit a total that counts up. */
.pts { position: relative; width: 100%; height: 100%; display: grid; place-items: center; }
.pts-total { display: flex; align-items: center; gap: 12px; padding: 14px 22px 14px 14px; border-radius: 18px; background: var(--brand); box-shadow: var(--shadow-brand); }
.pts-total img { width: 44px; height: 44px; }
.pts-total b { font-size: 34px; font-weight: 800; letter-spacing: -0.03em; line-height: 1; font-variant-numeric: tabular-nums; }
.pts-total span { display: block; font-size: 12px; font-weight: 700; }
.pts > img { position: absolute; width: 58px; height: 58px; left: var(--x); top: var(--y); filter: drop-shadow(0 8px 12px rgba(15, 17, 19, .15)); }
@media (prefers-reduced-motion: no-preference) {
  .pts > img { animation: bob var(--t, 3.6s) ease-in-out infinite; animation-delay: var(--dl, 0s); }
}

/* Messages: a short exchange with a family, bubble by bubble. */
.chat { width: min(88%, 360px); display: grid; gap: 7px; }
.bub { max-width: 84%; padding: 7px 12px; border-radius: 15px; font-size: 12.5px; line-height: 1.4; box-shadow: var(--shadow-soft); }
.bub.them { background: var(--card); border: 1px solid var(--line); border-bottom-left-radius: 6px; }
.bub.me { justify-self: end; background: var(--brand); border-bottom-right-radius: 6px; }
.bub small { display: block; font-size: 11px; font-weight: 700; color: var(--ink-muted); margin-bottom: 2px; }
.bub.me small { color: rgba(15, 17, 19, .72); }
@media (prefers-reduced-motion: no-preference) {
  .js .chat .bub { opacity: 0; transform: translate3d(0, 10px, 0) scale(.96); }
  .js .is-in .chat .bub { animation: bubble .5s var(--ease-spring) forwards; }
  .js .is-in .chat .bub:nth-child(2) { animation-delay: .7s; }
  .js .is-in .chat .bub:nth-child(3) { animation-delay: 1.5s; }
}
@keyframes bubble { to { opacity: 1; transform: none; } }

/* Bilingual: one switch, two languages. */
.lang { display: grid; gap: 14px; justify-items: center; }
.lang-switch { position: relative; display: grid; grid-template-columns: 1fr 1fr; width: 148px; padding: 4px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow-soft); font-size: 14px; font-weight: 800; }
.lang-switch span { position: relative; z-index: 1; padding: 8px 0; text-align: center; }
.lang-switch::before { content: ""; position: absolute; top: 4px; bottom: 4px; left: 4px; width: calc(50% - 4px); border-radius: 999px; background: var(--brand); box-shadow: inset 0 0 0 1.5px var(--ink); }
.lang-words { position: relative; height: 34px; width: 220px; }
.lang-words span { position: absolute; inset: 0; text-align: center; font-size: 24px; font-weight: 800; letter-spacing: -0.02em; }
.lang-words span + span { opacity: 0; }
@media (prefers-reduced-motion: no-preference) {
  .lang-switch::before { animation: thumb 5s var(--ease-out) infinite; }
  .lang-words span:first-child { animation: fadeOut 5s infinite; }
  .lang-words span + span { animation: fadeIn 5s infinite; }
}
@keyframes thumb { 0%, 42% { transform: none; } 50%, 92% { transform: translateX(100%); } 100% { transform: none; } }

/* A shared class: two teachers, one class. */
.duo { display: flex; align-items: center; gap: 10px; }
.duo img { width: 76px; height: 76px; padding: 8px; border-radius: 24px; background: var(--card); box-shadow: var(--shadow-float); }
.duo .link { display: flex; gap: 5px; }
.duo .link i { width: 7px; height: 7px; border-radius: 50%; background: var(--ink); opacity: .25; }
@media (prefers-reduced-motion: no-preference) {
  .duo .link i { animation: dots 1.6s infinite; }
  .duo .link i:nth-child(2) { animation-delay: .2s; }
  .duo .link i:nth-child(3) { animation-delay: .4s; }
}
@keyframes dots { 0%, 100% { opacity: .2; transform: none; } 40% { opacity: 1; transform: translateY(-3px); } }
.duo-class { position: absolute; bottom: 22px; left: 50%; transform: translateX(-50%); }

/* Observation note with its development domains. */
.obs { width: min(88%, 340px); padding: 14px 16px; }
.obs-top { display: flex; align-items: center; gap: 10px; }
.obs-top img { width: 38px; height: 38px; }
.obs-top b { font-size: 14px; }
.obs-top small { display: block; font-size: 11.5px; color: var(--ink-muted); }
.obs p { margin-top: 10px; font-size: 13.5px; line-height: 1.5; color: var(--ink-soft); }
.obs .tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }

/* The student's canvas: a drawing and the tool dock. */
.canvas-mock { position: relative; width: min(72%, 290px); padding: 8px; }
.canvas-mock img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; border-radius: 10px; }
/* The dock floats over the bottom of the sheet, as it does in the app. */
.dock { position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); display: flex; justify-content: center; gap: 4px; padding: 5px; border-radius: 14px; background: var(--card); box-shadow: var(--shadow-float); }
.dock i { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 9px; background: var(--paper-soft); }
.dock i.on { background: var(--brand); }
.dock i b { width: 14px; height: 14px; border-radius: 50%; background: var(--c); }
.dock svg { width: 16px; height: 16px; }

/* ----------------------------------------------------------------------------
   9. Grades (the four stops, kept from the previous homepage)
   ------------------------------------------------------------------------- */
@media (min-width: 1160px) {
  /* The line only appears once all four stops share a row: it is a ruler of
     ages, and a ruler that wraps onto two lines is not a ruler. */
  .parcours { padding-top: 58px; }
  .parcours::before { content: ""; position: absolute; left: calc(12.5% - 7.5px); right: calc(12.5% - 7.5px); top: 33px; height: 0; border-top: 3px dashed var(--brand-deep); opacity: .5; }
  .parcours-stops { grid-template-columns: repeat(4, 1fr); }
  .stop-marker { display: block; position: absolute; top: -32px; left: 50%; width: 16px; height: 16px; margin-left: -8px; border-radius: 50%; background: var(--paper); border: 3px solid var(--brand-deep); transition: background .18s ease, transform .18s ease; }
  .stop:hover .stop-marker { background: var(--brand); transform: scale(1.3); }
  /* Lino walks the line: the star parks over whichever stop is hovered. */
  .rail-star { display: block; position: absolute; z-index: 2; top: 0; left: calc(12.5% - 7.5px); width: 34px; height: 34px; margin-left: -17px; pointer-events: none; transition: left .45s cubic-bezier(.34, 1.3, .5, 1); }
  .parcours:has(.parcours-stops > li:nth-child(2) .stop:hover) .rail-star { left: calc(37.5% - 2.5px); }
  .parcours:has(.parcours-stops > li:nth-child(3) .stop:hover) .rail-star { left: calc(62.5% + 2.5px); }
  .parcours:has(.parcours-stops > li:nth-child(4) .stop:hover) .rail-star { left: calc(87.5% + 7.5px); }
}
@media (prefers-reduced-motion: reduce) {
  .stop-card, .stop-thumb img, .stop-marker, .rail-star, .stop-age { transition: none; }
  .stop:hover .stop-card, .stop:hover .stop-thumb img, .stop:hover .stop-marker { transform: none; }
}

@media (max-width: 560px) {
  .dock { gap: 2px; padding: 4px; }
  .dock i { width: 22px; height: 22px; border-radius: 7px; }
  .dock svg { width: 13px; height: 13px; }
  .dock i b { width: 11px; height: 11px; }
}

.story-screen .contain { object-fit: contain; object-position: center top; background: var(--paper); }
/* On a phone the card would cover the whole wall, so the rows move above it
   and the card overlaps only their last line. */
@media (max-width: 760px) {
  .crew { padding-top: 40px; }
  .crew-rows { position: relative; inset: auto; gap: 12px; margin-bottom: -56px; }
  .crew-track { gap: 12px; }
  @keyframes drift { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(calc(-50% - 6px), 0, 0); } }
}

/* Engines without container units drop every cqw size in the hero mock.
   Give it fixed sizes there rather than letting it fall apart. */
@supports not (width: 1cqw) {
  .screen { grid-template-columns: 56px 1fr; font-size: 11px; }
  .rail img, .rail i { width: 30px; height: 30px; }
  .app { padding: 16px; }
  .app-title { font-size: 20px; }
  .app-class, .app-btn, .app-search, .app-chip, .tile figcaption, .tile .new { font-size: 10px; }
  .app-grid, .app-chips { gap: 8px; margin-top: 10px; }
  .ini { width: 18px; height: 18px; font-size: 8px; }
}



