/* Ploposaurus.com site styles.
 *
 * Brand sources (see docs/ASSET_PROVENANCE.md):
 *  - Growth board /opt/ploposaurus-growth/docs/brand/brand.json: Plum Deep
 *    #1A0B2E anchors every surface, Dino Teal #2DD4BF is the only sanctioned
 *    primary action accent, muted foreground on dark cards is #FDE68A or
 *    #B5A8D6, gold #FBBF24 is reserved for score/reward emphasis, one accent
 *    per view, never teal text on plum cards, never C4 corporate blue.
 *  - Product board /opt/ploposaurus/docs/brand/brand.json productPalette:
 *    #0A0A1A, #1A1040, #F093FB, #F5576C, #FBBF24, #10B981. Never white text
 *    on pink or gold (2.05:1); dark ink on those hues passes.
 *  - The pink-to-violet gradient (#F093FB to #A78BFA) is the falling-block
 *    brand mark and may appear wherever a block appears.
 */

@font-face {
  font-family: Rajdhani;
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../assets/fonts/rajdhani-500.woff2') format('woff2');
}
@font-face {
  font-family: Rajdhani;
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../assets/fonts/rajdhani-600.woff2') format('woff2');
}
@font-face {
  font-family: Rajdhani;
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../assets/fonts/rajdhani-700.woff2') format('woff2');
}

:root {
  /* anchors and surfaces */
  --plum-deep: #1a0b2e;
  --plum-mid: #2d1457;
  --plum-soft: #241149;
  --ink: #0a0a1a;
  --surface: #1a1040;

  /* accents (one per view; teal is the primary action accent) */
  --teal: #2dd4bf;
  --pink: #f093fb;
  --violet: #a78bfa;
  --coral: #f5576c;
  --gold: #fbbf24;
  --mint: #4ade80;
  --sky: #38bdf8;

  /* text */
  --white: #ffffff;
  --cream: #fde68a;
  --muted: #b5a8d6;

  /* the falling-block brand mark */
  --block-grad: linear-gradient(135deg, #f093fb, #a78bfa);

  /* phone bezel / footer ink: productPalette background #0A0A1A (traceable
     replacement for the two off-board near-blacks #0b0718 / #070710) */
  --shadow-card: 0 18px 44px rgba(10, 10, 26, 0.35);
  --shadow-float: 0 25px 45px rgba(10, 10, 26, 0.45);
  --ease-pop: cubic-bezier(0.22, 1.2, 0.36, 1);

  /* Brand-board alias layer (docs/brand/BRAND.md, open item 1). Maps the
     board's 19 semantic names onto this site's flat variables: changes no
     pixels, it makes the board vocabulary real here. The board's muted
     SURFACE #3B2A5E gets its own variable because --muted is already ink
     on this site (BRAND.md naming hazard); --muted is aliased as
     --muted-foreground, which is what the board says it is. */
  --background: var(--plum-deep);
  --foreground: var(--cream);
  --card: var(--plum-mid);
  --card-foreground: var(--cream);
  --popover: var(--plum-soft);
  --popover-foreground: var(--cream);
  --primary: var(--teal);
  --primary-foreground: var(--plum-deep);
  --secondary: var(--violet);
  --secondary-foreground: var(--plum-deep);
  --muted-surface: #3b2a5e;
  --muted-foreground: var(--muted);
  --accent: var(--pink);
  --accent-foreground: var(--plum-deep);
  --destructive: var(--coral);
  --destructive-foreground: var(--white);
  --border: #473273;
  --input: #553c8a;
  --ring: var(--teal);
}

* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  overflow-x: hidden;
  color: var(--white);
  background:
    radial-gradient(circle at 85% -10%, rgba(45, 212, 191, 0.08), transparent 34rem),
    radial-gradient(circle at 8% 30%, rgba(240, 147, 251, 0.07), transparent 30rem),
    linear-gradient(180deg, var(--plum-deep) 0%, var(--ink) 100%);
  font-family: Rajdhani, 'Segoe UI', system-ui, -apple-system, sans-serif;
}
a {
  color: inherit;
}
img {
  display: block;
  max-width: 100%;
}
.shell {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
}
.prose {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

.skip-link {
  position: absolute;
  top: -4rem;
  left: 1rem;
  z-index: 40;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  background: var(--teal);
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
}
.skip-link:focus {
  top: 1rem;
}
:focus-visible {
  outline: 3px solid var(--teal);
  outline-offset: 4px;
}

/* ------------------------------------------------------------------ nav */

.nav {
  position: sticky;
  top: 0;
  z-index: 30;
  border-bottom: 1px solid rgba(167, 139, 250, 0.16);
  background: rgba(26, 11, 46, 0.82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 0;
}
.brand {
  display: inline-flex;
  align-items: center;
  padding: 0.55rem 0.25rem;
  margin: -0.55rem 0;
  text-decoration: none;
}
.brand img {
  height: 30px;
  width: auto;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 1.4rem;
}
.nav-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin: -0.7rem 0;
  color: var(--muted);
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-decoration: none;
  transition: color 0.18s ease;
}
.nav-link:hover {
  color: var(--teal);
}
.btn-pill {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin: -0.25rem 0;
  gap: 0.4rem;
  padding: 0.5rem 1.1rem;
  border-radius: 999px;
  background: var(--teal);
  color: var(--ink);
  font-weight: 700;
  font-size: 1.02rem;
  text-decoration: none;
  box-shadow: 0 6px 18px rgba(45, 212, 191, 0.28);
  transition:
    transform 0.18s ease,
    filter 0.18s ease;
}
.btn-pill:hover {
  transform: translateY(-2px);
  filter: brightness(1.08);
}

/* ----------------------------------------------------------------- hero */

.hero {
  position: relative;
  overflow: hidden;
  padding: 3.4rem 0 5.2rem;
}
.hero-scene {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-scene img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.18;
}
.hero-scene::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 78% 18%, rgba(240, 147, 251, 0.22), transparent 24rem),
    radial-gradient(circle at 16% 66%, rgba(45, 212, 191, 0.14), transparent 26rem),
    linear-gradient(180deg, rgba(26, 11, 46, 0.5) 0%, rgba(26, 11, 46, 0.86) 62%, var(--plum-deep) 100%);
}
/* Decorative corner blobs as background layers on an inset-0 pseudo-element:
   they bleed off-canvas by design and are clipped to .hero's paint box, so
   they must never contribute boxes (DOM or offsets) to any scrollable
   overflow computation. Colors: pink/violet categorical at 14% alpha. */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='480' height='480' viewBox='0 0 480 480'%3E%3Cg transform='rotate(22 240 240)'%3E%3Crect x='0.5' y='0.5' width='479' height='479' rx='230' fill='none' stroke='%23f093fb' stroke-opacity='0.14'/%3E%3C/g%3E%3C/svg%3E"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='448' height='448' viewBox='0 0 448 448'%3E%3Cg transform='rotate(-36 224 224)'%3E%3Crect x='0.5' y='0.5' width='447' height='447' rx='215' fill='none' stroke='%23a78bfa' stroke-opacity='0.14'/%3E%3C/g%3E%3C/svg%3E");
  background-repeat: no-repeat, no-repeat;
  background-position: right -9rem top -14rem, left -10rem bottom -19rem;
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.06fr 0.94fr;
  align-items: center;
  gap: clamp(1.4rem, 4vw, 4.5rem);
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--cream);
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.eyebrow::before {
  content: '';
  width: 0.65rem;
  height: 0.65rem;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 0.9rem var(--teal);
}
h1 {
  margin: 0.9rem 0 1.2rem;
  font-size: clamp(3.3rem, 8vw, 6.4rem);
  font-weight: 700;
  line-height: 0.82;
  letter-spacing: -0.055em;
  text-transform: uppercase;
}
h1 .roar {
  display: block;
  background: linear-gradient(92deg, var(--teal) 8%, var(--pink) 78%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-copy {
  max-width: 540px;
  margin: 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.8vw, 1.18rem);
  line-height: 1.65;
}
.hero-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 1.3rem;
}
.chip {
  padding: 0.3rem 0.85rem;
  border: 1px solid rgba(167, 139, 250, 0.35);
  border-radius: 999px;
  background: rgba(45, 212, 191, 0.08);
  color: var(--cream);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.store-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 1.9rem;
}
.store-button {
  position: relative;
  display: inline-flex;
  min-width: 200px;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.85rem 1.1rem;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 10px 30px rgba(10, 10, 26, 0.35);
  color: var(--white);
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  text-decoration: none;
  transition:
    transform 0.18s ease,
    border-color 0.18s ease,
    background 0.18s ease,
    box-shadow 0.18s ease;
}
.store-button:hover {
  transform: translateY(-3px);
  border-color: var(--teal);
  background: rgba(45, 212, 191, 0.14);
  box-shadow: 0 14px 34px rgba(45, 212, 191, 0.18);
}
.store-button small {
  display: block;
  font-size: 0.75rem;
  line-height: 1.1;
  opacity: 0.85;
}
.store-button strong {
  display: block;
  font-size: 1.08rem;
  line-height: 1.15;
}
.store-mark {
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
}
.store-mark svg {
  width: 100%;
  height: 100%;
}
.store-button.is-preferred {
  border-color: var(--gold);
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.2), rgba(45, 212, 191, 0.12));
}
.store-button.is-preferred::after {
  content: 'Best for this device';
  position: absolute;
  top: -0.2rem;
  left: 0.75rem;
  transform: translateY(-100%);
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  background: var(--gold);
  color: var(--ink);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  white-space: nowrap;
}
.hero.is-cascade-ready .store-button {
  animation: cta-pulse 0.9s ease both;
}
@keyframes cta-pulse {
  0% {
    transform: scale(1);
  }
  45% {
    transform: scale(1.035);
  }
  100% {
    transform: scale(1);
  }
}
.tiny-note {
  margin: 1rem 0 0;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.82rem;
}
.platform-note {
  min-height: 1.2rem;
  margin: 0.55rem 0 0;
  color: var(--cream);
  font-size: 0.82rem;
}

/* hero art: mini board + mascot + falling blocks */

.hero-art {
  position: relative;
  min-height: 480px;
}
.mascot {
  position: absolute;
  z-index: 2;
  right: 2%;
  bottom: 0;
  width: min(88%, 340px);
  filter: drop-shadow(0 26px 30px rgba(10, 10, 26, 0.55));
  animation: mascot-float 4.5s ease-in-out infinite;
}
.merge-play {
  position: absolute;
  z-index: 4;
  top: 2%;
  left: 0;
  width: min(100%, 280px);
  padding: 1rem;
  border: 1px solid rgba(240, 147, 251, 0.35);
  border-radius: 1.25rem;
  background: linear-gradient(155deg, rgba(45, 20, 87, 0.96), rgba(10, 10, 26, 0.94));
  box-shadow:
    0 22px 50px rgba(10, 10, 26, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.14);
}
.merge-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
  margin: 0 0 0.7rem;
}
.merge-heading strong {
  font-size: 1.2rem;
}
.merge-heading span {
  color: var(--cream);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.mini-board {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.35rem;
  padding: 0.35rem;
  border-radius: 0.85rem;
  background: rgba(255, 255, 255, 0.06);
}
.mini-cell {
  min-height: 46px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 0.6rem;
  background: rgba(255, 255, 255, 0.035);
  color: var(--white);
  font-family: inherit;
  cursor: pointer;
  transition:
    border-color 0.18s ease,
    background 0.18s ease,
    transform 0.18s ease;
}
.mini-cell:hover,
.mini-cell:focus-visible {
  border-color: var(--pink);
  background: rgba(240, 147, 251, 0.15);
  transform: translateY(-2px);
}
.mini-cell.is-selected {
  border-color: var(--pink);
}
.mini-tile {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  min-height: 44px;
  border-radius: 0.5rem;
  background: var(--block-grad);
  color: var(--ink);
  font-size: 1.15rem;
  font-weight: 700;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35);
}
.mini-board.is-merging .mini-cell.is-selected .mini-tile {
  animation: tile-pop 0.45s var(--ease-pop);
}
@keyframes tile-pop {
  0% {
    transform: scale(1);
  }
  40% {
    transform: scale(1.22);
    filter: brightness(1.25);
  }
  100% {
    transform: scale(1);
  }
}
.merge-readout {
  display: flex;
  justify-content: space-between;
  margin: 0.7rem 0 0.25rem;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.merge-score {
  color: var(--gold);
}
.merge-score.is-bump {
  animation: score-bump 0.45s var(--ease-pop);
}
@keyframes score-bump {
  40% {
    transform: scale(1.18);
  }
}
.merge-chain {
  color: var(--muted);
}
.merge-status {
  margin: 0.35rem 0 0;
  color: var(--cream);
  font-size: 0.85rem;
  line-height: 1.4;
}

.drop-block {
  position: absolute;
  z-index: 3;
  display: grid;
  place-items: center;
  border-radius: 22%;
  color: var(--ink);
  font-weight: 700;
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, 0.35),
    0 18px 24px rgba(10, 10, 26, 0.3);
  pointer-events: none;
}
.drop-block.a {
  top: 1%;
  left: 34%;
  width: 74px;
  height: 74px;
  font-size: 1.7rem;
  background: var(--block-grad);
  transform: rotate(-12deg);
  animation: bob-a 4.5s ease-in-out infinite;
}
.drop-block.b {
  top: 30%;
  right: 0.75rem;
  width: 56px;
  height: 56px;
  font-size: 1.3rem;
  background: linear-gradient(135deg, var(--mint), var(--teal));
  color: var(--ink);
  transform: rotate(10deg);
  animation: bob-b 4.5s ease-in-out infinite;
}
.drop-block.c {
  bottom: 6%;
  left: 6%;
  width: 50px;
  height: 50px;
  font-size: 1.15rem;
  /* partner stop reconciled to the board (was off-board #4f46e5): sky pairs
     with violet, both growth-board chart tokens */
  background: linear-gradient(135deg, var(--sky), var(--violet));
  transform: rotate(9deg);
  animation: bob-a 5.2s ease-in-out infinite;
}
@keyframes mascot-float {
  0%,
  100% {
    transform: translateY(0) rotate(-1deg);
  }
  50% {
    transform: translateY(-13px) rotate(1deg);
  }
}
@keyframes bob-a {
  0%,
  100% {
    translate: 0 0;
  }
  50% {
    translate: 0 14px;
  }
}
@keyframes bob-b {
  0%,
  100% {
    translate: 0 0;
  }
  50% {
    translate: 0 -12px;
  }
}

/* --------------------------------------------------------------- ribbon */

.ribbon {
  position: relative;
  z-index: 2;
  padding: 1rem 0;
  background: linear-gradient(90deg, var(--coral), var(--pink), var(--violet), var(--coral));
  background-size: 220% 100%;
  animation: ribbon-slide 11s linear infinite;
}
.ribbon p {
  margin: 0;
  color: var(--ink);
  font-size: 1.12rem;
  font-weight: 700;
  letter-spacing: 0.075em;
  text-align: center;
  text-transform: uppercase;
}
@keyframes ribbon-slide {
  to {
    background-position: 220% 0;
  }
}

/* ------------------------------------------------------------- sections */

.section {
  padding: 96px 0;
}
.section-heading {
  max-width: 700px;
  margin-bottom: 2.8rem;
}
.section-heading .eyebrow {
  color: var(--cream);
}
h2 {
  margin: 0.7rem 0 0;
  font-size: clamp(2.3rem, 5vw, 3.9rem);
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: -0.035em;
  text-transform: uppercase;
}
.section-intro {
  max-width: 640px;
  margin: 1.1rem 0 0;
  color: var(--muted);
  line-height: 1.7;
}

/* how to play (accent: pink) */

.howto {
  background: linear-gradient(180deg, var(--ink) 0%, var(--plum-deep) 100%);
}
.step-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
.step-card {
  padding: 1.6rem;
  border: 1px solid rgba(240, 147, 251, 0.22);
  border-radius: 1.4rem;
  background: linear-gradient(150deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02));
  box-shadow: var(--shadow-card);
}
.step-num {
  display: inline-grid;
  place-items: center;
  width: 2.4rem;
  height: 2.4rem;
  margin-bottom: 1.1rem;
  border-radius: 0.8rem;
  background: var(--pink);
  color: var(--ink);
  font-size: 1.25rem;
  font-weight: 700;
  box-shadow: 0 8px 20px rgba(240, 147, 251, 0.3);
}
.step-art {
  margin: 0 0 1.1rem;
}
.step-art svg {
  width: 100%;
  height: auto;
}
.step-card h3 {
  margin: 0 0 0.5rem;
  font-size: 1.45rem;
  letter-spacing: 0.01em;
}
.step-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}
.ladder {
  margin-top: 2.6rem;
}
.ladder-row {
  display: flex;
  gap: 0.45rem;
  padding: 0.6rem;
  overflow-x: auto;
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.05);
  scrollbar-width: thin;
}
.ladder-tile {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  min-width: 3.6rem;
  padding: 0.55rem 0.6rem;
  border-radius: 0.7rem;
  background: var(--plum-mid);
  color: var(--white);
  font-size: 1.15rem;
  font-weight: 700;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
}
.ladder-tile.final {
  /* partner stop reconciled to the board (was off-board #f97316): the final
     score tile keeps gold and pairs it with coral, both board tokens */
  background: linear-gradient(135deg, var(--gold), var(--coral));
  color: var(--ink);
  box-shadow: 0 10px 26px rgba(251, 191, 36, 0.32);
}
.ladder-note {
  margin: 0.7rem 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

/* about / the game */

.about {
  background:
    radial-gradient(circle at 80% 0, rgba(45, 212, 191, 0.09), transparent 30rem),
    var(--plum-deep);
}
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
.feature-card {
  min-height: 215px;
  padding: 1.6rem;
  border: 1px solid rgba(167, 139, 250, 0.2);
  border-radius: 1.4rem;
  background: linear-gradient(150deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.02));
  box-shadow: var(--shadow-card);
}
.feature-icon {
  display: grid;
  place-items: center;
  width: 3.2rem;
  height: 3.2rem;
  margin-bottom: 1.9rem;
  border-radius: 1rem;
  color: var(--ink);
  font-size: 1.45rem;
}
.feature-icon svg {
  width: 1.7rem;
  height: 1.7rem;
}
.feature-card.f-pink .feature-icon {
  background: linear-gradient(135deg, var(--pink), var(--violet));
}
.feature-card.f-teal .feature-icon {
  background: linear-gradient(135deg, var(--teal), var(--sky));
}
.feature-card.f-violet .feature-icon {
  /* partner stop reconciled to the board (was off-board #7c3aed) */
  background: linear-gradient(135deg, var(--violet), var(--sky));
}
.feature-card.f-gold .feature-icon {
  /* partner stop reconciled to the board (was off-board #fb923c) */
  background: linear-gradient(135deg, var(--gold), var(--coral));
}
.feature-card.f-mint .feature-icon {
  background: linear-gradient(135deg, var(--mint), var(--teal));
}
.feature-card.f-coral .feature-icon {
  background: linear-gradient(135deg, var(--coral), var(--pink));
}
.feature-card h3 {
  margin: 0 0 0.5rem;
  font-size: 1.4rem;
}
.feature-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.parade {
  margin-top: 3rem;
  padding: 1.6rem;
  border: 1px solid rgba(167, 139, 250, 0.18);
  border-radius: 1.5rem;
  background: linear-gradient(160deg, rgba(36, 17, 73, 0.7), rgba(26, 11, 46, 0.4));
}
.parade-heading {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.6rem;
  margin-bottom: 1.2rem;
}
.parade-heading h3 {
  margin: 0;
  font-size: 1.6rem;
}
.parade-heading p {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}
.parade-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}
.dino-chip {
  flex: 0 0 auto;
  display: grid;
  justify-items: center;
  gap: 0.4rem;
  /* 6rem + 2px borders keeps all ten chips on one row at the 1120px shell
     (10 x 98px + 9 gaps = 1075px); 6.2rem left an orphan wrap on wide screens */
  width: 6rem;
  padding: 0.7rem 0.4rem 0.6rem;
  border: 1px solid rgba(167, 139, 250, 0.22);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.05);
  transition:
    transform 0.18s ease,
    border-color 0.18s ease;
}
.dino-chip:hover {
  transform: translateY(-4px);
  border-color: var(--teal);
}
.dino-chip svg {
  width: 52px;
  height: 52px;
}
.dino-chip figcaption {
  color: var(--cream);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}
.seasons {
  margin-top: 1.6rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.season-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.32rem 0.8rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.season-chip i {
  width: 0.6rem;
  height: 0.6rem;
  border-radius: 50%;
}

/* screenshots */

.screens {
  background: linear-gradient(180deg, var(--plum-deep) 0%, var(--plum-mid) 100%);
}
.screens-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  align-items: center;
  gap: clamp(2rem, 6vw, 6rem);
}
.screens-copy p {
  margin: 1rem 0 0;
  color: var(--muted);
  line-height: 1.7;
}
.phone-stack {
  position: relative;
  height: 520px;
}
.phone {
  position: absolute;
  width: 225px;
  padding: 7px;
  overflow: hidden;
  border: 5px solid var(--ink);
  border-radius: 30px;
  background: var(--ink);
  box-shadow: var(--shadow-float);
}
.phone img {
  width: 100%;
  aspect-ratio: 9 / 16;
  object-fit: cover;
  object-position: top;
  border-radius: 20px;
}
.phone-back {
  top: 8px;
  left: 4%;
  transform: rotate(-10deg);
  opacity: 0.83;
}
.phone-middle {
  top: 26px;
  left: 33%;
  transform: rotate(-2deg);
  z-index: 1;
}
.phone-front {
  top: 48px;
  right: 5%;
  transform: rotate(8deg);
  z-index: 2;
}
.gallery {
  display: flex;
  gap: 1rem;
  padding: 1.6rem 0.4rem 0.6rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
}
.shot {
  flex: 0 0 auto;
  width: 190px;
  scroll-snap-align: center;
  margin: 0;
}
.shot img {
  width: 100%;
  aspect-ratio: 9 / 16;
  object-fit: cover;
  object-position: top;
  border: 4px solid var(--ink);
  border-radius: 22px;
  box-shadow: var(--shadow-card);
}
.shot figcaption {
  padding-top: 0.6rem;
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.4;
}

/* download cta */

.download-cta {
  padding: 100px 0;
  text-align: center;
  background:
    radial-gradient(circle at 50% 0, rgba(45, 212, 191, 0.22), transparent 30rem),
    linear-gradient(135deg, var(--plum-soft), var(--ink));
}
.download-cta h2 {
  max-width: 760px;
  margin: 0 auto;
}
.download-cta .section-intro {
  max-width: 560px;
  margin: 1.1rem auto 0;
}
.download-cta .store-links {
  justify-content: center;
}
.honest-note {
  max-width: 620px;
  margin: 1.4rem auto 0;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.85rem;
  line-height: 1.55;
}

/* --------------------------------------------------------------- footer */

footer {
  padding: 2.4rem 0 2.6rem;
  color: rgba(255, 255, 255, 0.62);
  background: var(--ink);
  font-size: 0.88rem;
}
.footer-grid {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.2rem;
}
.footer-brand {
  display: grid;
  gap: 0.7rem;
}
.footer-brand img {
  height: 24px;
  width: auto;
  opacity: 0.9;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.1rem;
}
.footer-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 0.35rem;
}
footer a {
  color: inherit;
  text-decoration: none;
}
footer a:hover {
  color: var(--teal);
}
.tiny-note a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

/* ---------------------------------------------------------- sticky bar */

.sticky-download {
  position: fixed;
  bottom: 1rem;
  left: 50%;
  z-index: 35;
  display: flex;
  align-items: center;
  gap: 1rem;
  width: min(640px, calc(100% - 28px));
  padding: 0.8rem 1rem;
  transform: translateX(-50%);
  border: 1px solid rgba(45, 212, 191, 0.35);
  border-radius: 1.1rem;
  background: rgba(26, 11, 46, 0.94);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 18px 44px rgba(10, 10, 26, 0.6);
}
/* the author display above would defeat the hidden attribute (author styles
   outrank the UA [hidden] rule), so the bar rendered before any scrolling;
   this restores the attribute's meaning */
.sticky-download[hidden] {
  display: none;
}
.sticky-copy {
  display: grid;
  line-height: 1.2;
}
.sticky-copy strong {
  font-size: 1.05rem;
}
.sticky-copy span {
  color: var(--muted);
  font-size: 0.82rem;
}
.sticky-store {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-left: auto;
  padding: 0.55rem 1.1rem;
  border-radius: 999px;
  background: var(--teal);
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}
.sticky-close {
  display: inline-grid;
  place-items: center;
  min-width: 44px;
  min-height: 44px;
  margin: -0.4rem -0.5rem;
  padding: 0.2rem 0.55rem;
  border: 0;
  border-radius: 0.5rem;
  background: transparent;
  color: var(--muted);
  font-size: 1.2rem;
  line-height: 1;
  cursor: pointer;
}
.sticky-close:hover {
  color: var(--white);
}

/* ------------------------------------------------------------ responsive */

@media (max-width: 940px) {
  .step-grid,
  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 760px) {
  .nav-links .nav-link {
    display: none;
  }
  .hero {
    padding: 2.4rem 0 4rem;
  }
  .hero-grid,
  .screens-grid {
    grid-template-columns: 1fr;
  }
  .hero-art {
    min-height: 0;
    margin-top: 1.6rem;
  }
  .merge-play {
    position: relative;
    top: 0;
    width: 100%;
    margin: 0 auto;
  }
  .mascot {
    position: relative;
    right: auto;
    bottom: auto;
    width: 260px;
    margin: -1.6rem auto 0;
    display: block;
  }
  .drop-block.a {
    left: 6%;
    top: -6%;
  }
  .drop-block.b {
    right: 4%;
    top: 34%;
  }
  .drop-block.c {
    display: none;
  }
  .step-grid,
  .feature-grid {
    grid-template-columns: 1fr;
  }
  .feature-card {
    min-height: 0;
  }
  .section {
    padding: 68px 0;
  }
  .phone-stack {
    height: 430px;
    margin-top: 1.4rem;
  }
  .phone {
    width: 148px;
  }
  .phone-back {
    left: 2%;
  }
  .phone-middle {
    left: 19%;
  }
  .phone-front {
    right: 3%;
  }
  .footer-grid {
    flex-direction: column;
    align-items: flex-start;
  }
}
@media (max-width: 420px) {
  .shell {
    width: calc(100% - 28px);
  }
  .store-links {
    flex-direction: column;
  }
  .store-button {
    width: 100%;
  }
  .dino-chip {
    width: 5.4rem;
  }
}

/* ------------------------------------------------------ reduced motion */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ============================================================ PHASE B (2026-09-23)
   New sections for about.html and how-to-play.html, plus the index video
   block and framed screenshot stack. Tokens come from the board via the
   flat variables above; biome accent hexes on how-to-play.html are the
   game's own BIOME_THEMES, transcribed in docs/copy-deck.md from
   /opt/ploposaurus/public/biomes.js, and are passed per card as --biome. */

/* subpage header */
.page-head {
  padding: 4.2rem 0 3.4rem;
  background:
    radial-gradient(circle at 82% -10%, rgba(240, 147, 251, 0.14), transparent 26rem),
    radial-gradient(circle at 12% 60%, rgba(45, 212, 191, 0.09), transparent 26rem),
    var(--plum-deep);
}
.page-head h1 {
  margin: 0.9rem 0 1.1rem;
  font-size: clamp(2.7rem, 6.5vw, 4.6rem);
}
.page-head .lede {
  max-width: 640px;
  margin: 0;
  color: var(--muted);
  font-size: clamp(1.02rem, 1.9vw, 1.18rem);
  line-height: 1.65;
}
.more-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-top: 1.4rem;
  color: var(--teal);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.3em;
}
.more-link:hover {
  color: var(--cream);
}
.btn-ghost {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-top: 1.5rem;
  padding: 0.5rem 1.2rem;
  border: 2px solid var(--teal);
  border-radius: 999px;
  color: var(--cream);
  font-weight: 700;
  text-decoration: none;
  transition:
    background 0.18s ease,
    transform 0.18s ease;
}
.btn-ghost:hover {
  background: rgba(45, 212, 191, 0.14);
  transform: translateY(-2px);
}
.back-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.6rem;
  margin-top: 1.8rem;
}

/* index: framed screenshot stack (bezel baked into the composites).
   Geometry note: every figure is a rotated box, so its bounding box is wider
   than its layout width; offsets are fixed px (not %) and sizes shrink per
   breakpoint so the rotated boxes always stay inside the stack. */
.frame-stack {
  position: relative;
  height: 540px;
}
.frame-stack figure {
  position: absolute;
  width: 240px;
  margin: 0;
  border-radius: 1.5rem;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: var(--ink);
  box-shadow: var(--shadow-float);
}
.frame-stack img {
  display: block;
  width: 100%;
  aspect-ratio: 9 / 16;
  object-fit: cover;
}
.frame-back {
  top: 10px;
  left: 36px;
  transform: rotate(-7deg);
  opacity: 0.85;
}
.frame-middle {
  top: 28px;
  left: 50%;
  transform: translateX(-50%) rotate(-2deg);
  z-index: 1;
}
.frame-front {
  top: 52px;
  right: 36px;
  transform: rotate(6deg);
  z-index: 2;
}

/* index + how-to: the gameplay clip */
.clip-block {
  max-width: 400px;
  margin: 3.2rem auto 0;
  text-align: center;
}
.clip-block video {
  display: block;
  width: 100%;
  aspect-ratio: 9 / 16;
  border: 4px solid var(--ink);
  border-radius: 1.6rem;
  background: var(--ink);
  box-shadow: var(--shadow-float);
}
.store-links.left {
  justify-content: flex-start;
}
.clip-caption {
  margin: 1.1rem 0 0;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}
.clip-facts {
  margin: 0.4rem 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.5;
}
.clip-chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.65rem;
  margin-top: 0.9rem;
}
.clip-chip {
  padding: 0.28rem 0.8rem;
  border: 1px solid rgba(167, 139, 250, 0.4);
  border-radius: 999px;
  color: var(--cream);
  font-size: 0.85rem;
  font-weight: 700;
}
.clip-chip.is-score {
  border-color: rgba(251, 191, 36, 0.55);
  color: var(--gold);
}

/* about: story prose */
.story {
  max-width: 680px;
}
.story p {
  margin: 0 0 1rem;
  color: var(--muted);
  line-height: 1.7;
}
.story .story-roar {
  margin: 0;
  color: var(--cream);
  font-weight: 700;
  font-size: 1.15rem;
}

/* about: factsheet */
.factsheet {
  max-width: 760px;
  margin: 0;
  border-top: 1px solid rgba(167, 139, 250, 0.28);
}
.factsheet div {
  display: grid;
  grid-template-columns: minmax(110px, 190px) 1fr;
  gap: 0.4rem 1.4rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid rgba(167, 139, 250, 0.28);
}
.factsheet dt {
  color: var(--cream);
  font-weight: 700;
}
.factsheet dd {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}
.factsheet dd a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--teal);
  font-weight: 700;
  text-decoration: none;
}
.factsheet dd a:hover {
  text-decoration: underline;
}

/* about: mascot variants */
.mascot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr));
  gap: 1.4rem 1rem;
  margin-top: 2.2rem;
}
.mascot-grid figure {
  display: grid;
  justify-items: center;
  gap: 0.7rem;
  margin: 0;
}
.mascot-grid img {
  width: min(100%, 150px);
  filter: drop-shadow(0 18px 22px rgba(10, 10, 26, 0.5));
}
.mascot-grid figcaption {
  color: var(--cream);
  font-weight: 700;
  letter-spacing: 0.03em;
}

/* about + how-to: dino art strips (game DINO_ART, not the kit mascot) */
.dino-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  gap: 1rem;
  margin-top: 2rem;
}
.dino-strip article {
  display: grid;
  justify-items: start;
  gap: 0.5rem;
  padding: 1.1rem 1.2rem 1.1rem 1.4rem;
  border-left: 4px solid var(--pink);
  border-radius: 0.4rem 1rem 1rem 0.4rem;
  background: rgba(255, 255, 255, 0.04);
}
.dino-strip svg {
  width: 60px;
  height: 60px;
}
.dino-strip h3 {
  margin: 0;
  font-size: 1.2rem;
}
.dino-strip p {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

/* how-to: animated merge demo (pure CSS; static merged frame under
   prefers-reduced-motion, see the block at the end of this section) */
.demo {
  position: relative;
  height: 168px;
  max-width: 100%;
  width: 320px;
  margin: 1.6rem auto 0.4rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 1.2rem;
  background: rgba(255, 255, 255, 0.05);
  overflow: hidden;
}
.demo-tile,
.demo-result {
  position: absolute;
  top: 50%;
  display: grid;
  place-items: center;
  width: 84px;
  height: 84px;
  margin-top: -42px;
  border-radius: 22%;
  color: var(--ink);
  font-size: 1.9rem;
  font-weight: 700;
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, 0.35),
    0 16px 26px rgba(10, 10, 26, 0.35);
}
.demo-tile {
  background: var(--block-grad);
}
.demo-tile.is-left {
  left: 8%;
  animation: demo-left 3.8s ease-in-out infinite;
}
.demo-tile.is-right {
  right: 8%;
  animation: demo-right 3.8s ease-in-out infinite;
}
.demo-result {
  left: 50%;
  margin-left: -42px;
  background: linear-gradient(135deg, var(--mint), var(--teal));
  opacity: 0;
  animation: demo-result 3.8s ease-in-out infinite;
}
.demo-flash {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, rgba(251, 191, 36, 0.32), transparent 46%);
  opacity: 0;
  animation: demo-flash 3.8s ease-in-out infinite;
}
.demo-note {
  margin: 0.9rem 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  text-align: center;
}
@keyframes demo-left {
  0%,
  14% {
    transform: translateX(0);
    opacity: 1;
  }
  47% {
    transform: translateX(84px);
    opacity: 1;
  }
  51%,
  100% {
    transform: translateX(84px);
    opacity: 0;
  }
}
@keyframes demo-right {
  0%,
  14% {
    transform: translateX(0);
    opacity: 1;
  }
  47% {
    transform: translateX(-84px);
    opacity: 1;
  }
  51%,
  100% {
    transform: translateX(-84px);
    opacity: 0;
  }
}
@keyframes demo-result {
  0%,
  50% {
    opacity: 0;
    transform: scale(0.4);
  }
  57% {
    opacity: 1;
    transform: scale(1.24);
  }
  67%,
  90% {
    opacity: 1;
    transform: scale(1);
  }
  100% {
    opacity: 0;
    transform: scale(1);
  }
}
@keyframes demo-flash {
  0%,
  48% {
    opacity: 0;
  }
  53% {
    opacity: 1;
  }
  62%,
  100% {
    opacity: 0;
  }
}

/* how-to: biome tour. --biome comes from the page (game BIOME_THEMES). */
.biome-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr));
  gap: 1rem;
  margin-top: 2.4rem;
}
.biome-card {
  position: relative;
  min-height: 172px;
  padding: 1.15rem 1.2rem 1.1rem 1.55rem;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 1.1rem;
  background: rgba(255, 255, 255, 0.035);
  overflow: hidden;
}
.biome-card::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 0;
  width: 6px;
  background: var(--biome);
}
.biome-card::after {
  content: '';
  position: absolute;
  /* kept fully inside the card: an off-edge blob would count in the card's
     scrollWidth even under overflow: hidden, and trip the overflow gate */
  top: 14px;
  right: 14px;
  width: 104px;
  height: 104px;
  border-radius: 50%;
  background: var(--biome);
  opacity: 0.09;
}
.biome-card h3 {
  position: relative;
  margin: 0 0 0.45rem;
  font-size: 1.3rem;
}
.biome-intro {
  position: relative;
  margin: 0;
  color: var(--cream);
  line-height: 1.5;
}
.biome-wrinkle {
  position: relative;
  margin: 0.55rem 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}
.biome-card svg {
  position: absolute;
  right: 0.85rem;
  bottom: 0.85rem;
  width: 64px;
  height: 64px;
  /* Species fills stay verbatim; each silhouette gets a soft glow in its own
     biome accent so dark-coated species (Nyxosaurus #7c3aed) still read on
     plum cards. Decorative only, so contrast rules do not apply to it. */
  filter: drop-shadow(0 0 8px color-mix(in srgb, var(--biome) 55%, transparent));
}
/* Ten cards, no orphan row: 2 cols mid-width (5 rows), 3 cols wide with the
   Apex Summit finale spanning 2 so the last row fills. Divisors only. */
@media (min-width: 640px) {
  .biome-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .biome-card--wide {
    grid-column: span 2;
  }
}
@media (min-width: 1024px) {
  .biome-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}
.era-note {
  max-width: 700px;
  margin: 1.8rem 0 0;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* how-to: power-ups */
.power-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 225px), 1fr));
  gap: 0.8rem;
  margin-top: 2.4rem;
}
/* Ten cards, no orphan row: 2 cols mid-width (5 rows), 5 cols wide (2 rows).
   Column counts that divide 10 only. */
@media (min-width: 640px) and (max-width: 1199px) {
  .power-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1200px) {
  .power-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}
.power-card {
  display: flex;
  align-items: flex-start;
  gap: 0.9rem;
  padding: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.9rem;
  background: var(--plum-soft);
}
.power-icon {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 0.8rem;
  background: var(--block-grad);
  color: var(--ink);
}
.power-icon svg {
  width: 1.25rem;
  height: 1.25rem;
}
.power-card h3 {
  margin: 0 0 0.3rem;
  font-size: 1.15rem;
}
.power-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}

/* how-to: daily challenges + offline */
.duo {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 1rem;
  margin-top: 2.4rem;
}
.panel {
  padding: 1.5rem 1.5rem 1.6rem;
  border-radius: 1.2rem;
}
.panel-daily {
  border: 1px solid rgba(167, 139, 250, 0.28);
  background: linear-gradient(160deg, rgba(36, 17, 73, 0.75), rgba(26, 11, 46, 0.45));
}
.panel-offline {
  border: 1px solid rgba(74, 222, 128, 0.32);
  background: rgba(74, 222, 128, 0.06);
}
.panel h3 {
  margin: 0 0 0.7rem;
  font-size: 1.4rem;
}
.panel p {
  margin: 0 0 0.7rem;
  color: var(--muted);
  line-height: 1.6;
}
.panel p:last-child {
  margin-bottom: 0;
}

/* respect block (store description, kept near purchase talk) */
.respect {
  max-width: 680px;
  margin: 1.8rem auto 0;
  padding: 1.2rem 1.4rem;
  border: 1px solid rgba(240, 147, 251, 0.28);
  border-radius: 1rem;
  background: rgba(240, 147, 251, 0.06);
}
.respect p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

/* merge ladder milestone flavor (how-to) */
.ladder-milestones {
  max-width: 640px;
  margin: 1.2rem 0 0;
  padding: 0;
  list-style: none;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.7;
}
.ladder-milestones li::before {
  content: '';
  display: inline-block;
  width: 0.55rem;
  height: 0.55rem;
  margin-right: 0.6rem;
  border-radius: 50%;
  background: var(--teal);
  vertical-align: middle;
}

/* Phase B responsive */
@media (max-width: 760px) {
  .page-head {
    padding: 3rem 0 2.6rem;
  }
  .frame-stack {
    height: 460px;
  }
  .frame-stack figure {
    width: 200px;
  }
  .clip-block {
    margin-top: 2.6rem;
  }
  .factsheet div {
    grid-template-columns: 1fr;
    gap: 0.15rem;
  }
  .demo {
    width: 100%;
  }
}
@media (max-width: 420px) {
  .frame-stack {
    height: 380px;
  }
  .frame-stack figure {
    width: 172px;
  }
}

/* Phase B reduced motion: the merge demo holds its merged frame, and the
   clip never autoplays (js also checks). Everything else is already covered
   by the global block above. */
@media (prefers-reduced-motion: reduce) {
  .demo-tile,
  .demo-result,
  .demo-flash {
    animation: none;
  }
  .demo-tile {
    opacity: 0;
  }
  .demo-result {
    opacity: 1;
    transform: none;
  }
}
