/* leadphrase.com — the only stylesheet (structure ported from the TrailBivvy website, docs/WEBSITE.md).
   Palette from the app (LeadPhrase/DesignSystem/Theme.swift): navy ink and gold, navy hero with a gold glow, the code
   colour families. Type: Inter for everything, Newsreader (serif) only for the words you'd actually say, as in the app.
   Both fonts are self-hosted (SIL OFL). Contrast of the colour-token pairs is checked by scripts/website/check_site.py. */

@font-face {
  font-family: "Inter";
  src: url("fonts/inter-var.c940764593.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Newsreader";
  src: url("fonts/newsreader-var.01817351be.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Newsreader";
  src: url("fonts/newsreader-italic-var.a99fb12768.woff2") format("woff2");
  font-weight: 200 800;
  font-style: italic;
  font-display: swap;
}

:root {
  color-scheme: light dark;
  --c-bg: #F3F4F8;
  --c-surface: #FFFFFF;
  --c-surface-alt: #EBEEF4;
  --c-text: #141B2B;
  --c-text-muted: #5D6474;
  --c-border: #E1E5EE;
  --c-border-strong: #A9B1C2;
  --c-accent: #1A325A;
  --c-accent-hover: #24467A;
  --c-on-accent: #FFFFFF;
  --c-accent-soft: #DCE4F3;
  --c-gold: #A2752B;
  --c-gold-text: #84601F;
  --c-focus: #24467A;
  --c-cta-top: #24467A;
  --c-cta-bottom: #132A4F;
  --c-on-cta: #FFFFFF;
  --c-pill-fg: #6E4E14;
  --c-pill-bg: #F5EAD3;
  --c-issue: #B43E33;
  --c-issue-soft: #F8E2DF;
  --c-positive: #23855A;
  /* The code colour families (Theme.Colors.code): as text on white surfaces, as markers elsewhere */
  --c-fam-context: #22807B;
  --c-fam-action: #4D4FC0;
  --c-fam-benefit: #A2660E;
  --c-fam-ask: #1A325A;
  --c-fam-positive: #23855A;
  --c-fam-context-soft: #D9EFED;
  --c-fam-action-soft: #E3E4F8;
  --c-fam-benefit-soft: #F6E8D2;
  --c-fam-ask-soft: #DCE4F3;
  --c-fam-positive-soft: #DAF0E4;
  /* The hero: navy in both appearances, as in the app icon */
  --c-hero-top: #0D1F3D;
  --c-hero-bottom: #23477F;
  --c-hero-glow: #E9C988;
  --c-on-hero: #FFFFFF;
  --c-on-hero-muted: #C9D3E6;
  --c-hero-gold: #E9C988;
  --c-hero-pill-bg: #142B52;
  --c-hero-pill-fg: #F0D394;
  --c-gold-cta-top: #F0D394;
  --c-gold-cta-bottom: #D9AE5F;
  --c-on-gold: #0B1B36;
  --c-bezel: #0B0D12;
  --c-screen: #F3F4F8;
  --shadow-lg: 0 28px 60px -24px rgba(17, 31, 61, 0.42), 0 0 0 1px rgba(17, 31, 61, 0.06);
  --shadow-sm: 0 1px 2px rgba(17, 31, 61, 0.06), 0 8px 24px -16px rgba(17, 31, 61, 0.18);

  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, Roboto, "Helvetica Neue", Arial,
    sans-serif;
  --font-serif: "Newsreader", "New York", ui-serif, Georgia, "Times New Roman", serif;
  --radius: 1.125rem;
  --radius-sm: 0.75rem;
  --gutter: clamp(1rem, 4vw, 2.5rem);
  --measure: 70ch;
}

@media (prefers-color-scheme: dark) {
  :root {
    --c-bg: #0A0C11;
    --c-surface: #1B1E25;
    --c-surface-alt: #262A33;
    --c-text: #E8ECF3;
    --c-text-muted: #9FA9BC;
    --c-border: #2E3340;
    --c-border-strong: #535C70;
    --c-accent: #A9C4F0;
    --c-accent-hover: #C6D8F5;
    --c-on-accent: #0B1B36;
    --c-accent-soft: #14264A;
    --c-gold: #E6C27F;
    --c-gold-text: #E6C27F;
    --c-focus: #E6C27F;
    --c-cta-top: #F0D394;
    --c-cta-bottom: #D9AE5F;
    --c-on-cta: #0B1B36;
    --c-pill-fg: #F0D394;
    --c-pill-bg: #2E2614;
    --c-issue: #F4897D;
    --c-issue-soft: #3A1D1A;
    --c-positive: #6FD6A2;
    --c-fam-context: #6CCFC8;
    --c-fam-action: #A9ABF7;
    --c-fam-benefit: #F0C36B;
    --c-fam-ask: #A9C4F0;
    --c-fam-positive: #6FD6A2;
    --c-fam-context-soft: #133230;
    --c-fam-action-soft: #22244A;
    --c-fam-benefit-soft: #352A12;
    --c-fam-ask-soft: #14264A;
    --c-fam-positive-soft: #133526;
    --c-hero-top: #0B1A34;
    --c-hero-bottom: #213F72;
    --c-bezel: #000000;
    --c-screen: #0A0C11;
    --shadow-lg: 0 28px 60px -24px rgba(0, 0, 0, 0.75), 0 0 0 1px rgba(255, 255, 255, 0.06);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
  }
}

/* ---------- Base ---------- */

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

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

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--c-bg);
  color: var(--c-text);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  font-feature-settings: "cv11", "ss01";
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
}

img, svg, video { display: block; max-width: 100%; }
img { height: auto; }

h1, h2, h3 {
  line-height: 1.15;
  margin: 0 0 0.6em;
  letter-spacing: -0.02em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.1rem, 1.5rem + 2.6vw, 3.25rem); font-weight: 780; }
h2 { font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.4rem); font-weight: 750; }
h3 { font-size: 1.1875rem; font-weight: 680; letter-spacing: -0.01em; }

p, ul, ol, dl, table, figure, blockquote, address { margin: 0 0 1rem; }
p { text-wrap: pretty; }
ul, ol { padding-inline-start: 1.25rem; }
li + li { margin-top: 0.35rem; }
strong { font-weight: 650; }

a {
  color: var(--c-accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}
a:hover { color: var(--c-accent-hover); text-decoration-thickness: 2px; }

kbd {
  display: inline-block;
  min-width: 1.6em;
  padding: 0.05em 0.4em;
  border: 1px solid var(--c-border-strong);
  border-bottom-width: 2px;
  border-radius: 0.35rem;
  background: var(--c-surface);
  color: var(--c-text);
  font-family: var(--font);
  font-size: 0.875em;
  font-weight: 600;
  line-height: 1.4;
  text-align: center;
  white-space: nowrap;
}

:focus-visible {
  outline: 3px solid var(--c-focus);
  outline-offset: 3px;
  border-radius: 4px;
}
main:focus { outline: none; }

::selection { background: var(--c-accent-soft); color: var(--c-text); }

.container {
  width: 100%;
  max-width: calc(72rem + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.container.narrow { max-width: calc(48rem + 2 * var(--gutter)); }

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

.skip-link {
  position: absolute;
  inset-inline-start: 1rem;
  top: 0.75rem;
  z-index: 10;
  padding: 0.6rem 1rem;
  border-radius: var(--radius-sm);
  background: var(--c-accent);
  color: var(--c-on-accent);
  font-weight: 650;
  text-decoration: none;
  transform: translateY(-200%);
}
.skip-link:focus { transform: none; color: var(--c-on-accent); }

.icon { width: 1.5rem; height: 1.5rem; flex: none; }

/* ---------- Header ---------- */

.site-header {
  border-bottom: 1px solid var(--c-border);
  background: var(--c-bg);
}
.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem 1.25rem;
  min-height: 4rem;
  padding-block: 0.5rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  min-height: 2.75rem;
  margin-inline-end: auto;
  color: var(--c-text);
  font-weight: 750;
  font-size: 1.125rem;
  text-decoration: none;
  letter-spacing: -0.015em;
}
.brand:hover { color: var(--c-text); }
.brand-icon { width: 2rem; height: 2rem; border-radius: 0.5rem; }
.site-nav ul {
  display: flex;
  flex-wrap: nowrap;
  gap: 0.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.site-nav li + li { margin: 0; }
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-sm);
  color: var(--c-text);
  font-weight: 560;
  font-size: 0.975rem;
  text-decoration: none;
  white-space: nowrap;
}
.site-nav a:hover { background: var(--c-surface-alt); color: var(--c-text); }
.site-nav a[aria-current="page"] {
  color: var(--c-accent);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.35em;
}
.lang-switch {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.75rem;
  min-height: 2.75rem;
  padding: 0.35rem 0.75rem;
  border: 1px solid var(--c-border-strong);
  border-radius: 999px;
  color: var(--c-text);
  font-size: 0.9rem;
  font-weight: 620;
  text-decoration: none;
}
.lang-switch:hover { background: var(--c-surface-alt); color: var(--c-text); }
.lang-short { display: none; }
/* Narrow screens: brand and language on the first row, the four links on one row below (never wrapped, down to
   320 px in both languages; scripts/website/check_site.py and the screenshots check it). */
@media (max-width: 759px) {
  .header-inner { gap: 0 0.5rem; padding-block: 0.35rem 0.25rem; }
  .site-nav { order: 3; flex-basis: 100%; margin-inline: -0.5rem; }
  .lang-long { display: none; }
  .lang-short { display: inline; }
  .lang-switch { padding-inline: 0.6rem; }
}
@media (max-width: 420px) {
  .site-nav ul { gap: 0; }
  .site-nav a { padding-inline: 0.5rem; }
}
@media (max-width: 360px) {
  .site-nav a { padding-inline: 0.4rem; font-size: 0.9rem; }
}

/* ---------- Buttons, pills, notices ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 2.875rem;
  padding: 0.65rem 1.25rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font-weight: 650;
  font-size: 1rem;
  line-height: 1.2;
  text-decoration: none;
  transition: background-color 0.15s ease, border-color 0.15s ease, filter 0.15s ease;
}
.btn-primary {
  background: linear-gradient(180deg, var(--c-cta-top), var(--c-cta-bottom));
  color: var(--c-on-cta);
}
.btn-primary:hover { color: var(--c-on-cta); filter: brightness(1.08); text-decoration: none; }
.btn-secondary { background: var(--c-surface); color: var(--c-text); border-color: var(--c-border-strong); }
.btn-secondary:hover { background: var(--c-surface-alt); color: var(--c-text); text-decoration: none; }

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  margin: 0 0 1rem;
  padding: 0.45rem 0.95rem;
  border-radius: 999px;
  background: var(--c-pill-bg);
  color: var(--c-pill-fg);
  font-size: 0.9rem;
  font-weight: 650;
  line-height: 1.3;
}
.status-dot {
  flex: none;
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: currentColor;
}
.store-badge { display: inline-block; margin-bottom: 1rem; }
.store-badge img { height: 3.25rem; width: auto; }

.notice {
  padding: 0.9rem 1.1rem;
  border-inline-start: 4px solid var(--c-gold);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: var(--c-surface-alt);
}

.fine { color: var(--c-text-muted); font-size: 0.9375rem; }
.meta { color: var(--c-text-muted); font-size: 0.9375rem; }
.lead { color: var(--c-text-muted); font-size: clamp(1.0625rem, 1rem + 0.35vw, 1.25rem); line-height: 1.55; max-width: 62ch; }
.label {
  margin: 0 0 0.4rem;
  color: var(--c-text-muted);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.eyebrow {
  margin: 0 0 0.6rem;
  color: var(--c-gold-text);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
/* Apple product names keep their capitalisation (iPhone, iPad): no upper-case transform */
.eyebrow-names { text-transform: none; letter-spacing: 0.01em; font-size: 0.9375rem; }
.check-list { margin: 0 0 1rem; padding: 0; list-style: none; }
.check-list li { display: flex; gap: 0.6rem; align-items: flex-start; }
.check-list li + li { margin-top: 0.55rem; }
.check-list .icon { width: 1.2rem; height: 1.2rem; margin-top: 0.2rem; color: var(--c-positive); }

/* ---------- Promo (opens the home page) and hero: one navy band ---------- */

.hero-promo,
.hero {
  position: relative;
  color: var(--c-on-hero);
  background-color: var(--c-hero-top);
  isolation: isolate;
}
.hero-promo {
  padding-block: clamp(0.75rem, 2vw, 1.5rem) clamp(1rem, 2.5vw, 1.75rem);
  background: var(--c-hero-top);
}
.hero {
  overflow: hidden;
  padding-block: clamp(2.5rem, 7vw, 5.5rem);
  background:
    radial-gradient(42rem 26rem at 88% 8%, rgba(233, 201, 136, 0.26), transparent 70%),
    radial-gradient(34rem 24rem at 0% 100%, rgba(109, 127, 214, 0.18), transparent 70%),
    linear-gradient(160deg, var(--c-hero-top), var(--c-hero-bottom));
}
.hero-after-promo {
  padding-top: clamp(1.5rem, 4vw, 3rem);
  background:
    radial-gradient(40rem 26rem at 90% 45%, rgba(233, 201, 136, 0.22), transparent 70%),
    radial-gradient(34rem 24rem at 0% 100%, rgba(109, 127, 214, 0.18), transparent 70%),
    linear-gradient(180deg, var(--c-hero-top), var(--c-hero-bottom));
}
.hero a:not(.btn) { color: var(--c-on-hero); }
.hero .eyebrow { color: var(--c-hero-gold); }
.hero-grid {
  display: grid;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
@media (min-width: 900px) {
  .hero-grid { grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); }
}
.hero-title {
  margin-bottom: 1.25rem;
  font-size: clamp(2.5rem, 1.6rem + 4.2vw, 4.6rem);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -0.035em;
}
.hero-title em { font-style: normal; color: var(--c-hero-gold); }
.hero-kicker {
  display: block;
  margin-bottom: 0.6rem;
  color: var(--c-on-hero-muted);
  font-size: clamp(1.25rem, 1rem + 1.1vw, 1.75rem);
  font-weight: 650;
  line-height: 1.3;
  letter-spacing: -0.015em;
}
.hero-slogan {
  margin-bottom: 0.6rem;
  font-size: clamp(1.2rem, 1.05rem + 0.8vw, 1.55rem);
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -0.01em;
}
.hero-signoff {
  margin-bottom: 1.25rem;
  color: var(--c-hero-gold);
  font-weight: 650;
}
.hero-lead {
  max-width: 38rem;
  margin-bottom: 1.5rem;
  color: var(--c-on-hero-muted);
  font-size: clamp(1.0625rem, 1rem + 0.45vw, 1.3125rem);
  line-height: 1.55;
}
.hero .status-pill { background: var(--c-hero-pill-bg); color: var(--c-hero-pill-fg); box-shadow: inset 0 0 0 1px rgba(240, 211, 148, 0.35); }
.trust {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.25rem;
  margin: 0 0 1.5rem;
  padding: 0;
  list-style: none;
  color: var(--c-on-hero-muted);
  font-size: 0.9375rem;
}
.trust li { display: inline-flex; align-items: center; gap: 0.4rem; margin: 0; }
.trust .icon { width: 1.1rem; height: 1.1rem; color: var(--c-hero-gold); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin: 0; }
.hero .btn-primary,
.final .btn-primary {
  background: linear-gradient(180deg, var(--c-gold-cta-top), var(--c-gold-cta-bottom));
  color: var(--c-on-gold);
}
.hero .btn-secondary {
  background: transparent;
  color: var(--c-on-hero);
  border-color: rgba(255, 255, 255, 0.45);
}
.hero .btn-secondary:hover { background: rgba(255, 255, 255, 0.1); }
.hero-visual { position: relative; display: flex; justify-content: center; }
.hero-visual::before {
  content: "";
  position: absolute;
  inset: 6% 8%;
  z-index: -1;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(233, 201, 136, 0.34), transparent);
  filter: blur(18px);
}
.phone-hero { width: min(18.5rem, 76vw); }
.hero .video-flag { color: var(--c-on-hero-muted); }
.hero .video-toggle { border-color: rgba(255, 255, 255, 0.4); background: rgba(255, 255, 255, 0.08); color: var(--c-on-hero); }
.hero .video-toggle:hover { background: rgba(255, 255, 255, 0.16); }

/* The promo: the whole video fits the first screen under the header (16:9 from 700 px, 9:16 below; one <video>
   each, the other hidden by CSS so it never loads). static/site.js plays it muted while it is on screen, with a
   pause button; with reduced motion, Save-Data or no JavaScript it shows its poster and a play link to the MP4. */
.promo { margin: 0; }
.promo-frame {
  position: relative;
  width: min(100%, calc((100vh - 8.5rem) * 16 / 9));
  width: min(100%, calc((100svh - 8.5rem) * 16 / 9));
  margin-inline: auto;
  overflow: hidden;
  border-radius: var(--radius);
  background: #071226;
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(255, 255, 255, 0.08);
}
@media (min-width: 700px) {
  .promo-tall { display: none !important; }
}
@media (max-width: 699px) {
  .promo-wide { display: none !important; }
  /* the header takes two rows here (about 6.5rem) */
  .promo-frame {
    width: min(100%, 22rem, calc((100vh - 10.5rem) * 9 / 16));
    width: min(100%, 22rem, calc((100svh - 10.5rem) * 9 / 16));
  }
}
.promo-variant { position: relative; }
.promo-video { display: block; width: 100%; height: auto; background: #071226; }
.promo-start { position: absolute; inset: 0; display: block; color: #FFFFFF; text-decoration: none; }
.promo.is-live .promo-start { display: none; }
.promo-play {
  position: absolute;
  inset-inline-end: 3%; /* bottom right of the 16:9 films: clear of the phone (left or right of centre), the
                           headline and the disclosure chip */
  bottom: clamp(0.6rem, 4%, 1.5rem);
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.4rem 1.1rem 0.4rem 0.4rem;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  background: rgba(7, 18, 38, 0.86);
  color: #FFFFFF;
  font-weight: 700;
  line-height: 1.2;
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.6);
  transition: background-color 0.15s ease;
}
.promo-play-icon {
  display: inline-grid;
  flex: none;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background: linear-gradient(180deg, #F0D394, #D9AE5F);
  color: #0B1B36;
}
.promo-play-icon .icon { width: 1.2rem; height: 1.2rem; margin-inline-start: 0.12rem; }
.promo-start:hover .promo-play { background: rgba(7, 18, 38, 0.96); }
.promo-start:focus-visible { outline-offset: -4px; }
@media (max-width: 699px) {
  /* 9:16: centred over the phone's tab bar, clear of the headline and the disclosure chip */
  .promo-play { inset-inline-start: 50%; inset-inline-end: auto; transform: translateX(-50%); white-space: nowrap; }
}
.promo-caption {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem 1rem;
  margin-top: 1rem;
  color: var(--c-text-muted);
  font-size: 0.9375rem;
  text-align: center;
}
/* Pause/play over the playing film, in the frame's bottom end corner (GlutenScanning website's .vid-toggle) */
.promo-toggle {
  position: absolute;
  inset-inline-end: 0.85rem;
  bottom: 0.85rem;
  z-index: 2;
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(7, 18, 38, 0.62);
  color: #FFFFFF;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  box-shadow: none;
}
.promo-toggle:hover { background: rgba(7, 18, 38, 0.88); }

/* Under the film, as on the GlutenScanning website: its title, tagline and facts at the start, "All videos" and the
   transcript link at the end, the other films below. Centred on phones; as wide as the film from 700 px. */
.film-meta {
  display: grid;
  grid-template-columns: minmax(0, 1fr); /* the "More videos" row scrolls on phones: never wider than the screen */
  gap: 1.25rem;
  max-width: 36rem;
  margin: 1.25rem auto 0;
  color: var(--c-on-hero-muted);
  text-align: center;
}
@media (min-width: 700px) {
  .film-meta {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    max-width: min(100%, calc((100vh - 8.5rem) * 16 / 9));
    max-width: min(100%, calc((100svh - 8.5rem) * 16 / 9));
    text-align: start;
  }
  .film-strip { grid-column: 1 / -1; }
}
.film-meta p { margin: 0; }
.film-title { color: var(--c-on-hero); font-size: 1.125rem; font-weight: 650; line-height: 1.35; letter-spacing: -0.01em; }
.film-tagline { margin-top: 0.25rem !important; font-size: 0.9375rem; }
.film-facts-line { display: flex; align-items: center; gap: 0.4rem; margin-top: 0.5rem !important; font-size: 0.875rem; }
.film-facts-line .icon { flex: none; width: 1.1rem; height: 1.1rem; }
.film-links { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1.5rem; }
.btn-ghost-dark { border-color: rgba(255, 255, 255, 0.32); background: rgba(255, 255, 255, 0.06); color: var(--c-on-hero); }
.btn-ghost-dark:hover { background: rgba(255, 255, 255, 0.14); color: var(--c-on-hero); text-decoration: none; }
.btn-ghost-dark .icon { width: 1.1rem; height: 1.1rem; }
.film-transcript { display: inline-flex; align-items: center; min-height: 2.75rem; color: var(--c-hero-gold); font-weight: 650; }
.film-transcript:hover { color: var(--c-hero-gold); }
.film-strip { min-width: 0; margin: 0; }
.film-strip-title { margin-bottom: 0.6rem !important; color: var(--c-on-hero-muted); font-size: 0.75rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; }
@media (max-width: 699px) {
  .film-head .film-facts-line, .film-links { justify-content: center; }
}

/* ---------- Transcripts (promo and Videos page) ---------- */

.transcript {
  margin-top: 1.75rem;
  border-block: 1px solid var(--c-border);
}
.transcript summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 2.75rem;
  padding: 0.6rem 0.25rem 0.6rem 0;
  color: var(--c-accent);
  font-weight: 650;
  cursor: pointer;
  list-style: none;
}
.transcript summary::-webkit-details-marker { display: none; }
.transcript summary::after {
  content: "+";
  content: "+" / "";
  flex: none;
  font-size: 1.4rem;
  font-weight: 500;
  line-height: 1;
}
.transcript[open] summary::after { content: "\2212"; content: "\2212" / ""; }
.transcript-body { max-width: var(--measure); padding-bottom: 1rem; font-size: 0.9375rem; }
.transcript-body > p { color: var(--c-text-muted); }
.transcript-body h3 { font-size: 1rem; }
.transcript-lines { padding: 0; list-style: none; }
.transcript-lines li { display: grid; grid-template-columns: 5.5rem minmax(0, 1fr); gap: 0.75rem; }
.transcript-lines li + li { margin-top: 0.75rem; }
.transcript-time { color: var(--c-text-muted); font-variant-numeric: tabular-nums; font-weight: 650; }
.transcript-shows { display: block; margin-top: 0.15rem; color: var(--c-text-muted); }
.transcript-edits { color: var(--c-text-muted); }
.transcript-on-dark { border-color: rgba(255, 255, 255, 0.16); }
.transcript-on-dark summary { color: var(--c-hero-gold); }
.transcript-on-dark .transcript-body,
.transcript-on-dark .transcript-body > p,
.transcript-on-dark .transcript-time,
.transcript-on-dark .transcript-shows { color: var(--c-on-hero-muted); }
.transcript-on-dark .transcript-text { color: var(--c-on-hero); }
.transcript-on-dark h3 { color: var(--c-on-hero); }
@media (max-width: 499px) {
  .transcript-lines li { grid-template-columns: minmax(0, 1fr); gap: 0.1rem; }
}

/* ---------- Chips, video strip ---------- */

.chips { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0; padding: 0; list-style: none; }
.chips li + li { margin: 0; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 2.75rem;
  padding: 0.4rem 0.95rem;
  border: 1px solid var(--c-border-strong);
  border-radius: 999px;
  background: var(--c-surface);
  color: var(--c-text);
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.25;
  text-decoration: none;
}
.chip:hover { border-color: var(--c-accent); background: var(--c-accent-soft); color: var(--c-text); }
.chip-meta { color: var(--c-text-muted); font-weight: 500; white-space: nowrap; }
.chip-all { color: var(--c-accent); }
.hero-promo .chip { border-color: rgba(255, 255, 255, 0.28); background: rgba(255, 255, 255, 0.06); color: var(--c-on-hero); }
.hero-promo .chip:hover { background: rgba(255, 255, 255, 0.14); }
.hero-promo .chip-meta { color: var(--c-on-hero-muted); }
.hero-promo .chip-all { color: var(--c-hero-gold); }
.film-facts { display: flex; align-items: center; gap: 0.45rem; margin-bottom: 0.6rem; font-weight: 700; }
.film-facts .icon, .film-link .icon { flex: none; width: 1.2rem; height: 1.2rem; }
/* Phones: one row that scrolls sideways; the right edge fades out as the cue that there is more */
@media (max-width: 699px) {
  .film-strip .chips {
    flex-wrap: nowrap;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x proximity;
    scroll-padding-inline: 0.4rem 2.5rem;
    margin-inline: -0.4rem;
    padding: 0.4rem 0.4rem 0.6rem;
    scrollbar-width: thin;
    -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 2.5rem), transparent);
    mask-image: linear-gradient(to right, #000 calc(100% - 2.5rem), transparent);
  }
  .film-strip .chips li { flex: none; scroll-snap-align: start; }
  .film-strip .chips::after { content: ""; flex: none; width: 2rem; }
}
.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.film-link a { display: inline-flex; align-items: center; gap: 0.45rem; min-height: 2.75rem; font-weight: 650; }
.watch-meta { color: var(--c-text-muted); font-weight: 500; }

/* ---------- Sections ---------- */

.section { padding-block: clamp(3rem, 8vw, 6rem); }
.section-head { max-width: 48rem; margin-bottom: clamp(1.75rem, 4vw, 2.75rem); }
.section-head h2 { margin-bottom: 0.5rem; }
.section-head .lead { margin-bottom: 0; }

/* How it works */
.steps {
  display: grid;
  gap: 2rem 1.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
@media (min-width: 700px) {
  .steps { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.steps li + li { margin: 0; }
.step-art {
  width: 100%;
  margin-bottom: 1.1rem;
  border-radius: var(--radius);
  background: #192841;
  box-shadow: var(--shadow-sm);
  aspect-ratio: 3 / 2;
  object-fit: cover;
}
.step-num { display: block; margin-bottom: 0.35rem; color: var(--c-gold-text); font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.08em; }
.step h3 { margin-bottom: 0.35rem; }
.step p { margin: 0; color: var(--c-text-muted); }

/* Principle: the reference case, before → after */
.principle { background: var(--c-surface); border-block: 1px solid var(--c-border); }
.principle-context { max-width: var(--measure); margin-bottom: 1.5rem; color: var(--c-text-muted); }
.principle-context .label { display: block; }
.split {
  display: grid;
  gap: 1rem;
  margin-bottom: 1.5rem;
}
@media (min-width: 860px) {
  .split { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
}
.split-card {
  padding: clamp(1.25rem, 3vw, 1.75rem);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  background: var(--c-bg);
}
.split-card > p:last-child { margin-bottom: 0; }
.split-card h3 { display: flex; align-items: center; gap: 0.6rem; }
.principle .split-card h3::before {
  content: "";
  flex: none;
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 50%;
  background: var(--c-issue);
}
.principle .split-senior h3::before { background: var(--c-gold); }
.split-senior { border-color: var(--c-gold); box-shadow: var(--shadow-sm); }
.spoken {
  margin: 0 0 1.25rem;
  font-family: var(--font-serif);
  font-size: clamp(1.2rem, 1.05rem + 0.6vw, 1.5rem);
  font-weight: 450;
  line-height: 1.45;
  letter-spacing: -0.005em;
}
.spoken p { margin: 0; }
.spoken-said { color: var(--c-text-muted); }
.said-meta { display: grid; gap: 0.75rem; margin-bottom: 1.25rem; }
.said-meta dt { color: var(--c-text-muted); font-size: 0.75rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
.said-meta dd { margin: 0.15rem 0 0; }
.said-meta dd.spoken { margin: 0.15rem 0 0; font-size: 1.125rem; font-style: italic; }
.tags { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0 0 1rem; padding: 0; list-style: none; }
.tags li { display: inline-flex; align-items: center; gap: 0.4rem; margin: 0; padding: 0.25rem 0.7rem; border-radius: 999px; font-size: 0.8125rem; font-weight: 650; line-height: 1.4; }
.tags-issue li { background: var(--c-issue-soft); color: var(--c-text); }
.tags-issue li::before { content: ""; width: 0.45rem; height: 0.45rem; border-radius: 50%; background: var(--c-issue); }
.tags-legend li { background: var(--fam-soft); color: var(--c-text); }
.dot { flex: none; width: 0.55rem; height: 0.55rem; border-radius: 50%; background: var(--fam); }
.seg {
  padding: 0 0.05em;
  background: linear-gradient(to top, var(--fam-soft) 0.62em, transparent 0.62em);
  color: inherit;
  text-decoration: underline;
  text-decoration-color: var(--fam);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.2em;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}
.pattern { margin: 0; padding-top: 1rem; border-top: 1px solid var(--c-border); }
.pattern .label { display: block; }
.pattern-formula { font-family: var(--font-serif); font-size: 1.3rem; font-weight: 500; }
.fam-context { --fam: var(--c-fam-context); --fam-soft: var(--c-fam-context-soft); }
.fam-action { --fam: var(--c-fam-action); --fam-soft: var(--c-fam-action-soft); }
.fam-benefit { --fam: var(--c-fam-benefit); --fam-soft: var(--c-fam-benefit-soft); }
.fam-ask { --fam: var(--c-fam-ask); --fam-soft: var(--c-fam-ask-soft); }
.fam-positive { --fam: var(--c-fam-positive); --fam-soft: var(--c-fam-positive-soft); }

/* The twelve codes */
.family-legend { display: flex; flex-wrap: wrap; gap: 0.5rem 1.25rem; margin: 0 0 1.5rem; padding: 0; list-style: none; font-size: 0.9375rem; font-weight: 600; }
.family-legend li { display: inline-flex; align-items: center; gap: 0.45rem; margin: 0; }
.code-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 15.5rem), 1fr));
  gap: 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.code-grid li + li { margin: 0; }
.code-card {
  position: relative;
  padding: 1.35rem 1.35rem 1.4rem;
  border: 1px solid var(--c-border);
  border-radius: var(--radius-sm);
  background: var(--c-surface);
  box-shadow: var(--shadow-sm);
}
.code-card::before { content: ""; position: absolute; inset-inline-start: 1.35rem; top: 0; width: 1.75rem; height: 3px; border-radius: 0 0 3px 3px; background: var(--fam); }
.code-num { display: block; margin-bottom: 0.5rem; color: var(--fam); font-size: 0.75rem; font-weight: 750; letter-spacing: 0.08em; }
.code-card h3 { margin-bottom: 0.3rem; font-size: 1.0625rem; }
.code-card p { margin: 0; color: var(--c-text-muted); font-size: 0.9375rem; }
.code-card .code-example { margin-top: 0.75rem; color: var(--c-text); font-family: var(--font-serif); font-size: 1.0625rem; line-height: 1.45; }

/* ---------- Features ---------- */

.features { padding-top: clamp(3rem, 8vw, 6rem); }
.feature-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.feature-grid li + li { margin: 0; }
@media (min-width: 760px) {
  .feature-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; }
}
.feature {
  display: flex;
  flex-direction: column;
  padding: clamp(1.15rem, 3vw, 1.5rem);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  background: var(--c-surface);
  box-shadow: var(--shadow-sm);
}
.feature-body { display: flex; flex: 1 1 auto; flex-direction: column; min-width: 0; }
.feature-body > p:not(.feature-link) { color: var(--c-text-muted); }
.feature-head { display: flex; align-items: center; gap: 0.85rem; margin-bottom: 0.75rem; }
.feature-head h3 { margin: 0; }
.feature-icon {
  display: inline-grid;
  flex: none;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.75rem;
  background: var(--c-accent-soft);
  color: var(--c-accent);
}
.feature-icon .icon { width: 1.4rem; height: 1.4rem; }
.feature-link { margin: 0 0 0.75rem; }
.feature-link a, .more-link a, .link-list a { display: inline-flex; align-items: center; min-height: 2.75rem; }
.feature .illus-aside { margin-top: auto; }
/* Cards with a screen recording or a still: full width, the phone beside the text (alternating sides); on narrow
   screens the phone follows the text. The caption under it gets the whole media column. */
.feature .feature-media { width: 100%; margin: 1.5rem 0 0; }
.feature .feature-media .screen-video,
.feature .feature-media .screen-img { width: min(66%, 14rem); margin-inline: auto; }
.feature .feature-media > figcaption { justify-content: center; text-align: center; }
.feature-media:has(noscript img) > video { display: none; } /* without JavaScript: the poster image instead */
@media (min-width: 760px) {
  .feature-has-media {
    display: grid;
    grid-column: 1 / -1;
    grid-template-columns: minmax(0, 1fr) clamp(14rem, 24vw, 18rem);
    column-gap: clamp(1.75rem, 5vw, 4.5rem);
    align-items: center;
    padding: clamp(1.5rem, 3vw, 2.5rem);
  }
  .feature-has-media .feature-body { grid-column: 1; grid-row: 1; max-width: 40rem; }
  .feature-has-media .feature-media { grid-column: 2; grid-row: 1; margin: 0; }
  .feature .feature-media .screen-video,
  .feature .feature-media .screen-img { width: clamp(10.5rem, 16vw, 13rem); }
  .feature-has-media.feature-media-start { grid-template-columns: clamp(14rem, 24vw, 18rem) minmax(0, 1fr); }
  .feature-media-start .feature-body { grid-column: 2; }
  .feature-media-start .feature-media { grid-column: 1; }
  .feature-has-media .feature-head h3 { font-size: 1.5rem; }
  .feature-has-media .feature-body > p { font-size: 1.0625rem; }
}

/* ---------- Phone frames (pure CSS): the captures already include the status bar ---------- */

.phone { margin: 0; }
.screen-img,
.screen-video {
  display: block;
  width: 100%;
  height: auto;
  border: 0.45rem solid var(--c-bezel);
  border-radius: 2.1rem;
  background: var(--c-screen);
  box-shadow: var(--shadow-lg);
  object-fit: cover;
  aspect-ratio: 660 / 1434;
}
.phone figcaption {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.5rem;
  align-items: baseline;
  justify-content: center;
  margin-top: 0.85rem;
  font-size: 0.9375rem;
  text-align: center;
}
.phone figcaption.video-caption { flex-wrap: nowrap; align-items: center; gap: 0.65rem; }
.video-caption-text { display: grid; gap: 0.2rem; min-width: 0; text-align: start; text-wrap: pretty; }
.video-flag { color: var(--c-text-muted); font-size: 0.8125rem; font-weight: 600; }
.video-toggle {
  display: inline-grid;
  flex: none;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 1px solid var(--c-border-strong);
  border-radius: 50%;
  background: var(--c-surface);
  color: var(--c-text);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
}
.video-toggle[hidden] { display: none; }
.video-toggle:hover { background: var(--c-surface-alt); }
.video-toggle .icon { width: 1.05rem; height: 1.05rem; }
.video-toggle .icon-play,
.video-toggle.is-paused .icon-pause { display: none; }
.video-toggle.is-paused .icon-play { display: block; }

/* ---------- Illustrations (real app content, shown where a capture is missing) ---------- */

.illus { display: grid; gap: 0.75rem; width: min(26rem, 100%); margin-inline: auto; }
.illus-card {
  position: relative;
  padding: 1rem 1.15rem;
  border: 1px solid var(--c-border);
  border-radius: var(--radius-sm);
  background: var(--c-surface);
  color: var(--c-text);
  box-shadow: var(--shadow-sm);
}
.illus-raised { box-shadow: var(--shadow-lg); }
.illus-muted { background: var(--c-surface-alt); box-shadow: none; }
.illus-quote { margin: 0; font-family: var(--font-serif); font-size: 1.0625rem; line-height: 1.45; }
.illus-text { margin: 0; font-size: 0.9375rem; }
.illus-point { margin: 0 0 0.2rem; font-weight: 650; }
.illus-small { margin: 0.15rem 0 0; color: var(--c-text-muted); font-size: 0.875rem; }
.illus-struck { color: var(--c-text-muted); text-decoration: line-through; text-decoration-color: var(--c-issue); }
.illus-ticks, .illus-options, .illus-notes, .illus-list { margin: 0.75rem 0 0; padding: 0; list-style: none; }
.illus-ticks { display: flex; flex-wrap: wrap; gap: 0.3rem 0.9rem; color: var(--c-text); font-size: 0.8125rem; font-weight: 600; }
.illus-ticks li, .illus-options li, .illus-notes li, .illus-list li { margin: 0; }
.illus-ticks li { display: inline-flex; align-items: center; gap: 0.3rem; }
.illus-ticks .icon { width: 0.9rem; height: 0.9rem; color: var(--c-positive); }
.illus-options { display: grid; gap: 0.4rem; font-size: 0.9375rem; font-weight: 600; }
.illus-option { display: flex; align-items: center; gap: 0.4rem; padding: 0.5rem 0.75rem; border: 1px solid var(--c-border); border-radius: 0.6rem; }
.illus-option-right { border: 2px solid var(--c-positive); }
.illus-option .icon { width: 1rem; height: 1rem; color: var(--c-positive); }
.illus-card-meeting { padding-inline-start: 3.25rem; }
.illus-num { position: absolute; inset-inline-start: 1rem; top: 1rem; display: grid; place-items: center; width: 1.6rem; height: 1.6rem; border-radius: 50%; background: var(--c-accent); color: var(--c-on-accent); font-size: 0.8125rem; font-weight: 700; }
.illus-list { display: grid; gap: 0.75rem; }
.illus-list li + li { padding-top: 0.75rem; border-top: 1px solid var(--c-border); }
.illus-filler { background: var(--c-issue-soft); border-radius: 0.2em; box-shadow: inset 0 -2px 0 var(--c-issue); }
.illus-hedge { background: var(--c-fam-benefit-soft); border-radius: 0.2em; box-shadow: inset 0 -2px 0 var(--c-fam-benefit); }
.illus-notes { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.illus-note { padding: 0.2rem 0.65rem; border-radius: 999px; font-size: 0.8125rem; font-weight: 600; }
.illus-note-filler { background: var(--c-issue-soft); color: var(--c-text); }
.illus-note-hedge { background: var(--c-fam-benefit-soft); color: var(--c-text); }
.illus-aside { width: 100%; margin-top: 0.5rem; }
.illus-aside .illus-card { box-shadow: none; background: var(--c-bg); }
.illus-aside .illus-muted { background: var(--c-surface-alt); }

/* ---------- Screenshots: the GlutenScanning website's rail ----------
   Phones: a horizontal scroll-snap row that bleeds to the screen edges. From 640 px a two-column grid, from 1024 px
   three columns with the middle one dropped, so the phones read as a staggered row rather than a table. */

.gallery-section { overflow-x: clip; padding-top: 0; }
.section-head-center { margin-inline: auto; text-align: center; }
.rail {
  display: flex;
  gap: 1.25rem;
  margin-inline: calc(-1 * var(--gutter));
  padding: 0.5rem var(--gutter) 1rem;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--gutter);
  scrollbar-width: none;
}
.rail::-webkit-scrollbar { display: none; }
.shot { position: relative; flex: 0 0 min(74%, 17rem); margin: 0; scroll-snap-align: center; }
@media (min-width: 640px) {
  .rail { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4rem 2rem; margin-inline: 0; padding: 0; overflow: visible; }
}
@media (min-width: 1024px) {
  .rail { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5rem 3.5rem; padding-bottom: 4.5rem; }
  .shot:nth-child(3n+2) { transform: translateY(4.5rem); }
}
.shot-phone { width: min(15.5rem, 100%); margin-inline: auto; }
.shot-text { max-width: 20rem; margin: 1.5rem auto 0; text-align: center; }
.shot-eyebrow { color: var(--c-gold-text); font-size: 0.75rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; }
.shot-text h3 { margin: 0.5rem 0 0; font-size: 1.125rem; line-height: 1.3; }
.shot-text p { margin: 0.5rem 0 0; color: var(--c-text-muted); font-size: 0.9375rem; }
.shot-watch { display: flex; justify-content: center; margin-top: 0.35rem !important; }

/* ---------- Devices: pure-CSS frames with real app content (or real captures when they exist) ---------- */

.devices { background: var(--c-surface); border-block: 1px solid var(--c-border); }
.device-grid {
  display: grid;
  gap: 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.device-grid li + li { margin: 0; }
@media (min-width: 900px) {
  .device-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; }
  .device-card-ipad, .device-card-watch { grid-column: 1 / -1; }
}
.device-card {
  display: grid;
  gap: 1.5rem;
  align-content: start;
  padding: clamp(1.15rem, 3vw, 1.75rem);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  background: var(--c-bg);
}
@media (min-width: 900px) {
  .device-card-ipad { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); align-items: center; column-gap: 2.5rem; }
  .device-card-watch { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); align-items: center; column-gap: 2.5rem; }
  .device-card-watch .device-art { grid-column: 2; grid-row: 1; }
  .device-card-watch .device-body { grid-column: 1; grid-row: 1; }
  .watch { max-width: 9.5rem; }
  .watch-main { max-width: 12.5rem; }
}
.device-body > p { color: var(--c-text-muted); }
.device-body .fine { margin-bottom: 0.5rem; }
.device-art { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: center; gap: 1rem; min-width: 0; }
.device-note, .device-state { margin: 0.6rem 0 0; color: var(--c-text-muted); font-size: 0.8125rem; font-weight: 600; text-align: center; }
.device-body .device-note { text-align: start; }
.device-illus { width: 100%; height: 100%; }
.device-capture { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top; }
.shortcut-list { display: grid; gap: 0.45rem; margin: 0; padding: 0; list-style: none; }
.shortcut-list li { display: grid; grid-template-columns: 7rem minmax(0, 1fr); gap: 0.75rem; align-items: center; margin: 0; }
.keys { white-space: nowrap; }

/* iPad, landscape */
.ipad { width: min(100%, 38rem); margin: 0; }
.ipad-screen {
  container-type: inline-size;
  overflow: hidden;
  aspect-ratio: 1.43;
  border: clamp(0.4rem, 1.4vw, 0.7rem) solid var(--c-bezel);
  border-radius: clamp(1rem, 3vw, 1.6rem);
  background: #F3F4F8;
  box-shadow: var(--shadow-lg);
}
.ipad-ui {
  display: grid;
  grid-template-columns: 22% minmax(0, 1fr) minmax(0, 1fr);
  height: 100%;
  color: #141B2B;
  font-size: 2.4cqi;
  line-height: 1.35;
}
.ipad-ui p, .ipad-ui ul, .ipad-ui ol { margin: 0; padding: 0; list-style: none; }
.ipad-ui li + li { margin: 0; }
.ipad-sidebar { padding: 4cqi 2.2cqi; border-inline-end: 1px solid #E1E5EE; background: #EBEEF4; }
.ipad-app { margin-bottom: 2.5cqi !important; font-weight: 750; font-size: 2.7cqi; }
.ipad-sidebar li { padding: 1.2cqi 1.6cqi; border-radius: 1.2cqi; color: #5D6474; font-weight: 600; }
.ipad-sidebar li.is-current { background: #1A325A; color: #FFFFFF; }
.ipad-col { padding: 4cqi 2.6cqi; min-width: 0; }
.ipad-col-lessons { border-inline-start: 1px solid #E1E5EE; background: #FFFFFF; }
.ipad-title { margin-bottom: 2cqi !important; font-size: 3.6cqi; font-weight: 800; letter-spacing: -0.02em; }
.ipad-mix { display: flex; align-items: center; gap: 1.4cqi; margin-bottom: 2.4cqi !important; padding: 1.6cqi 2cqi; border-radius: 1.6cqi; background: linear-gradient(135deg, #0D1F3D, #23477F); color: #FFFFFF; font-weight: 650; }
.ipad-mix-icon .icon { width: 3cqi; height: 3cqi; color: #E9C988; }
.ipad-path { display: grid; gap: 1.5cqi; }
.lvl { display: flex; align-items: center; gap: 1.6cqi; font-weight: 600; }
.lvl-dot { display: grid; flex: none; place-items: center; width: 4.4cqi; height: 4.4cqi; border-radius: 50%; background: #FFFFFF; color: #5D6474; box-shadow: inset 0 0 0 1.5px #A9B1C2; font-size: 2cqi; font-weight: 750; }
.lvl-dot .icon { width: 2.6cqi; height: 2.6cqi; }
.lvl-done .lvl-dot { background: #23855A; color: #FFFFFF; box-shadow: none; }
.lvl-current .lvl-dot { background: #A2752B; color: #FFFFFF; box-shadow: 0 0 0 0.8cqi rgba(162, 117, 43, 0.22); }
.lvl-locked { color: #5D6474; }
.lvl-title { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ipad-lessons { display: grid; gap: 1.2cqi; }
.ipad-lessons li { display: flex; align-items: center; gap: 1.4cqi; padding: 1.4cqi 1.8cqi; border: 1px solid #E1E5EE; border-radius: 1.4cqi; font-weight: 600; }
.lesson-dot { flex: none; width: 1.6cqi; height: 1.6cqi; border-radius: 50%; background: var(--fam-light); }
.ipad-ui .fam-context, .duo-ui .fam-context { --fam-light: #22807B; }
.ipad-ui .fam-action { --fam-light: #4D4FC0; }
.ipad-ui .fam-benefit { --fam-light: #A2660E; }
.ipad-ui .fam-ask { --fam-light: #1A325A; }
.ipad-ui .fam-positive { --fam-light: #23855A; }

/* iPhone Duo: closed (cover display) and open (inner display) */
.duo-art { align-items: flex-end; flex-wrap: nowrap; }
.duo { margin: 0; }
.duo-closed { width: 30%; max-width: 8.5rem; }
.duo-open { width: 62%; max-width: 18rem; }
.duo-screen {
  container-type: inline-size;
  overflow: hidden;
  border: 0.35rem solid var(--c-bezel);
  border-radius: 1.3rem;
  background: #F3F4F8;
  box-shadow: var(--shadow-lg);
}
.duo-closed .duo-screen { aspect-ratio: 0.5; }
.duo-open .duo-screen { aspect-ratio: 1.08; position: relative; }
.duo-open .duo-screen::after { content: ""; position: absolute; top: 0; bottom: 0; left: 50%; width: 1px; background: linear-gradient(rgba(17, 31, 61, 0), rgba(17, 31, 61, 0.18), rgba(17, 31, 61, 0)); }
.duo-ui { height: 100%; color: #141B2B; line-height: 1.35; }
.duo-ui p, .duo-ui ul { margin: 0; padding: 0; list-style: none; }
.duo-ui li + li { margin: 0; }
.duo-closed-ui { display: flex; flex-direction: column; gap: 4cqi; padding: 12cqi 6cqi 6cqi; font-size: 6.4cqi; }
.d-eyebrow { color: #5D6474; font-size: 6cqi; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.d-card { padding: 6cqi; border-radius: 6cqi; background: #FFFFFF; box-shadow: 0 1px 2px rgba(17, 31, 61, 0.08); }
.d-label { color: #1A325A; font-size: 5.6cqi; font-weight: 750; letter-spacing: 0.04em; text-transform: uppercase; }
.d-point { margin-top: 2cqi !important; font-weight: 700; }
.d-say { margin-top: 3cqi !important; font-family: var(--font-serif); font-size: 1.05em; line-height: 1.35; }
.d-dots { display: flex; justify-content: center; gap: 2.4cqi; margin-top: auto !important; }
.d-dots span { width: 3cqi; height: 3cqi; border-radius: 50%; background: #C5CBD8; }
.d-dots .is-on { background: #1A325A; }
.duo-open-ui { display: grid; grid-template-columns: 1fr 1fr; gap: 3.4cqi; padding: 6cqi 4cqi; font-size: 3.2cqi; }
.d-col { display: flex; flex-direction: column; gap: 2cqi; min-width: 0; }
.d-title { font-size: 3.6cqi; font-weight: 800; letter-spacing: -0.01em; }
.d-draft, .d-result { padding: 3cqi; border-radius: 3cqi; }
.d-draft { background: linear-gradient(150deg, #1A325A, #24467A); color: #FFFFFF; }
.d-result { background: #FFFFFF; box-shadow: 0 1px 2px rgba(17, 31, 61, 0.08); }
.d-result .d-say { margin-top: 0 !important; font-size: 1.12em; }
.d-ticks { display: flex; flex-wrap: wrap; gap: 1cqi 2.4cqi; margin-top: 2.4cqi !important; font-size: 2.7cqi; font-weight: 650; }
.d-ticks li { display: inline-flex; align-items: center; gap: 0.8cqi; }
.d-ticks .icon { width: 2.8cqi; height: 2.8cqi; color: #23855A; }

/* Apple Watch: case, crown and a black screen */
.watch-art { gap: clamp(0.6rem, 2vw, 1.25rem); flex-wrap: nowrap; align-items: center; }
.watch { position: relative; width: 28%; max-width: 8rem; margin: 0; }
.watch-main { width: 38%; max-width: 10.5rem; }
.watch::after {
  content: "";
  position: absolute;
  inset-inline-end: -5%;
  top: 26%;
  width: 5%;
  height: 16%;
  border-radius: 0 0.35rem 0.35rem 0;
  background: linear-gradient(90deg, #2A2F38, #5A606C);
}
.watch-screen {
  container-type: inline-size;
  overflow: hidden;
  aspect-ratio: 0.82;
  border: clamp(0.35rem, 1.2vw, 0.55rem) solid #1B1E25;
  border-radius: 28%;
  background: #000000;
  box-shadow: 0 0 0 1px #3A404C, var(--shadow-lg);
}
.w-ui { display: flex; flex-direction: column; gap: 4cqi; height: 100%; padding: 9cqi 9cqi 8cqi; color: #FFFFFF; font-size: 10cqi; line-height: 1.2; }
.w-ui p { margin: 0; }
.w-eyebrow { color: #E6C27F; font-size: 8cqi; font-weight: 700; }
.w-point { font-weight: 700; font-size: 11cqi; line-height: 1.18; }
.w-controls { display: flex; justify-content: space-between; margin-top: auto !important; }
.w-btn { display: grid; place-items: center; width: 26cqi; height: 18cqi; border-radius: 999px; background: #262A33; color: #FFFFFF; }
.w-btn-on { background: #A9C4F0; color: #0B1B36; }
.w-btn .icon { width: 11cqi; height: 11cqi; }
.w-question { font-family: var(--font-serif); font-size: 11cqi; line-height: 1.2; }
.w-options { display: grid; gap: 3cqi; margin-top: auto !important; }
.w-option { display: flex; align-items: center; justify-content: center; gap: 2cqi; padding: 3.4cqi; border-radius: 999px; background: #262A33; font-size: 9cqi; font-weight: 650; }
.w-option-right { background: #23855A; }
.w-option .icon { width: 9cqi; height: 9cqi; }
.w-face { justify-content: space-between; padding: 8cqi; }
.w-comps { display: flex; align-items: center; justify-content: space-between; gap: 2cqi; }
.w-comp { display: grid; place-items: center; width: 22cqi; height: 22cqi; border-radius: 50%; background: #1B1E25; color: #E6C27F; font-size: 8cqi; font-weight: 750; }
.w-comp .icon { width: 12cqi; height: 12cqi; }
.w-comp-text { color: #A9C4F0; }
.w-time { font-size: 21cqi; font-weight: 700; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.w-rect { display: grid; gap: 1.5cqi; padding: 5cqi 6cqi; border-radius: 6cqi; background: #1B1E25; }
.w-rect-label { color: #E6C27F; font-size: 7cqi; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em; }
.w-rect-text { font-size: 8.4cqi; font-weight: 600; line-height: 1.2; }

/* iPhone card */
.phone-device { width: min(13rem, 60%); }

/* ---------- Audience, privacy ---------- */

.audience-grid,
.privacy-grid {
  display: grid;
  gap: 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.audience-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); }
.privacy-grid { grid-template-columns: repeat(auto-fill, minmax(min(100%, 15.5rem), 1fr)); gap: 1.75rem 1.5rem; }
.audience-grid li + li, .privacy-grid li + li { margin: 0; }
.audience-grid li {
  padding: 1.5rem;
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  background: var(--c-surface);
  box-shadow: var(--shadow-sm);
}
.audience-grid h3 { margin-bottom: 0.4rem; }
.audience-grid p, .privacy-grid p { margin: 0; color: var(--c-text-muted); }
.privacy-section { background: var(--c-surface); border-block: 1px solid var(--c-border); }
/* What research says: seven findings, each with its source and what the app does with it */
.science-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 19rem), 1fr));
  gap: 1.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: finding;
}
.science-grid li {
  position: relative;
  padding: 1.25rem 1.25rem 1.1rem;
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  background: var(--c-surface);
  counter-increment: finding;
}
.science-grid li + li { margin: 0; }
.science-grid li::before {
  content: counter(finding, decimal-leading-zero);
  display: block;
  margin-bottom: 0.4rem;
  color: var(--c-gold-text);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}
.science-grid h3 { margin-bottom: 0.4rem; font-size: 1.0625rem; }
.science-grid p { margin-bottom: 0.6rem; }
.science-app { font-weight: 600; }
.science-source { margin-bottom: 0 !important; color: var(--c-text-muted); font-size: 0.875rem; overflow-wrap: anywhere; }
.science-note { margin-top: 1.25rem; max-width: 48rem; }
.privacy-grid li { padding-top: 1.1rem; border-top: 1px solid var(--c-border); }
.privacy-grid .feature-icon { margin-bottom: 0.75rem; }
.privacy-grid h3 { margin-bottom: 0.35rem; font-size: 1.0625rem; }
.more-link { margin: 1.5rem 0 0; font-weight: 650; }

/* ---------- LeadPhrase Pro ---------- */

.pro-grid { display: grid; gap: clamp(1.5rem, 4vw, 3rem); align-items: start; margin-bottom: 1.5rem; }
@media (min-width: 900px) {
  .pro-grid { grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); }
}
.pro-copy .lead { margin-bottom: 1.5rem; }
.pro-card {
  padding: clamp(1.4rem, 3vw, 2rem);
  border-radius: var(--radius);
  color: var(--c-on-hero);
  background:
    radial-gradient(22rem 14rem at 100% 0%, rgba(233, 201, 136, 0.26), transparent 70%),
    linear-gradient(160deg, var(--c-hero-top), var(--c-hero-bottom));
  box-shadow: var(--shadow-lg);
}
.pro-card a { color: var(--c-on-hero); }
.pro-card-name { display: flex; align-items: center; gap: 0.55rem; margin: 0 0 0.2rem; font-size: 1.5rem; font-weight: 780; letter-spacing: -0.02em; }
.pro-card-name .icon { color: var(--c-hero-gold); }
.pro-card-period { margin-bottom: 1rem; color: var(--c-hero-gold); font-weight: 650; }
.pro-card-price { margin-bottom: 0.5rem; font-size: 1.125rem; font-weight: 600; }
.pro-card-trial { margin-bottom: 1.25rem; color: var(--c-on-hero-muted); }
.pro-card .status-pill { background: var(--c-hero-pill-bg); color: var(--c-hero-pill-fg); box-shadow: inset 0 0 0 1px rgba(240, 211, 148, 0.35); }
.pro-terms { margin: 0.5rem 0 1rem; padding-inline-start: 1.1rem; color: var(--c-on-hero-muted); font-size: 0.875rem; }
.pro-legal { margin: 0; color: var(--c-on-hero-muted); font-size: 0.875rem; }
.pro-notes { margin-bottom: 0; }
.pro-notes .split-card { background: var(--c-surface); }
.pro-notes h3 { gap: 0.75rem; }
.pro-notes p { margin: 0; color: var(--c-text-muted); }

/* ---------- FAQ ---------- */

.faq { border-top: 1px solid var(--c-border); margin-bottom: 1.5rem; }
.faq details { border-bottom: 1px solid var(--c-border); }
.faq summary {
  position: relative;
  padding: 1.05rem 2.25rem 1.05rem 0;
  font-weight: 650;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  content: "+" / "";
  position: absolute;
  inset-inline-end: 0.25rem;
  top: 0.9rem;
  color: var(--c-gold-text);
  font-size: 1.4rem;
  font-weight: 500;
  line-height: 1;
}
.faq details[open] summary::after { content: "\2212"; content: "\2212" / ""; }
.faq details p { max-width: var(--measure); color: var(--c-text-muted); }
.faq-teaser { background: var(--c-surface); border-top: 1px solid var(--c-border); }
.faq-teaser .more-link { margin-top: 0; }

/* ---------- Final call to action ---------- */

.final {
  padding-block: clamp(3rem, 8vw, 5.5rem);
  color: var(--c-on-hero);
  text-align: center;
  background:
    radial-gradient(30rem 18rem at 50% 0%, rgba(233, 201, 136, 0.24), transparent 70%),
    linear-gradient(160deg, var(--c-hero-top), var(--c-hero-bottom));
}
.final-inner { display: grid; justify-items: center; gap: 0.75rem; }
.final-icon { width: 6rem; height: 6rem; border-radius: 22.5%; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.2), 0 18px 60px -10px rgba(233, 201, 136, 0.45); }
.final h2 { max-width: 18em; margin: 0.5rem 0 0; }
.final .lead { margin: 0 auto 0.5rem; color: var(--c-on-hero-muted); }
.final .status-pill { margin: 0; background: var(--c-hero-pill-bg); color: var(--c-hero-pill-fg); box-shadow: inset 0 0 0 1px rgba(240, 211, 148, 0.35); }

/* ---------- Inner pages ---------- */

.page { padding-block: clamp(2rem, 6vw, 4rem) clamp(3rem, 8vw, 5rem); }
.page-head { margin-bottom: clamp(1.5rem, 4vw, 2.5rem); }
.page-head h1 { margin-bottom: 0.5rem; }
.page-head .lead { margin-bottom: 1rem; }
.page-head .meta { margin-bottom: 0.75rem; }
.page section { margin-bottom: 2.5rem; }
.toc ul { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0 0 2rem; padding: 0; list-style: none; }
.toc li + li { margin: 0; }
.toc a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  padding: 0.35rem 0.9rem;
  border: 1px solid var(--c-border);
  border-radius: 999px;
  background: var(--c-surface);
  color: var(--c-text);
  font-size: 0.9rem;
  text-decoration: none;
}
.toc a:hover { border-color: var(--c-accent); color: var(--c-accent); }
.prose > * { max-width: var(--measure); }
.prose h2 { margin-top: 2.5rem; font-size: clamp(1.35rem, 1.15rem + 0.8vw, 1.7rem); scroll-margin-top: 1rem; }
.prose h2:first-child { margin-top: 0; }
.prose ol li + li, .prose ul li + li { margin-top: 0.5rem; }
.guide { margin-top: 3rem; }
[id] { scroll-margin-top: 1rem; }

/* Videos page */
.video-index { margin-top: 1.5rem; }
.film { padding-top: clamp(2rem, 5vw, 3.5rem); }
.film + .film { margin-top: clamp(1.5rem, 4vw, 2.5rem); border-top: 1px solid var(--c-border); }
.film-facts { color: var(--c-text-muted); font-weight: 650; }
.film-player .promo-start { position: relative; }
.film-player .promo-frame { width: 100%; background: #071226; }
.film-player .promo-caption { color: var(--c-text-muted); }
.film-downloads { display: flex; flex-wrap: wrap; justify-content: center; gap: 0 1.5rem; margin: 0.5rem 0 0; }
.download-link { position: relative; display: inline-flex; align-items: center; min-height: 2.75rem; font-size: 0.9375rem; }
.download-link .icon { flex: none; width: 1.1rem; height: 1.1rem; margin-inline-end: 0.35rem; }
.film .transcript { margin-top: 1rem; }
@media (min-width: 700px) {
  .film-player .promo-frame { max-width: 56rem; margin-inline: 0; }
  .film-player .promo-caption, .film-downloads { justify-content: flex-start; text-align: start; }
}
@media (max-width: 699px) {
  .film-player .promo-frame { width: min(100%, 22rem); }
}

/* 404 */
.not-found { text-align: center; }
.empty-icon {
  display: inline-grid;
  place-items: center;
  width: 3.5rem;
  height: 3.5rem;
  margin-bottom: 0.75rem;
  border-radius: 1rem;
  background: var(--c-accent-soft);
  color: var(--c-accent);
}
.empty-icon .icon { width: 1.75rem; height: 1.75rem; }
.not-found .lead { margin-inline: auto; }
.link-list { display: flex; flex-wrap: wrap; justify-content: center; gap: 0 1.5rem; padding: 0; list-style: none; font-weight: 600; }
.link-list li + li { margin: 0; }

/* ---------- Footer ---------- */

.site-footer {
  padding-block: 3rem 2rem;
  border-top: 1px solid var(--c-border);
  background: var(--c-surface-alt);
  font-size: 0.9375rem;
}
.footer-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2rem 1.5rem; }
.footer-about { grid-column: 1 / -1; }
@media (min-width: 760px) {
  .footer-about { grid-column: auto; }
  .footer-grid { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr); }
}
.footer-brand { display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.25rem; font-size: 1.0625rem; font-weight: 750; }
.footer-brand img { width: 1.75rem; height: 1.75rem; border-radius: 0.45rem; }
.footer-tagline { margin-bottom: 0.75rem; color: var(--c-text-muted); }
.footer-status { margin-bottom: 0.75rem; font-weight: 600; }
.footer-contact { max-width: 52ch; color: var(--c-text-muted); }
.footer-heading {
  margin-bottom: 0.25rem;
  color: var(--c-text-muted);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.site-footer ul { margin: 0; padding: 0; list-style: none; }
.site-footer li + li { margin-top: 0; }
.site-footer nav a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  color: var(--c-text);
  text-decoration: none;
}
.site-footer nav a:hover { color: var(--c-accent); text-decoration: underline; }
.site-footer nav a[aria-current] { color: var(--c-accent); font-weight: 650; }
.footer-bottom {
  display: grid;
  gap: 0.25rem;
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--c-border);
  color: var(--c-text-muted);
  font-size: 0.875rem;
}
.footer-bottom p { margin: 0; }

/* ---------- Motion ---------- */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
  /* Looping recordings get no source with reduced motion (poster only), so there is nothing to pause. */
  .video-toggle { display: none !important; }
}

@media print {
  .site-header nav, .site-footer nav, .skip-link, .video-toggle, .carousel-nav, .hero-promo { display: none; }
  .hero, .final, .pro-card { background: none; color: #000; }
}
