/* ============================================================
   Yarra Gardens — shared site framework
   Rules below are byte-identical across all pages (extracted from
   the former per-page inline <style> blocks). Link this file in
   <head> BEFORE each page's small page-specific inline <style>.
   Source order is preserved — the cascade depends on it.
   ============================================================ */

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

/* Lenis owns scroll smoothness now (see site.js); keep the native
   behaviour 'auto' so Lenis and the skip-link anchor jump don't fight a
   second smoothing layer. */
html { scroll-behavior: auto; }

:root {
  --bg: #f2f0ec;
  --text: #1a1a1a;
  --muted: #888;
  --border: #ccc;
  --error: #b34a4a;
  /* Refined forest green — used SPARINGLY (link/CTA hover, active nav
     underline, scroll-progress hairline). Never for body text or fills. */
  --accent: #3c4a3e;
  /* Deep near-black forest — backdrop for the ONE cinematic dark band per
     page. Cream (--bg) text sits on it at ~14:1, comfortably AA/AAA. */
  --ink: #1c2118;

  /* Type scale tokens (available for reuse — not retrofitted everywhere).
     Re-tuned upward a notch for Fraunces, which has a taller cap height and
     reads more editorially. Mobile floors kept sane so long strings still
     wrap to <=3 lines at ~375px. */
  --font-display: 'Fraunces', Georgia, serif;
  --font-sans: 'Montserrat', sans-serif;
  --t-h1: clamp(38px, 5.4vw, 72px);
  --t-h2: clamp(28px, 3.5vw, 48px);
  --t-h3: clamp(21px, 2.5vw, 32px);
  --t-body: clamp(13px, 1.2vw, 15px);
  --t-label: 10px;

  /* 8-pt spacing tokens */
  --s-1: 8px;  --s-2: 16px; --s-3: 24px; --s-4: 32px;
  --s-5: 40px; --s-6: 48px; --s-8: 64px; --s-10: 80px;
  --s-12: 96px;

  /* ── Tweakable motion / texture knobs (safe to adjust on preview) ── */
  --grain-opacity: 0.04;     /* paper-grain overlay strength */
  --reveal-duration: 1.7s;   /* base scroll-reveal duration (unhurried) */
  --lenis-duration: 1.3;     /* Lenis smooth-scroll weight (Apple cadence) —
                                read in the Lenis init in site.js. Larger = a
                                touch slower/weightier; keep modest so native
                                scrollY stays synced and never feels laggy. */
  --magnetic-max: 8px;       /* max magnetic-CTA pull toward cursor */
  --intro-duration: 1.4s;    /* intro veil total runtime */
  --parallax-max: 0.10;      /* framed-image parallax travel, as a fraction of
                                wrap height — MUST stay <= the 0.10 slack the
                                .parallax img height:120%/top:-10% provides, or
                                the image edge would expose a gap */
  --marquee-duration: 75s;   /* whisper-ribbon loop time (one full -50% cycle) — slow + editorial */
  --marquee-opacity: 0.55;   /* quiet-ribbon micro-cap text strength */
  --cursor-size: 7px;        /* custom-cursor inner dot diameter */
  --cursor-ring: 34px;       /* custom-cursor trailing ring diameter */
  --reading-floor: 0.5;      /* B1 scroll-reading reveal: resting word opacity
                                (legible at rest; warms to 1 as the block scrolls
                                through). 0.5 cream on --ink stays AA. */
  --header-h: 84px;          /* live sticky-header height — set precisely in
                                recompute() (site.js) from the header's measured
                                box. Read by the B2 pinned scene's .pin-stage so
                                the sticky stage clears the header. Default is a
                                sane first-paint guess. */
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-weight: 300;
  font-size: 13px;
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  /* Optical sizing on for Fraunces (opsz axis) across the page. */
  font-optical-sizing: auto;
  /* Horizontal-scroll guard for full-bleed sections. `clip` (NOT hidden)
     is sticky-SAFE — it does not create a scroll container, so the sticky
     header keeps working. NEVER use overflow:hidden or transform here. */
  overflow-x: clip;
  /* Page-load fade — supersedes a hard cut between pages */
  opacity: 0;
  animation: pageFadeIn 0.6s ease-out 0.04s forwards;
}
@keyframes pageFadeIn { to { opacity: 1; } }

/* Where View Transitions are supported, the cross-fade IS the entry — drop
   the body fade to avoid a double-fade. (Reduced-motion neutralises VT
   separately, so the body fade is still skipped there too.) */
@supports (view-transition-name: none) {
  body { animation: none; opacity: 1; }
}

/* ── PAGE TRANSITIONS ── (declarative cross-fade between same-origin
   navigations; NO JavaScript). Non-supporting browsers just navigate
   normally — the pageFadeIn body fade above is their entry. Reduced-motion
   neutralises this in the @media block below. */
@view-transition { navigation: auto; }
::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 0.5s;
  animation-timing-function: ease;
}

/* ── PAPER GRAIN ── (whisper-faint tiled noise; barely perceptible)
   Fixed full-viewport overlay, pointer-events:none so it never blocks
   clicks. mix-blend-mode:multiply lets the cream show through. The noise
   is an inline feTurbulence SVG data-URI (no network request). */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: var(--grain-opacity);
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 160px 160px;
}

/* ── INTRO VEIL ── (first load, once per session; see inline head guard +
   site.js cleanup). Default HIDDEN so no-JS / repeat visits never see it and
   content is never hidden. It is shown ONLY under html.intro, which the tiny
   inline head guard adds before paint on the first session — so it covers
   from frame 1 (no FOUC) and a CSS animation dismisses it (~--intro-duration,
   forwards, ending pointer-events:none + opacity:0). Reduced-motion is
   double-guarded: the inline guard won't add html.intro, and the @media
   block forces display:none. */
#intro-veil { display: none; }
html.intro #intro-veil {
  display: flex;
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: var(--bg);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 22px;
  /* in (cover) -> hold -> lift/out. Drives the whole veil's fade+rise out. */
  animation: introVeil var(--intro-duration) cubic-bezier(0.4, 0, 0.2, 1) forwards;
}
html.intro #intro-veil .intro-mark {
  width: clamp(46px, 7vw, 72px);
  height: auto;
  opacity: 0;
  transform: translateY(8px) scale(0.96);
  animation: introMark calc(var(--intro-duration) * 0.62) cubic-bezier(0.16, 0.84, 0.24, 1) 0.05s forwards;
}
html.intro #intro-veil .intro-word {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: clamp(11px, 1.6vw, 14px);
  letter-spacing: 0.42em;
  text-indent: 0.42em;       /* balance the trailing tracking */
  text-transform: uppercase;
  color: var(--text);
  opacity: 0;
  transform: translateY(6px);
  animation: introWord calc(var(--intro-duration) * 0.5) ease-out 0.22s forwards;
}
@keyframes introVeil {
  0%, 58%  { opacity: 1; transform: translateY(0); }
  100%     { opacity: 0; transform: translateY(-12px); pointer-events: none; }
}
@keyframes introMark {
  to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes introWord {
  to { opacity: 1; transform: translateY(0); }
}
/* When the veil is the entry, suppress the body pageFadeIn so they don't
   stack (the veil lift IS the reveal of the page beneath). */
html.intro body { animation: none; opacity: 1; }

/* ── DISPLAY HEADINGS — Fraunces refinements ──
   Optical sizing, ligatures + oldstyle figures, and a slight negative
   tracking so large Fraunces settings read as intended. Body stays
   Montserrat (untouched). The .site-title wordmark is deliberately
   EXCLUDED (it stays Montserrat — do not restyle the logotype). */
h1, h2, h3, blockquote {
  font-optical-sizing: auto;
  font-feature-settings: "liga" 1, "onum" 1;
  letter-spacing: -0.015em;
}

/* Reusable inline text link */
.text-link {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  padding-bottom: 1px;
  transition: border-color 0.2s ease;
}
.text-link:hover { border-bottom-color: var(--accent); }

/* ── MAGNETIC CTA ── (primary buttons subtly pull toward the cursor).
   JS (site.js) owns the transform while pointing — it writes a translate
   capped at --magnetic-max that already folds in the -1px hover lift, so it
   never fights the page-level `:hover { transform: translateY(-1px) }`.
   On mouseleave JS clears the inline transform and this transition springs
   it back. Only bound when canHover && !reduced-motion; otherwise the
   element behaves exactly as before. The hover colour swap is a separate
   accent tint, applied without disturbing the page's own hover rule. */
.magnetic {
  transition: transform 0.3s cubic-bezier(0.2, 0.7, 0.2, 1),
              background-color 0.25s ease, color 0.25s ease,
              border-color 0.25s ease;
  will-change: transform;
}
.magnetic:hover { border-color: var(--accent); }

/* ── SKIP LINK ── (visually hidden until focused) */
.skip-link {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 300;
  padding: 10px 16px;
  background: var(--text);
  color: var(--bg);
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 2px;
  transform: translateY(-150%);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.skip-link:focus {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

/* ── INTERACTIVE / FOCUS STATES ── */
*:focus { outline: none; }
*:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 3px;
  border-radius: 1px;
}

/* ── IMG WRAP — cursor-tracking 3D shadow ──
   Shadow offset is driven by --shadow-x / --shadow-y, set by JS
   on mousemove. Cursor on top-left → both negative → shadow falls
   to top-left, giving a directional "lit by cursor" feel. */
.img-wrap {
  --shadow-x: 0px;
  --shadow-y: 0px;
  --shadow-strength: 0;
  overflow: hidden;
  box-shadow:
    calc(var(--shadow-x) * 1.2) calc(var(--shadow-y) * 1.2) 44px -14px rgba(20, 22, 18, calc(0.26 * var(--shadow-strength))),
    calc(var(--shadow-x) * 0.5) calc(var(--shadow-y) * 0.5) 16px -6px  rgba(20, 22, 18, calc(0.16 * var(--shadow-strength)));
  transition: box-shadow 0.45s cubic-bezier(0.2, 0.7, 0.2, 1);
  will-change: box-shadow;
}
.img-wrap img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.04);
}
.img-wrap:not(:hover) {
  --shadow-x: 0px;
  --shadow-y: 0px;
  --shadow-strength: 0;
  transition: box-shadow 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}

/* ── SCROLL-REVEAL ── (granular: every photo + content block fades in)
   Driven by the SINGLE IntersectionObserver in site.js which toggles
   .in-view. Base duration is a touch slower (--reveal-duration) for an
   unhurried, editorial feel. */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity var(--reveal-duration) cubic-bezier(0.2, 0.7, 0.2, 1) var(--reveal-delay, 0s),
              transform var(--reveal-duration) cubic-bezier(0.2, 0.7, 0.2, 1) var(--reveal-delay, 0s);
  will-change: opacity, transform;
}
.reveal.in-view { opacity: 1; transform: translateY(0); }

/* ── REVEAL MODIFIER: MASK ── (CSS-only, used alongside .reveal on
   .img-wrap elements). The WRAP fades opacity 0->1; the inner IMG does a
   clip-path wipe + a subtle scale settle. clip-path is applied to the IMG,
   NEVER the wrap, so the wrap's cursor-shadow box-shadow isn't clipped. */
.reveal-mask {
  transform: none;            /* override the base translateY; the img moves */
  transition: opacity var(--reveal-duration) cubic-bezier(0.2, 0.7, 0.2, 1) var(--reveal-delay, 0s);
}
.reveal-mask.in-view { transform: none; }
.reveal-mask img {
  clip-path: inset(0 0 100% 0);
  transform: scale(1.06);
  transition: clip-path 1.1s cubic-bezier(0.16, 0.84, 0.24, 1) var(--reveal-delay, 0s),
              transform 1.1s cubic-bezier(0.16, 0.84, 0.24, 1) var(--reveal-delay, 0s);
  will-change: clip-path, transform;
}
.reveal-mask.in-view img {
  clip-path: inset(0 0 0 0);
  transform: scale(1);
}

/* ── REVEAL MODIFIER: TEXT ── (CSS-only, used alongside .reveal on major
   headings / intro copy). Whole-element soft blur + rise + fade. No line or
   character splitting. */
.reveal-text {
  opacity: 0;
  transform: translateY(18px);
  filter: blur(6px);
  transition: opacity 1.1s cubic-bezier(0.2, 0.7, 0.2, 1) var(--reveal-delay, 0s),
              transform 1.1s cubic-bezier(0.2, 0.7, 0.2, 1) var(--reveal-delay, 0s),
              filter 1.1s cubic-bezier(0.2, 0.7, 0.2, 1) var(--reveal-delay, 0s);
  will-change: opacity, transform, filter;
}
.reveal-text.in-view {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

/* Stagger children when parent has .reveal-stagger */
.reveal-stagger > *:nth-child(1)  { --reveal-delay: 0s; }
.reveal-stagger > *:nth-child(2)  { --reveal-delay: 0.08s; }
.reveal-stagger > *:nth-child(3)  { --reveal-delay: 0.16s; }
.reveal-stagger > *:nth-child(4)  { --reveal-delay: 0.24s; }
.reveal-stagger > *:nth-child(5)  { --reveal-delay: 0.32s; }
.reveal-stagger > *:nth-child(6)  { --reveal-delay: 0.40s; }
.reveal-stagger > *:nth-child(7)  { --reveal-delay: 0.48s; }
.reveal-stagger > *:nth-child(8)  { --reveal-delay: 0.56s; }
.reveal-stagger > *:nth-child(9)  { --reveal-delay: 0.64s; }
.reveal-stagger > *:nth-child(10) { --reveal-delay: 0.72s; }

/* ── SCROLL-PROGRESS HAIRLINE ── */
#scroll-progress {
  position: fixed;
  top: 0; left: 0;
  height: 3px; width: 0;
  background: var(--accent);
  opacity: 0;
  z-index: 200;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
#scroll-progress.active { opacity: 0.6; }

@media (prefers-reduced-motion: reduce) {
  body { animation: none; opacity: 1; }
  .reveal { opacity: 1; transform: none; transition: none; }
  /* All reveal variants show instantly — clear clip/blur/transform. */
  .reveal-mask, .reveal-text { opacity: 1; transform: none; filter: none; transition: none; }
  .reveal-mask img { clip-path: none; transform: none; transition: none; }
  .img-wrap, .img-wrap img { transition: none; }
  .hero img {
    animation: none !important; opacity: 1 !important; transform: none !important;
  }
  /* Keep the scroll-driven header from continuously morphing for
     reduced-motion users (JS snaps --logo-progress to 0/1). */
  #site-header, #site-header * { transition: none !important; }
  html { scroll-behavior: auto; }
  /* Disable the declarative page cross-fade. */
  ::view-transition-group(*),
  ::view-transition-old(*),
  ::view-transition-new(*) { animation: none !important; }
  /* Intro veil is already skipped by the inline guard (it won't add
     html.intro), but belt-and-suspenders in case the class is present. */
  #intro-veil { display: none !important; }

  /* ── SIGNATURE MOMENTS — reduced-motion neutralisation ──
     (1) dark band is static by nature — nothing to disable.
     (2) parallax: JS is gated on !reduceMQ so it never writes a transform;
         clear any inherited will-change and force transform:none belt-and-
         suspenders. The img keeps height:120%/top:-10% so it stays CENTRED. */
  .parallax img { transform: none; will-change: auto; }
  /* (3) hero object-position parallax: JS is gated, so --hero-py stays 50%
         (centred). No rule needed; the default token handles it.
     (4) custom cursor is never CREATED under reduced motion (JS gate) — no
         html.has-cursor, no nodes — so no CSS override is required.
     (5) marquee: stop the loop and show the first (readable) copy static. */
  .marquee-track { animation: none; transform: none; }
  /* (6) botanical dividers: show fully drawn, no stroke transition. */
  .svg-divider path { stroke-dashoffset: 0; transition: none; }
  /* B1 scroll-reading reveal: the JS warm-up is gated off, so show every word
     fully (overriding the resting floor) — the statement reads as static. */
  .w { opacity: 1 !important; transition: none; }
}

/* ── SITE HEADER ── (proportional, scroll-driven shrink)
   --logo-progress is set in JS based on scroll position relative to the
   hero. 0 = full size at top, 1 = compact size when hero has scrolled
   past. NOTE: header uses position: sticky — do NOT add overflow:hidden
   /clip or transform to any ancestor (html, body, wrappers). */
:root { --logo-progress: 0; }

#site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg);
  padding-left: var(--s-4);
  padding-right: var(--s-4);
  padding-top: calc(28px - 18px * var(--logo-progress));
  padding-bottom: calc(22px - 14px * var(--logo-progress));
  border-bottom: 1px solid rgba(204, 204, 204, calc(var(--logo-progress) * 0.6));
  box-shadow: 0 1px 0 rgba(0, 0, 0, calc(var(--logo-progress) * 0.03));
}

.site-title {
  /* B3 SHARED-ELEMENT TRANSITION: the wordmark is byte-identical and in the
     same position on every page, so naming it lets the cross-document View
     Transition persist it rock-solid across navigations (no flash/morph).
     Appears on exactly ONE element per page. The header itself is deliberately
     NOT named (its per-page .active nav state would morph). */
  view-transition-name: site-wordmark;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  width: 100%;
  font-family: var(--font-sans);
  font-weight: 400;
  /* Single clamp-based formula — sizes correctly at every viewport width,
     so no separate mobile font-size override is needed (avoids the old
     680px discontinuity). Endpoints expressed once as custom properties. */
  --title-full: clamp(18px, 3.2vw, 42px);
  --title-compact: clamp(11px, 1.5vw, 16px);
  font-size: calc(var(--title-full) - (var(--title-full) - var(--title-compact)) * var(--logo-progress));
  text-transform: uppercase;
  color: var(--text);
  text-decoration: none;
  user-select: none;
}
.site-title span { display: inline-block; }

.header-nav {
  display: flex;
  justify-content: space-between;
  width: 100%;
  margin-top: calc(14px - 8px * var(--logo-progress));
}
/* Nav links: AA-legible (#4a4a4a on cream) but still subordinate to the
   wordmark. ONE reusable animated underline (::after scaleX) replaces the old
   per-state border-bottom. Vertical padding keeps the tap target ~40px+. The
   visible :focus-visible outline comes from the shared *:focus-visible rule. */
.header-nav a {
  position: relative;
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #4a4a4a;
  text-decoration: none;
  padding: 12px 0;
  transition: color 0.2s;
}
.header-nav a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}
.header-nav a:hover::after,
.header-nav a:focus-visible::after,
.header-nav a.active::after { transform: scaleX(1); }
.header-nav a:hover { color: var(--text); }
.header-nav a.active { color: var(--text); }

/* ── HERO ── (standardized: 56vw / 660 max / 320 min across all pages) */
.hero {
  width: 100%;
  height: 56vw;
  max-height: 660px;
  min-height: 320px;
  overflow: hidden;
}
.hero img {
  /* B3 SHARED-ELEMENT TRANSITION: every page's hero shares the same box, so
     naming the hero image cross-dissolves it between pages. One element/page. */
  view-transition-name: page-hero;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.06);
  animation: heroEnter 1.8s cubic-bezier(0.16, 0.84, 0.24, 1) 0.15s forwards;
  will-change: opacity, transform;
  /* CINEMATIC HERO (signature moment 3): a SUBTLE scroll parallax driven by
     object-position — NOT transform. Using object-position keeps the hero's
     own getBoundingClientRect() stable (the header --logo-progress math reads
     it) and never collides with the heroEnter scale keyframe above. JS nudges
     --hero-py between ~40% and ~60% as the hero scrolls; default 50% is
     perfectly centred (so reduced-motion / no-JS sees a normal centred crop). */
  object-position: center var(--hero-py, 50%);
}
@keyframes heroEnter {
  to { opacity: 1; transform: scale(1); }
}

/* ============================================================
   SIGNATURE MOMENTS (additive — cream editorial base untouched)
   1 dark band · framed-image parallax · custom cursor ·
   kinetic marquee · botanical line-art dividers.
   Every motion here is reduced-motion-safe (see the single
   @media (prefers-reduced-motion: reduce) block above, which is
   extended for each of these).
   ============================================================ */

/* ── (1) CINEMATIC DARK BAND ── (full-bleed; ONE per page max)
   Deep forest --ink ground with cream text + a large Fraunces italic.
   Full-bleed via the SAME width:100vw + centring-margin escape the rest of
   the site uses; body's overflow-x:clip stops horizontal scroll and this is
   never an ancestor of #site-header (sticky stays safe). Static by nature —
   no internal motion, so nothing to gate for reduced motion. */
.dark-band {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  background: var(--ink);
  color: var(--bg);
  padding: var(--s-12) var(--s-4);
  text-align: center;
}
.dark-band .dark-band-inner {
  max-width: 880px;
  margin: 0 auto;
}
.dark-band .dark-band-label {
  display: block;
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  /* Cream dimmed to a soft sage — still well above AA on --ink. */
  color: rgba(242, 240, 236, 0.62);
  margin-bottom: var(--s-3);
}
.dark-band blockquote,
.dark-band p.dark-band-quote {
  font-family: var(--font-display);
  font-weight: 400;
  font-style: italic;
  font-size: clamp(26px, 3.6vw, 50px);
  line-height: 1.32;
  letter-spacing: -0.015em;
  color: var(--bg);
}
.dark-band cite {
  display: block;
  margin-top: var(--s-3);
  font-family: var(--font-sans);
  font-style: normal;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(242, 240, 236, 0.62);
}

/* ── B1: SCROLL-READING REVEAL (About #statement only) ──
   At init, site.js wraps each word of the statement paragraphs in <span.w>
   (spaces kept as text nodes between them, so wrapping / copy-paste / reading
   order are unaffected). The RESTING opacity is --reading-floor (legible — the
   words are never invisible), and onScroll warms each word toward 1 as the
   block passes up through the viewport. The transition softens the per-frame
   opacity writes. JS is gated on !reduceMQ; reduced-motion (and no-JS) shows
   the words at the floor, and the @media block below forces them fully on. */
.w {
  opacity: var(--reading-floor, 0.5);
  transition: opacity 0.3s ease;
}

/* ── (2) FRAMED-IMAGE PARALLAX ── (applied to a FEW feature .img-wrap only)
   The image is sized to 120% height and pulled up 10% so it sits CENTERED by
   default — meaning with NO JS (reduced motion, Lenis absent, or before the
   first scroll frame) it shows a correct, non-cropped frame. JS (onScroll in
   site.js) writes translateY on the IMG only, capped to ±--parallax-max of
   the wrap height so the image edge never exposes a gap. The wrap keeps its
   overflow:hidden (from .img-wrap) so the 20% overscan is clipped. transform
   lives on the inner img; any .reveal on the wrap animates the wrap — different
   element, no conflict. (Never combine with .reveal-mask — clip-path + this
   transform interplay is avoided per the design review.) */
.parallax img {
  position: relative;
  height: 120%;
  top: -10%;
  will-change: transform;
}

/* ── (5) KINETIC MARQUEE RIBBON ── (CSS-only; ONE per page, above footer)
   overflow:hidden lives ONLY on .marquee (a leaf element — NOT on body / html
   / .page-wrap / any #site-header ancestor, so sticky is safe). The track holds
   the real services list TWICE; translateX(-50%) loops the first copy out as the
   clone arrives, giving a seamless cycle. Pauses on hover. */
.marquee {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  overflow: hidden;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: var(--s-3) 0;
  margin-top: var(--s-10);
}
.marquee-track {
  display: flex;
  flex-wrap: nowrap;
  white-space: nowrap;
  width: max-content;
  animation: marquee var(--marquee-duration, 75s) linear infinite;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
/* Quiet editorial ribbon: small Montserrat micro-caps, widely tracked, in the
   muted tone at --marquee-opacity. Reads as a whisper, not a headline. */
.marquee-item {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-sans);
  font-size: clamp(11px, 1.4vw, 13px);
  text-transform: uppercase;
  letter-spacing: 0.3em;
  font-weight: 500;
  color: var(--muted);
  opacity: var(--marquee-opacity, 0.55);
  padding: 0 var(--s-4);
}
.marquee-sep {
  display: inline-flex;
  align-items: center;
  width: clamp(7px, 0.9vw, 11px);
  height: clamp(7px, 0.9vw, 11px);
  margin: 0 var(--s-2);
  color: var(--accent);
  opacity: var(--marquee-opacity, 0.55);
  flex: none;
}
.marquee-sep svg { width: 100%; height: 100%; display: block; }
@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ── (6) BOTANICAL LINE-ART DIVIDERS ── (draw-on-scroll; reuses the existing
   IntersectionObserver via .reveal → .in-view). Each <path> carries
   pathLength="1" so a dasharray/offset of 1 == the whole path; clearing the
   offset on .in-view draws it. Stroke-only, motif derived from the favicon
   leaf for brand cohesion. */
.svg-divider {
  display: block;
  width: 100%;
  max-width: 320px;
  margin: var(--s-10) auto;
  /* The wrapper is also tagged .reveal; neutralise the base translate so only
     the stroke draw reads (the wrapper still fades opacity 0→1). */
  transform: none;
}
.svg-divider svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}
.svg-divider path {
  fill: none;
  stroke: var(--muted);
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
}
.svg-divider.in-view path {
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 1.4s ease;
}
/* Stagger the leaves so the branch draws first, then leaves fill in. */
.svg-divider.in-view path:nth-child(2) { transition-delay: 0.5s; }
.svg-divider.in-view path:nth-child(3) { transition-delay: 0.62s; }
.svg-divider.in-view path:nth-child(4) { transition-delay: 0.74s; }
.svg-divider.in-view path:nth-child(5) { transition-delay: 0.86s; }
.svg-divider.in-view path:nth-child(6) { transition-delay: 0.98s; }
.svg-divider.in-view path:nth-child(7) { transition-delay: 1.10s; }
/* Accent variant for the occasional emphasised divider. */
.svg-divider.accent path { stroke: var(--accent); }

/* ── (4) CUSTOM CURSOR ── (dot + trailing ring; built in site.js ONLY when
   canHover && !reduced-motion). The ring trails purely via a CSS transition —
   NO perpetual rAF. Both layers are fixed, pointer-events:none, aria-hidden.
   Native cursor is hidden by html.has-cursor (added in JS), but text fields
   keep their I-beam via the carve-out so forms stay usable. */
.cursor-dot,
.cursor-ring {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 9999;
  pointer-events: none;
  border-radius: 50%;
  opacity: 0;
  /* ADAPTIVE CURSOR: white layers + mix-blend-mode:difference invert against
     ANY backdrop (crisp on the dark band / dark photos AND on the cream),
     so the cursor never gets lost. NOTE: will-change is intentionally NOT set
     on these elements — a will-change:transform would form a stacking context
     and isolate the blend, breaking the inversion. JS still drives transform
     inline (no perpetual rAF), which the compositor handles fine without it. */
  mix-blend-mode: difference;
  /* Centre the layer on the pointer; JS sets translate() before this. */
  transition: opacity 0.25s ease;
}
.cursor-dot {
  width: var(--cursor-size);
  height: var(--cursor-size);
  margin: calc(var(--cursor-size) / -2) 0 0 calc(var(--cursor-size) / -2);
  background: #fff;
}
.cursor-ring {
  width: var(--cursor-ring);
  height: var(--cursor-ring);
  margin: calc(var(--cursor-ring) / -2) 0 0 calc(var(--cursor-ring) / -2);
  border: 1px solid #fff;
  /* The trail: ring eases toward the dot's position. */
  transition: transform 0.16s ease-out, opacity 0.25s ease,
              width 0.2s ease, height 0.2s ease,
              margin 0.2s ease, border-width 0.2s ease;
}
.cursor-dot.cursor-visible,
.cursor-ring.cursor-visible { opacity: 1; }
/* Hover-grow over interactive / image targets — ring swells (and thickens
   slightly). NO accent tint/background here: a fill or colour swap is
   incompatible with mix-blend-mode:difference, so the hover state is the
   size grow + a marginally heavier border only. */
.cursor-ring.cursor-hover {
  width: calc(var(--cursor-ring) * 1.5);
  height: calc(var(--cursor-ring) * 1.5);
  margin: calc(var(--cursor-ring) * -0.75) 0 0 calc(var(--cursor-ring) * -0.75);
  border-width: 1.5px;
}
/* Hide the native cursor only once JS has built the custom one. Carve out text
   fields so the I-beam survives (forms stay legible/usable). */
html.has-cursor { cursor: none; }
html.has-cursor a,
html.has-cursor button,
html.has-cursor .magnetic,
html.has-cursor label,
html.has-cursor [data-cursor] { cursor: none; }
html.has-cursor input,
html.has-cursor textarea,
html.has-cursor select,
html.has-cursor [contenteditable] { cursor: text; }

/* ── OUTER WRAPPER ── */
.page-wrap { padding: 0 var(--s-4); }

/* ── FOOTER ── */
footer {
  border-top: 1px solid var(--border);
  margin: 0 var(--s-4);
  padding: var(--s-3) 0 var(--s-5);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: var(--s-3);
}
footer .footer-left {
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}
footer .footer-right {
  font-size: 10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: right;
}
footer .footer-right a { color: var(--muted); text-decoration: none; }
footer .footer-right a:hover { color: var(--text); }

/* ── MOBILE (shared header / page-wrap / footer rules) ── */
@media (max-width: 680px) {
  #site-header {
    padding-left: 20px;
    padding-right: 20px;
    padding-top: calc(16px - 8px * var(--logo-progress));
    padding-bottom: calc(12px - 6px * var(--logo-progress));
  }
  .header-nav { margin-top: calc(8px - 4px * var(--logo-progress)); }
  .header-nav a { font-size: 11px; letter-spacing: 0.16em; }
  .page-wrap { padding: 0 20px; }
  footer { margin: 0 20px; }

  footer { flex-direction: column; }
  footer .footer-right { text-align: left; }
}
