/* ProtoTanks — one dark system. Serif for voice, grotesque for body, mono for record. */

:root {
  --bg: #0a0b0d;
  --ink: #ebe8e1;
  --ink-2: #b9b5ac;
  --muted: #7d7a73;
  --line: rgba(235, 232, 225, .10);
  --line-strong: rgba(235, 232, 225, .22);
  --gold: #c9a86a;          /* arrival gold, dimmed for print-like restraint */
  --gold-bright: #ffd080;

  --paper: #f4efe3;
  --paper-ink: #2a2118;
  --paper-ink-2: #5b4f42;
  --paper-rule: #b8ab93;
  --paper-accent: #8a3b2a;

  --serif: "Cormorant Garamond", "EB Garamond", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;

  --gutter: clamp(1.25rem, 5vw, 5rem);
  --max: 1320px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

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

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible { outline: 1px solid var(--gold-bright); outline-offset: 4px; }

.skip { position: absolute; left: -999px; top: 0; }
.skip:focus { left: 1rem; top: 1rem; background: var(--ink); color: var(--bg); padding: .5rem 1rem; z-index: 100; }
main:focus { outline: none; }

.mono { font-family: var(--mono); font-size: .6875rem; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }

/* ─── nav ─── */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.25rem var(--gutter);
  flex-wrap: wrap; gap: .75rem 1rem;
  transition: background .4s ease, backdrop-filter .4s ease, border-color .4s ease;
  border-bottom: 1px solid transparent;
}
.nav.scrolled { background: rgba(10, 11, 13, .72); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-color: var(--line); }
.wordmark { font-family: var(--serif); font-weight: 400; font-size: 1.5rem; letter-spacing: .02em; color: var(--ink); }
.wordmark span { font-style: italic; font-weight: 300; color: var(--gold); }
.nav nav { display: flex; gap: clamp(1rem, 2.5vw, 2.25rem); align-items: center; flex-wrap: wrap; min-width: 0; max-width: 100%; }
.nav nav a { font-size: .8125rem; letter-spacing: .04em; color: var(--ink-2); transition: color .2s; }
.nav nav a:hover { color: var(--ink); }
.nav nav a.cta { color: var(--gold); border: 1px solid rgba(201, 168, 106, .45); padding: .45rem .9rem; border-radius: 999px; }
.nav nav a.cta:hover { border-color: var(--gold); color: var(--gold-bright); }
@media (max-width: 760px) { .nav nav a:not(.cta) { display: none; } }

/* ─── type ─── */
.eyebrow { font-family: var(--mono); font-size: .6875rem; letter-spacing: .16em; text-transform: uppercase; color: var(--gold); margin: 0 0 1.25rem; }
h1, h2, h3 { font-family: var(--serif); font-weight: 300; line-height: 1.02; letter-spacing: -.005em; margin: 0; }
h1 { font-size: clamp(3rem, 8.5vw, 7.25rem); }
h1 em, h2 em { font-style: italic; font-weight: 300; color: var(--ink); }
h2 { font-size: clamp(2.25rem, 5vw, 4rem); }
h3 { font-size: 1.625rem; font-weight: 400; margin-bottom: .5rem; }
.lede { font-size: clamp(1.125rem, 1.6vw, 1.375rem); line-height: 1.5; color: var(--ink-2); max-width: 46ch; margin: 2rem 0 0; }
.lede strong { font-weight: 400; color: var(--ink); }
.prose p { margin: 0 0 1.25rem; color: var(--ink-2); max-width: 58ch; }
.prose p:last-child { margin-bottom: 0; }
.prose a { border-bottom: 1px solid var(--line-strong); color: var(--ink); }
.prose a:hover { border-color: var(--gold); }
.prose a.btn { color: var(--bg); border-bottom: none; }
.prose a.btn:hover { color: var(--bg); }
.prose em { font-style: italic; }
.small { font-size: .875rem; color: var(--muted); }

.btn {
  display: inline-block; font-size: .875rem; letter-spacing: .04em; font-weight: 400;
  color: var(--bg); background: var(--ink); padding: .95rem 1.6rem; border-radius: 999px;
  transition: background .2s, transform .2s;
}
.btn:hover { background: #fff; transform: translateY(-1px); }
.link { font-size: .875rem; letter-spacing: .04em; color: var(--ink-2); margin-left: 1.5rem; }
.link:hover { color: var(--ink); }
.actions { display: flex; align-items: center; flex-wrap: wrap; gap: .75rem 0; margin-top: 2.5rem; }

/* ─── layout ─── */
.section { padding: clamp(5rem, 12vw, 11rem) var(--gutter); max-width: var(--max); margin: 0 auto; border-top: 1px solid var(--line); }
.grid-2 { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(2rem, 5vw, 6rem); align-items: start; }
@media (max-width: 900px) { .grid-2 { grid-template-columns: 1fr; gap: 2rem; } }

/* ─── hero ─── */
.hero { padding: clamp(7rem, 14vh, 9.5rem) var(--gutter) 0; max-width: var(--max); margin: 0 auto; }
.hero-copy { max-width: 60rem; }
.hero-wall { margin: clamp(2.5rem, 5vw, 4rem) 0 0; padding-left: clamp(1rem, 5vw, 4rem); padding-right: clamp(1rem, 5vw, 4rem); }
.hero-wall figcaption { margin-top: 1.25rem; text-align: center; display: flex; justify-content: center; align-items: center; gap: 1rem; flex-wrap: wrap; }
.motion { font: inherit; letter-spacing: inherit; text-transform: inherit; color: var(--ink-2); background: none; border: 1px solid var(--line-strong); border-radius: 999px; padding: .3rem .7rem; cursor: pointer; }
.motion:hover { color: var(--ink); border-color: var(--ink-2); }

/* ─── frameless screen mock ─── */
.wall {
  position: relative; margin: 0;
  padding: clamp(1.5rem, 5vw, 4rem) clamp(1rem, 4vw, 3.5rem) 0;
  background:
    radial-gradient(120% 80% at 50% 0%, #15181c 0%, var(--bg) 70%);
  border-radius: 2px;
}
.screen { position: relative; margin: 0; width: 100%; }
.screen .spill {
  position: absolute; inset: -6% -4%; width: 108%; height: 112%;
  object-fit: cover; filter: blur(70px) saturate(1.1); opacity: .42; pointer-events: none;
  transform: translateZ(0);
}
.screen .panel {
  position: relative; z-index: 1;
  background: #000; border-radius: 3px; overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(255,255,255,.07),
    0 1px 0 rgba(255,255,255,.05) inset,
    0 40px 90px -30px rgba(0,0,0,.9);
}
.screen .panel img { width: 100%; height: 100%; object-fit: cover; }
.screen .panel::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(118deg, rgba(255,255,255,.07) 0%, rgba(255,255,255,0) 30%);
}
.screen .floor {
  position: relative; z-index: 0; height: 26%; overflow: hidden; margin-top: 2px; pointer-events: none;
  -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,.5), rgba(0,0,0,0) 90%);
          mask-image: linear-gradient(to bottom, rgba(0,0,0,.5), rgba(0,0,0,0) 90%);
}
.screen .floor img { width: 100%; height: auto; transform: scaleY(-1); transform-origin: center; filter: blur(3px); opacity: .9; }
.screen-hero .panel { aspect-ratio: 16 / 7.8; }
.screen-hero .floor { height: 120px; }
@media (max-width: 700px) { .screen-hero .panel { aspect-ratio: 16 / 10; } .screen-hero .floor { height: 60px; } }

@media (prefers-reduced-motion: no-preference) {
  .screen-hero .panel img { animation: drift 40s ease-in-out infinite alternate; }
  .motion-paused .screen-hero .panel img { animation-play-state: paused; }
  @keyframes drift { from { transform: scale(1) translateX(0); } to { transform: scale(1.06) translateX(-1.5%); } }
}

/* installs */
.installs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.25rem; margin-top: 2.5rem; align-items: end; }
@media (max-width: 900px) { .installs { grid-template-columns: 1fr; } }
.install { display: flex; flex-direction: column; justify-content: flex-end; min-height: 100%; padding: clamp(2rem, 4vw, 3rem) 1.5rem 0; }
.install .screen { margin: auto auto 0; }
.install figcaption { padding: 1.25rem 0 1.5rem; display: flex; flex-direction: column; gap: .25rem; text-align: left; }
.formats-label { margin: clamp(3rem, 6vw, 5rem) 0 -1.5rem; }
.install figcaption b { font-family: var(--serif); font-weight: 400; font-size: 1.375rem; }
.screen.portrait { width: 64%; }
.screen.portrait .panel { aspect-ratio: 9 / 16; }
.screen.portrait .floor { height: 70px; }
.screen.landscape { width: 100%; }
.screen.landscape .panel { aspect-ratio: 16 / 9; }
.screen.landscape .floor { height: 60px; }
.screen.ultrawide { width: 100%; }
.screen.ultrawide .panel { aspect-ratio: 21 / 9; }
.screen.ultrawide .floor { height: 50px; }
.venues { list-style: none; margin: 3rem 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem .75rem; }
.venues li { font-size: .8125rem; letter-spacing: .04em; color: var(--ink-2); border: 1px solid var(--line-strong); border-radius: 999px; padding: .45rem 1rem; }

/* ─── stats ─── */
.stats { list-style: none; padding: 0; margin: clamp(3rem, 6vw, 5rem) 0 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem; border-top: 1px solid var(--line); }
@media (max-width: 760px) { .stats { grid-template-columns: 1fr; } }
.stats li { padding-top: 1.5rem; display: flex; flex-direction: column; gap: .5rem; min-width: 0; overflow-wrap: anywhere; }
.stat-k { font-family: var(--serif); font-size: 2rem; font-weight: 300; line-height: 1; }
.stat-v { color: var(--ink-2); font-size: .9375rem; max-width: 30ch; }

/* ─── bleed figure ─── */
.bleed { margin: clamp(3rem, 6vw, 5rem) 0 0; }
.bleed img { width: 100%; border-radius: 2px; }
.bleed figcaption { margin-top: 1rem; }

/* ─── offer ─── */
.offer { list-style: none; margin: clamp(3rem, 6vw, 5rem) 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
@media (max-width: 760px) { .offer { grid-template-columns: 1fr; } }
.offer li { padding: 2.25rem 2rem 2.5rem; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); display: flex; flex-direction: column; }
.offer .num { font-family: var(--mono); font-size: .6875rem; letter-spacing: .16em; color: var(--gold); margin-bottom: 2.5rem; }
.offer p { margin: 0; color: var(--ink-2); font-size: .9375rem; }

/* ─── gallery ─── */
.gallery { margin-top: clamp(3rem, 6vw, 5rem); display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: minmax(160px, auto); gap: 1rem; }
.gallery figure { margin: 0; position: relative; overflow: hidden; border-radius: 2px; background: #000; }
.gallery img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 1; transition: transform 1.2s ease; }
.gallery figure:hover img { transform: scale(1.03); }
@media (prefers-reduced-motion: reduce) { .gallery img { transition: none; } .gallery figure:hover img { transform: none; } .btn:hover { transform: none; } }
.gallery .tall { grid-row: span 2; }
.gallery .tall img { aspect-ratio: 4 / 5; height: 100%; }
.gallery .wide { grid-column: span 2; }
.gallery .wide img { aspect-ratio: 2 / 1; }
.gallery figcaption { position: absolute; left: 1rem; bottom: .9rem; right: 1rem; width: fit-content; max-width: calc(100% - 2rem); padding: .3rem .5rem; color: var(--ink); background: var(--bg); }
@media (max-width: 900px) { .gallery { grid-template-columns: repeat(2, 1fr); } .gallery .wide { grid-column: span 2; } }
@media (max-width: 520px) { .gallery { grid-template-columns: 1fr; } .gallery .tall { grid-row: auto; } .gallery .wide { grid-column: auto; } }

/* ─── provenance ─── */
.prov-grid { margin-top: clamp(3rem, 6vw, 5rem); display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 6fr); gap: clamp(2rem, 5vw, 5rem); align-items: start; }
.cert, .heredity { min-width: 0; }
@media (max-width: 900px) { .prov-grid { grid-template-columns: 1fr; } }

.cert {
  margin: 0; background: var(--paper); color: var(--paper-ink); padding: 2rem 2.25rem 1.75rem;
  border-radius: 2px; position: relative;
  box-shadow: 0 30px 80px -30px rgba(0,0,0,.8), 0 0 0 1px rgba(0,0,0,.4);
  background-image: radial-gradient(120% 60% at 50% -10%, rgba(255,255,255,.55), rgba(255,255,255,0) 60%);
}
.cert::before { content: ""; position: absolute; inset: 10px; border: .5px solid var(--paper-rule); pointer-events: none; }
.cert::after { content: ""; position: absolute; inset: 13px; border: 2px solid var(--paper-ink); opacity: .55; pointer-events: none; }
.cert-head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; padding-bottom: .9rem; border-bottom: .5px solid var(--paper-rule); }
.cert-series { font-family: var(--mono); font-size: .6875rem; letter-spacing: .22em; text-transform: uppercase; color: var(--paper-ink-2); }
.cert .cert-no { color: var(--paper-accent); }
.cert-plate { margin: 1.25rem 0 1rem; background: #000; aspect-ratio: 21 / 11; border: .5px solid var(--paper-ink); position: relative; display: grid; place-items: center; overflow: hidden; }
.cert-plate::before { content: ""; position: absolute; inset: 3px; border: .5px solid rgba(244,239,227,.35); pointer-events: none; }
.cert-plate img { width: 82%; height: 82%; max-width: 420px; object-fit: contain; }
.cert-plate span { position: absolute; left: .75rem; bottom: .55rem; color: rgba(244,239,227,.7); }
.cert-name { font-family: var(--serif); font-size: 2.25rem; font-weight: 500; line-height: 1; margin: .5rem 0 1rem; color: var(--paper-ink); }
.cert-name em { font-style: italic; font-weight: 400; }
.cert-dl { margin: 0; display: grid; gap: .35rem; }
.cert-dl div { display: grid; grid-template-columns: minmax(0, 7rem) minmax(0, 1fr); gap: 1rem; align-items: baseline; border-bottom: 1px dotted var(--paper-rule); padding-bottom: .3rem; }
.cert-dl dt { font-family: var(--mono); font-size: .625rem; letter-spacing: .14em; text-transform: uppercase; color: var(--paper-ink-2); }
.cert-dl dd { margin: 0; font-size: .9375rem; color: var(--paper-ink); min-width: 0; overflow-wrap: anywhere; }
.cert-dl dd.hash { font-size: .6875rem; text-transform: none; letter-spacing: .02em; color: var(--paper-accent); word-break: break-all; }
.genes { display: block; width: 100%; height: 40px; margin: 1.25rem 0 .75rem; }
.genes rect { fill: var(--paper-ink); opacity: .7; }
.cert-foot { text-transform: none; letter-spacing: .02em; font-size: .6875rem; color: var(--paper-ink-2); margin: 0; }

.heredity .eyebrow { margin-bottom: 1.5rem; }
.fig3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .75rem; }
@media (max-width: 480px) {
  .cert { padding: 1.5rem 1.25rem; }
  .cert-dl div { grid-template-columns: 1fr; gap: .2rem; }
  .fig3 { grid-template-columns: 1fr; }
  .fig3 img { max-width: 220px; }
}
.fig3 figure { margin: 0; }
.fig3 img { width: 100%; aspect-ratio: 1; object-fit: cover; background: #0e1014; border-radius: 2px; border: 1px solid var(--line); }
.fig3 figcaption { margin-top: .6rem; display: flex; flex-direction: column; gap: .15rem; }
.fig3 b { font-weight: 400; font-size: .8125rem; }
.fig3 span { font-size: .75rem; color: var(--muted); }
.heredity .small { margin-top: 1.5rem; max-width: 40ch; }

/* ─── features ─── */
.features { list-style: none; margin: clamp(3rem, 6vw, 5rem) 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 3rem 4rem; }
@media (max-width: 760px) { .features { grid-template-columns: 1fr; gap: 2rem; } }
.features li { border-top: 1px solid var(--line); padding-top: 1.5rem; }
.features h3 { font-size: 1.5rem; }
.features p { margin: 0; color: var(--ink-2); font-size: .9375rem; max-width: 40ch; }
.tag { display: inline-block; font-family: var(--mono); font-size: .625rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); border: 1px solid rgba(201,168,106,.4); border-radius: 999px; padding: .15rem .55rem; margin-left: .4rem; vertical-align: middle; }

/* ─── lineage ─── */
.lineage-figs { margin-top: clamp(3rem, 6vw, 5rem); display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 760px) { .lineage-figs { grid-template-columns: 1fr; } }
.lineage-figs figure { margin: 0; }
.lineage-figs img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; border-radius: 2px; background: #000; }
.lineage-figs figcaption { margin-top: .75rem; }
.lineage-figs .inv img { filter: invert(.93) contrast(1.05); }

/* ─── inquire ─── */
.enquire .contact { margin: 1.75rem 0 2.5rem; }
.enquire .btn { font-family: var(--mono); letter-spacing: .06em; text-transform: none; }
.process { list-style: none; margin: 0 0 2rem; padding: 0; display: grid; gap: 0; counter-reset: step; }
.process li { display: grid; grid-template-columns: 2rem 9rem 1fr; gap: 1rem; align-items: baseline; padding: .9rem 0; border-top: 1px solid var(--line); }
.process li::before { counter-increment: step; content: counter(step, decimal-leading-zero); font-family: var(--mono); font-size: .6875rem; color: var(--gold); letter-spacing: .1em; }
.process b { font-weight: 400; color: var(--ink); }
.process span { color: var(--muted); font-size: .9375rem; }
@media (max-width: 560px) { .process li { grid-template-columns: 2rem 1fr; } .process span { grid-column: 2; } }

/* ─── footer ─── */
.foot { border-top: 1px solid var(--line); padding: 3rem var(--gutter) 3.5rem; max-width: var(--max); margin: 0 auto; display: grid; grid-template-columns: 1fr auto; gap: 2rem; align-items: start; }
.foot nav { display: flex; gap: 1.75rem; flex-wrap: wrap; }
.foot nav a { font-size: .8125rem; color: var(--ink-2); }
.foot nav a:hover { color: var(--ink); }
.foot > .mono { grid-column: 1 / -1; text-transform: none; letter-spacing: .02em; margin: 0; }
.foot .wordmark { font-size: 1.25rem; }
.foot div .mono { margin: .5rem 0 0; }
@media (max-width: 640px) { .foot { grid-template-columns: 1fr; } }

/* ─── reveal ─── */
.reveal-ready .reveal { opacity: 0; transform: translateY(18px); transition: opacity .9s cubic-bezier(.2,.6,.2,1), transform .9s cubic-bezier(.2,.6,.2,1); }
.reveal-ready .reveal.in { opacity: 1; transform: none; }

/* ─── secondary pages ─── */
.page { max-width: 44rem; margin: 0 auto; padding: clamp(5rem, 14vh, 9rem) var(--gutter) 6rem; }
.page .wordmark { display: inline-block; margin-bottom: 3rem; }
.page h1 { font-size: clamp(2.5rem, 6vw, 4.5rem); margin-bottom: 1.5rem; }
.page .prose { margin-top: 1.5rem; }
.page .actions { margin-top: 2.5rem; }
