/* ==========================================================================
   Design tokens
   All colours meet WCAG AA for the text/background pairs they are used in.
   ========================================================================== */

@font-face {
  font-family: 'Marcellus';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/assets/fonts/marcellus-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: 'Jost';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/assets/fonts/jost-latin-var.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;
}

/* Metric-adjusted local fallbacks keep text from jumping when the web fonts load. */
@font-face {
  font-family: 'Marcellus Fallback';
  src: local('Georgia'), local('Times New Roman'), local('DejaVu Serif'), local('Liberation Serif');
  size-adjust: 100%;
  ascent-override: 97%;
  descent-override: 28%;
  line-gap-override: 0%;
}

@font-face {
  font-family: 'Jost Fallback';
  src: local('Arial'), local('Helvetica'), local('Liberation Sans'), local('DejaVu Sans');
  size-adjust: 96%;
  ascent-override: 111%;
  descent-override: 39%;
  line-gap-override: 0%;
}

:root {
  /* Palette */
  --navy-950: #0a1521;
  --navy-900: #0f1e2e;
  --navy-800: #162a3e;
  --navy-700: #1f3650;
  --slate-600: #3a5068;
  --slate-500: #536a82;
  --mist-400: #8fa3b6;
  --mist-300: #b4c3d0;
  --mist-200: #d4dee6;
  --mist-100: #e6edf2;
  --stone-50: #f6f3ee;
  --stone-100: #ede8e0;
  --stone-200: #ddd5c9;
  --brass-400: #c9ad7f; /* accent on dark backgrounds */
  --brass-500: #b39461; /* decorative lines */
  --brass-700: #765b2f; /* accent text on light backgrounds */
  --paper: #f4f0e8;
  --night: #0c1626;
  --ink: #16212d;
  --ink-soft: #46576a;
  --white: #ffffff;
  --error: #a3342a;
  --error-on-dark: #f2a9a0;
  --success: #2f6b4f;

  /* Semantic roles */
  --color-bg: var(--stone-50);
  --color-text: var(--ink);
  --color-text-muted: var(--ink-soft);
  --color-accent: var(--brass-700);
  --color-focus: #2b6cb0;
  --color-focus-on-dark: var(--brass-400);

  /* Typography */
  --font-serif: 'Marcellus', 'Marcellus Fallback', Georgia, 'Times New Roman', serif;
  --font-sans: 'Jost', 'Jost Fallback', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;

  --text-xs: 0.8125rem;
  --text-sm: 0.9375rem;
  --text-base: 1.0625rem;
  --text-lg: clamp(1.125rem, 1.05rem + 0.35vw, 1.3125rem);
  --text-xl: clamp(1.3rem, 1.15rem + 0.6vw, 1.6rem);
  --text-2xl: clamp(1.9rem, 1.45rem + 1.9vw, 3rem);
  --text-title: clamp(2.5rem, 1.5rem + 4vw, 5.25rem);
  --text-statement: clamp(2rem, 1.1rem + 3.6vw, 4.6rem);
  --text-hero: clamp(2rem, 1.3rem + 2.6vw, 3.6rem);

  --leading-tight: 1.12;
  --leading-snug: 1.3;
  --leading-body: 1.7;
  --tracking-eyebrow: 0.16em;

  /* Spacing scale */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4rem;
  --space-9: 6rem;
  --section-pad: clamp(4.5rem, 3rem + 6vw, 8.5rem);

  /* Layout */
  --container: 76rem;
  --container-narrow: 46rem;
  --gutter: clamp(1.25rem, 0.8rem + 2.4vw, 3rem);
  --header-height: 4.25rem;
  --edge: clamp(2.25rem, 1rem + 5vw, 5.5rem);
  --radius-sm: 2px;
  --radius: 4px;

  /* Motion */
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --duration: 220ms;
  --duration-reveal: 1000ms;
  --ease-out: cubic-bezier(0.16, 0.84, 0.24, 1);

  /* Elevation */
  --shadow-card: 0 1px 2px rgb(15 30 46 / 0.04), 0 12px 32px -18px rgb(15 30 46 / 0.28);
}

/* ==========================================================================
   Base: reset, typography, focus and accessibility helpers
   ========================================================================== */

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-height) + 1rem);
}

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

body {
  margin: 0;
  min-height: 100vh;
  background: var(--night);
  color: var(--color-text);
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--leading-body);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  /* Never a sideways scroll. On the body this applies to the viewport, so
     the sticky elements keep working. */
  overflow-x: hidden;
}

body.is-menu-open {
  overflow: hidden;
}

h1,
h2,
h3,
p,
ul,
ol,
dl,
dd,
figure,
address {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

address {
  font-style: normal;
}

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

h1,
h2,
h3 {
  font-family: var(--font-serif);
  font-weight: 400;
  line-height: var(--leading-tight);
  letter-spacing: 0;
  color: inherit;
  text-wrap: balance;
}

p {
  text-wrap: pretty;
}

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.22em;
}

input,
textarea,
button {
  font: inherit;
  color: inherit;
}

main:focus {
  outline: none;
}

/* Focus: always visible for keyboard users. */
:focus-visible {
  outline: 2px solid var(--color-focus);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

[data-ink='light'] :focus-visible,
.sheet--night :focus-visible,
.masthead:not(.is-scrolled) :focus-visible,
.masthead.is-menu-open :focus-visible {
  outline-color: var(--color-focus-on-dark);
}

.legal__body :focus-visible {
  outline-color: var(--color-focus);
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: var(--space-3);
  left: var(--space-3);
  z-index: 100;
  padding: var(--space-3) var(--space-4);
  background: var(--stone-50);
  color: var(--navy-900);
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius);
  transform: translateY(-200%);
  transition: transform var(--duration) var(--ease);
}

.skip-link:focus {
  transform: translateY(0);
}

::selection {
  background: var(--mist-200);
  color: var(--navy-900);
}

/* ==========================================================================
   Layout: the scene, the masthead, acts (windows and sheets), the finale
   ========================================================================== */

/* ---------------------------------------------------------------- scene */

.scene {
  position: fixed;
  inset: 0;
  z-index: 0;
  display: block;
  pointer-events: none;
  /* Never seen (the canvas is opaque), but it tells contrast checkers that
     text over the scene sits on a picture, not on the page colour. */
  background: linear-gradient(var(--night), var(--night));
}

/* A still drawing of the same view until the live scene starts. */
.backdrop {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: var(--night) url('/assets/images/view-south.svg') center bottom / cover no-repeat;
}

.scene-on .backdrop {
  display: none;
}

main,
.finale {
  position: relative;
  z-index: 1;
}

/* ------------------------------------------------------------- masthead */

.masthead {
  position: fixed;
  inset: 0 0 auto;
  z-index: 20;
  color: var(--stone-50);
  transition: background-color 400ms var(--ease), color 400ms var(--ease), box-shadow 400ms var(--ease);
}

.masthead.is-scrolled {
  background: rgb(244 240 232 / 0.88);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  backdrop-filter: blur(14px) saturate(1.2);
  color: var(--navy-900);
  box-shadow: 0 1px 0 rgb(15 30 46 / 0.08);
}

.masthead__inner {
  display: flex;
  align-items: center;
  gap: var(--space-5);
  height: var(--header-height);
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: inherit;
  text-decoration: none;
}

.brand__mark svg {
  width: 1.65rem;
  height: auto;
  color: var(--brass-400);
}

.masthead.is-scrolled .brand__mark svg {
  color: var(--brass-700);
}

.brand__word svg {
  width: 5.25rem;
  height: auto;
}

.masthead__nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: var(--space-5);
}

.masthead__nav ul {
  display: flex;
  gap: clamp(1rem, 0.2rem + 1.4vw, 2rem);
}

.masthead__nav a {
  position: relative;
  font-size: var(--text-sm);
  text-decoration: none;
  padding: 0.35rem 0;
}

.masthead__nav ul a::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 500ms var(--ease-out);
}

.masthead__nav ul a:hover::after,
.masthead__nav ul a[aria-current]::after {
  transform: scaleX(1);
  transform-origin: left;
}

.masthead__contact {
  padding: 0.5rem 1.1rem !important;
  border: 1px solid currentColor;
  border-radius: 999px;
  transition: background-color var(--duration) var(--ease), color var(--duration) var(--ease);
}

.masthead__contact:hover {
  background: var(--stone-50);
  color: var(--navy-900);
}

.masthead.is-scrolled .masthead__contact:hover {
  background: var(--navy-900);
  color: var(--stone-50);
}

.masthead__actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.lang-switch ul {
  display: flex;
  gap: 0.15rem;
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.12em;
}

.lang-switch a {
  display: inline-flex;
  min-width: 2.25rem;
  min-height: 2.25rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  text-decoration: none;
  opacity: 0.7;
  transition: opacity var(--duration) var(--ease);
}

.lang-switch a:hover,
.lang-switch a[aria-current] {
  opacity: 1;
}

.lang-switch a[aria-current] {
  box-shadow: inset 0 0 0 1px currentColor;
}

.menu-toggle {
  display: none;
  position: relative;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  background: none;
  border: 0;
  cursor: pointer;
}

.menu-toggle__bars,
.menu-toggle__bars::before {
  position: absolute;
  left: 0.65rem;
  right: 0.65rem;
  height: 1.5px;
  background: currentColor;
  transition: transform 300ms var(--ease);
}

.menu-toggle__bars {
  top: calc(50% - 4px);
}

.menu-toggle__bars::before {
  content: '';
  left: 0;
  right: 0;
  top: 7px;
}

.menu-toggle[aria-expanded='true'] .menu-toggle__bars {
  transform: translateY(3.5px) rotate(45deg);
}

.menu-toggle[aria-expanded='true'] .menu-toggle__bars::before {
  transform: translateY(-7px) rotate(-90deg);
}

@media (max-width: 63.99em) {
  .menu-toggle {
    display: block;
  }

  .masthead__actions {
    margin-left: auto;
  }

  .masthead__nav {
    position: fixed;
    inset: 0;
    z-index: -1;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: var(--space-7);
    margin: 0;
    padding: var(--header-height) var(--gutter) var(--space-7);
    background: var(--night);
    color: var(--stone-50);
    visibility: hidden;
    opacity: 0;
    transition: opacity 350ms var(--ease), visibility 0s linear 350ms;
  }

  .masthead__nav.is-open {
    visibility: visible;
    opacity: 1;
    transition: opacity 350ms var(--ease);
  }

  .masthead__nav ul {
    flex-direction: column;
    gap: var(--space-2);
  }

  .masthead__nav ul a {
    font-family: var(--font-serif);
    font-size: clamp(2rem, 1.4rem + 3vw, 3rem);
    font-weight: 400;
    letter-spacing: -0.005em;
  }

  .masthead.is-menu-open {
    background: transparent;
    color: var(--stone-50);
    box-shadow: none;
  }

  .masthead.is-menu-open .brand__mark svg {
    color: var(--brass-400);
  }
}

/* ----------------------------------------------------------------- acts */

.act {
  position: relative;
}

/* The soft text washes behind window copy reach past the screen edge. Clip
   them sideways only: 'clip' keeps the sticky lines working, where 'hidden'
   would not, and leaves the sheet edges free to rise above. */
.act--window {
  overflow-x: clip;
}

/* Windows: the scene shows through. Light text unless the scene is running
   and the window is set in daylight. */
.act--window,
.finale {
  color: var(--stone-50);
  text-shadow: 0 1px 2px rgb(5 10 20 / 0.35), 0 0 28px rgb(5 10 20 / 0.4);
}

.scene-on .act--window[data-ink='dark'] {
  color: var(--navy-950);
  text-shadow: 0 0 30px rgb(255 255 255 / 0.6);
}

/* Sheets: paper panels; the top edge is the outline of the range. */
.act--sheet {
  margin-top: var(--edge);
  background: var(--paper);
  color: var(--color-text);
}

.sheet__edge {
  position: absolute;
  left: 0;
  bottom: calc(100% - 1px);
  width: 100%;
  height: var(--edge);
  fill: var(--paper);
}

.sheet__edge--flip {
  transform: scaleX(-1);
}

.sheet--night {
  background: var(--night);
  color: var(--mist-200);
}

.sheet--night .sheet__edge {
  fill: var(--night);
}

/* A night sheet straight after a paper sheet: its edge rises out of the paper. */
.act--sheet + .act--sheet {
  margin-top: 0;
}

.act--sheet + .act--sheet .sheet__edge {
  bottom: auto;
  top: 0;
  transform: scaleY(-1);
  fill: var(--paper);
}

.act--sheet + .act--sheet.sheet--night .sheet__edge,
.sheet--night + .act--sheet .sheet__edge {
  fill: var(--night);
}

.sheet--night + .act--sheet .sheet__edge {
  transform: scale(-1, -1);
}

.sheet__inner {
  position: relative;
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin: 0 auto;
  padding: clamp(2.5rem, 1rem + 5vw, 6rem) var(--gutter) clamp(5rem, 3rem + 7vw, 10rem);
}

.act--sheet + .act--sheet .sheet__inner {
  padding-top: calc(var(--edge) + clamp(2.5rem, 1rem + 5vw, 6rem));
}

.grid {
  display: grid;
  gap: var(--space-6) var(--space-8);
}

@media (min-width: 60em) {
  .grid {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    align-items: start;
  }
}

.title {
  font-size: var(--text-title);
  font-weight: 400;
  letter-spacing: -0.012em;
  line-height: 1.04;
}

.intro {
  margin-top: var(--space-5);
  max-width: 30rem;
  font-size: var(--text-lg);
  color: var(--color-text-muted);
}

.sheet--night .intro {
  color: var(--mist-300);
}

/* --------------------------------------------------------------- finale */

.finale {
  min-height: 100vh;
  display: flex;
  align-items: flex-end;
  padding: calc(var(--header-height) + 18vh) var(--gutter) calc(var(--space-6) + 2.25rem);
}

.finale__inner {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
}

.finale__word svg {
  width: clamp(12rem, 8rem + 22vw, 30rem);
  height: auto;
  color: var(--stone-50);
  filter: drop-shadow(0 0 24px rgb(5 10 20 / 0.5));
}

.finale__descriptor {
  margin-top: var(--space-5);
  max-width: 28rem;
  font-size: var(--text-lg);
}

.finale__email {
  margin-top: var(--space-4);
  font-family: var(--font-serif);
  font-size: var(--text-xl);
}

.finale__email a {
  text-decoration-color: var(--brass-400);
}

.finale__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-5);
  margin-top: var(--space-8);
  padding-top: var(--space-5);
  border-top: 1px solid rgb(246 243 238 / 0.22);
}

.finale__nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-5);
  font-size: var(--text-sm);
}

.finale__nav a {
  text-decoration: none;
  opacity: 0.85;
}

.finale__nav a:hover {
  opacity: 1;
  text-decoration: underline;
}

.finale__legal {
  margin-top: var(--space-6);
  display: grid;
  gap: var(--space-3);
}

.finale__base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--space-3);
  margin-top: var(--space-7);
  font-size: var(--text-xs);
  opacity: 0.8;
}

/* ------------------------------------------------------------------ HUD */

/* The bearing of the view and the scene's hour, in the corner. Difference
   blending keeps it legible over sky, paper and night alike. */
.hud {
  position: fixed;
  left: var(--gutter);
  bottom: 1rem;
  z-index: 15;
  display: none;
  align-items: center;
  gap: 0.6rem;
  color: #fff;
  mix-blend-mode: difference;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-variant-numeric: tabular-nums;
  pointer-events: none;
  transition: opacity 300ms var(--ease);
}

/* Out of the way while a paper sheet passes beneath it. */
.hud.is-muted {
  opacity: 0;
}

.scene-on .hud {
  display: flex;
}

.hud__label {
  opacity: 0.75;
}

.hud__sep {
  width: 1.5rem;
  height: 1px;
  background: currentColor;
  opacity: 0.6;
}

@media (max-width: 30em) {
  .hud__label {
    display: none;
  }
}

@media print {
  .scene,
  .backdrop,
  .hud,
  .masthead {
    display: none !important;
  }
}

/* ==========================================================================
   Components: eyebrows, buttons, links, prose, form
   ========================================================================== */

.eyebrow {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-5);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: var(--tracking-eyebrow);
  text-transform: uppercase;
  color: var(--color-accent);
}

.eyebrow__num {
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.06em;
}

.eyebrow__num::after {
  content: '';
  display: inline-block;
  width: 2.5rem;
  height: 1px;
  margin: 0 0 0.3em var(--space-3);
  vertical-align: middle;
  background: currentColor;
  opacity: 0.6;
}

.eyebrow--plain {
  color: inherit;
  opacity: 0.85;
}

.sheet--night .eyebrow,
[data-ink='light'] .eyebrow {
  color: var(--brass-400);
}

[data-ink='light'] .eyebrow--plain {
  color: inherit;
}

/* ---------------------------------------------------------------- buttons */

.button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 3rem;
  padding: 0.8rem 1.65rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: var(--text-sm);
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1.2;
  text-decoration: none;
  text-shadow: none;
  cursor: pointer;
  overflow: hidden;
  isolation: isolate;
  transition: color var(--duration) var(--ease), border-color var(--duration) var(--ease),
    background-color var(--duration) var(--ease);
}

/* A fill that rises from below on hover, like light coming up a slope. */
.button::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  transform: translateY(101%);
  transition: transform 420ms var(--ease-out);
}

.button:hover::before {
  transform: translateY(0);
}

.button--brass {
  background: var(--brass-400);
  color: var(--navy-950);
}

.button--brass::before {
  background: var(--stone-50);
}

.button--line {
  border-color: rgb(246 243 238 / 0.55);
  color: var(--stone-50);
}

.button--line::before {
  background: var(--stone-50);
}

.button--line:hover {
  color: var(--navy-950);
  border-color: var(--stone-50);
}

.button--ink {
  background: var(--navy-900);
  color: var(--stone-50);
}

.button--ink::before {
  background: var(--navy-700);
}

.button--block {
  width: 100%;
}

.button[disabled] {
  opacity: 0.7;
  cursor: progress;
}

.text-link {
  color: inherit;
  text-decoration: underline;
  text-decoration-color: var(--brass-500);
  transition: text-decoration-color var(--duration) var(--ease);
}

.text-link:hover {
  text-decoration-color: currentColor;
}

/* ------------------------------------------------------------------ prose */

.prose > * + * {
  margin-top: var(--space-5);
}

.prose p {
  max-width: 38rem;
}

/* ------------------------------------------------------------------ form */

.form-card {
  padding: clamp(1.5rem, 4vw, 2.75rem);
  background: var(--white);
  border-radius: 6px;
  box-shadow: 0 1px 2px rgb(15 30 46 / 0.05), 0 30px 60px -40px rgb(15 30 46 / 0.45);
}

.form-card__title {
  font-size: var(--text-xl);
  margin-bottom: var(--space-5);
}

.contact-form {
  display: grid;
  gap: var(--space-5);
}

.field {
  display: grid;
  gap: var(--space-2);
}

.field__label {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--ink);
}

.field__optional {
  font-weight: 400;
  color: var(--color-text-muted);
}

.field input,
.field textarea {
  width: 100%;
  padding: 0.8rem 0.95rem;
  background: var(--stone-50);
  border: 1px solid #a7b3bf;
  border-radius: 4px;
  font-size: 1rem;
  line-height: 1.5;
  transition: border-color var(--duration) var(--ease), background-color var(--duration) var(--ease);
}

.field textarea {
  min-height: 8rem;
  resize: vertical;
}

.field input:hover,
.field textarea:hover {
  border-color: var(--slate-500);
}

.field input:focus,
.field textarea:focus {
  background: var(--white);
  border-color: var(--navy-700);
}

.field [aria-invalid='true'] {
  border-color: var(--error);
}

.field__error {
  font-size: var(--text-sm);
  color: var(--error);
}

/* Honeypot: off-screen for people, still present for bots. */
.hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form-note {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

.form-alert {
  padding: var(--space-3) var(--space-4);
  border-left: 3px solid var(--error);
  background: #fbefed;
  color: #7c241c;
  font-size: var(--text-sm);
}

.form-alert a {
  color: inherit;
}

.form-success {
  padding: var(--space-5);
  border-left: 3px solid var(--success);
  background: #edf4f0;
}

.form-success:focus {
  outline: none;
}

.form-success__title {
  font-family: var(--font-serif);
  font-size: var(--text-xl);
  margin-bottom: var(--space-2);
}

[hidden] {
  display: none !important;
}

/* ==========================================================================
   Sections
   ========================================================================== */

/* ----------------------------------------------------------------- hero */

.hero {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: flex-start;
  padding: calc(var(--header-height) + clamp(2rem, 9vh, 7rem)) var(--gutter) var(--space-8);
}

.hero__inner {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
}

.hero__word svg {
  width: clamp(15rem, 6rem + 34vw, 44rem);
  height: auto;
  margin-left: -0.4%;
  margin-bottom: clamp(1.5rem, 1rem + 2vw, 2.75rem);
  color: var(--stone-50);
  filter: drop-shadow(0 2px 30px rgb(5 10 20 / 0.45));
}

.hero__title {
  max-width: 20ch;
  font-size: var(--text-hero);
  font-weight: 400;
  letter-spacing: -0.005em;
  line-height: 1.1;
}

.hero__lead {
  max-width: 34rem;
  margin-top: var(--space-5);
  font-size: var(--text-lg);
  color: rgb(246 243 238 / 0.9);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-6);
}

.hero__coords {
  position: absolute;
  right: var(--gutter);
  bottom: 1rem;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  opacity: 0.75;
}

/* A drop of light running down a thread: there is more below. */
.hero__cue {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 1px;
  height: 4.5rem;
  background: linear-gradient(rgb(246 243 238 / 0), rgb(246 243 238 / 0.5));
  overflow: hidden;
}

.hero__cue::after {
  content: '';
  position: absolute;
  left: -1px;
  width: 3px;
  height: 0.9rem;
  border-radius: 2px;
  background: var(--brass-400);
  animation: cue 2.4s var(--ease) infinite;
}

@keyframes cue {
  from {
    transform: translateY(-1rem);
  }
  to {
    transform: translateY(4.5rem);
  }
}

@media (max-width: 40em) {
  .hero__coords {
    display: none;
  }
}

/* ------------------------------------------------------------ interlude */

/* The line holds its place in the sky while the window passes. */
.interlude {
  min-height: 150vh;
  padding: 24vh var(--gutter) 34vh;
}

.interlude__text {
  position: sticky;
  top: 20vh;
  max-width: 22ch;
  margin: 0 auto;
  font-family: var(--font-serif);
  font-size: var(--text-statement);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.01em;
  text-align: center;
  text-wrap: balance;
}

/* ---------------------------------------------------------------- about */

.prose {
  font-size: var(--text-lg);
  line-height: 1.65;
}

.grid__body {
  padding-top: clamp(0rem, 4vw, 3.5rem);
}

.pillars {
  display: grid;
  gap: var(--space-6);
  margin-top: clamp(3.5rem, 2rem + 5vw, 7rem);
}

@media (min-width: 48em) {
  .pillars {
    grid-template-columns: repeat(3, 1fr);
  }
}

.pillar {
  position: relative;
  padding-top: var(--space-5);
}

.pillar::before {
  content: '';
  position: absolute;
  inset: 0 0 auto;
  height: 1px;
  background: var(--brass-500);
  transform-origin: left;
  transition: transform 1.4s var(--ease-out) 200ms;
}

.pillar.reveal-pending::before {
  transform: scaleX(0);
}

.pillar__title {
  font-size: var(--text-xl);
  margin-bottom: var(--space-2);
}

.pillar p {
  color: var(--color-text-muted);
}

/* ----------------------------------------------------------- what we do */

.focus-pair {
  display: grid;
  gap: var(--space-7);
  margin-top: clamp(3rem, 2rem + 4vw, 6rem);
}

@media (min-width: 52em) {
  .focus-pair {
    grid-template-columns: 1fr 1fr;
    gap: 0;
  }

  .focus + .focus {
    padding-left: clamp(2rem, 5vw, 5rem);
    border-left: 1px solid var(--stone-200);
  }

  .focus:first-child {
    padding-right: clamp(2rem, 5vw, 5rem);
  }
}

.focus {
  position: relative;
  min-width: 0;
}

.focus__num {
  display: block;
  font-family: var(--font-serif);
  font-size: clamp(3.5rem, 2.5rem + 4vw, 7rem);
  font-weight: 400;
  line-height: 1;
  color: var(--brass-700);
}

.focus__icon {
  width: 5.5rem;
  height: auto;
  margin: var(--space-5) 0;
  color: var(--navy-900);
}

.focus__icon [pathLength] {
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 1.6s var(--ease-out);
}

.focus__icon [pathLength]:nth-child(2) {
  transition-delay: 150ms;
}

.focus__icon [pathLength]:nth-child(3) {
  transition-delay: 300ms;
}

.focus__icon [pathLength]:nth-child(4) {
  transition-delay: 450ms;
}

.focus.reveal-pending .focus__icon [pathLength] {
  stroke-dashoffset: 1;
}

.focus__title {
  font-size: var(--text-2xl);
  margin-bottom: var(--space-4);
  /* Long German compounds ("Immobilienentwicklung") must fit a 320px screen. */
  hyphens: auto;
  overflow-wrap: break-word;
}

.focus p {
  max-width: 32rem;
  font-size: var(--text-lg);
  color: var(--color-text-muted);
}

.aside {
  margin-top: clamp(3rem, 2rem + 4vw, 6rem);
  padding-top: var(--space-5);
  border-top: 1px solid var(--stone-200);
  color: var(--color-text-muted);
}

/* ------------------------------------------------------------ principles */

.topo {
  position: absolute;
  inset: 0;
  margin: 0;
  overflow: hidden;
  pointer-events: none;
}

.contours {
  width: 100%;
  height: 100%;
  opacity: 0.55;
}

.contours path {
  fill: none;
  stroke: #4d6782;
  stroke-width: 0.45;
}

.contours .c-major {
  stroke: var(--brass-500);
  stroke-width: 0.9;
}

.contours .c-shore {
  stroke: var(--mist-300);
  stroke-width: 1.1;
}

/* Each contour draws in turn as the section scrolls through. */
.topo.is-drawing path {
  stroke-dasharray: 1;
  stroke-dashoffset: calc(1 - clamp(0, var(--draw, 0) * 1.9 - var(--i, 0) * 0.9, 1));
}

/* Fade the map behind the text so the copy always reads cleanly. */
.topo::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, var(--night) 0%, rgb(12 22 38 / 0.82) 38%, rgb(12 22 38 / 0.35) 100%),
    linear-gradient(0deg, var(--night) 0%, rgb(12 22 38 / 0) 40%);
}

.topo__caption {
  position: absolute;
  right: var(--gutter);
  bottom: var(--space-5);
  z-index: 1;
  max-width: 18rem;
  font-size: var(--text-xs);
  letter-spacing: 0.04em;
  color: var(--mist-400);
  text-align: right;
}

.sheet--night .grid,
.principles {
  position: relative;
  z-index: 1;
}

.principles {
  display: grid;
  gap: var(--space-6) var(--space-7);
  margin-top: clamp(3rem, 2rem + 4vw, 6rem);
  counter-reset: none;
}

@media (min-width: 40em) {
  .principles {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 64em) {
  .principles {
    grid-template-columns: repeat(3, 1fr);
  }
}

.principle {
  padding-top: var(--space-4);
  border-top: 1px solid rgb(180 195 208 / 0.22);
}

.principle__num {
  display: block;
  margin-bottom: var(--space-4);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--brass-400);
  font-variant-numeric: tabular-nums;
}

.principle__title {
  font-size: var(--text-xl);
  color: var(--stone-50);
  margin-bottom: var(--space-2);
}

.principle p {
  color: var(--mist-300);
}

/* ----------------------------------------------------------------- trust */

.trust {
  display: grid;
}

.trust__item {
  display: grid;
  gap: var(--space-2);
  padding: var(--space-5) 0;
  border-top: 1px solid var(--stone-200);
}

.trust__item:last-child {
  border-bottom: 1px solid var(--stone-200);
}

@media (min-width: 48em) {
  .trust__item {
    grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
    gap: var(--space-6);
  }
}

.trust__title {
  font-size: var(--text-xl);
}

.trust__item p {
  color: var(--color-text-muted);
}

/* -------------------------------------------------------------- location */

/* The text first, then an open stretch of evening in which the landscape
   names itself. */
.place__intro {
  min-height: 100vh;
  padding: calc(var(--header-height) + 7vh) var(--gutter) var(--space-7);
}

.place__stage {
  height: 130vh;
}

html:not(.scene-on) .place__stage {
  height: 0;
}

.place__text {
  max-width: var(--container);
  margin: 0 auto;
}

.place__text > * {
  max-width: 32rem;
}

.place .title {
  font-size: clamp(2.4rem, 1.4rem + 3.4vw, 4.6rem);
}

.place .prose {
  margin-top: var(--space-5);
  color: rgb(246 243 238 / 0.92);
}

.facts {
  display: flex;
  gap: var(--space-7);
  margin-top: var(--space-6);
}

.facts dt {
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: var(--tracking-eyebrow);
  text-transform: uppercase;
  color: #f0e2c4;
}

.facts dd {
  margin: var(--space-1) 0 0;
  font-family: var(--font-serif);
  font-size: var(--text-xl);
}

@media (max-width: 40em) {
  .place .prose p:nth-child(2) {
    display: none;
  }
}

/* --------------------------------------------------------------- contact */

@media (min-width: 60em) {
  .grid--contact {
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    gap: var(--space-8);
  }
}

.contact-email {
  margin-top: var(--space-6);
  font-family: var(--font-serif);
  font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.4rem);
  font-weight: 400;
  letter-spacing: 0;
}

.contact-email a {
  text-decoration-color: var(--brass-500);
  text-decoration-thickness: 1px;
}

.contact-details {
  display: grid;
  gap: var(--space-5);
  margin-top: var(--space-6);
}

.contact-details dt {
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: var(--tracking-eyebrow);
  text-transform: uppercase;
  color: var(--brass-700);
}

.contact-details dd {
  margin: var(--space-1) 0 0;
}

/* ------------------------------------------------------------------ legal */

.legal {
  border-top: 1px solid rgb(246 243 238 / 0.22);
}

.legal:last-child {
  border-bottom: 1px solid rgb(246 243 238 / 0.22);
}

.legal__summary {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-4);
  padding: var(--space-4) 2.5rem var(--space-4) 0;
  position: relative;
  cursor: pointer;
  list-style: none;
}

.legal__summary::-webkit-details-marker {
  display: none;
}

.legal__title {
  font-family: var(--font-serif);
  font-size: var(--text-xl);
}

.legal__sub {
  font-size: var(--text-xs);
  letter-spacing: 0.04em;
  opacity: 0.75;
}

.legal__icon {
  position: absolute;
  right: 0.5rem;
  top: 50%;
  width: 0.9rem;
  height: 0.9rem;
}

.legal__icon::before,
.legal__icon::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 1px;
  background: currentColor;
  transition: transform 300ms var(--ease);
}

.legal__icon::after {
  transform: rotate(90deg);
}

.legal[open] .legal__icon::after {
  transform: rotate(0deg);
}

.legal__body {
  margin-bottom: var(--space-5);
  padding: clamp(1.5rem, 1rem + 3vw, 3.5rem);
  background: var(--paper);
  color: var(--color-text);
  text-shadow: none;
  border-radius: 6px;
  font-size: var(--text-sm);
  columns: 2 22rem;
  column-gap: var(--space-8);
}

.legal__heading {
  column-span: all;
  font-size: var(--text-2xl);
  margin-bottom: var(--space-5);
}

.legal__section {
  break-inside: avoid;
  margin-bottom: var(--space-5);
}

.legal__section h3 {
  font-family: var(--font-sans);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: var(--tracking-eyebrow);
  text-transform: uppercase;
  color: var(--brass-700);
  margin-bottom: var(--space-2);
}

.legal__section p + p,
.legal__section address + p {
  margin-top: var(--space-2);
}

/* ------------------------------------------------------------------- 404 */

.lost {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: var(--header-height) var(--gutter);
}

.lost__inner {
  display: grid;
  gap: var(--space-8);
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
}

@media (min-width: 48em) {
  .lost__inner {
    grid-template-columns: 1fr 1fr;
  }
}

.lost__title {
  font-size: var(--text-2xl);
  margin-bottom: var(--space-3);
}

.lost__block p + p {
  margin-top: var(--space-5);
}

/* ---------------------------------------------------------------- motion */

@media (prefers-reduced-motion: no-preference) {
  .reveal-pending {
    opacity: 0;
    transform: translateY(1.75rem);
  }

  .reveal-in {
    transition: opacity var(--duration-reveal) var(--ease-out), transform var(--duration-reveal) var(--ease-out);
  }

  /* Headings rise word by word out of a mask. */
  .word {
    display: inline-block;
    overflow: clip;
    overflow-clip-margin: 0.12em;
    padding-bottom: 0.1em;
    margin-bottom: -0.1em;
    vertical-align: top;
  }

  .word__in {
    display: inline-block;
  }

  [data-split].reveal-pending {
    opacity: 1;
    transform: none;
  }

  [data-split].reveal-pending .word__in {
    transform: translateY(110%);
  }

  [data-split].reveal-in .word__in {
    transition: transform 1.1s var(--ease-out) calc(var(--i) * 70ms);
  }

  [data-split].reveal-intro .word__in {
    animation: rise 1.2s var(--ease-out) calc(400ms + var(--i) * 80ms) both;
  }

  @keyframes rise {
    from {
      transform: translateY(110%);
    }
  }

  /* The hero: the wordmark surfaces from the dark, then the words follow. */
  .hero__word svg {
    animation: surface 2.2s var(--ease-out) both;
  }

  @keyframes surface {
    from {
      opacity: 0;
      clip-path: inset(0 0 100% 0);
      transform: translateY(1.5rem);
      filter: blur(8px) drop-shadow(0 2px 30px rgb(5 10 20 / 0.45));
    }
    60% {
      opacity: 1;
    }
  }

  .hero__lead,
  .hero__actions,
  .hero .eyebrow {
    animation: fade-up 1.2s var(--ease-out) both;
  }

  .hero .eyebrow {
    animation-delay: 300ms;
  }

  .hero__lead {
    animation-delay: 1s;
  }

  .hero__actions {
    animation-delay: 1.2s;
  }

  @keyframes fade-up {
    from {
      opacity: 0;
      transform: translateY(1rem);
    }
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero__cue::after {
    animation: none;
  }
}

/* ---------------------------------------------------------------- veils */

/* A soft wash behind text set straight on the scene: dusk behind light
   text, morning haze behind dark. It keeps the words legible whatever the
   hour without boxing them in. */
.scene-on .hero__inner,
.scene-on .place__text,
.scene-on .interlude__text {
  position: relative;
  isolation: isolate;
}

.scene-on .interlude__text {
  position: sticky;
}

.scene-on .hero__inner::before,
.scene-on .place__text::before,
.scene-on .interlude__text::before {
  content: '';
  position: absolute;
  z-index: -1;
  pointer-events: none;
}

.scene-on .hero__inner::before {
  inset: 18% 30% -12% -22%;
  background: radial-gradient(closest-side, rgb(9 15 30 / 0.5), rgb(9 15 30 / 0.28) 55%, rgb(9 15 30 / 0));
}

.scene-on .place__text::before {
  inset: -28% calc(100% - 42rem) -34% -20%;
  background: radial-gradient(closest-side, rgb(30 20 32 / 0.7), rgb(30 20 32 / 0.6) 50%, rgb(30 20 32 / 0.28) 78%, rgb(30 20 32 / 0));
}

.scene-on .interlude__text::before {
  inset: -50% -20%;
  background: radial-gradient(closest-side, rgb(12 28 60 / 0.34), rgb(12 28 60 / 0.22) 55%, rgb(12 28 60 / 0));
}

.scene-on [data-ink='dark'] .interlude__text::before {
  background: radial-gradient(closest-side, rgb(238 242 246 / 0.62), rgb(238 242 246 / 0.34) 55%, rgb(238 242 246 / 0));
}

/* Small type over the dusk sky: a paler brass. */
.place .eyebrow {
  color: #f7ecd6;
}

@media (max-width: 40em) {
  .scene-on .hero__inner::before {
    inset: -6% -30% -10%;
  }

  .scene-on .place__text::before {
    inset: -20% -40% -28%;
  }

  /* On a phone the mountains fill more of the screen: sit higher, with a
     deeper wash. */
  .interlude__text,
  .scene-on .interlude__text {
    top: 12vh;
  }

  .scene-on .interlude__text::before {
    background: radial-gradient(closest-side, rgb(12 28 60 / 0.42), rgb(12 28 60 / 0.28) 55%, rgb(12 28 60 / 0));
  }
}
