/* Fariba Cox, Life and Confidence Coach
   Layout: a calm, light editorial page; Fariba on her own lilac studio backdrop leads, one idea per section,
   one dark band for clients' words, a plum call to action that never moves. */

/* Fonts: self-hosted variable WOFF2, Latin subset (Newsreader and Figtree, SIL Open Font Licence) */
@font-face {
  font-family: "Newsreader"; font-style: normal; font-weight: 200 800; font-display: swap;
  src: url("../fonts/newsreader-variable-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Newsreader"; font-style: italic; font-weight: 200 800; font-display: swap;
  src: url("../fonts/newsreader-italic-variable-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Figtree"; font-style: normal; font-weight: 300 900; font-display: swap;
  src: url("../fonts/figtree-variable-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  /* Colour: drawn from the lilac studio backdrop (#c8b9cc) and the grey script logo */
  --lilac: #c8b9cc;          /* portrait backdrop, hero ground */
  --lilac-soft: #efe9f1;     /* quiet bands */
  --lilac-line: #ddd2e1;     /* rules and field borders on light grounds */
  --paper: #fbf9f7;          /* page */
  --white: #ffffff;
  --ink: #241f29;            /* text */
  --ink-2: #4c4452;          /* secondary text, 9:1 on paper */
  --plum: #4e3557;           /* call to action, 10:1 with white */
  --plum-deep: #3c2844;
  --night: #2a2230;          /* the one dark band */
  --night-ink: #f4eff6;
  --night-ink-2: #cbbfd0;
  --error: #a3262f;

  /* Type */
  --font-display: "Newsreader", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --font-body: "Figtree", "Segoe UI", system-ui, -apple-system, sans-serif;
  --step--1: 0.875rem;
  --step-0: 1.0625rem;
  --step-1: 1.25rem;
  --step-2: clamp(1.4rem, 1.2rem + 0.7vw, 1.75rem);
  --step-3: clamp(2rem, 1.5rem + 2.2vw, 3.1rem);
  --step-4: clamp(2.5rem, 1.6rem + 3.8vw, 4.4rem);

  /* Space and shape */
  --gutter: clamp(1.25rem, 4vw, 3rem);
  --section: clamp(4.5rem, 9vw, 8.5rem);
  --radius: 14px;
  --radius-small: 10px;
  --shadow: 0 18px 40px -18px rgba(42, 34, 48, 0.28), 0 2px 6px rgba(42, 34, 48, 0.06);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --header-h: 76px;

  color-scheme: light;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); scrollbar-color: var(--lilac) var(--paper); }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 var(--step-0)/1.65 var(--font-body);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  caret-color: var(--plum);
}
img, picture, svg { display: block; max-width: 100%; height: auto; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 500; line-height: 1.1; letter-spacing: -0.015em; margin: 0; text-wrap: balance; color: var(--ink); }
h1 { font-size: var(--step-4); letter-spacing: -0.025em; line-height: 1.04; font-variation-settings: "opsz" 72; }
h2 { font-size: var(--step-3); font-variation-settings: "opsz" 60; }
h3 { font-size: var(--step-2); line-height: 1.2; font-variation-settings: "opsz" 30; }
p { margin: 0; text-wrap: pretty; }
p + p { margin-top: 1em; }
a { color: var(--plum); text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
a:hover { color: var(--plum-deep); }
ul, ol { margin: 0; padding: 0; }
::selection { background: var(--lilac); color: var(--ink); }
:focus-visible { outline: 3px solid var(--plum); outline-offset: 3px; border-radius: 4px; }
.lead { font-size: var(--step-1); line-height: 1.55; color: var(--ink-2); max-width: 36em; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 1rem; top: -100px; z-index: 100; background: var(--ink); color: var(--white); padding: 0.75rem 1rem; border-radius: var(--radius-small); }
.skip-link:focus { top: 1rem; color: var(--white); }

.wrap {
  width: 100%; max-width: 1200px; margin-inline: auto;
  padding-left: max(var(--gutter), env(safe-area-inset-left, 0px));
  padding-right: max(var(--gutter), env(safe-area-inset-right, 0px));
}
.section { padding-block: var(--section); }
.section__head { display: grid; gap: 1rem; margin-bottom: clamp(2.5rem, 5vw, 4rem); max-width: 44rem; }
.icon { width: 1.25em; height: 1.25em; flex: none; }

/* ---------- Buttons and links ---------- */
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.6rem;
  min-height: 48px; padding: 0.8rem 1.4rem; border: 1px solid transparent; border-radius: 999px;
  font: 600 1rem/1.2 var(--font-body); text-decoration: none; cursor: pointer;
  transition: background-color 200ms ease, color 200ms ease, transform 200ms var(--ease-out), box-shadow 200ms ease;
}
.button--primary { background: var(--plum); color: var(--white); box-shadow: 0 8px 20px -10px rgba(78, 53, 87, 0.7); }
.button--primary:hover { background: var(--plum-deep); color: var(--white); transform: translateY(-1px); box-shadow: 0 12px 24px -12px rgba(78, 53, 87, 0.8); }
.button:active { transform: translateY(0) scale(0.98); transition-duration: 90ms; }
.button--large { min-height: 56px; padding: 1rem 1.75rem; font-size: 1.0625rem; }
.button .icon-arrow { transition: transform 220ms var(--ease-out); }
.button:hover .icon-arrow { transform: translateX(3px); }

.text-link { font-weight: 600; color: var(--ink); text-decoration: underline; text-decoration-color: rgba(36, 31, 41, 0.35); text-underline-offset: 0.3em; transition: text-decoration-color 200ms ease; }
.text-link:hover { color: var(--ink); text-decoration-color: var(--ink); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  -webkit-backdrop-filter: blur(18px) saturate(160%); backdrop-filter: blur(18px) saturate(160%);
  transition: background-color 300ms ease, box-shadow 300ms ease;
}
.page-home .site-header { background: color-mix(in srgb, var(--lilac) 88%, transparent); }
.site-header[data-scrolled] { background: color-mix(in srgb, var(--paper) 88%, transparent); box-shadow: 0 1px 0 rgba(36, 31, 41, 0.08); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; min-height: var(--header-h); }
.brand { display: block; width: clamp(150px, 16vw, 188px); flex: none; }
.brand img { width: 100%; }
.site-nav { display: flex; align-items: center; gap: clamp(1rem, 2.4vw, 2.25rem); }
.site-nav ul { display: flex; gap: clamp(1rem, 2.2vw, 2rem); list-style: none; }
.site-nav ul a { color: var(--ink); font-weight: 500; font-size: 0.98rem; text-decoration: none; padding: 0.4rem 0; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size 260ms var(--ease-out); }
.site-nav ul a:hover, .site-nav ul a[aria-current="page"] { background-size: 100% 1px; color: var(--ink); }
.site-nav__cta { min-height: 44px; padding: 0.6rem 1.2rem; font-size: 0.95rem; }
.menu-toggle { display: none; }

/* ---------- Hero ---------- */
.hero { background: var(--lilac); overflow: hidden; }
.hero__inner { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: end; gap: clamp(1.5rem, 4vw, 4rem); min-height: min(calc(100svh - var(--header-h)), 760px); }
.hero__copy { align-self: center; display: grid; gap: 1.5rem; padding-block: clamp(3rem, 7vw, 6rem); }
.hero .lead { color: #3b3340; }
.hero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.75rem; margin-top: 0.5rem; }
.hero__facts { display: flex; flex-wrap: wrap; gap: 0.6rem 1.5rem; list-style: none; font-size: var(--step--1); font-weight: 500; color: #3b3340; }
.hero__facts li { display: flex; align-items: center; gap: 0.45rem; }
.hero__facts .icon { color: var(--plum); width: 1.15rem; height: 1.15rem; }
/* Office portrait in a framed card: its white office background cannot blend into the lilac band */
.hero__portrait { align-self: center; justify-self: end; width: min(100%, 440px); margin-block: clamp(2.5rem, 6vw, 5rem); border-radius: var(--radius); overflow: hidden; box-shadow: 0 30px 60px -28px rgba(42, 34, 48, 0.45), 0 4px 12px rgba(42, 34, 48, 0.08); }
.hero__img { width: 100%; transition: transform 700ms var(--ease-out); }
.hero__portrait:hover .hero__img { transform: scale(1.02); }

/* Page load: the heading, words and buttons rise one after another while the photograph settles into its frame.
   "backwards" fill only, so nothing is held after the animation and hover effects still work. */
@media (prefers-reduced-motion: no-preference) {
  .hero__copy > *, .page-hero__copy > *, .doc__inner, .not-found__inner { animation: rise 1000ms var(--ease-out) backwards; }
  .hero__copy > :nth-child(2), .page-hero__copy > :nth-child(2) { animation-delay: 90ms; }
  .hero__copy > :nth-child(3), .page-hero__copy > :nth-child(3) { animation-delay: 180ms; }
  .hero__copy > :nth-child(4), .page-hero__copy > :nth-child(4) { animation-delay: 270ms; }
  .hero__portrait, .page-hero__photo { animation: lift 1200ms var(--ease-out) backwards; }
  .hero__portrait img, .page-hero__photo img { animation: unzoom 1800ms var(--ease-out) backwards; }
}
@keyframes rise { from { opacity: 0; transform: translateY(18px); } }
@keyframes lift { from { opacity: 0; transform: translateY(28px); } }
@keyframes unzoom { from { transform: scale(1.08); } }

/* ---------- Where I can help ---------- */
.help-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); list-style: none; border-top: 1px solid var(--lilac-line); }
.help-list li { border-bottom: 1px solid var(--lilac-line); }
.help-list li:nth-child(odd) { border-right: 1px solid var(--lilac-line); }
.help-item { display: grid; gap: 0.75rem; align-content: start; height: 100%; padding: clamp(1.75rem, 3.5vw, 2.75rem); color: var(--ink); text-decoration: none; transition: background-color 260ms ease; }
.help-item p { color: var(--ink-2); max-width: 32em; }
.help-item__more { display: inline-flex; align-items: center; gap: 0.45rem; margin-top: 0.5rem; font-weight: 600; color: var(--plum); }
.help-item__more .icon { transition: transform 240ms var(--ease-out); }
.help-item:hover { background: var(--lilac-soft); color: var(--ink); }
.help-item:hover .help-item__more .icon { transform: translateX(4px); }

/* ---------- About ---------- */
.about { background: var(--lilac-soft); }
.about__inner { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(2rem, 6vw, 6rem); align-items: center; }
.about__photo { margin: 0; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); max-width: 460px; }
.about__photo img { width: 100%; transition: transform 700ms var(--ease-out); }
.about__photo:hover img { transform: scale(1.025); }
.about__copy { display: grid; gap: 1.25rem; max-width: 38rem; }
.about__copy > p:not(.lead) { color: var(--ink-2); }
.pull-quote { margin: 1rem 0 0; padding-top: 1.5rem; border-top: 1px solid var(--lilac-line); }
.pull-quote p { font: italic 400 var(--step-2)/1.35 var(--font-display); color: var(--ink); }
.pull-quote footer { margin-top: 0.75rem; font-size: var(--step--1); color: var(--ink-2); }

/* ---------- How it works ---------- */
.how__inner { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(2rem, 6vw, 6rem); align-items: start; }
.how__head { display: grid; gap: 1.25rem; position: sticky; top: calc(var(--header-h) + 2rem); }
.how__drawing { width: min(100%, 360px); margin-top: 1rem; opacity: 0.9; }
.steps { list-style: none; counter-reset: step; display: grid; }
.steps li { counter-increment: step; display: grid; grid-template-columns: 3.5rem 1fr; column-gap: 1.25rem; row-gap: 0.4rem; padding-block: 1.75rem; border-top: 1px solid var(--lilac-line); }
.steps li:last-child { border-bottom: 1px solid var(--lilac-line); }
.steps li::before { content: counter(step); grid-row: span 2; font: 400 2.5rem/1 var(--font-display); color: var(--plum); font-variant-numeric: lining-nums; }
.steps p { color: var(--ink-2); }
.how__note { grid-column: 2; padding: 1.25rem 1.5rem; background: var(--lilac-soft); border-radius: var(--radius-small); color: var(--ink); }

/* ---------- Client stories (the one dark band) ---------- */
.stories { background: var(--night); color: var(--night-ink); }
.stories h2 { color: var(--night-ink); margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.stories__grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); grid-template-rows: auto auto; gap: clamp(2rem, 4vw, 3.5rem) clamp(2rem, 6vw, 5rem); }
.story { margin: 0; display: grid; gap: 1rem; align-content: start; }
.story p { font: 400 var(--step-1)/1.5 var(--font-display); color: var(--night-ink); }
.story--lead { grid-row: span 2; }
.story--lead p { font-size: var(--step-2); line-height: 1.4; }
.story footer { font-size: var(--step--1); letter-spacing: 0.02em; color: var(--night-ink-2); }
.story + .story:not(.story--lead) { padding-top: clamp(2rem, 4vw, 3rem); border-top: 1px solid rgba(244, 239, 246, 0.16); }

/* ---------- Book a call ---------- */
.book { background: var(--lilac-soft); }
.book__inner { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(2rem, 6vw, 6rem); align-items: start; }
.book__copy { display: grid; gap: 1.25rem; }
.facts { list-style: none; display: grid; gap: 0.9rem; margin-top: 0.75rem; }
.facts li { display: flex; gap: 0.8rem; align-items: flex-start; color: var(--ink); }
.facts .icon { color: var(--plum); margin-top: 0.15rem; }
.book__panel { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); padding: clamp(1.5rem, 4vw, 2.75rem); }

.form { display: grid; gap: 1.25rem; }
.field { display: grid; gap: 0.45rem; }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.field label { font-weight: 600; font-size: 0.98rem; }
.optional { font-weight: 400; color: var(--ink-2); }
.field input, .field textarea {
  width: 100%; min-height: 50px; padding: 0.75rem 0.95rem; border: 1px solid #857489; border-radius: var(--radius-small);
  background: var(--white); color: var(--ink); font: 400 1rem/1.5 var(--font-body);
  transition: border-color 180ms ease, box-shadow 180ms ease;
}
.field textarea { resize: vertical; min-height: 120px; }
.field input:hover, .field textarea:hover { border-color: #5e4f65; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--plum); box-shadow: 0 0 0 3px rgba(78, 53, 87, 0.22); }
.field [aria-invalid="true"] { border-color: var(--error); }
.field__hint { margin-top: -0.5rem; font-size: var(--step--1); color: var(--ink-2); }
.field__error { font-size: var(--step--1); font-weight: 600; color: var(--error); }
.form-errors { padding: 0.9rem 1.1rem; border-radius: var(--radius-small); background: #fbeaec; color: var(--error); }
.form-errors:focus { outline: 2px solid var(--error); outline-offset: 2px; }
.form .button { justify-self: start; }
.form__privacy { font-size: var(--step--1); color: var(--ink-2); }
.form-done { display: grid; gap: 0.75rem; }
.form-done:focus { outline: none; }
.form-done h3 { font-size: var(--step-2); }
.hp { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Service pages ---------- */
.page-hero { background: var(--lilac-soft); }
.page-hero__inner { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(2rem, 6vw, 5rem); align-items: center; padding-block: clamp(3rem, 7vw, 6rem); }
.page-hero__copy { display: grid; gap: 1.5rem; }
.page-hero__copy h1 { font-size: clamp(2.3rem, 1.6rem + 3vw, 3.9rem); }
.page-hero__photo { margin: 0; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.page-hero__photo img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4 / 3.4; transition: transform 700ms var(--ease-out); }
.page-hero__photo:hover img { transform: scale(1.025); }
.price-note { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; font-size: var(--step--1); font-weight: 500; color: var(--ink-2); list-style: none; }
.price-note li { display: flex; align-items: center; gap: 0.45rem; }
.price-note .icon { color: var(--plum); width: 1.15rem; height: 1.15rem; }

.split__inner { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(1.5rem, 6vw, 6rem); align-items: start; }
.split__head { display: grid; gap: 1rem; }
.prose { max-width: 40rem; color: var(--ink-2); }
.prose p:first-child { font-size: var(--step-1); line-height: 1.55; color: var(--ink); }
.prose h3 { margin: 2.25rem 0 0.75rem; font-size: var(--step-2); }

.topics { background: var(--lilac-soft); }
.checklist { list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 clamp(2rem, 5vw, 4rem); border-top: 1px solid var(--lilac-line); }
.checklist li { display: flex; gap: 0.9rem; align-items: flex-start; padding-block: 1.25rem; border-bottom: 1px solid var(--lilac-line); }
.checklist .icon { color: var(--plum); margin-top: 0.2rem; }
.checklist strong { display: block; font-weight: 600; color: var(--ink); }
.checklist span { color: var(--ink-2); }
.topics__note { margin-top: 2rem; max-width: 40rem; color: var(--ink-2); }

.quote-band { padding-block: clamp(3.5rem, 7vw, 6rem); }
.quote-band blockquote { margin: 0 auto; max-width: 50rem; text-align: center; display: grid; gap: 1.25rem; }
.quote-band blockquote p { font: italic 400 clamp(1.6rem, 1.2rem + 1.8vw, 2.5rem)/1.3 var(--font-display); color: var(--ink); text-wrap: balance; }
.quote-band blockquote footer { color: var(--ink-2); font-size: var(--step--1); }

.stories__grid--pair { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: auto; }
.stories__grid--pair .story + .story { padding-top: 0; border-top: 0; }
.stories__grid--single { grid-template-columns: minmax(0, 1fr); max-width: 52rem; }
.stories__grid--single .story p + p { margin-top: 0.75em; }

/* ---------- Privacy and 404 ---------- */
.doc { padding-block: clamp(3rem, 7vw, 6rem); }
.doc__inner { max-width: 46rem; display: grid; gap: 1rem; }
.doc h1 { font-size: var(--step-3); margin-bottom: 0.5rem; }
.doc h2 { font-size: var(--step-2); margin-top: 1.75rem; }
.doc p, .doc li { color: var(--ink-2); }
.doc ul { padding-left: 1.25rem; display: grid; gap: 0.4rem; }
.doc__updated { font-size: var(--step--1); }
.not-found { min-height: 60svh; display: grid; align-items: center; background: var(--lilac-soft); }
.not-found__inner { display: grid; gap: 1.25rem; max-width: 40rem; padding-block: clamp(4rem, 10vw, 8rem); }
.not-found ul { list-style: none; display: grid; gap: 0.6rem; margin-top: 0.5rem; }

/* ---------- Footer ---------- */
.site-footer { background: var(--paper); border-top: 1px solid var(--lilac-line); padding-block: clamp(3rem, 6vw, 4.5rem) 2rem; }
.site-footer__inner { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2.5rem 4rem; align-items: start; }
.site-footer__brand { display: grid; gap: 1rem; max-width: 26rem; color: var(--ink-2); }
.site-footer__brand img { width: 180px; }
.site-footer__nav { display: grid; grid-template-columns: repeat(2, auto); gap: 0 3.5rem; }
.site-footer__nav ul { list-style: none; display: grid; gap: 0.6rem; align-content: start; }
.site-footer__nav a { color: var(--ink); text-decoration: none; }
.site-footer__nav a:hover { text-decoration: underline; }
.site-footer__legal { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 0.5rem 2rem; margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid var(--lilac-line); font-size: var(--step--1); color: var(--ink-2); }
.site-footer__legal p + p { margin-top: 0; }

.mobile-cta { display: none; }

/* ---------- Gentle reveal on scroll (only when JS has run; content is visible without it) ----------
   main.js gives each child of a [data-reveal-group] its own reveal and staggers the ones that arrive together. */
@media (prefers-reduced-motion: no-preference) {
  .js-reveal [data-reveal]:not(.is-visible) { opacity: 0; transform: translateY(24px); }
  .js-reveal [data-reveal] { transition: opacity 900ms var(--ease-out), transform 1100ms var(--ease-out); }
  .js-reveal [data-reveal="late"] { transition-delay: 140ms; }
  /* Photographs: the frame rises and the picture settles from a slight zoom */
  .js-reveal [data-reveal="photo"]:not(.is-visible) img { transform: scale(1.08); }
  .js-reveal [data-reveal="photo"] img { transition-duration: 1600ms; }
  /* The four steps: each rule draws in from the left as its step arrives */
  .steps li { border-top: 0; background: linear-gradient(var(--lilac-line), var(--lilac-line)) 0 0 / 100% 1px no-repeat; }
  .js-reveal .steps li[data-reveal] { transition: opacity 900ms var(--ease-out), transform 1100ms var(--ease-out), background-size 1200ms var(--ease-out); }
  .js-reveal .steps li[data-reveal]:not(.is-visible) { background-size: 0 1px; }

  /* Smooth page-to-page navigation (browsers without support simply load the page as normal) */
  @view-transition { navigation: auto; }
  .site-header { view-transition-name: site-header; }
  ::view-transition-old(root) { animation: 200ms ease-in both page-out; }
  ::view-transition-new(root) { animation: 560ms var(--ease-out) both page-in; }
}
@keyframes page-out { to { opacity: 0; } }
@keyframes page-in { from { opacity: 0; transform: translateY(12px); } }

/* ---------- Form: a clear "sending" state while the message goes ---------- */
.button[aria-busy="true"] { pointer-events: none; background: var(--plum-deep); }
.button[aria-busy="true"] .icon-arrow { display: none; }
.button[aria-busy="true"]::after {
  content: ""; width: 1.05em; height: 1.05em; border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.35); border-top-color: var(--white);
  animation: spin 800ms linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Tablet ---------- */
@media (max-width: 980px) {
  .site-nav ul a { font-size: 0.95rem; }
  .site-nav ul { gap: 1.1rem; }
  .about__inner, .how__inner, .book__inner, .split__inner { grid-template-columns: minmax(0, 1fr); }
  .page-hero__inner { grid-template-columns: minmax(0, 1fr); }
  .page-hero__photo { max-width: 560px; }
  .stories__grid--pair { grid-template-columns: minmax(0, 1fr); }
  .how__head { position: static; }
  .how__note { grid-column: auto; }
  .about__photo { max-width: 420px; }
  .stories__grid { grid-template-columns: minmax(0, 1fr); }
  .story--lead { grid-row: auto; }
}

/* ---------- Mobile navigation ---------- */
@media (max-width: 860px) {
  :root { --header-h: 64px; }
  .menu-toggle {
    display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; margin-right: -10px;
    border: 0; border-radius: 999px; background: transparent; color: var(--ink); cursor: pointer;
  }
  .menu-toggle .icon { width: 28px; height: 28px; }
  .menu-toggle__close { display: none; }
  .menu-toggle[aria-expanded="true"] .menu-toggle__open { display: none; }
  .menu-toggle[aria-expanded="true"] .menu-toggle__close { display: block; }
  .site-nav {
    position: fixed; inset: var(--header-h) 0 0 0; z-index: 49; flex-direction: column; align-items: stretch; justify-content: flex-start; gap: 2rem;
    padding: 2rem max(var(--gutter), env(safe-area-inset-right, 0px)) calc(2rem + env(safe-area-inset-bottom, 0px)) max(var(--gutter), env(safe-area-inset-left, 0px));
    background: var(--paper); visibility: hidden; opacity: 0; transform: translateY(-8px);
    transition: opacity 200ms ease, transform 300ms var(--ease-out), visibility 0s linear 300ms;
  }
  .site-nav.is-open { visibility: visible; opacity: 1; transform: none; transition: opacity 150ms ease, transform 300ms var(--ease-out); }
  .site-nav ul { flex-direction: column; gap: 0; }
  .site-nav ul a { display: block; padding: 1rem 0; font: 500 1.6rem/1.2 var(--font-display); border-bottom: 1px solid var(--lilac-line); background: none; }
  .site-nav__cta { min-height: 56px; font-size: 1.05rem; }
  body.menu-open { overflow: hidden; }
}
/* Menu links arrive one after another when the menu opens */
@media (max-width: 860px) and (prefers-reduced-motion: no-preference) {
  .site-nav li, .site-nav .site-nav__cta { opacity: 0; transform: translateY(12px); transition: opacity 260ms ease, transform 420ms var(--ease-out); }
  .site-nav.is-open li, .site-nav.is-open .site-nav__cta { opacity: 1; transform: none; }
  .site-nav.is-open li:nth-child(1) { transition-delay: 60ms; }
  .site-nav.is-open li:nth-child(2) { transition-delay: 110ms; }
  .site-nav.is-open li:nth-child(3) { transition-delay: 160ms; }
  .site-nav.is-open li:nth-child(4) { transition-delay: 210ms; }
  .site-nav.is-open .site-nav__cta { transition-delay: 270ms; }
}

/* ---------- Phones ---------- */
@media (max-width: 720px) {
  .hero__inner { grid-template-columns: minmax(0, 1fr); min-height: 0; gap: 0; }
  .hero__copy { padding-block: 2.5rem 1.5rem; }
  .hero__portrait { justify-self: stretch; width: auto; max-width: 420px; margin-block: 0.5rem 2.5rem; }
  .hero__actions .button { width: 100%; }
  .help-list { grid-template-columns: minmax(0, 1fr); }
  .help-list li:nth-child(odd) { border-right: 0; }
  .help-item { padding-inline: 0; }
  .help-item:hover { background: transparent; }
  .field-row { grid-template-columns: minmax(0, 1fr); }
  .checklist { grid-template-columns: minmax(0, 1fr); }
  .page-hero__copy .button { width: 100%; }
  .form .button { width: 100%; }
  .site-footer__inner { grid-template-columns: minmax(0, 1fr); }
  .site-footer__nav { grid-template-columns: minmax(0, 1fr); gap: 0.6rem; }
  .mobile-cta {
    display: flex; position: fixed; z-index: 40; left: 0; right: 0; bottom: 0; border-radius: 0; min-height: 56px;
    padding-bottom: calc(0.8rem + env(safe-area-inset-bottom, 0px));
    transform: translateY(110%); transition: transform 320ms var(--ease-out);
  }
  .mobile-cta.is-shown { transform: none; }
  body { padding-bottom: 0; }
}

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