/* =============================================================
   Ironbridge Machine Works — styles.css  (DEMO · fictional business)
   Archetype 03 — Cinematic 3D, taken to the machine shop:
   one turned steel part spins on the "spindle" behind every page
   while a copper toolpath advances with the scroll.
   Palette: graphite + bare steel + heat-tint copper (not gold).
   Type: EB Garamond (display) · Manrope (body) · JetBrains Mono (data).
   1 Fonts · 2 Tokens · 3 Reset · 4 Utilities · 5 Scene layers
   6 Header · 7 Components · 8 Sections · 9 Pages · 10 Footer
   11 Effects · 12 Responsive · 13 Reduced motion
   ============================================================= */

/* =============================================================
   1. Fonts — self-hosted (no request to third parties).
   SIL Open Font License 1.1 — see assets/fonts/LICENSES.txt
   ============================================================= */
@font-face {
  font-family: "EB Garamond";
  src: url("assets/fonts/eb-garamond.woff2") format("woff2");
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "EB Garamond";
  src: url("assets/fonts/eb-garamond-italic.woff2") format("woff2");
  font-weight: 500; font-style: italic; font-display: swap;
}
@font-face {
  font-family: "Manrope";
  src: url("assets/fonts/manrope.woff2") format("woff2");
  font-weight: 400 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("assets/fonts/jetbrains-mono.woff2") format("woff2");
  font-weight: 400 500; font-style: normal; font-display: swap;
}

/* =============================================================
   2. Tokens
   ============================================================= */
:root {
  --bg-deep:   #07080a;   /* graphite, a touch cool */
  --bg-soft:   #0d0f12;
  --panel:     rgba(9, 10, 12, 0.9);
  --panel-2:   rgba(14, 16, 19, 0.94);
  --line:      rgba(222, 214, 202, 0.14);
  --line-2:    rgba(222, 214, 202, 0.26);

  --copper:    #e8955a;   /* heat-tint copper — the metallic accent */
  --copper-2:  #c9793f;
  --copper-3:  #8a4f27;
  --steel:     #a3adb6;

  --text:       #ede8df;  /* never #fff */
  --text-muted: rgba(237, 232, 223, 0.74);
  --text-dim:   rgba(237, 232, 223, 0.5);

  --serif: "EB Garamond", "Iowan Old Style", Georgia, serif;
  --sans:  "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --mono:  "JetBrains Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;

  --gutter: clamp(16px, 4.5vw, 56px);
  --maxw: 1280px;
  --strip-h: 30px;
  --nav-h: 68px;

  --ease-out:  cubic-bezier(0.16, 1, 0.3, 1);
  --ease-soft: cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* =============================================================
   3. Reset & base
   ============================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + var(--strip-h) + 16px); }
body {
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg-deep);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}
img, svg, video, canvas { display: block; max-width: 100%; }
img { height: auto; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
a { color: inherit; text-decoration: none; }
p { text-wrap: pretty; }
h1, h2, h3, h4 { text-wrap: balance; line-height: 1.04; letter-spacing: -0.015em; font-weight: 500; }
ul, ol { padding: 0; list-style: none; }
::selection { background: var(--copper); color: var(--bg-deep); }
:focus-visible { outline: 2px solid var(--copper); outline-offset: 3px; border-radius: 2px; }

@view-transition { navigation: auto; }
::view-transition-old(root), ::view-transition-new(root) {
  animation-duration: .45s; animation-timing-function: var(--ease-out);
}

/* =============================================================
   4. Utilities
   ============================================================= */
.skip-link {
  position: fixed; top: -100px; left: 1rem; z-index: 9999;
  padding: .6rem 1rem; background: var(--text); color: var(--bg-deep);
  font-weight: 600; border-radius: 2px;
}
.skip-link:focus { top: 1rem; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.wrap { width: min(100% - 2 * var(--gutter), var(--maxw)); margin-inline: auto; }
.mono { font-family: var(--mono); }
.kicker {
  font-family: var(--mono); font-size: .74rem; font-weight: 500;
  letter-spacing: .14em; text-transform: uppercase; color: var(--copper);
  display: inline-flex; align-items: center; gap: .7em;
}
.kicker::before { content: ""; width: 26px; height: 1px; background: currentColor; }
.lead { font-size: clamp(1.05rem, 1.4vw, 1.2rem); color: var(--text-muted); max-width: 56ch; }
.muted { color: var(--text-muted); }

/* =============================================================
   5. Scene layers (the fixed 3D background + contrast layers)
   ============================================================= */
.scene-canvas {
  position: fixed; inset: 0; z-index: 0;
  width: 100vw; height: 100vh; height: 100lvh;
  background: var(--bg-deep);
  opacity: 0; transition: opacity 1.4s var(--ease-soft);
}
.scene-ready .scene-canvas { opacity: 1; }
.scene-fallback {
  position: fixed; inset: 0; z-index: 0; display: none;
  background:
    radial-gradient(60% 50% at 72% 40%, rgba(232, 149, 90, .16), transparent 70%),
    radial-gradient(40% 40% at 20% 80%, rgba(163, 173, 182, .10), transparent 70%),
    var(--bg-deep);
}
.no-webgl .scene-fallback { display: block; }
.no-webgl .scene-canvas { display: none; }

.scrim    { position: fixed; inset: 0; z-index: 1; background: rgba(7, 8, 10, .26); pointer-events: none; }
.vignette {
  position: fixed; inset: 0; z-index: 1; pointer-events: none;
  background:
    radial-gradient(ellipse at center, transparent 32%, rgba(7, 8, 10, .42) 72%, rgba(7, 8, 10, .84) 100%),
    linear-gradient(180deg, rgba(7, 8, 10, .6) 0%, transparent 26%, transparent 72%, rgba(7, 8, 10, .74) 100%);
}
.grain {
  position: fixed; inset: 0; z-index: 2; opacity: .06; pointer-events: none; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
/* Pages with long text dim the scene a little more */
[data-scene="quote"] .scrim,
[data-scene="privacy"] .scrim { background: rgba(7, 8, 10, .5); }

.page { position: relative; z-index: 3; overflow-x: clip; }

/* Spindle read-out (decorative) */
.hud {
  position: fixed; right: var(--gutter); bottom: 18px; z-index: 4;
  font-family: var(--mono); font-size: .68rem; letter-spacing: .08em; color: var(--text-dim);
  display: none; gap: 1.2rem; pointer-events: none; text-transform: uppercase;
  padding: .45rem .8rem; background: rgba(7, 8, 10, .82); border: 1px solid var(--line);
}
.hud b { color: var(--copper); font-weight: 500; }
.hud { transition: opacity .4s var(--ease-out); }
.hud-off .hud { opacity: 0; }

/* =============================================================
   6. Header — demo strip + nav
   ============================================================= */
.site-header { position: fixed; inset: 0 0 auto 0; z-index: 50; }
.demo-strip {
  min-height: var(--strip-h);
  display: flex; align-items: center; justify-content: center;
  background: var(--copper); color: #140b05;
  font-family: var(--mono); font-size: .7rem; font-weight: 500; letter-spacing: .04em; line-height: 1.25;
  padding: 4px 12px; text-align: center;
}
.demo-strip a { text-decoration: underline; text-underline-offset: 3px; }
.demo-strip a:hover { text-decoration-thickness: 2px; }

.nav {
  height: var(--nav-h);
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding-inline: var(--gutter);
  border-bottom: 1px solid transparent;
  transition: background-color .35s var(--ease-out), border-color .35s var(--ease-out);
}
.is-scrolled .nav, .nav-open .nav {
  background: rgba(7, 8, 10, .9);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-bottom-color: var(--line);
}
.brand { display: flex; align-items: center; gap: .7rem; line-height: 1; }
.brand svg { width: 30px; height: 30px; color: var(--copper); flex: none; }
.brand-name { font-family: var(--serif); font-size: 1.45rem; letter-spacing: -.01em; }
.brand-sub { display: block; font-family: var(--mono); font-size: .58rem; letter-spacing: .24em; color: var(--text-dim); margin-top: .3rem; }

.nav-links { display: none; align-items: center; gap: .3rem; }
.nav-links a {
  font-size: .9rem; font-weight: 500; padding: .5rem .85rem; color: var(--text-muted);
  transition: color .25s var(--ease-out);
}
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--text); }
.nav-links a[aria-current="page"] { box-shadow: inset 0 -1px 0 var(--copper); }

.nav-toggle {
  width: 44px; height: 44px; display: grid; place-content: center; gap: 6px;
  border: 1px solid var(--line-2); border-radius: 2px;
}
.nav-toggle span { display: block; width: 18px; height: 1.5px; background: var(--text); transition: transform .3s var(--ease-out); }
.nav-open .nav-toggle span:first-child { transform: translateY(3.75px) rotate(45deg); }
.nav-open .nav-toggle span:last-child  { transform: translateY(-3.75px) rotate(-45deg); }

.mobile-menu {
  display: none;
  background: var(--bg-deep); border-bottom: 1px solid var(--line);
  padding: 1rem var(--gutter) 1.6rem;
  max-height: calc(100svh - var(--strip-h) - var(--nav-h)); overflow-y: auto;
}
.nav-open .mobile-menu { display: block; }
.mobile-menu a {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: .95rem 0; border-bottom: 1px solid var(--line);
  font-family: var(--serif); font-size: 1.6rem;
}
.mobile-menu a span { font-family: var(--mono); font-size: .7rem; color: var(--copper); }
.mobile-menu .btn { margin-top: 1.2rem; width: 100%; justify-content: center; }

/* =============================================================
   7. Components
   ============================================================= */
.btn {
  display: inline-flex; align-items: center; gap: .65rem;
  min-height: 48px; padding: .8rem 1.35rem;
  font-weight: 600; font-size: .95rem; letter-spacing: .01em;
  border-radius: 2px; border: 1px solid transparent;
  transition: background-color .3s var(--ease-out), color .3s var(--ease-out), border-color .3s var(--ease-out), transform .3s var(--ease-out);
}
.btn svg { width: 16px; height: 16px; transition: transform .3s var(--ease-out); }
.btn:hover svg { transform: translateX(3px); }
.btn-metal {
  color: #170c05;
  background: linear-gradient(180deg, #f3b07c 0%, var(--copper) 45%, var(--copper-2) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 236, 214, .55), 0 10px 30px -12px rgba(232, 149, 90, .7);
}
.btn-metal:hover { transform: translateY(-1px); background: linear-gradient(180deg, #f7c196 0%, #eea36c 45%, var(--copper) 100%); }
.btn-line { color: var(--text); border-color: var(--line-2); background: rgba(7, 8, 10, .35); }
.btn-line:hover { border-color: var(--copper); color: var(--copper); }
.btn-sm { min-height: 40px; padding: .55rem 1rem; font-size: .88rem; }

.text-link {
  color: var(--copper); font-weight: 600;
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: background-size .35s var(--ease-out);
}
.text-link:hover { background-size: 100% 1px; }

/* Legibility halo for text floating over the 3D */
.halo { position: relative; text-shadow: 0 2px 24px rgba(0, 0, 0, .85), 0 1px 4px rgba(0, 0, 0, .9); }
.halo::before {
  content: ""; position: absolute; inset: -60px -70px; z-index: -1; pointer-events: none;
  background: radial-gradient(closest-side, rgba(7, 8, 10, .82) 0%, rgba(7, 8, 10, .5) 55%, rgba(7, 8, 10, 0) 100%);
}

.panel {
  background: var(--panel);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border: 1px solid var(--line);
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .panel { background: var(--panel-2); }
}

/* Photo insert: b/w with a copper tint, colour on hover */
.photo { position: relative; overflow: hidden; background: #111; border: 1px solid var(--line); }
.photo img {
  width: 100%; height: 100%; object-fit: cover;
  filter: grayscale(1) contrast(1.12) brightness(.82);
  transition: filter .6s var(--ease-out), transform .9s var(--ease-out);
}
.photo::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(160deg, rgba(232, 149, 90, .28), rgba(7, 8, 10, .1) 60%);
  mix-blend-mode: color; transition: opacity .6s var(--ease-out);
}
.photo:hover img { filter: grayscale(.15) contrast(1.05) brightness(.95); transform: scale(1.03); }
.photo:hover::after { opacity: 0; }
.photo figcaption {
  position: absolute; left: 0; bottom: 0; z-index: 1;
  font-family: var(--mono); font-size: .64rem; letter-spacing: .1em; text-transform: uppercase;
  padding: .45rem .7rem; background: rgba(7, 8, 10, .82); color: var(--text-muted);
}

/* Spec list (mono key/value rows) */
.spec { border-top: 1px solid var(--line); }
.spec div {
  display: flex; justify-content: space-between; gap: 1rem;
  padding: .7rem 0; border-bottom: 1px solid var(--line);
  font-family: var(--mono); font-size: .8rem;
}
.spec dt { color: var(--text-dim); letter-spacing: .06em; text-transform: uppercase; }
.spec dd { color: var(--text); text-align: right; }

.section { padding-block: clamp(80px, 12vw, 160px); }
.section-head { display: grid; gap: 1.1rem; margin-bottom: clamp(36px, 5vw, 64px); max-width: 780px; }
.section-head h2 { font-family: var(--serif); font-size: clamp(2.3rem, 5.2vw, 4.2rem); }
.section-head h2 em { font-style: italic; color: var(--copper); }

/* =============================================================
   8. Home sections
   ============================================================= */
/* 8.1 Hero */
.hero {
  min-height: 100vh; min-height: 100svh;
  display: flex; align-items: flex-end;
  padding-top: calc(var(--strip-h) + var(--nav-h) + 40px);
  padding-bottom: clamp(48px, 8vh, 96px);
}
.hero-inner { display: grid; gap: 1.6rem; max-width: 720px; }
.hero h1 {
  font-family: var(--serif);
  font-size: clamp(3rem, 8.6vw, 7.4rem);
  line-height: .96; letter-spacing: -.025em;
}
.hero h1 em { font-style: italic; color: var(--copper); display: inline-block; }
.hero-cta { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: .4rem; }
.hero-meta {
  display: flex; flex-wrap: wrap; gap: .5rem 1.4rem; margin-top: .8rem;
  font-family: var(--mono); font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--text-dim);
}
.hero-meta li { display: flex; align-items: center; gap: .5rem; }
.hero-meta li::before { content: ""; width: 5px; height: 5px; background: var(--copper); }

/* 8.2 Inputs (drawing / sketch / sample) */
.inputs { display: grid; gap: clamp(28px, 4vw, 56px); align-items: start; }
.inputs-copy { display: grid; gap: 1.2rem; }
.inputs-copy h2 { font-family: var(--serif); font-size: clamp(2.3rem, 5vw, 4rem); }
.inputs-copy h2 em { font-style: italic; color: var(--copper); }
.input-list { display: grid; gap: 1px; background: var(--line); border: 1px solid var(--line); }
.input-list li { background: var(--panel-2); padding: 1.3rem 1.4rem; display: grid; grid-template-columns: auto 1fr; gap: .3rem 1.1rem; }
.input-list .num { font-family: var(--mono); font-size: .75rem; color: var(--copper); grid-row: span 2; padding-top: .3rem; }
.input-list h3 { font-family: var(--serif); font-size: 1.55rem; }
.input-list p { color: var(--text-muted); font-size: .95rem; }
.inputs .photo { aspect-ratio: 4 / 3; }

/* 8.3 Capability archive (numbered list) */
.archive { border-top: 1px solid var(--line-2); }
.archive a {
  display: grid; grid-template-columns: 3.2rem 1fr auto; align-items: baseline; gap: 1rem;
  padding: 1.35rem .2rem; border-bottom: 1px solid var(--line-2);
  transition: background-color .35s var(--ease-out), padding .35s var(--ease-out);
}
.archive .idx { font-family: var(--mono); font-size: .75rem; color: var(--text-dim); }
.archive h3 { font-family: var(--serif); font-size: clamp(1.6rem, 3.4vw, 2.6rem); transition: color .3s var(--ease-out); }
.archive p { grid-column: 2; color: var(--text-muted); font-size: .95rem; max-width: 60ch; }
.archive .arrow { grid-row: 1; grid-column: 3; font-family: var(--mono); color: var(--copper); opacity: .5; transition: transform .35s var(--ease-out), opacity .35s; }
.archive a:hover { background: rgba(232, 149, 90, .06); padding-inline: 1rem; }
.archive a:hover h3 { color: var(--copper); }
.archive a:hover .arrow { opacity: 1; transform: translateX(4px); }
.archive-wrap { background: rgba(7, 8, 10, .72); padding: clamp(20px, 3vw, 40px); border: 1px solid var(--line); }

/* 8.4 Process */
.process { display: grid; gap: 1px; background: var(--line); border: 1px solid var(--line); counter-reset: step; }
.process li { background: var(--panel-2); padding: 1.6rem 1.4rem 1.8rem; display: grid; gap: .6rem; align-content: start; }
.process .step { font-family: var(--mono); font-size: .72rem; letter-spacing: .12em; color: var(--copper); text-transform: uppercase; }
.process h3 { font-family: var(--serif); font-size: 1.7rem; }
.process p { color: var(--text-muted); font-size: .95rem; }

/* 8.5 Spec numbers */
.numbers { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.numbers div { background: rgba(7, 8, 10, .82); padding: 1.6rem 1.2rem; display: grid; gap: .4rem; }
.numbers strong { font-family: var(--serif); font-weight: 500; font-size: clamp(2.6rem, 6vw, 4.6rem); line-height: 1; letter-spacing: -.02em; }
.numbers strong small { font-family: var(--mono); font-size: .9rem; color: var(--copper); margin-left: .25rem; letter-spacing: 0; }
.numbers div > span { font-family: var(--mono); font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--text-dim); }

/* 8.6 Industry cards */
.cards { display: grid; gap: 1rem; }
.card { display: grid; grid-template-rows: auto 1fr; background: var(--panel-2); border: 1px solid var(--line); transition: border-color .35s var(--ease-out), transform .45s var(--ease-out); }
.card:hover { border-color: rgba(232, 149, 90, .55); transform: translateY(-3px); }
.card .photo { aspect-ratio: 16 / 10; border: 0; border-bottom: 1px solid var(--line); }
.card-body { padding: 1.4rem; display: grid; gap: .6rem; align-content: start; }
.card-body .tag { font-family: var(--mono); font-size: .7rem; letter-spacing: .12em; text-transform: uppercase; color: var(--copper); }
.card-body h3 { font-family: var(--serif); font-size: 1.8rem; }
.card-body p { color: var(--text-muted); font-size: .95rem; }

/* 8.7 FAQ */
.faq { border-top: 1px solid var(--line-2); max-width: 900px; }
.faq details { border-bottom: 1px solid var(--line-2); background: rgba(7, 8, 10, .74); }
.faq summary {
  list-style: none; cursor: pointer; padding: 1.3rem 1.2rem;
  display: flex; justify-content: space-between; gap: 1rem; align-items: baseline;
  font-family: var(--serif); font-size: clamp(1.3rem, 2.2vw, 1.65rem); line-height: 1.2;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-family: var(--mono); color: var(--copper); font-size: 1.1rem; transition: transform .3s var(--ease-out); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 1.2rem 1.4rem; color: var(--text-muted); max-width: 68ch; }

/* 8.8 Final CTA */
.final { text-align: left; }
.final-box { padding: clamp(28px, 5vw, 64px); display: grid; gap: 1.4rem; }
.final h2 { font-family: var(--serif); font-size: clamp(2.4rem, 6vw, 5rem); max-width: 16ch; }
.final h2 em { font-style: italic; color: var(--copper); }
.final-contacts { display: flex; flex-wrap: wrap; gap: .6rem 2rem; font-family: var(--mono); font-size: .85rem; color: var(--text-muted); }
.final-contacts a:hover { color: var(--copper); }

/* =============================================================
   9. Inner pages
   ============================================================= */
.page-hero {
  min-height: 72vh; min-height: 72svh;
  display: flex; align-items: flex-end;
  padding-top: calc(var(--strip-h) + var(--nav-h) + 40px);
  padding-bottom: clamp(40px, 7vh, 80px);
}
.page-hero .hero-inner { max-width: 760px; }
.page-hero-short { min-height: 56vh; min-height: 56svh; }
.section-tight { padding-top: 0; }
.page-hero h1 { font-family: var(--serif); font-size: clamp(2.8rem, 7.6vw, 6.4rem); line-height: .98; letter-spacing: -.025em; }
.page-hero h1 em { font-style: italic; color: var(--copper); }

.jump { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .6rem; }
.jump a {
  font-family: var(--mono); font-size: .72rem; letter-spacing: .06em; text-transform: uppercase;
  padding: .5rem .75rem; border: 1px solid var(--line-2); background: rgba(7, 8, 10, .5); color: var(--text-muted);
  transition: color .25s, border-color .25s;
}
.jump a:hover { color: var(--copper); border-color: var(--copper); }

/* Capability / industry detail blocks */
.detail { display: grid; gap: clamp(24px, 4vw, 56px); padding: clamp(24px, 4vw, 48px); margin-bottom: clamp(20px, 3vw, 32px); }
.detail-head { display: grid; gap: .8rem; }
.detail-head .idx { font-family: var(--mono); font-size: .75rem; letter-spacing: .12em; color: var(--copper); text-transform: uppercase; }
.detail h2 { font-family: var(--serif); font-size: clamp(2rem, 4.4vw, 3.4rem); }
.detail h2 em { font-style: italic; color: var(--copper); }
.detail .photo { aspect-ratio: 4 / 3; }
.detail h3 { font-family: var(--mono); font-size: .74rem; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; color: var(--text-dim); margin: 1.4rem 0 .6rem; }
.ticks li { position: relative; padding: .42rem 0 .42rem 1.4rem; color: var(--text-muted); border-bottom: 1px dashed var(--line); }
.ticks li::before { content: ""; position: absolute; left: 0; top: 1.02em; width: 8px; height: 1px; background: var(--copper); }
.note {
  margin-top: 1.2rem; padding: .9rem 1rem; border-left: 2px solid var(--copper);
  background: rgba(232, 149, 90, .07); color: var(--text-muted); font-size: .92rem;
}
.note strong { color: var(--text); }

.grid-2 { display: grid; gap: 1rem; }
.materials { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.materials li { background: var(--panel-2); padding: 1.1rem 1.1rem 1.2rem; }
.materials b { display: block; font-family: var(--serif); font-weight: 500; font-size: 1.35rem; }
.materials span { font-family: var(--mono); font-size: .72rem; color: var(--text-dim); letter-spacing: .04em; }

/* 9.1 Quote form */
.quote-layout { display: grid; gap: 1.2rem; align-items: start; }
.form { padding: clamp(22px, 4vw, 44px); display: grid; gap: 1.8rem; }
.form fieldset { border: 0; padding: 0; display: grid; gap: 1rem; min-width: 0; }
.form legend {
  font-family: var(--mono); font-size: .74rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--copper); padding: 0; margin-bottom: .6rem; display: flex; gap: .6rem;
}
.form legend span { color: var(--text-dim); }
.row { display: grid; gap: 1rem; }
.field { display: grid; gap: .4rem; min-width: 0; }
.field label, .field .label { font-size: .86rem; font-weight: 600; color: var(--text); }
.field label small, .field .label small { font-weight: 400; color: var(--text-dim); }
.field input, .field select, .field textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--text);
  background: rgba(3, 4, 5, .7); border: 1px solid var(--line-2); border-radius: 2px;
  padding: .8rem .9rem; min-height: 48px;
  transition: border-color .25s var(--ease-out), background-color .25s var(--ease-out);
}
.field select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--copper) 50%), linear-gradient(135deg, var(--copper) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 2.4rem; }
.field select option { background: #121417; color: var(--text); }
.field textarea { min-height: 140px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--copper); background: rgba(3, 4, 5, .9); }
.field input:user-invalid, .field textarea:user-invalid, .field select:user-invalid { border-color: #e06a5a; }
.field .hint { font-size: .8rem; color: var(--text-dim); }

.drop {
  position: relative; display: grid; gap: .5rem; place-items: center; text-align: center;
  padding: 1.8rem 1rem; border: 1px dashed var(--line-2); background: rgba(3, 4, 5, .55);
  transition: border-color .25s, background-color .25s;
}
.drop:hover, .drop.is-over { border-color: var(--copper); background: rgba(232, 149, 90, .06); }
.drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
.drop svg { width: 28px; height: 28px; color: var(--copper); }
.drop strong { font-weight: 600; }
.drop span { font-family: var(--mono); font-size: .72rem; color: var(--text-dim); letter-spacing: .04em; }
.drop input:focus-visible + .drop-focus { position: absolute; inset: -3px; outline: 2px solid var(--copper); pointer-events: none; }
.file-list { display: grid; gap: .4rem; font-family: var(--mono); font-size: .78rem; }
.file-list li { display: flex; justify-content: space-between; gap: 1rem; padding: .55rem .7rem; background: rgba(232, 149, 90, .07); border: 1px solid var(--line); }
.file-list li span:last-child { color: var(--text-dim); flex: none; }

.check { display: grid; grid-template-columns: auto 1fr; gap: .8rem; align-items: start; font-size: .9rem; color: var(--text-muted); }
.check input { width: 20px; height: 20px; margin-top: .15rem; accent-color: var(--copper); }
.check a { color: var(--copper); text-decoration: underline; text-underline-offset: 3px; }

.form-foot { display: grid; gap: 1rem; }
.demo-note { font-family: var(--mono); font-size: .75rem; color: var(--text-dim); letter-spacing: .02em; }
.demo-note b { color: var(--copper); font-weight: 500; }
.form-result {
  padding: 1.2rem 1.3rem; border: 1px solid var(--copper); background: rgba(232, 149, 90, .1);
  display: grid; gap: .4rem;
}
.form-result strong { font-family: var(--serif); font-weight: 500; font-size: 1.6rem; color: var(--text); }
.form-result p { color: var(--text-muted); font-size: .95rem; }
.form-result button { justify-self: start; margin-top: .4rem; }

.aside { padding: clamp(22px, 3vw, 34px); display: grid; gap: 1.4rem; }
.aside h2 { font-family: var(--serif); font-size: 1.8rem; }
.aside ol { counter-reset: n; display: grid; gap: .9rem; }
.aside ol li { counter-increment: n; display: grid; grid-template-columns: 2rem 1fr; gap: .2rem; color: var(--text-muted); font-size: .94rem; }
.aside ol li::before { content: "0" counter(n); font-family: var(--mono); font-size: .74rem; color: var(--copper); padding-top: .2rem; }
.aside ol li b { color: var(--text); font-weight: 600; }

/* 9.2 Privacy / text pages */
.prose { padding: clamp(24px, 5vw, 60px); max-width: 860px; }
.prose h2 { font-family: var(--serif); font-size: clamp(1.7rem, 3vw, 2.3rem); margin: 2.4rem 0 .8rem; }
.prose h2:first-child { margin-top: 0; }
.prose p, .prose li { color: var(--text-muted); margin-bottom: .9rem; max-width: 70ch; }
.prose ul { margin: 0 0 1rem; }
.prose ul li { position: relative; padding-left: 1.3rem; margin-bottom: .5rem; }
.prose ul li::before { content: ""; position: absolute; left: 0; top: .8em; width: 8px; height: 1px; background: var(--copper); }
.prose a { color: var(--copper); text-decoration: underline; text-underline-offset: 3px; }
.prose strong { color: var(--text); }
.credits li { font-size: .9rem; }
.lang-es { border-top: 1px solid var(--line-2); margin-top: 2.6rem; padding-top: .4rem; }

/* =============================================================
   10. Footer
   ============================================================= */
.site-footer { position: relative; z-index: 3; background: rgba(5, 6, 7, .96); border-top: 1px solid var(--line); }
.footer-grid { display: grid; gap: 2rem; padding-block: clamp(48px, 7vw, 80px) 2rem; }
.footer-grid h2 { font-family: var(--mono); font-size: .72rem; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; color: var(--text-dim); margin-bottom: .9rem; }
.footer-grid li { margin-bottom: .45rem; color: var(--text-muted); font-size: .94rem; }
.footer-grid a:hover { color: var(--copper); }
.footer-brand p { color: var(--text-muted); font-size: .94rem; max-width: 36ch; margin-top: 1rem; }
.footer-base {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: .8rem 2rem;
  padding-block: 1.4rem 2rem; border-top: 1px solid var(--line);
  font-family: var(--mono); font-size: .72rem; color: var(--text-dim); letter-spacing: .03em;
}
.footer-base a { text-decoration: underline; text-underline-offset: 3px; }
.footer-base a:hover { color: var(--copper); }

/* =============================================================
   11. Effects — reveals
   ============================================================= */
.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity .9s var(--ease-out), transform .9s var(--ease-out); }
.js .reveal.is-in { opacity: 1; transform: none; }
.js .reveal[data-delay="1"] { transition-delay: .08s; }
.js .reveal[data-delay="2"] { transition-delay: .16s; }
.js .reveal[data-delay="3"] { transition-delay: .24s; }

/* Hero entrance — pure CSS, content is in the HTML regardless */
@keyframes introUp { from { opacity: 0; transform: translateY(26px); } to { opacity: 1; transform: none; } }
.js [data-intro] { animation: introUp 1.1s var(--ease-out) both; }
.js [data-intro]:nth-child(2) { animation-delay: .09s; }
.js [data-intro]:nth-child(3) { animation-delay: .18s; }
.js [data-intro]:nth-child(4) { animation-delay: .27s; }
.js [data-intro]:nth-child(5) { animation-delay: .36s; }

/* =============================================================
   12. Responsive (mobile first)
   ============================================================= */
@media (min-width: 540px) {
  .numbers { grid-template-columns: repeat(2, 1fr); }
  .row-2 { grid-template-columns: 1fr 1fr; }
  .materials { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 720px) {
  .process { grid-template-columns: repeat(2, 1fr); }
  .cards { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; }
  .grid-2 { grid-template-columns: 1fr 1fr; }
  .row-3 { grid-template-columns: 1fr 1fr 1fr; }
}
@media (min-width: 960px) {
  .nav-links { display: flex; }
  .nav-toggle, .mobile-menu, .nav-open .mobile-menu { display: none; }
  [data-scene="home"] .hud { display: flex; }
  .inputs { grid-template-columns: 1.05fr 1fr; }
  .inputs .photo { margin-top: 5rem; }
  .process { grid-template-columns: repeat(4, 1fr); }
  .numbers { grid-template-columns: repeat(4, 1fr); }
  .detail { grid-template-columns: 1.1fr 1fr; }
  .detail.flip > :first-child { order: 2; }
  .quote-layout { grid-template-columns: 1.6fr 1fr; }
  .aside { position: sticky; top: calc(var(--strip-h) + var(--nav-h) + 20px); }
  .materials { grid-template-columns: repeat(4, 1fr); }
  .hero-inner.push-left { margin-right: auto; }
}
@media (max-width: 539px) {
  :root { --strip-h: 28px; --nav-h: 60px; }
  .demo-strip { font-family: var(--sans); font-size: .7rem; font-weight: 600; letter-spacing: 0; }
  .brand-name { font-size: 1.25rem; }
  .archive a { grid-template-columns: 2.2rem 1fr auto; gap: .6rem; }
}

/* =============================================================
   13. Reduced motion — only intrusive things
   ============================================================= */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .grain { display: none; }
}
