/* ============================================================
   Birch — homepage v1
   Palette: deep ink background, brand teal (#40e1ce) → navy (#325390) accent
   ============================================================ */

:root {
  --bg:        #070b12;
  --bg-2:      #0b111c;
  --surface:   #0f1726;
  --surface-2: #131d30;
  --border:    rgba(148, 163, 184, 0.14);
  --border-hi: rgba(64, 225, 206, 0.35);

  --text:      #e6edf5;
  --text-mut:  #93a1b5;
  --text-dim:  #647088;

  --accent:     #40e1ce;          /* brand teal (logo mark) */
  --accent-2:   #4f93dd;          /* readable blue derived from brand navy */
  --brand-navy: #325390;          /* exact logo navy — deep fills / solid brand */
  --accent-grad: linear-gradient(110deg, #40e1ce 0%, #4f93dd 100%);

  --warn:      #fbbf24;
  --danger:    #fb7185;

  --radius:    16px;
  --radius-sm: 10px;
  --maxw:      1180px;

  --font-sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-disp: "Space Grotesk", var(--font-sans);
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: 24px;
}

h1, h2, h3, h4 { font-family: var(--font-disp); line-height: 1.1; letter-spacing: -0.01em; }

.accent {
  background: var(--accent-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.8em 1.4em;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease),
              background 0.25s var(--ease), border-color 0.25s var(--ease);
  white-space: nowrap;
}
.btn .arrow { transition: transform 0.25s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }

.btn-primary {
  background: var(--accent-grad);
  color: #04130d;
  box-shadow: 0 8px 30px -8px rgba(64, 225, 206, 0.5);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 40px -10px rgba(64, 225, 206, 0.65); }

.btn-ghost {
  background: rgba(255, 255, 255, 0.02);
  border-color: var(--border);
  color: var(--text);
}
.btn-ghost:hover { border-color: var(--border-hi); background: rgba(64, 225, 206, 0.06); transform: translateY(-2px); }

.btn-sm { padding: 0.6em 1.1em; font-size: 0.88rem; }
.btn-lg { padding: 0.95em 1.7em; font-size: 1.02rem; }

/* ===== Header ===== */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  padding: 18px 0;
  transition: background 0.3s var(--ease), border-color 0.3s var(--ease), padding 0.3s var(--ease);
  border-bottom: 1px solid transparent;
}
.site-header.scrolled {
  background: rgba(7, 11, 18, 0.78);
  backdrop-filter: blur(14px);
  border-bottom-color: var(--border);
  padding: 12px 0;
}
.header-inner { display: flex; align-items: center; gap: 32px; }

.brand { display: inline-flex; align-items: center; }
.brand-logo { height: 44px; width: auto; display: block; }
.site-header.scrolled .brand-logo { height: 38px; }
.footer-brand .brand-logo { height: 50px; }

.nav { display: flex; gap: 30px; margin-left: auto; }
.nav a {
  color: var(--text-mut);
  font-size: 0.94rem;
  font-weight: 500;
  position: relative;
  transition: color 0.2s var(--ease);
}
.nav a::after {
  content: "";
  position: absolute;
  left: 0; bottom: -6px;
  width: 0; height: 2px;
  background: var(--accent-grad);
  transition: width 0.25s var(--ease);
}
.nav a:hover { color: var(--text); }
.nav a:hover::after { width: 100%; }
.nav a[aria-current="page"] { color: var(--text); }
.nav a[aria-current="page"]::after { width: 100%; }

.header-cta { margin-left: 4px; }

.nav-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: 6px; z-index: 201; }
.nav-toggle span { width: 24px; height: 2px; background: var(--text); border-radius: 2px; transition: 0.25s var(--ease); }


/* Mobile nav drawer */
.mobile-nav {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 199;
  padding-top: var(--header-h, 64px);
}
.mobile-nav-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
}
.mobile-nav-panel {
  position: absolute;
  top: calc(var(--header-h, 64px) + 8px);
  left: 16px; right: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 8px 20px 12px;
  display: flex;
  flex-direction: column;
  gap: 0;
  transform: translateY(-8px);
  opacity: 0;
  transition: transform 0.25s var(--ease), opacity 0.25s var(--ease);
}
.mobile-nav-panel a {
  color: var(--text-mut);
  font-size: 1.05rem;
  font-weight: 500;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  transition: color 0.2s var(--ease);
}
.mobile-nav-panel a:last-of-type { border-bottom: none; }
.mobile-nav-panel a:hover { color: var(--text); }
.mobile-nav-panel a[aria-current="page"] { color: var(--accent); }
.nav-open .mobile-nav { display: block; }
.nav-open .mobile-nav-panel { transform: translateY(0); opacity: 1; }

/* ===== Hero ===== */
.hero {
  position: relative;
  padding: 170px 0 70px;
  overflow: hidden;
  background:
    radial-gradient(1100px 600px at 78% -8%, rgba(79, 147, 221, 0.10), transparent 60%),
    radial-gradient(900px 600px at 10% 0%, rgba(64, 225, 206, 0.10), transparent 55%),
    var(--bg);
}
.hero-canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; }
.hero-glow {
  position: absolute;
  width: 600px; height: 600px;
  right: -120px; top: -160px;
  background: radial-gradient(circle, rgba(79, 147, 221, 0.18), transparent 65%);
  filter: blur(20px);
  z-index: 0;
  pointer-events: none;
}
.hero-inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent);
  background: rgba(64, 225, 206, 0.08);
  border: 1px solid var(--border-hi);
  padding: 6px 14px;
  border-radius: 999px;
}
.eyebrow .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 0 rgba(64,225,206,0.6); animation: pulse 2.2s infinite; }
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(64, 225, 206, 0.55); }
  70%  { box-shadow: 0 0 0 9px rgba(64, 225, 206, 0); }
  100% { box-shadow: 0 0 0 0 rgba(64, 225, 206, 0); }
}

.hero h1 {
  font-size: clamp(2.5rem, 5.4vw, 4rem);
  font-weight: 700;
  margin: 22px 0 0;
}
.lede { color: var(--text-mut); font-size: 1.12rem; max-width: 36ch; margin-top: 20px; }
.lede-clients { color: var(--text); font-size: 0.95rem; font-weight: 500; margin-top: 14px; }

.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 32px; }

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 26px;
  margin-top: 34px;
  color: var(--text-dim);
  font-size: 0.9rem;
}
.hero-meta li { position: relative; padding-left: 18px; }
.hero-meta li::before { content: ""; position: absolute; left: 0; top: 0.6em; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); opacity: 0.8; }
.hero-meta strong { color: var(--text); font-weight: 600; }

/* Terminal */
.hero-terminal {
  background: linear-gradient(180deg, var(--surface-2), var(--surface));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 40px 80px -30px rgba(0, 0, 0, 0.7), inset 0 1px 0 rgba(255,255,255,0.04);
  overflow: hidden;
}
.term-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid var(--border);
}
.term-dot { width: 11px; height: 11px; border-radius: 50%; }
.term-dot.red { background: #ff5f57; }
.term-dot.amber { background: #febc2e; }
.term-dot.green { background: #28c840; }
.term-title { margin-left: 10px; font-size: 0.8rem; color: var(--text-dim); font-family: var(--font-mono); }
.term-body { padding: 20px 22px; font-family: var(--font-mono); font-size: 0.86rem; line-height: 1.85; color: var(--text-mut); overflow-x: auto; }
.c-prompt { color: var(--accent-2); }
.c-cmd { color: var(--text); font-weight: 500; }
.c-ok { color: var(--accent); }
.c-warn { color: var(--warn); }
.c-info { color: var(--accent-2); }
.c-dim { color: var(--text-dim); }
.c-cursor { color: var(--accent); animation: blink 1.1s step-end infinite; }
@keyframes blink { 50% { opacity: 0; } }

/* Trust strip */
.trust-strip {
  position: relative;
  z-index: 2;
  margin-top: 70px;
  padding-top: 30px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px 40px;
}
.trust-label { color: var(--text-dim); font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.08em; }
.trust-logos { display: flex; flex-wrap: wrap; gap: 14px 32px; margin-left: auto; }
.trust-logos li {
  font-family: var(--font-disp);
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text-mut);
  opacity: 0.65;
  transition: opacity 0.2s var(--ease), color 0.2s var(--ease);
}
.trust-logos li:hover { opacity: 1; color: var(--text); }

/* ===== Generic section ===== */
.section { padding: 100px 0; }
.section-head { max-width: 640px; margin-bottom: 56px; }
.kicker {
  display: inline-block;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}
.section-head h2 { font-size: clamp(1.9rem, 3.6vw, 2.7rem); }
.section-head p { color: var(--text-mut); margin-top: 16px; font-size: 1.05rem; }

/* ===== Service cards ===== */
.card-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; max-width: 820px; margin: 0 auto; }
.card {
  position: relative;
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px 28px;
  transition: transform 0.3s var(--ease), border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
  overflow: hidden;
}
.card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 2px;
  background: var(--accent-grad);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease);
}
.card:hover { transform: translateY(-6px); border-color: var(--border-hi); box-shadow: 0 30px 60px -30px rgba(0,0,0,0.8); }
.card:hover::before { transform: scaleX(1); }

.card-icon {
  display: grid;
  place-items: center;
  width: 50px; height: 50px;
  border-radius: 14px;
  color: var(--accent);
  background: rgba(64, 225, 206, 0.10);
  border: 1px solid var(--border-hi);
  margin: 0 auto 22px;
}
.card h3 { font-size: 1.22rem; margin-bottom: 0; text-align: center; padding-bottom: 20px; position: relative; }
.card h3::after { content: ""; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%); width: 40%; height: 1px; background: var(--border); }
.card p, .card .card-list { margin-top: 20px; }
.card p { color: var(--text-mut); font-size: 0.97rem; }
.card-list { margin-top: 18px; display: grid; gap: 9px; }
.card-list li { position: relative; padding-left: 24px; font-size: 0.92rem; color: var(--text); }
.card-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.45em;
  width: 12px; height: 7px;
  border-left: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: rotate(-45deg);
}

/* ===== Tech stack ===== */
.section-stack {
  background:
    radial-gradient(800px 400px at 50% 0%, rgba(79, 147, 221, 0.07), transparent 60%),
    var(--bg-2);
  border-block: 1px solid var(--border);
}
.stack-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; align-items: start; }
.stack-group {
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px 24px;
  transition: border-color 0.3s var(--ease), transform 0.3s var(--ease);
}
.stack-group:hover { border-color: var(--border-hi); transform: translateY(-4px); }
.stack-cat {
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}
.tech-list { display: flex; flex-wrap: wrap; gap: 9px; }
.tech {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text);
  background: rgba(64, 225, 206, 0.05);
  border: 1px solid var(--border);
  padding: 6px 12px;
  border-radius: 999px;
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease);
}
.tech::before {
  content: "";
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent-grad);
  flex: none;
}
.tech:hover { border-color: var(--border-hi); background: rgba(64, 225, 206, 0.1); }
.tech a { color: inherit; text-decoration: none; }
.tech a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.tech:has(a) { position: relative; cursor: pointer; }
.tech:has(a):hover { color: var(--accent); }

/* ===== Tech badges ===== */
.tech-badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 28px 64px;
  margin-top: 56px;
  padding-top: 48px;
  border-top: 1px solid var(--border);
}
.tech-badge {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  min-width: 7rem;
  color: var(--text-dim);
  transition: color 0.25s var(--ease), transform 0.25s var(--ease);
}
.tech-badge svg {
  width: 34px;
  height: 34px;
  fill: currentColor;
}
.tech-badge span {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.04em;
}
.tech-badge:hover { color: var(--text); transform: translateY(-3px); }

/* ===== Workflow cycle (Security Assessments) ===== */
.workflow-cycle {
  display: none;
}
.wf-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.wf-track {
  fill: none;
  stroke: var(--accent);
  stroke-width: 1.5;
  opacity: 0.25;
}
.wf-arrow {
  fill: var(--accent);
  opacity: 0.6;
}
.wf-node {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  color: var(--accent);
  animation: wf-counter 18s linear infinite;
}
/* top / right / bottom / left of a 100px-radius circle centred in 280×280 */
.wf-node--0 { left: 118px; top: 18px;  }
.wf-node--1 { left: 218px; top: 118px; }
.wf-node--2 { left: 118px; top: 218px; }
.wf-node--3 { left: 18px;  top: 118px; }
.wf-node-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  animation: wf-pop 18s ease-in-out infinite;
}
/* phase each node so it pops when it reaches the top of the circle */
.wf-node--0 .wf-node-inner { animation-delay: 0s;     }
.wf-node--3 .wf-node-inner { animation-delay: -13.5s; }
.wf-node--2 .wf-node-inner { animation-delay: -9s;    }
.wf-node--1 .wf-node-inner { animation-delay: -4.5s;  }
@keyframes wf-pop {
  0%, 100% { transform: scale(1.5); filter: drop-shadow(0 0 10px var(--accent)); color: #fff; }
  10%, 90% { transform: scale(1);   filter: none; color: var(--accent); }
}
@keyframes wf-rotate  { to { transform: rotate(360deg);  } }
@keyframes wf-counter { to { transform: rotate(-360deg); } }

/* ===== Steps ===== */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; counter-reset: step; }
.step {
  position: relative;
  padding: 28px 22px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  transition: border-color 0.3s var(--ease), transform 0.3s var(--ease);
}
.step:hover { border-color: var(--border-hi); transform: translateY(-4px); }
.step-num {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--accent);
  background: rgba(64, 225, 206, 0.08);
  border: 1px solid var(--border-hi);
  padding: 4px 10px;
  border-radius: 999px;
}
.step h3 { font-size: 1.1rem; margin: 18px 0 8px; }
.step p { color: var(--text-mut); font-size: 0.93rem; }

/* ===== CTA band ===== */
.cta-band {
  margin: 0 24px;
  border-radius: 28px;
  background:
    radial-gradient(600px 300px at 85% 120%, rgba(79, 147, 221, 0.22), transparent 60%),
    linear-gradient(120deg, rgba(64, 225, 206, 0.14), rgba(79, 147, 221, 0.06)),
    var(--surface);
  border: 1px solid var(--border-hi);
  overflow: hidden;
}
.cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 28px;
  padding-block: 56px;
}
.cta-copy h2 { font-size: clamp(1.8rem, 3.4vw, 2.5rem); }
.cta-copy p { color: var(--text-mut); margin-top: 12px; max-width: 46ch; }
.cta-actions { display: flex; flex-wrap: wrap; gap: 14px; }

/* ===== Footer ===== */
.site-footer { padding: 70px 0 30px; margin-top: 90px; border-top: 1px solid var(--border); background: var(--bg-2); }
.footer-inner { display: grid; grid-template-columns: 1.4fr 2fr; gap: 40px; }
.footer-tag { color: var(--text-mut); margin-top: 16px; max-width: 34ch; font-size: 0.95rem; }
.footer-back-top { display: none; }
.footer-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.footer-col h4 { font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-dim); margin-bottom: 14px; }
.footer-col a { display: block; color: var(--text-mut); font-size: 0.94rem; padding: 5px 0; transition: color 0.2s var(--ease); }
.footer-col a:hover { color: var(--accent); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 50px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  color: var(--text-dim);
  font-size: 0.88rem;
}
.footer-legal a:hover { color: var(--accent); }

/* ===== Prose (privacy policy etc) ===== */
.prose { max-width: 68ch; }
.prose h2 { font-size: 1.3rem; margin: 40px 0 12px; color: var(--text); }
.prose p { color: var(--text-mut); font-size: 0.97rem; line-height: 1.75; margin-bottom: 16px; }
.prose ul { margin: 0 0 16px 20px; display: grid; gap: 8px; }
.prose ul li { color: var(--text-mut); font-size: 0.97rem; list-style: disc; }
.prose a { color: var(--accent); text-decoration: underline; }

/* ===== Services page ===== */
.service-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 72px;
  align-items: start;
}
.service-copy h2 { font-size: clamp(2rem, 3.6vw, 2.8rem); margin: 0 0 10px; color: var(--accent); }
.service-copy--center { max-width: 600px; margin: 0 auto; text-align: center; margin-bottom: 48px; }
.service-copy .service-subtitle { font-size: 1.12rem; color: var(--text); font-weight: 500; margin-bottom: 16px; }
.service-copy p { color: var(--text-mut); font-size: 1.02rem; line-height: 1.7; margin-bottom: 28px; }
.service-features {
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
}
.service-features-label {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-dim);
  margin-bottom: 14px;
}
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 56px;
}
.pricing-block {
  padding: 32px 28px;
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border-right: 1px solid var(--border);
}
.pricing-block:last-child { border-right: none; }
.pricing-block .kicker { margin-bottom: 14px; display: block; font-size: 1rem; color: var(--text); letter-spacing: 0.02em; }
.pricing-price {
  font-family: var(--font-disp);
  font-size: clamp(1.5rem, 2.2vw, 1.9rem);
  font-weight: 700;
  color: var(--accent);
  margin: 0 0 12px;
}
.pricing-detail { color: var(--text-mut); font-size: 0.93rem; margin-bottom: 4px; }
.pricing-footnote {
  font-size: 0.88rem;
  color: var(--text-dim);
  max-width: 62ch;
  margin: 0 auto 32px;
  text-align: center;
  line-height: 1.6;
}
.pricing-cta { display: flex; justify-content: center; padding: 0 0 8px; }

.example-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 40px;
}
.example-card {
  aspect-ratio: 4 / 3;
  background: var(--surface);
  border: 1px dashed var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  padding: 0;
  transition: border-color 0.25s var(--ease), transform 0.25s var(--ease);
  display: block;
  width: 100%;
}
.example-card:hover { border-color: var(--border-hi); transform: translateY(-3px); }
.example-card img { width: 100%; height: 100%; object-fit: cover; display: block; }

.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s var(--ease);
}
.lightbox[hidden] { display: none; }
.lightbox.is-open { opacity: 1; }
.lightbox-img {
  max-width: 90vw;
  max-height: 88vh;
  object-fit: contain;
  border-radius: var(--radius);
  box-shadow: 0 40px 80px rgba(0,0,0,0.8);
}
.lightbox-close {
  position: absolute;
  top: 20px;
  right: 24px;
  font-size: 2rem;
  line-height: 1;
  background: none;
  border: none;
  color: var(--text);
  cursor: pointer;
  opacity: 0.6;
  transition: opacity 0.2s var(--ease);
}
.lightbox-close:hover { opacity: 1; }

/* ===== Enquiry page ===== */
.enquiry-section { padding-top: 20px; }
.enquiry-grid {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 72px;
  align-items: start;
}

.enquiry-form { display: grid; gap: 32px; }
.field-group { display: grid; gap: 24px; }
.enquiry-form button[type="submit"] { justify-self: center; }

.field { display: flex; flex-direction: column; gap: 8px; }
.field label, .field legend {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text);
  padding: 0;
  border: none;
}
.field legend { margin-bottom: 4px; }
.field fieldset, fieldset.field { border: none; padding: 0; margin: 0; }
.field input[type="text"],
.field input[type="email"],
.field textarea {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 0.97rem;
  padding: 12px 16px;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
  width: 100%;
  resize: vertical;
}
.field input::placeholder, .field textarea::placeholder { color: var(--text-dim); }
.field input:focus, .field textarea:focus {
  outline: none;
  border-color: var(--border-hi);
  box-shadow: 0 0 0 3px rgba(64, 225, 206, 0.1);
}
.field--error input, .field--error textarea { border-color: var(--danger); }
.field-error { color: var(--danger); font-size: 0.85rem; margin: 0; }

.check-group { display: flex; flex-direction: column; gap: 10px; }
.check-label {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 0.95rem;
  color: var(--text-mut);
  transition: color 0.2s var(--ease);
}
.check-label:hover { color: var(--text); }
input[type="radio"]:focus,
input[type="radio"]:focus-visible {
  outline: none;
  box-shadow: none;
}
.check-label input[type="radio"] {
  width: 18px;
  height: 18px;
  accent-color: var(--accent);
  cursor: pointer;
  flex-shrink: 0;
}

.form-success {
  background: rgba(64, 225, 206, 0.08);
  border: 1px solid var(--border-hi);
  border-radius: var(--radius-sm);
  color: var(--accent);
  padding: 16px 20px;
  margin-bottom: 32px;
  font-size: 0.97rem;
}

.enquiry-contact { padding-top: 8px; }
.enquiry-contact h3 { font-size: 1.3rem; margin-bottom: 10px; }
.enquiry-contact > p { color: var(--text-mut); font-size: 0.97rem; margin-bottom: 18px; }
.enquiry-email {
  display: inline-block;
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.92rem;
  transition: opacity 0.2s var(--ease);
  margin-bottom: 40px;
}
.enquiry-email:hover { opacity: 0.75; }

.enquiry-next h4 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-dim);
  margin-bottom: 14px;
}
.enquiry-steps {
  list-style: none;
  display: grid;
  gap: 12px;
  counter-reset: step;
}
.enquiry-steps li {
  position: relative;
  padding-left: 32px;
  font-size: 0.93rem;
  color: var(--text-mut);
  counter-increment: step;
}
.enquiry-steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--accent);
  background: rgba(64, 225, 206, 0.08);
  border: 1px solid var(--border-hi);
  border-radius: 50%;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
}


/* ===== Portfolio page ===== */
.page-hero { padding: 170px 0 20px; text-align: center; }
.page-hero h1 { font-size: clamp(2.2rem, 5vw, 3.4rem); font-weight: 700; margin: 18px 0 0; }
.page-hero .lede { margin: 20px auto 0; max-width: 56ch; text-align: center; }
.work-section { padding: 40px 0 100px; }
.work-section .card-grid { max-width: none; }
.work-card { display: flex; flex-direction: column; }
.work-card .tech-list { margin-top: 18px; }
.work-card.is-invite { border-style: dashed; background: transparent; }
.work-tag {
  display: inline-block;
  align-self: flex-start;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid var(--border-hi);
  border-radius: 999px;
  padding: 4px 11px;
}
.work-card .card-foot { margin-top: auto; padding-top: 22px; }
.card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 16px;
}
.card-head .work-tag { margin-bottom: 0; }
.work-logo {
  width: 64px;
  height: 64px;
  object-fit: contain;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
  flex-shrink: 0;
}

.work-tag--studio     { color: var(--accent-2); border-color: rgba(79, 147, 221, 0.35); }
.work-tag--client     { color: var(--accent);   border-color: var(--border-hi); }
.work-tag--assessment { color: #f59e4a;          border-color: rgba(245, 158, 74, 0.35); }
.work-tag--pentest    { color: #fb7185;          border-color: rgba(251, 113, 133, 0.35); }
.work-tag--available  { color: #4ade80;          border-color: rgba(74, 222, 128, 0.35); }

/* ===== Reveal animation ===== */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 1.5s var(--ease), transform 1.5s var(--ease); }
.reveal.in-view { opacity: 1; transform: none; }

/* ===== Responsive ===== */
@media (min-width: 1024px) {
  .work-section .card-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; gap: 40px; }
  .lede { max-width: none; }
  .card-grid { grid-template-columns: 1fr; }

  /* Portfolio carousel */
  .work-section .card-grid {
    display: flex;
    overflow-x: scroll;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    gap: 12px;
    padding: 0 11vw 16px;
    margin: 0 -20px;
  }
  .work-section .card-grid::-webkit-scrollbar { display: none; }
  .work-section .work-card {
    flex: 0 0 78vw;
    scroll-snap-align: center;
    transform: scale(0.92);
    transition: transform 0.3s var(--ease);
  }
  .work-section .work-card.carousel-active {
    transform: scale(1);
  }
  .carousel-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
  }
  .carousel-dot {
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--border-hi);
    transition: background 0.2s var(--ease), transform 0.2s var(--ease);
  }
  .carousel-dot.active {
    background: var(--accent);
    transform: scale(1.3);
  }
  .stack-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 900px) {
  .enquiry-grid { grid-template-columns: 1fr; gap: 48px; }
  .enquiry-contact { text-align: center; }
  .enquiry-next { text-align: left; }
  .enquiry-email { justify-content: center; }
}

@media (max-width: 680px) {
  /* Layout */
  body { overflow-x: hidden; }
  .nav, .header-cta { display: none; }
  .nav-toggle { display: flex; margin-left: auto; }

  /* Hero */
  .hero { padding-top: 100px; padding-bottom: 20px; }
  .hero-copy { text-align: center; }
  .eyebrow { display: inline-flex; }
  .lede { margin-left: auto; margin-right: auto; text-align: left; }
  .hero-actions { flex-direction: column; align-items: center; }
  .hero-actions .btn { width: 80%; justify-content: center; }

  /* Trust strip */
  .trust-strip { display: none; }
  .trust-logos { margin-left: 0; }

  /* Sections */
  .section { padding: 48px 0; }
  .section-stack { padding-bottom: 12px; }
  #services { border-top: 1px solid var(--accent); }
  .page-hero { padding-top: 100px; }
  .steps { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; }

  /* Stack accordion */
  .stack-grid { grid-template-columns: 1fr; gap: 0; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
  .stack-group {
    border: none;
    border-bottom: 1px solid var(--border);
    border-radius: 0;
    padding: 0;
    transform: none !important;
    transition: none;
  }
  .stack-group:last-child { border-bottom: none; }
  .stack-cat {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0;
    padding: 16px 20px;
    border-bottom: none;
    cursor: pointer;
    user-select: none;
  }
  .stack-cat::after {
    content: "+";
    font-size: 1.2rem;
    font-weight: 400;
    color: var(--text-dim);
    transition: transform 0.25s var(--ease);
  }
  .stack-group.open .stack-cat::after { transform: rotate(45deg); }
  .tech-list {
    max-height: 0;
    overflow: hidden;
    padding: 0 20px;
    transition: max-height 0.3s var(--ease), padding 0.3s var(--ease);
  }
  .stack-group.open .tech-list { max-height: 300px; padding: 0 20px 16px; }

  /* Tech badges marquee */
  .tech-badges-wrap {
    overflow: hidden;
    margin-top: 36px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
    -webkit-mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
    mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
  }
  .tech-badges {
    flex-wrap: nowrap;
    width: max-content;
    margin-top: 0;
    padding-top: 0;
    border-top: none;
    gap: 0 40px;
    animation: marquee-scroll 20s linear infinite;
  }
  .tech-badge { min-width: auto; gap: 6px; }
  .tech-badge svg { width: 24px; height: 24px; }
  .tech-badge span { font-size: 0.65rem; }
  @keyframes marquee-scroll {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
  }

  /* Services */
  .service-split { grid-template-columns: 1fr; gap: 36px; }
  .service-copy { text-align: center; }
  .service-copy .btn { display: inline-block; }
  .example-grid {
    display: flex;
    overflow-x: scroll;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    gap: 12px;
    margin: 40px -20px 0;
    padding: 0 20px;
  }
  .example-grid::-webkit-scrollbar { display: none; }
  .example-card { flex: 0 0 360px; scroll-snap-align: center; width: 360px; }
  .pricing-grid { grid-template-columns: 1fr; border: none; gap: 12px; overflow: visible; }
  .pricing-block { border: 1px solid var(--border); border-radius: var(--radius); }
  .pricing-block:last-child { border-right: 1px solid var(--border); }

  /* Portfolio carousel */
  .work-section .card-grid {
    display: flex;
    overflow-x: scroll;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    gap: 12px;
    padding: 0 11vw 16px;
    margin: 0 -20px;
  }
  .work-section .card-grid::-webkit-scrollbar { display: none; }
  .work-section .work-card { flex: 0 0 78vw; scroll-snap-align: center; transform: scale(0.92); transition: transform 0.3s var(--ease); }
  .work-section .work-card.carousel-active { transform: scale(1); }
  .carousel-dots { display: flex; justify-content: center; gap: 8px; margin-top: 20px; }
  .carousel-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--border-hi); transition: background 0.2s var(--ease), transform 0.2s var(--ease); }
  .carousel-dot.active { background: var(--accent); transform: scale(1.3); }

  /* CTA band */
  .cta-band { margin: 0 16px; }
  .cta-inner { flex-direction: column; align-items: center; text-align: center; }
  .cta-copy p { margin-left: auto; margin-right: auto; }
  .cta-actions { justify-content: center; }

  /* Footer */
  .footer-brand { display: flex; justify-content: center; transform: translateX(-20px); }
  .footer-cols { display: none; }
  .footer-back-top {
    display: block;
    color: var(--text-mut);
    font-size: 0.9rem;
    text-align: center;
    padding: 10px 0;
    transition: color 0.2s var(--ease);
  }
  .footer-back-top:hover { color: var(--accent); }
  .footer-bottom { flex-direction: column; align-items: center; text-align: center; border-top: none; margin-top: 0; }
  .site-footer { padding: 32px 0 24px; margin-top: 48px; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}
