/* ---------------------------------------------------------------
   Atmos1 website: one stylesheet for index.html and download.html, which
   live in the accounts site's public/ folder (D-045).

   Tokens are the app's own light theme
   (apps/desktop/src/renderer/tokens.css, built against British Dyslexia
   Association guidance) with the ground lifted to near white. There is
   no dark mode on this site by Jamie's decision. DyslexicAid's navy
   (dyslexicAid/brand/style-guide.md) is used only for the maker's
   identity: the masthead link and the footer band.
   --------------------------------------------------------------- */
/* Lexend, served from this folder (SIL Open Font License 1.1; the licence
   text is in fonts/OFL.txt). Chosen for readability: it was designed to
   reduce visual stress for readers who find text hard. A variable file per
   subset, so one request covers every weight the pages use. */
@font-face {
  font-family: "Lexend";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("fonts/lexend-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Lexend";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("fonts/lexend-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --surface: #fcfbf9;
  --surface-raised: #ffffff;
  --ink: #26251f;
  --ink-muted: #6b6a63;
  --border: rgba(38, 37, 31, 0.12);
  --border-strong: rgba(38, 37, 31, 0.24);

  --accent: #2e7d6b;
  --on-accent: #ffffff;
  --accent-tint: rgba(46, 125, 107, 0.12);

  --warning: #8a5a10;
  --warning-tint: rgba(138, 90, 16, 0.14);

  --scrim: rgba(38, 37, 31, 0.06);
  --shadow-lifted: 0 2px 4px rgba(38, 37, 31, 0.05),
    0 18px 48px rgba(38, 37, 31, 0.1);

  /* The demo scenes' "desktop": a shade darker than the page so the
     mock windows read as windows. */
  --desk: #f1eee9;
  /* The reading highlight, the app's own selection colour family. */
  --read-tint: rgba(46, 125, 107, 0.22);
  --select-tint: rgba(46, 125, 107, 0.16);

  /* DyslexicAid tokens (dyslexicAid/brand/style-guide.md). Scoped to
     the maker's identity only -- masthead lockup and footer band --
     so the parent brand signs the page without fighting the product's
     own palette for it. */
  --da-navy: #194a7a;
  --da-ice: #a8d4ff;
  --da-link: #194a7a;

  --photo-shadow: 0 2px 6px rgba(38, 37, 31, 0.06),
    0 24px 60px rgba(38, 37, 31, 0.14);

  --font-display: "Lexend", ui-rounded, "SF Pro Rounded", -apple-system,
    system-ui, sans-serif;
  --font-body: "Lexend", -apple-system, system-ui, "Segoe UI", sans-serif;
  --font-mono: ui-monospace, "SF Mono", "Cascadia Code", "Segoe UI Mono",
    monospace;

  --leading: 1.5;
  --tracking: 0.014em;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-pill: 999px;

  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 56px;
  --space-8: 88px;

  --motion-fast: 80ms;
  --ease-standard: cubic-bezier(0.2, 0, 0, 1);
}

/* One light theme. Jamie asked for the page to be light everywhere,
   so there is deliberately no dark-mode block: the ground stays
   off-white whatever the visitor's system setting. */

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: var(--leading);
  letter-spacing: var(--tracking);
  color: var(--ink);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
  text-align: left;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: var(--tracking);
  text-wrap: balance;
  margin: 0;
}

p {
  margin: 0;
  max-width: 60ch;
}

a {
  color: var(--accent);
}

:focus {
  outline: none;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

.mono {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0;
}

.shell {
  width: min(100% - 2.5rem, 66rem);
  margin-inline: auto;
}

.prose {
  max-width: 60ch;
}

/* ---------------- Masthead: the brand lockup ---------------- */
.masthead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  flex-wrap: wrap;
  padding-block: var(--space-5);
}

.wordmark {
  display: flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  color: inherit;
}

/* The product's signature element: the HUD's five-bar listening
   waveform (src/renderer/hud/Murmuration.tsx). The bars rise once on
   load, a gesture that says what the product does, then hold still. */
.waveform {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 24px;
  flex: none;
}

.waveform span {
  display: block;
  width: 4px;
  border-radius: var(--radius-pill);
  background: var(--accent);
  transform-origin: bottom;
  animation: bar-rise 620ms var(--ease-standard) both;
}

.waveform span:nth-child(1) { height: 10px; animation-delay: 0ms; }
.waveform span:nth-child(2) { height: 17px; animation-delay: 70ms; }
.waveform span:nth-child(3) { height: 24px; animation-delay: 140ms; }
.waveform span:nth-child(4) { height: 15px; animation-delay: 210ms; }
.waveform span:nth-child(5) { height: 8px;  animation-delay: 280ms; }

@keyframes bar-rise {
  from { transform: scaleY(0.16); opacity: 0.4; }
  to   { transform: scaleY(1);    opacity: 1; }
}

.wordmark-stack {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.wordmark-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.125rem;
}

.wordmark-maker {
  font-size: 0.8125rem;
  color: var(--da-link);
  text-decoration: none;
  font-weight: 500;
}

.wordmark-maker b {
  font-weight: 800;
}

.wordmark-maker:hover {
  text-decoration: underline;
}

.masthead-right {
  display: flex;
  align-items: center;
  gap: var(--space-4) var(--space-5);
  flex-wrap: wrap;
}

.nav {
  display: flex;
  gap: var(--space-2) var(--space-5);
  flex-wrap: wrap;
  font-size: 0.9375rem;
}

.nav a {
  color: var(--ink-muted);
  text-decoration: none;
  font-weight: 500;
  padding-block: 4px;
}

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

.channel-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  background: var(--warning-tint);
  color: var(--warning);
  font-size: 0.875rem;
  font-weight: 500;
  white-space: nowrap;
}

.channel-chip::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  flex: none;
}

/* ---------------- Buttons ---------------- */
.button {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: 14px 24px;
  border: none;
  border-radius: var(--radius-md);
  background: var(--accent);
  color: var(--on-accent);
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 600;
  letter-spacing: var(--tracking);
  text-decoration: none;
  cursor: pointer;
  transition: filter var(--motion-fast) var(--ease-standard);
}

.button:hover {
  filter: brightness(1.06);
}

.button:active {
  filter: brightness(0.95);
}

.button-quiet {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--border-strong);
}

.button-quiet:hover {
  background: var(--scrim);
  filter: none;
}

/* ---------------- Hero ---------------- */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: var(--space-7) var(--space-6);
  align-items: center;
  padding-block: clamp(var(--space-5), 4vw, var(--space-7)) var(--space-8);
}

.hero h1 {
  font-size: clamp(2.125rem, 5vw, 3.375rem);
  line-height: 1.12;
  max-width: 14ch;
}

.hero-lede {
  margin-top: var(--space-5);
  font-size: 1.125rem;
  color: var(--ink-muted);
  max-width: 44ch;
}

.hero-actions {
  margin-top: var(--space-6);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3) var(--space-4);
}

.hero-availability {
  margin-top: var(--space-4);
  font-size: 0.9375rem;
  color: var(--ink-muted);
}

.hero-tagline {
  margin-top: var(--space-6);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.125rem;
  color: var(--accent);
}

/* =================================================================
   DEMO SCENES
   A scene is a small desktop: a darker ground, a mock window inside
   it, and the app's HUD pill floating at the bottom. Each has a
   timeline expressed as --t custom properties; `.is-playing` runs it.
   The rest state (no class) is the FINISHED state, so no JavaScript
   and reduced motion both show the outcome rather than a blank card.
   ================================================================= */
.scene {
  position: relative;
  background: var(--desk);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(18px, 3.4vw, 30px);
  overflow: hidden;
  min-height: 300px;
  container-type: inline-size;
}

.scene-caption {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--space-3);
  margin-top: var(--space-3);
  font-size: 0.875rem;
  color: var(--ink-muted);
}


/* The mock window */
.win {
  background: var(--surface-raised);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lifted);
  border: 1px solid var(--border);
  overflow: hidden;
  font-size: 0.9375rem;
}

.win-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 9px 12px;
  border-bottom: 1px solid var(--border);
  color: var(--ink-muted);
  font-size: 0.8125rem;
}

.win-bar i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border-strong);
  display: inline-block;
}

.win-bar i:nth-child(1) { background: #e5655a; }
.win-bar i:nth-child(2) { background: #e8b53c; }
.win-bar i:nth-child(3) { background: #62c26a; }

.win-title {
  margin-left: 8px;
}

.win-body {
  padding: 14px 16px 18px;
}

.field {
  display: flex;
  gap: 10px;
  padding-block: 6px;
  border-bottom: 1px solid var(--border);
  font-size: 0.875rem;
}

.field b {
  font-weight: 500;
  color: var(--ink-muted);
  min-width: 4.5em;
}

.typed {
  padding-top: 12px;
  min-height: 5.5em;
  line-height: 1.55;
}

/* Words appear one at a time, like a transcript landing at the cursor. */
.w {
  display: inline;
}

/* `both` holds the first keyframe through the delay, so a word that
   has not landed takes no space and the caret sits after the last
   word that has, exactly as real typing reflows. Browsers that cannot
   animate `display` ignore that line and simply fade the words in. */
.is-playing .w {
  animation: word-in 260ms var(--ease-standard) both;
  animation-delay: calc(var(--t-words) + var(--i) * var(--t-word));
}

@keyframes word-in {
  0%   { display: none; opacity: 0; transform: translateY(4px); }
  1%   { display: inline-block; opacity: 0; transform: translateY(4px); }
  100% { display: inline-block; opacity: 1; transform: none; }
}

/* The text caret: blinks while the words land, then goes still. */
.caret {
  display: inline-block;
  width: 2px;
  height: 1.1em;
  background: var(--ink);
  vertical-align: -0.2em;
  margin-left: 1px;
  opacity: 0;
}

.is-playing .caret {
  animation: caret-blink 900ms steps(1) infinite;
  animation-delay: var(--t-hud-in);
  animation-duration: 900ms;
}

.is-playing .caret {
  /* Blink from the HUD appearing until the HUD leaves; expressed as a
     finite iteration count so it does not blink for ever. */
  animation-iteration-count: var(--caret-blinks);
}

@keyframes caret-blink {
  0%   { opacity: 1; }
  50%  { opacity: 0; }
  100% { opacity: 1; }
}

/* The HUD: the app's floating listening pill, as it looks on screen. */
.hud {
  position: absolute;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 16px 9px 14px;
  border-radius: var(--radius-pill);
  background: var(--surface-raised);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lifted);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ink);
  white-space: nowrap;
  opacity: 0;
}

.is-playing .hud {
  animation: hud-visit var(--t-hud-dur) var(--ease-standard) forwards;
  animation-delay: var(--t-hud-in);
}

@keyframes hud-visit {
  0%   { opacity: 0; transform: translate(-50%, 10px) scale(0.96); }
  6%   { opacity: 1; transform: translate(-50%, 0) scale(1); }
  92%  { opacity: 1; transform: translate(-50%, 0) scale(1); }
  100% { opacity: 0; transform: translate(-50%, 6px) scale(0.98); }
}

.hud .waveform {
  height: 16px;
  gap: 2px;
}

.hud .waveform span {
  width: 3px;
  animation: none;
}

.is-playing .hud .waveform span {
  animation: listen 700ms ease-in-out infinite alternate;
  animation-delay: calc(var(--t-hud-in) + var(--d));
}

.hud .waveform span:nth-child(1) { height: 7px;  --d: 0ms; }
.hud .waveform span:nth-child(2) { height: 12px; --d: 120ms; }
.hud .waveform span:nth-child(3) { height: 16px; --d: 240ms; }
.hud .waveform span:nth-child(4) { height: 11px; --d: 60ms; }
.hud .waveform span:nth-child(5) { height: 6px;  --d: 180ms; }

@keyframes listen {
  from { transform: scaleY(0.35); }
  to   { transform: scaleY(1); }
}

/* The timer's digits are written by the demo script while the HUD is
   up (see the script below); without JavaScript it reads 0:00. */
.hud-timer {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  color: var(--ink-muted);
}

/* ---- Scene: dictation into an email (hero) ---- */
.scene-dictate {
  --t-hud-in: 300ms;
  --t-hud-dur: 5200ms;
  --t-words: 1000ms;
  --t-word: 190ms;
  --caret-blinks: 6;
}

/* ---- Scene: the same key in three different apps ---- */
.scene-anywhere {
  --t-hud-in: 200ms;
  --t-hud-dur: 7600ms;
  --t-word: 150ms;
}

.apps {
  display: grid;
  gap: 10px;
}

.app {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: start;
}

.app-name {
  font-size: 0.8125rem;
  color: var(--ink-muted);
  font-weight: 500;
  min-width: 6.5em;
  padding-top: 9px;
}

.app-box {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: 0 1px 2px rgba(38, 37, 31, 0.06);
  padding: 9px 12px;
  font-size: 0.9375rem;
  min-height: 2.6em;
  line-height: 1.5;
}

.app-box.bubble {
  border-radius: var(--radius-lg);
  border-bottom-left-radius: 4px;
}

.app-box.search {
  border-radius: var(--radius-pill);
  display: flex;
  gap: 8px;
  align-items: center;
}

.app-box.search::before {
  content: "";
  width: 12px;
  height: 12px;
  border: 2px solid var(--ink-muted);
  border-radius: 50%;
  flex: none;
  box-shadow: 4px 4px 0 -2px var(--ink-muted);
  margin-right: 2px;
}

.app[data-slot="1"] { --t-words: 900ms; }
.app[data-slot="2"] { --t-words: 3300ms; }
.app[data-slot="3"] { --t-words: 5700ms; }

/* ---- Scene: read what you highlight ---- */
.scene-read {
  --t-select: 500ms;
  --t-select-dur: 900ms;
  --t-strip-in: 1500ms;
  --t-read: 1700ms;
  --t-sentence: 1500ms;
}

.article {
  padding: 16px 18px 20px;
  line-height: 1.6;
  font-size: 0.9375rem;
}

.article h4 {
  margin: 0 0 8px;
  font-size: 1rem;
  font-weight: 600;
}

.article p {
  max-width: none;
}

/* The selection sweeps across the paragraph left to right, top to
   bottom, the way a drag-select paints. */
.selectable {
  background-image: linear-gradient(var(--select-tint), var(--select-tint));
  background-repeat: no-repeat;
  background-size: 100% 100%;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

.is-playing .selectable {
  background-size: 0% 100%;
  animation: sweep var(--t-select-dur) var(--ease-standard) forwards;
  animation-delay: var(--t-select);
}

@keyframes sweep {
  from { background-size: 0% 100%; }
  to   { background-size: 100% 100%; }
}

/* Sentences light up one after another as they are spoken, and the
   finished state leaves the last one lit. */
.s {
  border-radius: 3px;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
  padding: 1px 0;
}

.s:last-child {
  background: var(--read-tint);
}

.is-playing .s {
  background: transparent;
  animation: speak var(--t-sentence) linear forwards;
  animation-delay: calc(var(--t-read) + var(--i) * var(--t-sentence));
}

.is-playing .s:last-child {
  animation-name: speak-last;
}

@keyframes speak {
  0%   { background: transparent; }
  4%   { background: var(--read-tint); }
  96%  { background: var(--read-tint); }
  100% { background: transparent; }
}

@keyframes speak-last {
  0%   { background: transparent; }
  4%   { background: var(--read-tint); }
  100% { background: var(--read-tint); }
}

/* The reader strip: the app's playback controls, as a card. */
.strip {
  position: absolute;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 14px 8px 10px;
  border-radius: var(--radius-pill);
  background: var(--surface-raised);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lifted);
  font-size: 0.8125rem;
  font-weight: 500;
  white-space: nowrap;
}

.is-playing .strip {
  opacity: 0;
  animation: strip-in 300ms var(--ease-standard) forwards;
  animation-delay: var(--t-strip-in);
}

@keyframes strip-in {
  from { opacity: 0; transform: translate(-50%, 10px); }
  to   { opacity: 1; transform: translate(-50%, 0); }
}

.strip-play {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--accent);
  display: grid;
  place-items: center;
  flex: none;
}

.strip-play::before {
  content: "";
  width: 3px;
  height: 11px;
  border-left: 3px solid var(--on-accent);
  border-right: 3px solid var(--on-accent);
}

.strip-meta {
  color: var(--ink-muted);
}

.strip-rate {
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  background: var(--accent-tint);
  color: var(--accent);
  font-family: var(--font-mono);
  letter-spacing: 0;
}

/* ---- Scene: read a picture of text ---- */
.scene-shot {
  --t-box: 500ms;
  --t-box-dur: 1600ms;
  --t-strip-in: 2000ms;
  --t-read: 2200ms;
  --t-sentence: 1500ms;
}

.photo {
  position: relative;
  margin: 0 auto;
  width: min(100%, 360px);
  transform: rotate(-1.6deg);
  background: #fffdf7;
  color: #2a2822;
  border-radius: 4px;
  padding: 18px 20px 22px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08), 0 14px 32px rgba(0, 0, 0, 0.16);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 0.9375rem;
  line-height: 1.55;
  letter-spacing: 0;
}

/* A grainy scan, so the card reads as a photo of paper, not a window. */
.photo::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    radial-gradient(120% 80% at 80% 0%, rgba(0, 0, 0, 0.05), transparent 60%),
    repeating-linear-gradient(
      0deg,
      rgba(0, 0, 0, 0.012) 0 2px,
      transparent 2px 4px
    );
  pointer-events: none;
}

.photo-head {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  color: #6f6a5f;
  border-bottom: 1px solid #ddd6c6;
  padding-bottom: 6px;
  margin-bottom: 10px;
}

.photo .s:last-child {
  background: var(--read-tint);
}

/* The drag box, drawn from the top-left corner outwards. While it is
   being dragged the rest of the screen dims, as the app's capture
   overlay does; once the box is set the dim lifts and only the outline
   stays, which is also the finished state. */
.box {
  position: absolute;
  inset: 8px;
  border: 2px solid var(--accent);
  border-radius: 4px;
  box-shadow: 0 0 0 9999px rgba(38, 37, 31, 0);
  pointer-events: none;
  transform-origin: top left;
}

.box::after {
  /* The cursor, riding the bottom-right corner. */
  content: "";
  position: absolute;
  right: -14px;
  bottom: -14px;
  width: 14px;
  height: 14px;
  border-left: 2px solid var(--ink);
  border-top: 2px solid var(--ink);
  background: var(--surface-raised);
  opacity: 0;
}

.is-playing .box {
  opacity: 0;
  transform: scale(0.08, 0.1);
  animation: drag var(--t-box-dur) var(--ease-standard) forwards;
  animation-delay: var(--t-box);
}

.is-playing .box::after {
  animation: cursor-show var(--t-box-dur) steps(1) forwards;
  animation-delay: var(--t-box);
}

@keyframes drag {
  0%   { opacity: 0; transform: scale(0.08, 0.1); box-shadow: 0 0 0 9999px rgba(38, 37, 31, 0.28); }
  6%   { opacity: 1; transform: scale(0.08, 0.1); box-shadow: 0 0 0 9999px rgba(38, 37, 31, 0.28); }
  70%  { opacity: 1; transform: scale(1, 1);      box-shadow: 0 0 0 9999px rgba(38, 37, 31, 0.28); }
  100% { opacity: 1; transform: scale(1, 1);      box-shadow: 0 0 0 9999px rgba(38, 37, 31, 0); }
}

@keyframes cursor-show {
  0%   { opacity: 1; }
  72%  { opacity: 1; }
  73%  { opacity: 0; }
  100% { opacity: 0; }
}

/* ---------------- Reveal on scroll ----------------
   Only chapter text and photographs, only once, and only when the
   script has confirmed motion is welcome: without it (or with reduced
   motion) everything is simply visible. */
.has-motion .reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 600ms var(--ease-standard), transform 600ms var(--ease-standard);
}

.has-motion .reveal.is-in {
  opacity: 1;
  transform: none;
}

/* ---------------- Marquee: where it works ----------------
   Names of the places people type, drifting slowly. No logos: these
   are other companies' marks and the page has no licence to them. */
.works-in {
  padding-block: var(--space-5) var(--space-7);
}

.works-in-label {
  font-size: 0.9375rem;
  color: var(--ink-muted);
  margin-bottom: var(--space-4);
}

.marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.marquee-track {
  display: flex;
  gap: var(--space-3);
  width: max-content;
}

.has-motion .marquee-track {
  animation: drift 46s linear infinite;
}

.marquee:hover .marquee-track {
  animation-play-state: paused;
}

@keyframes drift {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

.chip {
  flex: none;
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  background: var(--surface-raised);
  border: 1px solid var(--border);
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--ink);
  white-space: nowrap;
}

/* ---------------- Photographs ---------------- */
.photo-frame {
  margin: 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--photo-shadow);
  background: var(--desk);
}

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

/* ---------------- Who it is for: three photographs ---------------- */
.audience {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-6) var(--space-5);
}

.audience .photo-frame {
  aspect-ratio: 3 / 2;
}

.audience-text {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--space-3);
  align-items: start;
  margin-top: var(--space-4);
}

.audience-text b {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.0625rem;
}

.audience-text p {
  margin-top: 2px;
  color: var(--ink-muted);
  font-size: 0.9375rem;
}

/* ---------------- Privacy: photo beside the promises ---------------- */
.privacy {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr);
  gap: var(--space-6) var(--space-7);
  align-items: center;
}

.privacy .photo-frame {
  aspect-ratio: 4 / 5;
}

/* Small glyphs drawn inline: a page, a briefcase, two figures. */
.glyph {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--accent-tint);
  color: var(--accent);
  display: grid;
  place-items: center;
  flex: none;
}

.glyph svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------------- Section rhythm ---------------- */
.section {
  padding-block: var(--space-8);
  border-top: 1px solid var(--border);
}

.section-head {
  max-width: 60ch;
  margin-bottom: var(--space-7);
}

.section-head h2 {
  font-size: clamp(1.625rem, 3.2vw, 2.25rem);
  line-height: 1.2;
}

.section-head p {
  margin-top: var(--space-4);
  color: var(--ink-muted);
  font-size: 1.0625rem;
}

.section-note {
  margin-bottom: var(--space-5);
  color: var(--ink-muted);
  font-size: 0.9375rem;
}

/* ---------------- Chapters: one per job ---------------- */
.chapter {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: var(--space-6) var(--space-7);
  align-items: center;
}

.chapter + .chapter {
  margin-top: var(--space-8);
}

.chapter h3 {
  font-size: clamp(1.375rem, 2.4vw, 1.75rem);
  line-height: 1.22;
}

.chapter p {
  margin-top: var(--space-4);
  color: var(--ink-muted);
  max-width: 42ch;
}

/* ---------------- Three words ---------------- */
.triplet {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-6) var(--space-7);
}

.triplet h3 {
  font-size: 1.375rem;
  margin-top: var(--space-4);
}

.triplet p {
  margin-top: var(--space-3);
  color: var(--ink-muted);
}

/* ---------------- Story ---------------- */
.story {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: var(--space-6) var(--space-7);
  align-items: start;
}

.story-aside .photo-frame {
  aspect-ratio: 4 / 3;
  margin-bottom: var(--space-5);
}

.story p + p {
  margin-top: var(--space-4);
}

.story-aside {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
}

.story-aside h3 {
  font-size: 1.125rem;
}

.story-aside p {
  margin-top: var(--space-3);
  color: var(--ink-muted);
  font-size: 0.9375rem;
}

.story-aside .button {
  margin-top: var(--space-4);
}

/* ---------------- Privacy ---------------- */
.promises {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-5) var(--space-6);
}

.promises li {
  padding-left: var(--space-5);
  position: relative;
}

.promises li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
}

.promises b {
  display: block;
  font-weight: 600;
  font-family: var(--font-display);
  font-size: 1.0625rem;
}

.promises p {
  margin-top: 4px;
  color: var(--ink-muted);
  font-size: 0.9375rem;
}

/* ---------------- Expected pricing ----------------
   Two plain tables (personal, institutions) side by side on a wide
   screen, stacked on a narrow one. The licence calculator is hidden until
   landing.js arms it, so without JavaScript the tables still say it all. */
.pricing {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-6);
  align-items: start;
}

.pricing-group {
  display: grid;
  gap: var(--space-5);
  justify-items: start;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  background: var(--surface-raised);
}

.pricing-group h3 {
  font-size: 1.25rem;
}

.price-table-wrap {
  width: 100%;
  overflow-x: auto;
}

.price-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
  text-align: left;
}

.price-table th,
.price-table td {
  padding: var(--space-3) var(--space-3) var(--space-3) 0;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

.price-table thead th {
  color: var(--ink-muted);
  font-weight: 500;
  font-size: 0.875rem;
}

.price-table tbody th {
  font-family: var(--font-display);
  font-weight: 600;
}

.price-cell {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.125rem;
  white-space: nowrap;
}

.price-sub {
  display: block;
  color: var(--ink-muted);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.8125rem;
}

.pricing-note {
  color: var(--ink-muted);
  font-size: 0.9375rem;
}

.planned {
  width: 100%;
  border-radius: var(--radius-md);
  background: var(--scrim);
  padding: var(--space-4);
}

.planned-label {
  display: inline-block;
  padding: 2px 10px;
  border-radius: var(--radius-pill);
  background: var(--warning-tint);
  color: var(--warning);
  font-size: 0.8125rem;
  font-weight: 600;
}

.planned-intro {
  margin-top: var(--space-2);
  color: var(--ink-muted);
  font-size: 0.9375rem;
}

.planned ul {
  margin: var(--space-3) 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: var(--space-2);
  font-size: 0.9375rem;
}

.planned li {
  padding-left: 22px;
  position: relative;
}

.planned li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.5em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: 2px solid var(--accent);
}

.calc {
  width: 100%;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  padding: var(--space-4);
}

.calc[hidden] {
  display: none;
}

.calc h4 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 600;
}

.calc-help,
.calc-small {
  margin-top: var(--space-1);
  color: var(--ink-muted);
  font-size: 0.875rem;
}

.calc-row {
  margin-top: var(--space-3);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.calc-step {
  width: 44px;
  height: 44px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface-raised);
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.375rem;
  line-height: 1;
  cursor: pointer;
}

.calc-step:hover {
  background: var(--scrim);
}

.calc-step:disabled {
  opacity: 0.4;
  cursor: default;
}

.calc-field input {
  width: 6.5em;
  height: 44px;
  padding: 0 var(--space-3);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface-raised);
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 600;
  text-align: center;
}

.calc-field input[aria-invalid="true"] {
  border-color: var(--warning);
}

.calc-unit {
  color: var(--ink-muted);
}

.calc-result {
  margin-top: var(--space-3);
  font-size: 1rem;
}

.calc-result b {
  font-family: var(--font-display);
  font-size: 1.375rem;
}

.calc-result.is-invalid {
  color: var(--warning);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ---------------- Questions ----------------
   The heading sits in its own column so the questions line up as one
   block on the right instead of hanging off a short heading. */
.questions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.7fr);
  gap: var(--space-5) var(--space-7);
  align-items: start;
}

.questions .section-head {
  margin-bottom: 0;
}

.faq {
  border-top: 1px solid var(--border);
}

.faq details {
  border-bottom: 1px solid var(--border);
}

.faq summary {
  cursor: pointer;
  list-style: none;
  padding-block: var(--space-4);
  padding-right: var(--space-2);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.0625rem;
  display: flex;
  justify-content: space-between;
  gap: var(--space-4);
  align-items: center;
}

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

.faq summary::after {
  /* A plus that becomes a minus when the answer is open. */
  content: "";
  flex: none;
  width: 14px;
  height: 14px;
  margin-right: 2px;
  background:
    linear-gradient(var(--ink-muted), var(--ink-muted)) center / 14px 2px no-repeat,
    linear-gradient(var(--ink-muted), var(--ink-muted)) center / 2px 14px no-repeat;
}

.faq details[open] summary::after {
  background:
    linear-gradient(var(--ink-muted), var(--ink-muted)) center / 14px 2px no-repeat;
}

.faq details p {
  color: var(--ink-muted);
  padding-bottom: var(--space-4);
}

.faq details p + p {
  margin-top: calc(var(--space-3) * -1 + var(--space-4));
}

.faq details p {
  max-width: 56ch;
}

/* ---------------- Closing call ---------------- */
.cta-band {
  border-top: 1px solid var(--border);
  padding-block: var(--space-8);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: var(--space-5) var(--space-7);
  align-items: center;
}

.cta-band h2 {
  font-size: clamp(1.625rem, 3.2vw, 2.25rem);
  line-height: 1.2;
}

.cta-band p {
  margin-top: var(--space-3);
  color: var(--ink-muted);
}

.cta-band .button {
  font-size: 1.125rem;
  padding: 16px 28px;
}

/* ---------------- Download page ---------------- */
.page-head {
  padding-block: clamp(var(--space-5), 4vw, var(--space-7)) var(--space-4);
  max-width: 60ch;
}

.page-head h1 {
  font-size: clamp(2rem, 4.6vw, 2.75rem);
  line-height: 1.14;
}

.page-head p {
  margin-top: var(--space-4);
  color: var(--ink-muted);
  font-size: 1.0625rem;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--ink-muted);
  text-decoration: none;
  margin-top: var(--space-5);
}

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

/* ---------------- Download ---------------- */
.picker {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lifted);
  padding: clamp(var(--space-5), 3.5vw, var(--space-6));
  margin-block: var(--space-5) var(--space-6);
}

.picker-heading {
  font-size: 1.375rem;
  line-height: 1.25;
}

.picker-sub {
  margin-top: var(--space-2);
  color: var(--ink-muted);
  font-size: 0.9375rem;
}

.picker-action {
  margin-top: var(--space-5);
}

.download-button {
  max-width: 100%;
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  padding: 16px 28px;
  border: none;
  border-radius: var(--radius-md);
  background: var(--accent);
  color: var(--on-accent);
  font-family: var(--font-display);
  font-size: 1.1875rem;
  font-weight: 600;
  letter-spacing: var(--tracking);
  text-decoration: none;
  cursor: pointer;
  transition: filter var(--motion-fast) var(--ease-standard);
}

.download-button:hover {
  filter: brightness(1.06);
}

.download-button:active {
  filter: brightness(0.95);
}

.download-button-meta {
  /* A long file name wraps instead of pushing the page sideways on a phone. */
  overflow-wrap: anywhere;
  max-width: 100%;
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  font-weight: 400;
  opacity: 0.86;
  letter-spacing: 0;
}

.download-blocked {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  padding: 16px 28px;
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-md);
  background: var(--scrim);
  color: var(--ink-muted);
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 600;
}

.download-blocked-meta {
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 400;
}

.variant-row {
  margin-top: var(--space-5);
  padding-top: var(--space-4);
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--space-2) var(--space-3);
  font-size: 0.9375rem;
  color: var(--ink-muted);
}

.variant-row-label {
  margin: 0;
}

.pill-button {
  appearance: none;
  border: 1px solid var(--border-strong);
  background: transparent;
  color: var(--ink);
  font-family: inherit;
  font-size: 0.9375rem;
  letter-spacing: var(--tracking);
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: background var(--motion-fast) var(--ease-standard),
    border-color var(--motion-fast) var(--ease-standard);
}

.pill-button:hover {
  background: var(--scrim);
}

.pill-button[aria-pressed="true"] {
  background: var(--accent-tint);
  border-color: transparent;
  color: var(--accent);
  font-weight: 500;
}

.picker-help {
  margin-top: var(--space-4);
  font-size: 0.875rem;
  color: var(--ink-muted);
  max-width: 58ch;
}

.notice {
  margin-top: var(--space-5);
  padding: var(--space-4);
  border-radius: var(--radius-md);
  background: var(--warning-tint);
  color: var(--ink);
  font-size: 0.9375rem;
}

.notice strong {
  font-weight: 600;
}

.subsection {
  padding-block: var(--space-6);
  border-top: 1px solid var(--border);
}

.subsection > h3 {
  font-size: 1.375rem;
  margin-bottom: var(--space-5);
}

/* Numbered, because installing genuinely is a sequence. */
.steps {
  list-style: none;
  counter-reset: step;
  margin: 0;
  padding: 0;
  max-width: 60ch;
}

.steps li {
  counter-increment: step;
  position: relative;
  padding-left: 3rem;
  padding-block: var(--space-3);
}

.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: var(--space-3);
  width: 2rem;
  height: 2rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--accent-tint);
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.875rem;
  font-weight: 600;
}

.steps li p {
  color: var(--ink-muted);
  font-size: 0.9375rem;
  margin-top: 4px;
}

/* ---------------- All downloads: every live installer ---------------- */
.download-list-sub {
  margin-top: calc(-1 * var(--space-3));
  margin-bottom: var(--space-4);
  color: var(--ink-muted);
  font-size: 0.9375rem;
}

.download-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
}

.download-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3) var(--space-5);
  padding: var(--space-4) 0;
}

.download-item + .download-item {
  border-top: 1px solid var(--border);
}

.download-item-text {
  display: grid;
  gap: 2px;
  min-width: 0;
  flex: 1 1 26ch;
}

.download-item-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.0625rem;
}

.download-item-meta {
  color: var(--ink-muted);
  font-size: 0.9375rem;
}

.download-item-file {
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  color: var(--ink-muted);
  overflow-wrap: anywhere;
}

.download-item-link {
  display: inline-flex;
  align-items: center;
  padding: 8px 18px;
  border: 1px solid var(--accent);
  border-radius: var(--radius-pill);
  color: var(--accent);
  font-weight: 600;
  font-size: 0.9375rem;
  text-decoration: none;
  white-space: nowrap;
  transition: background var(--motion-fast) var(--ease-standard);
}

.download-item-link:hover {
  background: var(--accent-tint);
}

/* ---------------- Platform status ---------------- */
.platform-list {
  display: grid;
  gap: var(--space-4);
}

.platform-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3) var(--space-4);
  padding: var(--space-4) 0;
}

.platform-row + .platform-row {
  border-top: 1px solid var(--border);
}

.platform-row-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.0625rem;
  min-width: 9rem;
}

.platform-row-note {
  color: var(--ink-muted);
  font-size: 0.9375rem;
  flex: 1 1 22ch;
  margin: 0;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8125rem;
  font-weight: 500;
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  background: var(--scrim);
  color: var(--ink-muted);
  white-space: nowrap;
}

.status-badge[data-status="preview"] {
  background: var(--warning-tint);
  color: var(--warning);
}

.status-badge[data-status="available"] {
  background: var(--accent-tint);
  color: var(--accent);
}

/* ---------------- Footer: the DyslexicAid band ----------------
   Full-bleed navy, matching the parent site's own footer background.
   This is where the maker's brand gets its proper billing. */
.footer {
  background: var(--da-navy);
  color: #ffffff;
  margin-top: var(--space-6);
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}

.footer-inner {
  width: min(100% - 2.5rem, 66rem);
  margin-inline: auto;
  padding-block: 40px 48px;
  display: grid;
  gap: var(--space-5);
}

.footer-maker {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--space-2) var(--space-3);
}

.footer-maker-lede {
  color: var(--da-ice);
  font-size: 0.9375rem;
  margin: 0;
}

.footer-brand {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.25rem;
  color: #ffffff;
  text-decoration: none;
  letter-spacing: 0.2px;
}

.footer-brand:hover {
  text-decoration: underline;
}

.footer p {
  color: var(--da-ice);
  font-size: 0.875rem;
  max-width: 64ch;
}

.footer a:not(.footer-brand) {
  color: #ffffff;
}

.footer :focus-visible {
  outline-color: var(--da-ice);
}

.footer-rule {
  height: 1px;
  background: rgba(255, 255, 255, 0.16);
}

/* ---------------- Responsive ---------------- */
@media (max-width: 56rem) {
  .hero,
  .chapter,
  .story,
  .privacy,
  .questions,
  .cta-band {
    grid-template-columns: 1fr;
  }

  .cta-band {
    padding-block: var(--space-7);
  }

  .audience {
    grid-template-columns: 1fr;
    max-width: 34rem;
  }

  .privacy .photo-frame {
    aspect-ratio: 3 / 2;
  }

  .hero {
    padding-bottom: var(--space-7);
  }

  .hero h1 {
    max-width: 16ch;
    font-size: clamp(2rem, 9vw, 2.75rem);
  }

  .chapter-demo {
    order: 2;
  }

  .triplet {
    grid-template-columns: 1fr;
    gap: var(--space-6);
  }

  .section {
    padding-block: var(--space-7);
  }

  .chapter + .chapter {
    margin-top: var(--space-7);
  }
}

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

@media (max-width: 40rem) {
  body {
    font-size: 16px;
  }

  .nav {
    display: none;
  }

  .masthead {
    padding-block: var(--space-4);
  }

  /* The hero's own "Register your interest" sits just below, so the
     masthead copy would only crowd the wordmark on a phone. */
  .masthead-right .button {
    display: none;
  }

  .promises,
  .pricing {
    grid-template-columns: 1fr;
  }

  /* Each price row becomes a small block: name and price on one line,
     what it includes underneath, so nothing is squeezed into a column
     a word wide. The column headings stay for screen readers. */
  .price-table thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }

  .price-table tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    column-gap: var(--space-4);
    padding-block: var(--space-3);
    border-bottom: 1px solid var(--border);
  }

  .price-table th,
  .price-table td {
    padding: 0;
    border: 0;
  }

  .price-table .price-cell {
    text-align: right;
  }

  .price-table td:last-child {
    grid-column: 1 / -1;
    margin-top: var(--space-2);
    color: var(--ink-muted);
  }

  .calc-field input {
    width: 5em;
  }

  .download-button,
  .download-blocked,
  .hero-actions .button {
    width: 100%;
    justify-content: center;
  }

  .scene {
    min-height: 0;
    padding: 14px;
  }

  .app-name {
    min-width: 5.5em;
  }
}

@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;
  }

  /* The scenes jump straight to their finished state: nothing on the
     page moves. */
  .is-playing .hud,
  .is-playing .strip {
    animation: none;
    opacity: 1;
  }
}
