/* ==========================================================================
   FinSteps — sunlit shallows
   --------------------------------------------------------------------------
   The page is a tank you descend through. Chunky pixel chrome (notched
   frames, Silkscreen HUD labels, reward gold) layered over the app's real
   ocean ramp, with a warm optical serif carrying the prose so the legal
   pages read like a game manual rather than a EULA.

   Palette is lifted verbatim from Sources/DesignSystem/Colors.swift.
   ========================================================================== */

/* --- tokens ------------------------------------------------------------- */

:root {
  /* Water column, surface to floor. */
  --sky: #b6e9f5;
  --water-1: #82d0e8;
  --water-2: #5eb8d6;
  --water-3: #429fc6;
  --water-deep: #2a7fa8;
  --abyss: #0b3848;

  /* Ink. */
  --ink: #062a38;
  --ink-soft: #2b5a6b;
  --ink-faint: #5b8697;

  /* Accents. */
  --teal: #0fa598;
  --teal-deep: #0a6e66;
  --mint: #4fe0c6;
  --gold: #e9b94f;
  --gold-deep: #b8862a;
  --coral: #f2762e;
  --coral-deep: #c4551a;
  --murk: #55663b;

  /* Surfaces. */
  --pearl: #fbf6ea;
  --pearl-2: #f3ead7;
  --sand: #e4d1a6;
  --sand-lit: #f2e4c4;
  --sand-shade: #c0a56c;

  /* Type. */
  --font-display: "Pixelify Sans", "Courier New", monospace;
  --font-hud: "Silkscreen", "Courier New", monospace;
  --font-body: "Fraunces", Georgia, "Times New Roman", serif;

  /* Rhythm. */
  --gutter: clamp(1.25rem, 5vw, 3rem);
  --measure: 68rem;
  --prose: 44rem;
  --pb: 4px; /* pixel-border unit */

  --radius: 0px; /* the pixel world has no rounded corners */
  --ease-pop: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

/* --- reset -------------------------------------------------------------- */

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 6rem;
}

body {
  margin: 0;
  background: var(--pearl);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.68;
  font-variation-settings: "opsz" 14, "SOFT" 30;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  display: block;
  /* The width/height attributes are kept for layout stability, but they also
     apply as presentational hints — so any rule that sets only `width` would
     leave the attribute height in place and squash the image. */
  height: auto;
}

a {
  color: var(--teal-deep);
  text-underline-offset: 0.18em;
  text-decoration-thickness: 0.08em;
}

a:hover {
  color: var(--coral-deep);
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.01em;
  margin: 0;
  text-wrap: balance;
}

p {
  text-wrap: pretty;
}

::selection {
  background: var(--mint);
  color: var(--abyss);
}

:focus-visible {
  outline: 3px solid var(--coral);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 999;
  background: var(--abyss);
  color: var(--pearl);
  font-family: var(--font-hud);
  padding: 0.9rem 1.4rem;
}

.skip-link:focus {
  left: 0;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* --- pixel primitives --------------------------------------------------- */

/* A notched-corner border, drawn with four offset shadows the way a sprite
   editor would draw it — no border-radius anywhere in this world. */
.pixel-frame {
  position: relative;
  box-shadow:
    0 calc(-1 * var(--pb)) 0 0 var(--edge, var(--abyss)),
    0 var(--pb) 0 0 var(--edge, var(--abyss)),
    calc(-1 * var(--pb)) 0 0 0 var(--edge, var(--abyss)),
    var(--pb) 0 0 0 var(--edge, var(--abyss));
}

.pixel-frame--lift {
  box-shadow:
    0 calc(-1 * var(--pb)) 0 0 var(--edge, var(--abyss)),
    0 var(--pb) 0 0 var(--edge, var(--abyss)),
    calc(-1 * var(--pb)) 0 0 0 var(--edge, var(--abyss)),
    var(--pb) 0 0 0 var(--edge, var(--abyss)),
    var(--pb) calc(var(--pb) * 2) 0 0 var(--shade, rgba(6, 42, 56, 0.18));
}

.hud {
  font-family: var(--font-hud);
  font-size: 0.6875rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  line-height: 1;
}

/* --- layout ------------------------------------------------------------- */

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

.section {
  padding-block: clamp(4.5rem, 10vw, 8rem);
  position: relative;
}

.section__head {
  max-width: 46rem;
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
}

.section__eyebrow {
  color: var(--teal-deep);
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 1.1rem;
}

.section__eyebrow::before {
  content: "";
  width: 10px;
  height: 10px;
  background: var(--coral);
  box-shadow: 14px 0 0 var(--gold);
  margin-right: 14px;
}

.section__title {
  font-size: clamp(2.1rem, 5.6vw, 3.5rem);
}

.section__lede {
  font-size: clamp(1.075rem, 1.9vw, 1.3rem);
  color: var(--ink-soft);
  margin: 1.25rem 0 0;
  max-width: 40rem;
}

/* ==========================================================================
   Navigation
   ========================================================================== */

.nav {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(251, 246, 234, 0.86);
  backdrop-filter: blur(10px) saturate(1.4);
  -webkit-backdrop-filter: blur(10px) saturate(1.4);
  border-bottom: var(--pb) solid var(--abyss);
}

.nav__inner {
  width: min(100% - var(--gutter) * 2, var(--measure));
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  min-height: 4.25rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.35rem;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.02em;
  margin-right: auto;
}

.brand:hover {
  color: var(--ink);
}

.brand__mark {
  width: 34px;
  height: 34px;
  image-rendering: pixelated;
  box-shadow: 0 0 0 3px var(--abyss);
}

.brand:hover .brand__mark {
  animation: bob 0.5s var(--ease-pop) 2;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 1.6rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav__links a {
  font-family: var(--font-hud);
  font-size: 0.72rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--ink-soft);
  text-decoration: none;
  padding-block: 0.4rem;
  border-bottom: 3px solid transparent;
  transition: color 0.18s, border-color 0.18s;
}

.nav__links a:hover {
  color: var(--ink);
  border-bottom-color: var(--coral);
}

@media (max-width: 60rem) {
  .nav__links {
    display: none;
  }
}

/* --- buttons ------------------------------------------------------------ */

.btn {
  --edge: var(--abyss);
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  font-family: var(--font-hud);
  font-size: 0.8rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.95rem 1.5rem;
  border: 0;
  cursor: pointer;
  background: var(--teal);
  color: var(--pearl);
  box-shadow:
    0 calc(-1 * var(--pb)) 0 0 var(--edge),
    0 var(--pb) 0 0 var(--edge),
    calc(-1 * var(--pb)) 0 0 0 var(--edge),
    var(--pb) 0 0 0 var(--edge),
    var(--pb) calc(var(--pb) * 2) 0 0 var(--teal-deep);
  transition: transform 0.12s var(--ease-out), box-shadow 0.12s var(--ease-out);
}

.btn:hover {
  color: var(--pearl);
  transform: translateY(-2px);
  box-shadow:
    0 calc(-1 * var(--pb)) 0 0 var(--edge),
    0 var(--pb) 0 0 var(--edge),
    calc(-1 * var(--pb)) 0 0 0 var(--edge),
    var(--pb) 0 0 0 var(--edge),
    var(--pb) calc(var(--pb) * 3) 0 0 var(--teal-deep);
}

.btn:active {
  transform: translateY(2px);
  box-shadow:
    0 calc(-1 * var(--pb)) 0 0 var(--edge),
    0 var(--pb) 0 0 var(--edge),
    calc(-1 * var(--pb)) 0 0 0 var(--edge),
    var(--pb) 0 0 0 var(--edge);
}

.btn--ghost {
  background: var(--pearl);
  color: var(--ink);
  box-shadow:
    0 calc(-1 * var(--pb)) 0 0 var(--edge),
    0 var(--pb) 0 0 var(--edge),
    calc(-1 * var(--pb)) 0 0 0 var(--edge),
    var(--pb) 0 0 0 var(--edge),
    var(--pb) calc(var(--pb) * 2) 0 0 rgba(6, 42, 56, 0.25);
}

.btn--ghost:hover {
  color: var(--ink);
  background: var(--sand-lit);
}

.btn--gold {
  background: var(--gold);
  color: var(--abyss);
  box-shadow:
    0 calc(-1 * var(--pb)) 0 0 var(--edge),
    0 var(--pb) 0 0 var(--edge),
    calc(-1 * var(--pb)) 0 0 0 var(--edge),
    var(--pb) 0 0 0 var(--edge),
    var(--pb) calc(var(--pb) * 2) 0 0 var(--gold-deep);
}

.btn--gold:hover {
  color: var(--abyss);
}

.btn--sm {
  padding: 0.7rem 1.05rem;
  font-size: 0.7rem;
}

/* ==========================================================================
   Hero — the tank
   ========================================================================== */

.tank {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  /* Sand geometry, shared with .tank__floor and the bottom-dwelling lane so
     the two can't drift apart. The floor is a dune: it hangs --sand-drop
     below the tank and stands --sand-h tall, so its highest point sits
     --sand-line above the tank's bottom edge. Anything that should swim
     rather than burrow has to clear that line at every viewport width — which
     a percentage `top` cannot do, because --sand-h is a clamp(). */
  --sand-h: clamp(9rem, 17vw, 14rem);
  --sand-drop: 3rem;
  --sand-line: calc(var(--sand-h) - var(--sand-drop));
  background:
    linear-gradient(
      180deg,
      var(--sky) 0%,
      var(--water-1) 26%,
      var(--water-2) 58%,
      var(--water-3) 82%,
      var(--water-deep) 100%
    );
  border-bottom: var(--pb) solid var(--abyss);
  padding-block: clamp(3.5rem, 9vw, 6.5rem) clamp(9rem, 18vw, 14rem);
}

/* Sunlight shafts breaking through the surface. */
.tank__rays {
  position: absolute;
  inset: -10% -20% auto -20%;
  height: 120%;
  pointer-events: none;
  z-index: 1;
  background:
    linear-gradient(103deg, transparent 46%, rgba(255, 255, 255, 0.5) 48%, transparent 51%),
    linear-gradient(96deg, transparent 22%, rgba(255, 255, 255, 0.34) 25%, transparent 29%),
    linear-gradient(110deg, transparent 66%, rgba(255, 255, 255, 0.4) 69%, transparent 73%),
    linear-gradient(99deg, transparent 82%, rgba(255, 255, 255, 0.26) 84%, transparent 87%);
  mask-image: linear-gradient(180deg, #000 0%, rgba(0, 0, 0, 0.35) 55%, transparent 88%);
  animation: rays 14s ease-in-out infinite alternate;
}

/* Caustic dapple on the surface film. Two prime-ish tile sizes drifting at
   different speeds, heavily blurred — a single tiled gradient reads as a
   visible grid of boxes, which is the one thing water never looks like. */
.tank__caustics {
  position: absolute;
  inset: 0 0 auto 0;
  height: 40%;
  z-index: 1;
  pointer-events: none;
  opacity: 0.42;
  filter: blur(9px);
  background-image:
    radial-gradient(ellipse 90px 16px at 50% 50%, rgba(255, 255, 255, 0.5), transparent 72%),
    radial-gradient(ellipse 130px 22px at 30% 60%, rgba(255, 255, 255, 0.35), transparent 76%);
  background-size: 237px 74px, 389px 118px;
  mask-image: linear-gradient(180deg, #000 0%, rgba(0, 0, 0, 0.4) 45%, transparent 100%);
  animation: caustics 17s linear infinite;
}

.tank__floor {
  position: absolute;
  left: -6%;
  right: -6%;
  bottom: calc(var(--sand-drop) * -1);
  height: var(--sand-h);
  z-index: 2;
  border-radius: 50% 50% 0 0 / 100% 100% 0 0;
  background: linear-gradient(180deg, var(--sand-lit) 0%, var(--sand) 42%, var(--sand-shade) 100%);
  box-shadow: inset 0 6px 0 rgba(255, 255, 255, 0.45);
}

.tank__decor {
  position: absolute;
  inset: auto 0 0 0;
  height: clamp(9rem, 17vw, 14rem);
  z-index: 3;
  pointer-events: none;
}

/* Decorations rest ON the sand mound, not on the section's bottom edge —
   otherwise the pixel border slices their bases off. */
.tank__decor img {
  position: absolute;
  bottom: 2.25rem;
  image-rendering: pixelated;
  filter: drop-shadow(0 4px 0 rgba(6, 42, 56, 0.12));
}

.decor--castle {
  left: 6%;
  width: clamp(88px, 12vw, 150px);
}

.decor--plant {
  left: 24%;
  width: clamp(42px, 5.5vw, 70px);
  transform-origin: bottom center;
  animation: sway 6s ease-in-out infinite alternate;
}

.decor--coral {
  right: 12%;
  width: clamp(66px, 9vw, 120px);
}

.decor--chest {
  right: 30%;
  width: clamp(58px, 7.5vw, 100px);
}

@media (max-width: 48rem) {
  .decor--chest,
  .decor--plant {
    display: none;
  }
}

/* --- bubbles ------------------------------------------------------------ */

.bubbles {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  overflow: hidden;
}

.bubble {
  position: absolute;
  bottom: -60px;
  width: var(--s, 10px);
  height: var(--s, 10px);
  border-radius: 50%;
  background: radial-gradient(
    circle at 32% 30%,
    rgba(255, 255, 255, 0.95),
    rgba(255, 255, 255, 0.28) 55%,
    rgba(255, 255, 255, 0.08) 70%
  );
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.5);
  animation: rise var(--dur, 12s) linear var(--delay, 0s) infinite;
  opacity: 0;
}

/* --- swimming sprites --------------------------------------------------- */

.school {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
}

/* Fish cross the headline constantly, and at full strength a clownfish
   passing through "keep them alive" turns the promise into noise. Rather
   than laying a lightened panel behind the copy — which can only ever end
   in a visible edge where the gradient meets its own box — the hero school
   simply swims deeper: dimmed toward the water it sits in. No mask, no
   boundary, and it reads as distance. The roster and 404 sprites, which
   never sit under text, stay fully saturated. */
.tank .school {
  opacity: 0.5;
}

/* One lane per fish: the lane travels across the tank, the sprite inside it
   plays its 4-frame cycle and bobs. Splitting the two means a fish can swim
   slowly while its fins beat fast. */
.lane {
  position: absolute;
  top: var(--top, 30%);
  left: 0;
  animation: cross var(--speed, 26s) linear var(--delay, 0s) infinite;
  will-change: transform;
}

.lane--rtl {
  animation-name: cross-back;
}

.sprite {
  width: var(--cell);
  height: var(--h);
  background-repeat: no-repeat;
  background-size: calc(var(--cell) * 4) var(--h);
  image-rendering: pixelated;
  animation: frames var(--fps, 0.62s) steps(4) infinite, bob 3.4s ease-in-out infinite alternate;
  filter: drop-shadow(0 3px 0 rgba(6, 42, 56, 0.1));
  transform-origin: center;
}

.lane--rtl .sprite {
  transform: scaleX(-1);
}

.sprite--sm {
  zoom: 0.72;
}

/* Per-actor sheet geometry. Cell widths come straight out of
   scripts/build-assets.py, which pads every frame of an animation into an
   identical cell — rerun it and these are the numbers it prints. Kept as
   classes rather than inline styles so the site can ship a strict CSP with
   no 'unsafe-inline' in style-src. */

.sp-guppy {
  --cell: 112px;
  --h: 80px;
  --fps: 0.55s;
  background-image: url("/assets/img/guppy_swim.png");
}

.sp-clownfish {
  --cell: 130px;
  --h: 96px;
  --fps: 0.6s;
  background-image: url("/assets/img/clownfish_swim.png");
}

.sp-blue-tang {
  --cell: 140px;
  --h: 96px;
  --fps: 0.55s;
  background-image: url("/assets/img/blue_tang_swim.png");
}

.sp-jellyfish {
  --cell: 97px;
  --h: 112px;
  --fps: 0.9s;
  background-image: url("/assets/img/jellyfish_swim.png");
}

.sp-seahorse {
  --cell: 66px;
  --h: 104px;
  --fps: 0.7s;
  background-image: url("/assets/img/seahorse_swim.png");
}

.sp-octopus {
  --cell: 97px;
  --h: 104px;
  --fps: 0.8s;
  background-image: url("/assets/img/octopus_swim.png");
}

.sp-pufferfish {
  --cell: 107px;
  --h: 96px;
  --fps: 0.65s;
  background-image: url("/assets/img/pufferfish_swim.png");
}

.sp-betta {
  --cell: 96px;
  --h: 96px;
  --fps: 0.5s;
  background-image: url("/assets/img/betta_swim.png");
}

.sp-sea-turtle {
  --cell: 165px;
  --h: 112px;
  --fps: 1.1s;
  background-image: url("/assets/img/sea_turtle_swim.png");
}

.sp-koi {
  --cell: 104px;
  --h: 104px;
  --fps: 0.7s;
  background-image: url("/assets/img/koi_swim.png");
}

.sp-manta-ray {
  --cell: 112px;
  --h: 112px;
  --fps: 1s;
  background-image: url("/assets/img/manta_ray_swim.png");
}

.sp-arowana {
  --cell: 104px;
  --h: 104px;
  --fps: 0.6s;
  background-image: url("/assets/img/golden_arowana_swim.png");
}

.sp-mascot-walk {
  --cell: 173px;
  --h: 160px;
  --fps: 0.4s;
  background-image: url("/assets/img/mascot_walk.png");
}

.sp-mascot-celebrate {
  --cell: 191px;
  --h: 200px;
  --fps: 0.35s;
  background-image: url("/assets/img/mascot_celebrate.png");
}

.sp-mascot-heart {
  --cell: 124px;
  --h: 160px;
  --fps: 0.5s;
  background-image: url("/assets/img/mascot_heart.png");
}

.sp-mascot-wave {
  --cell: 196px;
  --h: 200px;
  --fps: 0.42s;
  background-image: url("/assets/img/mascot_wave.png");
}

/* Hero swim lanes — depth, pace, and where each fish parks under
   prefers-reduced-motion. Offset delays stop the school from marching in
   formation. */

.lane-1 {
  --top: 14%;
  --speed: 34s;
  --delay: -6s;
  --rest: 18vw;
}

.lane-2 {
  --top: 30%;
  --speed: 44s;
  --delay: -22s;
  --rest: 62vw;
}

.lane-3 {
  --top: 52%;
  --speed: 52s;
  --delay: -14s;
  --rest: 34vw;
}

.lane-4 {
  --top: 68%;
  --speed: 38s;
  --delay: -30s;
  --rest: 72vw;
}

/* The sea turtle: the tank's bottom-dweller, and the only sprite big enough to
   sink into the sand. Anchored from the BOTTOM against --sand-line rather than
   given a percentage `top` — at 78% its 112px body sat 98px below the dune,
   so it read as swimming through sand. `top: auto` is required to let `bottom`
   win over .lane's `top: var(--top)`. */
.lane-5 {
  top: auto;
  bottom: calc(var(--sand-line) + 0.75rem);
  --speed: 60s;
  --delay: -40s;
  --rest: 8vw;
}

.lane-6 {
  --top: 16%;
  --speed: 26s;
  --delay: -4s;
  --rest: 22vw;
}

.lane-7 {
  --top: 76%;
  --speed: 32s;
  --delay: -16s;
  --rest: 60vw;
}

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

.hero {
  position: relative;
  z-index: 10;
  width: min(100% - var(--gutter) * 2, var(--measure));
  margin-inline: auto;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}

@media (max-width: 60rem) {
  .hero {
    grid-template-columns: 1fr;
  }
}

.hero__copy {
  position: relative;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: var(--pearl);
  color: var(--teal-deep);
  padding: 0.6rem 0.95rem;
  --edge: var(--abyss);
  --pb: 3px;
  margin-bottom: 1.6rem;
}

.hero__badge b {
  color: var(--coral-deep);
}

.hero__badge::before {
  content: "";
  width: 8px;
  height: 8px;
  background: var(--coral);
  animation: blink 1.6s steps(1) infinite;
}

/* Sized to genuinely fit the copy column at its widest — the previous cap
   only looked right because `nowrap` let it spill into the grid gap. */
.hero__title {
  font-size: clamp(2.35rem, 5.4vw, 4.15rem);
  color: var(--ink);
  line-height: 1.06;
  text-wrap: normal;
  text-shadow: 0 3px 0 rgba(255, 255, 255, 0.45);
}

/* The break after "Your steps" is deliberate, not whatever the measure
   happens to produce — the two halves are a setup and a payoff. */
.hero__title-lead {
  display: block;
}

/* Chunky pixel underline — a health bar under the promise. Painted as a
   two-stop background (bar + its shade) rather than an absolute ::after, so
   it clones onto every line: on a narrow phone "keep them alive." wraps, and
   a nowrap + absolutely-positioned rule would push the page sideways. */
.hero__title em {
  font-style: normal;
  color: var(--coral-deep);
  padding-bottom: 0.18em;
  background-image: linear-gradient(
    var(--gold) 0 8px,
    var(--gold-deep) 8px 12px
  );
  background-repeat: no-repeat;
  background-size: 100% 12px;
  background-position: 0 100%;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

.hero__lede {
  font-size: clamp(1.1rem, 2.1vw, 1.375rem);
  color: var(--ink);
  max-width: 32rem;
  margin: 1.9rem 0 0;
  font-variation-settings: "opsz" 24, "SOFT" 40;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-top: 2.2rem;
}

.hero__note {
  margin: 1.3rem 0 0;
  color: var(--teal-deep);
  font-size: 0.95rem;
}

/* --- the HUD card — a live progress ring -------------------------------- */

.hud-card {
  --edge: var(--abyss);
  background: var(--pearl);
  padding: 1.6rem 1.6rem 1.4rem;
  display: grid;
  gap: 1.2rem;
  justify-items: center;
  max-width: 22rem;
  margin-inline: auto;
  width: 100%;
}

.hud-card__label {
  color: var(--ink-faint);
}

.ring {
  position: relative;
  width: 172px;
  height: 172px;
}

.ring svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.ring__track {
  fill: none;
  stroke: var(--pearl-2);
  stroke-width: 14;
}

.ring__fill {
  fill: none;
  stroke: var(--teal);
  stroke-width: 14;
  stroke-linecap: butt;
  stroke-dasharray: var(--circ);
  stroke-dashoffset: var(--circ);
  transition: stroke-dashoffset 1.6s var(--ease-out), stroke 0.4s;
}

.ring.is-complete .ring__fill {
  stroke: var(--gold);
}

.ring__readout {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  text-align: center;
  gap: 0.2rem;
}

.ring__value {
  font-family: var(--font-display);
  font-size: 2.1rem;
  font-weight: 700;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.ring__goal {
  color: var(--ink-faint);
}

.hud-card__reward {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--gold);
  color: var(--abyss);
  padding: 0.55rem 0.9rem;
  --pb: 3px;
  --edge: var(--abyss);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.4s 1.2s, transform 0.4s 1.2s var(--ease-pop);
}

.ring.is-complete + .hud-card__reward,
.hud-card__reward.is-shown {
  opacity: 1;
  transform: none;
}

/* ==========================================================================
   Ticker
   ========================================================================== */

.ticker {
  background: var(--abyss);
  color: var(--sand-lit);
  border-bottom: var(--pb) solid var(--abyss);
  overflow: hidden;
  padding-block: 0.85rem;
  display: flex;
  user-select: none;
}

.ticker__track {
  display: flex;
  gap: 2.5rem;
  padding-right: 2.5rem;
  flex: none;
  min-width: 100%;
  animation: marquee 38s linear infinite;
}

.ticker span {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  white-space: nowrap;
}

.ticker span::after {
  content: "";
  width: 7px;
  height: 7px;
  background: var(--mint);
}

.ticker b {
  color: var(--gold);
  font-weight: 400;
}

/* ==========================================================================
   How it works
   ========================================================================== */

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: clamp(1.5rem, 3vw, 2.5rem);
}

.step {
  --edge: var(--abyss);
  background: var(--pearl);
  padding: 1.9rem 1.7rem 1.7rem;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.step:nth-child(2) {
  background: var(--sand-lit);
}

.step:nth-child(3) {
  background: var(--pearl-2);
}

.step__n {
  position: absolute;
  top: -18px;
  left: 1.6rem;
  width: 40px;
  height: 40px;
  display: grid;
  place-content: center;
  background: var(--coral);
  color: var(--pearl);
  font-family: var(--font-hud);
  font-size: 1rem;
  --pb: 3px;
  --edge: var(--abyss);
}

.step__art {
  height: 108px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  margin-block: 0.6rem 0.4rem;
}

.step h3 {
  font-size: 1.4rem;
}

.step p {
  margin: 0;
  color: var(--ink-soft);
}

/* ==========================================================================
   Stakes — the split panel
   ========================================================================== */

.stakes {
  background: linear-gradient(180deg, var(--water-1), var(--water-3));
  border-block: var(--pb) solid var(--abyss);
  color: var(--ink);
  position: relative;
  overflow: hidden;
}

.stakes .section__lede {
  color: var(--ink);
}

.stakes .section__eyebrow {
  color: var(--abyss);
}

.split {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  gap: clamp(1.5rem, 3vw, 2.25rem);
}

.panel {
  --edge: var(--abyss);
  padding: 1.75rem;
  background: var(--pearl);
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.panel--met {
  background: var(--pearl);
}

.panel--missed {
  background: #d9dcc3;
}

.panel__tag {
  display: inline-flex;
  align-self: flex-start;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.75rem;
  --pb: 3px;
  --edge: var(--abyss);
}

.panel--met .panel__tag {
  background: var(--mint);
  color: var(--abyss);
}

.panel--missed .panel__tag {
  background: var(--murk);
  color: var(--sand-lit);
}

.panel h3 {
  font-size: 1.55rem;
}

.panel ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.7rem;
}

.panel li {
  display: grid;
  grid-template-columns: 1.35rem 1fr;
  gap: 0.7rem;
  align-items: baseline;
  color: var(--ink-soft);
}

.panel li::before {
  content: "▸";
  color: var(--teal);
  font-family: var(--font-hud);
}

.panel--missed li::before {
  content: "▾";
  color: var(--murk);
}

/* The recoverable-tank note, set apart as a reassurance. */
.reassure {
  --edge: var(--abyss);
  margin-top: clamp(1.5rem, 3vw, 2.25rem);
  background: var(--gold);
  color: var(--abyss);
  padding: 1.3rem 1.6rem;
  display: flex;
  align-items: center;
  gap: 1.2rem;
  flex-wrap: wrap;
}

/* The guppy here is a still, cropped to frame 1 of its sheet rather than
   animated — a fish holding steady is the whole point of the sentence. */
.reassure__guppy {
  flex: none;
  width: 112px;
  height: 80px;
  background-image: url("/assets/img/guppy_swim.png");
  background-size: 448px 80px;
  background-position: 0 0;
  image-rendering: pixelated;
}

.reassure p {
  margin: 0;
  font-size: 1.075rem;
  flex: 1 1 18rem;
}

/* ==========================================================================
   Fish roster
   ========================================================================== */

.roster {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(13.5rem, 1fr));
  gap: 1.25rem;
}

.fish {
  --edge: var(--abyss);
  background: linear-gradient(180deg, var(--water-1), var(--water-2));
  padding: 1.1rem 1.1rem 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  overflow: hidden;
  position: relative;
  transition: transform 0.18s var(--ease-out);
}

.fish:hover {
  transform: translateY(-4px);
}

.fish__stage {
  height: 92px;
  display: grid;
  place-items: center;
  margin-bottom: 0.35rem;
}

.fish__stage .sprite {
  animation-play-state: paused;
}

.fish:hover .fish__stage .sprite,
.fish:focus-within .fish__stage .sprite {
  animation-play-state: running;
}

.fish h3 {
  font-size: 1.15rem;
  color: var(--abyss);
}

.fish__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: auto;
  padding-top: 0.5rem;
}

.chip {
  font-family: var(--font-hud);
  font-size: 0.6rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  padding: 0.35rem 0.5rem;
  background: var(--pearl);
  color: var(--ink);
  --pb: 2px;
  --edge: var(--abyss);
}

.chip--gold {
  background: var(--gold);
}

.chip--hearts {
  background: var(--coral);
  color: var(--pearl);
}

.fish--exclusive {
  background: linear-gradient(180deg, #2f6f8c, var(--abyss));
}

.fish--exclusive h3 {
  color: var(--sand-lit);
}

/* ==========================================================================
   Milestones table
   ========================================================================== */

.table-wrap {
  overflow-x: auto;
  --edge: var(--abyss);
  background: var(--pearl);
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 34rem;
}

caption {
  text-align: left;
  padding: 1.1rem 1.25rem;
  color: var(--ink-faint);
  font-family: var(--font-hud);
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border-bottom: 3px solid var(--abyss);
}

th,
td {
  text-align: left;
  padding: 0.85rem 1.25rem;
  border-bottom: 2px solid rgba(6, 42, 56, 0.12);
}

thead th {
  font-family: var(--font-hud);
  font-size: 0.66rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--ink-faint);
  font-weight: 400;
}

tbody th {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
}

tbody tr:nth-child(even) {
  background: rgba(228, 209, 166, 0.28);
}

tbody tr:last-child th,
tbody tr:last-child td {
  border-bottom: 0;
}

td b {
  color: var(--gold-deep);
  font-weight: 700;
}

/* ==========================================================================
   Pricing
   ========================================================================== */

.plans {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16.5rem, 1fr));
  gap: clamp(1.25rem, 3vw, 2rem);
  align-items: start;
  max-width: 44rem;
}

.plan {
  --edge: var(--abyss);
  background: var(--pearl);
  padding: 1.9rem 1.6rem 1.7rem;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  position: relative;
}

.plan--featured {
  background: var(--sand-lit);
}

.plan__flag {
  position: absolute;
  top: -17px;
  right: 1.3rem;
  background: var(--gold);
  color: var(--abyss);
  padding: 0.45rem 0.7rem;
  --pb: 3px;
  --edge: var(--abyss);
}

.plan__name {
  color: var(--ink-faint);
}

.plan__price {
  display: flex;
  align-items: baseline;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.plan__amount {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.3rem, 6vw, 3rem);
  line-height: 1;
  letter-spacing: -0.02em;
}

.plan__period {
  color: var(--ink-soft);
  font-size: 1.05rem;
}

.plan__lede {
  margin: 0;
  color: var(--ink-soft);
}

.plan ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.55rem;
  font-size: 0.98rem;
}

.plan li {
  display: grid;
  grid-template-columns: 1.1rem 1fr;
  gap: 0.6rem;
  align-items: baseline;
  color: var(--ink-soft);
}

.plan li::before {
  content: "▸";
  color: var(--teal);
  font-family: var(--font-hud);
}

.plan__trial {
  align-self: flex-start;
  background: var(--mint);
  color: var(--abyss);
  padding: 0.45rem 0.7rem;
  --pb: 3px;
  --edge: var(--abyss);
}

.pricing__fineprint {
  margin: clamp(1.75rem, 3vw, 2.5rem) 0 0;
  color: var(--ink-soft);
  font-size: 0.95rem;
  max-width: 44rem;
}

/* ==========================================================================
   Privacy plank
   ========================================================================== */

.plank {
  background: var(--abyss);
  color: var(--sand-lit);
  border-block: var(--pb) solid var(--abyss);
  position: relative;
  overflow: hidden;
}

.plank .section__title {
  color: var(--pearl);
}

.plank .section__eyebrow {
  color: var(--mint);
}

.plank .section__lede {
  color: #a9c7d4;
}

.plank__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
  gap: 1.25rem;
  margin-top: 2.5rem;
}

.plank__item {
  border-top: 3px solid var(--mint);
  padding-top: 1.1rem;
}

.plank__item h3 {
  font-size: 1.15rem;
  color: var(--pearl);
  margin-bottom: 0.5rem;
}

.plank__item p {
  margin: 0;
  color: #a9c7d4;
  font-size: 0.98rem;
}

/* ==========================================================================
   FAQ
   ========================================================================== */

.faq {
  display: grid;
  gap: 0.85rem;
  max-width: 52rem;
}

.faq details {
  --edge: var(--abyss);
  background: var(--pearl);
  padding: 0 1.4rem;
}

.faq summary {
  cursor: pointer;
  list-style: none;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  padding: 1.15rem 2.5rem 1.15rem 0;
  position: relative;
}

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

.faq summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--font-hud);
  color: var(--coral);
  font-size: 1.35rem;
}

.faq details[open] summary::after {
  content: "−";
}

.faq details[open] summary {
  border-bottom: 2px solid rgba(6, 42, 56, 0.12);
}

.faq details > p {
  color: var(--ink-soft);
  padding-block: 1rem 1.35rem;
  margin: 0;
}

.faq details > p + p {
  padding-top: 0;
}

/* ==========================================================================
   Closing CTA
   ========================================================================== */

.closer {
  background: linear-gradient(180deg, var(--water-2), var(--water-deep));
  border-top: var(--pb) solid var(--abyss);
  position: relative;
  overflow: hidden;
  text-align: center;
}

.closer__inner {
  position: relative;
  z-index: 3;
  display: grid;
  justify-items: center;
  gap: 1.4rem;
}

.closer__mascot {
  image-rendering: pixelated;
  animation: bob 2.6s ease-in-out infinite alternate;
}

.closer h2 {
  font-size: clamp(2.1rem, 6vw, 3.6rem);
  color: var(--ink);
  text-shadow: 0 3px 0 rgba(255, 255, 255, 0.35);
}

.closer p {
  color: var(--ink);
  max-width: 34rem;
  margin: 0;
  font-size: 1.1rem;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.footer {
  background: var(--abyss);
  color: #9fbecd;
  padding-block: clamp(3rem, 6vw, 4.5rem) 2.5rem;
  font-size: 0.95rem;
}

.footer__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) repeat(auto-fit, minmax(9rem, 1fr));
  gap: 2.5rem;
  padding-bottom: 2.5rem;
  border-bottom: 2px solid rgba(255, 255, 255, 0.12);
}

.footer .brand {
  color: var(--pearl);
  margin-right: 0;
}

.footer__blurb {
  margin: 1rem 0 0;
  max-width: 22rem;
  color: #8fb2c2;
}

.footer h2 {
  font-family: var(--font-hud);
  font-size: 0.68rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--mint);
  font-weight: 400;
  margin-bottom: 1rem;
}

.footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.6rem;
}

.footer a {
  color: #c9dde6;
  text-decoration: none;
}

.footer a:hover {
  color: var(--mint);
  text-decoration: underline;
}

.footer__base {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 2rem;
  justify-content: space-between;
  padding-top: 2rem;
  color: #7fa4b5;
  font-size: 0.9rem;
}

/* ==========================================================================
   Document pages — privacy, terms, support
   ========================================================================== */

.doc-hero {
  background: linear-gradient(180deg, var(--sky), var(--water-1));
  border-bottom: var(--pb) solid var(--abyss);
  padding-block: clamp(3rem, 7vw, 5rem);
  position: relative;
  overflow: hidden;
}

.doc-hero__inner {
  position: relative;
  z-index: 3;
}

.doc-hero h1 {
  font-size: clamp(2.2rem, 6vw, 3.4rem);
  margin-top: 1rem;
}

.doc-hero .meta {
  margin: 0.9rem 0 0;
  color: var(--teal-deep);
}

.crumb {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--teal-deep);
  text-decoration: none;
}

.crumb::before {
  content: "←";
}

.doc {
  width: min(100% - var(--gutter) * 2, var(--prose));
  margin-inline: auto;
  padding-block: clamp(3rem, 6vw, 4.5rem) clamp(4rem, 8vw, 6rem);
}

.doc h2 {
  font-size: clamp(1.45rem, 3.4vw, 1.95rem);
  margin: 3rem 0 0.9rem;
  padding-top: 1.6rem;
  border-top: 3px solid rgba(6, 42, 56, 0.15);
}

.doc h2:first-of-type {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.doc h3 {
  font-size: 1.2rem;
  margin: 2rem 0 0.6rem;
}

.doc p,
.doc li {
  color: var(--ink-soft);
}

.doc p {
  margin: 0 0 1.1rem;
}

.doc ul,
.doc ol {
  margin: 0 0 1.2rem;
  padding-left: 1.35rem;
}

.doc li {
  margin-bottom: 0.55rem;
}

.doc strong {
  color: var(--ink);
}

.doc .callout {
  --edge: var(--abyss);
  background: var(--sand-lit);
  padding: 1.4rem 1.5rem;
  margin: 0 0 2.75rem;
}

.doc .callout p:last-child {
  margin-bottom: 0;
}

.doc .callout__label {
  color: var(--teal-deep);
  display: block;
  margin-bottom: 0.7rem;
}

.doc .toc {
  --edge: var(--abyss);
  background: var(--pearl-2);
  padding: 1.3rem 1.5rem;
  margin-bottom: 2.75rem;
}

.doc .toc h2 {
  font-family: var(--font-hud);
  font-size: 0.68rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--ink-faint);
  border: 0;
  margin: 0 0 0.85rem;
  padding: 0;
  font-weight: 400;
}

.doc .toc ol {
  columns: 2;
  column-gap: 2rem;
  margin: 0;
  padding-left: 1.2rem;
  font-size: 0.95rem;
}

@media (max-width: 40rem) {
  .doc .toc ol {
    columns: 1;
  }
}

.doc-cta {
  --edge: var(--abyss);
  background: var(--teal);
  color: var(--pearl);
  padding: 1.6rem;
  margin: 2.5rem 0 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.2rem;
  justify-content: space-between;
}

.doc-cta p {
  margin: 0;
  color: var(--pearl);
  flex: 1 1 16rem;
}

/* ==========================================================================
   Narrow screens
   ========================================================================== */

@media (max-width: 48rem) {
  /* auto-fit would still try to seat three 9rem link columns beside the
     blurb on a phone, squeezing "Privacy Policy" to two words per line. */
  .footer__grid {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }

  .footer__grid > :first-child {
    grid-column: 1 / -1;
  }

  .reassure,
  .doc-cta {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 30rem) {
  .nav__inner {
    gap: 0.75rem;
  }

  .brand {
    font-size: 1.15rem;
  }

  .nav .btn {
    padding: 0.6rem 0.8rem;
    font-size: 0.62rem;
  }

  .hero__actions .btn {
    width: 100%;
  }

  .footer__grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   404
   ========================================================================== */

.lost {
  min-height: 100vh;
  display: grid;
  place-content: center;
  justify-items: center;
  text-align: center;
  gap: 1.4rem;
  padding: 3rem var(--gutter);
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: linear-gradient(180deg, var(--sky) 0%, var(--water-2) 55%, var(--water-deep) 100%);
}

.lost > * {
  position: relative;
  z-index: 3;
}

.lost h1 {
  font-size: clamp(4rem, 18vw, 9rem);
  color: var(--ink);
  line-height: 0.9;
  text-shadow: 0 5px 0 rgba(255, 255, 255, 0.4);
}

.lost h2 {
  font-size: clamp(1.4rem, 4vw, 2.1rem);
  color: var(--ink);
}

.lost p {
  max-width: 30rem;
  margin: 0;
  color: var(--ink);
}

.lost__links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  justify-content: center;
  margin-top: 0.8rem;
}

/* ==========================================================================
   Utilities
   ========================================================================== */

/* Two sections that read as one spread share a single block of breathing room
   rather than stacking two. */
.section--joined {
  padding-top: 0;
}

.section__outro {
  margin-top: clamp(2rem, 4vw, 3rem);
}

/* ==========================================================================
   Scroll reveal
   ========================================================================== */

[data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out);
  transition-delay: var(--reveal-delay, 0ms);
}

[data-reveal].is-revealed {
  opacity: 1;
  transform: none;
}

/* ==========================================================================
   Keyframes
   ========================================================================== */

@keyframes frames {
  to {
    background-position: calc(var(--cell) * -4) 0;
  }
}

@keyframes cross {
  from {
    transform: translateX(-30vw);
  }
  to {
    transform: translateX(115vw);
  }
}

@keyframes cross-back {
  from {
    transform: translateX(115vw);
  }
  to {
    transform: translateX(-30vw);
  }
}

@keyframes bob {
  from {
    translate: 0 -4px;
  }
  to {
    translate: 0 5px;
  }
}

@keyframes sway {
  from {
    transform: rotate(-4deg);
  }
  to {
    transform: rotate(4deg);
  }
}

@keyframes rise {
  0% {
    opacity: 0;
    transform: translate(0, 0) scale(0.7);
  }
  8% {
    opacity: 0.85;
  }
  100% {
    opacity: 0;
    transform: translate(var(--drift, 24px), calc(-1 * var(--climb, 90vh))) scale(1);
  }
}

@keyframes rays {
  from {
    transform: translateX(-4%) skewX(-1deg);
    opacity: 0.75;
  }
  to {
    transform: translateX(4%) skewX(1.5deg);
    opacity: 1;
  }
}

@keyframes caustics {
  to {
    background-position: 237px 0, -389px 0;
  }
}

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

@keyframes blink {
  0%,
  55% {
    opacity: 1;
  }
  56%,
  100% {
    opacity: 0.15;
  }
}

/* ==========================================================================
   Reduced motion — the tank goes still, nothing disappears
   ========================================================================== */

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

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .bubbles {
    display: none;
  }

  /* Park each fish somewhere legible instead of letting it snap off-screen. */
  .lane {
    animation: none;
    transform: translateX(var(--rest, 40vw));
  }

  .sprite {
    animation: none;
    background-position: 0 0;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
  }
}
