/* Plateoff landing page. The app's Midnight Feast world: indigo night, cream ink, butter for
   highlights and pills, one tomato action. Bricolage Grotesque over Onest, both served from fonts/.
   Each font keeps every Latin letter but only the weights these pages use (Bricolage 700 to 800, Onest
   400 to 700), which makes them 15 KB lighter. A new weight needs the full files from
   @fontsource-variable/bricolage-grotesque and /onest, cut again (docs/ASSETS.md). */

@font-face {
  font-family: 'Bricolage Grotesque';
  src: url('fonts/bricolage-grotesque-latin-wght-normal.woff2') format('woff2');
  font-weight: 700 800;
  font-display: swap;
}

@font-face {
  font-family: 'Onest';
  src: url('fonts/onest-latin-wght-normal.woff2') format('woff2');
  font-weight: 400 700;
  font-display: swap;
}

:root {
  --sky: #19142f;
  --sky-2: #221b40;
  --panel: #2a2150;
  --panel-2: #332a5e;
  --line: #3b3170;
  --hairline: rgba(255, 243, 220, 0.14);
  --ink: #fff3dc;
  --ink-2: #b7aee0;
  --butter: #ffd23f;
  --on-butter: #19142f;
  --tomato: #ff5a3c;
  --good: #7de68c;
  --cold: #6fb1ff;
  --hot: #ff5a3c;
  --bronze: #d6905c;
  --silver: #c9cfdf;
  /* The app's Diamond rank colour (RANK_INK in src/app/ui/RankEmblem.tsx). */
  --diamond: #8fdcff;
  --display: 'Bricolage Grotesque', system-ui, sans-serif;
  --text: 'Onest', system-ui, sans-serif;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  /* Every section starts on the pitch's own left edge. */
  --edge: calc(36 * var(--u));
  /* The first screen is drawn on a 1024-wide sheet and scales with the window, up to 1600. */
  --u: calc(min(100vw, 1600px) / 1024);
  color-scheme: dark;
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scrollbar-color: var(--line) var(--sky);
}

body {
  margin: 0;
  font: 400 1.0625rem/1.6 var(--text);
  color: var(--ink-2);
  background-color: var(--sky);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection {
  background: var(--butter);
  color: var(--on-butter);
}

:focus-visible {
  outline: 3px solid var(--butter);
  outline-offset: 3px;
  border-radius: 6px;
}

img,
video {
  max-width: 100%;
}

h1,
h2,
h3,
p,
ul,
ol,
dl,
dd,
figure {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

a {
  color: inherit;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 0.2em;
}

.lp-skip {
  position: absolute;
  left: 12px;
  top: -80px;
  z-index: 10;
  padding: 12px 18px;
  border-radius: 999px;
  background: var(--butter);
  color: var(--on-butter);
  font-weight: 700;
  text-decoration: none;
}

.lp-skip:focus {
  top: 12px;
}

/* ── buttons: full pills, as in the app ── */

.lp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55em;
  min-height: 48px;
  padding: 0 1.6em;
  border: 0;
  border-radius: 999px;
  font: 700 1rem/1 var(--text);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition:
    transform 120ms var(--ease),
    box-shadow 220ms var(--ease),
    background-color 220ms var(--ease);
}

.lp-btn svg {
  flex: none;
  width: 1.3em;
  height: 1.3em;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.lp-btn svg .is-solid {
  fill: currentColor;
  stroke: none;
}

.lp-btn--go {
  background: var(--tomato);
  color: var(--on-butter);
  box-shadow: 0 8px 20px -8px rgba(0, 0, 0, 0.6);
}

.lp-btn--butter {
  background: var(--butter);
  color: var(--on-butter);
  box-shadow: 0 6px 16px -6px rgba(0, 0, 0, 0.5);
}

.lp-btn--line {
  background: rgba(25, 20, 47, 0.6);
  color: var(--ink);
  box-shadow: inset 0 0 0 2px var(--butter);
}

.lp-btn--small {
  min-height: 44px;
  padding: 0 1.25em;
  font-size: 0.875rem;
}

@media (hover: hover) {
  .lp-btn:hover {
    transform: translateY(-2px);
  }

  .lp-btn--go:hover {
    background: #ff6c50;
    box-shadow: 0 14px 26px -10px rgba(0, 0, 0, 0.7);
  }

  .lp-btn--butter:hover {
    background: #ffdc66;
  }

  .lp-btn--line:hover {
    background: rgba(255, 210, 63, 0.12);
  }
}

.lp-btn:active {
  transform: translateY(1px);
}

.lp-btn:disabled {
  cursor: default;
  transform: none;
}

/* ── top bar ── */

.lp-top {
  max-width: 1600px;
  margin: 0 auto;
}

.lp-nav {
  display: flex;
  align-items: center;
  height: calc(68 * var(--u));
  padding: 0 calc(23 * var(--u)) 0 calc(31 * var(--u));
}

.lp-brand {
  display: inline-flex;
  align-items: center;
  gap: calc(2 * var(--u));
  width: calc(308 * var(--u));
  color: var(--ink);
  text-decoration: none;
}

.lp-brand__mark {
  display: block;
  width: calc(52 * var(--u));
  height: auto;
}

.lp-brand__name {
  font: 800 calc(24 * var(--u))/1 var(--display);
  letter-spacing: -0.04em;
  color: var(--ink);
}

/* The wordmark's second word, "off", is butter (the owner's choice of 14 November 2026). */
.lp-brand__off {
  color: var(--butter);
}

/* The o of "off" is a small butter moon with three craters, as in the app's logo (DESIGN.md, "The logo
   and the rat"; the owner, 14 November 2026). The letter stays in the text for reading and copying. */
.lp-brand__o {
  display: inline-block;
  width: 0.62em;
  height: 0.62em;
  margin: 0 0.03em 0 0.05em;
  border-radius: 50%;
  color: transparent;
  overflow: hidden;
  vertical-align: baseline;
  background:
    radial-gradient(circle at 33% 35%, rgba(120, 80, 0, 0.16) 0 13%, transparent 14%),
    radial-gradient(circle at 65% 65%, rgba(120, 80, 0, 0.16) 0 9%, transparent 10%),
    radial-gradient(circle at 66% 24%, rgba(120, 80, 0, 0.16) 0 6%, transparent 7%),
    var(--butter);
}

.lp-nav__links {
  display: flex;
  gap: calc(33 * var(--u));
}

.lp-nav__links a {
  padding: 0.6em 0;
  font: 600 max(13px, calc(14.5 * var(--u)))/1 var(--text);
  color: var(--ink);
  text-decoration: none;
}

.lp-nav__links a:hover {
  color: var(--butter);
}

/* English and Português, at the top (the owner's words: "a language switcher right at the top"). It is
   hidden until i18n.js runs, since without it the switch could do nothing. */
.lp-lang {
  display: flex;
  gap: 2px;
  margin-left: auto;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--sky-2);
}

.lp-lang[hidden] {
  display: none;
}

.lp-lang button {
  min-width: max(40px, calc(40 * var(--u)));
  min-height: max(32px, calc(30 * var(--u)));
  padding: 0 10px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--ink-2);
  font: 700 max(13px, calc(13 * var(--u)))/1 var(--text);
  letter-spacing: 0.04em;
  cursor: pointer;
}

.lp-lang button[aria-pressed='true'] {
  background: var(--panel-2);
  color: var(--butter);
  cursor: default;
}

@media (hover: hover) {
  .lp-lang button[aria-pressed='false']:hover {
    color: var(--ink);
  }
}

/* Until the Portuguese is in place, a visitor who chose it sees nothing rather than English. */
.lp-nav .lp-btn {
  margin-left: calc(12 * var(--u));
  min-height: max(40px, calc(38 * var(--u)));
  padding: 0 calc(15 * var(--u));
  font-size: max(13px, calc(13.5 * var(--u)));
  box-shadow: none;
}

.lp-lang[hidden] + .lp-btn {
  margin-left: auto;
}

/* ── the pitch ── */

.lp-hero {
  position: relative;
  padding: calc(26 * var(--u)) calc(36 * var(--u)) 0;
}

.lp-hero__title {
  max-width: calc(730 * var(--u));
  font: 800 calc(44 * var(--u))/1.045 var(--display);
  letter-spacing: -0.02em;
  color: var(--ink);
}

/* The third beat always starts its own line. */
.lp-hero__title span:last-child {
  display: block;
}

.lp-hero__title em {
  font-style: normal;
  color: var(--butter);
}

.lp-hero__intro {
  max-width: calc(662 * var(--u));
  margin-top: calc(18 * var(--u));
  font: 400 calc(16.6 * var(--u))/1.5 var(--text);
  color: var(--ink-2);
}

.lp-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: calc(15 * var(--u));
  margin-top: calc(26 * var(--u));
}

.lp-hero .lp-btn {
  min-height: max(44px, calc(47 * var(--u)));
  padding: 0 calc(31 * var(--u));
  font-size: max(15px, calc(16 * var(--u)));
}

.lp-hero__host {
  position: absolute;
  left: calc(748 * var(--u));
  top: calc(-8 * var(--u));
  width: calc(214 * var(--u));
  height: auto;
  pointer-events: none;
}

/* The row runs off both edges; it scrolls sideways to show the rest. */
.lp-dishes {
  margin: calc(52 * var(--u)) calc(-36 * var(--u)) 0;
  padding: 0 calc(3 * var(--u));
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
}

.lp-dishes::-webkit-scrollbar {
  display: none;
}

.lp-dishes__track {
  display: flex;
  gap: calc(4 * var(--u));
  width: max-content;
}

.lp-dish {
  position: relative;
  flex: none;
  width: calc(126 * var(--u));
  height: calc(105 * var(--u));
  border-radius: calc(9 * var(--u));
  overflow: hidden;
  background: var(--panel);
}

.lp-dish img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lp-dish b {
  position: absolute;
  left: calc(4 * var(--u));
  top: calc(3 * var(--u));
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: calc(38 * var(--u));
  height: calc(25 * var(--u));
  padding: 0 0.5em;
  border-radius: 999px;
  /* A dish's score runs from cold blue, through cream and butter, to hot tomato: four stops, mixed in
     oklab so no step turns pink, green or muddy. Butter is the fallback where colour mixing is missing. */
  background: var(--butter);
  background: color-mix(
    in oklab,
    var(--hot) calc(clamp(0, (var(--heat, 0.5) - 0.56) / 0.44, 1) * 100%),
    color-mix(
      in oklab,
      var(--butter) calc(clamp(0, (var(--heat, 0.5) - 0.3) / 0.26, 1) * 100%),
      color-mix(in oklab, var(--ink) calc(clamp(0, var(--heat, 0.5) / 0.3, 1) * 100%), var(--cold))
    )
  );
  color: var(--on-butter);
  font: 800 calc(13.5 * var(--u))/1 var(--display);
  font-variant-numeric: tabular-nums;
  box-shadow: 0 3px 8px -2px rgba(0, 0, 0, 0.5);
  animation: lp-stamp 520ms var(--ease) backwards;
}

/* A flame on the hottest dishes: the app's own flame icon (IconFlame), butter with an ink outline. */
.lp-dish b.is-hot::after {
  content: '';
  flex: none;
  width: 0.86em;
  height: 1.16em;
  margin-left: 0.22em;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='5.3 1.3 13.4 18.4' fill='%23ffd23f' stroke='%2319142f' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3c1 3.5 5 5.5 5 10a5 5 0 0 1-10 0c0-2 1-3.5 2-4.5.3 1.6 1 2.3 1.7 2.5C10.5 8.5 10.8 5.5 12 3Z'/%3E%3C/svg%3E") center / contain no-repeat;
}

.lp-dish:nth-child(2) b { animation-delay: 70ms; }
.lp-dish:nth-child(3) b { animation-delay: 140ms; }
.lp-dish:nth-child(4) b { animation-delay: 210ms; }
.lp-dish:nth-child(5) b { animation-delay: 280ms; }
.lp-dish:nth-child(6) b { animation-delay: 350ms; }
.lp-dish:nth-child(7) b { animation-delay: 420ms; }
.lp-dish:nth-child(8) b { animation-delay: 490ms; }

/* The points land on each photo as the page opens. The app's own stamp is an outlined label; this is its
   filled-pill cousin. */
@keyframes lp-stamp {
  from {
    opacity: 0;
    transform: scale(1.7) rotate(-14deg);
  }
}

/* The night sky behind the whole page (the owner, 15 November 2026: "make the stars more prominent ...
   and some hand drawn galaxies and other astral objects in the background, without taking too much
   attention"). Three fixed layers: hand-drawn galaxies, a ringed planet, a comet, a crescent and two
   constellations, faint; and two sets of stars that twinkle slowly out of step. They drift a little
   slower than the page as it scrolls (--scroll, set by main.js). Sections with their own fill cover it. */
.lp-sky {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.lp-sky i {
  position: absolute;
  inset: 0;
  background-repeat: repeat;
  background-size: 1440px auto;
}

.lp-sky__far {
  background-image: url("assets/sky/sky-far.svg");
  background-position: center calc(var(--scroll, 0) * -0.03px);
}

.lp-sky__stars {
  background-position: center calc(var(--scroll, 0) * -0.07px);
  animation: lp-twinkle 5.5s ease-in-out infinite alternate;
}

.lp-sky__stars--a {
  background-image: url("assets/sky/sky-stars-a.svg");
}

.lp-sky__stars--b {
  background-image: url("assets/sky/sky-stars-b.svg");
  animation-delay: -2.75s;
}

@keyframes lp-twinkle {
  from {
    opacity: 0.35;
  }

  to {
    opacity: 1;
  }
}

@media (max-width: 599px) {
  .lp-sky i {
    background-size: 1000px auto;
  }
}

/* The sample dishes float a little while the page is still, each on its own beat, and the row slides
   sideways as the page scrolls (at most about 40px). */
.lp-dishes__track {
  transform: translateX(calc(min(var(--scroll, 0), 700) * -0.06px));
  will-change: transform;
}

.lp-dish {
  animation: lp-float 6.5s ease-in-out infinite alternate;
}

.lp-dish:nth-child(2n) {
  animation-duration: 7.4s;
  animation-delay: -2.1s;
}

.lp-dish:nth-child(3n) {
  animation-duration: 5.8s;
  animation-delay: -3.7s;
}

.lp-dish:nth-child(5n) {
  animation-delay: -1.2s;
}

@keyframes lp-float {
  from {
    transform: translateY(0) rotate(-0.5deg);
  }

  to {
    transform: translateY(-5px) rotate(0.6deg);
  }
}

/* A few stars, only where the sky is empty: beside the host and above the divisions. */
.lp-hero::before,
.lp-steps::before {
  content: '';
  position: absolute;
  pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 316 238'%3E%3Ccircle cx='41' cy='128' r='1.4' fill='%23fff3dc' opacity='.75'/%3E%3Ccircle cx='16' cy='209' r='1.1' fill='%23c5bde8' opacity='.6'/%3E%3Ccircle cx='224' cy='12' r='1.2' fill='%23fff3dc' opacity='.5'/%3E%3Ccircle cx='284' cy='98' r='1.5' fill='%23ffd23f' opacity='.7'/%3E%3Ccircle cx='306' cy='200' r='1.1' fill='%23c5bde8' opacity='.55'/%3E%3Ccircle cx='253' cy='233' r='1.3' fill='%23fff3dc' opacity='.6'/%3E%3C/svg%3E")
    no-repeat left top / contain;
}

.lp-hero::before {
  left: calc(704 * var(--u));
  top: 0;
  width: calc(316 * var(--u));
  height: calc(238 * var(--u));
}

.lp-steps {
  position: relative;
}

.lp-steps::before {
  left: 0;
  top: 0;
  width: 44%;
  aspect-ratio: 316 / 238;
  transform: scaleX(-1);
}

/* ── the blind vote ── */

.lp-vote {
  padding: calc(64 * var(--u)) 0 calc(40 * var(--u));
}

.lp-vote__panel {
  width: calc(808 * var(--u));
  max-width: calc(100% - 24px);
  margin: 0 auto;
  padding: calc(30 * var(--u)) calc(28 * var(--u)) calc(38 * var(--u));
  border: 1.5px solid var(--butter);
  border-radius: calc(26 * var(--u));
  background: var(--sky-2);
  text-align: center;
}

.lp-vote__q {
  max-width: none;
  margin: 0;
  font: 800 calc(31 * var(--u))/1.16 var(--display);
  letter-spacing: -0.015em;
  color: var(--butter);
}

.lp-vote__pair {
  display: flex;
  justify-content: center;
  gap: calc(30 * var(--u));
  margin-top: calc(22 * var(--u));
}

.lp-ballot {
  position: relative;
  width: calc(209 * var(--u));
  padding: calc(3 * var(--u)) calc(3 * var(--u)) calc(6 * var(--u));
  border-radius: calc(13 * var(--u));
  background: var(--panel-2);
  box-shadow: 0 10px 24px -8px rgba(0, 0, 0, 0.55);
  transition:
    opacity 320ms var(--ease),
    transform 320ms var(--ease),
    box-shadow 320ms var(--ease);
}

.lp-ballot img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 204 / 110;
  object-fit: cover;
  border-radius: calc(10 * var(--u));
  /* A plate-coloured space while the photo arrives, not an empty hole. */
  background: var(--panel);
  transition: opacity 200ms linear;
}

.lp-vote__pair.is-swapping img {
  opacity: 0;
}

.lp-ballot__photo {
  position: relative;
}

/* A pick earns the cook ranking points, so a stamp lands on the photo that was picked. */
.lp-ballot__stamp {
  position: absolute;
  right: calc(8 * var(--u));
  bottom: calc(8 * var(--u));
  display: none;
  place-items: center;
  min-width: max(44px, calc(46 * var(--u)));
  height: max(30px, calc(30 * var(--u)));
  padding: 0 0.6em;
  border-radius: 999px;
  background: var(--tomato);
  color: var(--on-butter);
  font: 800 max(15px, calc(16 * var(--u)))/1 var(--display);
  box-shadow: 0 4px 10px -3px rgba(0, 0, 0, 0.55);
  transform: rotate(-8deg);
}

.lp-ballot.is-picked .lp-ballot__stamp {
  display: grid;
  animation: lp-land 460ms var(--ease) backwards;
}

@keyframes lp-land {
  from {
    opacity: 0;
    transform: scale(1.9) rotate(-22deg);
  }
}

.lp-ballot__letter {
  position: absolute;
  left: calc(6 * var(--u));
  top: calc(6 * var(--u));
  z-index: 1;
  display: grid;
  place-items: center;
  width: calc(36 * var(--u));
  height: calc(36 * var(--u));
  border-radius: 50%;
  background: var(--ink);
  color: var(--on-butter);
  font: 800 calc(19 * var(--u))/1 var(--display);
}

.lp-ballot .lp-btn {
  width: calc(100% - 12 * var(--u));
  min-height: max(44px, calc(38 * var(--u)));
  margin-top: calc(6 * var(--u));
  padding: 0;
  font-size: max(14px, calc(15 * var(--u)));
}

.lp-ballot.is-picked {
  transform: translateY(calc(-4 * var(--u)));
  box-shadow:
    0 0 0 3px var(--butter),
    0 16px 30px -10px rgba(0, 0, 0, 0.6);
}

.lp-ballot.is-passed {
  opacity: 0.42;
}

.lp-ballot.is-picked .lp-btn,
.lp-ballot.is-passed .lp-btn {
  box-shadow: none;
}

/* Read by screen readers only. */
.lp-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* Three pairs: one dot each. */
.lp-vote__dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: calc(22 * var(--u));
}

.lp-vote__dots[hidden] {
  display: none;
}

.lp-vote__dots li {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--line);
  transition: background-color 220ms var(--ease);
}

.lp-vote__dots li.is-on {
  background: var(--butter);
}

.lp-vote__pair[hidden] {
  display: none;
}

/* The reveal: a table of six dishes that opens into this week's table of cooks. */
.lp-reveal {
  display: grid;
  align-content: start;
  gap: 6px;
  width: min(100%, 460px);
  margin: calc(20 * var(--u)) auto 0;
  text-align: left;
}

.lp-reveal[hidden] {
  display: none;
}

.lp-reveal__row {
  position: relative;
  display: grid;
  grid-template-columns: 22px 56px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 6px 16px 6px 12px;
  border-radius: 14px;
  background: var(--panel);
  color: var(--ink);
}

/* The dishes the visitor picked. */
.lp-reveal__row.is-yours {
  background: var(--panel-2);
  box-shadow: inset 0 0 0 1.5px var(--butter);
}

.lp-reveal__row--cook {
  grid-template-columns: 20px 36px minmax(0, 1fr) auto 28px 3.2ch;
  gap: 10px;
  min-height: 52px;
}

.lp-reveal__rank {
  font: 800 1rem/1 var(--display);
  font-variant-numeric: tabular-nums;
  color: var(--butter);
  text-align: center;
}

.lp-reveal__dish {
  display: block;
  border-radius: 12px;
  object-fit: cover;
  transform-origin: 0 0;
}

.lp-reveal__dish {
  width: 56px;
  height: 44px;
}

.lp-reveal__face {
  display: block;
  width: 36px;
  height: 36px;
  border-radius: 999px;
}

.lp-reveal__what {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.lp-reveal__what b {
  font: 700 1rem/1.1 var(--text);
}

/* Votes won, as a bar that fills while the points count. */
.lp-reveal__votes {
  display: flex;
  align-items: center;
  gap: 8px;
  font: 400 14px/1 var(--text);
  font-variant-numeric: tabular-nums;
  color: var(--ink-2);
}

.lp-reveal__bar {
  flex: 1;
  max-width: 150px;
  height: 6px;
  border-radius: 999px;
  background: var(--line);
  overflow: hidden;
}

.lp-reveal__bar i {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: var(--ink-2);
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform 1100ms var(--ease);
}

.lp-reveal__row.is-yours .lp-reveal__bar i {
  background: var(--butter);
}

.lp-reveal.is-counted .lp-reveal__bar i {
  transform: scaleX(var(--won));
}

/* A cook's dishes this week, up to three. The judged one lands last, with the points it brings. */
.lp-reveal__plates {
  display: flex;
  justify-content: flex-end;
  gap: 4px;
}

.lp-reveal__plates img {
  display: block;
  width: 32px;
  height: 26px;
  border-radius: 6px;
  object-fit: cover;
  transform-origin: 0 0;
  transition: opacity 400ms var(--ease);
}

.lp-reveal__plate {
  position: relative;
  display: grid;
  place-items: center;
}

.lp-reveal__plate i {
  position: absolute;
  z-index: 1;
  padding: 0.3em 0.55em;
  border-radius: 999px;
  background: var(--butter);
  color: var(--on-butter);
  font: 800 14px/1 var(--display);
  font-style: normal;
  font-variant-numeric: tabular-nums;
  box-shadow: 0 4px 10px -3px rgba(0, 0, 0, 0.55);
  opacity: 0;
  transform: scale(0.6);
  transition:
    opacity 320ms var(--ease),
    transform 420ms var(--ease);
}

.lp-reveal.is-gaining .lp-reveal__plate img {
  opacity: 0.35;
}

.lp-reveal.is-gaining .lp-reveal__plate i {
  opacity: 1;
  transform: none;
}

/* Places gained or lost, shown once the cooks have changed places. */
.lp-reveal__move {
  display: flex;
  align-items: center;
  gap: 1px;
  font: 700 14px/1 var(--text);
  font-variant-numeric: tabular-nums;
  opacity: 0;
  transition: opacity 400ms var(--ease);
}

.lp-reveal__move i {
  font-style: normal;
}

.lp-reveal__move svg {
  flex: none;
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.lp-reveal__row.is-up .lp-reveal__move {
  opacity: 1;
  color: var(--good);
}

.lp-reveal__row.is-down .lp-reveal__move {
  opacity: 1;
  color: var(--ink-2);
}

.lp-reveal__row.is-down .lp-reveal__move svg {
  transform: rotate(180deg);
}

.lp-reveal__points {
  min-width: 2.6ch;
  font: 800 1rem/1 var(--display);
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.lp-vote__panel > .lp-btn--go {
  margin-top: calc(22 * var(--u));
  min-height: 48px;
  font-size: 1rem;
}

.lp-vote__panel > .lp-btn--go[hidden] {
  display: none;
}

/* ── sections below the first screen ── */

.lp-band {
  max-width: 1600px;
  margin: 0 auto;
  padding: clamp(72px, 10vw, 160px) var(--edge);
}

h2 {
  max-width: 18ch;
  margin-bottom: 0.75em;
  font: 800 clamp(1.75rem, 3.3vw, 2.75rem)/1.06 var(--display);
  letter-spacing: -0.025em;
  color: var(--ink);
  text-wrap: balance;
}

h3 {
  margin: 1.4rem 0 0.4rem;
  font: 700 1.4rem/1.2 var(--display);
  letter-spacing: -0.01em;
  color: var(--ink);
}

.lp-band p {
  max-width: 58ch;
}

.lp-band p + p {
  margin-top: 1em;
}

/* A phone, holding a real screen from the app. */
.lp-phone {
  position: relative;
  flex: none;
  width: min(272px, 74vw);
  padding: 9px;
  border-radius: 42px;
  background: #0c0919;
  box-shadow:
    0 0 0 1.5px var(--line),
    0 34px 60px -24px rgba(0, 0, 0, 0.75);
}

.lp-phone--lead {
  width: min(318px, 78vw);
}

.lp-phone__screen {
  aspect-ratio: 600 / 1298;
  border-radius: 34px;
  overflow: hidden;
  background: var(--sky);
}

.lp-phone__screen img,
.lp-phone__screen video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Scoring, beside the climb. */
.lp-climb {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(32px, 5vw, 80px);
}

.lp-climb__rule p:first-child {
  margin-bottom: 0.9rem;
  color: var(--ink);
}

.lp-climb__rule p:last-child {
  font-size: 0.875rem;
}

@media (min-width: 900px) and (max-width: 1239px) {
  .lp-climb {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .lp-climb .lp-phone {
    grid-row: 1 / span 2;
  }

  .lp-climb__text {
    align-self: end;
  }

  .lp-climb__rule {
    align-self: start;
  }
}

.lp-rule {
  max-width: 34rem;
  margin: 0 0 1.2rem;
  border-bottom: 1px solid var(--hairline);
}

.lp-rule div {
  display: grid;
  grid-template-columns: 7.2rem minmax(0, 1fr);
  align-items: baseline;
  gap: 1rem;
  padding: 0.8rem 0;
  border-top: 1px solid var(--hairline);
}

.lp-rule dt {
  font: 800 1.55rem/1 var(--display);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.01em;
  color: var(--butter);
}

.lp-rule dd {
  color: var(--ink);
}

/* The same colours as the points that land in the scene. */
.lp-rule .is-good dt {
  color: var(--good);
}

.lp-rule .is-bonus dt {
  color: var(--butter);
}

.lp-rule .is-accent dt {
  color: var(--tomato);
}

/* The week, in three screens. */
.lp-week h2 {
  max-width: 16ch;
}

.lp-week__steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(20px, 4vw, 56px);
  margin-top: clamp(32px, 5vw, 56px);
}

.lp-week__steps li {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.lp-week .lp-phone {
  aspect-ratio: 5 / 6;
  padding-bottom: 0;
  border-radius: 42px 42px 0 0;
  overflow: hidden;
  box-shadow: 0 0 0 1.5px var(--line);
  -webkit-mask-image: linear-gradient(#19142f 80%, transparent);
  mask-image: linear-gradient(#19142f 80%, transparent);
}

.lp-week .lp-phone__screen {
  border-radius: 34px 34px 0 0;
}

.lp-week__steps li:nth-child(2) {
  margin-top: clamp(32px, 6vw, 80px);
}

.lp-week__steps p {
  max-width: 30ch;
}

/* The pack ranks as four steps, each rank's emblem on its own. */
.lp-ladder {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  align-items: end;
  gap: clamp(32px, 6vw, 88px);
}

.lp-steps {
  display: flex;
  align-items: flex-end;
  gap: clamp(8px, 1.4vw, 16px);
}

.lp-step {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 0;
}

/* Each pack rank's emblem, as the app draws it (src/app/ui/RankEmblem.tsx), stands on its step. */
.lp-step img {
  display: block;
  width: 92%;
  height: auto;
  margin-bottom: 6%;
}

.lp-step span {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  width: 100%;
  height: var(--rise);
  padding-bottom: 0.9rem;
  border-radius: 26px 26px 6px 6px;
  background: var(--metal);
  color: var(--on-butter);
  font: 800 clamp(1rem, 1.8vw, 1.35rem)/1 var(--display);
  letter-spacing: -0.01em;
}

.lp-step--bronze { --metal: var(--bronze); --rise: clamp(52px, 6vw, 76px); }
.lp-step--silver { --metal: var(--silver); --rise: clamp(88px, 10.5vw, 136px); }
.lp-step--gold { --metal: var(--butter); --rise: clamp(124px, 15vw, 196px); }
.lp-step--diamond { --metal: var(--diamond); --rise: clamp(160px, 19.5vw, 256px); }

/* Groups. */
.lp-groups {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(32px, 6vw, 88px);
}

.lp-groups .lp-phone {
  justify-self: center;
}

/* What it never does: plain statements, no cards. */
.lp-never ul {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: clamp(32px, 6vw, 88px);
  margin-top: clamp(32px, 5vw, 56px);
}

.lp-never li {
  padding: 1.3rem 0 1.4rem;
  border-top: 1px solid var(--hairline);
}

.lp-never strong {
  display: block;
  font: 700 1.35rem/1.2 var(--display);
  letter-spacing: -0.01em;
  color: var(--ink);
}

/* The close. */
.lp-close {
  display: grid;
  grid-template-columns: auto auto;
  justify-content: center;
  align-items: center;
  gap: clamp(32px, 6vw, 96px);
  width: calc(100% - 2 * var(--edge));
  max-width: 1320px;
  margin: clamp(32px, 5vw, 72px) auto clamp(72px, 10vw, 160px);
  padding: clamp(48px, 7vw, 104px) clamp(28px, 5vw, 72px);
  border-radius: 40px;
  background: var(--panel);
  box-shadow: 0 40px 80px -40px rgba(0, 0, 0, 0.7);
}

.lp-close h2 {
  max-width: 14ch;
  color: var(--butter);
}

.lp-close p {
  color: var(--ink);
}

.lp-close .lp-hero__actions {
  gap: 14px;
  margin-top: 1.6rem;
}

/* The moon from the logo, with the host standing in front of it. */
.lp-close__moon {
  position: relative;
  display: grid;
  place-items: center;
  width: clamp(170px, 22vw, 290px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--butter);
}

.lp-close__host {
  display: block;
  width: 66%;
  height: auto;
  /* The figure's weight sits right of its tail, so it is nudged to look centred on the disc. */
  transform: translate(-3%, -4%);
}

/* Footer. */
.lp-foot {
  max-width: 1600px;
  margin: 0 auto;
  padding: 32px var(--edge) 48px;
  border-top: 1px solid var(--hairline);
  font-size: 0.9rem;
}

/* The guides, in the footer of every page. */
.lp-foot__guides {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}

.lp-foot__guides a {
  color: var(--ink-2);
  text-decoration: none;
}

.lp-foot__guides a:hover {
  color: var(--butter);
}

.lp-foot__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px 32px;
}

.lp-foot .lp-brand__name {
  font-size: 1.4rem;
}

.lp-foot nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 24px;
}

.lp-foot nav a {
  padding: 0.7em 0;
  color: var(--ink);
  text-decoration: none;
}

.lp-foot nav a:hover {
  color: var(--butter);
}

.lp-credits {
  margin-top: 20px;
}

.lp-credits summary {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  padding: 0.7em 0;
  color: var(--ink);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 0.2em;
  cursor: pointer;
  list-style: none;
}

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

/* A chevron that turns when the list opens. */
.lp-credits summary::after {
  content: '';
  width: 0.5em;
  height: 0.5em;
  border-right: 2px solid var(--butter);
  border-bottom: 2px solid var(--butter);
  transform: translateY(-0.15em) rotate(45deg);
  transition: transform 200ms var(--ease);
}

.lp-credits[open] summary::after {
  transform: translateY(0.1em) rotate(-135deg);
}

.lp-credits ul {
  columns: 2;
  column-gap: 40px;
  margin: 12px 0;
}

.lp-credits li {
  padding: 0.25em 0;
  break-inside: avoid;
}

.lp-foot__fine {
  margin-top: 20px;
}

/* ── narrower windows: the same parts, restacked ── */

@media (max-width: 899px) {
  :root {
    --u: 1px;
    --edge: 20px;
  }

  .lp-hero::before {
    display: none;
  }

  .lp-nav {
    height: 64px;
    padding: 0 16px;
  }

  .lp-brand {
    width: auto;
  }

  .lp-nav__links {
    display: none;
  }

  .lp-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    column-gap: 10px;
    padding: 12px var(--edge) 0;
  }

  .lp-hero__title,
  .lp-hero__intro,
  .lp-dishes {
    grid-column: 1 / -1;
  }

  .lp-hero__title {
    max-width: none;
    font-size: clamp(1.75rem, 9.4vw, 2.75rem);
    line-height: 1.06;
  }

  .lp-hero__title span {
    display: block;
  }

  .lp-hero__intro {
    max-width: 34rem;
    margin-top: 14px;
    font-size: 1.0625rem;
    line-height: 1.5;
  }

  .lp-hero__actions {
    grid-column: 1;
    flex-direction: column;
    align-self: end;
    gap: 10px;
    max-width: 360px;
    margin-top: 20px;
  }

  .lp-hero__actions .lp-btn {
    width: 100%;
    min-height: 52px;
    padding: 0 20px;
    font-size: 1rem;
  }

  .lp-hero__host {
    position: static;
    grid-column: 2;
    align-self: end;
    width: clamp(96px, 28vw, 150px);
    margin-bottom: -4px;
  }

  .lp-dishes {
    margin: 40px calc(-1 * var(--edge)) 0;
    padding: 0 12px;
  }

  .lp-dishes__track {
    gap: 6px;
  }

  .lp-dish {
    width: 150px;
    height: 124px;
    border-radius: 14px;
  }

  .lp-dish b {
    left: 6px;
    top: 6px;
    min-width: 44px;
    height: 28px;
    font-size: 14px;
  }

  .lp-dish i {
    left: 6px;
    bottom: 6px;
  }

  .lp-vote {
    padding: 44px 0 40px;
  }

  .lp-vote__panel {
    width: auto;
    margin: 0 12px;
    padding: 28px 14px 30px;
    border-radius: 26px;
  }

  .lp-vote__q {
    font-size: clamp(1.4rem, 6.6vw, 1.75rem);
    text-wrap: balance;
  }

  .lp-vote__pair {
    gap: 10px;
    margin-top: 16px;
  }

  .lp-ballot {
    flex: 1;
    width: auto;
    min-width: 0;
    padding: 5px 5px 8px;
    border-radius: 18px;
  }

  .lp-ballot img {
    aspect-ratio: 4 / 3;
    border-radius: 14px;
  }

  .lp-ballot__letter {
    left: 9px;
    top: 9px;
    width: 32px;
    height: 32px;
    font-size: 17px;
  }

  .lp-ballot .lp-btn {
    width: 100%;
    min-height: 48px;
    margin-top: 8px;
    font-size: 1rem;
  }

  .lp-climb,
  .lp-ladder,
  .lp-groups {
    grid-template-columns: minmax(0, 1fr);
    justify-items: center;
  }

  .lp-climb__text,
  .lp-climb__rule,
  .lp-ladder__text,
  .lp-groups__text {
    justify-self: stretch;
  }

  .lp-climb__rule {
    order: 3;
  }

  .lp-groups .lp-phone,
  .lp-climb .lp-phone {
    order: 2;
  }

  .lp-steps {
    width: 100%;
    max-width: 440px;
  }

  /* Three screens become one row to swipe through. */
  .lp-week__steps {
    display: flex;
    gap: 20px;
    margin: 28px calc(-1 * var(--edge)) 0;
    padding: 0 var(--edge) 12px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-left: var(--edge);
    scrollbar-width: none;
  }

  .lp-week__steps::-webkit-scrollbar {
    display: none;
  }

  .lp-week__steps li {
    flex: 0 0 min(272px, 74vw);
    scroll-snap-align: start;
  }

  .lp-week__steps li:nth-child(2) {
    margin-top: 0;
  }

  .lp-never ul {
    grid-template-columns: minmax(0, 1fr);
  }

  .lp-close {
    grid-template-columns: minmax(0, 1fr);
    justify-content: stretch;
    width: auto;
    margin-left: 12px;
    margin-right: 12px;
    padding: 44px 28px;
  }

  .lp-close__moon {
    width: 168px;
  }

  .lp-close .lp-btn {
    width: 100%;
  }

  .lp-credits ul {
    columns: 1;
  }
}

@media (min-width: 600px) and (max-width: 899px) {
  :root {
    --edge: 32px;
  }

  .lp-nav {
    padding: 0 var(--edge);
  }

  .lp-hero__title,
  .lp-hero__intro {
    grid-column: 1;
  }

  .lp-hero__host {
    grid-row: 1 / span 3;
    width: clamp(160px, 27vw, 230px);
  }

  .lp-hero__actions {
    flex-direction: row;
    max-width: none;
  }

  .lp-hero__actions .lp-btn {
    width: auto;
    padding: 0 28px;
  }

  .lp-vote__panel {
    margin: 0 var(--edge);
  }

  .lp-ballot img {
    aspect-ratio: 16 / 10;
  }

  .lp-close {
    grid-template-columns: auto minmax(0, 1fr);
    margin-left: var(--edge);
    margin-right: var(--edge);
    padding: 56px 40px;
  }

  .lp-close .lp-btn {
    width: auto;
  }
}

/* On a phone the top bar holds the name and the language switch; the hero's own button, on the first
   screen, starts cooking. Without the switch (no script), the bar keeps its button. */
@media (max-width: 599px) {
  .lp-nav .lp-lang:not([hidden]) + .lp-btn {
    display: none;
  }

  /* Four steps share a phone's width: "Diamante" must fit on the narrowest, inside its own inset. */
  .lp-step span {
    padding-inline: 8px;
    font-size: clamp(0.75rem, 3.3vw, 1rem);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .lp-sky__stars,
  .lp-dish {
    animation: none;
  }

  .lp-dishes__track {
    transform: none;
  }

  .lp-dish b,
  .lp-ballot.is-picked .lp-ballot__stamp {
    animation: none;
  }

  .lp-btn,
  .lp-ballot,
  .lp-ballot img,
  .lp-vote__dots li,
  .lp-reveal__move,
  .lp-reveal__bar i,
  .lp-reveal__plate img,
  .lp-reveal__plate i {
    transition: none;
  }
}
