/* f00.sh hub — content-width header rule · soft radial film · no edge box */
:root {
  --max: 68rem;
  --pad: clamp(1rem, 3vw, 2rem);
  --header-h: 3.35rem;
  --splash-max: clamp(8rem, 28vw, 18rem);
  --splash-rest: clamp(4.25rem, 12vw, 7rem);
  --splash-slot-h: 40vh;
  /* same air: header line → logo top  AND  logo bottom → projects line */
  --logo-gap: 1.75rem;
  --p: 0;
  --dock-y: 0px;
  --dock-op: 1;
  --film-poppy: #d44a18;
  --film-sky: #1e78c8;
  --film-cream: #ede6de;
  --film-ink: #090909;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100dvh;
  overflow-x: hidden;
}

.crt, #field { display: none !important; }

.skip {
  position: absolute; left: -999px; top: 0; z-index: 200;
  background: #090909; color: #d0d5db; padding: 0.5rem 1rem;
  border: 1px solid #d0d5db;
}
.skip:focus { left: 1rem; top: 1rem; }

/* ════════ HEADER ════════
 * Plate = full-bleed frost (cutoff only).
 * Rule = CONTENT WIDTH on .top-inner — same as .foot.
 * Theme forces .top { border-bottom } — kill with higher specificity.
 */
header.top,
.top {
  position: fixed !important;
  top: 0 !important;
  left: 0;
  right: 0;
  z-index: 50 !important;
  margin: 0 !important;
  padding: 0 !important;
  max-width: none !important;
  width: 100% !important;
  opacity: 1 !important;
  pointer-events: none;
  border: 0 !important;
  border-top: 0 !important;
  border-right: 0 !important;
  border-bottom: 0 !important;
  border-left: 0 !important;
  border-color: transparent !important;
  box-shadow: none !important;
  background: transparent !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}
/* no frost / shadow plate — header sits straight on the field */
header.top::before,
.top::before {
  content: none !important;
  display: none !important;
  background: none !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}
.top-inner {
  position: relative;
  z-index: 1;
  pointer-events: auto;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  max-width: var(--max);
  width: 100%;
  margin: 0 auto;
  padding: 0.95rem var(--pad);
  /* rule is projected SVG (.e-rule) — never a CAD 1px collinear border */
  border: 0 !important;
  border-bottom: 0 !important;
  box-shadow: none !important;
  background: transparent !important;
}
.brand {
  display: inline-flex;
  align-items: baseline;
  gap: 0.25rem;
  text-decoration: none;
  cursor: pointer;
}
.brand-mark { font-size: 1.45rem; letter-spacing: 0.14em; }
.brand-sub { letter-spacing: 0.14em; font-size: 0.8rem; }
.nav { display: flex; gap: 1.15rem; font-size: 0.82rem; letter-spacing: 0.14em; }
.nav a {
  text-decoration: none;
  border-bottom: 1px solid transparent;
  text-transform: uppercase;
}

main {
  position: relative;
  z-index: 1;
  padding-top: var(--header-h);
}

/* slot only — no film rects here */
.hero {
  position: relative;
  z-index: 5;
  width: 100%;
  height: var(--splash-slot-h);
  margin: 0;
  padding: 0;
  pointer-events: none;
}

/* fixed under header — equal air above mark (= --logo-gap under header line) */
.splash-frame {
  position: fixed;
  top: var(--header-h);
  left: 0;
  right: 0;
  z-index: 6;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  width: 100%;
  margin: 0;
  /* top padding = logo-gap so header line ↔ logo top matches logo bottom ↔ projects */
  padding: var(--logo-gap) var(--pad) 0;
  pointer-events: none;
  transform: translateY(var(--dock-y, 0px));
  opacity: var(--dock-op, 1);
  will-change: transform, opacity;
  overflow: visible;
}
.splash-frame::before { content: none !important; display: none !important; }

/* mark + WebGL film plate share one box that tracks font-size reflow */
.splash-wrap {
  position: relative;
  display: inline-block;
  max-width: 100%;
  pointer-events: none;
  overflow: visible; /* bloom / CA pad extends past glyph box */
}
/* WebGL canvas — true film plate (warp / CA / bloom / grain in shader) */
.splash-film {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
  pointer-events: none;
  display: none;
  background: transparent !important;
  /* no CSS filter — shader owns the look */
  filter: none !important;
  mix-blend-mode: normal;
}
.splash-wrap.is-film .splash-film {
  display: block;
}
/* DOM mark holds layout + a11y; invisible when shader plate is live */
.splash-wrap.is-film .splash,
.splash-wrap.is-film .splash .glyph {
  color: transparent !important;
  text-shadow: none !important;
  animation: none !important;
}
.splash-wrap.is-film .splash .glyph::before,
.splash-wrap.is-film .splash .glyph::after {
  content: none !important;
  display: none !important;
}
/* legacy CSS film layers — off (shader owns the look) */
.film-bloom,
.film-grain,
.film-gate {
  display: none !important;
}

.splash {
  margin: 0;
  display: inline-block;
  position: relative;
  z-index: 1;
  pointer-events: auto;
  font-size: calc(
    var(--splash-rest) + (var(--splash-max) - var(--splash-rest)) * (1 - var(--p, 0))
  ) !important;
  line-height: 0.86 !important;
  letter-spacing: var(--splash-tracking, -0.055em) !important;
  font-weight: 400 !important;
  user-select: none;
  white-space: nowrap;
  width: max-content;
  color: var(--film-ink) !important;
  transition: none;
  transform-origin: top center;
  isolation: isolate;
}
.splash, .splash .glyph, h1.splash, .brand-mark {
  text-transform: none !important;
}

.splash .glyph {
  display: inline-block;
  position: relative;
  font-size: inherit !important;
  font-family: inherit !important;
  color: var(--film-ink) !important;
}
/* no CSS “glitch” plates — film is WebGL (film-logo.js) */
.splash .glyph::before,
.splash .glyph::after {
  content: none !important;
  display: none !important;
}

.hero-cue { display: none !important; }

.projects, .products {
  position: relative;
  z-index: 2;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--pad) 3rem;
  opacity: 1;
  transform: none;
}
.section-head {
  margin-bottom: 1rem;
  border-bottom: 0 !important; /* SVG emulsion rule via f00-entropy */
  padding-bottom: 0.45rem;
}
.section-head h2 {
  margin: 0;
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 700;
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr));
  gap: 1.1rem;
  border: 0;
}
.card-actions {
  display: flex; flex-wrap: wrap; margin-top: 0.75rem; padding-top: 0.65rem;
  border-top: 1px solid rgba(9, 9, 9, 0.25);
}
.card-actions .btn { margin: 0 0.4rem 0.35rem 0; }
.facts { margin: 0.75rem 0; padding: 0; list-style: none; font-size: 0.85rem; }
.facts li { margin: 0.15rem 0; padding: 0.15rem 0; }

.foot {
  max-width: var(--max);
  margin: 0 auto;
  padding: 1.1rem var(--pad) 2rem;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: none;
  position: relative;
  z-index: 1;
  border-top: 0 !important;
}
.foot-stars {
  text-decoration: none;
  font-family: var(--font-chip, ui-monospace, monospace);
  letter-spacing: 0.12em;
  font-variant-numeric: tabular-nums;
  color: rgba(208, 213, 219, 0.92) !important;
}
.foot-stars:hover { color: #e4e8ed !important; }

@media (prefers-reduced-motion: reduce) {
  .splash { font-size: var(--splash-rest) !important; }
  .film-bloom, .film-grain, .film-gate { animation: none; opacity: 0.12; }
  .splash .glyph { animation: none; }
  .hero-cue { display: none; }
  html { scroll-behavior: auto; }
}

@media (max-width: 520px) {
  .nav { gap: 0.7rem; font-size: 0.72rem; }
  :root {
    --splash-max: clamp(5.5rem, 26vw, 10rem);
    --splash-rest: clamp(3.5rem, 16vw, 5.5rem);
    --header-h: 3.1rem;
    --logo-gap: 1.35rem;
  }
  .card h3 { font-size: 0.88rem; }
  .grid { gap: 1.1rem; }
}
