/* ============================================================================
   MINKA Builder, SHELL styles (site.css)
   Owns: the design system (:root tokens), page chrome, and every non-builder
   section. Also owns the builder-frame LAYOUT (stage + rail split, sticky,
   pricebar). STAGE / PLANS / ENGINE style their own internals elsewhere.
   No em dashes. One accent (rust), spent rarely. Paper, ink, taupe, timber.
   ========================================================================== */

/* ------------------------------------------------------------------ fonts */
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url('../assets/fonts/hanken-grotesk-300.woff2') format('woff2');
}
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../assets/fonts/hanken-grotesk-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../assets/fonts/hanken-grotesk-500.woff2') format('woff2');
}
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../assets/fonts/hanken-grotesk-600.woff2') format('woff2');
}
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../assets/fonts/hanken-grotesk-700.woff2') format('woff2');
}

/* ----------------------------------------------------------------- tokens */
:root {
  /* color */
  --paper: oklch(0.977 0.005 95);        /* warm page white */
  --paper-2: oklch(0.955 0.008 95);      /* tinted panel */
  --ink: oklch(0.24 0.01 85);            /* warm near-black text */
  --ink-2: oklch(0.49 0.015 85);         /* secondary text */
  --taupe: oklch(0.745 0.028 95);        /* #baaf99, bands + rules */
  --taupe-soft: oklch(0.87 0.018 95);    /* light rules, hover tint */
  --rust: oklch(0.455 0.115 35);         /* #9c3c21, THE accent, spend rarely */
  --charcoal: oklch(0.255 0.008 85);     /* footer, dusk chrome */
  --timber: oklch(0.87 0.04 85);         /* pale CLT wood */
  --line: color-mix(in oklab, var(--taupe) 45%, transparent);
  /* type */
  --serif: Georgia, 'Times New Roman', serif;
  --sans: 'Hanken Grotesk', system-ui, -apple-system, sans-serif;
  --text-xs: 0.75rem;   /* letterspaced caps labels, 0.14em tracking */
  --text-sm: 0.875rem;
  --text-base: 1rem;    /* line-height 1.6 */
  --text-lg: clamp(1.25rem, 1.1rem + 0.6vw, 1.5rem);
  --text-h2: clamp(2rem, 1.4rem + 2.6vw, 3.25rem);      /* Georgia bold */
  --text-hero: clamp(3.75rem, 2rem + 11vw, 9rem);       /* Georgia, hero MINKA */
  /* space, 4pt scale */
  --space-2xs: 4px; --space-xs: 8px; --space-sm: 12px; --space-md: 16px;
  --space-lg: 24px; --space-xl: 32px; --space-2xl: 48px; --space-3xl: 64px; --space-4xl: 96px;
  /* motion */
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --dur-fast: 180ms; --dur-med: 420ms; --dur-slow: 700ms;
  /* z scale */
  --z-sticky: 10; --z-pricebar: 20; --z-tooltip: 30;

  /* additive SHELL layout helpers (not part of the shared token contract) */
  --topbar-h: 60px;
  --pricebar-h: 66px;
  --maxw: 1240px;
  --serif-display: clamp(1.35rem, 1.05rem + 1.2vw, 2rem);
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: calc(var(--topbar-h) + 12px);
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 400;
  font-size: var(--text-base);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { max-width: 100%; height: auto; display: block; }
h1, h2, h3, h4 { margin: 0; font-weight: 400; line-height: 1.15; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
a { color: inherit; }
button { font: inherit; color: inherit; margin: 0; }
[hidden] { display: none !important; }

:where(a, button, input, textarea, select, [tabindex]):focus-visible {
  outline: 2px solid var(--rust);
  outline-offset: 2px;
  border-radius: 1px;
}

.skip-link {
  position: fixed;
  left: var(--space-sm);
  top: -80px;
  z-index: 100;
  background: var(--charcoal);
  color: var(--paper);
  padding: 12px 18px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: var(--text-xs);
  text-decoration: none;
  transition: top var(--dur-fast) var(--ease-out);
}
.skip-link:focus { top: var(--space-sm); }

/* ------------------------------------------------------------- utilities */
.num { font-variant-numeric: tabular-nums; font-feature-settings: 'tnum' 1; }

.section { padding-block: clamp(var(--space-3xl), 6vw, var(--space-4xl)); }
.section-inner { max-width: var(--maxw); margin-inline: auto; padding-inline: clamp(var(--space-md), 4vw, var(--space-xl)); }
[id] { scroll-margin-top: calc(var(--topbar-h) + 12px); }

.kicker {
  font-family: var(--sans);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--ink-2);
}

/* Section label: taupe band block, letterspaced Georgia caps (packet motif).
   Uses charcoal caps on the true taupe band for readable AA contrast. */
.band-label {
  display: inline-block;
  background: var(--taupe);
  color: var(--charcoal);
  font-family: var(--serif);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: var(--text-sm);
  line-height: 1;
  padding: 8px 15px 7px;
}

/* Title block caption: charcoal strip, white tracked caps (render/drawing plates). */
.titleblock {
  display: block;
  background: var(--charcoal);
  color: var(--paper);
  font-family: var(--sans);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.13em;
  font-size: var(--text-xs);
  padding: 9px 14px;
}

.serif-lg {
  font-family: var(--serif);
  font-weight: 400;
  font-size: var(--serif-display);
  line-height: 1.4;
  color: var(--ink);
}

/* Dimension line motif, inline callout: 1px taupe rule, end ticks, caps label. */
.dimline { display: inline-flex; align-items: center; gap: var(--space-md); }
.dimline-rule { position: relative; height: 1px; width: clamp(24px, 6vw, 72px); background: var(--taupe); }
.dimline-rule::before {
  content: ""; position: absolute; top: -3px; left: 0;
  width: 1px; height: 7px; background: var(--taupe);
}
.dimline-rule:last-child::before { left: auto; right: 0; }
.dimline-cap {
  font-family: var(--sans);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: var(--text-xs);
  color: var(--ink-2);
  white-space: nowrap;
}

/* Dimension line motif, plain underline for key numbers: rule + end ticks. */
.dimrule {
  display: block; position: relative;
  height: 1px; width: 100%; max-width: 220px;
  background: var(--taupe);
  margin-top: var(--space-md);
}
.dimrule::before, .dimrule::after {
  content: ""; position: absolute; bottom: 0;
  width: 1px; height: 7px; background: var(--taupe);
}
.dimrule::before { left: 0; }
.dimrule::after { right: 0; }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 var(--space-xl);
  font-family: var(--sans); font-weight: 600;
  font-size: var(--text-sm); letter-spacing: 0.06em; text-transform: uppercase;
  text-decoration: none; cursor: pointer;
  border: 1px solid transparent;
  transition: background var(--dur-fast) var(--ease-out),
              color var(--dur-fast) var(--ease-out),
              border-color var(--dur-fast) var(--ease-out);
}
.btn-rust { background: var(--rust); color: var(--paper); }
.btn-rust:hover { background: color-mix(in oklab, var(--rust) 86%, var(--charcoal)); }
.btn-ghost { background: transparent; color: var(--ink); border-color: color-mix(in oklab, var(--ink) 40%, transparent); }
.btn-ghost:hover { border-color: var(--ink); background: color-mix(in oklab, var(--taupe) 28%, transparent); }
.btn-ghost--ondark { color: var(--paper); border-color: color-mix(in oklab, var(--paper) 55%, transparent); }
.btn-ghost--ondark:hover { border-color: var(--paper); background: color-mix(in oklab, var(--paper) 12%, transparent); }

/* folio plate (small inset photo with a caption tick) */
.plate { margin: 0; }
.plate img { width: 100%; height: auto; border: 1px solid var(--line); }
.plate-cap {
  display: flex; align-items: center; gap: var(--space-xs);
  margin-top: var(--space-xs);
  font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--ink-2);
}
.plate-tick { display: inline-block; width: 1px; height: 10px; background: var(--taupe); }

/* reveal (scroll + load). site.js adds html.js, then toggles .is-visible.
   Gated on html.js so content is never hidden if scripts fail to run.
   Reset inside #build; the builder is the engine's territory. */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity var(--dur-med) var(--ease-out), transform var(--dur-med) var(--ease-out);
}
.js [data-reveal].is-visible { opacity: 1; transform: none; }
#build [data-reveal] { opacity: 1; transform: none; transition: none; }

/* ---------------------------------------------------------------- topbar */
.topbar {
  position: sticky; top: 0; z-index: var(--z-sticky);
  background: var(--paper);
  border-bottom: 1px solid transparent;
  transition: border-color var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
}
.topbar.is-scrolled { border-bottom-color: var(--line); box-shadow: 0 6px 20px -18px color-mix(in oklab, var(--charcoal) 60%, transparent); }
.topbar-inner {
  max-width: var(--maxw); margin-inline: auto;
  height: var(--topbar-h);
  display: flex; align-items: center; gap: var(--space-lg);
  padding-inline: clamp(var(--space-md), 4vw, var(--space-xl));
}
.wordmark {
  font-family: var(--serif); font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.2em;
  font-size: var(--text-sm); text-decoration: none; color: var(--ink);
  white-space: nowrap; flex: 0 0 auto;
}
.topbar-nav {
  display: flex; gap: clamp(var(--space-md), 2.5vw, var(--space-lg));
  margin-inline: auto;
  overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
  min-width: 0;
}
.topbar-nav::-webkit-scrollbar { display: none; }
.topbar-nav a {
  font-size: var(--text-sm); letter-spacing: 0.05em; color: var(--ink-2);
  text-decoration: none; white-space: nowrap; padding-block: 14px;
  transition: color var(--dur-fast) var(--ease-out);
}
.topbar-nav a:hover { color: var(--ink); }
.topbar-price {
  display: inline-flex; align-items: baseline; gap: var(--space-xs);
  text-decoration: none; white-space: nowrap; flex: 0 0 auto;
  padding-block: 12px;
}
/* stay invisible until the engine writes the first live total */
.topbar-price:has(.topbar-price-value:empty) { visibility: hidden; }
.topbar-price-label { text-transform: uppercase; letter-spacing: 0.14em; font-size: var(--text-xs); color: var(--ink-2); }
.topbar-price-value { font-family: var(--sans); font-weight: 700; color: var(--rust); min-width: 4ch; text-align: right; }

/* ------------------------------------------------------------------ hero */
.hero {
  position: relative; isolation: isolate;
  min-height: 100svh;
  display: flex; align-items: flex-end;
  overflow: hidden;
}
.hero-media { position: absolute; inset: 0; z-index: -2; background: var(--charcoal); }
.hero-img {
  width: 100%; height: 100%; object-fit: cover;
  animation: kenburns 26s var(--ease-out) forwards;
}
@keyframes kenburns {
  from { transform: scale(1.06); }
  to   { transform: scale(1.0); }
}
.hero-scrim {
  position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(
    to top,
    color-mix(in oklab, var(--charcoal) 80%, transparent) 0%,
    color-mix(in oklab, var(--charcoal) 34%, transparent) 40%,
    transparent 72%);
}
.hero-content {
  width: 100%; max-width: var(--maxw); margin-inline: auto;
  padding: clamp(var(--space-2xl), 7vw, var(--space-4xl)) clamp(var(--space-md), 4vw, var(--space-xl));
  display: grid; gap: var(--space-lg);
  color: var(--paper);
}
.hero-kicker { color: color-mix(in oklab, var(--paper) 85%, transparent); }
.hero-title {
  font-family: var(--serif); font-weight: 700;
  font-size: var(--text-hero); line-height: 0.9; letter-spacing: -0.025em;
  color: var(--paper);
}
.hero-sub {
  max-width: 46ch; font-size: var(--text-lg); line-height: 1.5;
  color: color-mix(in oklab, var(--paper) 90%, transparent);
}
.hero-price { margin-top: var(--space-2xs); }
.hero-price .dimline-cap { color: var(--paper); font-size: var(--text-sm); letter-spacing: 0.12em; }
.hero-price .dimline-rule,
.hero-price .dimline-rule::before { background: color-mix(in oklab, var(--paper) 60%, transparent); }
.hero-cta { display: flex; flex-wrap: wrap; gap: var(--space-md); margin-top: var(--space-sm); }

/* ----------------------------------------------------------------- story */
.story-grid {
  display: grid; grid-template-columns: 5fr 7fr;
  gap: clamp(var(--space-2xl), 6vw, var(--space-4xl));
  align-items: start;
}
.story-col--lead { display: grid; gap: var(--space-lg); align-content: start; }
.story-mission { font-size: clamp(1.5rem, 1.1rem + 1.5vw, 2.15rem); line-height: 1.32; }
.story-col--body { display: grid; gap: var(--space-2xl); max-width: 62ch; }
.story-para { color: var(--ink-2); font-size: var(--text-lg); line-height: 1.6; }
.pullquote { margin: 0; padding-left: var(--space-xl); border-left: 1px solid var(--taupe); }
.pullquote-text { font-family: var(--serif); font-style: italic; font-size: var(--serif-display); line-height: 1.4; color: var(--ink); }
.pullquote-cite { display: block; margin-top: var(--space-md); font-style: normal; text-transform: uppercase; letter-spacing: 0.14em; font-size: var(--text-xs); color: var(--ink-2); }
.story-plates { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-lg); }

/* ------------------------------------------------------------------ bands */
.band {
  position: relative; isolation: isolate; overflow: hidden;
  display: flex; align-items: center; justify-content: center; text-align: center;
  min-height: clamp(320px, 46vh, 520px);
  padding: var(--space-4xl) var(--space-xl);
}
.band-img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; }
.band-scrim {
  position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(180deg, color-mix(in oklab, var(--charcoal) 34%, transparent), color-mix(in oklab, var(--charcoal) 56%, transparent)),
    radial-gradient(70% 70% at 50% 50%, color-mix(in oklab, var(--charcoal) 30%, transparent), transparent 72%);
}
.band-content { display: grid; gap: var(--space-md); justify-items: center; }
.band-kicker {
  font-family: var(--sans); text-transform: lowercase;
  letter-spacing: 0.14em; font-size: var(--text-sm);
  color: color-mix(in oklab, var(--paper) 88%, transparent);
  max-width: 44ch;
}
.band-serif {
  font-family: var(--serif); text-transform: uppercase;
  letter-spacing: 0.3em; line-height: 1.1;
  font-size: clamp(1.15rem, 0.55rem + 2.9vw, 2.6rem);
  color: var(--paper);
  white-space: nowrap;
}
.band-serif--lg { text-transform: none; font-style: italic; letter-spacing: 0.02em; font-size: var(--text-h2); white-space: normal; max-width: 24ch; }

/* ------------------------------------------------------------- difference */
.difference-head {
  display: grid; grid-template-columns: 1.5fr 0.9fr;
  gap: clamp(var(--space-xl), 5vw, var(--space-3xl));
  align-items: end;
  margin-top: var(--space-xl);
}
.diff-lead { max-width: 22ch; }
.plate-inline img { aspect-ratio: 900 / 581; object-fit: cover; }

.diff-list { margin-top: clamp(var(--space-2xl), 5vw, var(--space-4xl)); }
.diff-item {
  display: grid; grid-template-columns: auto 1fr;
  gap: clamp(var(--space-md), 3vw, var(--space-2xl));
  padding-block: var(--space-2xl);
  border-top: 1px solid var(--line);
}
.diff-item:last-child { border-bottom: 1px solid var(--line); }
.diff-num { font-family: var(--serif); font-size: clamp(2rem, 1.3rem + 2.4vw, 3.2rem); color: var(--taupe); line-height: 0.9; }
.diff-title { font-family: var(--serif); font-size: var(--serif-display); margin-bottom: var(--space-sm); }
.diff-copy { max-width: 62ch; color: var(--ink-2); line-height: 1.6; }

.masstimber {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: clamp(var(--space-2xl), 6vw, var(--space-4xl));
  margin-top: clamp(var(--space-3xl), 6vw, var(--space-4xl));
  align-items: start;
}
.mt-lead { position: sticky; top: calc(var(--topbar-h) + var(--space-lg)); display: grid; gap: var(--space-lg); align-content: start; }
.mt-heading { font-family: var(--serif); text-transform: uppercase; letter-spacing: 0.14em; font-size: var(--text-lg); color: var(--ink); }
.mt-goal { max-width: 26ch; }
.mt-plate { max-width: 360px; }
.mt-data-label { margin-bottom: var(--space-lg); }
.rvals { display: grid; gap: var(--space-2xl); }
.rval { margin: 0; display: grid; gap: var(--space-xs); }
.rval-key { font-family: var(--sans); text-transform: uppercase; letter-spacing: 0.14em; font-size: var(--text-xs); color: var(--ink-2); }
.rval-val { margin: 0; display: block; }
.rval-num { font-family: var(--serif); font-weight: 400; font-size: clamp(2.6rem, 1.7rem + 3.4vw, 4rem); line-height: 0.95; color: var(--ink); display: block; }
.rvals-note { margin-top: var(--space-lg); font-family: var(--serif); font-style: italic; color: var(--ink-2); }

.drawings { margin-top: clamp(var(--space-3xl), 6vw, var(--space-4xl)); display: grid; gap: var(--space-xl); }
.drawing { margin: 0; border: 1px solid var(--line); background: var(--paper-2); }
.drawing img { width: 100%; height: auto; }
.drawings-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-xl); }

/* ------------------------------------------------------------------ line */
.line-list {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: clamp(var(--space-md), 3vw, var(--space-xl));
  margin-top: var(--space-2xl);
}
.line-item {
  margin: 0; display: grid; gap: var(--space-md); justify-items: center; text-align: center;
  padding: var(--space-lg); border: 1px solid transparent;
}
.line-item--current { border: 1px dashed var(--taupe); background: color-mix(in oklab, var(--taupe) 12%, transparent); }
.line-thumb {
  width: auto; height: 176px; max-width: 100%; object-fit: contain;
  filter: grayscale(1) contrast(0.96) opacity(0.72);
}
.line-cap { display: grid; gap: var(--space-2xs); }
.line-name { font-family: var(--serif); text-transform: uppercase; letter-spacing: 0.22em; font-size: var(--text-lg); color: var(--ink); }
.line-tag { display: block; font-family: var(--sans); text-transform: uppercase; letter-spacing: 0.14em; font-size: var(--text-xs); color: var(--rust); }
.line-note { margin-top: var(--space-2xl); font-family: var(--serif); font-style: italic; color: var(--ink-2); max-width: 60ch; }

/* --------------------------------------------------------------- builder */
.builder { background: var(--paper); }
.builder-frame {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(400px, 440px);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.builder-stage {
  position: sticky; top: var(--topbar-h);
  height: calc(100svh - var(--topbar-h) - var(--pricebar-h));
  display: flex; flex-direction: column; gap: var(--space-md);
  padding: var(--space-lg);
  background: var(--paper-2);
  border-right: 1px solid var(--line);
}
.stage-tabs { display: flex; gap: var(--space-2xs); flex: 0 0 auto; }
.stage-tabs button {
  appearance: none; background: transparent;
  border: 0; border-bottom: 1px solid var(--line);
  padding: 10px 16px; min-height: 44px;
  font-size: var(--text-sm); letter-spacing: 0.04em; color: var(--ink-2);
  cursor: pointer;
  transition: color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out);
}
.stage-tabs button:hover { color: var(--ink); }
.stage-tabs button[aria-pressed="true"] { color: var(--ink); border-bottom-color: var(--rust); }
#scene-toggle {
  position: absolute; top: var(--space-lg); right: var(--space-lg); z-index: 2;
  appearance: none; background: var(--paper); color: var(--ink);
  border: 1px solid var(--line); border-radius: 999px;
  padding: 9px 18px; min-height: 44px;
  font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.14em;
  cursor: pointer;
  transition: background var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out);
}
#scene-toggle[aria-pressed="true"] { background: var(--charcoal); color: var(--paper); border-color: var(--charcoal); }
.stage-views { position: relative; flex: 1 1 auto; min-height: 0; }
.stage-view { position: absolute; inset: 0; }
.stage-view[hidden] { display: none; }
.stage-caption {
  flex: 0 0 auto; align-self: flex-start; max-width: 100%;
  margin: 0; background: var(--charcoal); color: var(--paper);
  font-family: var(--sans); text-transform: uppercase; letter-spacing: 0.12em;
  font-size: var(--text-xs); line-height: 1.4; padding: 9px 13px;
}
.stage-caption:empty { display: none; }
.builder-rail {
  padding: clamp(var(--space-xl), 4vw, var(--space-2xl)) clamp(var(--space-md), 3vw, var(--space-xl)) calc(var(--pricebar-h) + var(--space-2xl));
  min-height: calc(100svh - var(--topbar-h));
}
.builder-pricebar {
  position: sticky; bottom: 0; z-index: var(--z-pricebar);
  min-height: var(--pricebar-h);
  display: flex; align-items: center; gap: var(--space-md); flex-wrap: wrap;
  padding: var(--space-sm) clamp(var(--space-md), 4vw, var(--space-xl));
  background: var(--paper);
  border-top: 1px solid var(--taupe);
}
.pricebar-label { text-transform: uppercase; letter-spacing: 0.14em; font-size: var(--text-xs); color: var(--ink-2); }
#price-value {
  font-family: var(--serif); font-weight: 700;
  font-size: clamp(1.5rem, 1.1rem + 1.4vw, 2rem);
  color: var(--rust); font-variant-numeric: tabular-nums;
}
#price-note-toggle {
  margin-left: auto; appearance: none; background: transparent;
  border: 1px solid var(--line); border-radius: 999px;
  padding: 9px 16px; min-height: 44px;
  font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.1em; color: var(--ink-2);
  cursor: pointer;
}
#price-note-toggle:hover { color: var(--ink); border-color: var(--taupe); }
#price-note { flex-basis: 100%; margin: 0; font-size: var(--text-xs); color: var(--ink-2); line-height: 1.6; max-width: 76ch; padding-bottom: var(--space-xs); }

/* --------------------------------------------------------------- gallery */
.gallery-strip {
  display: flex; gap: var(--space-lg);
  overflow-x: auto; scroll-snap-type: x mandatory;
  padding: clamp(var(--space-xl), 4vw, var(--space-2xl)) clamp(var(--space-md), 4vw, var(--space-xl));
  cursor: grab; touch-action: pan-x;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}
.gallery-strip.is-dragging { cursor: grabbing; user-select: none; }
.gallery-item {
  margin: 0; flex: 0 0 auto; scroll-snap-align: center;
  border: 1px solid var(--line); background: var(--paper-2);
}
.gallery-img { height: min(70vh, 720px); width: auto; }
.gallery-item .titleblock { border-top: 1px solid var(--line); }
.gallery-hint {
  text-align: center; text-transform: uppercase; letter-spacing: 0.16em;
  font-size: var(--text-xs); color: var(--ink-2);
  margin-top: var(--space-sm);
}

/* -------------------------------------------------------------- included */
.included-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: clamp(var(--space-2xl), 6vw, var(--space-4xl));
  margin-top: var(--space-2xl);
}
.included-col { display: block; }
.included-head { font-family: var(--serif); font-weight: 700; font-size: clamp(1.7rem, 1.2rem + 1.8vw, 2.6rem); margin-bottom: var(--space-lg); }
.included-col--nope .included-head { color: var(--taupe); }
.included-list { display: grid; }
.included-li {
  display: grid; grid-template-columns: auto 1fr; gap: var(--space-md); align-items: start;
  padding-block: var(--space-sm); border-bottom: 1px solid var(--line);
}
.included-mark { position: relative; width: 15px; height: 15px; margin-top: 5px; }
.included-col--yup .included-mark::before {
  content: ""; position: absolute; left: 3px; top: 0;
  width: 5px; height: 11px;
  border-right: 1.5px solid var(--ink); border-bottom: 1.5px solid var(--ink);
  transform: rotate(40deg);
}
.included-col--nope .included-mark::before,
.included-col--nope .included-mark::after {
  content: ""; position: absolute; left: 7px; top: 0;
  width: 1.5px; height: 15px; background: var(--taupe);
}
.included-col--nope .included-mark::before { transform: rotate(45deg); }
.included-col--nope .included-mark::after { transform: rotate(-45deg); }
.included-text { color: var(--ink-2); line-height: 1.5; }
.included-notes { margin-top: var(--space-2xl); display: grid; gap: var(--space-lg); max-width: 80ch; }
.included-footnotes { display: grid; gap: var(--space-2xs); }
.included-footnotes li { font-size: var(--text-xs); color: var(--ink-2); letter-spacing: 0.02em; }
.included-close { font-family: var(--serif); font-style: italic; color: var(--ink); line-height: 1.5; }

/* --------------------------------------------------------------- process */
.process-kicker { margin-top: var(--space-lg); font-family: var(--serif); font-style: italic; font-size: var(--serif-display); color: var(--ink-2); max-width: 60ch; }
.process-timeline {
  display: flex; gap: var(--space-xl);
  overflow-x: auto; scrollbar-width: thin;
  padding: clamp(var(--space-2xl), 5vw, var(--space-3xl)) 0 var(--space-xl);
}
.tl-step {
  flex: 0 0 clamp(200px, 40vw, 246px);
  display: grid; gap: var(--space-sm); align-content: start;
  padding-top: var(--space-md);
  border-top: 1px solid var(--ink-2);
}
.tl-step--optional { border-top: 1px dashed var(--taupe); }
.tl-index { font-family: var(--serif); font-size: var(--text-lg); color: var(--taupe); }
.tl-head { display: flex; align-items: baseline; gap: var(--space-sm); flex-wrap: wrap; }
.tl-name { font-family: var(--serif); font-size: var(--text-lg); color: var(--ink); }
.tl-tag { text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.625rem; color: var(--ink-2); border: 1px solid var(--line); border-radius: 999px; padding: 2px 8px; }
.tl-days { text-transform: uppercase; letter-spacing: 0.12em; font-size: var(--text-xs); color: var(--ink-2); }
.tl-note { color: var(--ink-2); font-size: var(--text-sm); line-height: 1.5; }
.process-tracks {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: clamp(var(--space-xl), 5vw, var(--space-3xl));
  margin-top: var(--space-2xl);
}
.track { display: grid; gap: var(--space-xs); align-content: start; }
.track-label { color: var(--ink-2); }
.track-val { display: flex; align-items: baseline; gap: var(--space-sm); }
.track-num { font-family: var(--serif); font-size: clamp(2.6rem, 1.7rem + 3.4vw, 4rem); line-height: 0.95; color: var(--ink); }
.track-unit { text-transform: uppercase; letter-spacing: 0.14em; font-size: var(--text-xs); color: var(--ink-2); }

/* --------------------------------------------------------------- contact */
.contact { position: relative; isolation: isolate; overflow: hidden; background: var(--charcoal); color: var(--paper); }
.contact-img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; opacity: 0.42; }
.contact-scrim {
  position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, color-mix(in oklab, var(--charcoal) 70%, transparent), color-mix(in oklab, var(--charcoal) 88%, transparent));
}
.contact-content {
  max-width: 68ch; margin-inline: auto;
  padding: clamp(var(--space-3xl), 8vw, calc(var(--space-4xl) + var(--space-xl))) var(--space-xl);
  display: grid; gap: var(--space-xl); justify-items: center; text-align: center;
}
.contact-cta { font-family: var(--serif); font-weight: 400; font-size: var(--text-h2); color: var(--paper); line-height: 1.2; }
.contact-actions { display: flex; flex-wrap: wrap; gap: var(--space-md); justify-content: center; }
.contact-email { text-transform: uppercase; letter-spacing: 0.2em; font-size: var(--text-xs); color: color-mix(in oklab, var(--paper) 78%, transparent); }

/* ---------------------------------------------------------------- footer */
.site-footer { background: var(--paper); border-top: 1px solid var(--line); }
.footer-inner {
  max-width: var(--maxw); margin-inline: auto;
  padding: clamp(var(--space-3xl), 6vw, var(--space-4xl)) var(--space-xl);
  display: grid; gap: var(--space-2xl); justify-items: center; text-align: center;
}
.footer-brand { display: grid; gap: var(--space-sm); justify-items: center; }
.badge { width: 92px; height: 92px; }
.badge-ring { fill: none; stroke: var(--rust); stroke-width: 1.2; }
.badge-ring--inner { stroke: color-mix(in oklab, var(--rust) 45%, transparent); stroke-width: 0.8; }
.badge-tree { fill: var(--charcoal); }
.footer-wordmark { font-family: var(--serif); font-weight: 700; text-transform: uppercase; letter-spacing: 0.28em; font-size: var(--text-sm); color: var(--ink); }
.footer-tagline { text-transform: uppercase; letter-spacing: 0.2em; font-size: var(--text-xs); color: var(--taupe); }
.footer-nav { display: flex; flex-wrap: wrap; gap: clamp(var(--space-md), 3vw, var(--space-lg)); justify-content: center; }
.footer-nav a { text-transform: uppercase; letter-spacing: 0.12em; font-size: var(--text-xs); color: var(--ink-2); text-decoration: none; display: inline-block; padding: 14px 4px; }
.footer-nav a:hover { color: var(--ink); }
.footer-legal { max-width: 74ch; font-size: var(--text-xs); color: var(--ink-2); line-height: 1.7; }

/* ----------------------------------------------------------- responsive */
@media (max-width: 1024px) {
  .builder-frame { grid-template-columns: minmax(0, 1fr) minmax(360px, 400px); }
}

@media (max-width: 900px) {
  .story-grid,
  .difference-head,
  .masstimber { grid-template-columns: 1fr; gap: var(--space-2xl); }
  .difference-head { align-items: start; }
  .mt-lead { position: static; }
  .mt-plate { max-width: none; }
  .included-grid { grid-template-columns: 1fr; gap: var(--space-2xl); }
  .drawings-row { grid-template-columns: 1fr; }
  .process-tracks { grid-template-columns: 1fr; gap: var(--space-2xl); }
  .line-list { grid-template-columns: repeat(2, 1fr); }

  /* builder: stage on top (collapsed), rail below, pricebar sticky bottom.
     minmax(0, 1fr) so rail content can never push the page wider. */
  .builder-frame { grid-template-columns: minmax(0, 1fr); }
  .builder-stage {
    position: sticky; top: var(--topbar-h);
    height: 44vh;
    border-right: 0; border-bottom: 1px solid var(--line);
  }
  .builder-rail { min-height: 0; }
}

@media (max-width: 560px) {
  .story-plates { grid-template-columns: 1fr 1fr; }
  .gallery-img { height: min(52vh, 460px); }
  .diff-item { grid-template-columns: 1fr; gap: var(--space-sm); }
  .diff-num { color: var(--taupe); }
  .drawings-row { grid-template-columns: 1fr; }
  .builder-stage { padding: var(--space-md); }
  .band-serif { letter-spacing: 0.1em; }
  .topbar-price-label { display: none; }
  .line-thumb { height: 132px; }
}

@media (max-width: 380px) {
  .stage-tabs { flex-wrap: wrap; }
}

/* ------------------------------------------------------ reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  [data-reveal] { opacity: 1 !important; transform: none !important; }
  .hero-img { animation: none !important; transform: none !important; }
}

/* ------------------------------------------------------------------ print
   body.printing-spec renders only the builder rail (summary spec sheet). */
@media print {
  [data-reveal] { opacity: 1 !important; transform: none !important; }

  body.printing-spec .skip-link,
  body.printing-spec .topbar,
  body.printing-spec .site-footer,
  body.printing-spec main > *:not(#build) { display: none !important; }

  body.printing-spec #build { display: block; }
  body.printing-spec .builder-frame { display: block; border: 0; }
  body.printing-spec .builder-stage,
  body.printing-spec .stage-tabs,
  body.printing-spec #scene-toggle,
  body.printing-spec .builder-pricebar { display: none !important; }
  body.printing-spec .builder-rail {
    position: static; width: auto; min-height: 0; padding: 0;
    color: var(--ink);
  }
}

/* integration pass: mobile builder stacking + compact stage chrome */
@media (max-width: 900px) {
  .builder-stage {
    z-index: var(--z-sticky);
    box-shadow: 0 10px 18px -14px oklch(0.24 0.01 85 / 0.3);
  }
}
@media (max-width: 640px) {
  .stage-tabs { padding-right: 84px; }
  .stage-tabs button { padding: 10px 8px; font-size: 0.8125rem; }
  #scene-toggle { top: 10px; right: 10px; min-height: 44px; padding: 8px 13px; }
  .stage-caption { font-size: 0.625rem; padding: 7px 10px; letter-spacing: 0.1em; }
}

/* build teaser band (marketing page), links into configure.html */
.build-teaser { background: var(--paper-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.teaser-grid {
  display: grid; grid-template-columns: minmax(280px, 5fr) 7fr;
  gap: var(--space-3xl); align-items: center;
}
.teaser-title {
  margin: 0 0 var(--space-md);
  font-family: var(--serif); font-weight: 700;
  font-size: var(--text-h2); line-height: 1.05; color: var(--ink);
}
.teaser-sub {
  margin: 0 0 var(--space-xl); max-width: 44ch;
  color: var(--ink-2); line-height: 1.6;
}
.teaser-shot { display: block; border: 1px solid var(--line); background: var(--paper); }
.teaser-shot img { display: block; width: 100%; height: auto; }
.teaser-shot:focus-visible { outline: 2px solid var(--rust); outline-offset: 2px; }
@media (max-width: 900px) {
  .teaser-grid { grid-template-columns: 1fr; gap: var(--space-xl); }
}

/* review pass: line band asset integration */
.line-thumb { mix-blend-mode: multiply; }
.line-item--current { border: 0; }
.line-item--current .line-thumb { filter: none; }

/* review pass: an empty stage caption disappears instead of leaving a chip */
.stage-caption:empty { display: none; }

/* review pass: horizontal scroller affordances */
.process-timeline {
  -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 56px), transparent);
  mask-image: linear-gradient(90deg, #000 calc(100% - 56px), transparent);
}
@media (max-width: 640px) {
  .topbar-nav {
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent);
    mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent);
  }
  .hero-scrim {
    background: linear-gradient(
      to top,
      color-mix(in oklab, var(--charcoal) 88%, transparent) 0%,
      color-mix(in oklab, var(--charcoal) 34%, transparent) 52%,
      color-mix(in oklab, var(--charcoal) 46%, transparent) 100%
    );
  }
  .hero-content { text-shadow: 0 1px 22px oklch(0.2 0.005 85 / 0.5); }
}
