/* atatype.com design system (Apple-style). Hebrew RTL first. Tokens -> base -> components.
   Light + dark: prefers-color-scheme, overridable with <html data-theme="light|dark">. */

/* ---------- tokens ---------- */
:root {
  --font: "Heebo", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;

  /* type scale (fluid) */
  --fs-hero: clamp(3rem, 10.5vw, 7.5rem);
  --fs-display: clamp(2.4rem, 7.6vw, 5.5rem);
  --fs-h2: clamp(2.1rem, 6vw, 4.25rem);
  --fs-h3: clamp(1.3rem, 2.4vw, 1.75rem);
  --fs-quote: clamp(1.9rem, 5.4vw, 4rem);
  --fs-lead: clamp(1.2rem, 2.4vw, 1.6rem);
  --fs-body: 1.0625rem;
  --fs-small: .9rem;
  --fs-eyebrow: clamp(1rem, 1.6vw, 1.2rem);
  --lh-tight: 1.08;
  --lh-body: 1.6;

  /* spacing */
  --s1: .25rem; --s2: .5rem; --s3: 1rem; --s4: 1.5rem; --s5: 2.5rem; --s6: 4rem; --s7: 6rem;
  --section: clamp(5rem, 13vw, 10rem);
  --gutter: clamp(16px, 4.5vw, 48px);
  --wrap: 1180px;
  --narrow: 820px;

  /* shape + motion */
  --r-s: 12px; --r: 22px; --r-l: 32px; --pill: 999px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --nav-h: 52px;

  /* colour: near-monochrome + one accent (logo sky blue, deepened for AA) */
  --bg: #ffffff;
  --bg-alt: #f5f5f7;
  --ink: #1d1d1f;
  --muted: #616166;
  --line: #d2d2d7;
  --accent: #0a6aa8;
  --on-accent: #ffffff;
  --nav-bg: rgba(255, 255, 255, .72);
  --card: #ffffff;
  --dark-bg: #000000;
  --dark-ink: #f5f5f7;
  --dark-muted: #a1a1a6;
  --dark-accent: #5ab4ee;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #000000; --bg-alt: #161617; --ink: #f5f5f7; --muted: #a1a1a6; --line: #333336;
    --accent: #5ab4ee; --on-accent: #000000; --nav-bg: rgba(22, 22, 23, .72); --card: #1d1d1f;
  }
}
:root[data-theme="dark"] {
  --bg: #000000; --bg-alt: #161617; --ink: #f5f5f7; --muted: #a1a1a6; --line: #333336;
  --accent: #5ab4ee; --on-accent: #000000; --nav-bg: rgba(22, 22, 23, .72); --card: #1d1d1f;
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 12px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: var(--fs-body); line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-x: hidden;
}
h1, h2, h3, p, blockquote, figure { margin: 0; }
h1, h2, h3 { font-weight: 800; letter-spacing: -.02em; line-height: var(--lh-tight); text-wrap: balance; }
p { text-wrap: pretty; }
img, video { display: block; max-width: 100%; height: auto; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 4px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
address { font-style: normal; }
.ltr { direction: ltr; unicode-bidi: isolate; display: inline-block; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.skip { position: absolute; top: -80px; inset-inline-start: 12px; z-index: 200; background: var(--bg); color: var(--ink); padding: 10px 16px; border-radius: var(--r-s); }
.skip:focus { top: 12px; }
.preview-bar { background: #ffd60a; color: #1d1d1f; text-align: center; font-size: var(--fs-small); font-weight: 600; padding: 6px 16px; }

.wrap { width: 100%; max-width: calc(var(--wrap) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }
.narrow { max-width: calc(var(--narrow) + 2 * var(--gutter)); }
.center { text-align: center; }
.center .actions, .center.actions { justify-content: center; }

/* ---------- type helpers ---------- */
.eyebrow { display: block; font-size: var(--fs-eyebrow); font-weight: 600; color: var(--accent); margin-bottom: var(--s3); letter-spacing: .01em; }
.display { font-size: var(--fs-display); }
.h2 { font-size: var(--fs-h2); }
.h3 { font-size: var(--fs-h3); letter-spacing: -.01em; }
.lead { font-size: var(--fs-lead); line-height: 1.45; color: var(--muted); font-weight: 400; }
.lead strong { color: var(--ink); font-weight: 600; }
.stack > * + * { margin-top: var(--s4); }
.muted { color: var(--muted); }

/* ---------- buttons + links ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 48px; padding: 12px 26px; border-radius: var(--pill); border: 0;
  background: var(--accent); color: var(--on-accent); font: inherit; font-size: 1.05rem; font-weight: 600;
  cursor: pointer; transition: transform .2s var(--ease), filter .2s var(--ease);
}
.btn:hover { text-decoration: none; filter: brightness(1.08); }
.btn:active { transform: scale(.98); }
.btn--ghost { background: transparent; color: var(--accent); box-shadow: inset 0 0 0 1.5px currentColor; }
.btn--light { background: #fff; color: #1d1d1f; }
.btn--small { min-height: 34px; padding: 6px 16px; font-size: .9rem; }
.link-arrow { display: inline-flex; align-items: center; gap: .3em; font-size: 1.1rem; font-weight: 500; min-height: 44px; }
.link-arrow::after { content: "‹"; font-size: 1.35em; line-height: 1; transform: translateY(-.04em); transition: transform .2s var(--ease); }
.link-arrow:hover::after { transform: translate(-3px, -.04em); }
.link-out::after { content: "↗"; font-size: .95em; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s3) var(--s4); margin-top: var(--s5); }

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 100; height: var(--nav-h);
  background: var(--nav-bg); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 60%, transparent);
}
.nav .wrap { height: 100%; display: flex; align-items: center; gap: var(--s4); }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 700; font-size: 1.05rem; white-space: nowrap; }
.brand:hover { text-decoration: none; }
.brand img { width: 30px; height: 30px; border-radius: 8px; }
.nav-links { display: none; list-style: none; margin: 0; padding: 0; gap: var(--s4); margin-inline-start: auto; }
.nav-links a { color: var(--ink); opacity: .82; font-size: .92rem; }
.nav-links a:hover { opacity: 1; text-decoration: none; }
.nav .btn { margin-inline-start: auto; }
.nav-links + .btn { margin-inline-start: 0; }

/* ---------- sections ---------- */
.section { padding-block: var(--section); }
.section--alt { background: var(--bg-alt); }
.section--dark { background: var(--dark-bg); color: var(--dark-ink); --ink: var(--dark-ink); --bg-alt: #161617; --muted: var(--dark-muted); --accent: var(--dark-accent); --on-accent: #000; --line: #333336; --card: #1d1d1f; }
.section--tight { padding-block: calc(var(--section) * .6); }
.section-head { max-width: var(--narrow); margin-bottom: var(--s6); }
.section-head.center { margin-inline: auto; }
.section-head .lead { margin-top: var(--s4); }

/* ---------- hero (video background + single headline) ---------- */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: min(calc(100svh - var(--nav-h)), 980px); display: grid; align-items: end;
  background: #000; color: #fff; --accent: var(--dark-accent);
}
.hero-media, .hero-media img, .hero-media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-media { z-index: -2; }
.hero-media img, .hero-media video { object-position: 22% 50%; }
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(to top, rgba(0,0,0,.86) 0%, rgba(0,0,0,.55) 38%, rgba(0,0,0,.05) 70%); }
.hero-content { padding-block: var(--s6) clamp(3rem, 9vw, 6.5rem); text-align: center; }
.hero h1 { font-size: var(--fs-hero); font-weight: 800; letter-spacing: -.035em; line-height: 1.02; max-width: 12ch; margin-inline: auto; }
.hero .tagline { margin-top: var(--s4); font-size: var(--fs-lead); font-weight: 400; color: rgba(255,255,255,.86); }
.hero .eyebrow { color: rgba(255,255,255,.8); }
.hero .actions { justify-content: center; }

/* ---------- media frame (poster image + lazy video on top) ---------- */
.vframe { position: relative; overflow: hidden; border-radius: var(--r-l); background: #111; aspect-ratio: 16 / 9; }
.vframe img, .vframe video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.vframe video, .hero-media video { opacity: 0; transition: opacity .8s var(--ease); }
.vframe video.is-playing, .hero-media video.is-playing { opacity: 1; }
.vframe--tall { aspect-ratio: 4 / 5; }
.vframe-caption {
  position: absolute; inset-inline: 0; bottom: 0; padding: var(--s6) var(--s4) var(--s4);
  background: linear-gradient(to top, rgba(0,0,0,.72), transparent); color: #fff;
  font-size: var(--fs-h3); font-weight: 700; letter-spacing: -.01em;
}
.bleed { margin-inline: calc(var(--gutter) * -1); }
.bleed .vframe { border-radius: 0; }

/* ---------- statement ---------- */
.statement { text-align: center; }
.statement .display { max-width: 14ch; margin-inline: auto; }
.statement .lead { max-width: 34ch; margin: var(--s5) auto 0; }

/* ---------- facts (stat tiles) ---------- */
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: var(--s3); margin-top: var(--s6); list-style: none; padding: 0; }
.facts li { background: var(--card); border-radius: var(--r); padding: var(--s4); }
.section--alt .facts li { background: var(--card); }
.facts b { display: block; font-size: clamp(2rem, 5vw, 3rem); font-weight: 800; letter-spacing: -.03em; line-height: 1.1; color: var(--ink); }
.facts span { color: var(--muted); font-size: var(--fs-small); }

/* ---------- split (media + text) ---------- */
.split { display: grid; gap: var(--s5); align-items: center; }
.split .stack .lead { margin-top: var(--s4); }

/* ---------- steps ---------- */
.steps { list-style: none; padding: 0; margin: var(--s6) 0 0; display: grid; gap: var(--s5); counter-reset: step; }
.steps li { counter-increment: step; border-top: 1px solid var(--line); padding-top: var(--s4); }
.steps li::before { content: "0" counter(step); display: block; font-size: var(--fs-small); font-weight: 700; color: var(--accent); margin-bottom: var(--s2); letter-spacing: .08em; }
.steps h3 { font-size: var(--fs-h3); margin-bottom: var(--s2); }
.steps p { color: var(--muted); }

/* ---------- quotes ---------- */
.big-quote { text-align: center; }
.big-quote blockquote p { font-size: var(--fs-quote); font-weight: 700; line-height: 1.18; letter-spacing: -.02em; max-width: 18ch; margin-inline: auto; }
.big-quote blockquote p::before, .big-quote blockquote p::after { color: var(--accent); }
.big-quote blockquote p::before { content: '"'; }
.big-quote blockquote p::after { content: '"'; }
.big-quote figcaption { margin-top: var(--s5); color: var(--muted); font-size: var(--fs-body); }
.quotes {
  display: grid; grid-auto-flow: column; grid-auto-columns: min(84%, 380px); gap: var(--s3);
  overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain; scrollbar-width: none;
  padding: var(--s2) var(--gutter) var(--s4); margin-inline: calc(var(--gutter) * -1); scroll-padding-inline: var(--gutter);
}
.quotes::-webkit-scrollbar { display: none; }
.quote-card {
  scroll-snap-align: start; display: flex; flex-direction: column; justify-content: space-between; gap: var(--s4);
  background: var(--card); border-radius: var(--r-l); padding: var(--s5) var(--s4);
}
.section--alt .quote-card { background: var(--card); }
.quote-card blockquote p { font-size: 1.25rem; line-height: 1.5; font-weight: 500; }
.quote-card blockquote p::before { content: '"'; }
.quote-card blockquote p::after { content: '"'; }
.quote-card footer { color: var(--muted); font-size: var(--fs-small); }
.quote-card footer b { display: block; color: var(--ink); font-size: 1rem; font-weight: 600; }
.quote-card .link-arrow { font-size: .95rem; min-height: 32px; margin-top: var(--s2); }
.quote-card--video { padding: 0; overflow: hidden; position: relative; min-height: 420px; color: #fff; }
.quote-card--video img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.quote-card--video .qv-body { position: relative; margin-top: auto; padding: var(--s6) var(--s4) var(--s4); background: linear-gradient(to top, rgba(0,0,0,.85), transparent); }
.quote-card--video .qv-body p { font-size: 1.2rem; font-weight: 600; line-height: 1.4; }
.quote-card--video a { color: #fff; }
.scroll-hint { color: var(--muted); font-size: var(--fs-small); margin-top: var(--s2); }

/* ---------- team ---------- */
.team { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--s5) var(--s4); text-align: center; }
.team img { width: 100%; max-width: 180px; aspect-ratio: 1; margin: 0 auto var(--s3); border-radius: 50%; object-fit: cover; background: #e8e8ed; }
.team b { display: block; font-size: 1.05rem; font-weight: 700; }
.team span { color: var(--muted); font-size: var(--fs-small); }

/* ---------- tiles (services) ---------- */
.tiles { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--s3); }
.tile { background: var(--bg-alt); border-radius: var(--r-l); padding: var(--s5) var(--s4); min-height: 190px; display: flex; flex-direction: column; justify-content: flex-end; }
.tile b { font-size: clamp(1.6rem, 3.6vw, 2.25rem); font-weight: 800; letter-spacing: -.02em; line-height: 1.1; }
.tile span { color: var(--muted); margin-top: var(--s2); }
.tile .key { width: 44px; height: 44px; border-radius: 12px; margin-bottom: auto; display: grid; place-items: center; background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent); }

/* ---------- press ---------- */
.press { list-style: none; padding: 0; margin: var(--s6) 0 0; display: grid; }
.press li { border-top: 1px solid var(--line); }
.press a { display: grid; grid-template-columns: 1fr auto; gap: var(--s1) var(--s3); padding: var(--s4) 0; color: var(--ink); }
.press a:hover { text-decoration: none; }
.press a:hover .press-what { color: var(--accent); }
.press-outlet { font-size: var(--fs-small); font-weight: 700; color: var(--muted); letter-spacing: .02em; }
.press-what { grid-column: 1; font-size: 1.2rem; font-weight: 600; line-height: 1.35; transition: color .2s; }
.press a::after { content: "↗"; grid-column: 2; grid-row: 1 / span 2; align-self: center; color: var(--accent); font-size: 1.2rem; }

/* ---------- CTA band ---------- */
.cta-band { text-align: center; }
.cta-band .h2 { max-width: 16ch; margin-inline: auto; }
.chips { list-style: none; padding: 0; margin: var(--s5) auto 0; display: flex; flex-wrap: wrap; justify-content: center; gap: var(--s2); max-width: 720px; }
.chips li { border: 1px solid var(--line); border-radius: var(--pill); padding: 6px 16px; font-size: var(--fs-small); color: var(--ink); }

/* ---------- contact ---------- */
.contact-list { list-style: none; padding: 0; margin: var(--s5) 0 0; display: grid; gap: var(--s2); }
.contact-list a { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); padding: var(--s4); border-radius: var(--r); background: var(--bg-alt); color: var(--ink); min-height: 72px; }
.section--alt .contact-list a { background: var(--card); }
.contact-list a:hover { text-decoration: none; background: color-mix(in srgb, var(--accent) 8%, var(--card)); }
.contact-list small { display: block; color: var(--muted); font-size: var(--fs-small); }
.contact-list strong { font-size: clamp(1.15rem, 2.4vw, 1.5rem); font-weight: 700; }
.contact-list .ic { flex: none; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: var(--on-accent); }
.place { margin-top: var(--s5); }
.place address { font-size: var(--fs-lead); font-weight: 600; margin-top: var(--s2); }

/* ---------- footer ---------- */
.footer { background: var(--bg-alt); color: var(--muted); font-size: var(--fs-small); padding-block: var(--s6) var(--s5); }
.footer .brand { font-size: 1rem; }
.footer p { margin-top: var(--s3); max-width: 60ch; }
.footer nav ul { list-style: none; padding: 0; margin: var(--s4) 0 0; display: flex; flex-wrap: wrap; gap: var(--s2) var(--s4); }
.footer nav a { color: var(--ink); display: inline-block; min-height: 32px; padding-block: 4px; }
.footer .legal { border-top: 1px solid var(--line); margin-top: var(--s5); padding-top: var(--s4); }

/* ---------- styleguide only ---------- */
.swatches { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: var(--s3); list-style: none; padding: 0; }
.swatches li { border-radius: var(--r-s); overflow: hidden; border: 1px solid var(--line); font-size: var(--fs-small); }
.swatches i { display: block; height: 64px; }
.swatches span { display: block; padding: 6px 10px; }
.sg-block { border-top: 1px solid var(--line); padding-block: var(--s6); }
.sg-label { font-family: ui-monospace, Consolas, monospace; font-size: .8rem; color: var(--muted); margin-bottom: var(--s3); }

/* ---------- scroll reveal (only when JS is on) ---------- */
.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.js .reveal.in { opacity: 1; transform: none; }

/* ---------- breakpoints ---------- */
@media (min-width: 700px) {
  .team { grid-template-columns: repeat(3, 1fr); }
  .tiles { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(3, 1fr); }
  .press { grid-template-columns: repeat(2, 1fr); column-gap: var(--s6); }
  .bleed { margin-inline: 0; }
  .bleed .vframe { border-radius: var(--r-l); }
}
@media (min-width: 900px) {
  .nav-links { display: flex; }
  .split { grid-template-columns: 1.1fr 1fr; gap: var(--s6); }
  .split--flip > :first-child { order: 2; }
  .quotes { grid-auto-flow: row; grid-template-columns: repeat(3, 1fr); grid-auto-columns: auto; overflow: visible; margin-inline: 0; padding-inline: 0; }
  .scroll-hint { display: none; }
  .contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s6); align-items: start; }
  .contact-grid .contact-list { margin-top: 0; }
  .hero-media img, .hero-media video { object-position: 50% 50%; }
  /* desktop: Eden stands on the left of the frame -> headline on the RTL start side, over the dark screen */
  .hero-content { text-align: start; }
  .hero h1 { margin-inline: 0; max-width: 9ch; }
  .hero .actions { justify-content: flex-start; }
  .hero::after { background: linear-gradient(to top, rgba(0,0,0,.8) 0%, rgba(0,0,0,.35) 45%, rgba(0,0,0,0) 70%), linear-gradient(to left, rgba(0,0,0,.55), rgba(0,0,0,0) 55%); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .link-arrow::after, .vframe video, .hero-media video { transition: none; }
}

/* ======================================================================
   Step 6: blog, article, /usa, 404 (same tokens + visual language)
   ====================================================================== */

/* ---------- crumbs + page head ---------- */
.crumbs { font-size: var(--fs-small); color: var(--muted); margin-bottom: var(--s5); }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--accent); }
.page-head { margin-bottom: var(--s6); }
.page-head .lead { margin-top: var(--s4); }

/* ---------- blog cards ---------- */
.cards { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--s4); }
.card a { display: flex; flex-direction: column; height: 100%; background: var(--bg-alt); border-radius: var(--r-l); overflow: hidden; color: var(--ink); transition: transform .35s var(--ease), box-shadow .35s var(--ease); }
.section--alt .card a { background: var(--card); }
.card a:hover { text-decoration: none; transform: translateY(-4px); box-shadow: 0 18px 40px -24px rgba(0,0,0,.35); }
.card a:hover .card-title { color: var(--accent); }
.card-media { aspect-ratio: 16 / 10; background: var(--card); overflow: hidden; }
.card-media img { width: 100%; height: 100%; object-fit: cover; }
.card-media--type { display: grid; place-items: center; background: radial-gradient(120% 120% at 85% 0%, color-mix(in srgb, var(--accent) 22%, var(--bg-alt)), var(--bg-alt) 70%); }
.section--alt .card-media--type { background: radial-gradient(120% 120% at 85% 0%, color-mix(in srgb, var(--accent) 22%, var(--card)), var(--card) 70%); }
.card-media--type span { font-size: clamp(7rem, 16vw, 10rem); line-height: 1; font-weight: 800; color: var(--accent); opacity: .55; transform: translateY(.2em); }
.card-body { padding: var(--s4) var(--s4) var(--s5); display: flex; flex-direction: column; gap: var(--s2); }
.card-meta { font-size: var(--fs-small); color: var(--muted); font-weight: 500; }
.card-title { font-size: 1.35rem; line-height: 1.25; letter-spacing: -.01em; transition: color .2s; }
.card-excerpt { color: var(--muted); display: -webkit-box; -webkit-line-clamp: 3; line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.more-title { margin-bottom: var(--s5); }

/* ---------- article (Apple-newsroom measure) ---------- */
.article { padding-block: var(--s5) var(--s6); }
.article-wrap { max-width: calc(700px + 2 * var(--gutter)); }
.article-head { margin-bottom: var(--s5); }
.article-title { font-size: clamp(2.2rem, 6.4vw, 4rem); letter-spacing: -.03em; line-height: 1.08; }
.article-meta { margin-top: var(--s4); color: var(--muted); }
.article-cover { max-width: calc(980px + 2 * var(--gutter)); margin-bottom: var(--s6); }
.article-cover img { width: 100%; border-radius: var(--r-l); background: var(--bg-alt); }
.prose { font-size: clamp(1.125rem, 1.7vw, 1.3rem); line-height: 1.85; }
.prose > * + * { margin-top: 1.15em; }
.prose a { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; overflow-wrap: anywhere; }
.prose-figure { margin-block: var(--s5); }
.prose-figure img { width: 100%; border-radius: var(--r); background: var(--bg-alt); }
.prose-embed a { text-decoration: none; font-weight: 600; }
.article-back { margin-top: var(--s6); padding-top: var(--s4); border-top: 1px solid var(--line); }

/* ---------- /usa ---------- */
.usa-hero .display { max-width: 18ch; margin-inline: auto; }
.usa-hero .lead { max-width: 40ch; margin: var(--s4) auto 0; }
.big-quote--raw blockquote p::before, .big-quote--raw blockquote p::after { content: none; }
.big-quote--raw blockquote p { max-width: 24ch; }
.bios { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--s5); }
.bios li { display: grid; grid-template-columns: 96px 1fr; gap: var(--s4); align-items: start; }
.bios img { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; }
.bios p { color: var(--muted); font-size: 1.1rem; }
.usa-next { margin-top: var(--s5); text-align: center; color: var(--accent); }
.story blockquote p { font-size: clamp(1.1rem, 1.8vw, 1.3rem); line-height: 1.8; margin-top: var(--s5); }
.story figcaption { margin-top: var(--s4); font-weight: 700; }

/* ---------- 404 ---------- */
.notfound { min-height: 60svh; display: grid; align-items: center; }
.notfound .lead { margin: var(--s4) auto 0; }

@media (min-width: 700px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .card--feature { grid-column: 1 / -1; }
  .card--feature a { display: grid; grid-template-columns: 1.25fr 1fr; }
  .card--feature .card-media { aspect-ratio: auto; min-height: 360px; }
  .card--feature .card-body { justify-content: center; padding: var(--s5); }
  .card--feature .card-title { font-size: clamp(1.8rem, 3.4vw, 2.6rem); line-height: 1.12; }
  .bios { grid-template-columns: 1fr 1fr; gap: var(--s6); }
  .bios li { grid-template-columns: 1fr; }
  .bios img { width: 160px; height: 160px; }
}
@media (min-width: 1000px) {
  .cards { grid-template-columns: repeat(3, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  .card a { transition: none; }
  .card a:hover { transform: none; }
}

/* LTR pages / English articles: arrows point the reading direction */
[dir="ltr"] .link-arrow::after { content: "›"; }
[dir="ltr"] .link-arrow:hover::after { transform: translate(3px, -.04em); }

/* ======================================================================
   Course landing (/course + thanks + policies, templates/course_*.html)
   Same tokens; denser rhythm than the site (forms + long copy). body.course
   ====================================================================== */
:root { --wa: #0e7a3e; --err: #b42318; --err-bg: #fef3f2; --err-line: #fda29b; --note-bg: #fff8e1; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --err: #ff8a80; --err-bg: #2a1311; --err-line: #7a2e27; --note-bg: #2a2410; }
}
:root[data-theme="dark"] { --err: #ff8a80; --err-bg: #2a1311; --err-line: #7a2e27; --note-bg: #2a2410; }

.course .section { padding-block: clamp(3.5rem, 9vw, 6.5rem); }
/* two same-colour sections in a row (copy + its short form) read as one block */
.course .section:not(.section--alt) + .section:not(.section--alt), .course .section--alt + .section--alt { padding-top: 0; }
.course .narrow > p, .course .ticks, .course .c-press { font-size: 1.125rem; }
.course h2 { font-size: clamp(1.9rem, 5vw, 3rem); margin-bottom: var(--s4); }
.course h3 { font-size: var(--fs-h3); margin: var(--s5) 0 var(--s3); }
.course .narrow p + p, .course .narrow p + ul, .course .narrow ul + p { margin-top: var(--s3); }
.course .nav .btn { margin-inline-start: auto; }
.hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* hero: headline + lead + video, form beside it on desktop */
.c-hero { padding-block: clamp(2.5rem, 7vw, 5.5rem) clamp(2rem, 5vw, 3.5rem); }
.c-hero-grid { display: grid; gap: var(--s5); }
.c-hero h1 { font-size: clamp(2rem, 5.6vw, 3.6rem); letter-spacing: -.03em; line-height: 1.1; }
.c-hero .lead { margin-top: var(--s4); }
.c-facts { padding-bottom: clamp(2.5rem, 6vw, 4rem); }
.c-facts .chips { margin-top: 0; max-width: none; }

/* embedded YouTube */
.video { margin-top: var(--s5); }
.ratio { position: relative; aspect-ratio: 16 / 9; border-radius: var(--r-l); overflow: hidden; background: #111; }
.ratio iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.course figcaption { color: var(--muted); font-size: var(--fs-small); margin-top: var(--s2); }

/* forms */
.form-card { background: var(--bg-alt); border-radius: var(--r-l); padding: var(--s5) var(--s4); }
.section--alt .form-card { background: var(--card); }
.form-card h2 { font-size: clamp(1.35rem, 2.6vw, 1.7rem); letter-spacing: -.01em; line-height: 1.25; }
.field { margin-bottom: var(--s3); }
.field label, .check label { font-weight: 600; }
.req { color: var(--err); }
.course input[type=text], .course input[type=tel], .course input[type=email], .course select {
  display: block; width: 100%; min-height: 50px; padding: 10px 14px; margin-top: 6px;
  font: inherit; color: var(--ink); background: var(--bg);
  border: 1.5px solid color-mix(in srgb, var(--ink) 42%, transparent); border-radius: var(--r-s);
}
.course input:focus-visible, .course select:focus-visible { outline: 3px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }
.ltr-input { text-align: right; }
.ltr-input:not(:placeholder-shown), .course input[type=tel], .course input[type=email] { unicode-bidi: plaintext; }
.check { display: flex; gap: 10px; align-items: flex-start; margin: var(--s3) 0 var(--s2); }
.check input { width: 24px; height: 24px; flex: none; margin-top: 3px; accent-color: var(--accent); }
.check label { font-weight: 400; font-size: .95rem; line-height: 1.5; }
.check a, .course .narrow p a, .c-press a { text-decoration: underline; text-underline-offset: 3px; }
.field-error { color: var(--err); font-size: .95rem; font-weight: 600; margin-top: 4px; }
.form-error { background: var(--err-bg); border: 1px solid var(--err-line); color: var(--ink); border-radius: var(--r-s); padding: 10px 14px; margin-bottom: var(--s3); }
.btn-block { display: flex; width: 100%; margin-top: var(--s3); }
.btn-wa { background: var(--wa); color: #fff; flex-wrap: wrap; column-gap: .4em; row-gap: 0; }
.btn bdi { white-space: nowrap; }
.wa-form { margin: 0; }

/* content blocks */
.callout { background: var(--bg-alt); border-inline-start: 4px solid var(--accent); padding: var(--s3) var(--s4); border-radius: var(--r-s); }
.section--alt .callout { background: var(--card); }
.ticks { list-style: none; padding: 0; margin: 0; }
.ticks li { position: relative; padding-inline-start: 30px; margin-bottom: var(--s3); }
.ticks li::before { content: "✓"; position: absolute; inset-inline-start: 0; top: 0; color: var(--accent); font-weight: 800; }
.icons { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s3); padding: 0; margin: var(--s5) 0; }
.icons li { text-align: center; color: var(--accent); background: var(--card); border-radius: var(--r); padding: var(--s4) var(--s2); }
.icons svg { display: block; margin: 0 auto var(--s2); }
.icons span { color: var(--ink); font-size: .95rem; font-weight: 600; }
.about { display: grid; gap: var(--s5); align-items: center; }
.about img { border-radius: var(--r-l); }
blockquote.plain p { font-size: var(--fs-lead); line-height: 1.5; color: var(--ink); }
.c-quotes { margin-top: var(--s5); margin-bottom: var(--s5); }
.quote-card--raw blockquote p::before, .quote-card--raw blockquote p::after { content: none; }
.quote-card > footer { color: var(--ink); font-weight: 600; font-size: 1rem; }
.c-press { list-style: none; padding: 0; margin: 0; }
.c-press li { padding: var(--s3) 0; border-top: 1px solid var(--line); }
/* FAQ accordion (native details): course FAQ + home #faq */
.faq details { border-top: 1px solid var(--line); }
.faq details:last-of-type { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; font-weight: 700; font-size: 1.1rem; padding: var(--s3) 0; min-height: 56px; display: flex; align-items: center; justify-content: space-between; gap: var(--s3); list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--accent); font-size: 1.5rem; font-weight: 400; line-height: 1; transition: transform .2s var(--ease); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding-bottom: var(--s4); color: var(--muted); }
.closing-grid { display: grid; gap: var(--s5); }
.closing .lead { margin-bottom: var(--s4); }

/* policies + thanks */
.doc h1 { font-size: clamp(2rem, 5vw, 3rem); margin-bottom: var(--s4); }
.doc h2 { font-size: clamp(1.3rem, 2.6vw, 1.6rem); margin: var(--s5) 0 var(--s3); letter-spacing: -.01em; }
.doc p, .doc ul, .doc ol, .doc .table-wrap { margin-bottom: var(--s3); }
.doc ul, .doc ol { padding-inline-start: 24px; }
.doc a { text-decoration: underline; text-underline-offset: 3px; overflow-wrap: anywhere; }
.table-wrap { overflow-x: auto; }
.doc table { border-collapse: collapse; width: 100%; }
.doc th, .doc td { border: 1px solid var(--line); padding: 8px 12px; text-align: start; vertical-align: top; }
.doc th { background: var(--bg-alt); }
mark.todo { background: #ffe66d; color: #1d1d1f; padding: 0 3px; border-radius: 3px; }
.draft-note { background: var(--note-bg); border: 1px solid #e0b400; border-radius: var(--r-s); padding: 10px 14px; font-size: .95rem; margin-bottom: var(--s4); }
.thanks { min-height: 60svh; display: grid; align-items: center; }
.thanks h1 { font-size: var(--fs-display); margin-bottom: var(--s4); }
.thanks .lead { max-width: 36ch; margin-inline: auto; margin-bottom: var(--s5); }
.thanks p + p { margin-top: var(--s4); }

/* floating WhatsApp (desktop) + sticky bar (mobile) */
.wa-float {
  position: fixed; inset-inline-start: 16px; bottom: 16px; z-index: 50;
  display: inline-flex; align-items: center; gap: 8px; min-height: 52px; padding: 10px 20px;
  background: var(--wa); color: #fff; border-radius: var(--pill); font-weight: 600;
  box-shadow: 0 10px 28px -8px rgba(0, 0, 0, .45);
}
.wa-float:hover { text-decoration: none; filter: brightness(1.08); }
button.wa-float { border: 0; font: inherit; cursor: pointer; }
.stickybar { display: none; }
.course .footer { padding-bottom: 110px; } /* room for the floating button / bottom bar */

@media (min-width: 900px) {
  .c-hero-grid { grid-template-columns: 1.15fr 1fr; align-items: start; gap: var(--s6); }
  .closing-grid { grid-template-columns: 1fr 1fr; align-items: start; gap: var(--s6); }
  .about { grid-template-columns: 300px 1fr; gap: var(--s6); }
  .c-hero .form-card { position: sticky; top: calc(var(--nav-h) + 24px); }
}
@media (max-width: 768px) {
  /* bottom bar replaces the floating WhatsApp button; footer gets room so nothing hides under it */
  .stickybar {
    display: flex; gap: 10px; position: fixed; inset-inline: 0; bottom: 0; z-index: 60;
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
    background: var(--nav-bg); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px);
    border-top: 1px solid color-mix(in srgb, var(--line) 60%, transparent);
  }
  .stickybar > a, .stickybar > .wa-form { flex: 1; }
  .stickybar .btn { width: 100%; min-height: 48px; }
  .stickybar ~ .wa-form { display: none; }
}
@media (prefers-reduced-motion: reduce) { .faq summary::after { transition: none; } }
