/*
 * The app's design system, on the web.
 *
 * Every value here is lifted from `src/theme/palettes.ts` and
 * `src/theme/tokens.ts` rather than eyeballed, so the site and the app cannot
 * drift into being two different products. The rules that matter, and which a
 * later edit should not quietly break:
 *
 * - **Pastel and tonal.** Every hue sits in the 70-90% lightness band, so no hue
 *   outranks another: hue carries role, not rank. Aqua is the anchor, coral is
 *   curiosity, mint is the page. Exactly one deep value breaks the band
 *   (`--primary`, for interactive things) plus the ink ramp. Nothing pops, which
 *   is the emotional point and a hazard for hierarchy — so hierarchy comes from
 *   size and position, never from shouting.
 * - **No red and no green exist in this palette**, so nothing can read as
 *   failure.
 * - **Elevation is a coloured glow plus an inner top light**, both in one
 *   shadow. There is no grey shadow anywhere: a shadow is the object's own hue,
 *   blurred.
 * - **Fredoka at 20px and up, Nunito below it.** A size boundary, not a role
 *   list. The one documented exception is button labels, which are Fredoka at 17
 *   because a pill reads as a single object.
 * - **No em dashes in copy.** Two sentences, or a comma. The separator is `·`.
 */

:root {
  /* --- palette, from src/theme/palettes.ts --- */
  --primary: #2a707a;
  --primary-dark: #266770;
  --teal: #7fd3dc;
  --teal-light: #d6f3f4;
  --coral: #f58a6a;
  --coral-dark: #de7455;
  --coral-light: #fac9b8;
  --sand-light: #faf2e6;
  --background: #c9ede8;
  --surface: #fdfcfa;
  --surface-alt: #e4f7f4;
  --text: #16404a;
  --text-secondary: #3f646d;
  --text-light: #fdfcfa;
  --border: rgba(127, 211, 220, 0.45);
  --border-light: rgba(46, 122, 133, 0.16);
  --on-action: #5a2412;

  /* --- geometry, from tokens.ts --- */
  --r-sm: 8px;
  --r-md: 16px;
  --r-lg: 24px;
  --r-xl: 32px;
  --r-pill: 999px;

  /* The object's own hue, blurred, plus a light along the top edge. */
  --glow: 0 12px 32px rgba(42, 112, 122, 0.13), inset 0 1px 0 rgba(255, 255, 255, 0.75);
  --glow-lift: 0 18px 44px rgba(42, 112, 122, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.85);
  --glow-coral: 0 12px 32px rgba(245, 138, 106, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.6);
  /* A deeper cast for the hero pair, which is the one place on the page an
     object is meant to sit above everything else rather than on the page. */
  --glow-deep: 0 30px 70px rgba(22, 64, 74, 0.22), 0 6px 18px rgba(22, 64, 74, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.85);

  /* The sticky header's fill. White at an alpha rather than a palette colour,
     which is the app's own idiom for translucent chrome: the wash behind it
     runs cream to mint, so any tinted fill would band against one end of it. */
  --chrome: rgba(253, 252, 250, 0.62);
  --chrome-opaque: rgba(253, 252, 250, 0.94);

  /* Height of the sticky header, so anchored sections can clear it. */
  --head-h: 78px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

body {
  margin: 0;
  /* Two layers, both fixed so neither repeats down a long policy page.
   *
   * On top, a fine greyscale grain. The app draws one (`Grain` in
   * components/onboarding/Atmosphere.tsx) and it is doing the same job here:
   * a wide, perfectly smooth gradient is the single clearest tell of a page
   * assembled from a template, because nothing in print or in the physical
   * world is that clean. At this opacity it is invisible as texture and
   * reads only as the ground having a surface.
   *
   * Generated rather than fetched — an feTurbulence data URI costs no request
   * and no file, and tiles seamlessly via stitchTiles.
   *
   * Under it, cream at the top settling into the page's mint, the same wash
   * the onboarding flow uses. */
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='4' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='0.35'/%3E%3C/svg%3E") repeat,
    linear-gradient(180deg, var(--sand-light) 0%, var(--background) 62%) no-repeat;
  background-attachment: fixed, fixed;
  background-color: var(--background);
  color: var(--text);
  font-family: 'Nunito', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  max-width: 1040px;
  margin: 0 auto;
  padding: 0 24px;
}

.wrap--narrow {
  max-width: 720px;
}

/* --- type ---------------------------------------------------------------- */

h1,
h2,
h3,
.display {
  font-family: 'Fredoka', -apple-system, BlinkMacSystemFont, sans-serif;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.15;
  margin: 0;
  /* Evens the line lengths instead of leaving one orphaned word on the last
     line, which is the difference between a headline that was set and one that
     was merely typed. The browser caps this at a few lines, so it costs
     nothing on long text and does nothing where it is not wanted. */
  text-wrap: balance;
}

/* Stops a single trailing word on a paragraph. Same idea, cheaper rule: unlike
   `balance` this is unbounded by line count, so it is the right one for body
   copy. Ignored where unsupported. */
p,
li {
  text-wrap: pretty;
}

h1 {
  font-size: clamp(38px, 6.5vw, 62px);
}

h2 {
  font-size: clamp(26px, 3.6vw, 36px);
}

h3 {
  font-size: 21px;
}

p {
  margin: 0;
}

.lede {
  font-size: clamp(18px, 2.1vw, 21px);
  line-height: 1.5;
  color: var(--text-secondary);
}

.kicker {
  font-family: 'Nunito', sans-serif;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--primary);
}

.muted {
  color: var(--text-secondary);
}

.small {
  font-size: 15px;
}

a {
  color: var(--primary);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--primary-dark);
}

/* --- header -------------------------------------------------------------- */

/* Sticky, and frosted.
 *
 * **This is the one place on the site where glass is the honest material**, by
 * the app's own test for it: the question is never "is it chrome", it is "does
 * content pass underneath". Here it genuinely does, all the way down the page.
 * Nothing else here floats over anything, which is why nothing else is frosted.
 *
 * The fill is white at an alpha rather than a tint, because the page's wash
 * runs cream at the top into mint below: a mint-tinted bar would be invisible
 * over the bottom of that and a visible band over the top of it.
 *
 * `@supports` carries the fallback rather than decorating it. Without
 * backdrop-filter the bar has to become near-opaque, or the nav sits on top of
 * whatever is scrolling under it at 62% and becomes unreadable — which is a
 * legibility failure, not a lost effect. */
.site-head {
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 16px 0;
  background: var(--chrome-opaque);
  border-bottom: 1px solid var(--border-light);
}

@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .site-head {
    background: var(--chrome);
    -webkit-backdrop-filter: blur(16px) saturate(160%);
    backdrop-filter: blur(16px) saturate(160%);
  }
}

/* Anchored sections clear the sticky bar rather than sliding under it. */
section[id] {
  scroll-margin-top: calc(var(--head-h) + 12px);
}

.site-head__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-family: 'Fredoka', sans-serif;
  font-weight: 700;
  font-size: 21px;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.01em;
}

.brand img {
  width: 34px;
  height: 34px;
  border-radius: var(--r-sm);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 15px;
  font-weight: 600;
}

.site-nav a {
  color: var(--text-secondary);
  text-decoration: none;
}

.site-nav a:hover {
  color: var(--primary);
}

.site-nav .btn {
  color: var(--text-light);
}

/* Below 620px the two text links go and the CTA stays. A header that wraps to
   two rows costs more vertical space than the links are worth on a page this
   short, and both destinations are reachable from the footer. */
@media (max-width: 619px) {
  .site-nav__link {
    display: none;
  }
}

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

/* Every button is a pill, and the label is Fredoka at 17: the one documented
   exception to the size boundary, because a pill reads as a single object
   rather than a capsule with words in it. */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 52px;
  padding: 0 30px;
  border: 0;
  border-radius: var(--r-pill);
  font-family: 'Fredoka', sans-serif;
  font-size: 17px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform 140ms ease, box-shadow 140ms ease;
}

.btn--primary {
  background: var(--primary);
  color: var(--text-light);
  box-shadow: var(--glow);
}

.btn--primary:hover {
  color: var(--text-light);
  box-shadow: var(--glow-lift);
}

/* The header's compact CTA. 44px rather than the 52 of the primary button and
   never less: that is the floor the app holds every tap target to, and a
   header button is the one most likely to be pressed with a thumb on the
   move. */
.btn--sm {
  min-height: 44px;
  padding: 0 20px;
  font-size: 15px;
}

/* scale(0.97) on press, matching the app. */
.btn:active {
  transform: scale(0.97);
}

.btn[disabled] {
  opacity: 0.55;
  cursor: default;
  transform: none;
}

/* --- surfaces ------------------------------------------------------------ */

.card {
  background: var(--surface);
  border-radius: var(--r-lg);
  padding: 28px;
  box-shadow: var(--glow);
}

/* Edges are value change, not stroke: the card draws no border, and the tint
   fill is what separates it from the page. */
.card--tint {
  background: var(--surface-alt);
}

/* Generous and viewport-relative rather than a fixed 56. Whitespace between
   sections is most of what separates a page that looks composed from one that
   looks packed, and it is the cheapest single change on this file. */
section {
  padding: clamp(56px, 8vw, 92px) 0;
}

.section-head {
  max-width: 640px;
  margin-bottom: 38px;
  display: grid;
  gap: 12px;
}

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

.hero {
  padding: 48px 0 30px;
  display: grid;
  gap: 44px;
  grid-template-columns: 1fr;
  align-items: center;
}

@media (min-width: 900px) {
  .hero {
    grid-template-columns: 1.05fr 0.95fr;
    padding: 64px 0 40px;
  }
}

.hero__copy {
  display: grid;
  gap: 22px;
  justify-items: start;
}

/* The one word allowed to be loud on the page. `onAction` rather than coral
   itself: coral-dark measures 2.49 against the mint stop, below even the
   large-text floor, and this deep terracotta is what the palette already uses
   as ink on a coral fill. */
.accent-word {
  color: var(--on-action);
}

/* --- phone frames -------------------------------------------------------- */

/* Two columns at every width, never `auto-fit`.
 *
 * Auto-fit collapses to one column below about 400px, which on a phone stacks
 * two screenshots at roughly 680px each: 1,350px of pictures between the
 * headline and the first sentence explaining what the app does. The pair is a
 * single composition rather than a responsive list, so it stays a pair and
 * simply gets smaller. */
.shots {
  position: relative;
  display: grid;
  gap: 18px;
  grid-template-columns: 1fr 1fr;
  max-width: 460px;
}

/* A soft bloom under the pair, so they read as sitting *above* the page rather
   than printed on it. This is the palette's own aqua at low alpha and heavily
   blurred, which is the same thing every elevation in this system is: the
   object's own hue, out of focus. */
.shots::before {
  content: '';
  position: absolute;
  inset: -14% -8% -4%;
  background: radial-gradient(58% 48% at 50% 44%, rgba(127, 211, 220, 0.55), transparent 72%);
  filter: blur(30px);
  pointer-events: none;
}

.phone {
  /* Held as custom properties so the hover rule can recompose the whole
     transform instead of replacing it. Setting `transform` twice is how a
     tilted phone silently snaps upright the moment you add a hover scale. */
  --tilt: 0deg;
  --shift: 0px;
  transform: rotate(var(--tilt)) translateY(var(--shift));
  aspect-ratio: 9 / 19.5;
  border-radius: var(--r-xl);
  background: var(--surface);
  box-shadow: var(--glow);
  padding: 9px;
  overflow: hidden;
  /* Not only for the hover z-index below: a positioned frame is what stops the
     scaled one being painted under its neighbour in the hero pair. */
  position: relative;
}

.phone img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 25px;
  display: block;
  /* A hairline inside the bezel. Four of the five screenshots are near-white at
     the top, and without this they bleed into the white frame around them and
     the phone stops having an edge. Outset would grow the box; inset does not. */
  outline: 1px solid var(--border-light);
  outline-offset: -1px;
}

/* The hero pair is staged rather than laid out: one leaning back, one forward
 * and dropped, both lifted off the page. A matched pair sitting square is the
 * flattest way to show two screens, and it is what makes a hero read as a
 * template rather than a product shot.
 *
 * Only from 900px. Below that the hero is a single column and the phones are
 * already large relative to the viewport, where a tilt reads as a mistake
 * rather than as staging. */
@media (min-width: 900px) {
  .hero__media .phone {
    box-shadow: var(--glow-deep);
  }

  .hero__media .phone--lead {
    --tilt: -3deg;
    --shift: -12px;
  }

  .hero__media .phone--trail {
    --tilt: 3.5deg;
    --shift: 26px;
  }
}

/* Hover lifts the frame and scales it, so a screenshot can be read rather than
 * just recognised. There is real detail to uncover rather than a blur being
 * enlarged: the assets are 640px wide and the frames lay out at about 221px in
 * the hero pair and 250px in the feature rows.
 *
 * **22% is near the ceiling, and the ceiling is arithmetic rather than taste.**
 * A 250px frame on a 2x display already wants 500 real pixels, so scaling it
 * by S wants 500S, and the asset runs out at 640. That puts the feature rows'
 * limit at 1.28 and the hero's at 1.45; the smaller of the two governs, since
 * one zoom level serves both. Going beyond this means re-running
 * scripts/build-site-shots.py at a larger TARGET_W, not editing this line.
 *
 * Two guards, and both are load-bearing rather than defensive habit:
 *
 * - **`hover: hover` and `pointer: fine`.** A bare `:hover` latches on touch —
 *   tap a screenshot on a phone and it stays enlarged until you tap another
 *   one, with no way to undo it. Most visitors to a page advertising an iPhone
 *   app are on an iPhone, so the unguarded version is broken for the majority.
 * - **The transform is inside `prefers-reduced-motion: no-preference`, not
 *   merely inside the global transition-killer at the top of this file.** That
 *   block sets `transition-duration: 0.01ms`, which does not remove the
 *   movement, it makes it instant — a *snap* between two sizes, which is worse
 *   for the vestibular trigger the setting exists to avoid than the animation
 *   it replaced. Reduced motion therefore keeps the shadow lift and drops the
 *   scale entirely, so the frame still answers the pointer without moving. */
@media (hover: hover) and (pointer: fine) {
  .phone {
    transition: transform 300ms cubic-bezier(0.22, 1, 0.36, 1), box-shadow 300ms ease;
  }

  .phone:hover {
    box-shadow: var(--glow-lift);
    z-index: 2;
  }
}

@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  /* Rights itself as well as rising: the tilt is staging, and the moment
     someone is actually trying to read a screenshot it stops helping. Picking
     something up to look at it squarely is the gesture this borrows. */
  .phone:hover {
    transform: rotate(0deg) translateY(calc(var(--shift) - 15px)) scale(1.22);
  }
}

/* --- feature rows -------------------------------------------------------- */

.feature {
  display: grid;
  gap: 32px;
  align-items: center;
  padding: 34px 0;
}

@media (min-width: 900px) {
  .feature {
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    padding: 44px 0;
  }
  /* Alternating sides, so a column of features reads as a walk rather than a
     list. `order` only, so the DOM order stays the reading order. */
  .feature:nth-child(even) .feature__media {
    order: -1;
  }
}

.feature__copy {
  display: grid;
  gap: 14px;
  align-content: start;
}

.feature__media .phone {
  max-width: 250px;
  margin: 0 auto;
}

/* --- steps --------------------------------------------------------------- */

.steps {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  counter-reset: step;
}

.step {
  background: var(--surface);
  border-radius: var(--r-lg);
  padding: 26px;
  box-shadow: var(--glow);
  display: grid;
  gap: 10px;
  align-content: start;
}

.step__n {
  width: 44px;
  height: 44px;
  border-radius: var(--r-pill);
  background: var(--teal-light);
  color: var(--primary);
  display: grid;
  place-content: center;
  font-family: 'Fredoka', sans-serif;
  font-weight: 700;
  font-size: 19px;
  margin-bottom: 4px;
  /* A tint edge at this size, the same call the app makes on its small icon
     tiles: at 44px a fill alone has no edge against a white card, and a value
     change is this system's border. */
  box-shadow: inset 0 0 0 1px var(--border);
}

/* --- the beta page ------------------------------------------------------- */

/* Everything here is an override of the homepage's rhythm, and the reason is
   the same for all of it: `section`'s padding and `.prose`'s heading margins
   are sized for a wide marketing page whose blocks are pictures. On a narrow
   column of short text the same values read as holes between the sections
   rather than as breathing room. Roughly half, throughout. */
.beta section {
  padding: clamp(26px, 4vw, 40px) 0;
}

.beta section:last-of-type {
  padding-bottom: clamp(40px, 6vw, 64px);
}

/* The beta page has no screenshot pair beside its headline, so it cannot use
   `.hero`'s two-column grid. A single column, with a measure short enough that
   the lede does not run the full width of the wrap. */
.beta-hero {
  padding: clamp(28px, 4vw, 44px) 0 clamp(18px, 2.5vw, 26px);
  display: grid;
  gap: 14px;
  max-width: 600px;
}

/* A section heading with the cards directly under it, rather than
   `.section-head`'s heading-plus-paragraph pair. */
.beta-h {
  margin-bottom: 18px;
}

/* One card holds three subjects here, so the gap between them has to say
   "next subject" without saying "next page". 40px was the latter. */
.beta .prose h2 {
  margin: 30px 0 10px;
}

.beta .prose h2:first-child {
  margin-top: 0;
}

/* The buttons sit inside paragraphs rather than in a row of their own. `.btn`
   is `inline-flex`, so without this the pill closes up against the copy. */
.cta-row {
  margin-top: 12px;
}

.beta .prose .cta-row {
  margin-top: 26px;
}

/* --- waitlist ------------------------------------------------------------ */

/* The page's last object, and the only one asked to close it, so it carries a
   little more than the cards above it: a wash rather than a flat fill, and the
   deeper cast. Still no colour it has not earned. */
.waitlist {
  position: relative;
  background: linear-gradient(165deg, var(--sand-light) 0%, var(--surface) 46%, var(--surface-alt) 100%);
  border-radius: var(--r-xl);
  padding: clamp(34px, 5.5vw, 60px);
  box-shadow: var(--glow-deep);
  text-align: center;
  display: grid;
  gap: 18px;
  justify-items: center;
  overflow: hidden;
}

/* A light off the top-left corner, the same inner top light every raised
   surface in this system carries, just at the scale of a whole panel. */
.waitlist::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(70% 60% at 12% 0%, rgba(255, 255, 255, 0.9), transparent 60%);
  pointer-events: none;
}

.waitlist > * {
  position: relative;
}

.waitlist form {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
  width: 100%;
  max-width: 480px;
}

.waitlist input {
  flex: 1 1 240px;
  min-height: 52px;
  padding: 0 20px;
  border-radius: var(--r-pill);
  border: 1px solid var(--border);
  background: var(--surface-alt);
  color: var(--text);
  font-family: 'Nunito', sans-serif;
  font-size: 16px;
}

.waitlist input:focus-visible,
.btn:focus-visible,
a:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
}

.waitlist input::placeholder {
  color: var(--text-secondary);
}

/* Reserved whether or not it holds anything, so the form does not jump when it
   answers. */
.form-note {
  min-height: 22px;
  font-size: 15px;
  color: var(--text-secondary);
}

/* --- prose (policy, terms, support) -------------------------------------- */

.prose {
  background: var(--surface);
  border-radius: var(--r-xl);
  padding: clamp(28px, 5vw, 56px);
  box-shadow: var(--glow);
}

.prose h1 {
  font-size: clamp(30px, 4.4vw, 42px);
  margin-bottom: 8px;
}

.prose h2 {
  font-size: 25px;
  margin: 40px 0 12px;
}

.prose h3 {
  font-size: 19px;
  margin: 28px 0 8px;
}

.prose p,
.prose ul,
.prose ol {
  margin: 12px 0;
}

.prose ul,
.prose ol {
  padding-left: 22px;
}

.prose li {
  margin: 7px 0;
}

.prose hr {
  border: 0;
  border-top: 1px solid var(--border-light);
  margin: 36px 0;
}

/* Wide tables scroll inside their own container rather than the page. */
.table-scroll {
  overflow-x: auto;
  margin: 18px 0;
  border-radius: var(--r-md);
  border: 1px solid var(--border-light);
}

.prose table {
  border-collapse: collapse;
  width: 100%;
  min-width: 520px;
  font-size: 15px;
}

.prose th,
.prose td {
  text-align: left;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-light);
  vertical-align: top;
}

.prose th {
  background: var(--surface-alt);
  font-family: 'Fredoka', sans-serif;
  font-weight: 600;
  color: var(--text);
}

.prose tr:last-child td {
  border-bottom: 0;
}

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

.site-foot {
  padding: 44px 0 56px;
  border-top: 1px solid var(--border-light);
  margin-top: 40px;
}

.site-foot__inner {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 26px;
  justify-content: space-between;
  align-items: center;
  font-size: 15px;
  color: var(--text-secondary);
}

.site-foot a {
  color: var(--text-secondary);
  text-decoration: none;
}

.site-foot a:hover {
  color: var(--primary);
}

/* --- arrival ------------------------------------------------------------- */

/*
 * Sections rise as they come into view, which is the app's own `Settle` one
 * layer out: something arriving, once, rather than a page that fidgets.
 *
 * **Scroll-driven CSS, deliberately, with no JavaScript anywhere near it.**
 * The usual way to do this is an IntersectionObserver that adds a class, and
 * that pattern has one failure mode this page cannot afford: the element is
 * hidden first and revealed second, so a script that never runs — blocked,
 * errored, still downloading on a bad connection — leaves the entire middle of
 * the landing page permanently invisible. Here the hidden state exists only
 * inside the animation, so a browser that does not support `view()` simply
 * runs no animation and renders the page exactly as it would have anyway.
 * Failure is *no effect*, never *no content*.
 *
 * `@supports` is what makes that true rather than hoped for. `animation-range`
 * and `animation-timeline` are ignored as unknown properties by anything that
 * does not implement them, but `animation: rise-in linear both` on its own
 * would still resolve — with no timeline to drive it, `both` would hold the
 * `from` frame and pin every section at zero opacity. The guard keeps the
 * shorthand and its timeline together.
 *
 * Not applied to the hero: it is above the fold, so there is no scroll to
 * drive it and it would either flash or sit still. The one thing on this page
 * that must be legible in the first frame is the sentence saying what the app
 * is.
 */
@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    .step,
    .feature,
    .waitlist,
    .section-head {
      animation: rise-in linear both;
      animation-timeline: view();
      /* Finished well before the element is centred. A reveal still running
         when you are already reading it is the effect drawing attention to
         itself rather than to the thing arriving. */
      animation-range: entry 5% cover 22%;
    }
  }
}

@keyframes rise-in {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}


/* --- page transitions ---------------------------------------------------- */

/*
 * Cross-document view transitions: navigating between the four pages
 * cross-fades rather than flashing white.
 *
 * Safe by construction. A browser without support performs an ordinary
 * navigation, which is what every browser did before this line existed, so
 * there is no fallback to write and nothing to break. The pages share a
 * header, a footer and a background, so the default cross-fade is close to
 * the right effect with nothing named or paired.
 *
 * Disabled rather than merely shortened under reduced motion: the transition
 * cannot live inside a media query, so the animation is cancelled on the
 * pseudo-elements instead, which is the documented way to opt out.
 */
@view-transition {
  navigation: auto;
}

@media (prefers-reduced-motion: reduce) {
  ::view-transition-group(*),
  ::view-transition-old(*),
  ::view-transition-new(*) {
    animation: none !important;
  }
}
