/* QuantCorner home hero: a centred headline whose last line changes and is set in the handwriting
   face, a join box, and a wheel of eight quant terms rolling at the right edge. Plain Paper field,
   no cards and no photographs. Lucid Current tokens from assets/styles.css. */
@font-face { font-family: "Sriracha"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/sriracha.woff2") format("woff2"); }
:root { --pill: 999px; }

.cx-hero {
  position: relative; min-height: max(640px, 100svh); padding: 96px 0 72px;
  display: grid; place-items: center; overflow: clip; background: var(--tint);
}

/* Wheel of eight terms at the right edge. Two copies of the list, rolled by one list height. */
.cx-terms {
  position: absolute; right: var(--pad); top: calc(50% + 12px); translate: 0 -50%; z-index: 1;
  height: 132px; overflow: hidden; text-align: right; font-size: 13px; line-height: 26px; white-space: nowrap; color: var(--ink-2);
  -webkit-mask-image: linear-gradient(to bottom, transparent, var(--mask) 32%, var(--mask) 68%, transparent);
  mask-image: linear-gradient(to bottom, transparent, var(--mask) 32%, var(--mask) 68%, transparent);
}
.cx-terms ul { list-style: none; margin: 0; padding: 0; }
@media (max-width: 860px) { .cx-terms { display: none; } }

@media (prefers-reduced-motion: no-preference) {
  .cx-terms ul { animation: cx-roll 20s linear infinite; }
  /* backwards only: once in, the scroll scene below owns these properties. */
  .cx-center { animation: cx-copy-in 700ms var(--ease-smooth-out) 100ms backwards; }
  .cx-terms, .cx-down { animation: cx-fade 700ms var(--ease-out) 500ms backwards; }
  @keyframes cx-roll { to { transform: translateY(-208px); } }
  @keyframes cx-copy-in { from { opacity: 0; filter: blur(16px); transform: translateY(12px); } }
  @keyframes cx-fade { from { opacity: 0; } }
}

.cx-center { position: relative; z-index: 2; display: grid; justify-items: center; gap: 28px; width: min(1120px, 100% - 40px); text-align: center; }
/* Thai needs room above and below the line for vowels and tone marks. */
.cx-title { font: 700 clamp(38px, 7.2vw, 96px)/1.28 var(--display); letter-spacing: 0; color: var(--ink); }
.cx-title-line { display: block; }
/* The changing line is handwritten (Sriracha, the system's font-hand; it has one weight). */
.cx-rot { display: inline-block; min-height: 1.28em; font-family: "Sriracha", cursive; font-weight: 400; font-synthesis: none;
  transition: opacity 260ms var(--ease-out), transform 260ms var(--ease-out), filter 260ms var(--ease-out); }
/* A long phrase (over 28 characters) is set smaller so it keeps to one line on desktop. */
.cx-rot.is-long { font-size: 0.75em; }
.cx-rot.is-out { opacity: 0; transform: translateY(-0.18em); filter: blur(6px); }
.cx-rot.is-pre { opacity: 0; transform: translateY(0.18em); filter: blur(6px); transition: none; }

/* Join box (where cosmos.so has its search). Enter sends it; the Enter key inside the box does the same. */
.cx-join { display: grid; grid-template-columns: minmax(0, 1fr); justify-items: center; gap: 14px; width: min(560px, 100%); }
.cx-join-box {
  display: flex; align-items: center; gap: 12px; width: 100%; height: 60px; padding: 0 10px 0 22px; border-radius: var(--pill);
  background: var(--surface); box-shadow: 0 0 0 1px var(--rule), 0 8px 24px var(--k08); cursor: text;
}
.cx-join-box:focus-within { box-shadow: 0 0 0 2px var(--focus), 0 8px 24px var(--k08); }
.cx-join-box.is-bad { box-shadow: 0 0 0 2px #B13D2A, 0 8px 24px var(--k08); }
.cx-join-box > svg { width: 22px; height: 22px; flex: none; fill: none; stroke: var(--ink-2); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.cx-join-box input { flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: transparent; font: 400 18px/1.2 var(--font); color: var(--ink); }
.cx-join-box input::placeholder { color: var(--ink-2); }
/* Aqua Splash accent with Abyss text. */
.cx-enter {
  flex: none; display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 16px; border: 0; border-radius: var(--pill);
  background: #85CED0; color: var(--ink); font: 500 14px/1 var(--font); cursor: pointer;
  transition: background-color var(--duration-quick) var(--ease-out), transform var(--duration-quick) var(--ease-out);
}
.cx-enter svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.cx-enter:hover { background: #0BA6AD; }
.cx-enter:active { transform: translateY(1px); }
.cx-enter:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.cx-err { font-size: 15px; line-height: 1.5; color: #B13D2A; min-height: 0; }
.cx-err:empty { display: none; }
.cx-done { display: grid; gap: 8px; justify-items: center; padding: 22px 28px; border-radius: 24px; background: var(--surface); box-shadow: 0 0 0 1px var(--rule), 0 8px 24px var(--k08); max-width: 560px; }
.cx-done[hidden] { display: none; }
.cx-done:focus { outline: none; }
.cx-done b { font: 700 22px/1.2 var(--display); }
.cx-done p { color: var(--ink-2); }
.cx-down { position: absolute; bottom: 18px; left: 50%; translate: -50% 0; z-index: 2; color: var(--ink-2); display: grid; place-items: center; width: 44px; height: 44px; border-radius: var(--pill); }
.cx-down svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ───────── Who is QuantCorner ─────────
   Without pinning (narrow screens, reduced motion) this is an ordinary block under the hero. */
.cx-stage { background: var(--tint); }
.cx-about { padding: clamp(56px, 10vw, 120px) 0; }
.cx-about-inner {
  --g: clamp(32px, 6vw, 96px); --W: min(1120px, 100vw - 2 * var(--pad));
  width: var(--W); margin-inline: auto; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: var(--g); align-items: center;
}
.cx-about-logo img { display: block; width: 100%; height: auto; }
.cx-about-copy { display: grid; gap: 16px; justify-items: start; }
.cx-about-eyebrow { font: 500 15px/1.5 var(--font); color: var(--teal-ink); }
.cx-about-reveal { margin: 0; }
/* The whole panel opens /about: a link stretched over it (above the logo and text). */
.cx-about-inner { position: relative; }
.cx-about-link { position: absolute; inset: 0; z-index: 1; border-radius: 8px; cursor: pointer; }
.cx-about-link:focus-visible { outline: 2px solid var(--teal-ink); outline-offset: -6px; }
.cx-about-inner:has(.cx-about-link:hover) .cx-about-eyebrow { text-decoration: underline; text-underline-offset: 4px; }
/* Handwritten, like the changing line of the headline (Sriracha has one weight). */
/* Two classes, to win over the size and weight that ScrollReveal.css sets on .scroll-reveal-text. */
.cx-about .cx-about-text { font: 400 clamp(19px, 1.9vw, 30px)/1.6 "Sriracha", cursive; font-synthesis: none; color: var(--ink); }
@media (max-width: 860px) {
  .cx-about-inner { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .cx-about-logo { width: min(260px, 70%); }
}

/* ───────── Pinned scene (html.pinning, set by assets/main.js; --p runs 0 to 1 over the scene) ─────────
   0.00–0.14 the hero zooms towards the reader, blurs and goes     0.11–0.22 the logo arrives in the middle
   0.26–0.36 the logo moves left                                   0.34–0.48 the text is revealed (AboutReveal.tsx)
   0.55–0.62 the panel becomes a sheet of paper
   0.64–0.78 the sheet crumples, 0.78–0.97 it is thrown (PaperScene.tsx)   0.88–0.98 the stage goes dark */
html.pinning .cx-scene {
  --z: clamp(0, calc(var(--p) / 0.14), 1);
  --l: clamp(0, calc((var(--p) - 0.11) / 0.11), 1);
  --s0: clamp(0, calc((var(--p) - 0.26) / 0.1), 1);
  --s: calc(var(--s0) * var(--s0) * (3 - 2 * var(--s0)));
  --e: clamp(0, calc((var(--p) - 0.32) / 0.04), 1);
  --k: clamp(0, calc((var(--p) - 0.55) / 0.07), 1);
  --dk: clamp(0, calc((var(--p) - 0.88) / 0.1), 1);
}
html.pinning .cx-stage { background: color-mix(in srgb, var(--dark) calc(var(--dk) * 100%), var(--tint)); }
html.pinning .cx-hero { position: absolute; inset: 0; min-height: 0; background: transparent; }
html.pinning .cx-center { transform: scale(calc(1 + var(--z) * var(--z) * 5)); opacity: calc(1 - var(--z) * 1.15); filter: blur(calc(var(--z) * 18px)); }
html.pinning .cx-terms { translate: calc(var(--z) * 30vw) -50%; opacity: calc(1 - var(--z) * 2); }
html.pinning .cx-down { opacity: calc(1 - var(--z) * 4); }
html.pinning .cx-scene.is-zoomed .cx-hero { visibility: hidden; }

html.pinning .cx-about { position: absolute; inset: 0; z-index: 3; padding: 0; display: grid; place-items: center; pointer-events: none; }
html.pinning .cx-scene.is-about .cx-about-copy { pointer-events: auto; }
/* Clickable only while the panel is shown (is-about: p 0.34–0.58), not while the logo flies in or the sheet crumples. */
html.pinning .cx-about-link { pointer-events: none; }
html.pinning .cx-scene.is-about .cx-about-link { pointer-events: auto; }
/* The panel is the sheet: its own box, padding included, is what PaperScene.tsx photographs. */
/* The sheet fills the stage, less the 24px margin PaperCrumple keeps around a sheet; its content stays 1120px wide at most. */
html.pinning .cx-stage { container-type: inline-size; }
html.pinning .cx-about-inner {
  --W: calc(100cqw - 48px); --pd: max(clamp(28px, 3.4vw, 56px), calc((var(--W) - 1120px) / 2));
  position: relative; isolation: isolate; width: var(--W); min-height: calc(100svh - 48px); align-content: center; padding: 72px var(--pd) 40px;
}
html.pinning .cx-about-inner::before {
  content: ""; position: absolute; inset: 0; z-index: -1; background: #FFFFFF; box-shadow: 0 6px 10px rgb(0 0 0 / 0.08);
  opacity: var(--k); transform: scale(calc(0.97 + 0.03 * var(--k)));
}
html.pinning .cx-about-logo {
  --off: calc(var(--W) / 2 - var(--pd) - (var(--W) - 2 * var(--pd) - var(--g)) / 4.3);
  opacity: var(--l); filter: blur(calc((1 - var(--l)) * 14px));
  transform: translateX(calc(var(--off) * (1 - var(--s)))) scale(calc((0.35 + 0.65 * var(--l)) * (1.35 - 0.35 * var(--s))));
}
html.pinning .cx-about-eyebrow { opacity: var(--e); transform: translateY(calc((1 - var(--e)) * 12px)); }
/* The server-rendered words are fully visible until AboutReveal hydrates and takes them to 0, which showed as a flash
   over the hero on load. Keep the block hidden until just before the reveal starts (0.34). */
html.pinning .cx-about-reveal { opacity: clamp(0, calc((var(--p) - 0.33) / 0.01), 1); }

/* The WebGL sheet covers the stage and stays hidden until it is ready and its turn has come.
   Hidden with opacity, not visibility: PaperCrumple sets visibility: visible on its own canvas, which would
   show through a hidden parent and cover the hero. */
.cx-ball { display: none; }
html.pinning .cx-ball { display: block; position: absolute; inset: 0; z-index: 4; pointer-events: none; opacity: 0; will-change: transform; }
html.pinning .cx-scene.is-paper3d .cx-ball { opacity: 1; }
html.pinning .cx-scene.is-paper3d .cx-about-inner { visibility: hidden; }

/* ───────── Who is it for, dark (Abyss page, raised surfaces, Aqua as primary with Abyss text) ───────── */
.who--dark { background: var(--dark); color: var(--on-dark); }
.who--dark .who-title h2 { color: var(--on-dark); }
.who--dark .who-card { background: var(--dark-raised); color: var(--on-dark); box-shadow: none; }
.who--dark .who-card p { color: var(--on-dark-2); }
.who--dark .who-card--tint { background: #1F434A; }
.who--dark .who-card--teal { background: var(--strong); }
.who--dark .who-card--teal p { color: rgba(255, 255, 255, 0.78); }
.who--dark .who-card--primary { background: var(--teal-accent); color: var(--ink); }
.who--dark .who-card--primary p { color: var(--ink); }
.who--dark .pill, .who--dark .pill--light, .who--dark .pill--tint, .who--dark .pill--white { background: var(--dark); color: var(--teal-accent); box-shadow: none; }

/* Video cards on the home page: YouTube thumbnails are 16:9. */
.lcard-media--video { aspect-ratio: 16 / 9; height: auto; }
/* Thai headings in this section need more line height than the Latin default. */
.who--dark .who-title h2, .who--dark .who-card h3 { line-height: 1.35; }

/* The home navigation scrolls away with the first screen. */
.hdr { position: absolute; }

/* ───────── Phones (≤ 860px): the pinned desktop scenes are off; assets/mobile.js adds the classes used here ─────────
   On wide screens these wrappers change nothing: .who-cards is display: contents, the dots and the term copies are hidden. */
.who-cards { display: contents; }
.who-dots { display: none; }
.term.is-clone { display: none; }

@media (max-width: 860px) {
  /* "คุณมาที่นี่เพราะอยากได้อะไร": a swipe carousel that snaps card by card; the next card peeks in from the right. */
  .who-track { display: block; padding: 24px 0 56px; }
  .who-title { padding: 40px var(--pad) 24px; }
  .who-cards {
    position: relative; display: flex; gap: 12px; padding: 4px var(--pad) 8px;
    overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scroll-padding-inline: var(--pad);
    scrollbar-width: none;
  }
  .who-cards::-webkit-scrollbar { display: none; }
  .who-card {
    flex: none; width: min(82vw, 420px); min-height: min(420px, 60svh); scroll-snap-align: start;
    transition: transform var(--duration-medium) var(--ease-smooth-out), opacity var(--duration-medium) var(--ease-smooth-out);
  }
  .who-cards.is-ready .who-card:not(.is-active) { transform: scale(0.94); opacity: 0.6; }
  .who-dots { display: flex; justify-content: center; gap: 8px; margin-top: 20px; }
  .who-dots i { width: 6px; height: 6px; border-radius: 3px; background: var(--on-dark-2); transition: width var(--duration-fast) var(--ease-out), background-color var(--duration-fast) var(--ease-out); }
  .who-dots i.is-on { width: 22px; background: var(--teal-accent); }

  /* The 29 terms: six ticker rows gliding in turn left and right, like a market tape (mobile.js doubles each row). */
  #terms .wall { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; padding: 8px 0 72px; overflow: hidden; }
  #terms .wall-col { display: block; overflow: hidden; }
  #terms .wall-col > ul {
    display: flex; gap: 10px; width: max-content; padding-right: 10px;
    animation: qc-ticker calc(34s * var(--k)) linear infinite; animation-play-state: paused;
  }
  #terms .wall.is-live .wall-col > ul { animation-play-state: running; }
  #terms .wall-col:nth-child(even) > ul { animation-direction: reverse; }
  #terms .term, #terms .term.is-clone {
    display: flex; flex: none; aspect-ratio: auto; flex-direction: row; align-items: baseline; gap: 10px;
    padding: 12px 16px; font-size: 16px; white-space: nowrap;
  }
}
@keyframes qc-ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* Lessons slide in from alternate sides; the circles grow into place. */
@media (max-width: 860px) and (prefers-reduced-motion: no-preference) {
  html.js .m-rise { opacity: 0; transition: opacity 650ms var(--ease-smooth-out), transform 650ms var(--ease-smooth-out); }
  html.js .lesson.m-rise:nth-child(odd) { transform: translateX(-28px); }
  html.js .lesson.m-rise:nth-child(even) { transform: translateX(28px); }
  html.js .circle.m-rise { transform: scale(0.86); }
  html.js .lesson.m-rise.is-in, html.js .circle.m-rise.is-in { opacity: 1; transform: none; }
}
/* Reduced motion: the terms wrap and stay still, nothing slides. */
@media (max-width: 860px) and (prefers-reduced-motion: reduce) {
  #terms .wall-col > ul { animation: none; flex-wrap: wrap; width: auto; padding: 0 var(--pad); }
  #terms .term.is-clone { display: none; }
  .who-card { transition: none; }
  .who-cards.is-ready .who-card:not(.is-active) { transform: none; }
}

/* ───────── Otter finale (phones): the page ends with the otter dancing full screen ─────────
   The dance is the GIF itself. .otter-beat adds a bounce on each beat of the music: assets/sfx.js sets --beat (0 to 1)
   and --sway (-1 to 1) on .otter-finale while music plays; both stay 0 otherwise. */
.otter-finale { display: none; }
@media (max-width: 860px) {
  .otter-finale { display: grid; place-items: center; min-height: 100svh; overflow: hidden; background: var(--tint); }
  .otter-stage { position: relative; display: grid; justify-items: center; width: min(96vw, 78svh * 0.914, 560px); padding-bottom: 6svh; }
  .otter-beat {
    width: 100%; transform-origin: 50% 100%;
    transform: translate(calc(var(--sway, 0) * 10px), calc(var(--beat, 0) * 16px)) rotate(calc(var(--sway, 0) * 4deg)) scale(calc(1 + var(--beat, 0) * 0.04), calc(1 - var(--beat, 0) * 0.06));
  }
  .otter-beat picture, .otter-dance { display: block; width: 100%; height: auto; }
  .otter-shadow {
    position: absolute; left: 50%; bottom: calc(6svh + 2%); width: 56%; height: 26px; border-radius: 50%; translate: -50% 0;
    background: radial-gradient(closest-side, rgb(6 24 28 / 0.2), transparent);
  }
}

/* Framed paper voyage. The stage holds the question and brig still while the
   desktop track or the native mobile carousel takes the scenery past them. */
.who--frames .pin-stage {
  --travel: var(--p, 0);
  --entry: clamp(0, (var(--travel) - .045) / .145, 1);
  --dock: calc(var(--entry) * var(--entry) * (3 - 2 * var(--entry)));
  --frame-width: min(60vw, 780px);
  --frame-gap: 20px;
  --lead: 84vw;
  --upper: clamp(16px, 3svh, 32px);
  --corner-scale: .43;
  position: relative;
  container-type: inline-size;
  isolation: isolate;
  overflow: clip;
  background: var(--dark);
}
html.pinning .who--frames .pin-stage { position: sticky; }
.who--frames .voyage-hud { padding: 32px var(--pad) 8px; }
.who--frames .voyage-heading { width: max-content; max-width: 100%; }
.who--frames #who-title {
  color: var(--on-dark);
  font-size: clamp(40px, 4.9vw, 74px);
  line-height: 1.32;
}
.voyage-water { display: none; }
.voyage-rock-toggle:not([hidden]) {
  position: absolute; top: var(--upper); right: var(--pad); pointer-events: auto;
  min-height: 44px; padding: 0 6px; font: 500 14px/1.4 var(--font);
  background: transparent; border: 0; color: var(--teal-accent); cursor: pointer;
}
.voyage-rock-toggle:hover { text-decoration: underline; text-underline-offset: .25em; }
.voyage-rock-toggle:focus-visible { outline: 2px solid var(--teal-accent); outline-offset: 2px; }
html.pinning .who--frames .who-track {
  gap: var(--frame-gap);
  padding: clamp(74px, 11svh, 112px) max(var(--pad), calc((100vw - var(--frame-width)) / 2)) clamp(32px, 6svh, 64px) var(--lead);
}
html.pinning .who--frames .who-card { width: var(--frame-width); }
#who.who--frames .who-card {
  position: relative; isolation: isolate; overflow: clip; justify-content: flex-end;
  padding: clamp(24px, 3vw, 40px);
  border: 1px solid rgb(244 250 250 / .67);
  box-shadow: inset 0 0 0 4px rgb(244 250 250 / .1);
  background: var(--dark-raised) var(--sky) center / cover no-repeat;
  color: #fff;
}
#who.who--frames .who-card p { color: #f4fafa; }
.paper-scenery { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.paper-scenery::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(0deg, rgb(6 24 28 / .96), rgb(6 24 28 / .72) 15%, transparent 38%);
}
.paper-piece {
  position: absolute; height: auto; max-height: var(--max-height, 28%);
  object-fit: contain; object-position: center bottom;
  transform: translate3d(calc(-50% + var(--camera, 0px) * var(--counter-travel)), 0, 0);
}
/* Positive travel offsets the track motion for distant paper. Negative travel
   overtakes it: a foreground crest crosses the boat before its headland. */
.paper-sky      { --counter-travel: .78; --max-height: 19%; }
.paper-cloud    { --counter-travel: .66; --max-height: 26%; }
.paper-mountain { --counter-travel: .43; --max-height: 30%; }
.paper-coast    { --counter-travel: .29; --max-height: 20%; }
.paper-surface  { --counter-travel: .08; --max-height: 14%; }
.paper-wave     { --counter-travel: -.24; --max-height: 31%; }
.paper-foam     { --counter-travel: -.47; --max-height: 16%; }
.voyage-still {
  position: absolute; left: 50%; top: 53%; width: 38%; height: auto;
  transform: translate(-50%, -50%);
}

.who--frames.is-sailing .voyage-still { display: none; }
.who--frames.is-sailing .voyage-hud {
  position: absolute; inset: 0; z-index: 3; padding: 0; pointer-events: none; container-type: size;
}
.who--frames.is-sailing .voyage-heading {
  position: absolute; left: var(--pad); top: var(--upper);
  max-width: calc(100% - var(--pad) * 2); transform-origin: top left;
  transform: translate3d(
    calc((1 - var(--dock)) * (50cqw - var(--pad) - 50%)),
    calc((1 - var(--dock)) * (50cqh - var(--upper) - 50%)), 0
  ) scale(calc(1 - (1 - var(--corner-scale)) * var(--dock)));
}
.who--frames.is-sailing .voyage-title-ready { opacity: 0; transform: translateY(26px); transition: transform .9s ease-out, opacity .9s ease-out; }
.who--frames.is-sailing .voyage-title-ready.is-visible { opacity: 1; transform: none; }
.who--frames.is-sailing .voyage-water { display: block; position: absolute; inset: 0; z-index: 2; pointer-events: none; }
.voyage-vessel {
  position: absolute; left: 50%; top: 50%; width: min(26vw, 38svh, 410px);
  translate: -50% -50%;
  transform: translate3d(calc((var(--dock) - 1) * (50cqw + 65%)), 0, 0);
  opacity: var(--entry);
}
.voyage-vessel img {
  display: block; width: 100%; height: auto; transform-origin: 50% 86%;
  animation: framed-swell 5.6s ease-in-out infinite; animation-play-state: paused;
}
.who--frames.is-rocking .voyage-vessel img { animation-play-state: running; }
@keyframes framed-swell {
  0%, 100% { transform: translateY(1px) rotate(-1.15deg); }
  35% { transform: translateY(-3px) rotate(.45deg); }
  66% { transform: translateY(2px) rotate(1.35deg); }
}
.who--frames.is-sailing .who-card {
  --track-offset: calc(0px - var(--x, 0px));
  --rest-center: calc(var(--lead) + var(--index) * (var(--frame-width) + var(--frame-gap)) + var(--frame-width) / 2);
  --camera: clamp(calc(-.85 * var(--frame-width)), calc(50cqw + var(--track-offset) - var(--rest-center)), calc(.85 * var(--frame-width)));
}
@media (max-width: 860px) {
  .who--frames .pin-stage {
    --travel: var(--swipe, 0); --frame-width: min(82vw, 620px);
    --frame-gap: 12px; --lead: calc((100vw - var(--frame-width)) / 2); --corner-scale: .58;
    --upper: clamp(12px, 2.2svh, 22px);
    --top-band: clamp(76px, 11svh, 112px);
    --bottom-band: clamp(80px, 10svh, 100px);
  }
  .who--frames.is-sailing .pin-stage { min-height: 100svh; }
  .who--frames #who-title { font-size: clamp(31px, 8.6vw, 48px); }
  .who--frames #who-title span { display: block; }
  .who--frames.is-sailing #who-title { text-shadow: 0 2px 7px rgb(6 24 28 / .8); }
  .who--frames .who-track { padding: 12px 0 48px; }
  .who--frames.is-sailing .who-track { padding: var(--top-band) 0 var(--bottom-band); }
  .who--frames .who-cards { gap: var(--frame-gap); padding-inline: var(--lead); scroll-padding-inline: 0; }
  .who--frames .who-card { width: var(--frame-width); min-height: clamp(340px, calc(100svh - var(--top-band) - var(--bottom-band) - 40px), 780px); scroll-snap-align: center; }
  .who--frames.is-sailing .who-card { --track-offset: var(--native-offset, 0px); }
  .who--frames .who-cards.is-ready .who-card:not(.is-active) { opacity: 1; transform: none; }
  .voyage-vessel { width: min(46vw, 30svh); }
}
@media (max-width: 360px), (max-width: 860px) and (max-height: 480px) {
  #who.who--frames .who-card { padding: 18px; }
  #who.who--frames .who-card h3 { font-size: 21px; }
  #who.who--frames .who-card p { font-size: 14px; margin-top: 6px; }
}
@media (min-width: 861px) {
  html:not(.pinning) .who--frames .who-card { width: calc(50% - 8px); min-height: 360px; }
}

/* 2026-12-05: a voyage card can link out (/quant-history); the title link covers the whole card */
.who-card .voyage-link { color: inherit; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 6px; text-decoration-color: rgb(154 221 224 / .7); }
.who-card .voyage-link::after { content: ""; position: absolute; inset: 0; z-index: 5; }
.who-card .voyage-link:hover { text-decoration-color: #9ADDE0; }
.who-card .voyage-link:focus-visible { outline: none; }
.who-card:has(.voyage-link:focus-visible) { outline: 3px solid #9ADDE0; outline-offset: -3px; }
