/* ============================================================
   BITWOOD FRAMING — Design System
   A Division of Bitwood Build · Atlanta, GA
   Language: "Black & Tan" structural luxury
   Type: Clash Display (display) / Satoshi (body) / IBM Plex Mono (specs)
   Radius rule: cards 20px · media 14px · buttons full-pill · inputs 10px
   Z-scale: 10 nav · 40 menu overlay · 60 grain
   ============================================================ */

:root {
  --bg:        #0D0C0A;
  --bg-raise:  #14120F;
  --surface:   #191612;
  --surface-2: #1F1B16;
  --line:      rgba(233, 221, 202, 0.09);
  --line-hi:   rgba(233, 221, 202, 0.18);
  --text:      #FFFFFF;
  --muted:     #FFFFFF;
  --faint:     #FFFFFF;
  --placeholder: rgba(255, 255, 255, 0.45);
  --accent:    #56B365;              /* Bitwood Build brand green — the ONLY accent */
  --accent-ink:#171105;
  --accent-dim:rgba(86, 179, 101, 0.14);

  --font-display: "Clash Display", "Satoshi", sans-serif;
  --font-body:    "Satoshi", -apple-system, sans-serif;
  --font-mono:    "IBM Plex Mono", ui-monospace, monospace;

  --ease-out:  cubic-bezier(0.16, 1, 0.3, 1);
  --ease-soft: cubic-bezier(0.32, 0.72, 0, 1);

  --r-card: 20px;
  --r-media: 14px;
  --r-input: 10px;

  --pad-section: clamp(6rem, 12vw, 11rem);
  --gutter: clamp(1.25rem, 4vw, 3.5rem);
  --max-w: 1400px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

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

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.1875rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

main { overflow-x: hidden; width: 100%; max-width: 100%; }

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

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

a { color: inherit; text-decoration: none; }

/* Film grain — fixed, pointer-events-none, never on scrolling containers */
.grain {
  position: fixed; inset: 0; z-index: 60; pointer-events: none;
  opacity: 0.05; 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='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ------------------------------------------------------------
   Typography
   ------------------------------------------------------------ */
.display {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.02;
  text-wrap: balance;
}

h1.display { font-size: clamp(2.9rem, 6.4vw, 6rem); }
h2.display { font-size: clamp(2.5rem, 5vw, 4.5rem); }
h3.display { font-size: clamp(1.5rem, 2.2vw, 2rem); font-weight: 500; }

.display em {
  font-style: italic;
  font-weight: 500;
  color: var(--accent);
  line-height: 1.1;
  padding-bottom: 0.08em; /* italic descender clearance */
  display: inline-block;
}
.hero-copy h1.display em { color: var(--text); }

.eyebrow {
  display: inline-flex; align-items: center; gap: 0.6rem;
  font-family: var(--font-mono);
  font-size: 0.88rem; font-weight: 500;
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--accent);
  border: 1px solid rgba(86, 179, 101, 0.45);
  border-radius: 999px;
  padding: 0.55rem 1.15rem;
  background: rgba(86, 179, 101, 0.08);
}
.eyebrow::before {
  content: ""; width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent);
}

.lede { font-size: clamp(1.2rem, 1.6vw, 1.45rem); color: var(--muted); max-width: 58ch; }
.body-muted { color: var(--muted); max-width: 62ch; }

.mono {
  font-family: var(--font-mono);
  font-size: 0.9rem; letter-spacing: 0.06em;
  color: var(--faint);
}

/* ------------------------------------------------------------
   Layout primitives
   ------------------------------------------------------------ */
.wrap { max-width: var(--max-w); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--pad-section); position: relative; }
.section-head { display: grid; gap: 1.4rem; max-width: 760px; margin-bottom: clamp(3rem, 6vw, 5.5rem); }

hr.rule { border: 0; border-top: 1px solid var(--line); }

/* ------------------------------------------------------------
   Buttons — pill, button-in-button trailing icon, one intent per label
   ------------------------------------------------------------ */
.btn {
  display: inline-flex; align-items: center; gap: 0.85rem;
  border-radius: 999px;
  padding: 0.55rem 0.55rem 0.55rem 1.6rem;
  font-family: var(--font-body); font-weight: 700; font-size: 0.98rem;
  letter-spacing: 0.01em; white-space: nowrap;
  cursor: pointer; border: 0;
  transition: transform 0.5s var(--ease-soft), background-color 0.5s var(--ease-soft),
              border-color 0.5s var(--ease-soft), color 0.5s var(--ease-soft);
}
.btn:active { transform: scale(0.98); }

.btn .btn-orb {
  width: 2.35rem; height: 2.35rem; border-radius: 50%;
  display: grid; place-items: center; flex: none;
  transition: transform 0.5s var(--ease-soft);
}
.btn:hover .btn-orb { transform: translate(3px, -1px) scale(1.06); }
.btn .btn-orb svg { width: 0.9rem; height: 0.9rem; }

.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary .btn-orb { background: rgba(23, 17, 5, 0.14); color: var(--accent-ink); }
.btn-primary:hover { background: #E2AE6C; }

.btn-ghost {
  background: rgba(233, 221, 202, 0.04);
  color: var(--text);
  border: 1px solid var(--line-hi);
}
.btn-ghost .btn-orb { background: rgba(233, 221, 202, 0.07); color: var(--text); }
.btn-ghost:hover { background: rgba(233, 221, 202, 0.08); border-color: rgba(233,221,202,0.3); }

/* ------------------------------------------------------------
   Floating pill navigation
   ------------------------------------------------------------ */
.nav-shell {
  position: fixed; top: 1.4rem; left: 0; right: 0; z-index: 10;
  display: flex; justify-content: center;
  padding-inline: 1rem;
  pointer-events: none;
}
.nav {
  pointer-events: auto;
  display: flex; align-items: center; gap: clamp(1rem, 3vw, 2.4rem);
  padding: 0.55rem 0.6rem 0.55rem 1.4rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(13, 12, 10, 0.62);
  backdrop-filter: blur(20px) saturate(150%);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
  box-shadow: inset 0 1px 0 rgba(233,221,202,0.06), 0 18px 50px rgba(0,0,0,0.45);
  transition: transform 0.6s var(--ease-soft);
}
.nav-brand { display: grid; line-height: 1.05; }
.nav-brand .nb-name {
  font-family: var(--font-display); font-weight: 600;
  font-size: 0.98rem; letter-spacing: 0.02em;
}
.nav-brand .nb-div {
  font-family: var(--font-mono); font-size: 0.55rem;
  letter-spacing: 0.2em; text-transform: uppercase; color: var(--faint);
}
.nav-links { display: flex; align-items: center; gap: 1.7rem; }
.nav-links a {
  font-size: 0.9rem; font-weight: 500; color: var(--muted);
  transition: color 0.4s var(--ease-soft);
}
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--text); }
.nav .btn { padding: 0.35rem 0.35rem 0.35rem 1.15rem; font-size: 0.88rem; }
.nav .btn .btn-orb { width: 1.9rem; height: 1.9rem; }

.nav-burger {
  display: none; position: relative; width: 2.6rem; height: 2.6rem;
  border-radius: 50%; border: 1px solid var(--line-hi);
  background: rgba(233,221,202,0.05); cursor: pointer;
}
.nav-burger span {
  position: absolute; left: 50%; top: 50%; width: 1.05rem; height: 1.5px;
  background: var(--text); border-radius: 2px;
  transition: transform 0.5s var(--ease-soft);
}
.nav-burger span:nth-child(1) { transform: translate(-50%, calc(-50% - 3.5px)); }
.nav-burger span:nth-child(2) { transform: translate(-50%, calc(-50% + 3.5px)); }
.nav-burger[aria-expanded="true"] span:nth-child(1) { transform: translate(-50%, -50%) rotate(45deg); }
.nav-burger[aria-expanded="true"] span:nth-child(2) { transform: translate(-50%, -50%) rotate(-45deg); }

/* Full-screen mobile menu */
.menu-overlay {
  position: fixed; inset: 0; z-index: 40;
  background: rgba(13, 12, 10, 0.88);
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
  display: grid; place-content: center; gap: 0.4rem;
  opacity: 0; visibility: hidden;
  transition: opacity 0.55s var(--ease-soft), visibility 0.55s;
}
.menu-overlay.open { opacity: 1; visibility: visible; }
.menu-overlay a {
  font-family: var(--font-display); font-weight: 600;
  font-size: clamp(2.2rem, 9vw, 3.4rem);
  padding: 0.35rem 0; text-align: center;
  transform: translateY(2.6rem); opacity: 0;
  transition: transform 0.7s var(--ease-out), opacity 0.7s var(--ease-out);
}
.menu-overlay.open a { transform: translateY(0); opacity: 1; }
.menu-overlay.open a:nth-child(1) { transition-delay: 0.08s; }
.menu-overlay.open a:nth-child(2) { transition-delay: 0.15s; }
.menu-overlay.open a:nth-child(3) { transition-delay: 0.22s; }
.menu-overlay.open a:nth-child(4) { transition-delay: 0.29s; }
.menu-overlay a:hover { color: var(--accent); }

/* ------------------------------------------------------------
   Hero — asymmetric, live 3D frame behind
   ------------------------------------------------------------ */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex; align-items: flex-end;
  padding-bottom: clamp(3.5rem, 7vw, 6rem);
  padding-top: 9rem;
}
#hero-canvas {
  position: absolute; inset: 0; z-index: 0;
  min-height: 420px;
  -webkit-transform: translateZ(0);
  transform: translateZ(0);
}
#hero-canvas canvas { width: 100%; height: 100%; }
.hero-wash {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background:
    radial-gradient(120% 90% at 18% 88%, rgba(13,12,10,0.94) 0%, rgba(13,12,10,0.55) 42%, rgba(13,12,10,0) 72%),
    linear-gradient(180deg, rgba(13,12,10,0.55) 0%, rgba(13,12,10,0) 24%, rgba(13,12,10,0) 62%, rgba(13,12,10,0.9) 100%);
}
.hero-inner { position: relative; z-index: 2; width: 100%; }
.hero-copy { max-width: 60rem; display: grid; gap: 1.9rem; justify-items: start; }
.hero-copy .lede { max-width: 44ch; }
.hero-ctas { display: flex; gap: 0.9rem; flex-wrap: wrap; }

.hero-coord {
  position: absolute; right: var(--gutter); bottom: clamp(3.5rem, 7vw, 6rem);
  z-index: 2; text-align: right; display: grid; gap: 0.3rem;
}
.hero-coord .mono { color: var(--text); }

/* ------------------------------------------------------------
   Spec marquee ticker
   ------------------------------------------------------------ */
.ticker {
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  overflow: hidden; padding-block: 1.05rem;
  background: var(--bg-raise);
}
.ticker-track {
  display: flex; gap: 3.2rem; width: max-content;
  animation: ticker 42s linear infinite;
}
.ticker span {
  font-family: var(--font-mono); font-size: 0.86rem;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--faint); white-space: nowrap;
  display: inline-flex; align-items: center; gap: 3.2rem;
}
.ticker span::after { content: "▪"; color: var(--accent); font-size: 0.5rem; }
@keyframes ticker { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ticker-track { animation: none; } }

/* ------------------------------------------------------------
   Services — asymmetric gapless bento
   ------------------------------------------------------------ */
.svc-grid {
  display: grid; gap: 1rem;
  grid-template-columns: repeat(12, 1fr);
  grid-auto-rows: 1fr;
  grid-auto-flow: dense;
}
.svc { grid-column: span 4; }

/* Double-bezel card architecture: outer shell + inner core */
.shell {
  background: rgba(233, 221, 202, 0.035);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  padding: 6px;
  transition: transform 0.7s var(--ease-soft), border-color 0.7s var(--ease-soft);
}
.shell:hover { border-color: var(--line-hi); transform: translateY(-4px); }
.core {
  height: 100%;
  background: linear-gradient(160deg, var(--surface-2) 0%, var(--surface) 60%);
  border-radius: calc(var(--r-card) - 6px);
  box-shadow: inset 0 1px 0 rgba(233,221,202,0.05);
  padding: clamp(1.4rem, 2.4vw, 2rem);
  display: flex; flex-direction: column; justify-content: space-between; gap: 2.2rem;
  position: relative; overflow: hidden;
}
.core .svc-spec {
  font-family: var(--font-mono); font-size: 0.78rem;
  letter-spacing: 0.18em; text-transform: uppercase; color: var(--faint);
}
.core h3 { margin-top: 0.75rem; }
.core p { color: var(--muted); font-size: 1.08rem; margin-top: 0.6rem; max-width: 46ch; }
.svc-foot { display: flex; align-items: center; justify-content: space-between; }
.svc-foot .mono { color: var(--faint); }
.svc-orb {
  width: 2.4rem; height: 2.4rem; border-radius: 50%;
  border: 1px solid var(--line-hi);
  display: grid; place-items: center; color: var(--muted);
  transition: transform 0.55s var(--ease-soft), background-color 0.55s var(--ease-soft),
              color 0.55s var(--ease-soft), border-color 0.55s var(--ease-soft);
}
.svc-orb svg { width: 0.85rem; height: 0.85rem; }
.shell:hover .svc-orb {
  background: var(--accent); color: var(--accent-ink);
  border-color: var(--accent); transform: translate(2px, -2px);
}
/* faint structural linework inside feature cards */
.core .joists {
  position: absolute; inset: 0; pointer-events: none; opacity: 0.5;
}

/* ------------------------------------------------------------
   Manifesto — scrubbing word reveal
   ------------------------------------------------------------ */
.manifesto p {
  font-family: var(--font-display); font-weight: 500;
  font-size: clamp(1.7rem, 3.4vw, 3rem);
  line-height: 1.28; letter-spacing: -0.015em;
  max-width: 22em;
}
.manifesto .w { opacity: 0.13; transition: opacity 0.2s linear; }

/* ------------------------------------------------------------
   Process — pinned split
   ------------------------------------------------------------ */
.process-grid {
  display: grid; grid-template-columns: 5fr 7fr; gap: clamp(2rem, 6vw, 6rem);
  align-items: start;
}
.process-sticky { position: sticky; top: 8.5rem; display: grid; gap: 1.4rem; }
.steps { display: grid; gap: 1rem; }
.step {
  border-top: 1px solid var(--line);
  padding: clamp(1.6rem, 2.6vw, 2.4rem) 0.25rem;
  display: grid; grid-template-columns: auto 1fr; gap: clamp(1.2rem, 3vw, 2.6rem);
  align-items: start;
}
.step-num {
  font-family: var(--font-mono); font-size: 0.92rem; color: var(--accent);
  letter-spacing: 0.1em; padding-top: 0.45rem;
}
.step h3 { margin-bottom: 0.55rem; }
.step p { color: var(--muted); max-width: 52ch; font-size: 1.1rem; }
.step .mono { display: block; margin-top: 0.9rem; }

/* ------------------------------------------------------------
   Numbers strip
   ------------------------------------------------------------ */
.stats {
  display: grid; grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line);
}
.stat {
  padding: clamp(1.8rem, 3vw, 2.8rem) clamp(0.4rem, 1.6vw, 1.6rem);
  border-left: 1px solid var(--line);
}
.stat:first-child { border-left: 0; }
.stat b {
  display: block;
  font-family: var(--font-mono); font-weight: 500;
  font-size: clamp(1.7rem, 3.2vw, 2.7rem);
  letter-spacing: -0.02em; color: var(--text);
}
.stat b i { font-style: normal; color: var(--accent); }
.stat span { font-size: 0.98rem; color: var(--faint); display: block; margin-top: 0.5rem; }

/* ------------------------------------------------------------
   Education teaser split
   ------------------------------------------------------------ */
.edu-split {
  display: grid; grid-template-columns: 1.1fr 1fr;
  gap: clamp(2.4rem, 6vw, 6rem); align-items: center;
}
.edu-figure .core { padding: clamp(1.2rem, 2vw, 1.8rem); }
.edu-figure svg { width: 100%; height: auto; }

/* ------------------------------------------------------------
   Big CTA + footer
   ------------------------------------------------------------ */
.cta-final { text-align: left; }
.cta-final h2 { font-size: clamp(2.6rem, 6vw, 5.4rem); max-width: 12em; }
.cta-final .lede { margin-top: 1.4rem; }
.cta-final .btn { margin-top: 2.6rem; }

footer {
  border-top: 1px solid var(--line);
  padding: clamp(2.5rem, 5vw, 4rem) 0 2.2rem;
  background: var(--bg-raise);
}
.foot-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1.2fr;
  gap: clamp(1.6rem, 4vw, 3rem);
}
.foot-brand { display: grid; gap: 0.7rem; align-content: start; }
.foot-brand .nb-name { font-family: var(--font-display); font-weight: 600; font-size: 1.3rem; }
.foot-col h4 {
  font-family: var(--font-mono); font-size: 0.74rem; font-weight: 500;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--faint);
  margin-bottom: 1.1rem;
}
.foot-col a, .foot-col span { display: block; color: var(--muted); font-size: 1.05rem; padding: 0.28rem 0; }
.foot-col a:hover { color: var(--text); }
.foot-legal {
  margin-top: clamp(2.5rem, 5vw, 4rem);
  padding-top: 1.6rem; border-top: 1px solid var(--line);
  display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
}

/* ------------------------------------------------------------
   Scroll reveal (IntersectionObserver adds .in)
   ------------------------------------------------------------ */
.reveal {
  opacity: 0; transform: translateY(3.4rem);
  filter: blur(6px);
  transition: opacity 1s var(--ease-out), transform 1s var(--ease-out), filter 1s var(--ease-out);
}
.reveal.in { opacity: 1; transform: none; filter: none; }
.reveal.d1 { transition-delay: 0.1s; }
.reveal.d2 { transition-delay: 0.2s; }
.reveal.d3 { transition-delay: 0.3s; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; filter: none; transition: none; }
}

/* ------------------------------------------------------------
   Page hero (interior pages)
   ------------------------------------------------------------ */
.page-hero { padding-top: clamp(10rem, 18vw, 14rem); padding-bottom: clamp(3rem, 6vw, 5rem); }
.page-hero .display { max-width: 14em; }
.page-hero .lede { margin-top: 1.6rem; }

/* ------------------------------------------------------------
   FRAMING 101 — interactive anatomy + glossary
   ------------------------------------------------------------ */
.anatomy-grid {
  display: grid; grid-template-columns: 1.35fr 1fr;
  gap: clamp(2rem, 4vw, 4rem); align-items: start;
}
.anatomy-stage .core { padding: clamp(1rem, 2vw, 1.8rem); }
.anatomy-stage svg { width: 100%; height: auto; }

.anatomy-panel { position: sticky; top: 8.5rem; }
.anatomy-panel .core { min-height: 340px; justify-content: flex-start; gap: 1rem; }
.anatomy-panel h3 { color: var(--accent); }
.anatomy-panel .ap-hint { color: var(--faint); font-size: 0.97rem; }

.part { cursor: pointer; }
.part rect, .part path { transition: fill 0.35s var(--ease-soft), stroke 0.35s var(--ease-soft); }
.part:hover rect, .part.active rect,
.part:hover path, .part.active path { fill: rgba(86,179,101,0.55); stroke: var(--accent); }

.gloss-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem;
}
.gloss .core { gap: 0.9rem; justify-content: flex-start; min-height: 190px; }
.gloss .core h3 { margin-top: 0; font-size: 1.35rem; }
.gloss .core p { font-size: 1.05rem; }
.gloss .core .mono { color: var(--accent); font-size: 0.76rem; letter-spacing: 0.18em; text-transform: uppercase; }

.loadpath { display: grid; grid-template-columns: 1fr 1.2fr; gap: clamp(2rem, 5vw, 5rem); align-items: center; }
.loadpath ol { list-style: none; counter-reset: lp; display: grid; gap: 0; }
.loadpath li {
  counter-increment: lp;
  border-top: 1px solid var(--line);
  padding: 1.3rem 0.2rem;
  display: grid; grid-template-columns: auto 1fr; gap: 1.4rem; align-items: baseline;
}
.loadpath li::before {
  content: counter(lp, decimal-leading-zero);
  font-family: var(--font-mono); font-size: 0.9rem; color: var(--accent);
}
.loadpath li b { display: block; font-weight: 700; }
.loadpath li span { color: var(--muted); font-size: 1.06rem; }

/* ------------------------------------------------------------
   Contact / Estimate form
   ------------------------------------------------------------ */
.contact-grid {
  display: grid; grid-template-columns: 1fr 1.35fr;
  gap: clamp(2rem, 5vw, 5rem); align-items: start;
}
.contact-aside { position: sticky; top: 8.5rem; display: grid; gap: 2rem; }
.contact-aside .mono { color: var(--muted); }
.contact-line { display: grid; gap: 0.25rem; padding: 1.1rem 0; border-top: 1px solid var(--line); }
.contact-line a { font-family: var(--font-display); font-weight: 500; font-size: 1.25rem; }
.contact-line a:hover { color: var(--accent); }

.form-shell .core { gap: 0; justify-content: flex-start; padding: clamp(1.6rem, 3vw, 2.6rem); }

.field { display: grid; gap: 0.5rem; margin-bottom: 1.5rem; }
.field label { font-size: 0.98rem; font-weight: 700; letter-spacing: 0.01em; }
.field .hint { font-size: 0.9rem; color: var(--faint); }
.field input, .field select, .field textarea {
  width: 100%;
  background: rgba(13, 12, 10, 0.55);
  border: 1px solid var(--line-hi);
  border-radius: var(--r-input);
  color: var(--text);
  font-family: var(--font-body); font-size: 1.1rem;
  padding: 0.85rem 1rem;
  transition: border-color 0.4s var(--ease-soft), box-shadow 0.4s var(--ease-soft);
}
.field textarea { min-height: 140px; resize: vertical; }
.field select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--text) 50%), linear-gradient(135deg, var(--text) 50%, transparent 50%); background-position: calc(100% - 20px) 1.25rem, calc(100% - 14px) 1.25rem; background-size: 6px 6px; background-repeat: no-repeat; }
.field input::placeholder, .field textarea::placeholder { color: var(--placeholder); }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
}
.field .err { display: none; font-size: 0.92rem; color: #E08B7B; }
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: #C96A57; }
.field.invalid .err { display: block; }

.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.1rem; }

/* Drag & drop uploader */
.dropzone {
  border: 1.5px dashed var(--line-hi);
  border-radius: var(--r-media);
  padding: 2.2rem 1.4rem;
  display: grid; justify-items: center; gap: 0.55rem;
  text-align: center; cursor: pointer;
  background: rgba(13, 12, 10, 0.35);
  transition: border-color 0.4s var(--ease-soft), background-color 0.4s var(--ease-soft);
}
.dropzone:hover, .dropzone.drag { border-color: var(--accent); background: var(--accent-dim); }
.dropzone b { font-weight: 700; }
.dropzone .mono { color: var(--faint); }
.dz-icon { color: var(--accent); }
.dz-icon svg { width: 1.6rem; height: 1.6rem; }

.filelist { display: grid; gap: 0.6rem; margin-top: 1rem; }
.filecard {
  display: flex; align-items: center; gap: 0.9rem;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: var(--r-input);
  padding: 0.6rem 0.75rem;
}
.filecard .thumb {
  width: 44px; height: 44px; border-radius: 8px; flex: none;
  object-fit: cover; background: var(--surface-2);
  display: grid; place-items: center; color: var(--faint);
  font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.1em;
}
.filecard .fmeta { flex: 1; min-width: 0; }
.filecard .fname { font-size: 0.88rem; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.filecard .fsize { font-family: var(--font-mono); font-size: 0.68rem; color: var(--faint); }
.filecard .fremove {
  flex: none; width: 1.8rem; height: 1.8rem; border-radius: 50%;
  border: 1px solid var(--line-hi); background: none; color: var(--muted);
  cursor: pointer; display: grid; place-items: center; font-size: 0.85rem;
  transition: color 0.3s, border-color 0.3s;
}
.filecard .fremove:hover { color: #E08B7B; border-color: #C96A57; }

.form-status {
  display: none; margin-top: 1.4rem; padding: 1rem 1.2rem;
  border-radius: var(--r-input); font-size: 0.92rem;
}
.form-status.ok { display: block; background: rgba(120, 170, 110, 0.12); border: 1px solid rgba(120,170,110,0.35); color: #BCd8B2; }
.form-status.bad { display: block; background: rgba(201, 106, 87, 0.12); border: 1px solid rgba(201,106,87,0.4); color: #E8B4A8; }

.hp { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }

/* ------------------------------------------------------------
   Responsive collapse — everything single-column below 900
   ------------------------------------------------------------ */
@media (max-width: 1080px) {
  .svc { grid-column: span 6; }
}
@media (max-width: 900px) {
  .nav-links { display: none; }
  .nav-burger { display: block; }
  .nav .btn { display: none; }

  .svc { grid-column: span 12; }

  .process-grid, .edu-split, .anatomy-grid, .contact-grid, .loadpath { grid-template-columns: 1fr; }
  .process-sticky, .anatomy-panel, .contact-aside { position: static; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(3) { border-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
  .gloss-grid { grid-template-columns: 1fr 1fr; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .hero-coord { display: none; }
  .field-row { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .gloss-grid { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr; }
  .hero { padding-top: 7.5rem; }
}

/* ============ v2: service icons ============ */
.svc-icon {
  width: 96px; height: 96px;
  border-radius: 14px;                 /* media radius */
  object-fit: cover;
  border: 1px solid var(--line);
  background: var(--bg);
  margin-bottom: 1.1rem;
  display: block;
}

/* ============ v2: services CTA row ============ */
.svc-cta {
  margin-top: clamp(2.4rem, 4vw, 3.4rem);
  display: flex; align-items: center; justify-content: space-between;
  gap: 1.6rem; flex-wrap: wrap;
  padding: clamp(1.4rem, 2.5vw, 2rem) clamp(1.6rem, 3vw, 2.4rem);
  border: 1px solid var(--line);
  border-radius: 20px;                 /* card radius */
  background: var(--bg-raise);
}
.svc-cta p { margin: 0; color: var(--muted); max-width: 52ch; }
.svc-cta b { color: var(--text); font-weight: 600; }

/* ============ v2: past projects gallery ============ */
.proj-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(272px, 1fr));
  gap: clamp(1rem, 2vw, 1.6rem);
  margin-top: clamp(2.4rem, 4vw, 3.4rem);
}
.proj { display: block; }
.proj .core { padding: 0; overflow: hidden; position: relative; }
.proj img {
  display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover;
  border-radius: 14px;                 /* media radius */
  transform: scale(1.001);
  transition: transform 0.9s var(--ease-soft);
}
.proj:hover img { transform: scale(1.045); }
.proj-meta {
  position: absolute; left: 0; right: 0; bottom: 0;
  display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem;
  padding: 1.1rem 1.25rem;
  background: linear-gradient(to top, rgba(13,12,10,0.88), rgba(13,12,10,0));
  border-radius: 0 0 14px 14px;
}
.proj-meta { flex-direction: column; align-items: flex-start; gap: 0.3rem; }
.proj-meta h3 { margin: 0; font-size: clamp(1.1rem, 1.5vw, 1.25rem); }
.proj-meta .mono { font-size: 0.78rem; color: var(--accent); letter-spacing: 0.16em; white-space: nowrap; }
@media (max-width: 720px) {
  .proj-grid { grid-template-columns: 1fr; }
}

/* ============ v2: one-page anchor scrolling ============ */
html { scroll-behavior: smooth; }
section[id], header[id] { scroll-margin-top: 96px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }


/* ============ v5: spam check field ============ */
.captcha-field label b {
  color: var(--accent);
  font-weight: 600;
  letter-spacing: 0.01em;
}
.captcha-field input { max-width: 220px; }
