/* Hallmark · pre-emit critique: P5 H4 E5 S4 R5 V4
 * genre: atmospheric · macrostructure: Split Studio · theme: Midnight
 * enrichment: Tier-A CSS material swatches + labelled photo-placeholders
 * nav: N9 Edge-aligned minimal · footer: Ft5 Statement
 * H2 split knobs: ratio=6/6 · right=proof column (material swatches) · divider=negative space
 * tone: industrieel-premium · anchor hue: steel-blue 220
 * states: links/buttons — default·hover·focus-visible·active·disabled
 * contrast: pass (46–50) · honest copy: no invented metrics, no fabricated hours
 */

@import url("tokens.css");

/* ── Reset / base ──────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }

html { overflow-x: clip; scroll-behavior: smooth; }
body {
  overflow-x: clip;
  font-family: var(--font-body);
  font-size: var(--text-md);
  line-height: var(--lh-normal);
  color: var(--color-ink-2);
  background-color: var(--color-paper);
  /* two fixed cool blooms behind the content — atmospheric ground */
  background-image:
    radial-gradient(50rem 38rem at 80% -8%, oklch(66% 0.155 285 / 0.18), transparent 60%),
    radial-gradient(40rem 36rem at -4% 34%, oklch(82% 0.095 92 / 0.08), transparent 55%);
  background-attachment: fixed;
  background-repeat: no-repeat;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

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

::selection { background: var(--color-accent); color: var(--color-accent-ink); }

:focus-visible {
  outline: 2px solid var(--color-focus);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ── Layout primitives ─────────────────────────────────────────── */
.wrap {
  max-width: var(--page-max);
  margin-inline: auto;
  padding-inline: var(--page-gutter);
}

.section { padding-block: var(--section-gap); }
.section--tight { padding-block: var(--space-2xl); }

.diptych {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
}
.diptych--reverse .diptych__visual { order: -1; }

.eyebrow-stack { display: grid; gap: var(--space-sm); }

.kicker {
  font-family: var(--font-label);
  font-size: var(--text-xs);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--color-accent);
  margin: 0;
}

.section__head { max-width: 30ch; margin-bottom: var(--space-xl); display: grid; gap: var(--space-sm); }
.section__title {
  font-family: var(--font-display);
  font-weight: var(--display-weight);
  font-size: var(--text-2xl);
  line-height: var(--lh-snug);
  letter-spacing: var(--tracking-tight);
  color: var(--color-ink);
  overflow-wrap: anywhere;
  min-width: 0;
}
.section__sub { color: var(--color-muted); max-width: var(--measure); }

.lede { font-size: var(--text-lg); line-height: var(--lh-relaxed); color: var(--color-neutral); max-width: 46ch; }
.prose p { max-width: var(--measure); }
.prose p + p { margin-top: var(--space-md); }

/* ── Nav · N9 edge-aligned minimal ─────────────────────────────── */
.nav {
  position: sticky;
  top: 0;
  z-index: var(--z-sticky-nav);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--page-gutter);
  background: oklch(15% 0.022 250 / 0.72);
  backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  border-bottom: var(--rule-hair) solid var(--color-rule);
}
.wordmark {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--text-md);
  letter-spacing: var(--tracking-tight);
  color: var(--color-ink);
  text-decoration: none;
  display: inline-flex;
  align-items: baseline;
  gap: 0.5ch;
  white-space: nowrap;
}

/* width-conditional labels (keep clickable text on one line) */
.u-sm { display: none; }
@media (max-width: 40rem) {
  .u-lg { display: none; }
  .u-sm { display: inline; }
}
.wordmark b { color: var(--color-accent); font-weight: 600; }
.nav__cta { white-space: nowrap; }

/* ── Buttons ───────────────────────────────────────────────────── */
.btn {
  --_bg: transparent;
  --_fg: var(--color-ink);
  --_bd: var(--color-rule-2);
  display: inline-flex;
  align-items: center;
  gap: 0.6ch;
  min-height: 44px;
  padding: 0.7em 1.3em;
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 500;
  line-height: 1;
  white-space: nowrap;
  text-decoration: none;
  color: var(--_fg);
  background: var(--_bg);
  border: 1.5px solid var(--_bd);
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition:
    background-color var(--dur-short) var(--ease-out),
    border-color var(--dur-short) var(--ease-out),
    color var(--dur-short) var(--ease-out),
    transform var(--dur-micro) var(--ease-out);
}
.btn .arrow { transition: transform var(--dur-short) var(--ease-out); }
.btn:hover .arrow, .btn:focus-visible .arrow { transform: translateX(3px); }
.btn:active { transform: translateY(1px); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.5; cursor: not-allowed; pointer-events: none; }

.btn--primary {
  --_bg: var(--color-accent);
  --_fg: var(--color-accent-ink);
  --_bd: var(--color-accent);
  font-weight: 600;
}
.btn--primary:hover, .btn--primary:focus-visible { --_bg: var(--color-focus); --_bd: var(--color-focus); }

.btn--ghost:hover, .btn--ghost:focus-visible {
  --_bd: var(--color-accent);
  --_fg: var(--color-ink);
  background: var(--color-paper-2);
}

/* Typographic link */
.tlink {
  color: var(--color-accent);
  text-decoration: none;
  font-weight: 500;
  border-bottom: 1px solid oklch(72% 0.16 220 / 0.4);
  padding-bottom: 1px;
  transition: border-color var(--dur-short) var(--ease-out), color var(--dur-short) var(--ease-out);
}
.tlink:hover, .tlink:focus-visible { border-bottom-color: var(--color-accent); color: var(--color-focus); }

/* ── Hero · H2 split diptych ───────────────────────────────────── */
.hero { padding-block: clamp(3rem, 8vw, 6.5rem) var(--section-gap); }
.hero__grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}
.hero__copy { display: grid; gap: var(--space-lg); }
.hero__title {
  font-family: var(--font-display);
  font-weight: var(--display-weight);
  font-size: var(--text-display);
  line-height: var(--lh-tight);
  letter-spacing: var(--tracking-display);
  color: var(--color-ink);
  overflow-wrap: anywhere;
  min-width: 0;
}
.hero__title em { font-style: normal; color: var(--color-accent); }
.hero__cluster { display: flex; flex-wrap: wrap; gap: var(--space-sm); margin-top: var(--space-xs); }
.hero__meta {
  display: flex; flex-wrap: wrap; gap: var(--space-xs) var(--space-lg);
  font-family: var(--font-label); font-size: var(--text-xs);
  letter-spacing: 0.04em; text-transform: uppercase; color: var(--color-muted);
  margin-top: var(--space-sm);
}
.hero__meta span { display: inline-flex; align-items: center; gap: 0.6ch; }
.hero__meta span::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--color-accent-2); }

/* ── Material swatch grid (Tier-A CSS art) ─────────────────────── */
.swatches {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-sm);
}
.swatch {
  position: relative;
  aspect-ratio: 5 / 4;
  border-radius: var(--radius-card);
  border: var(--rule-card) solid var(--color-rule);
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  padding: var(--space-md);
  box-shadow: var(--shadow-card);
  transition: transform var(--dur-short) var(--ease-out), box-shadow var(--dur-short) var(--ease-out);
}
.swatch:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.swatch::before {
  content: "";
  position: absolute; inset: 0;
  background:
    linear-gradient(145deg, var(--_hi) 0%, var(--_base) 46%, var(--_base) 60%, var(--_hi) 100%),
    radial-gradient(120% 80% at 20% 0%, oklch(100% 0 0 / 0.18), transparent 55%);
  background-blend-mode: screen;
}
.swatch::after {
  /* brushed-metal striations */
  content: "";
  position: absolute; inset: 0;
  background: repeating-linear-gradient(
    115deg,
    oklch(100% 0 0 / 0.05) 0 1px,
    transparent 1px 4px
  );
  mix-blend-mode: overlay;
}
.swatch__label {
  position: relative;
  font-family: var(--font-label);
  font-size: var(--text-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: oklch(18% 0.02 250);
  background: oklch(96% 0.01 250 / 0.82);
  padding: 0.35em 0.7em;
  border-radius: var(--radius-pill);
}
.swatch--copper    { --_base: var(--metal-copper);    --_hi: var(--metal-copper-hi); }
.swatch--aluminium { --_base: var(--metal-aluminium); --_hi: var(--metal-aluminium-hi); }
.swatch--lead      { --_base: var(--metal-lead);      --_hi: var(--metal-lead-hi); }
.swatch--zinc      { --_base: var(--metal-zinc);      --_hi: var(--metal-zinc-hi); }
.swatch--steel     { --_base: var(--metal-steel);     --_hi: var(--metal-steel-hi); }
.swatch--rvs       { --_base: var(--metal-rvs);       --_hi: var(--metal-rvs-hi); }

/* ── Services — asymmetric list, no icon tiles ─────────────────── */
.services { display: grid; gap: var(--space-md); }
.service {
  display: grid;
  grid-template-columns: 3.5rem 1fr;
  gap: var(--space-lg);
  align-items: start;
  padding: var(--space-lg) 0;
  border-top: var(--rule-hair) solid var(--color-rule);
}
.service:last-child { border-bottom: var(--rule-hair) solid var(--color-rule); }
.service__no {
  font-family: var(--font-label);
  font-size: var(--text-sm);
  color: var(--color-accent);
  padding-top: 0.35em;
  font-variant-numeric: tabular-nums;
}
.service__title { font-family: var(--font-display); font-size: var(--text-lg); color: var(--color-ink); font-weight: 600; }
.service__body { color: var(--color-muted); margin-top: var(--space-2xs); max-width: 52ch; }

/* ── Materials · F3 tabular spec sheet ─────────────────────────── */
.spec { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.spec caption { text-align: left; color: var(--color-muted); font-size: var(--text-sm); margin-bottom: var(--space-md); }
.spec th, .spec td { text-align: left; padding: var(--space-md) var(--space-md) var(--space-md) 0; vertical-align: baseline; }
.spec thead th {
  font-family: var(--font-label); font-size: var(--text-xs); letter-spacing: var(--tracking-label);
  text-transform: uppercase; color: var(--color-muted); font-weight: 500;
  border-bottom: 1.5px solid var(--color-rule-2);
}
.spec tbody tr { border-bottom: var(--rule-hair) solid var(--color-rule); }
.spec tbody tr:hover { background: var(--color-paper-2); }
.spec__metal { color: var(--color-ink); font-weight: 600; font-size: var(--text-md); }
.spec__cat {
  display: inline-block; font-family: var(--font-label); font-size: var(--text-xs);
  letter-spacing: 0.06em; text-transform: uppercase; color: var(--color-accent);
}
.spec__note { color: var(--color-muted); }

/* ── Process · F4 step sequence ────────────────────────────────── */
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-lg); counter-reset: step; }
.step {
  position: relative;
  padding: var(--space-lg);
  background: var(--color-paper-2);
  border: var(--rule-card) solid var(--color-rule);
  border-radius: var(--radius-card);
}
.step__no {
  font-family: var(--font-label);
  font-size: var(--text-sm);
  color: var(--color-accent);
  font-variant-numeric: tabular-nums;
}
.step__title { font-family: var(--font-display); font-size: var(--text-lg); color: var(--color-ink); margin-top: var(--space-sm); font-weight: 600; }
.step__body { color: var(--color-muted); margin-top: var(--space-xs); font-size: var(--text-base); }

/* ── Callout · demontage (real number) ─────────────────────────── */
.callout {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: center;
  padding: clamp(1.75rem, 4vw, 3rem);
  background: var(--color-paper-2);
  border: var(--rule-card) solid var(--color-rule);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
}
.callout__num {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.75rem, 6vw, 4.5rem);
  line-height: 1;
  letter-spacing: var(--tracking-display);
  color: var(--color-accent);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.callout__unit { font-size: 0.4em; color: var(--color-muted); }
.callout__text { color: var(--color-neutral); max-width: 46ch; }
.callout__text strong { color: var(--color-ink); font-weight: 600; }

/* ── Photo placeholder (client supplies real imagery) ──────────── */
.photo-ph {
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-card);
  border: 1.5px dashed var(--color-rule-2);
  background:
    repeating-linear-gradient(135deg, oklch(20% 0.024 250) 0 12px, oklch(22% 0.024 250) 12px 24px);
  display: grid;
  place-content: center;
  gap: var(--space-2xs);
  text-align: center;
  padding: var(--space-lg);
  color: var(--color-muted);
}
.photo-ph__icon { width: 28px; height: 28px; stroke: var(--color-rule-2); justify-self: center; }
.photo-ph__label { font-family: var(--font-label); font-size: var(--text-xs); letter-spacing: 0.06em; text-transform: uppercase; }
.photo-ph__hint { font-size: var(--text-sm); max-width: 28ch; }

/* ── Contact ───────────────────────────────────────────────────── */
.contact__card {
  display: grid;
  gap: var(--space-lg);
  padding: clamp(1.5rem, 4vw, 2.5rem);
  background: var(--color-paper-2);
  border: var(--rule-card) solid var(--color-rule);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
}
.contact__rows { display: grid; gap: var(--space-md); }
.contact__row { display: grid; grid-template-columns: 9rem 1fr; gap: var(--space-md); align-items: baseline; }
.contact__key {
  font-family: var(--font-label); font-size: var(--text-xs); letter-spacing: var(--tracking-label);
  text-transform: uppercase; color: var(--color-muted);
}
.contact__val { color: var(--color-ink-2); font-size: var(--text-md); }
.contact__val a { color: var(--color-ink); text-decoration: none; border-bottom: 1px solid var(--color-rule-2); transition: border-color var(--dur-short) var(--ease-out); }
.contact__val a:hover, .contact__val a:focus-visible { border-bottom-color: var(--color-accent); }
.contact__muted { color: var(--color-muted); font-size: var(--text-sm); }
.contact__note { font-size: var(--text-sm); color: var(--color-muted); }
.contact__actions { display: flex; flex-wrap: wrap; gap: var(--space-sm); }

/* ── Footer · Ft5 statement ────────────────────────────────────── */
.foot {
  margin-top: var(--space-2xl);
  border-top: var(--rule-hair) solid var(--color-rule);
  padding-block: var(--space-3xl) var(--space-xl);
}
.foot__line {
  font-family: var(--font-display);
  font-weight: var(--display-weight);
  font-size: clamp(1.75rem, 5vw, 3.25rem);
  line-height: var(--lh-tight);
  letter-spacing: var(--tracking-display);
  color: var(--color-ink);
  max-width: 22ch;
}
.foot__line em { font-style: normal; color: var(--color-accent); }
.foot__meta {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-md);
  align-items: baseline;
  margin-top: var(--space-2xl);
  padding-top: var(--space-md);
  border-top: var(--rule-hair) solid var(--color-rule);
  color: var(--color-muted); font-size: var(--text-sm);
}
.foot__meta a { color: var(--color-muted); text-decoration: none; }
.foot__meta a:hover, .foot__meta a:focus-visible { color: var(--color-ink-2); }

/* ── Brand logo plaque (nav) ───────────────────────────────────── */
.brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  background: oklch(97% 0.012 90);            /* warm ivory, matches the logo cream */
  border: 1px solid oklch(88% 0.02 90);
  border-radius: 12px;
  padding: 6px 12px;
  line-height: 0;
  box-shadow: 0 2px 6px oklch(8% 0.03 285 / 0.45);
  transition: transform var(--dur-micro) var(--ease-out), box-shadow var(--dur-short) var(--ease-out);
}
.brand:hover { transform: translateY(-1px); box-shadow: 0 4px 12px oklch(8% 0.03 285 / 0.5); }
.brand img { height: 38px; width: auto; }

/* ── Real photography — figure with graceful fallback ──────────── */
.media {
  position: relative;
  border-radius: var(--radius-card);
  overflow: hidden;
  border: var(--rule-card) solid var(--color-rule);
  box-shadow: var(--shadow-card);
  /* fallback shown if the image is missing — striped placeholder ground */
  background:
    repeating-linear-gradient(135deg, oklch(20% 0.024 285) 0 12px, oklch(22% 0.024 285) 12px 24px);
}
.media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  aspect-ratio: var(--_ar, 4 / 3);
}
.media--wide img  { aspect-ratio: 5 / 4; }
.media--photo img { aspect-ratio: 3 / 2; }
.media--pano img  { aspect-ratio: 851 / 315; }
.media__cap {
  position: absolute;
  inset-inline: 0;
  inset-block-end: 0;
  padding: var(--space-sm) var(--space-md);
  font-family: var(--font-label);
  font-size: var(--text-xs);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: oklch(96% 0.01 285);
  background: linear-gradient(to top, oklch(10% 0.02 285 / 0.78), transparent);
}

/* ── Embedded map (contact) ────────────────────────────────────── */
.map {
  position: relative;
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-card);
  overflow: hidden;
  border: var(--rule-card) solid var(--color-rule);
  box-shadow: var(--shadow-card);
  background: var(--color-paper-2);
}
.map iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
  /* tone the bright Google map down to match the dark canvas */
  filter: invert(0.9) hue-rotate(180deg) brightness(0.95) contrast(0.92) saturate(0.85);
  transition: filter var(--dur-long) var(--ease-out);
}
.map:hover iframe,
.map:focus-within iframe { filter: none; }   /* true colours when the user engages */
.map__link { display: inline-block; margin-top: var(--space-sm); }

/* click-to-load consent (AVG — Google wordt pas geladen na klik) */
.map__consent {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-2xs);
  padding: var(--space-lg);
  text-align: center;
  border: 0;
  cursor: pointer;
  font-family: var(--font-body);
  color: var(--color-muted);
  background: repeating-linear-gradient(135deg, oklch(20% 0.024 285) 0 12px, oklch(22% 0.024 285) 12px 24px);
  transition: color var(--dur-short) var(--ease-out);
}
.map__consent:hover, .map__consent:focus-visible { color: var(--color-ink-2); }
.map__consent svg { width: 30px; height: 30px; fill: none; stroke: var(--color-accent); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.map__consent-title { font-family: var(--font-label); font-size: var(--text-xs); letter-spacing: var(--tracking-label); text-transform: uppercase; color: var(--color-ink-2); }
.map__consent-note { font-size: var(--text-sm); max-width: 32ch; line-height: var(--lh-normal); }

@media (prefers-reduced-motion: reduce) {
  .map iframe { transition: none; }
}

/* ── Material swatch strip (in Materialen) ─────────────────────── */
.swatches--strip {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  margin-bottom: var(--space-xl);
}
.swatches--strip .swatch { aspect-ratio: 3 / 2; }

/* ── Entrance — one orchestrated reveal on load ────────────────── */
@keyframes rise {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}
.reveal { opacity: 0; animation: rise var(--dur-long) var(--ease-out) forwards; }
.reveal-1 { animation-delay: 60ms; }
.reveal-2 { animation-delay: 180ms; }
.reveal-3 { animation-delay: 300ms; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; animation: none; }
  .swatch, .btn, .step { transition: none; }
}

/* ── Responsive ────────────────────────────────────────────────── */
@media (max-width: 60rem) {
  .hero__grid { grid-template-columns: 1fr; gap: var(--space-2xl); }
  .diptych { grid-template-columns: 1fr; gap: var(--space-xl); }
  .diptych--reverse .diptych__visual { order: 0; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .callout { grid-template-columns: 1fr; text-align: left; gap: var(--space-md); }
}

@media (max-width: 40rem) {
  body { font-size: var(--text-base); }
  .section { padding-block: var(--space-2xl); }
  .swatches { gap: var(--space-xs); }
  .swatches--strip { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .brand img { height: 28px; }
  .steps { grid-template-columns: 1fr; }
  .spec thead { display: none; }
  .spec tbody tr { display: grid; grid-template-columns: 1fr; gap: var(--space-2xs); padding-block: var(--space-md); }
  .spec th, .spec td { padding: 0; }
  .spec__note { font-size: var(--text-sm); }
  .contact__row { grid-template-columns: 1fr; gap: var(--space-2xs); }
  .foot__meta { flex-direction: column; gap: var(--space-xs); }
  .nav__cta { padding-inline: 1em; }
}
