/* Rosedale — bold architectural aesthetic matching the ROSEDALE brand mark */

@import url('https://fonts.googleapis.com/css2?family=Archivo:wght@400;500;600;700;800;900&family=Archivo+Narrow:wght@500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  /* Architectural neutrals */
  --paper: #ece9e2;
  --paper-2: #dedbd1;
  --ink: #0f1114;
  --ink-soft: #2a2d32;
  --ink-mute: #5e6167;
  --rule: #0f111422;
  --rule-strong: #0f111455;

  /* Accent — signature gold from the logo mark */
  --accent: #c9a23b;
  --accent-ink: #0f1114;
  --gold: #c9a23b;
  --gold-deep: #8f7220;

  /* Bold geometric sans — matches the ROSEDALE wordmark's weight */
  --serif: "Archivo", ui-sans-serif, system-ui, sans-serif;
  --sans: "Archivo", ui-sans-serif, system-ui, sans-serif;
  --display: "Archivo", ui-sans-serif, system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;

  --container: 1440px;
  --gutter: 40px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; }

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

:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { outline: none; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-feature-settings: "ss01", "cv11";
  -webkit-tap-highlight-color: transparent;
}

.serif { font-family: var(--display); font-weight: 800; letter-spacing: -0.03em; text-transform: uppercase; }
.mono { font-family: var(--mono); }

.container { max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); padding-left: max(var(--gutter), env(safe-area-inset-left)); padding-right: max(var(--gutter), env(safe-area-inset-right)); }

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

/* Eyebrow — tiny monospace label */
.eyebrow {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-mute);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: "";
  width: 24px; height: 1px;
  background: var(--gold);
  opacity: 1;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 24px;
  border-radius: 0;
  font-family: var(--display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1),
              background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  background: var(--ink);
  color: var(--paper);
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn .arrow { transition: transform 0.25s ease; }
.btn:hover .arrow { transform: translateX(3px); }
.btn.ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--rule-strong);
}
.btn.ghost:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.btn.accent { background: var(--accent); color: var(--accent-ink); }

/* Underline link */
.ulink {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  border-bottom: 1px solid var(--rule-strong);
  padding-bottom: 2px;
  cursor: pointer;
}
.ulink:hover { border-color: var(--ink); }

/* NAV */
.nav {
  position: sticky;
  top: 0;
  z-index: 40;
  background: color-mix(in oklab, var(--paper), transparent 8%);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--rule);
  transition: box-shadow 0.3s ease;
}
.nav.scrolled { box-shadow: 0 8px 30px -18px #0f111466; }
.nav.scrolled .nav-inner { min-height: 60px; }
.nav-inner { transition: min-height 0.3s ease; }
.nav-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 12px var(--gutter);
  min-height: 72px;
}
.logo {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  height: 44px;
}
.logo-word {
  font-family: var(--display);
  font-weight: 800;
  font-size: 21px;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--ink);
  line-height: 1;
}

.nav-links {
  display: flex;
  gap: clamp(14px, 1.8vw, 28px);
  padding: 0 28px;
  justify-content: center;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.nav-links a { position: relative; padding: 6px 0; }
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0; right: 100%; bottom: 0;
  height: 2px;
  background: var(--gold);
  transition: right 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.nav-links a:hover { color: var(--ink); }
.nav-links a:hover::after { right: 0; }

.nav-right {
  display: flex;
  align-items: center;
  gap: 16px;
  justify-content: flex-end;
}
.lang-toggle {
  display: inline-flex;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  border: 1px solid var(--rule-strong);
  border-radius: 0;
  overflow: hidden;
}
.lang-toggle button {
  padding: 10px 12px;
  min-height: 36px;
  background: transparent;
  color: var(--ink-mute);
  border: 0;
  cursor: pointer;
  font: inherit;
}
.lang-toggle button.on { background: var(--ink); color: var(--paper); }

/* HERO */
.hero {
  padding: 88px 0 64px;
  border-bottom: 1px solid var(--rule);
  position: relative;
  overflow: hidden;
}
.hero .container { position: relative; z-index: 1; }
.hero-cubes {
  position: absolute;
  top: -70px;
  right: -110px;
  width: 480px;
  height: 480px;
  opacity: 0.07;
  pointer-events: none;
  z-index: 0;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 64px;
  align-items: end;
}
.hero h1 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(56px, 9vw, 148px);
  line-height: 0.88;
  letter-spacing: -0.045em;
  text-transform: uppercase;
  margin: 28px 0 0;
}
.hero h1 .it { font-weight: 400; font-style: normal; color: var(--ink-soft); letter-spacing: -0.03em; }
.hero h1 .it.gold { color: var(--gold); font-weight: 800; font-style: normal; letter-spacing: -0.04em; }
.hero-body {
  font-size: 18px;
  line-height: 1.45;
  color: var(--ink-soft);
  max-width: 44ch;
  margin-top: 40px;
}
.hero-ctas { display: flex; gap: 12px; margin-top: 28px; flex-wrap: wrap; }
.hero-meta {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--rule);
}
.hero-meta .loc { font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; color: var(--ink-mute); }

/* Hero visual column */
.hero-visual {
  position: relative;
  aspect-ratio: 4 / 5;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  overflow: hidden;
}
.hero-visual .ph-label {
  position: absolute;
  top: 16px; left: 16px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--ink-mute);
  z-index: 2;
  pointer-events: none;
}
.hero-visual .ph-caption {
  position: absolute;
  bottom: 16px; left: 16px; right: 16px;
  display: flex; justify-content: space-between;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--ink-mute);
  z-index: 2;
  pointer-events: none;
}
.hero-visual img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Stats strip */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-bottom: 1px solid var(--rule);
}
.stat {
  padding: 40px var(--gutter);
  border-right: 1px solid var(--rule);
}
.stat:last-child { border-right: 0; }
.stat .n {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(40px, 5vw, 76px);
  line-height: 1;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
}
.stat .label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin-top: 12px;
}

/* Generic section header */
.section-head {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 64px;
  padding-bottom: 48px;
  border-bottom: 1px solid var(--rule);
  margin-bottom: 48px;
}
.section-head h2 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(42px, 5vw, 80px);
  line-height: 0.95;
  letter-spacing: -0.04em;
  text-transform: uppercase;
  margin: 20px 0 0;
}
.section-head .sh-body {
  max-width: 48ch;
  font-size: 17px;
  color: var(--ink-soft);
  align-self: end;
}

/* Projects */
.projects { padding: 96px 0; border-bottom: 1px solid var(--rule); }
.proj-filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 32px; }
.chip {
  padding: 10px 16px;
  border-radius: 0;
  background: transparent;
  border: 1px solid var(--rule-strong);
  font-family: var(--display);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-mute);
  cursor: pointer;
  transition: all 0.2s ease;
}
.chip:hover { color: var(--ink); }
.chip.on { background: var(--ink); color: var(--paper); border-color: var(--ink); }

.proj-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 32px 24px;
}
.proj-card {
  grid-column: span 3;
  cursor: pointer;
  transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.proj-card:nth-child(5n) { grid-column: span 2; }
.proj-card:nth-child(5n+1) { grid-column: span 4; }
.proj-card:hover { transform: translateY(-4px); }

.proj-media {
  aspect-ratio: 4 / 3;
  position: relative;
  overflow: hidden;
  border: 1px solid var(--rule);
  background: var(--paper-2);
}
.proj-media img { width: 100%; height: 100%; display: block; object-fit: cover; transition: transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1); }
.proj-card:hover .proj-media img { transform: scale(1.03); }
.proj-media .tag {
  position: absolute;
  top: 14px; left: 14px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
  background: var(--paper);
  padding: 5px 9px;
  border-radius: 0;
  border: 1px solid var(--rule);
  z-index: 2;
  pointer-events: none;
}
.proj-meta {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-top: 16px;
  gap: 24px;
  cursor: pointer;
}
.proj-meta h3 {
  font-family: var(--display);
  font-weight: 700;
  font-size: 22px;
  line-height: 1.1;
  margin: 0;
  letter-spacing: -0.02em;
  text-transform: uppercase;
}
.proj-meta h3::after {
  content: "→";
  display: inline-block;
  margin-left: 8px;
  color: var(--gold);
  opacity: 0;
  transform: translateX(-6px);
  transition: opacity 0.25s ease, transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.proj-card:hover .proj-meta h3::after { opacity: 1; transform: none; }
.proj-meta .sub {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--ink-mute);
  text-transform: uppercase;
  white-space: nowrap;
}

/* Photo-pending placeholder — projects awaiting real photography */
.photo-pending {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--paper-2);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-mute);
  text-align: center;
  padding: 24px;
}

/* Services */
.services { padding: 96px 0; border-bottom: 1px solid var(--rule); background: var(--paper-2); }
.svc-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0;
  border-top: 1px solid var(--rule);
}
.svc {
  padding: 40px 36px;
  border-bottom: 1px solid var(--rule);
  border-right: 1px solid var(--rule);
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 28px;
  align-items: start;
  transition: background 0.3s ease;
}
.svc:nth-child(2n) { border-right: 0; }
.svc:hover { background: color-mix(in oklab, var(--accent), transparent 92%); }
.svc .num {
  font-family: var(--mono);
  font-weight: 500;
  font-size: 13px;
  color: var(--gold);
  line-height: 1;
  padding-top: 12px;
  letter-spacing: 0.1em;
}
.svc h3 {
  font-family: var(--display);
  font-weight: 700;
  font-size: 28px;
  line-height: 1.05;
  letter-spacing: -0.025em;
  text-transform: uppercase;
  margin: 0 0 12px;
}
.svc p { color: var(--ink-soft); font-size: 15.5px; line-height: 1.55; margin: 0; max-width: 44ch; }

/* Approach — dark charcoal section, echoes the logo */
.approach {
  --paper: #141310;
  --paper-2: #1c1b17;
  --ink: #eeeae1;
  --ink-soft: #cfcabe;
  --ink-mute: #8a857a;
  --rule: #eeeae122;
  --rule-strong: #eeeae144;
  background: var(--paper);
  color: var(--ink);
  padding: 120px 0;
  border-bottom: 1px solid var(--rule);
}
.approach-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}
.approach h2 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(44px, 5.5vw, 88px);
  line-height: 0.92;
  letter-spacing: -0.045em;
  text-transform: uppercase;
  margin: 20px 0 0;
}
.approach .body {
  font-size: 18px;
  color: var(--ink-soft);
  line-height: 1.55;
  max-width: 48ch;
}
.pillars {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0;
  margin-top: 64px;
  border-top: 1px solid var(--rule);
  grid-column: 1 / -1;
}
.pillar {
  padding: 32px 0 32px 24px;
  border-bottom: 1px solid var(--rule);
  border-right: 1px solid var(--rule);
  position: relative;
}
.pillar:nth-child(2n) { border-right: 0; padding-left: 40px; }
.pillar .num {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--ink-mute);
}
.pillar h4 {
  font-family: var(--display);
  font-weight: 700;
  font-size: 22px;
  margin: 12px 0 10px;
  letter-spacing: -0.025em;
  text-transform: uppercase;
}
.pillar p { margin: 0; color: var(--ink-soft); font-size: 15px; max-width: 32ch; }

/* About */
.about { padding: 120px 0; border-bottom: 1px solid var(--rule); background: var(--paper-2); }
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}
.about h2 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(44px, 5vw, 80px);
  line-height: 0.95;
  letter-spacing: -0.045em;
  text-transform: uppercase;
  margin: 20px 0 24px;
}
.about .body { font-size: 18px; color: var(--ink-soft); line-height: 1.55; max-width: 48ch; }

.leadership {
  margin-top: 40px;
  border-top: 1px solid var(--rule);
}
.lead {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 24px;
  align-items: baseline;
  padding: 18px 0;
  border-bottom: 1px solid var(--rule);
}
.lead .mono { color: var(--ink-mute); font-size: 11px; letter-spacing: 0.1em; }
.lead .nm { font-family: var(--display); font-weight: 600; font-size: 17px; letter-spacing: -0.01em; text-transform: uppercase; }
.lead .rl { font-size: 13px; color: var(--ink-soft); text-align: right; }

.certs {
  margin-top: 40px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.cert {
  font-family: var(--display);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 10px 14px;
  border: 1px solid var(--rule-strong);
  border-radius: 0;
  color: var(--ink-soft);
}

/* RFQ */
.rfq { padding: 120px 0; border-bottom: 1px solid var(--rule); }
.rfq-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 80px;
  align-items: start;
}
.rfq h2 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(44px, 5vw, 80px);
  line-height: 0.95;
  letter-spacing: -0.045em;
  text-transform: uppercase;
  margin: 20px 0 24px;
}
.rfq .body { font-size: 17px; color: var(--ink-soft); max-width: 40ch; line-height: 1.55; }

.form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  border-top: 1px solid var(--rule-strong);
}
.field {
  grid-column: span 1;
  border-bottom: 1px solid var(--rule-strong);
  padding: 18px 0;
  position: relative;
}
.field.full { grid-column: span 2; }
.field label {
  display: block;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin-bottom: 8px;
}
.field input,
.field select,
.field textarea {
  width: 100%;
  background: transparent;
  border: 0;
  font-family: var(--display);
  font-size: 20px;
  color: var(--ink);
  padding: 4px 0;
  letter-spacing: -0.015em;
  outline: none;
  font-weight: 500;
}
.field select { font-family: var(--sans); font-size: 16px; color: var(--ink); appearance: none; cursor: pointer; }
.field textarea { font-family: var(--sans); font-size: 16px; min-height: 120px; resize: vertical; line-height: 1.5; }
.field input::placeholder, .field textarea::placeholder { color: var(--ink-mute); opacity: 0.6; }
.field.left-pad { padding-left: 24px; }
.field.error { border-bottom-color: #c0392b; }
.field:focus-within { border-bottom-color: var(--gold); }
.field:focus-within label { color: var(--gold-deep); }
.field .err {
  position: absolute;
  top: 10px; right: 0;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  color: #c0392b;
}
.form-actions {
  grid-column: span 2;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 0 0;
  gap: 16px;
}
.form-note {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-mute);
  letter-spacing: 0.08em;
}

.form-success {
  padding: 48px 32px;
  border: 1px solid var(--rule-strong);
  text-align: center;
  font-family: var(--display);
  font-weight: 600;
  font-size: 22px;
  line-height: 1.3;
  letter-spacing: -0.02em;
}
.form-success .mono {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  display: block;
  margin-bottom: 16px;
}

/* Footer */
.footer {
  padding: 96px 0 32px;
  background: #0a0b0d;
  color: var(--paper);
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 64px;
  border-bottom: 1px solid #ffffff22;
}
.footer h3 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(36px, 4vw, 60px);
  line-height: 0.92;
  margin: 0 0 24px;
  letter-spacing: -0.045em;
  text-transform: uppercase;
  max-width: 16ch;
}
.footer h3 .it { font-weight: 400; color: var(--gold); }
.footer-logo {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 40px;
}
.footer-word {
  font-family: var(--display);
  font-weight: 800;
  font-size: 24px;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--paper);
  line-height: 1;
}
.footer .col-label {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #ffffff99;
  margin-bottom: 16px;
}
.footer a { color: #ffffffcc; }
.footer a:hover { color: white; }
.footer .addr { font-size: 14px; line-height: 1.7; color: #ffffffcc; }
.footer .flinks { display: grid; gap: 8px; font-size: 14px; }
.footer-bottom {
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: #ffffff88;
}
.footer-bottom .bug-link { text-decoration: underline; text-underline-offset: 3px; }
.footer-bottom .bug-link:hover { color: var(--gold); }

/* Case study modal */
.modal-backdrop {
  position: fixed; inset: 0;
  background: #0a0908cc;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 32px;
  animation: fade 0.25s ease;
}
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.modal {
  background: var(--paper);
  width: min(1100px, 100%);
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  border-radius: 2px;
  animation: rise 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
}
@keyframes rise { from { transform: translateY(24px); opacity: 0; } to { transform: none; opacity: 1; } }
.modal-close {
  position: absolute;
  top: 20px; right: 20px;
  width: 40px; height: 40px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--paper);
  border: 0;
  cursor: pointer;
  display: grid; place-items: center;
  z-index: 2;
  font-size: 16px;
}
.modal-hero {
  aspect-ratio: 16 / 9;
  background: var(--paper-2);
  overflow: hidden;
  border-bottom: 1px solid var(--rule);
  position: relative;
}
.modal-hero img { width: 100%; height: 100%; object-fit: cover; display: block; }
.modal-body { padding: 48px 48px 56px; }
.modal-body .eyebrow { margin-bottom: 24px; }
.modal-body h2 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(36px, 4.5vw, 64px);
  line-height: 0.95;
  letter-spacing: -0.04em;
  text-transform: uppercase;
  margin: 0 0 28px;
}
.modal-body p { font-size: 17px; line-height: 1.55; color: var(--ink-soft); max-width: 62ch; }
.modal-facts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: 40px;
  border-top: 1px solid var(--rule);
}
.modal-facts .f {
  padding: 20px 20px 20px 0;
  border-right: 1px solid var(--rule);
}
.modal-facts .f:last-child { border-right: 0; }
.modal-facts .f .k {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin-bottom: 10px;
}
.modal-facts .f .v { font-family: var(--display); font-weight: 600; font-size: 16px; letter-spacing: -0.015em; text-transform: uppercase; }

/* Scroll reveals */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.2, 0.8, 0.2, 1);
  }
  .reveal.in { opacity: 1; transform: none; }

  /* Staggered children */
  .svc-grid.reveal .svc,
  .approach-grid.reveal .pillar {
    opacity: 0;
    transform: translateY(14px);
    transition: opacity 0.55s ease, transform 0.55s cubic-bezier(0.2, 0.8, 0.2, 1);
  }
  .svc-grid.reveal.in .svc,
  .approach-grid.reveal.in .pillar { opacity: 1; transform: none; }
  .svc-grid.reveal.in .svc:nth-child(1), .approach-grid.reveal.in .pillar:nth-child(1) { transition-delay: 0.08s; }
  .svc-grid.reveal.in .svc:nth-child(2), .approach-grid.reveal.in .pillar:nth-child(2) { transition-delay: 0.16s; }
  .svc-grid.reveal.in .svc:nth-child(3), .approach-grid.reveal.in .pillar:nth-child(3) { transition-delay: 0.24s; }
  .svc-grid.reveal.in .svc:nth-child(4), .approach-grid.reveal.in .pillar:nth-child(4) { transition-delay: 0.32s; }
  .svc-grid.reveal.in .svc:nth-child(5) { transition-delay: 0.4s; }
  .svc-grid.reveal.in .svc:nth-child(6) { transition-delay: 0.48s; }

  /* Gold eyebrow rule grows in */
  .reveal .eyebrow::before { width: 0; transition: width 0.6s cubic-bezier(0.2, 0.8, 0.2, 1) 0.25s; }
  .reveal.in .eyebrow::before { width: 24px; }

  /* Hero entrance on load */
  @keyframes rise-in {
    from { opacity: 0; transform: translateY(22px); }
    to { opacity: 1; transform: none; }
  }
  .hero .eyebrow { animation: rise-in 0.6s cubic-bezier(0.2, 0.8, 0.2, 1) 0.05s backwards; }
  .hero h1 { animation: rise-in 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) 0.14s backwards; }
  .hero-body { animation: rise-in 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) 0.26s backwards; }
  .hero-ctas { animation: rise-in 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) 0.36s backwards; }
  .hero-grid > div:last-child { animation: rise-in 0.9s cubic-bezier(0.2, 0.8, 0.2, 1) 0.2s backwards; }

  .btn:active { transform: translateY(0) scale(0.98); }
}

/* Hamburger + mobile menu */
.menu-btn {
  display: none;
  width: 44px; height: 44px;
  border: 1px solid var(--rule-strong);
  background: transparent;
  cursor: pointer;
  position: relative;
  padding: 0;
}
.menu-btn span {
  position: absolute;
  left: 12px; right: 12px;
  height: 2px;
  background: var(--ink);
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1), top 0.3s ease;
}
.menu-btn span:nth-child(1) { top: 17px; }
.menu-btn span:nth-child(2) { top: 25px; }
.menu-btn.open span:nth-child(1) { top: 21px; transform: rotate(45deg); }
.menu-btn.open span:nth-child(2) { top: 21px; transform: rotate(-45deg); }

.nav-menu {
  display: none;
  position: absolute;
  top: 100%; left: 0; right: 0;
  height: calc(100dvh - 100%);
  background: var(--paper);
  z-index: 39;
  flex-direction: column;
  padding: 24px var(--gutter) max(24px, env(safe-area-inset-bottom));
  overflow-y: auto;
}
.nav-menu a {
  font-family: var(--display);
  font-weight: 800;
  font-size: 32px;
  letter-spacing: -0.03em;
  text-transform: uppercase;
  padding: 16px 0;
  border-bottom: 1px solid var(--rule);
}
.nav-menu a:active { color: var(--gold-deep); }
.nav-menu .menu-cta {
  font-size: 13px;
  letter-spacing: 0.12em;
  margin-top: 28px;
  justify-content: center;
  border-bottom: 0;
  padding: 18px 24px;
}

/* Mid widths — nav gets tight before mobile */
@media (max-width: 1280px) {
  .nav-links { font-size: 12px; }
  .nav-right { gap: 12px; }
}
@media (max-width: 1120px) {
  .nav-inner { grid-template-columns: 1fr auto; }
  .nav-links { display: none; }
  .menu-btn { display: block; }
  .nav-menu.open { display: flex; }
}

/* Mobile */
@media (max-width: 860px) {
  :root { --gutter: 20px; }
  .nav-inner { grid-template-columns: 1fr auto; }
  .nav-links { display: none; }
  .nav-cta { display: none; }
  .logo-word { font-size: 18px; }
  .hero { padding: 48px 0 48px; }
  .hero-cubes { width: 260px; height: 260px; top: -40px; right: -80px; }
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero h1 { font-size: clamp(44px, 14vw, 80px); }
  .hero-ctas { flex-direction: column; align-items: stretch; }
  .hero-ctas .btn { justify-content: center; padding: 18px 24px; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stat { padding: 24px 20px; }
  .stat:nth-child(2) { border-right: 0; }
  .stat:nth-child(1), .stat:nth-child(2) { border-bottom: 1px solid var(--rule); }
  .section-head { grid-template-columns: 1fr; gap: 16px; }
  .projects, .services, .approach, .about, .rfq { padding: 64px 0; }
  .proj-grid { grid-template-columns: 1fr; }
  .proj-card, .proj-card:nth-child(5n), .proj-card:nth-child(5n+1) { grid-column: span 1; }
  .svc-grid { grid-template-columns: 1fr; }
  .svc { border-right: 0; }
  .approach-grid, .about-grid, .rfq-grid { grid-template-columns: 1fr; gap: 40px; }
  .pillars { grid-template-columns: 1fr; }
  .pillar, .pillar:nth-child(2n) { border-right: 0; padding-left: 0; }
  .form { grid-template-columns: 1fr; }
  .field, .field.full { grid-column: span 1; }
  .field.left-pad { padding-left: 0; }
  .form-actions { grid-column: span 1; flex-direction: column; align-items: flex-start; }
  .modal-body { padding: 32px 20px max(32px, env(safe-area-inset-bottom)); }
  .modal-facts { grid-template-columns: 1fr 1fr; }
  .modal-backdrop { padding: 0; align-items: end; }
  .modal { max-height: 94dvh; width: 100%; border-radius: 12px 12px 0 0; }
  .proj-meta h3 { font-size: 19px; }
  .svc { padding: 28px 20px; grid-template-columns: auto 1fr; gap: 18px; }
  .svc h3 { font-size: 22px; }
  .section-head h2, .approach h2, .about h2, .rfq h2 { overflow-wrap: anywhere; }
  .footer { padding: 64px 0 max(24px, env(safe-area-inset-bottom)); }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; gap: 8px; }
}
