/* Bubblewake. The page is a dive: the water darkens section by section, from sunlit reef to black water to the sea floor. */

@font-face { font-family: "Manrope"; src: url("../fonts/manrope-latin-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Manrope"; src: url("../fonts/manrope-latin-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Manrope"; src: url("../fonts/manrope-latin-800.woff2") format("woff2"); font-weight: 800; font-display: swap; }

:root {
  --night: #0B0E17;
  --ink: #141729;
  --cream: #FFF4E3;
  --cream-2: #E4E6DE;
  --juice-a: #FFB547;
  --juice-b: #FF6A2B;
  --orange: #FF8A1F;
  --coral: #FF4F5E;
  --sky: #3EC5FF;
  --juice: linear-gradient(180deg, var(--juice-a), var(--juice-b));
  --gutter: clamp(16px, 4vw, 40px);
  /* The water, top to bottom. Each section fades into the next stop. */
  --w-surface: #0F5A6C;
  --w-try: #0C4A5A;
  --w-how: #0B4150;
  --w-shallows: #0F5F73;
  --w-kelp: #123F2E;
  --w-trench: #14466B;
  --w-wreck: #33190E;
  --w-caves: #0E3526;
  --w-deep-top: #040916;
  --w-deep: #081328;
  --w-reef: #0A2D42;
  --w-free: #060B18;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--night);
  color: var(--cream);
  font: 400 1.0625rem/1.6 "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  overflow-x: clip;
}
img, video, svg { display: block; max-width: 100%; height: auto; }
a { color: var(--cream); text-underline-offset: 3px; }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
h2 { font-size: clamp(2rem, 5.2vw, 3.5rem); line-height: 1.06; font-weight: 800; letter-spacing: -0.03em; text-wrap: balance; }
h3 { font-weight: 800; letter-spacing: -0.015em; line-height: 1.2; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--sky); outline-offset: 3px; border-radius: 6px; }
section[id], div[id] { scroll-margin-top: 16px; }

.wrap { width: min(1160px, 100%); margin-inline: auto; padding-inline: var(--gutter); }
.section-lede { margin-top: 14px; font-size: clamp(1.1rem, 2vw, 1.3rem); line-height: 1.5; max-width: 34em; color: var(--cream-2); }

.skip { position: absolute; left: 12px; top: -80px; z-index: 30; padding: 12px 18px; border-radius: 10px; background: var(--cream); color: var(--ink); font-weight: 800; }
.skip:focus { top: 12px; }

/* Top bar */
.topbar { position: absolute; inset: 0 0 auto; z-index: 10; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px var(--gutter); }
.brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; text-decoration: none; font-weight: 800; font-size: 1.1rem; letter-spacing: -0.02em; }
.brand img { width: 40px; height: 40px; border-radius: 11px; }
.topnav { display: flex; align-items: center; gap: 22px; font-weight: 700; font-size: 0.97rem; }
.topnav a { text-decoration: none; display: inline-flex; align-items: center; min-height: 44px; }
.topnav a:hover { text-decoration: underline; }
.topnav-get { padding-inline: 18px; border-radius: 999px; background: rgba(11, 14, 23, 0.55); border: 1.5px solid rgba(255, 244, 227, 0.55); }
.topnav-get:hover { background: var(--cream); color: var(--ink); text-decoration: none !important; }
@media (max-width: 760px) { .topnav-wide { display: none !important; } }

/* Buttons */
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 22px; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 54px; padding: 12px 26px; border-radius: 999px; font: inherit; font-weight: 800; letter-spacing: -0.01em; text-decoration: none; cursor: pointer; border: 0; transition: transform 0.15s ease; }
.btn:hover { transform: translateY(-2px); }
.btn--juice { color: var(--ink); background: var(--juice); box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.45), 0 4px 0 #A83F10; }
.btn--ghost { color: var(--cream); background: rgba(11, 14, 23, 0.42); border: 1.5px solid rgba(255, 244, 227, 0.55); }
.btn--ghost:hover { background: rgba(11, 14, 23, 0.7); }

/* The phone is a plain dark frame, with no maker's details. */
.phone { position: relative; width: min(100%, 300px); aspect-ratio: 1206 / 2622; border-radius: 34px; border: 7px solid var(--night); background: var(--night); overflow: hidden; box-shadow: 0 30px 70px rgba(2, 8, 20, 0.55); flex: none; }
.phone img, .phone video { width: 100%; height: 100%; object-fit: cover; }

/* Hero: sunlit water from the game's own home screen */
.hero::before { content: ""; position: absolute; inset: -10% -20% 20%; pointer-events: none; background: linear-gradient(100deg, transparent 12%, rgba(210, 250, 255, 0.13) 17%, transparent 25%, transparent 38%, rgba(210, 250, 255, 0.1) 46%, transparent 55%, transparent 66%, rgba(210, 250, 255, 0.14) 72%, transparent 80%); -webkit-mask-image: linear-gradient(180deg, #000, transparent); mask-image: linear-gradient(180deg, #000, transparent); }
.hero { position: relative; overflow: hidden; padding: 96px 0 56px; background: linear-gradient(180deg, rgba(8, 56, 70, 0.5), rgba(8, 62, 76, 0.52) 45%, var(--w-try) 100%), url("../img/open-water.webp") center top / cover no-repeat, var(--w-surface); }
.hero-grid { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: clamp(24px, 5vw, 72px); align-items: center; }
.kicker { font-weight: 800; font-size: 0.95rem; letter-spacing: 0.01em; color: #FFE0AE; }
.wordmark {
  margin: 4px 0 0 -0.03em;
  font-size: clamp(3.1rem, 13.6vw, 7.8rem);
  line-height: 1.02;
  font-weight: 800;
  letter-spacing: -0.045em;
  color: #FFD6A3;
  background: linear-gradient(180deg, #FFF8EC 18%, #FFB56B 88%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0.055em 0 #0B2433);
  padding-bottom: 0.08em;
}
.hero-lede { margin-top: 14px; max-width: 25em; font-size: clamp(1.2rem, 2.3vw, 1.5rem); line-height: 1.42; font-weight: 700; }
.hero-free { margin-top: 16px; max-width: 25em; font-size: clamp(1.1rem, 2vw, 1.3rem); line-height: 1.35; font-weight: 800; color: #FFD08A; letter-spacing: -0.015em; text-wrap: balance; }
.hero-former { margin-top: 20px; font-size: 0.97rem; color: var(--cream-2); max-width: 32em; }
.hero-phone { position: relative; width: clamp(240px, 25vw, 310px); }
.hero-phone .phone { width: 100%; transform: rotate(2.5deg); }
.hero-friend { position: absolute; z-index: 2; width: 44%; left: -27%; top: 13%; animation: bob 5.5s ease-in-out infinite; filter: drop-shadow(0 12px 18px rgba(2, 20, 34, 0.35)); }
@keyframes bob { 50% { transform: translateY(-14px) rotate(-3deg); } }
.clip-toggle { position: absolute; right: 10px; bottom: 10px; min-height: 44px; min-width: 44px; padding: 0 14px; border-radius: 999px; border: 0; font: inherit; font-size: 0.85rem; font-weight: 800; color: var(--cream); background: rgba(11, 14, 23, 0.72); cursor: pointer; }

/* Rising bubbles. Drawn, not photographed, and silent for anyone who asked for less motion. */
.drift { position: absolute; inset: 0; pointer-events: none; }
.drift i { position: absolute; bottom: -60px; width: 26px; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle at 32% 28%, rgba(255, 255, 255, 0.85) 0 7%, transparent 9%), radial-gradient(circle at 50% 50%, transparent 62%, rgba(190, 240, 255, 0.5) 72%, rgba(255, 210, 240, 0.65) 100%); animation: rise 17s linear infinite; }
.drift i:nth-child(1) { left: 6%; animation-delay: -2s; }
.drift i:nth-child(2) { left: 22%; width: 14px; animation-delay: -11s; animation-duration: 21s; }
.drift i:nth-child(3) { left: 41%; width: 38px; animation-delay: -6s; }
.drift i:nth-child(4) { left: 58%; width: 18px; animation-delay: -14s; animation-duration: 23s; }
.drift i:nth-child(5) { left: 79%; width: 30px; animation-delay: -9s; animation-duration: 19s; }
.drift i:nth-child(6) { left: 93%; width: 16px; animation-delay: -4s; }
@keyframes rise { to { transform: translateY(-110vh) translateX(18px); } }

/* Try it */
.try { padding: clamp(48px, 7vw, 88px) 0; background: linear-gradient(180deg, var(--w-try), var(--w-how)); }
.try-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 400px); gap: clamp(24px, 6vw, 80px); align-items: center; }
.try p { margin-top: 14px; max-width: 30em; font-size: clamp(1.08rem, 1.8vw, 1.2rem); color: var(--cream-2); }
.try .coach { min-height: 3.1em; margin-top: 22px; scroll-margin-top: 12px; font-size: clamp(1.25rem, 2.6vw, 1.6rem); line-height: 1.3; font-weight: 800; color: #FFD08A; letter-spacing: -0.015em; }
.try .btn { margin-top: 10px; }
.well:focus { outline-offset: 3px; }
.well { position: relative; width: 100%; aspect-ratio: 3 / 4; border-radius: 34px; overflow: hidden; touch-action: manipulation; background: linear-gradient(180deg, rgba(120, 215, 225, 0.55), rgba(25, 110, 135, 0.35) 60%, rgba(14, 62, 84, 0.65)), url("../img/open-water.webp") center / cover; border: 7px solid #0A2F3D; box-shadow: inset 0 0 50px rgba(3, 25, 40, 0.5); user-select: none; -webkit-user-select: none; }
.w-bubble, .w-friend, .w-urchin, .w-shell { position: absolute; left: 0; top: 0; }
.w-bubble { padding: 0; border: 0; background: none; border-radius: 50%; cursor: pointer; }
.w-bubble:focus-visible { outline-offset: 2px; }
.w-holder { width: 30%; aspect-ratio: 1; }
.w-holder img { width: 100%; }
.w-side { width: 24%; aspect-ratio: 1; background: radial-gradient(circle at 32% 26%, rgba(255, 255, 255, 0.95) 0 6%, transparent 8%), radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.05) 55%, rgba(170, 240, 225, 0.55) 72%, rgba(190, 170, 255, 0.75) 88%, rgba(255, 215, 235, 0.95) 100%); }
.w-bubble.is-target::after { content: ""; position: absolute; inset: -8%; border-radius: 50%; border: 3px solid var(--cream); animation: target 1.1s ease-out infinite; pointer-events: none; }
@keyframes target { from { transform: scale(0.9); opacity: 1; } to { transform: scale(1.3); opacity: 0; } }
.w-friend { width: 15%; }
.w-urchin { width: 18%; filter: drop-shadow(0 0 8px rgba(255, 70, 170, 0.8)); }
.w-shell { width: 34%; }
.w-ring { position: absolute; border-radius: 50%; border: 4px solid #FFF; pointer-events: none; animation: ring 0.5s ease-out forwards; }
@keyframes ring { from { transform: translate(-50%, -50%) scale(0.5); opacity: 1; } to { transform: translate(-50%, -50%) scale(1.7); opacity: 0; } }

/* How it plays */
.how { padding: clamp(40px, 6vw, 72px) 0 clamp(48px, 7vw, 88px); background: linear-gradient(180deg, var(--w-how), var(--w-shallows)); }
.how-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
/* The rules step down and across, the way a pop sends things sinking. */
.rules { display: grid; gap: clamp(26px, 3.4vw, 40px); }
.rule { display: grid; grid-template-columns: clamp(84px, 9vw, 112px) minmax(0, 1fr); gap: clamp(16px, 2.4vw, 28px); align-items: center; }
.rule:nth-child(2) { margin-left: clamp(0px, 4vw, 56px); }
.rule:nth-child(3) { margin-left: clamp(0px, 8vw, 112px); }
.rule h3 { font-size: clamp(1.3rem, 2.3vw, 1.6rem); }
.rule p { margin-top: 8px; color: var(--cream-2); }
.rule--last h3 { color: #FFD08A; }
.stars { grid-column: 1 / -1; display: flex; align-items: center; gap: 22px; margin-top: clamp(8px, 2vw, 24px); }
.stars-marks { display: flex; gap: 6px; flex: none; }
.stars-marks b { display: grid; place-items: center; width: 44px; height: 44px; color: var(--ink); font-size: 0.85rem; font-weight: 800; background: var(--juice); clip-path: polygon(50% 2%, 63% 35%, 98% 37%, 70% 59%, 80% 94%, 50% 74%, 20% 94%, 30% 59%, 2% 37%, 37% 35%); padding-top: 5px; }
.stars p { max-width: 42em; }
.stars strong { font-weight: 800; }

/* The worlds */
.world-intro { padding: clamp(32px, 5vw, 64px) 0 0; background: var(--w-shallows); }
/* Each world's light comes from a gradient drawn here, so no screenshot downloads before it is needed. */
.world { position: relative; overflow: hidden; padding: clamp(40px, 6vw, 80px) 0; background: var(--light), linear-gradient(180deg, var(--top), var(--bottom)); }
.world-grid { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: clamp(24px, 6vw, 96px); align-items: center; }
.world:nth-of-type(odd) .world-grid { grid-template-columns: 300px minmax(0, 1fr); }
.world:nth-of-type(odd) .phone { order: -1; }
.world--shallows { --top: var(--w-shallows); --bottom: #11563F; --light: radial-gradient(52% 58% at 80% 42%, rgba(150, 240, 215, 0.26), transparent 72%); }
.world--kelp { --top: #11563F; --bottom: var(--w-kelp); --light: radial-gradient(48% 62% at 20% 48%, rgba(120, 215, 110, 0.2), transparent 72%); }
.world--trench { --top: var(--w-kelp); --bottom: var(--w-trench); --light: radial-gradient(52% 60% at 80% 52%, rgba(165, 225, 255, 0.26), transparent 72%); }
/* Blue drops to near-black before the rust comes in. Blending blue straight into brown turns to mud. */
.world--wreck { padding-bottom: calc(clamp(40px, 6vw, 80px) + clamp(36px, 6vw, 84px)); --light: radial-gradient(48% 56% at 20% 58%, rgba(255, 150, 70, 0.22), transparent 72%); background: var(--light), linear-gradient(180deg, var(--w-trench), #0B1520 20%, #1B100B 36%, var(--w-wreck) 62%, #40200F); }
/* The Wreck ends on a torn hull, not a fade: rust stops and black water starts on a hard edge. */
.world--wreck::before, .world--wreck::after { content: ""; position: absolute; inset: auto 0 0; height: clamp(40px, 6.4vw, 92px); clip-path: polygon(0 100%, 0 40%, 9% 40%, 11% 64%, 14% 46%, 26% 46%, 29% 74%, 31% 36%, 47% 36%, 50% 60%, 53% 26%, 68% 26%, 70% 68%, 73% 50%, 86% 50%, 88% 78%, 91% 34%, 100% 34%, 100% 100%); }
.world--wreck::before { background: #7E431E; bottom: 7px; }
.world--wreck::after { background: var(--w-deep-top); }
/* The Forking Caves sit in the same green gloom as the Kelp Forest, between the Wreck's dark edge and the Deep. */
.world--caves { margin-top: -1px; --light: radial-gradient(48% 58% at 22% 52%, rgba(120, 215, 160, 0.18), transparent 72%); background: var(--light), linear-gradient(180deg, var(--w-deep-top), var(--w-caves) 45%, var(--w-deep-top)); }
.fork-art { width: 100%; max-width: 300px; margin: 0; }
.fork-art svg { display: block; width: 100%; height: auto; filter: drop-shadow(0 30px 50px rgba(2, 8, 20, 0.55)); }
.world:nth-of-type(odd) .fork-art { order: -1; }
.world--deep { margin-top: -1px; --top: var(--w-deep-top); --bottom: var(--w-deep); --light: radial-gradient(50% 58% at 80% 48%, rgba(190, 60, 190, 0.2), transparent 72%), radial-gradient(40% 40% at 16% 76%, rgba(60, 170, 255, 0.12), transparent 72%); }
.levels { font-weight: 800; font-size: 1rem; color: #FFD08A; }
.world-name { margin-top: 4px; font-size: clamp(2.7rem, 8.4vw, 6rem); line-height: 1; letter-spacing: -0.04em; }
.world-copy > p:not(.levels) { margin-top: 18px; max-width: 28em; font-size: clamp(1.08rem, 1.8vw, 1.22rem); line-height: 1.5; }
.adds { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.adds li { padding: 5px 14px; border-radius: 999px; font-weight: 700; font-size: 0.93rem; background: rgba(255, 255, 255, 0.13); border: 1px solid rgba(255, 255, 255, 0.28); }

/* Depth rail, wide screens only */
.rail { display: none; }
@media (min-width: 1320px) {
  .rail { position: fixed; z-index: 8; left: 22px; top: 50%; transform: translateY(-50%); height: min(62vh, 480px); display: flex; flex-direction: column; justify-content: space-between; width: 3px; background: rgba(255, 244, 227, 0.28); border-radius: 3px; }
  .rail a { position: relative; display: block; width: 44px; height: 44px; margin: -22px 0 -22px -21px; }
  .rail a::before { content: ""; position: absolute; left: 16px; top: 16px; width: 12px; height: 12px; border-radius: 50%; background: var(--cream); opacity: 0.75; }
  .rail a span { position: absolute; left: 44px; top: 10px; white-space: nowrap; font-size: 0.85rem; font-weight: 700; opacity: 0; transition: opacity 0.2s; pointer-events: none; }
  .rail a:hover span, .rail a:focus-visible span { opacity: 1; }
  .rail-friend { position: absolute; left: -16px; top: 0; width: 34px; max-width: none; height: 34px; margin-top: -17px; z-index: 1; pointer-events: none; }
}

/* The reef */
.reef { padding: clamp(48px, 7vw, 96px) 0; background: linear-gradient(180deg, var(--w-deep), var(--w-reef) 40%, var(--w-free)); }
.reef-grid { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: clamp(28px, 6vw, 88px); align-items: center; }
.reef-phones { display: flex; align-items: flex-end; flex: none; }
.reef-phones figure { width: 220px; margin-right: -46px; transform: rotate(-4deg); }
.reef-phones .phone--reef { width: 300px; margin-right: 0; transform: none; z-index: 1; }
.reef-phones figcaption { position: absolute; left: 50%; bottom: 12px; transform: translateX(-50%); white-space: nowrap; padding: 3px 12px; border-radius: 999px; font-size: 0.82rem; font-weight: 800; background: rgba(11, 14, 23, 0.8); }
.extras { margin-top: 28px; display: grid; gap: 16px; max-width: 36em; }
.extras li { border-top: 1px solid rgba(255, 244, 227, 0.26); padding-top: 14px; color: var(--cream-2); }
.extras strong { color: var(--cream); font-weight: 800; }

/* Free to play, in the darkest water */
.free { position: relative; overflow: hidden; padding: clamp(64px, 10vw, 128px) 0; background: var(--w-free); text-align: center; }
.free-big { font-size: clamp(3rem, 11.4vw, 8.2rem); line-height: 1; letter-spacing: -0.05em; background: var(--juice); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; padding-bottom: 0.06em; color: var(--orange); position: relative; }
.free-line { position: relative; margin: 22px auto 0; max-width: 22em; font-size: clamp(1.3rem, 3vw, 2rem); line-height: 1.28; font-weight: 700; letter-spacing: -0.02em; }
.free-note { position: relative; margin-top: 18px; font-weight: 700; color: var(--cream-2); }
.glow i { position: absolute; width: 10px; height: 10px; border-radius: 50%; background: var(--sky); box-shadow: 0 0 22px 7px rgba(62, 197, 255, 0.55); opacity: 0.55; animation: glow 6s ease-in-out infinite; }
.glow i:nth-child(1) { left: 8%; top: 18%; }
.glow i:nth-child(2) { left: 20%; top: 76%; width: 6px; height: 6px; animation-delay: -2s; }
.glow i:nth-child(3) { left: 34%; top: 9%; width: 5px; height: 5px; animation-delay: -4s; background: #5CF0C8; box-shadow: 0 0 20px 6px rgba(92, 240, 200, 0.5); }
.glow i:nth-child(4) { left: 52%; top: 90%; animation-delay: -1s; background: #FF5FB0; box-shadow: 0 0 22px 7px rgba(255, 95, 176, 0.45); }
.glow i:nth-child(5) { left: 68%; top: 12%; width: 7px; height: 7px; animation-delay: -3s; }
.glow i:nth-child(6) { left: 82%; top: 70%; animation-delay: -5s; background: #5CF0C8; box-shadow: 0 0 20px 6px rgba(92, 240, 200, 0.5); }
.glow i:nth-child(7) { left: 93%; top: 26%; width: 5px; height: 5px; animation-delay: -2.5s; background: #FF5FB0; box-shadow: 0 0 22px 7px rgba(255, 95, 176, 0.45); }
.glow i:nth-child(8) { left: 4%; top: 58%; width: 6px; height: 6px; animation-delay: -3.5s; }
@keyframes glow { 50% { opacity: 0.15; } }

/* Get it, on the sea floor */
.get { position: relative; padding: clamp(40px, 6vw, 72px) 0 0; background: linear-gradient(180deg, var(--w-free), #0B2A38 62%, #124A58); }
.get-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px clamp(28px, 5vw, 64px); }
.get-head { grid-column: 1 / -1; display: flex; align-items: center; gap: 16px; }
.get-friend { width: 72px; flex: none; }
.get-label { font-size: clamp(1.25rem, 2.3vw, 1.5rem); }
.get-now p, .get-old p { margin-top: 10px; color: var(--cream-2); max-width: 30em; }
.get-now:last-child { grid-column: 1 / -1; }
.get-old { border-left: 2px solid rgba(255, 244, 227, 0.3); padding-left: clamp(16px, 3vw, 32px); }
.badge-row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-top: 18px; }
.badge { display: inline-block; border-radius: 8px; }
.badge img { height: 48px; width: auto; }
.badge--play img { height: 70px; margin: -11px 0; }
.seafloor { position: relative; height: clamp(150px, 19vw, 230px); margin-top: 8px; overflow: hidden; }
.seafloor svg { position: absolute; inset: auto 0 0; width: 100%; height: 66%; }
.seafloor img { position: absolute; left: 50%; bottom: 10%; width: clamp(110px, 13vw, 170px); transform: translateX(-50%); }

/* Support */
.support { padding: clamp(36px, 5vw, 64px) 0; background: #A98F6D; color: var(--ink); }
.support a { color: var(--ink); font-weight: 800; overflow-wrap: anywhere; }
.support h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
.support p { margin-top: 10px; }
.support-grid { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(20px, 5vw, 64px); }
.support :focus-visible { outline-color: var(--ink); }
.faq details { border-top: 1.5px solid rgba(20, 23, 41, 0.45); }
.faq details:last-child { border-bottom: 1.5px solid rgba(20, 23, 41, 0.45); }
.faq summary { min-height: 52px; display: flex; align-items: center; justify-content: space-between; gap: 12px; cursor: pointer; font-weight: 800; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.5rem; line-height: 1; flex: none; }
.faq details[open] summary::after { content: "\2212"; }
.faq p { margin: 0 0 14px; }

/* Footer */
.site-footer { padding: 36px 0 44px; background: var(--night); }
.footer-grid { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: clamp(20px, 5vw, 56px); align-items: center; }
.splash { width: 190px; height: auto; background: var(--night); object-fit: contain; }
.footer-line { font-weight: 700; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 0 22px; margin-top: 6px; }
.site-footer nav a { display: inline-flex; align-items: center; min-height: 44px; overflow-wrap: anywhere; }
.footer-small { margin-top: 6px; font-size: 0.9rem; color: #B9BDC6; }

/* Legal and accessibility pages */
.doc-head { position: relative; padding: 100px 0 40px; background: linear-gradient(180deg, rgba(8, 56, 70, 0.72), var(--ink)), url("../img/open-water.webp") center top / cover, var(--ink); }
.doc-head h1 { font-size: clamp(2.3rem, 6vw, 4rem); line-height: 1.05; font-weight: 800; letter-spacing: -0.035em; text-wrap: balance; }
.doc-head .kicker { margin-bottom: 8px; }
.doc-head p:not(.kicker) { margin-top: 14px; max-width: 36em; font-size: 1.12rem; }
.doc { background: var(--ink); padding: 8px 0 64px; }
.doc .wrap { width: min(780px, 100%); }
.doc section { padding-top: 30px; }
.doc h2 { font-size: clamp(1.35rem, 3vw, 1.7rem); letter-spacing: -0.02em; }
.doc h3 { margin-top: 18px; font-size: 1.1rem; }
.doc p, .doc ul, .doc ol { margin-top: 12px; color: var(--cream-2); }
.doc ul { list-style: disc; padding-left: 1.3em; }
.doc ol { list-style: decimal; padding-left: 1.5em; }
.doc li + li { margin-top: 6px; }
.doc strong { color: var(--cream); }
.doc code { font-size: 0.92em; overflow-wrap: anywhere; }
.doc a { overflow-wrap: anywhere; }
.doc-callout { margin-top: 14px; padding: 16px 18px; border-left: 4px solid var(--orange); background: rgba(255, 255, 255, 0.06); border-radius: 0 12px 12px 0; }
.doc-callout p { margin: 0; color: var(--cream); font-weight: 700; }
.notfound { min-height: 72vh; display: grid; align-content: center; padding: 110px 0 60px; background: linear-gradient(180deg, var(--w-try), var(--w-free)); }
.notfound img { width: 96px; margin-bottom: 18px; }
.notfound p { margin-top: 12px; max-width: 28em; }

@media (min-width: 861px) { .hero .wordmark { font-size: min(8vw, 7.2rem); } }

/* Narrow screens */
@media (max-width: 860px) {
  .hero { padding-top: 80px; }
  .hero-grid, .try-grid, .reef-grid, .support-grid, .get-grid { grid-template-columns: minmax(0, 1fr); }
  .hero-phone { width: min(62vw, 270px); margin: 12px auto 0; }
  .hero-friend { left: -30%; top: 8%; }
  .how-grid { grid-template-columns: minmax(0, 1fr); }
  .rule:nth-child(n) { margin-left: 0; }
  .try .coach { min-height: 4em; }
  .well { max-width: 400px; margin-inline: auto; }
  .world-grid, .world:nth-of-type(odd) .world-grid { grid-template-columns: minmax(0, 1fr); gap: 26px; }
  .world .phone, .world:nth-of-type(odd) .phone { order: 0; width: min(66vw, 280px); margin-inline: auto; }
  .world .fork-art, .world:nth-of-type(odd) .fork-art { order: 0; width: min(66vw, 280px); margin-inline: auto; }
  .reef-phones { justify-content: center; order: 2; }
  .reef-phones figure { width: 38vw; margin-right: -9vw; }
  .reef-phones .phone--reef { width: 54vw; }
  .stars { align-items: flex-start; flex-direction: column; gap: 12px; }
  .get-old { border-left: 0; padding-left: 0; border-top: 2px solid rgba(255, 244, 227, 0.3); padding-top: 24px; }
  .btn-row .btn { flex: 1 1 100%; }
  .footer-grid { grid-template-columns: minmax(0, 1fr); }
  .splash { width: 170px; }
}

/* The Pause motion button freezes every decorative loop. The target ring holds still rather than vanish mid-fade. */
.motion-paused .hero-friend, .motion-paused .drift i, .motion-paused .glow i { animation-play-state: paused; }
.motion-paused .w-bubble.is-target::after { animation: none; }

/* Less motion */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .drift, .glow { display: none; }
  .btn:hover { transform: none; }
  .w-bubble.is-target::after { opacity: 1; }
  .w-ring { display: none; }
}
