/* palette: bg=#0A1E3F fg=#EAF1FA accent=#3DD6C6 */
/* fonts: display="Space Grotesk" body="IBM Plex Sans" mono="IBM Plex Mono" */

:root {
  --bg: #0A1E3F;          /* deep blueprint blue */
  --bg-alt: #0D274F;      /* alternating section background */
  --bg-deep: #07172F;     /* darkest band */
  --fg: #EAF1FA;          /* cream-white line-work / text */
  --fg-soft: #C6D5EA;     /* slightly softer foreground */
  --muted: #7C92B6;       /* secondary text */
  --accent: #3DD6C6;      /* cyan technical accent */
  --accent-deep: #21A89A; /* darker accent for hover */
  --accent-2: #6E8BFF;    /* secondary annotation blue */
  --line: rgba(234, 241, 250, 0.16);
  --line-soft: rgba(234, 241, 250, 0.08);
  --border: rgba(234, 241, 250, 0.18);
  --serif: 'Space Grotesk', ui-sans-serif, system-ui, sans-serif;
  --sans: 'IBM Plex Sans', ui-sans-serif, system-ui, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, 'SFMono-Regular', monospace;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --container: 1280px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--sans);
  font-size: 18px;
  line-height: 1.75;
  color: var(--fg);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 500; margin: 0; }
p { margin: 0; }

/* blueprint grid backdrop applied to body */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    linear-gradient(var(--line-soft) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-soft) 1px, transparent 1px);
  background-size: 64px 64px;
  opacity: 0.7;
}

/* ---------- layout ---------- */
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 20px; position: relative; z-index: 1; }
@media (min-width: 768px) { .container { padding: 0 32px; } }
section { position: relative; z-index: 1; }
.section { padding: clamp(80px, 12vw, 160px) 0; }

.eyebrow {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 28px;
}
.eyebrow::before { content: ""; width: 28px; height: 1px; background: var(--accent); display: inline-block; }

.lead { font-size: clamp(1.05rem, 2.2vw, 1.35rem); color: var(--fg-soft); line-height: 1.65; max-width: 60ch; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: var(--mono); font-size: 13px; letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 16px 30px;
  border: 1px solid var(--accent);
  color: var(--bg); background: var(--accent);
  transition: background .35s var(--ease), color .35s var(--ease), transform .35s var(--ease);
}
.btn:hover { background: transparent; color: var(--accent); transform: translateY(-2px); }
.btn--ghost { background: transparent; color: var(--fg); border-color: var(--border); }
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); }
.arrow-link {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--mono); font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--fg); transition: gap .3s var(--ease), color .3s var(--ease);
}
.arrow-link::after { content: "\2192"; transition: transform .3s var(--ease); }
.arrow-link:hover { color: var(--accent); gap: 14px; }

/* ---------- header ---------- */
.header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(10, 30, 63, 0.82);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--line-soft);
  transition: box-shadow .35s var(--ease), border-color .35s var(--ease);
}
.header[data-scrolled="true"] { box-shadow: 0 8px 40px -12px rgba(0,0,0,0.55); border-bottom-color: var(--line); }
.header__inner { display: flex; align-items: center; justify-content: space-between; height: 76px; }
.brand { display: flex; align-items: center; gap: 12px; font-family: var(--serif); font-weight: 600; font-size: 1.15rem; letter-spacing: -0.01em; }
.brand__mark { width: 30px; height: 30px; flex: none; }
.brand small { font-family: var(--mono); font-size: 9px; letter-spacing: 0.22em; color: var(--muted); display: block; text-transform: uppercase; }
.nav { display: none; gap: 38px; align-items: center; }
@media (min-width: 1024px) { .nav { display: flex; } }
.nav a { font-family: var(--mono); font-size: 13px; letter-spacing: 0.04em; color: var(--fg-soft); transition: color .25s; position: relative; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--accent); }
.header .btn { display: none; }
@media (min-width: 1024px) { .header .btn { display: inline-flex; padding: 12px 22px; } }

.menu-toggle { display: inline-flex; flex-direction: column; gap: 5px; width: 34px; height: 34px; align-items: center; justify-content: center; }
@media (min-width: 1024px) { .menu-toggle { display: none; } }
.menu-toggle span { width: 22px; height: 1.5px; background: var(--fg); transition: transform .3s var(--ease), opacity .3s; }
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

.mobile-menu {
  position: fixed; inset: 76px 0 0 0; z-index: 99;
  background: var(--bg-deep);
  padding: 40px 24px;
  transform: translateY(-12px); opacity: 0; pointer-events: none;
  transition: opacity .35s var(--ease), transform .35s var(--ease);
  display: flex; flex-direction: column;
}
.mobile-menu[data-open="true"] { opacity: 1; transform: none; pointer-events: all; }
.mobile-menu a { font-family: var(--serif); font-size: 1.8rem; padding: 16px 0; border-bottom: 1px solid var(--line-soft); }
.mobile-menu .btn { margin-top: 32px; justify-content: center; }

/* ---------- hero ---------- */
.hero { min-height: 100vh; display: flex; align-items: center; position: relative; overflow: hidden; padding: 120px 0 80px; }
.hero__bg { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.hero__bg img { width: 100%; height: 100%; object-fit: cover; opacity: 0.28; animation: heroZoom 9s var(--ease) forwards; }
.hero__bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(7,23,47,0.55) 0%, rgba(10,30,63,0.85) 70%, var(--bg) 100%); }
@keyframes heroZoom { from { transform: scale(1.1); } to { transform: scale(1); } }
.hero__inner { position: relative; z-index: 2; max-width: 980px; }
.hero h1 {
  font-size: clamp(3.2rem, 9vw, 8rem);
  line-height: 0.98; letter-spacing: -0.035em; font-weight: 400;
  margin: 0 0 32px;
}
.hero h1 em { font-style: normal; color: var(--accent); }
.hero__meta { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 44px; align-items: center; }
.hero__annotations { position: absolute; inset: 0; z-index: 1; pointer-events: none; display: none; }
@media (min-width: 1024px) { .hero__annotations { display: block; } }
.annot { position: absolute; font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; color: var(--muted); text-transform: uppercase; }
.annot::before { content: ""; position: absolute; background: var(--line); }
.annot--tl { top: 120px; left: 32px; }
.annot--br { bottom: 60px; right: 32px; text-align: right; }
.annot--tr { top: 130px; right: 32px; }
.hero__coords { position: absolute; bottom: 40px; left: 50%; transform: translateX(-50%); font-family: var(--mono); font-size: 11px; letter-spacing: 0.2em; color: var(--muted); z-index: 2; }

/* ---------- tiles (capabilities, echoing reference category tiles) ---------- */
.tiles { display: grid; grid-template-columns: 1fr; gap: 1px; background: var(--line); border: 1px solid var(--line); }
@media (min-width: 640px) { .tiles { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .tiles { grid-template-columns: repeat(3, 1fr); } }
.tile { background: var(--bg); padding: 40px 32px; min-height: 240px; display: flex; flex-direction: column; justify-content: space-between; transition: background .4s var(--ease), transform .4s var(--ease); position: relative; }
.tile:hover { background: var(--bg-alt); }
.tile__no { font-family: var(--mono); font-size: 12px; color: var(--accent); letter-spacing: 0.1em; }
.tile h3 { font-size: 1.55rem; letter-spacing: -0.01em; margin: 0 0 12px; }
.tile p { color: var(--muted); font-size: 0.96rem; line-height: 1.6; }
.tile__bar { width: 40px; height: 3px; background: var(--accent); margin-top: 24px; transition: width .4s var(--ease); }
.tile:hover .tile__bar { width: 72px; }

/* ---------- section headers ---------- */
.section-head { max-width: 760px; margin-bottom: 64px; }
.section-head h2 { font-size: clamp(2.5rem, 6vw, 5rem); letter-spacing: -0.025em; line-height: 1.02; font-weight: 400; }
.section-head p { margin-top: 24px; }
.split-head { display: grid; gap: 32px; align-items: end; margin-bottom: 64px; }
@media (min-width: 900px) { .split-head { grid-template-columns: 1.4fr 1fr; } }

/* ---------- manifesto / dark band ---------- */
.manifesto { background: var(--fg); color: var(--bg-deep); }
.manifesto::after { content: ""; position: absolute; inset: 0; background-image: linear-gradient(rgba(7,23,47,0.05) 1px, transparent 1px), linear-gradient(90deg, rgba(7,23,47,0.05) 1px, transparent 1px); background-size: 64px 64px; pointer-events: none; }
.manifesto .container { text-align: center; }
.manifesto .eyebrow { color: var(--accent-deep); }
.manifesto .eyebrow::before { background: var(--accent-deep); }
.manifesto blockquote { margin: 0 auto; max-width: 980px; font-family: var(--serif); font-weight: 400; font-size: clamp(2rem, 5vw, 4rem); line-height: 1.14; letter-spacing: -0.02em; }
.manifesto blockquote span { color: var(--accent-deep); }
.manifesto cite { display: block; margin-top: 40px; font-family: var(--mono); font-size: 13px; letter-spacing: 0.06em; font-style: normal; color: #3a5276; text-transform: uppercase; }

/* ---------- approach (numbered list) ---------- */
.approach { background: var(--bg-alt); }
.approach__list { border-top: 1px solid var(--line); }
.approach__item { display: grid; gap: 16px; padding: 44px 0; border-bottom: 1px solid var(--line); align-items: start; }
@media (min-width: 900px) { .approach__item { grid-template-columns: 120px 1fr 1.2fr; gap: 40px; } }
.approach__item:hover .approach__num { color: var(--accent); }
.approach__num { font-family: var(--mono); font-size: 14px; color: var(--muted); letter-spacing: 0.1em; transition: color .3s; }
.approach__item h3 { font-size: 1.7rem; letter-spacing: -0.01em; }
.approach__item p { color: var(--fg-soft); }

/* ---------- work / case grid ---------- */
.work-grid { display: grid; gap: 28px; }
@media (min-width: 768px) { .work-grid { grid-template-columns: repeat(2, 1fr); } }
.work-card { border: 1px solid var(--line); background: var(--bg-alt); overflow: hidden; transition: transform .4s var(--ease), box-shadow .4s var(--ease), border-color .4s; }
.work-card:hover { transform: translateY(-6px); box-shadow: 0 24px 60px -20px rgba(0,0,0,0.6); border-color: var(--accent); }
.work-card__img { aspect-ratio: 16 / 10; overflow: hidden; position: relative; }
.work-card__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); filter: saturate(0.9); }
.work-card:hover .work-card__img img { transform: scale(1.05); }
.work-card__tag { position: absolute; top: 16px; left: 16px; font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; background: var(--bg-deep); color: var(--accent); padding: 6px 12px; border: 1px solid var(--line); }
.work-card__body { padding: 28px 28px 32px; }
.work-card__body h3 { font-size: 1.45rem; letter-spacing: -0.01em; margin-bottom: 12px; }
.work-card__body p { color: var(--muted); font-size: 0.95rem; }
.work-card__meta { display: flex; gap: 18px; margin-top: 22px; font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); flex-wrap: wrap; }

/* ---------- stats band ---------- */
.stats { background: var(--bg-deep); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stats__grid { display: grid; gap: 1px; background: var(--line); border: 1px solid var(--line); }
@media (min-width: 640px) { .stats__grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .stats__grid { grid-template-columns: repeat(4, 1fr); } }
.stat { background: var(--bg-deep); padding: 44px 32px; }
.stat__num { font-family: var(--serif); font-size: clamp(2.6rem, 5vw, 3.8rem); letter-spacing: -0.03em; line-height: 1; }
.stat__num span { color: var(--accent); }
.stat__label { margin-top: 14px; font-family: var(--mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }

/* ---------- FAQ ---------- */
.faq__item { border-bottom: 1px solid var(--line); padding: 8px 0; }
.faq__q { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 24px; text-align: left; padding: 28px 0; font-family: var(--serif); font-size: clamp(1.15rem, 2.4vw, 1.5rem); letter-spacing: -0.01em; color: var(--fg); transition: color .3s; }
.faq__q:hover { color: var(--accent); }
.faq__icon { flex: none; width: 22px; height: 22px; position: relative; }
.faq__icon::before, .faq__icon::after { content: ""; position: absolute; background: var(--accent); transition: transform .3s var(--ease); }
.faq__icon::before { top: 10px; left: 0; width: 22px; height: 1.5px; }
.faq__icon::after { left: 10px; top: 0; width: 1.5px; height: 22px; }
.faq__item[data-open="true"] .faq__icon::after { transform: scaleY(0); }
.faq__a { max-height: 0; overflow: hidden; transition: max-height .4s var(--ease); }
.faq__a-inner { padding: 0 0 30px; color: var(--fg-soft); max-width: 70ch; }
.faq__item[data-open="true"] .faq__a { max-height: 320px; }

/* ---------- CTA ---------- */
.cta { background: var(--fg); color: var(--bg-deep); text-align: center; overflow: hidden; }
.cta h2 { font-size: clamp(2.5rem, 7vw, 5.5rem); letter-spacing: -0.03em; line-height: 1; font-weight: 400; max-width: 16ch; margin: 0 auto; }
.cta p { color: #3a5276; max-width: 52ch; margin: 28px auto 0; }
.cta .btn { background: var(--bg-deep); border-color: var(--bg-deep); color: var(--fg); margin-top: 44px; }
.cta .btn:hover { background: transparent; color: var(--bg-deep); }

/* ---------- contact form ---------- */
.contact-grid { display: grid; gap: 56px; }
@media (min-width: 960px) { .contact-grid { grid-template-columns: 1fr 1fr; gap: 80px; } }
.field { margin-bottom: 24px; }
.field label { display: block; font-family: var(--mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.field input, .field textarea, .field select {
  width: 100%; padding: 15px 18px; background: var(--bg-alt); border: 1px solid var(--border);
  color: var(--fg); font-family: var(--sans); font-size: 1rem; transition: border-color .3s;
}
.field input:focus, .field textarea:focus, .field select:focus { outline: none; border-color: var(--accent); }
.field textarea { resize: vertical; min-height: 140px; }
.contact-info dl { display: grid; gap: 28px; margin: 0; }
.contact-info dt { font-family: var(--mono); font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); margin-bottom: 6px; }
.contact-info dd { margin: 0; font-size: 1.05rem; color: var(--fg-soft); }

/* ---------- generic prose (legal pages) ---------- */
.prose { max-width: 760px; }
.prose h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); margin: 56px 0 18px; letter-spacing: -0.01em; }
.prose h3 { font-size: 1.2rem; margin: 32px 0 12px; }
.prose p, .prose li { color: var(--fg-soft); margin-bottom: 16px; }
.prose ul { padding-left: 22px; }
.prose a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.page-hero { padding: clamp(120px, 18vw, 200px) 0 clamp(48px, 8vw, 90px); border-bottom: 1px solid var(--line); }
.page-hero h1 { font-size: clamp(2.8rem, 8vw, 6rem); letter-spacing: -0.03em; font-weight: 400; line-height: 1; }
.page-hero p { margin-top: 24px; }

/* ---------- footer ---------- */
.footer { background: var(--bg-deep); border-top: 1px solid var(--line); padding: 80px 0 40px; }
.footer__top { display: grid; gap: 48px; }
@media (min-width: 768px) { .footer__top { grid-template-columns: 1.6fr 1fr 1fr; } }
.footer__brand p { color: var(--muted); margin-top: 22px; max-width: 38ch; font-size: 0.95rem; }
.footer__col h4 { font-family: var(--mono); font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); margin-bottom: 20px; font-weight: 500; }
.footer__col a { display: block; color: var(--fg-soft); padding: 7px 0; font-size: 0.96rem; transition: color .25s; }
.footer__col a:hover { color: var(--accent); }
.footer__bottom { display: flex; flex-wrap: wrap; gap: 14px; justify-content: space-between; align-items: center; margin-top: 64px; padding-top: 28px; border-top: 1px solid var(--line-soft); font-family: var(--mono); font-size: 12px; letter-spacing: 0.04em; color: var(--muted); }

/* ---------- reveal ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.65s var(--ease), transform 0.65s var(--ease); transition-delay: calc(var(--i, 0) * 80ms); }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; }
  .hero__bg img { animation: none; }
  html { scroll-behavior: auto; }
}

/* ---------- cookie popup ---------- */
.cookie-popup { position:fixed;inset:0;z-index:9999;display:flex;align-items:flex-end;padding:24px;background:rgba(0,0,0,0.4);backdrop-filter:blur(4px);opacity:0;pointer-events:none;transition:opacity .3s; }
.cookie-popup[data-open="true"] { opacity:1;pointer-events:all; }
.cookie-popup__card { background:var(--bg-alt);padding:32px 36px;max-width:480px;border-radius:4px;border:1px solid var(--border); }
.cookie-popup__label { font-family:var(--mono);font-size:11px;letter-spacing:0.14em;text-transform:uppercase;color:var(--accent);margin-bottom:14px; }
.cookie-popup__card h3 { font-size:1.3rem;margin-bottom:12px;letter-spacing:-0.01em; }
.cookie-popup__card p { font-size:0.9rem;color:var(--fg-soft);line-height:1.6; }
.cookie-popup__card p a { color:var(--accent);text-decoration:underline; }
.cookie-popup__actions { display:flex;gap:12px;margin-top:20px; }
.cookie-popup__actions button { padding:11px 24px;border:1px solid var(--border);cursor:pointer;font-size:13px;font-family:var(--mono);letter-spacing:0.04em;transition:border-color .25s,background .25s; }
.cookie-popup__actions button:first-child:hover { border-color:var(--accent); }
.cookie-popup__actions button:last-child { background:var(--accent);color:var(--bg-deep);border-color:var(--accent); }
.cookie-popup__actions button:last-child:hover { background:var(--accent-deep); }

@media (min-width: 768px) { .cookie-popup { align-items: flex-end; justify-content: flex-start; } }
