/*
 * trendy.ai — the home page.
 *
 * Dark, in the app's own palette: ink, bone, cobalt and lime, set in Geist.
 * Motion is transforms and opacity only. Loops live here; anything tied to the
 * scroll reads one custom property per scene, --p (0 → 1), which home.js
 * writes. Without the script the page still reads top to bottom: every hidden
 * start state is scoped to .js.
 */

:root {
  --ink: #0a0a0a;
  --ink-2: #121211;
  --ink-3: #1b1b19;
  --bone: #f2f2ee;
  --bone-2: rgb(242 242 238 / 0.72);
  --bone-3: rgb(242 242 238 / 0.5);
  --line: rgb(242 242 238 / 0.09);
  --line-2: rgb(242 242 238 / 0.16);
  --cobalt: #2640ff;
  --cobalt-2: #4a63ff;
  --blue: #5166ff;
  --peri: #8190ff;
  --lime: #d8ff00;
  --sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --gutter: clamp(16px, 4.2vw, 48px);
  --maxw: 1280px;
  --expo: cubic-bezier(0.16, 1, 0.3, 1);
  --quint: cubic-bezier(0.22, 1, 0.36, 1);
  --spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --inout: cubic-bezier(0.65, 0, 0.35, 1);
  color-scheme: dark;
}

/*
 * Geist has no Japanese or Korean glyphs; the system's own faces take those
 * characters, and the brand guide's Noto Sans comes last where it is installed.
 */
:root:lang(ja) {
  --sans: "Geist", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic", Meiryo, system-ui, sans-serif;
  line-break: strict;
}

:root:lang(ko) {
  --sans: "Geist", "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", system-ui, sans-serif;
  word-break: keep-all;
}

/* ───────────────────────────── base ───────────────────────────── */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  background: var(--ink);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: 80px;
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--ink);
  color: var(--bone);
  font: 400 16px/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  overflow-x: clip;
}

img {
  display: block;
  max-width: 100%;
}

/* Author display rules (.btn and friends) would otherwise outrank it. */
[hidden] {
  display: none !important;
}

a {
  color: inherit;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 2px solid var(--lime);
  outline-offset: 3px;
  border-radius: 10px;
}

::selection {
  background: var(--lime);
  color: var(--ink);
}

.wrap {
  width: min(100% - 2 * var(--gutter), var(--maxw));
  margin-inline: auto;
}

/* Film grain over everything: a static tile, so it costs one composite. */
.grain {
  position: fixed;
  inset: 0;
  z-index: 90;
  pointer-events: none;
  opacity: 0.07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .9 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Reading progress, along the very top. */
.bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 70;
  height: 2px;
  background: var(--lime);
  transform-origin: 0 50%;
  transform: scaleX(0);
  box-shadow: 0 0 12px rgb(216 255 0 / 0.7);
}

/* ───────────────────────────── type ───────────────────────────── */

.label {
  margin: 0 0 18px;
  font: 500 12px/1 var(--mono);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--lime);
  display: flex;
  align-items: center;
  gap: 10px;
}

.label::before {
  content: "";
  width: 18px;
  height: 1px;
  background: currentColor;
}

.h2 {
  margin: 0;
  font-weight: 700;
  font-size: clamp(40px, 8.2vw, 104px);
  line-height: 0.94;
  letter-spacing: -0.052em;
  text-wrap: balance;
}

.sec-head {
  margin-bottom: clamp(28px, 5vw, 56px);
}

.sec-body {
  margin: 20px 0 0;
  max-width: 46ch;
  font-size: clamp(16px, 1.6vw, 19px);
  color: var(--bone-2);
  text-wrap: pretty;
}

/*
 * Words rise from under their own baseline. The clip box is padded so accents
 * above (İ) and descenders below (g, y, ş) survive the tight line height.
 */
.w {
  display: inline-block;
  overflow: hidden;
  vertical-align: top;
  padding: 0.1em 0.02em 0.14em;
  margin: -0.1em -0.02em -0.14em;
}

.w > span {
  display: inline-block;
  transition: transform 1.1s var(--expo);
  transition-delay: calc(var(--i, 0) * 70ms + var(--d, 0ms));
}

.js .w > span {
  transform: translate3d(0, 108%, 0) rotate(5deg);
  transform-origin: 0 100%;
}

.js .in .w > span,
.js .in.w > span {
  transform: none;
}

/* Generic rise-in for blocks. */
.js .rv {
  opacity: 0;
  transform: translate3d(0, 34px, 0);
  transition:
    opacity 0.9s var(--expo) var(--d, 0ms),
    transform 1.2s var(--expo) var(--d, 0ms);
}

.js .rv.in {
  opacity: 1;
  transform: none;
}

/* The wordmark's full stop: a lime square. */
.sq {
  display: inline-block;
  width: 0.17em;
  height: 0.17em;
  margin-left: 0.05em;
  background: var(--lime);
  vertical-align: baseline;
  transition: transform 0.9s var(--spring) 0.95s;
}

.js .sq {
  transform: scale(0) rotate(-90deg);
}

.js .in .sq {
  transform: none;
}

/* ───────────────────────────── buttons ───────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  font: 600 15px/1 var(--sans);
  letter-spacing: -0.01em;
  text-decoration: none;
  white-space: nowrap;
  transition:
    transform 0.5s var(--expo),
    background-color 0.25s,
    color 0.25s,
    box-shadow 0.4s;
}

.btn-sm {
  height: 38px;
  padding: 0 16px;
  font-size: 14px;
}

.btn-lime {
  background: var(--lime);
  color: var(--ink);
}

.btn-lime:hover {
  box-shadow: 0 10px 30px -8px rgb(216 255 0 / 0.55);
}

.btn-ghost {
  border: 1px solid var(--line-2);
  color: var(--bone);
  background: rgb(242 242 238 / 0.03);
}

.btn-ghost:hover {
  border-color: var(--bone-3);
  background: rgb(242 242 238 / 0.07);
}

.stores {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.store {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  height: 60px;
  padding: 0 24px 0 18px;
  border-radius: 18px;
  background: var(--bone);
  color: var(--ink);
  text-decoration: none;
  overflow: hidden;
  isolation: isolate;
  transition:
    transform 0.5s var(--expo),
    box-shadow 0.4s var(--expo),
    background-color 0.25s;
}

.store svg {
  width: 26px;
  height: 26px;
  flex: none;
}

.store small {
  display: block;
  font: 500 11px/1.1 var(--sans);
  opacity: 0.7;
}

.store b {
  display: block;
  font: 700 19px/1.15 var(--sans);
  letter-spacing: -0.025em;
}

/* A sheen that crosses the button on hover. */
.store::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(105deg, transparent 30%, rgb(255 255 255 / 0.55) 50%, transparent 70%);
  transform: translateX(-120%);
}

.store:hover::after {
  transform: translateX(120%);
  transition: transform 0.9s var(--quint);
}

.store:hover {
  box-shadow: 0 18px 40px -18px rgb(216 255 0 / 0.45);
}

/* Side by side on a phone: both stores in one row. */
@media (max-width: 520px) {
  .store {
    flex: 1 1 0;
    min-width: 0;
    justify-content: center;
    gap: 10px;
    padding: 0 12px;
  }

  .store b {
    font-size: 17px;
  }

  .store svg {
    width: 23px;
    height: 23px;
  }
}

.store-alt {
  background: rgb(242 242 238 / 0.06);
  color: var(--bone);
  box-shadow: inset 0 0 0 1px var(--line-2);
}

.store-alt::after {
  background: linear-gradient(105deg, transparent 30%, rgb(255 255 255 / 0.14) 50%, transparent 70%);
}

.store-alt:hover {
  background: rgb(242 242 238 / 0.1);
  box-shadow: inset 0 0 0 1px var(--bone-3);
}

[data-magnetic] {
  will-change: transform;
}

/* ───────────────────────────── nav ───────────────────────────── */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: calc(12px + env(safe-area-inset-top)) var(--gutter) 12px;
  border-bottom: 1px solid transparent;
  transition:
    transform 0.6s var(--expo),
    background-color 0.35s,
    border-color 0.35s;
}

.nav.solid {
  background: rgb(10 10 10 / 0.62);
  -webkit-backdrop-filter: saturate(1.6) blur(18px);
  backdrop-filter: saturate(1.6) blur(18px);
  border-bottom-color: var(--line);
}

.nav.away {
  transform: translate3d(0, -110%, 0);
}

.wordmark {
  margin: 0;
  line-height: 0;
}

.wordmark img {
  width: 116px;
  height: auto;
}

.nav-links {
  display: none;
}

.nav .langs {
  margin-left: auto;
}

/* A phone has room for the mark, the language and the button, just. */
@media (max-width: 459px) {
  .nav {
    gap: 8px;
  }

  .wordmark img {
    width: 98px;
  }

  .nav .langs .chev {
    display: none;
  }

  .nav > .btn {
    padding: 0 14px;
  }
}

@media (max-width: 359px) {
  .nav > .btn {
    display: none;
  }
}

@media (min-width: 900px) {
  .nav-links {
    display: flex;
    gap: 2px;
    margin-left: auto;
    padding: 4px;
    border-radius: 999px;
    background: rgb(242 242 238 / 0.04);
    box-shadow: inset 0 0 0 1px var(--line);
  }

  .nav-links a {
    position: relative;
    padding: 8px 14px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 500;
    color: var(--bone-2);
    text-decoration: none;
    transition:
      color 0.25s,
      background-color 0.25s;
  }

  .nav-links a:hover,
  .nav-links a[aria-current="true"] {
    color: var(--bone);
    background: rgb(242 242 238 / 0.08);
  }

  .nav .langs {
    margin-left: 8px;
  }
}

/* ───────────────────────────── hero ───────────────────────────── */

.hero {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
  min-height: 100svh;
  padding: calc(92px + env(safe-area-inset-top)) 0 64px;
  display: grid;
  align-items: center;
  overflow: hidden;
  overflow: clip;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  transform: translate3d(calc(var(--mx, 0) * -24px), calc(var(--my, 0) * -24px + var(--p, 0) * 22vh), 0);
  transition: transform 1.2s var(--expo);
}

/* A dot grid, lit in the middle. */
.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgb(242 242 238 / 0.1) 1px, transparent 1.4px);
  background-size: 26px 26px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 60% 45%, #000 20%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 60% at 60% 45%, #000 20%, transparent 75%);
}

.blob {
  position: absolute;
  border-radius: 50%;
  animation: drift 26s var(--inout) infinite alternate;
}

.blob-a {
  width: 80vmax;
  height: 80vmax;
  left: -30vmax;
  top: -38vmax;
  background: radial-gradient(closest-side, rgb(38 64 255 / 0.8), rgb(38 64 255 / 0));
}

.blob-b {
  width: 64vmax;
  height: 64vmax;
  right: -26vmax;
  top: -6vmax;
  background: radial-gradient(closest-side, rgb(129 144 255 / 0.36), rgb(129 144 255 / 0));
  animation-duration: 32s;
  animation-delay: -9s;
}

.blob-c {
  width: 46vmax;
  height: 46vmax;
  left: 34%;
  bottom: -28vmax;
  background: radial-gradient(closest-side, rgb(216 255 0 / 0.2), rgb(216 255 0 / 0));
  animation-duration: 21s;
  animation-delay: -4s;
}

@keyframes drift {
  0% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  50% {
    transform: translate3d(6vmax, 4vmax, 0) scale(1.12);
  }
  100% {
    transform: translate3d(-4vmax, 7vmax, 0) scale(0.94);
  }
}

.hero-grid {
  width: min(100% - 2 * var(--gutter), var(--maxw));
  margin-inline: auto;
  display: grid;
  grid-template-areas: "kicker" "title" "deck" "lede" "cta";
  row-gap: 18px;
}

/* On a phone the deck sits between the headline and the words under it. */
.hero-copy {
  display: contents;
}

.kicker {
  grid-area: kicker;
}

.display {
  grid-area: title;
}

.deck {
  grid-area: deck;
}

.lede {
  grid-area: lede;
}

.hero-cta {
  grid-area: cta;
}

@media (min-width: 980px) {
  .hero-grid {
    grid-template-columns: minmax(0, 1.04fr) minmax(0, 0.96fr);
    grid-template-areas: "copy deck";
    align-items: center;
    column-gap: 24px;
  }

  .hero-copy {
    position: relative;
    z-index: 2;
    display: block;
    grid-area: copy;
  }
}

.kicker {
  margin: 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  justify-self: start;
  padding: 8px 14px 8px 10px;
  border-radius: 999px;
  background: rgb(242 242 238 / 0.05);
  box-shadow: inset 0 0 0 1px var(--line-2);
  font: 500 12px/1 var(--mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--bone-2);
}

.live {
  position: relative;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--lime);
}

.live::after {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1px solid var(--lime);
  animation: ping 2s var(--quint) infinite;
}

@keyframes ping {
  from {
    transform: scale(0.5);
    opacity: 1;
  }
  to {
    transform: scale(2.2);
    opacity: 0;
  }
}

/*
 * The headline never wraps, so it is sized to fit: the page states how many ems
 * its longer line runs (--em), and the face is as large as the room allows, up
 * to the size the English was drawn at.
 */
.display {
  --room: calc(100vw - 2 * var(--gutter));
  margin: 14px 0 0;
  font-weight: 700;
  font-size: clamp(34px, min(15.4vw, var(--room) / var(--em, 5.3) * 0.96), 150px);
  line-height: 0.9;
  letter-spacing: -0.062em;
}

.display .line {
  display: block;
  white-space: nowrap;
}

@media (min-width: 980px) {
  .display {
    --room: calc((min(100vw - 2 * var(--gutter), var(--maxw)) - 24px) * 0.52);
    margin-top: 26px;
    font-size: clamp(52px, min(8.2vw, var(--room) / var(--em, 5.3) * 0.96), 136px);
  }
}

.lede {
  margin: 4px 0 0;
  max-width: 40ch;
  font-size: clamp(16.5px, 1.45vw, 19px);
  line-height: 1.6;
  color: var(--bone-2);
  text-wrap: pretty;
}

@media (min-width: 980px) {
  .lede {
    margin-top: 28px;
  }

  .hero-cta {
    margin-top: 34px;
  }
}

.fine {
  margin: 14px 0 0;
  font: 500 12px/1.4 var(--mono);
  letter-spacing: 0.06em;
  color: var(--bone-3);
}

/* Hero entrance: kicker, words, the square, then the rest. */
.js .hero .kicker,
.js .hero .lede,
.js .hero-cta {
  opacity: 0;
  transform: translate3d(0, 24px, 0);
  transition:
    opacity 1s var(--expo),
    transform 1.2s var(--expo);
}

.js .hero.in .kicker {
  opacity: 1;
  transform: none;
}

.js .hero.in .lede {
  opacity: 1;
  transform: none;
  transition-delay: 0.55s;
}

.js .hero.in .hero-cta {
  opacity: 1;
  transform: none;
  transition-delay: 0.7s;
}

.hero .w > span {
  transition-delay: calc(var(--i, 0) * 80ms + 120ms);
}

/* Scroll hint, desktop only. */
.cue {
  display: none;
}

@media (min-width: 980px) and (min-height: 760px) {
  .cue {
    position: absolute;
    left: 50%;
    bottom: 26px;
    display: grid;
    justify-items: center;
    gap: 10px;
    transform: translateX(-50%);
    font: 500 11px/1 var(--mono);
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--bone-3);
    opacity: calc(1 - var(--p, 0) * 6);
  }

  .cue i {
    position: relative;
    width: 1px;
    height: 44px;
    background: var(--line-2);
    overflow: hidden;
  }

  .cue i::after {
    content: "";
    position: absolute;
    left: 0;
    top: -40%;
    width: 1px;
    height: 40%;
    background: var(--lime);
    animation: cue 2.2s var(--inout) infinite;
  }
}

@keyframes cue {
  to {
    transform: translateY(350%);
  }
}

/* ─────────── the deck: live covers fanned out, shuffling ─────────── */

.deck {
  position: relative;
  height: clamp(330px, 98vw, 450px);
  margin: 4px calc(-1 * var(--gutter));
  perspective: 1600px;
}

@media (min-width: 980px) {
  .deck {
    height: min(680px, 78svh);
    margin: 0;
  }
}

.deck-tilt {
  position: absolute;
  inset: 0;
  z-index: 1;
  transform-style: preserve-3d;
  transform: rotateX(var(--tx, 0deg)) rotateY(var(--ty, 0deg));
  transition: transform 1s var(--expo);
}

.dcard {
  --cw: clamp(172px, 49vw, 232px);
  --spread: calc(54 + var(--p, 0) * 60);
  position: absolute;
  inset: 0;
  margin: auto;
  width: var(--cw);
  height: calc(var(--cw) * 1.25);
  border-radius: 22px;
  overflow: hidden;
  background: linear-gradient(155deg, var(--tint, #2640ff), var(--shade, #0a0a0a) 78%);
  box-shadow:
    0 40px 70px -30px rgb(0 0 0 / 0.85),
    inset 0 0 0 1px rgb(255 255 255 / 0.08);
  transform: translate3d(
      calc(var(--pos) * var(--spread) * 1%),
      calc(var(--abs) * 6% - var(--p, 0) * (30% + var(--abs) * 12%)),
      calc(var(--abs) * -70px)
    )
    rotate(calc(var(--pos) * (7deg + var(--p, 0) * 12deg)))
    scale(calc(1 - var(--abs) * 0.085));
  opacity: calc(1 - max(0, var(--abs) - 2));
  transition:
    transform 1.15s var(--expo),
    opacity 0.8s var(--expo);
}

@media (min-width: 980px) {
  .dcard {
    --cw: clamp(220px, 20vw, 316px);
    --spread: calc(38 + var(--p, 0) * 50);
  }

  .deck-tilt {
    left: 8%;
  }
}

@media (min-width: 1280px) {
  .dcard {
    --spread: calc(46 + var(--p, 0) * 50);
  }

  .deck-tilt {
    left: 4%;
  }
}

/* Cards away from the front sit in shadow. */
.dcard::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  background: rgb(10 10 10 / calc(var(--abs) * 0.22));
  transition: background-color 0.8s var(--expo);
  pointer-events: none;
}

.dcard.jump {
  transition: none;
}

/* Dealt from a single pile on the first paint. */
.js .hero:not(.in) .dcard {
  transform: translate3d(0, 30%, 0) rotate(calc(var(--pos) * 2deg)) scale(0.82);
  opacity: 0;
}

.hero.dealing .dcard {
  transition-delay: calc(0.35s + (3 - var(--k)) * 0.09s);
}

.dcard-media,
.dcard-media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.dcard-media img {
  object-fit: cover;
  opacity: 0;
  transform: scale(1.08);
  transition:
    opacity 0.8s,
    transform 1.6s var(--expo);
}

.dcard-media img.ok {
  opacity: 1;
  transform: scale(1);
}

.dcard figcaption {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 10px;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px 9px 9px;
  border-radius: 14px;
  background: rgb(10 10 10 / 0.58);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  font: 600 13.5px/1.2 var(--sans);
  letter-spacing: -0.01em;
  opacity: 0;
  transform: translate3d(0, 12px, 0);
  transition:
    opacity 0.4s,
    transform 0.6s var(--expo);
}

.dcard.front figcaption {
  opacity: 1;
  transform: none;
  transition-delay: 0.4s;
}

.dcard-kind {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  flex: none;
  border-radius: 8px;
  background: var(--lime);
  color: var(--ink);
}

.dcard-kind:empty {
  display: none;
}

.dcard-kind svg {
  width: 13px;
  height: 13px;
}

.dcard-title {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

/* Echo rings behind the deck. */
.rings {
  position: absolute;
  inset: 0;
  z-index: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
}

.rings i {
  position: absolute;
  width: min(120vw, 700px);
  aspect-ratio: 1;
  border-radius: 50%;
  border: 1px solid rgb(129 144 255 / 0.5);
  opacity: 0;
  animation: ripple 8s var(--quint) infinite;
  animation-delay: calc(var(--i) * -2s);
}

@keyframes ripple {
  0% {
    transform: scale(0.22);
    opacity: 0;
  }
  14% {
    opacity: 0.85;
  }
  100% {
    transform: scale(1.3);
    opacity: 0;
  }
}

/* Floating status chips, the way the app reports a render. */
.fchip {
  position: absolute;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 14px 9px 9px;
  border-radius: 16px;
  background: rgb(22 22 21 / 0.74);
  -webkit-backdrop-filter: blur(16px) saturate(1.5);
  backdrop-filter: blur(16px) saturate(1.5);
  box-shadow:
    inset 0 0 0 1px var(--line-2),
    0 24px 44px -20px rgb(0 0 0 / 0.9);
  font-size: 13px;
  line-height: 1.2;
  animation: bob 6s var(--inout) infinite alternate;
  transition:
    opacity 0.8s var(--expo),
    translate 1s var(--expo);
}

.js .hero:not(.in) .fchip {
  opacity: 0;
  translate: 0 20px;
}

.hero.in .fchip-make {
  transition-delay: 1.1s;
}

.hero.in .fchip-ready {
  transition-delay: 1.3s;
}

@keyframes bob {
  from {
    transform: translate3d(0, -6px, 0);
  }
  to {
    transform: translate3d(0, 6px, 0);
  }
}

.fchip small {
  display: block;
  font: 500 10.5px/1.2 var(--mono);
  letter-spacing: 0.04em;
  color: var(--bone-3);
  white-space: nowrap;
}

.fchip b {
  display: block;
  font: 700 15px/1.2 var(--sans);
  font-variant-numeric: tabular-nums;
}

.fchip-make {
  left: calc(var(--gutter) * 0.5);
  bottom: 4%;
  min-width: 170px;
}

.fchip-ready {
  right: calc(var(--gutter) * 0.5);
  top: 5%;
  animation-delay: -3s;
  font-weight: 600;
}

.fchip-ready svg {
  width: 26px;
  height: 26px;
  padding: 5px;
  border-radius: 9px;
  background: var(--lime);
  color: var(--ink);
  stroke-width: 2.6;
}

@media (min-width: 980px) {
  .fchip-make {
    left: -2%;
    bottom: 12%;
  }

  .fchip-ready {
    right: 2%;
    top: 10%;
  }
}

.fchip-ring {
  width: 36px;
  height: 36px;
  flex: none;
  transform: rotate(-90deg);
}

.fchip-ring circle {
  fill: none;
  stroke: rgb(242 242 238 / 0.14);
  stroke-width: 3.5;
}

.fchip-ring .arc {
  stroke: var(--lime);
  stroke-linecap: round;
  stroke-dasharray: 100;
  stroke-dashoffset: calc(100 - var(--k, 0.72) * 100);
}

.fchip-make.done b {
  color: var(--lime);
}

/* ───────────────────────────── ticker ───────────────────────────── */

.ticker {
  position: relative;
  z-index: 2;
  height: clamp(170px, 24vw, 280px);
  margin-top: -30px;
  overflow: hidden;
  overflow: clip;
}

.tape {
  position: absolute;
  left: -6%;
  width: 112%;
  top: 50%;
  overflow: hidden;
  white-space: nowrap;
  box-shadow: 0 30px 60px -30px rgb(0 0 0 / 0.9);
}

.tape-a {
  top: 58%;
  background: var(--lime);
  color: var(--ink);
  transform: translateY(-50%) rotate(-3.2deg);
}

.tape-b {
  top: 30%;
  background: var(--cobalt);
  color: #fff;
  transform: translateY(-50%) rotate(2.6deg);
}

.tape-track {
  display: flex;
  width: max-content;
  align-items: center;
  gap: 0.5em;
  padding: 0.34em 0;
  font: 700 clamp(26px, 5.4vw, 64px)/1 var(--sans);
  letter-spacing: -0.045em;
  will-change: transform;
}

.tape-track .echo-mark {
  width: 0.62em;
  height: 0.62em;
  flex: none;
  margin: 0 0.12em;
}

.tape-a .e1 {
  fill: var(--cobalt);
}

.tape-a .e2 {
  fill: var(--blue);
}

.tape-a .e3 {
  fill: var(--ink);
}

.tape-b .e1 {
  fill: var(--peri);
}

.tape-b .e2 {
  fill: #b7c0ff;
}

.tape-b .e3 {
  fill: var(--lime);
}

.tape-b .tape-track {
  font-size: clamp(20px, 3.6vw, 40px);
  font-weight: 600;
  letter-spacing: -0.03em;
}

/* ───────────────────────────── echo mark ───────────────────────────── */

.echo-mark .e1 {
  fill: var(--blue);
}

.echo-mark .e2 {
  fill: var(--peri);
}

.echo-mark .e3 {
  fill: var(--lime);
}

/* ───────────────────── how it works: pinned phone ───────────────────── */

.how {
  position: relative;
  padding-top: clamp(80px, 12vw, 170px);
}

.how-track {
  position: relative;
  height: 320vh;
}

.how-sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  display: flex;
  align-items: center;
  overflow: hidden;
  overflow: clip;
}

.how-grid {
  display: grid;
  justify-items: center;
  gap: 18px;
}

.phone-wrap {
  order: -1;
}

@media (min-width: 980px) {
  .how-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: center;
    justify-items: stretch;
    gap: 56px;
  }

  .phone-wrap {
    order: 0;
  }
}

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  width: 100%;
  max-width: 520px;
  text-align: center;
}

.step {
  grid-area: 1 / 1;
  opacity: 0;
  transform: translate3d(0, 18px, 0);
  transition:
    opacity 0.5s var(--expo),
    transform 0.8s var(--expo);
  pointer-events: none;
}

.step h3 {
  margin: 0;
  font-size: clamp(26px, 6.6vw, 44px);
  line-height: 1.02;
  letter-spacing: -0.04em;
  font-weight: 700;
}

.step h3 button {
  text-align: inherit;
  letter-spacing: inherit;
  line-height: inherit;
}

.step-num {
  display: block;
  margin-bottom: 10px;
  font: 500 12px/1 var(--mono);
  letter-spacing: 0.14em;
  color: var(--lime);
}

.step p {
  margin: 12px auto 0;
  max-width: 40ch;
  color: var(--bone-2);
  font-size: clamp(15px, 1.4vw, 18px);
  text-wrap: pretty;
}

.how-track[data-step="0"] .step[data-i="0"],
.how-track[data-step="1"] .step[data-i="1"],
.how-track[data-step="2"] .step[data-i="2"] {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

@media (min-width: 980px) {
  .steps {
    position: relative;
    grid-template-rows: auto;
    gap: 40px;
    padding-left: 34px;
    text-align: left;
    max-width: none;
  }

  /* The rail and its lime fill, which tracks the scroll. */
  .steps::before,
  .steps::after {
    content: "";
    position: absolute;
    left: 0;
    top: 4px;
    bottom: 4px;
    width: 2px;
    border-radius: 2px;
    background: var(--line-2);
  }

  .steps::after {
    background: var(--lime);
    transform-origin: 50% 0;
    transform: scaleY(var(--p, 0));
    box-shadow: 0 0 18px rgb(216 255 0 / 0.6);
  }

  .step {
    grid-area: auto;
    opacity: 0.26;
    transform: none;
    pointer-events: auto;
  }

  .step p {
    margin-left: 0;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition:
      max-height 0.7s var(--expo),
      opacity 0.5s,
      margin 0.7s var(--expo);
    margin-top: 0;
  }

  .how-track[data-step="0"] .step[data-i="0"] p,
  .how-track[data-step="1"] .step[data-i="1"] p,
  .how-track[data-step="2"] .step[data-i="2"] p {
    max-height: 8em;
    opacity: 1;
    margin-top: 14px;
  }

  .step h3 {
    font-size: clamp(30px, 3.3vw, 48px);
  }
}

.phone-wrap {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 16px;
}

.phone-glow {
  position: absolute;
  inset: -20% -40%;
  z-index: -1;
  background:
    radial-gradient(closest-side, rgb(38 64 255 / 0.55), transparent 70%),
    radial-gradient(closest-side at 70% 30%, rgb(216 255 0 / 0.14), transparent 60%);
  filter: blur(10px);
  animation: glow 7s var(--inout) infinite alternate;
}

@keyframes glow {
  to {
    transform: scale(1.12) rotate(8deg);
  }
}

.phone {
  position: relative;
  height: min(58svh, 560px);
  aspect-ratio: 9 / 19;
  padding: 9px;
  border-radius: 46px;
  background: linear-gradient(145deg, #2a2a28, #0d0d0c 40%, #1d1d1b);
  box-shadow:
    inset 0 0 0 1.5px rgb(255 255 255 / 0.14),
    0 60px 120px -40px rgb(38 64 255 / 0.6),
    0 40px 80px -40px rgb(0 0 0 / 0.95);
  transform: rotate(calc((var(--p, 0) - 0.5) * -4deg));
}

@media (min-width: 980px) {
  .phone {
    height: min(76svh, 690px);
    justify-self: center;
  }
}

.island {
  position: absolute;
  z-index: 6;
  top: 18px;
  left: 50%;
  width: 30%;
  height: 24px;
  border-radius: 20px;
  background: #000;
  transform: translateX(-50%);
}

.phone-screen {
  position: relative;
  height: 100%;
  border-radius: 38px;
  overflow: hidden;
  background: var(--bone);
  color: var(--ink);
  /* Each step's own progress, 0 → 1, written by home.js. */
  --s0: 0;
  --s1: 0;
  --s2: 0;
}

.screen {
  position: absolute;
  inset: 0;
  padding: 50px 14px 14px;
  opacity: 0;
  transform: scale(0.94) translate3d(0, 14px, 0);
  transition:
    opacity 0.5s var(--expo),
    transform 0.8s var(--expo);
}

.how-track[data-step="0"] .scr-photos,
.how-track[data-step="1"] .scr-feed,
.how-track[data-step="2"] .scr-make {
  opacity: 1;
  transform: none;
}

.app-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 6px 4px 12px;
}

.app-top b {
  font: 700 21px/1 var(--sans);
  letter-spacing: -0.035em;
}

.app-add {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--cobalt);
  color: #fff;
}

.app-add svg {
  width: 16px;
  height: 16px;
  stroke-width: 2.4;
}

.app-tabs {
  display: flex;
  gap: 6px;
  margin: 0 2px 12px;
  overflow: hidden;
}

.app-tabs span {
  flex: none;
  padding: 7px 11px;
  border-radius: 99px;
  background: #fff;
  box-shadow: inset 0 0 0 1px rgb(10 10 10 / 0.06);
  font: 600 11px/1 var(--sans);
  color: #4a4a4a;
}

.app-tabs .on {
  background: var(--ink);
  color: var(--bone);
}

/* Step 1: photos land in the library one by one; the last is read. */
.ph-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 5px;
}

.ph {
  --o: clamp(0, (var(--s0) - var(--t)) * 7, 1);
  position: relative;
  aspect-ratio: 1;
  border-radius: 12px;
  overflow: hidden;
  background: linear-gradient(160deg, var(--tint), var(--shade));
  opacity: var(--o);
  transform: scale(calc(0.6 + var(--o) * 0.4)) rotate(calc((1 - var(--o)) * -8deg));
}

.ph img,
.fc img,
.make-img img,
.core-img img,
.o img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.6s;
}

.ph img.ok,
.fc img.ok,
.make-img img.ok,
.core-img img.ok,
.o img.ok {
  opacity: 1;
}

.ph.scan em {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  z-index: 2;
  height: 36%;
  background: linear-gradient(to bottom, transparent, rgb(216 255 0 / 0.65), transparent);
  animation: scan 1.5s var(--inout) infinite alternate;
  opacity: calc(1 - clamp(0, (var(--s0) - 0.8) * 10, 1));
}

@keyframes scan {
  from {
    transform: translateY(-40%);
  }
  to {
    transform: translateY(210%);
  }
}

/* Face brackets on the photo being read. */
.ph.scan i {
  position: absolute;
  z-index: 3;
  width: 22%;
  height: 22%;
  border: 2px solid var(--lime);
  opacity: clamp(0, (var(--s0) - 0.6) * 6, 1);
}

.ph.scan i:nth-of-type(1) {
  left: 18%;
  top: 16%;
  border-right: 0;
  border-bottom: 0;
}

.ph.scan i:nth-of-type(2) {
  right: 18%;
  top: 16%;
  border-left: 0;
  border-bottom: 0;
}

.ph.scan i:nth-of-type(3) {
  left: 18%;
  bottom: 22%;
  border-right: 0;
  border-top: 0;
}

.ph.scan i:nth-of-type(4) {
  right: 18%;
  bottom: 22%;
  border-left: 0;
  border-top: 0;
}

.ph-status {
  position: relative;
  display: grid;
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 16px;
  background: #fff;
  box-shadow: inset 0 0 0 1px rgb(10 10 10 / 0.06);
  font: 600 12.5px/1.2 var(--sans);
}

.ph-status > span {
  grid-area: 1 / 1;
  display: flex;
  align-items: center;
  gap: 8px;
}

.ph-status .reading {
  opacity: calc(1 - clamp(0, (var(--s0) - 0.8) * 10, 1));
  color: #4a4a4a;
}

.ph-status .reading::before {
  content: "";
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 2px solid rgb(38 64 255 / 0.25);
  border-top-color: var(--cobalt);
  animation: spin 0.8s linear infinite;
}

.ph-status .done {
  opacity: clamp(0, (var(--s0) - 0.8) * 10, 1);
  color: var(--cobalt);
}

.ph-status .done svg {
  width: 16px;
  height: 16px;
  stroke-width: 2.6;
}

/* Step 2: the feed scrolls, one trend is picked. */
.feed-window {
  position: relative;
  height: calc(100% - 118px);
  overflow: hidden;
  border-radius: 14px;
  -webkit-mask-image: linear-gradient(to bottom, #000 80%, transparent);
  mask-image: linear-gradient(to bottom, #000 80%, transparent);
}

.feed-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  transform: translate3d(0, calc(var(--s1) * -30%), 0);
}

.fc {
  --k: 0;
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: 12px;
  overflow: hidden;
  background: linear-gradient(160deg, var(--tint), var(--shade));
}

.fc:nth-child(even) {
  margin-top: 18px;
}

.fc b {
  position: absolute;
  left: 7px;
  right: 7px;
  bottom: 6px;
  z-index: 2;
  font: 600 10px/1.15 var(--sans);
  color: #fff;
  text-shadow: 0 1px 8px rgb(0 0 0 / 0.7);
}

.fc.pick {
  --k: clamp(0, (var(--s1) - 0.5) * 5, 1);
  z-index: 2;
  box-shadow:
    0 0 0 calc(var(--k) * 3px) var(--cobalt),
    0 12px 30px -8px rgb(38 64 255 / calc(var(--k) * 0.7));
  transform: scale(calc(1 + var(--k) * 0.05));
}

.feed-cta {
  --k: clamp(0, (var(--s1) - 0.6) * 4, 1);
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 14px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 99px;
  background: var(--cobalt);
  color: #fff;
  font: 600 15px/1 var(--sans);
  transform: translate3d(0, calc((1 - var(--k)) * 80px), 0);
  box-shadow: 0 14px 30px -12px rgb(38 64 255 / 0.9);
}

/* Step 3: the render develops like a print. */
.scr-make {
  padding: 0;
  --dev: clamp(0, (var(--s2) - 0.04) / 0.8, 1);
  --done: clamp(0, (var(--s2) - 0.86) * 8, 1);
}

.make-img {
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, var(--tint), var(--shade));
  overflow: hidden;
}

.make-img img {
  filter: blur(calc((1 - var(--dev)) * 22px)) saturate(calc(0.15 + var(--dev) * 0.85)) brightness(calc(0.5 + var(--dev) * 0.5));
  transform: scale(calc(1.18 - var(--dev) * 0.18));
}

.make-hud {
  position: absolute;
  left: 50%;
  top: 46%;
  z-index: 2;
  display: grid;
  justify-items: center;
  gap: 8px;
  color: #fff;
  text-align: center;
  transform: translate(-50%, -50%) scale(calc(1 - var(--done) * 0.2));
  opacity: calc(1 - var(--done));
}

.make-ring {
  width: 96px;
  height: 96px;
  transform: rotate(-90deg);
  filter: drop-shadow(0 4px 18px rgb(0 0 0 / 0.5));
}

.make-ring circle {
  fill: rgb(10 10 10 / 0.25);
  stroke: rgb(255 255 255 / 0.22);
  stroke-width: 6;
}

.make-ring .arc {
  fill: none;
  stroke: var(--lime);
  stroke-linecap: round;
  stroke-dasharray: 100;
  stroke-dashoffset: calc(100 - var(--dev) * 100);
}

.make-hud b {
  position: absolute;
  top: 48px;
  transform: translateY(-50%);
  font: 700 22px/1 var(--sans);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.03em;
}

.make-hud small {
  padding: 6px 10px;
  border-radius: 99px;
  background: rgb(10 10 10 / 0.45);
  font: 500 10.5px/1 var(--mono);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
}

.make-actions {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 3;
  display: flex;
  gap: 8px;
  transform: translate3d(0, calc((1 - var(--done)) * 90px), 0);
}

.make-actions span {
  flex: 1;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 99px;
  background: rgb(255 255 255 / 0.94);
  color: var(--ink);
  font: 600 14px/1 var(--sans);
}

.make-actions .on {
  background: var(--cobalt);
  color: #fff;
}

.step-dots {
  display: flex;
  gap: 6px;
}

.step-dots i {
  width: 6px;
  height: 6px;
  border-radius: 6px;
  background: var(--line-2);
  transition:
    width 0.5s var(--expo),
    background-color 0.3s;
}

.how-track[data-step="0"] .step-dots i:nth-child(1),
.how-track[data-step="1"] .step-dots i:nth-child(2),
.how-track[data-step="2"] .step-dots i:nth-child(3) {
  width: 22px;
  background: var(--lime);
}

@media (min-width: 980px) {
  .step-dots {
    display: none;
  }
}

/* ───────────────────────────── explore ───────────────────────────── */

.explore {
  position: relative;
  padding: clamp(90px, 12vw, 170px) 0 clamp(60px, 8vw, 110px);
}

.chips {
  display: flex;
  gap: 8px;
  margin: 0 calc(-1 * var(--gutter)) 22px;
  padding: 4px var(--gutter) 10px;
  overflow-x: auto;
  scrollbar-width: none;
  scroll-snap-type: x proximity;
}

.chips::-webkit-scrollbar {
  display: none;
}

@media (min-width: 900px) {
  .chips {
    flex-wrap: wrap;
    margin-inline: 0;
    padding-inline: 0;
    overflow: visible;
  }
}

.chip {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 44px;
  padding: 0 18px 0 14px;
  border-radius: 999px;
  background: rgb(242 242 238 / 0.04);
  box-shadow: inset 0 0 0 1px var(--line-2);
  font: 500 15px/1 var(--sans);
  letter-spacing: -0.01em;
  color: var(--bone);
  scroll-snap-align: start;
  transition:
    background-color 0.3s,
    color 0.3s,
    box-shadow 0.3s,
    transform 0.5s var(--expo);
}

.chip:hover {
  box-shadow: inset 0 0 0 1px var(--bone-3);
}

.chip:active {
  transform: scale(0.96);
}

.chip[aria-pressed="true"] {
  background: var(--lime);
  color: var(--ink);
  box-shadow: none;
}

.chip .ic {
  width: 18px;
  height: 18px;
  flex: none;
}

/* Each category's icon has a small life of its own. */
.chip:hover .ic,
.chip[aria-pressed="true"] .ic {
  animation: var(--icon-anim, pop) 1.3s var(--inout) infinite;
}

.ic-flame {
  --icon-anim: flicker;
  transform-origin: 50% 90%;
}

.ic-heart {
  --icon-anim: beat;
}

.ic-plane {
  --icon-anim: fly;
}

.ic-sparkles {
  --icon-anim: twinkle;
}

.ic-film {
  --icon-anim: roll;
}

.ic-trophy {
  --icon-anim: hop;
  transform-origin: 50% 100%;
}

.ic-star {
  --icon-anim: turn;
}

.ic-box {
  --icon-anim: hop;
  transform-origin: 50% 100%;
}

.ic-camera {
  --icon-anim: snap;
}

.ic-grid {
  --icon-anim: shuffle;
}

@keyframes flicker {
  0%,
  100% {
    transform: scale(1, 1) rotate(0);
  }
  30% {
    transform: scale(1.08, 0.94) rotate(-4deg);
  }
  60% {
    transform: scale(0.95, 1.1) rotate(4deg);
  }
}

@keyframes beat {
  0%,
  40%,
  100% {
    transform: scale(1);
  }
  15% {
    transform: scale(1.25);
  }
  28% {
    transform: scale(1.05);
  }
}

@keyframes fly {
  0%,
  100% {
    transform: translate(0, 0) rotate(0);
  }
  50% {
    transform: translate(3px, -3px) rotate(-6deg);
  }
}

@keyframes twinkle {
  0%,
  100% {
    transform: scale(1) rotate(0);
  }
  50% {
    transform: scale(1.18) rotate(18deg);
  }
}

@keyframes roll {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-2px) rotate(-8deg);
  }
}

@keyframes hop {
  0%,
  100% {
    transform: translateY(0) scale(1);
  }
  30% {
    transform: translateY(-4px) scale(1.05, 0.95);
  }
  55% {
    transform: translateY(0) scale(0.95, 1.05);
  }
}

@keyframes turn {
  to {
    transform: rotate(144deg);
  }
}

@keyframes snap {
  0%,
  100% {
    transform: scale(1);
  }
  20% {
    transform: scale(0.85);
  }
  35% {
    transform: scale(1.12);
  }
}

@keyframes shuffle {
  0%,
  100% {
    transform: rotate(0);
  }
  50% {
    transform: rotate(90deg);
  }
}

@keyframes pop {
  50% {
    transform: scale(1.15);
  }
}

.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

@media (min-width: 700px) {
  .grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
  }
}

@media (min-width: 1100px) {
  .grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
  }
}

.tcell[hidden] {
  display: none !important;
}

/* Collapsed: two rows less than everything, until "show all". */
.grid.collapsed .tcell:nth-child(n + 9) {
  display: none;
}

@media (min-width: 700px) {
  .grid.collapsed .tcell:nth-child(n + 9) {
    display: block;
  }

  .grid.collapsed .tcell:nth-child(n + 13) {
    display: none;
  }
}

.tcard {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 4 / 5;
  border-radius: 20px;
  overflow: hidden;
  isolation: isolate;
  text-align: left;
  background: linear-gradient(160deg, var(--tint, #333), var(--shade, #111) 80%);
  box-shadow: inset 0 0 0 1px rgb(255 255 255 / 0.07);
  transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  transition:
    transform 0.7s var(--expo),
    box-shadow 0.6s var(--expo);
}

.tcard:hover {
  box-shadow:
    0 34px 70px -34px color-mix(in srgb, var(--tint, #2640ff) 80%, transparent),
    inset 0 0 0 1px rgb(255 255 255 / 0.12);
}

.skel .tcard::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, transparent 30%, rgb(255 255 255 / 0.12) 50%, transparent 70%);
  animation: shimmer 1.6s linear infinite;
}

@keyframes shimmer {
  from {
    transform: translateX(-100%);
  }
  to {
    transform: translateX(100%);
  }
}

.tcard-media {
  position: absolute;
  inset: 0;
  z-index: -1;
}

.tcard-media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.04);
  transition:
    opacity 0.7s,
    transform 1.4s var(--expo);
}

.tcard-media img.ok {
  opacity: 1;
}

.tcard-media img.alt.ok {
  opacity: 0;
}

.tcard:hover .tcard-media img.ok {
  transform: scale(1.1);
}

.tcard:hover .tcard-media img.alt.ok {
  opacity: 1;
}

/* A scrim so the title reads on any cover. */
.tcard::before {
  content: "";
  position: absolute;
  inset: 45% 0 0;
  z-index: 0;
  background: linear-gradient(to bottom, transparent, rgb(8 8 8 / 0.88));
  pointer-events: none;
}

.tcard-glare {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: radial-gradient(460px circle at var(--gx, 50%) var(--gy, 0%), rgb(255 255 255 / 0.2), transparent 45%);
  opacity: 0;
  transition: opacity 0.4s;
  pointer-events: none;
}

.tcard:hover .tcard-glare {
  opacity: 1;
}

.badges {
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 8px;
  border-radius: 9px;
  background: rgb(10 10 10 / 0.6);
  font: 600 10.5px/1 var(--mono);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--bone);
}

.badge svg {
  width: 11px;
  height: 11px;
}

.badge-new {
  background: var(--lime);
  color: var(--ink);
}

.badge-video {
  background: var(--cobalt);
  color: #fff;
}

.tcard-body {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  display: grid;
  gap: 4px;
  padding: 14px;
}

.tcard-cat {
  font: 500 10.5px/1 var(--mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--lime);
}

.tcard-title {
  font: 700 clamp(17px, 2vw, 22px)/1.08 var(--sans);
  letter-spacing: -0.035em;
  color: #fff;
  text-wrap: balance;
}

.tcard-blurb {
  display: none;
}

@media (hover: hover) and (min-width: 700px) {
  .tcard-blurb {
    display: block;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    font-size: 13.5px;
    line-height: 1.4;
    color: rgb(255 255 255 / 0.8);
    transition:
      max-height 0.6s var(--expo),
      opacity 0.4s,
      margin 0.6s var(--expo);
  }

  .tcard:hover .tcard-blurb {
    max-height: 5em;
    opacity: 1;
    margin-top: 4px;
  }
}

.more {
  display: flex;
  justify-content: center;
  margin-top: 30px;
}

::view-transition-group(*) {
  animation-duration: 0.55s;
  animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
}

::view-transition-old(root),
::view-transition-new(root) {
  animation: none;
}

/* ─────────────── video: a reel that scrolls sideways ─────────────── */

.reel-sec {
  position: relative;
  padding: clamp(80px, 10vw, 140px) 0 40px;
}

.reel-scroller {
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  overscroll-behavior-x: contain;
}

.reel-scroller::-webkit-scrollbar {
  display: none;
}

.reel {
  display: flex;
  gap: 14px;
  width: max-content;
  padding: 10px var(--gutter) 24px;
}

.vcard {
  position: relative;
  flex: none;
  width: clamp(252px, 74vw, 340px);
  aspect-ratio: 9 / 13;
  border-radius: 28px;
  overflow: hidden;
  isolation: isolate;
  scroll-snap-align: center;
  background: linear-gradient(160deg, var(--tint), var(--shade));
  color: #fff;
  box-shadow:
    0 40px 80px -44px color-mix(in srgb, var(--tint, #2640ff) 70%, transparent),
    inset 0 0 0 1px rgb(255 255 255 / 0.08);
}

.vcard.skel::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, transparent 30%, rgb(255 255 255 / 0.1) 50%, transparent 70%);
  animation: shimmer 1.6s linear infinite;
}

.vcard-media {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
}

/* Stills made to breathe: a slow push-in, like the clip it stands for. */
.vcard-media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.8s;
  animation: kenburns 12s var(--inout) infinite alternate;
  animation-delay: calc(var(--n, 0) * -2.3s);
}

.vcard-media img.ok {
  opacity: 1;
}

@keyframes kenburns {
  from {
    transform: scale(1.02) translate3d(0, 0, 0);
  }
  to {
    transform: scale(1.18) translate3d(-3%, -4%, 0);
  }
}

.vcard::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(to bottom, rgb(8 8 8 / 0.5), transparent 26%),
    linear-gradient(to top, rgb(8 8 8 / 0.92), transparent 55%);
  pointer-events: none;
}

.vcard-top {
  position: absolute;
  top: 16px;
  left: 16px;
  right: 16px;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font: 500 11px/1 var(--mono);
  letter-spacing: 0.1em;
}

.rec {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  border-radius: 99px;
  background: rgb(10 10 10 / 0.55);
}

.rec::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #ff3b30;
  animation: blink 1.2s steps(2, jump-none) infinite;
}

@keyframes blink {
  50% {
    opacity: 0.2;
  }
}

.vcard-body {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  z-index: 1;
}

.vcard-body h3 {
  margin: 0;
  font: 700 clamp(24px, 2.6vw, 32px)/1.02 var(--sans);
  letter-spacing: -0.04em;
}

.vcard-body p {
  margin: 8px 0 16px;
  font-size: 14px;
  line-height: 1.45;
  color: rgb(255 255 255 / 0.78);
}

.scrub {
  display: flex;
  align-items: center;
  gap: 10px;
  font: 500 11px/1 var(--mono);
  font-variant-numeric: tabular-nums;
  color: rgb(255 255 255 / 0.8);
}

.scrub span {
  position: relative;
  flex: 1;
  height: 3px;
  border-radius: 3px;
  background: rgb(255 255 255 / 0.25);
  overflow: hidden;
}

.scrub span::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--lime);
  transform-origin: 0 50%;
  animation: scrub var(--dur, 5s) linear infinite;
}

@keyframes scrub {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

.reel-foot {
  display: none;
}

@media (min-width: 768px) {
  .reel-sec {
    height: var(--reel-h, 260vh);
    padding: 0;
  }

  .reel-sticky {
    position: sticky;
    top: 0;
    height: 100vh;
    height: 100svh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden;
    overflow: clip;
  }

  .reel-head {
    margin-bottom: clamp(22px, 3vw, 40px);
  }

  .reel-head .sec-body {
    margin-top: 14px;
  }

  .reel-scroller {
    overflow: visible;
    scroll-snap-type: none;
  }

  .reel {
    gap: 22px;
    padding-block: 0;
    transform: translate3d(calc(var(--p, 0) * var(--reel-x, 0px) * -1), 0, 0);
  }

  .vcard {
    width: clamp(260px, 25vw, 360px);
    max-height: 52svh;
    aspect-ratio: auto;
    height: min(52svh, 520px);
  }

  .vcard:nth-child(even) {
    transform: translate3d(0, 34px, 0);
  }

  .reel-foot {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-top: 34px;
    font: 500 12px/1 var(--mono);
    letter-spacing: 0.1em;
    color: var(--bone-3);
  }

  .reel-line {
    position: relative;
    flex: 1;
    height: 1px;
    background: var(--line-2);
  }

  .reel-line i {
    position: absolute;
    inset: 0;
    background: var(--lime);
    transform-origin: 0 50%;
    transform: scaleX(var(--p, 0));
  }
}

/* ───────────────────────── echo: orbiting covers ───────────────────────── */

.echo {
  position: relative;
  padding: clamp(90px, 12vw, 170px) 0;
  overflow: hidden;
  overflow: clip;
}

.echo-grid {
  display: grid;
  gap: 48px;
  align-items: center;
}

@media (min-width: 980px) {
  .echo-grid {
    grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  }
}

.echo-two {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin: 26px 0 0;
  max-width: 44ch;
  padding: 16px 18px;
  border-radius: 18px;
  background: rgb(242 242 238 / 0.04);
  box-shadow: inset 0 0 0 1px var(--line);
  color: var(--bone-2);
  font-size: 15px;
}

.echo-two svg {
  width: 22px;
  height: 22px;
  flex: none;
  color: var(--lime);
}

.orbit {
  position: relative;
  width: min(100%, 640px);
  aspect-ratio: 1;
  margin-inline: auto;
  container-type: size;
  --grow: min(var(--p, 0) * 2.2, 1);
  transform: scale(calc(0.72 + var(--grow) * 0.28)) rotate(calc((var(--p, 0) - 0.5) * 50deg));
  opacity: calc(0.2 + var(--grow) * 0.8);
}

.ring {
  position: absolute;
  inset: 0;
  margin: auto;
  border-radius: 50%;
  border: 1px dashed rgb(242 242 238 / 0.17);
  animation: spin var(--dur) linear infinite;
}

.ring.r1 {
  width: 46%;
  height: 46%;
  --dur: 44s;
  --R: 23cqw;
  --size: 14cqw;
}

.ring.r2 {
  width: 72%;
  height: 72%;
  --dur: 66s;
  --R: 36cqw;
  --size: 12.5cqw;
  animation-direction: reverse;
}

.ring.r3 {
  width: 98%;
  height: 98%;
  --dur: 92s;
  --R: 49cqw;
  --size: 11cqw;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.o {
  position: absolute;
  left: 50%;
  top: 50%;
  width: var(--size);
  height: calc(var(--size) * 1.25);
  margin: calc(var(--size) * -0.625) 0 0 calc(var(--size) * -0.5);
  transform: rotate(var(--a)) translate(var(--R)) rotate(calc(-1 * var(--a)));
}

/* Counter-spun so every cover stays upright while its ring turns. */
.o > span {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 14px;
  overflow: hidden;
  background: linear-gradient(160deg, var(--tint), var(--shade));
  box-shadow:
    0 14px 30px -12px rgb(0 0 0 / 0.9),
    inset 0 0 0 1px rgb(255 255 255 / 0.1);
  animation: spin var(--dur) linear infinite reverse;
}

.ring.r2 .o > span {
  animation-direction: normal;
}

.core {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 25%;
  height: 25%;
}

.core-img {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  overflow: hidden;
  background: linear-gradient(160deg, var(--cobalt), var(--ink));
  box-shadow:
    0 0 0 3px var(--lime),
    0 0 0 12px rgb(216 255 0 / 0.08),
    0 0 90px rgb(38 64 255 / 0.8);
}

.core i {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1.5px solid rgb(216 255 0 / 0.55);
  animation: echo 3.6s var(--quint) infinite;
  animation-delay: calc(var(--i) * -1.2s);
}

@keyframes echo {
  from {
    transform: scale(1);
    opacity: 0.9;
  }
  to {
    transform: scale(2.7);
    opacity: 0;
  }
}

/* ───────────────────────────── stats ───────────────────────────── */

.stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  margin-bottom: clamp(60px, 8vw, 120px);
}

.stat {
  padding: 34px 16px 30px 0;
  border-bottom: 1px solid var(--line);
}

.stat:nth-child(odd) {
  border-right: 1px solid var(--line);
}

.stat:nth-child(even) {
  padding-left: 18px;
}

@media (min-width: 860px) {
  .stats {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .stat {
    padding: 44px 20px 40px;
    border-right: 1px solid var(--line);
  }

  .stat:first-child {
    padding-left: 0;
  }

  .stat:last-child {
    border-right: 0;
  }
}

.stat b {
  display: block;
  font: 700 clamp(58px, 9vw, 116px)/0.86 var(--sans);
  letter-spacing: -0.065em;
  font-variant-numeric: tabular-nums;
}

.stat:first-child b {
  color: var(--lime);
}

.stat span {
  display: block;
  margin-top: 14px;
  font: 500 11.5px/1.35 var(--mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--bone-3);
}

/* ───────────────────────────── trust ───────────────────────────── */

.trust {
  position: relative;
  padding: clamp(40px, 6vw, 80px) 0 clamp(90px, 12vw, 160px);
}

.bento {
  display: grid;
  gap: 12px;
}

@media (min-width: 860px) {
  .bento {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
  }

  .tile-wide {
    grid-column: span 2;
  }
}

.tile {
  position: relative;
  min-height: 250px;
  padding: 28px;
  border-radius: 28px;
  overflow: hidden;
  isolation: isolate;
  background: linear-gradient(180deg, rgb(242 242 238 / 0.055), rgb(242 242 238 / 0.02));
  box-shadow: inset 0 0 0 1px var(--line);
  display: flex;
  flex-direction: column;
}

/* A spotlight that follows the pointer across the whole grid. */
.tile::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(520px circle at var(--mx, -500px) var(--my, -500px), rgb(216 255 0 / 0.11), transparent 42%);
  opacity: 0;
  transition: opacity 0.5s;
}

.bento:hover .tile::before {
  opacity: 1;
}

.tile::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  padding: 1px;
  background: radial-gradient(360px circle at var(--mx, -500px) var(--my, -500px), rgb(216 255 0 / 0.55), transparent 45%);
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask:
    linear-gradient(#000 0 0) content-box exclude,
    linear-gradient(#000 0 0);
  opacity: 0;
  transition: opacity 0.5s;
}

.bento:hover .tile::after {
  opacity: 1;
}

.tile-ico {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 18px;
  background: rgb(38 64 255 / 0.22);
  box-shadow: inset 0 0 0 1px rgb(129 144 255 / 0.3);
  color: var(--lime);
}

.tile-ico svg {
  width: 28px;
  height: 28px;
  overflow: visible;
}

/*
 * The icon draws itself on when its tile arrives. Every shape in these icons
 * has pathLength="1". Selected by element, not by [pathLength]: Chromium does
 * not restyle a camel-cased SVG attribute selector when an ancestor's class
 * changes, and the icons stayed undrawn.
 */
.js .tile-ico svg :is(path, rect) {
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  transition: stroke-dashoffset 1.6s var(--quint) 0.35s;
}

.js .tile.in .tile-ico svg :is(path, rect) {
  stroke-dashoffset: 0;
}

.tile:hover .lid {
  animation: lid 0.8s var(--spring);
  transform-origin: 20px 6px;
}

.tile:hover .shackle {
  animation: shackle 0.9s var(--spring);
}

@keyframes lid {
  40% {
    transform: translateY(-2px) rotate(14deg);
  }
}

@keyframes shackle {
  40% {
    transform: translateY(-2.5px);
  }
}

.tile h3 {
  margin: auto 0 0;
  padding-top: 40px;
  font: 700 clamp(24px, 2.7vw, 34px)/1.04 var(--sans);
  letter-spacing: -0.04em;
  text-wrap: balance;
}

.tile p {
  margin: 12px 0 0;
  max-width: 46ch;
  color: var(--bone-2);
  font-size: 15.5px;
  text-wrap: pretty;
}

.tile-echo {
  position: absolute;
  right: -40px;
  top: -40px;
  z-index: -1;
  width: 220px;
  height: 220px;
  opacity: 0.08;
  transition:
    opacity 0.6s,
    transform 1.2s var(--expo);
}

.tile-echo svg {
  width: 100%;
  height: 100%;
}

.tile:hover .tile-echo {
  opacity: 0.22;
  transform: rotate(-12deg) scale(1.08);
}

.about {
  margin: 30px 0 0;
  max-width: 70ch;
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--bone-3);
}

.about a {
  color: var(--lime);
  text-underline-offset: 3px;
}

/* ───────────── finale: the lime circle floods the screen ───────────── */

.finale {
  position: relative;
  height: 240vh;
}

.finale-sticky {
  --S: min(44vmin, 340px);
  --k: clamp(0, (var(--p, 0) - 0.08) / 0.62, 1);
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  display: grid;
  place-items: center;
  overflow: hidden;
  overflow: clip;
}

.finale-hint {
  position: absolute;
  top: calc(50% - var(--S) * 0.7);
  left: 0;
  right: 0;
  margin: 0;
  text-align: center;
  font: 500 12px/1 var(--mono);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--bone-3);
  opacity: calc(1 - var(--k) * 4);
}

.finale-mark {
  position: absolute;
  left: 50%;
  top: 50%;
  width: var(--S);
  height: var(--S);
  margin: calc(var(--S) / -2) 0 0 calc(var(--S) / -2);
}

.finale-mark svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}

.finale-mark circle {
  transform-box: fill-box;
  transform-origin: center;
}

.finale-mark .e1 {
  transform: translate(calc(var(--k) * -60%), calc(var(--k) * 60%)) scale(calc(1 - var(--k) * 0.6));
  opacity: calc(1 - var(--k) * 1.6);
}

.finale-mark .e2 {
  transform: translate(calc(var(--k) * -30%), calc(var(--k) * 30%)) scale(calc(1 - var(--k) * 0.4));
  opacity: calc(1 - var(--k) * 1.4);
}

/* The lime circle is drawn by the flood itself, so the two never part. */
.finale-mark .e3 {
  opacity: 0;
}

.flood {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: var(--lime);
  color: var(--ink);
  clip-path: circle(
    calc(var(--S) * 0.3 + var(--k) * var(--k) * 150vmax) at calc(50% + var(--S) * 0.15) calc(50% - var(--S) * 0.15)
  );
}

.flood-inner {
  --show: clamp(0, (var(--k) - 0.5) * 3, 1);
  width: min(100% - 2 * var(--gutter), 1100px);
  text-align: center;
  opacity: var(--show);
  transform: translate3d(0, calc((1 - var(--show)) * 50px), 0);
}

.mega {
  margin: 0;
  font: 700 clamp(72px, 17vw, 250px)/0.86 var(--sans);
  letter-spacing: -0.07em;
  text-wrap: balance;
}

.mega .sq {
  background: var(--cobalt);
}

/* The last word and its square never part across a line break. */
.tail {
  white-space: nowrap;
}

.js .finale:not(.done) .mega .w > span {
  transform: translate3d(0, 108%, 0) rotate(5deg);
}

.js .finale.done .mega .w > span,
.js .finale.done .mega .sq {
  transform: none;
}

.js .finale:not(.done) .mega .sq {
  transform: scale(0) rotate(-90deg);
}

.finale.done .mega .sq {
  transition-delay: 0.45s;
}

.finale-body {
  margin: 26px auto 0;
  max-width: 32ch;
  text-wrap: balance;
  font: 600 clamp(18px, 2.2vw, 26px)/1.3 var(--sans);
  letter-spacing: -0.02em;
}

.flood .stores {
  justify-content: center;
  margin-top: 30px;
}

.flood .store {
  background: var(--ink);
  color: var(--bone);
}

.flood .store::after {
  background: linear-gradient(105deg, transparent 30%, rgb(216 255 0 / 0.25) 50%, transparent 70%);
}

.flood .store-alt {
  background: transparent;
  color: var(--ink);
  box-shadow: inset 0 0 0 1.5px var(--ink);
}

.flood .store:hover {
  box-shadow: 0 18px 40px -16px rgb(10 10 10 / 0.6);
}

.flood .store-alt:hover {
  background: rgb(10 10 10 / 0.06);
  box-shadow: inset 0 0 0 1.5px var(--ink);
}

.finale-fine {
  margin: 22px auto 0;
  max-width: 48ch;
  font: 500 12.5px/1.5 var(--mono);
  letter-spacing: 0.02em;
  color: rgb(10 10 10 / 0.66);
}

/* ───────────────────────────── footer ───────────────────────────── */

.foot {
  position: relative;
  padding: 72px 0 calc(40px + env(safe-area-inset-bottom));
  background: var(--ink);
  border-top: 1px solid var(--line);
}

.foot-mark {
  width: min(78vw, 540px);
  height: auto;
}

.foot-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 18px 32px;
  margin-top: 48px;
}

.foot-links,
.lang {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
}

.foot-links a,
.lang a {
  font-size: 15px;
  color: var(--bone-2);
  text-decoration: none;
  transition: color 0.2s;
}

.foot-links a:hover,
.lang a:hover,
.lang a[aria-current="page"] {
  color: var(--lime);
}

.foot-legal {
  margin: 28px 0 0;
  font: 500 12px/1 var(--mono);
  letter-spacing: 0.08em;
  color: var(--bone-3);
}

/* ───────────────────────────── language menu ───────────────────────────── */

.langs {
  position: relative;
  flex: none;
}

.langs summary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 38px;
  padding: 0 10px 0 11px;
  border-radius: 999px;
  list-style: none;
  cursor: pointer;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  background: rgb(242 242 238 / 0.05);
  box-shadow: inset 0 0 0 1px var(--line-2);
  font: 600 12.5px/1 var(--mono);
  letter-spacing: 0.06em;
  color: var(--bone);
  transition:
    background-color 0.25s,
    box-shadow 0.25s;
}

.langs summary::-webkit-details-marker {
  display: none;
}

.langs summary:hover,
.langs[open] summary {
  background: rgb(242 242 238 / 0.1);
  box-shadow: inset 0 0 0 1px var(--bone-3);
}

.langs summary svg {
  width: 16px;
  height: 16px;
  flex: none;
}

.langs .chev {
  width: 14px;
  height: 14px;
  opacity: 0.7;
  transition: transform 0.45s var(--expo);
}

.langs[open] .chev {
  transform: rotate(180deg);
}

.langs[open] .globe {
  animation: turn-globe 1.2s var(--expo);
}

@keyframes turn-globe {
  from {
    transform: rotate(-180deg) scale(0.6);
  }
}

.langs-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 80;
  display: grid;
  gap: 2px;
  width: max-content;
  min-width: 236px;
  max-height: min(72svh, 470px);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 6px;
  border-radius: 20px;
  background: rgb(22 22 21 / 0.94);
  -webkit-backdrop-filter: blur(20px) saturate(1.4);
  backdrop-filter: blur(20px) saturate(1.4);
  box-shadow:
    inset 0 0 0 1px var(--line-2),
    0 30px 70px -20px rgb(0 0 0 / 0.9);
  transform-origin: top right;
  animation: menu-in 0.45s var(--expo);
}

@keyframes menu-in {
  from {
    opacity: 0;
    transform: translate3d(0, -8px, 0) scale(0.95);
  }
}

.langs-menu a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 12px;
  border-radius: 13px;
  color: var(--bone-2);
  text-decoration: none;
  font: 500 15px/1.2 var(--sans);
  transition:
    background-color 0.2s,
    color 0.2s;
  animation: item-in 0.5s var(--expo) backwards;
  animation-delay: calc(var(--n, 0) * 22ms + 40ms);
}

@keyframes item-in {
  from {
    opacity: 0;
    transform: translate3d(0, -6px, 0);
  }
}

.langs-menu a:hover,
.langs-menu a:focus-visible {
  background: rgb(242 242 238 / 0.08);
  color: var(--bone);
}

.langs-menu a[aria-current="page"] {
  color: var(--bone);
  background: rgb(216 255 0 / 0.09);
}

.langs-menu small {
  margin-left: auto;
  font: 500 11px/1 var(--mono);
  letter-spacing: 0.1em;
  color: var(--bone-3);
}

.langs-menu a svg {
  width: 16px;
  height: 16px;
  flex: none;
  color: var(--lime);
  stroke-width: 2.4;
}

/* Every row keeps the check's width, so the codes line up. */
.langs-menu a:not([aria-current="page"])::after {
  content: "";
  width: 16px;
  flex: none;
}

/* The foot's menu opens upwards. */
.langs-foot .langs-menu {
  top: auto;
  bottom: calc(100% + 10px);
  right: auto;
  left: 0;
  transform-origin: bottom left;
  animation-name: menu-up;
}

@keyframes menu-up {
  from {
    opacity: 0;
    transform: translate3d(0, 8px, 0) scale(0.95);
  }
}

/* ───────────── Japanese and Korean: their own rhythm ───────────── */

:lang(ja) .display,
:lang(ko) .display,
:lang(ja) .h2,
:lang(ko) .h2,
:lang(ja) .mega,
:lang(ko) .mega {
  letter-spacing: -0.02em;
  line-height: 1.1;
}

:lang(ja) .mega,
:lang(ko) .mega {
  font-size: clamp(56px, 13vw, 200px);
}

:lang(ja) .step h3,
:lang(ko) .step h3,
:lang(ja) .tile h3,
:lang(ko) .tile h3,
:lang(ja) .vcard-body h3,
:lang(ko) .vcard-body h3,
:lang(ja) .tcard-title,
:lang(ko) .tcard-title {
  letter-spacing: -0.01em;
  line-height: 1.25;
}

:lang(ja) .label,
:lang(ko) .label,
:lang(ja) .kicker,
:lang(ko) .kicker {
  letter-spacing: 0.04em;
}

/* Japanese rises a character at a time, so each waits less. */
:lang(ja) .w > span {
  transition-delay: calc(var(--i, 0) * 32ms + var(--d, 0ms));
}

.hero:lang(ja) .w > span {
  transition-delay: calc(var(--i, 0) * 45ms + 120ms);
}

/* ───────────────── paused when out of sight, still on request ───────────────── */

[data-ambient].paused,
[data-ambient].paused * {
  animation-play-state: paused !important;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 1ms !important;
    transition-delay: 0ms !important;
  }

  .js .rv,
  .js .w > span,
  .js .sq,
  .js .hero .kicker,
  .js .hero .lede,
  .js .hero-cta {
    opacity: 1 !important;
    transform: none !important;
  }

  .hero-bg,
  .phone,
  .orbit {
    transform: none !important;
  }
}
