/* -------------------------------------------------------------------------
   Swiss grid + golden ratio (φ ≈ 1.618)
   Reference: large monitor (e.g. 2560×1440 / 4k) – generous top/bottom and
   negative space. All spacing scales from this ideal with safe minimums so
   the logo never gets cut off on small or landscape viewports.

   Proportion guide (match large-window spacing):
   - Vertical rhythm: 1 unit, φ (1.618), φ² (~2.618) between logo / wireframe / CTA
   - Safe top: max(1.25rem, 5vh) so logo always has room; increase 5vh if needed
   - Logo height: min(300px, 28vh, 20vw) – scales down on small/short viewports
   - CTA bottom: safe-bottom + space-3 for padding
   - Type scale: base × φ for CTA; scale with viewport (clamp)
   ------------------------------------------------------------------------- */
:root {
  --phi: 1.618;
  /* Base space unit: fluid so large screens get generous space, small get safe min */
  --space-base: clamp(0.5rem, 1.8vh + 0.25rem, 1.5rem);
  --space-1: var(--space-base);
  --space-2: calc(var(--space-base) * var(--phi));
  --space-3: calc(var(--space-base) * var(--phi) * var(--phi));
  /* Safe top margin so logo is never cut off (replaces 16.67vh - 150px) */
  --safe-top: max(1.25rem, 5vh);
  --safe-bottom: max(1rem, 4vh);
  /* Logo: scale down on short/narrow viewports; max 300px on large screens */
  --logo-height: min(300px, 28vh, 20vw);
  /* Horizontal margin: proportional to viewport, matches large-screen negative space */
  --margin-h: clamp(1rem, 5vw, 4rem);
  /* SVG position: gap from logo bottom = 50% of (space-2 - 3×space-1) */
  --svg-top: calc(var(--safe-top) + var(--logo-height) + (var(--space-2) - 3 * var(--space-1)) / 2);
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100vh; background: #0b0b0b; }
/* Safari: avoid 0-height canvas with fixed + 100vh */
html { height: 100%; -webkit-text-size-adjust: 100%; }
body { min-height: 100%; min-height: -webkit-fill-available; }
.varen-svg-bg {
  position: fixed;
  top: var(--svg-top);
  left: 23.5%;
  width: 53%;
  height: min(53%, calc(100vh - var(--svg-top) - 6rem));
  max-height: calc(100vh - var(--svg-top) - 6rem);
  object-fit: contain;
  object-position: center;
  z-index: 0;
  pointer-events: none;
  opacity: 1;
  transform: translateY(0);
  will-change: transform, opacity;
  transition: opacity 0.5s ease;
}
#canvas-wrap {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  opacity: 0;
  background: transparent;
  transition: opacity 0.5s ease;
}
#scene-canvas {
  display: block;
  width: 100%;
  height: 100%;
  min-width: 1px;
  min-height: 1px;
  background: transparent;
}
#logo {
  position: fixed;
  top: var(--safe-top);
  left: 50%;
  transform: translateX(-50%);
  height: var(--logo-height);
  width: auto;
  z-index: 2;
  pointer-events: none;
  transition: opacity 0.5s ease;
}
/* Additive store entry. Does not replace JOIN THE FIELD or the footer. */
.shop-entry {
  position: fixed;
  top: calc(0.65rem + env(safe-area-inset-top, 0px));
  right: clamp(0.75rem, 3vw, 2rem);
  z-index: 30;
  min-width: 44px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 10px;
  font-family: "Söhne Mono", "Soehne Mono", "SF Mono", Menlo, monospace;
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(244, 241, 234, 0.78);
  text-decoration: none;
}
.shop-entry:hover,
.shop-entry:focus-visible {
  color: #f4f1ea;
  outline: 1px solid rgba(244, 241, 234, 0.45);
  outline-offset: 2px;
}
.fallback-message {
  display: none;
  position: fixed;
  inset: 0;
  align-items: center;
  justify-content: center;
  background: #0b0b0b;
  color: #fff;
  padding: 2rem;
  text-align: center;
  z-index: 1;
}
/* Signifier — Klim Type Foundry.
   Italic variants are required for the joining-convention rule (`<em>&amp;</em>`
   renders the Signifier italic ampersand). Without a matching italic font face
   at each weight, browsers fall back to the system serif (Georgia), which
   produces the wrong ampersand glyph. See [[varen-joining-convention]]. */
@font-face {
  font-family: "Signifier";
  src: url("../assets/Fonts/WOFF2/signifier-thin.woff2") format("woff2");
  font-weight: 100; font-style: normal;
  font-display: block;
}
@font-face {
  font-family: "Signifier";
  src: url("../assets/Fonts/WOFF2/signifier-thin-italic.woff2") format("woff2");
  font-weight: 100; font-style: italic;
  font-display: block;
}
@font-face {
  font-family: "Signifier";
  src: url("../assets/Fonts/WOFF2/signifier-extralight.woff2") format("woff2");
  font-weight: 200; font-style: normal;
  font-display: block;
}
@font-face {
  font-family: "Signifier";
  src: url("../assets/Fonts/WOFF2/signifier-extralight-italic.woff2") format("woff2");
  font-weight: 200; font-style: italic;
  font-display: block;
}
@font-face {
  font-family: "Signifier";
  src: url("../assets/Fonts/WOFF2/signifier-light.woff2") format("woff2");
  font-weight: 300; font-style: normal;
  font-display: block;
}
@font-face {
  font-family: "Signifier";
  src: url("../assets/Fonts/WOFF2/signifier-light-italic.woff2") format("woff2");
  font-weight: 300; font-style: italic;
  font-display: block;
}
@font-face {
  font-family: "Signifier";
  src: url("../assets/Fonts/WOFF2/signifier-regular.woff2") format("woff2");
  font-weight: 400; font-style: normal;
  font-display: block;
}
@font-face {
  font-family: "Signifier";
  src: url("../assets/Fonts/WOFF2/signifier-regular-italic.woff2") format("woff2");
  font-weight: 400; font-style: italic;
  font-display: block;
}
@font-face {
  font-family: "Signifier";
  src: url("../assets/Fonts/WOFF2/signifier-medium.woff2") format("woff2");
  font-weight: 500; font-style: normal;
  font-display: block;
}
@font-face {
  font-family: "Signifier";
  src: url("../assets/Fonts/WOFF2/signifier-medium-italic.woff2") format("woff2");
  font-weight: 500; font-style: italic;
  font-display: block;
}

/* ── Söhne (proportional) — Klim Type Foundry ─────────────────────────
   German weight names mapped to CSS numeric weights:
     extraleicht (200)  ·  leicht (300)  ·  buch (400)  ·  kraftig (500)
     halbfett (600)  ·  dreiviertelfett (700)  ·  fett (800)  ·  extrafett (900)
   Each weight has a roman + a `-kursiv` (italic) variant.
   font-display: block = hold text invisible until the file loads — no fallback-font flash (font-flash fix 2026-06-10).
   Used in VAREN for: sans-serif body accents, future product copy, future shop UI. */
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-extraleicht.woff2") format("woff2"); font-weight: 200; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-extraleicht.woff2") format("woff2"); font-weight: 200; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-extraleicht-kursiv.woff2") format("woff2"); font-weight: 200; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-extraleicht-kursiv.woff2") format("woff2"); font-weight: 200; font-style: italic; font-display: block; }
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-leicht.woff2") format("woff2"); font-weight: 300; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-leicht.woff2") format("woff2"); font-weight: 300; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-leicht-kursiv.woff2") format("woff2"); font-weight: 300; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-leicht-kursiv.woff2") format("woff2"); font-weight: 300; font-style: italic; font-display: block; }
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-buch.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-buch.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-buch-kursiv.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-buch-kursiv.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: block; }
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-kraftig.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-kraftig.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-kraftig-kursiv.woff2") format("woff2"); font-weight: 500; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-kraftig-kursiv.woff2") format("woff2"); font-weight: 500; font-style: italic; font-display: block; }
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-halbfett.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-halbfett.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-halbfett-kursiv.woff2") format("woff2"); font-weight: 600; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-halbfett-kursiv.woff2") format("woff2"); font-weight: 600; font-style: italic; font-display: block; }
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-dreiviertelfett.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-dreiviertelfett.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-dreiviertelfett-kursiv.woff2") format("woff2"); font-weight: 700; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-dreiviertelfett-kursiv.woff2") format("woff2"); font-weight: 700; font-style: italic; font-display: block; }
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-fett.woff2") format("woff2"); font-weight: 800; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-fett.woff2") format("woff2"); font-weight: 800; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-fett-kursiv.woff2") format("woff2"); font-weight: 800; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-fett-kursiv.woff2") format("woff2"); font-weight: 800; font-style: italic; font-display: block; }
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-extrafett.woff2") format("woff2"); font-weight: 900; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-extrafett.woff2") format("woff2"); font-weight: 900; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne"; src: url("../assets/Fonts/WOFF2/soehne-extrafett-kursiv.woff2") format("woff2"); font-weight: 900; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne"; src: url("../assets/Fonts/WOFF2/soehne-extrafett-kursiv.woff2") format("woff2"); font-weight: 900; font-style: italic; font-display: block; }

/* ── Söhne Mono — Klim Type Foundry ────────────────────────────────────
   Same weight system as Söhne above. Used in VAREN for the engineering
   register: bracketed eyebrows (gold), stamp labels, and stamp lines.
   See varen-brand-grammar.md Rule 5 registers 1, 3, 4. */
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-extraleicht.woff2") format("woff2"); font-weight: 200; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-extraleicht.woff2") format("woff2"); font-weight: 200; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-extraleicht-kursiv.woff2") format("woff2"); font-weight: 200; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-extraleicht-kursiv.woff2") format("woff2"); font-weight: 200; font-style: italic; font-display: block; }
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-leicht.woff2") format("woff2"); font-weight: 300; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-leicht.woff2") format("woff2"); font-weight: 300; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-leicht-kursiv.woff2") format("woff2"); font-weight: 300; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-leicht-kursiv.woff2") format("woff2"); font-weight: 300; font-style: italic; font-display: block; }
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-buch.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-buch.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-buch-kursiv.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-buch-kursiv.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: block; }
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-kraftig.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-kraftig.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-kraftig-kursiv.woff2") format("woff2"); font-weight: 500; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-kraftig-kursiv.woff2") format("woff2"); font-weight: 500; font-style: italic; font-display: block; }
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-halbfett.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-halbfett.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-halbfett-kursiv.woff2") format("woff2"); font-weight: 600; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-halbfett-kursiv.woff2") format("woff2"); font-weight: 600; font-style: italic; font-display: block; }
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-dreiviertelfett.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-dreiviertelfett.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-dreiviertelfett-kursiv.woff2") format("woff2"); font-weight: 700; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-dreiviertelfett-kursiv.woff2") format("woff2"); font-weight: 700; font-style: italic; font-display: block; }
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-fett.woff2") format("woff2"); font-weight: 800; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-fett.woff2") format("woff2"); font-weight: 800; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-fett-kursiv.woff2") format("woff2"); font-weight: 800; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-fett-kursiv.woff2") format("woff2"); font-weight: 800; font-style: italic; font-display: block; }
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-extrafett.woff2") format("woff2"); font-weight: 900; font-style: normal; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-extrafett.woff2") format("woff2"); font-weight: 900; font-style: normal; font-display: block; }
@font-face { font-family: "Soehne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-extrafett-kursiv.woff2") format("woff2"); font-weight: 900; font-style: italic; font-display: block; }
@font-face { font-family: "Söhne Mono"; src: url("../assets/Fonts/WOFF2/soehne-mono-extrafett-kursiv.woff2") format("woff2"); font-weight: 900; font-style: italic; font-display: block; }
.cta-bottom {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 2;
  display: flex;
  justify-content: center;
  padding: var(--space-2) var(--margin-h) var(--safe-bottom);
  padding-bottom: max(var(--safe-bottom), var(--space-3));
  transition: opacity 0.5s ease;
}
.cta-bottom button,
.cta-bottom .cta-link {
  font-family: "Signifier", serif;
  /* Golden-ratio type scale: base scales with viewport, cap at large size */
  font-size: clamp(1rem, 0.5rem + 1.8vw, calc(1rem * var(--phi)));
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #fff;
  background: transparent;
  border: none;
  /* Top/bottom padding brings the hit area to ≥44px (WCAG 2.2 ergonomic
     comfort) without changing visible text size. min-height enforces
     the threshold even at small font-size clamp values. */
  padding: 0.625rem 1.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  box-sizing: border-box;
  cursor: pointer;
  /* Match the GSAP outline-draw timing: 0.7s, ease-out (power2.out ≈
     cubic-bezier(0.165, 0.84, 0.44, 1)). Bidirectional fade — gold engages
     on hover, returns to white when cursor leaves. */
  transition: color 0.7s cubic-bezier(0.165, 0.84, 0.44, 1);
  text-shadow: 0 1px 2px #0b0b0b, 0 3px 8px #0b0b0b, 0 5px 20px #0b0b0b, 0 8px 32px rgba(11, 11, 11, 0.95);
  text-decoration: none;
}
.cta-bottom button:hover,
.cta-bottom .cta-link:hover {
  /* Command Gold — pairs with the manifesto's emphasis color */
  color: #C8A96F;
}
.cta-bottom button:focus-visible,
.cta-bottom .cta-link:focus-visible {
  outline: 1px solid rgba(255, 255, 255, 0.6);
  outline-offset: 0.25rem;
}
#webgl-fallback:not([hidden]) { display: flex; }
/* The contact/lowest-floor mirror needs the SAME not-hidden -> flex override as
   #webgl-fallback. Without it the base .fallback-message{display:none} kept it
   hidden even after scene.js cleared [hidden] — that, not a z-index burial, is
   why ?force-fallback=contact rendered as a blank page. */
#contact-fallback:not([hidden]) { display: flex; }

/* ── Progressive-enhancement floor isolation (2026-06-16) ─────────────
   When a forced floor is active, <html> carries no-webgl (set before paint by
   the head script in index.html). The floor is then the SOLE layer: every
   rich-page chrome element is removed (not merely hidden) and the system
   cursor is restored. PE: the rich page simply never initializes here. */
html.no-webgl #canvas-wrap,
html.no-webgl #logo,
html.no-webgl #varen-svg-bg,
html.no-webgl .cta-bottom,
html.no-webgl #cta-border-lines,
html.no-webgl #custom-cursor,
html.no-webgl #cursor-liquid-morph,
html.no-webgl #cursor-coords,
html.no-webgl #quote-overlay,
html.no-webgl #idle-clock,
html.no-webgl .site-footer { display: none !important; }
html.no-webgl, html.no-webgl * { cursor: auto !important; }
/* The active floor sits alone, above anything that escapes the net above. */
html.no-webgl .fallback-message.floor { z-index: 2147483646; }

/* Bug A — at rest only the bare email form shows. The author-origin
   display:flex on these panes was tying the UA [hidden]{display:none} (same
   origin, flex wins), so both confirm panes rendered at once. Make hidden win
   (the welcome.css SVG-icon idiom). */
.floor__confirm[hidden],
.floor__mailto[hidden] { display: none !important; }

/* ── No-JS floor (deepest fallback) ───────────────────────────────────────
   .js-intro is added by the first <head> script; with scripts OFF it is never
   added. Without these rules the rich chrome leaks (its only hide path is the
   .js-intro rule) and the <noscript> contact floor stays display:none (base
   .fallback-message rule), so the page shows its static skeleton with a dead,
   JS-wired JOIN link. Mirror the html.no-webgl isolation, keyed on the absence
   of .js-intro: true only in the sub-ms before that head script runs (JS on,
   pre-paint) or permanently (JS off). Hide the chrome, restore the system
   cursor, and reveal the noscript floor (the only .fallback-message.floor
   without [hidden]; the #webgl/#contact mirrors keep [hidden] with JS off). */
html:not(.js-intro) #canvas-wrap,
html:not(.js-intro) #logo,
html:not(.js-intro) #varen-svg-bg,
html:not(.js-intro) .cta-bottom,
html:not(.js-intro) #cta-border-lines,
html:not(.js-intro) #custom-cursor,
html:not(.js-intro) #cursor-liquid-morph,
html:not(.js-intro) #cursor-coords,
html:not(.js-intro) #quote-overlay,
html:not(.js-intro) #idle-clock,
html:not(.js-intro) .site-footer { display: none !important; }
html:not(.js-intro), html:not(.js-intro) * { cursor: auto !important; }
html:not(.js-intro) .fallback-message.floor:not([hidden]) { display: flex; }
.fallback-message p { margin: 0; }

/* ── WebGL-off / no-JS RICH FLOOR (Fallback Floor Protocol, Switch 1) ──────
   Brand floor on #0b0b0b: VAREN lockup + brand statement + the inline join
   form (which reuses .join-form / .join-form__submit / .fallback-mailto from
   index.html's inline styles verbatim). Only the .floor* layout shell is new.
   Literal hex (this sheet predates the welcome.css token block). Eased only. */
.fallback-message.floor {
  flex-direction: column;
  overflow-y: auto;
  padding: clamp(1.5rem, 5vw, 3rem) clamp(1.25rem, 5vw, 3rem);
  -webkit-font-smoothing: antialiased;
}
.floor__inner {
  width: 100%;
  max-width: 34rem;
  margin: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: clamp(1.25rem, 3.5vw, 2rem);
  animation: floor-rise 0.6s cubic-bezier(0.22, 0.61, 0.36, 1) both;
}
@keyframes floor-rise {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  .floor__inner { animation: none; }
}
.floor__logo {
  width: clamp(190px, 42vw, 300px);
  height: auto;
  display: block;
}
.floor__statement {
  font-family: "Signifier", Georgia, "Times New Roman", serif;
  font-weight: 300;
  font-size: clamp(20px, 3.2vw, 30px);
  line-height: 1.25;
  letter-spacing: 0.005em;
  color: #f4f1ea;
  margin: 0;
  max-width: 22ch;
  text-wrap: balance;
}
.floor__statement .emphasis { font-style: italic; color: #c8a96f; }
.floor__statement--plain { max-width: 26ch; }
.floor__form { width: 100%; text-align: left; }
.floor__form .join-form__fineprint,
.floor__form .join-form__status { text-align: center; }
.floor__confirm,
.floor__mailto { width: 100%; display: flex; flex-direction: column; gap: 0.75rem; align-items: center; }
.floor__confirm-eyebrow {
  font-family: "Soehne Mono", "SF Mono", "Menlo", monospace;
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #c8a96f;
  margin: 0;
}
.floor__confirm-line,
.floor__noscript-line {
  font-family: "Signifier", Georgia, serif;
  font-weight: 300;
  font-size: clamp(15px, 1.6vw, 17px);
  line-height: 1.55;
  color: rgba(244, 241, 234, 0.82);
  margin: 0;
}
.floor__confirm-line { max-width: 44ch; }
.floor__noscript-line { max-width: 40ch; }

/* Idle (30s inactivity): button 47%, mountains 27%, logo + SVG 11%; restore on interaction */
body.is-idle .cta-bottom {
  opacity: 0.47 !important;
}
body.is-idle #canvas-wrap {
  opacity: 0.27 !important;
}
body.is-idle .varen-svg-bg,
body.is-idle #logo {
  opacity: 0.11 !important;
}
body.is-idle #quote-overlay {
  opacity: 0.11 !important;
}

/* Idle clock: Swiss grid + golden ratio (1.125² step), tabular nums so no shift */
.idle-clock {
  --clock-base: 2rem;
  --clock-scale: 1.125;   /* Swiss Major Second */
  --clock-step: 1.618;   /* Golden ratio for one factor */
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  font-family: "Signifier", serif;
  font-size: clamp(
    calc(var(--clock-base) * var(--clock-scale) * var(--clock-step)),
    calc(6.75vw * var(--clock-step)),
    calc(3.5rem * var(--clock-scale) * var(--clock-step))
  );
  font-weight: 400;
  letter-spacing: 0.12em;
  font-variant-numeric: tabular-nums;
  min-width: 8ch;
  text-align: center;
  color: #fff;
  opacity: 0;
  pointer-events: none;
  z-index: 10;
  transition: opacity 0.5s ease;
}
body.is-idle .idle-clock {
  opacity: 1;
}

/* Quote overlay – golden ratio grid, 67% black, Signifier Thin Italic */
.quote-overlay {
  position: fixed;
  inset: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 1.618rem;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}
.quote-overlay.is-visible {
  visibility: visible;
  /* opacity driven by JS (cursor distance) on desktop; transition for smooth fade */
  transition: opacity 0.6s ease, visibility 0.5s ease;
}
/* Desktop: let clicks pass through so CTA mailto still works */
@media (min-width: 1025px) {
  .quote-overlay.is-visible {
    pointer-events: none;
  }
}
/* Mobile/tablet: overlay captures taps so backdrop dismisses; backdrop leaves CTA area tappable */
@media (max-width: 1024px) {
  .quote-overlay.is-visible {
    pointer-events: auto;
  }
  .quote-overlay__backdrop {
    bottom: auto;
    height: calc(100vh - 5.5rem);
    cursor: pointer;
  }
}
.quote-overlay__backdrop {
  position: absolute;
  inset: 0;
  background: transparent;
  cursor: pointer;
}
/* Golden ratio grid: --phi = 1.618; type scale 1, φ, φ², φ³. Box +1φ width each side, text width unchanged. */
.quote-overlay__box {
  --phi: 1.618;
  --text-base: 1rem;
  --text-scale: calc(var(--text-base) * var(--phi));
  position: relative;
  width: 100%;
  max-width: min(44vw, 32rem);
  /* Equilateral triangle: width / height = 2 / √3 ≈ 1.1547.
     Setting aspect-ratio means the box always renders the correct
     equilateral proportions regardless of content height. */
  aspect-ratio: 2 / 1.732;
  overflow: visible;
  background: rgba(11, 11, 11, 0.72);
  -webkit-clip-path: polygon(0 0, 100% 0, 50% 100%);
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  /* Top + horizontal padding only; aspect-ratio governs total height */
  padding: 2.4rem 3rem 0;
  /* Stack content from the top so the four lines sit in the wide upper
     portion of the triangle and the apex extends below them. */
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  box-shadow: none;
  border-radius: 0;
}
.quote-overlay__text {
  font-family: "Signifier", serif;
  font-weight: 100;
  font-style: italic;
  /* Kelman type scale: H4 (1.97rem) — one step down from previous H3 (2.95) */
  font-size: clamp(1.5rem, 3vw + 1.2rem, 1.97rem);
  /* Tightened leading — between Kelman heading constant (1.176) and golden
     body (1.618). Display italic reads denser at this clamp. */
  line-height: 1.3;
  letter-spacing: 0.02em;
  /* Command Gold Light for body */
  color: #E7D6B2;
  text-shadow: 0 1px 2px rgba(11, 11, 11, 0.55), 0 2px 8px rgba(11, 11, 11, 0.4);
  margin: 0;
  white-space: pre-line;
  text-align: center;
}
/* Command Gold for the recurring "the challenge" phrase — two-tone read */
.quote-overlay__text .emphasis {
  color: #C8A96F;
}
.quote-overlay__text:not(:first-child) {
  /* Tighter than golden ratio — keeps the four lines as a compact block
     so they fit in the wide upper portion of the inverted triangle. */
  margin-top: 0.6em;
}
/* Mobile/tablet: overlay on logo tap; wider box, golden ratio, responsive text, no widows */
@media (max-width: 1024px) {
  #logo {
    pointer-events: auto;
    cursor: pointer;
  }
  .quote-overlay {
    padding: 1rem 1.618rem 5.5rem;
  }
  .quote-overlay__box {
    --phi: 1.618;
    max-width: min(96vw, 48rem);
    width: 100%;
    max-height: calc(100vh - 7rem);
    padding: calc(1rem * var(--phi)) calc(1.618rem * 2);
    overflow: hidden;
    flex-shrink: 1;
    min-height: 0;
  }
  .quote-overlay__text {
    font-size: clamp(0.8125rem, 2.4vw + 1.4vh, 1.25rem);
    line-height: 1.618;
    letter-spacing: 0.02em;
    orphans: 2;
    widows: 2;
    text-wrap: pretty;
  }
}

/* Tablet: 769px–1024px – same ratios, slightly smaller logo */
@media (min-width: 769px) and (max-width: 1024px) {
  :root {
    --logo-height: min(240px, 22vh, 18vw);
    --safe-top: max(1.25rem, 5vh);
  }
  html, body { overflow: hidden; }
  #logo {
    padding: var(--space-1);
    margin: 0;
    box-sizing: content-box;
  }
  .varen-svg-bg {
    top: var(--svg-top);
    left: 15%;
    width: 70%;
    max-height: calc(100vh - var(--svg-top) - 5rem);
  }
  .cta-bottom button,
  .cta-bottom .cta-link {
    font-size: clamp(1rem, 0.5rem + 1.5vw, 1.4rem);
  }
}

@media (min-width: 769px) and (max-width: 1024px) and (orientation: landscape) {
  :root {
    --logo-height: min(100px, 18vh, 14vw);
    --safe-top: max(0.75rem, 4vh);
  }
  #logo {
    padding: var(--space-1);
  }
  .varen-svg-bg {
    top: var(--svg-top);
    left: 18%;
    width: 64%;
    max-height: calc(100vh - var(--svg-top) - 4.5rem);
  }
  .cta-bottom {
    padding: var(--space-1) var(--margin-h) var(--safe-bottom);
  }
  .quote-overlay {
    padding: 0.75rem 1rem 4.5rem;
  }
  .quote-overlay__box {
    max-width: min(96vw, 48rem);
    max-height: calc(100vh - 5rem);
    padding: calc(0.9rem * var(--phi)) calc(1.618rem * 1.5);
    overflow: hidden;
  }
  .quote-overlay__text {
    font-size: clamp(0.7rem, 1.8vw + 1.2vh, 1rem);
    line-height: 1.618;
    orphans: 2;
    widows: 2;
    text-wrap: pretty;
  }
}

/* Mobile: up to 768px – safe top keeps logo visible */
@media (max-width: 768px) {
  :root {
    --logo-height: min(180px, 24vh, 22vw);
    --safe-top: max(1rem, 5vh);
  }
  html, body { overflow: hidden; }
  #logo {
    padding: var(--space-1);
    margin: 0;
    box-sizing: content-box;
  }
  .varen-svg-bg {
    top: var(--svg-top);
    left: 12%;
    width: 76%;
    max-height: calc(100vh - var(--svg-top) - 4rem);
  }
  .cta-bottom button,
  .cta-bottom .cta-link {
    font-size: clamp(0.95rem, 0.5rem + 3vw, 1.15rem);
    letter-spacing: 0.1em;
  }
}

/* Mobile portrait: Swiss grid (8pt base), same golden-ratio spacing */
@media (max-width: 768px) and (orientation: portrait) {
  :root {
    --grid: 0.5rem;
    --grid-margin: 1rem;
    --grid-gutter: 0.5rem;
    --grid-columns: 8;
  }
  #logo {
    padding: var(--grid-margin);
  }
  .varen-svg-bg {
    left: var(--grid-margin);
    width: calc(100% - 2 * var(--grid-margin));
  }
  .cta-bottom {
    padding: var(--space-2) var(--grid-margin) max(var(--safe-bottom), var(--space-3));
  }
  .quote-overlay {
    padding: var(--grid-margin) var(--grid-margin) 5.5rem;
  }
  .quote-overlay__box {
    --phi: 1.618;
    max-width: min(calc(100vw - 2 * var(--grid-margin)), 50rem);
    width: 100%;
    max-height: calc(100vh - 7rem);
    padding: calc(3 * var(--grid)) calc(var(--grid-margin) + var(--grid-gutter));
    overflow: hidden;
    flex-shrink: 1;
    min-height: 0;
  }
  .quote-overlay__text {
    font-size: clamp(0.8125rem, 2.4vw + 1.4vh, 1.25rem);
    line-height: 1.618;
    letter-spacing: 0.02em;
    orphans: 2;
    widows: 2;
    text-wrap: pretty;
  }
}

/* Mobile landscape: short viewport – safe top + smaller logo so never cut off */
@media (max-width: 768px) and (orientation: landscape) {
  :root {
    --logo-height: min(72px, 16vh, 12vw);
    --safe-top: max(0.5rem, 3vh);
  }
  #logo {
    padding: var(--space-1);
  }
  /* Landscape-phone wordmark: drop from 70% width to 50% so the VAREN
     letters don't dominate the viewport on iPhone landscape (e.g.
     844×390). Bryan QA 2026-05-12 — "varen logo wordmark / letters
     are still huge". Aspect-ratio-aware max-height too so the wordmark
     never eats the CTA's vertical space. */
  .varen-svg-bg {
    top: var(--svg-top);
    left: 25%;
    width: 50%;
    max-height: min(38vh, calc(100vh - var(--svg-top) - 5rem));
  }
  .cta-bottom {
    padding: var(--space-1) var(--margin-h) var(--safe-bottom);
  }
  .quote-overlay {
    padding: 0.5rem 1rem 4rem;
  }
  .quote-overlay__box {
    max-width: min(96vw, 48rem);
    max-height: calc(100vh - 4.5rem);
    padding: calc(0.75rem * var(--phi)) calc(1.618rem * 1.5);
    overflow: hidden;
  }
  .quote-overlay__text {
    font-size: clamp(0.65rem, 1.5vw + 1vh, 0.95rem);
    line-height: 1.618;
    orphans: 2;
    widows: 2;
    text-wrap: pretty;
  }
}

/* ── iPad portrait (744-1024 wide) ──
   The existing (max-width: 768px) breakpoints don't catch most iPads
   in portrait: iPad standard is 810, iPad Pro 11" is 834, iPad Pro 12.9"
   is 1024. They were falling through to the default desktop rule
   (`width: 53%`) which renders the wordmark at ~430-540px wide on a
   tall narrow viewport — visually dominant. This rule constrains the
   wordmark to a tighter 42% width with extra clearance above the CTA.
   Bryan QA 2026-05-12 — "Yes to the adjustments on the iPad". */
@media (min-width: 744px) and (max-width: 1024px) and (orientation: portrait) {
  .varen-svg-bg {
    top: var(--svg-top);
    left: 29%;
    width: 42%;
    max-height: min(34vh, calc(100vh - var(--svg-top) - 10rem));
  }
}

canvas {
  pointer-events: none !important;
}
