/* =========================================================================
   XRayDetect — design system
   Built on the deliverable brand templates (deliverables/pages).
   Brand: Technical Blue #15346B · X-Ray Cyan #16B8CC · Ink #0E1419 · Paper #F5F7F9
   Dark surfaces: Deep Navy #0C2147 · Hero Navy #07142B
   Type:  Space Grotesk (display) · IBM Plex Sans (body) · IBM Plex Mono (labels)
   ========================================================================= */

/* ----- Tokens ----------------------------------------------------------- */
:root {
  --bg:          #f5f7f9;
  --surface:     #ffffff;
  --surface-2:   #eef2f6;

  --navy:        #07142b;   /* hero navy */
  --navy-2:      #0c2147;   /* deep navy panels */
  --navy-3:      #14478a;   /* hero gradient top */
  --panel-dark:  #06182f;   /* media panel */

  --border:        #e4e9ee;
  --border-strong: #d4dce4;
  --border-blue:   #15346b;
  --border-cyan:   rgba(22, 184, 204, 0.34);

  --ink:         #0e1419;
  --text:        #37434f;
  --text-dim:    #5c6b7a;
  --muted:       #5c6b7a;
  --muted-2:     #9aa7b3;

  --on-dark:       #ffffff;
  --on-dark-dim:   #c5d2e2;
  --on-dark-mut:   #8fa6c2;
  --on-dark-cyan:  #5fd3e4;
  --on-dark-line:  rgba(255, 255, 255, 0.12);

  --blue:        #15346b;
  --blue-deep:   #0c2147;
  --cyan:        #16b8cc;
  --cyan-bright: #37c9da;
  --cyan-deep:   #1296a8;

  --radius:      12px;
  --radius-sm:   6px;
  --radius-lg:   16px;
  --shadow:      0 24px 60px -28px rgba(7, 20, 43, 0.30);
  --shadow-soft: 0 14px 36px -22px rgba(7, 20, 43, 0.20);

  --maxw:        1280px;
  --gutter:      clamp(20px, 5vw, 56px);

  --font-head: "Space Grotesk", "Segoe UI", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --font-body: "IBM Plex Sans", "Segoe UI", system-ui, -apple-system, sans-serif;

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

/* ----- Reset ------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
::selection { background: #16b8cc; color: #06243f; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 4px; }

/* ----- Layout ----------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.section { padding-block: clamp(56px, 8vw, 96px); }
.section--tight { padding-block: clamp(40px, 5vw, 64px); }
.divider { height: 1px; border: 0; background: var(--border); margin: 0; }

/* ----- Typography ------------------------------------------------------- */
h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--ink);
}
h1 { font-size: clamp(2.3rem, 5vw, 3.9rem); letter-spacing: -0.03em; line-height: 1.04; }
h2 { font-size: clamp(1.7rem, 3.6vw, 2.65rem); }
h3 { font-size: clamp(1.2rem, 2vw, 1.5rem); }
h4 { font-size: 1.05rem; }
p { color: var(--text); }
strong { color: var(--ink); font-weight: 600; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--cyan-deep);
}
.lead { font-size: clamp(1.05rem, 1.5vw, 1.18rem); color: var(--text); max-width: 56ch; line-height: 1.6; }
.text-cyan { color: var(--blue); font-weight: 600; }

/* ----- Buttons ---------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55em;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1rem;
  padding: 0.95em 1.6em;
  border-radius: var(--radius-sm);
  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), color 0.2s;
  white-space: nowrap;
}
.btn .arrow { transition: transform 0.25s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }
.btn--primary { background: var(--blue); color: #fff; }
.btn--primary:hover { background: var(--blue-deep); transform: translateY(-2px); }
.btn--ghost { background: var(--surface); border-color: var(--border-strong); color: var(--ink); }
.btn--ghost:hover { border-color: var(--blue); transform: translateY(-2px); }
.btn--block { width: 100%; justify-content: center; }

/* On dark surfaces: primary -> cyan, ghost -> light outline */
.hero .btn--primary, .cta .btn--primary, .page-hero .btn--primary {
  background: var(--cyan); color: #06243f;
}
.hero .btn--primary:hover, .cta .btn--primary:hover, .page-hero .btn--primary:hover {
  background: var(--cyan-bright); color: #06243f;
}
.hero .btn--ghost, .cta .btn--ghost, .page-hero .btn--ghost {
  background: transparent; border-color: rgba(255, 255, 255, 0.28); color: #fff;
}
.hero .btn--ghost:hover, .cta .btn--ghost:hover, .page-hero .btn--ghost:hover {
  border-color: #fff; background: rgba(255, 255, 255, 0.06);
}

/* ----- Header ----------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(245, 247, 249, 0.85);
  backdrop-filter: saturate(150%) blur(12px);
  -webkit-backdrop-filter: saturate(150%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.site-header__bar { display: flex; align-items: center; gap: 24px; height: 72px; }
.brand { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.brand img { height: 32px; width: auto; }

.nav { display: flex; align-items: center; gap: clamp(18px, 2.4vw, 34px); margin-left: auto; }
.nav a {
  position: relative;
  font-size: 0.94rem; font-weight: 500;
  color: var(--text-dim);
  padding: 6px 0;
  transition: color 0.2s;
}
.nav a:hover { color: var(--blue); }
.nav a.is-active { color: var(--blue); }
.nav a.is-active::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px;
  height: 2px; background: var(--cyan); border-radius: 2px;
}
.nav a.btn--primary { padding: 0.7em 1.3em; color: #fff; }
.nav a.btn--primary.is-active { color: #fff; }
.nav a.btn--primary.is-active::after { content: none; }
.nav a.btn--primary:hover { background: var(--blue-deep); color: #fff; }

.header-tools { display: flex; align-items: center; gap: 10px; flex-shrink: 0; margin-left: auto; }
.burger {
  display: none; width: 42px; height: 42px;
  border: 1px solid var(--border-strong); border-radius: 8px;
  background: var(--surface); cursor: pointer; padding: 0; position: relative;
}
.burger span, .burger span::before, .burger span::after {
  content: ""; position: absolute; left: 50%; top: 50%;
  width: 18px; height: 2px; background: var(--ink);
  transform: translate(-50%, -50%); transition: transform 0.25s var(--ease), opacity 0.2s;
}
.burger span::before { transform: translate(-50%, -7px); }
.burger span::after  { transform: translate(-50%, 5px); }
body.nav-open .burger span { background: transparent; }
body.nav-open .burger span::before { transform: translate(-50%, -50%) rotate(45deg); }
body.nav-open .burger span::after  { transform: translate(-50%, -50%) rotate(-45deg); }

/* ----- Dark hero (home) ------------------------------------------------- */
.hero {
  position: relative; overflow: hidden; color: var(--on-dark);
  background: radial-gradient(120% 130% at 82% -10%, var(--navy-3) 0%, var(--navy-2) 50%, var(--navy) 100%);
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 46px 46px;
}
.hero::after {
  content: ""; position: absolute; right: -80px; top: -120px; z-index: 0;
  width: 520px; height: 520px; pointer-events: none;
  background: radial-gradient(circle, rgba(34, 178, 204, 0.26) 0%, rgba(34, 178, 204, 0) 60%);
}
.hero > .container { position: relative; z-index: 1; }
.hero h1, .hero h2 { color: #fff; }
.hero p { color: var(--on-dark-dim); }
.hero strong { color: #fff; }
.hero .eyebrow { color: var(--on-dark-cyan); }

.hero__inner {
  display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 56px; align-items: center;
  padding-block: clamp(56px, 8vw, 88px) clamp(48px, 6vw, 72px);
}
.hero__copy h1 { margin-top: 20px; max-width: 14ch; }
.hero__copy .lead { margin-top: 22px; color: var(--on-dark-dim); max-width: 52ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }
.hero__media { position: relative; }

/* radiograph mock panel (no photo needed) */
.scope {
  position: relative;
  border: 1px solid rgba(95, 211, 228, 0.3);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--panel-dark);
}
.scope__bar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; border-bottom: 1px solid rgba(95, 211, 228, 0.18);
  font-family: var(--font-mono); font-size: 0.69rem; letter-spacing: 0.12em; color: var(--on-dark-cyan);
}
.scope__bar .dim { color: #7e90a6; }
.scope__view {
  position: relative; height: 380px; overflow: hidden;
  background:
    radial-gradient(60% 80% at 50% 45%, rgba(95, 211, 228, 0.16), transparent 70%),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.025) 0 2px, transparent 2px 5px),
    linear-gradient(180deg, #0a2138, #06182f);
}
.scope__view::before {
  /* faux organic/metal blobs */
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(22% 30% at 38% 42%, rgba(255, 150, 60, 0.22), transparent 70%),
    radial-gradient(16% 22% at 62% 58%, rgba(120, 200, 255, 0.20), transparent 70%),
    radial-gradient(10% 14% at 56% 40%, rgba(70, 240, 160, 0.30), transparent 70%);
  mix-blend-mode: screen;
}
.scope__scan {
  position: absolute; top: 0; bottom: 0; width: 26%;
  background: linear-gradient(90deg, transparent, rgba(95, 211, 228, 0.5), transparent);
  filter: blur(2px);
  animation: scopescan 5.5s var(--ease) infinite;
}
@keyframes scopescan {
  0% { transform: translateX(-120%); } 50% { transform: translateX(380%); } 100% { transform: translateX(-120%); }
}
.scope__strip { position: absolute; left: 0; right: 0; bottom: 0; }
.scope__badge {
  position: absolute; left: -20px; bottom: -22px; z-index: 2;
  display: flex; align-items: center; gap: 13px;
  background: #fff; color: var(--ink);
  border-radius: 10px; padding: 14px 18px; box-shadow: 0 18px 40px rgba(6, 20, 47, 0.35);
}
.scope__badge img { width: 36px; height: 36px; flex: none; }
.scope__badge b { font-family: var(--font-head); font-weight: 600; font-size: 0.98rem; display: block; line-height: 1.2; }
.scope__badge span { font-family: var(--font-mono); font-size: 0.66rem; color: var(--muted); letter-spacing: 0.06em; white-space: nowrap; }

/* ----- Stat / capability strip ----------------------------------------- */
.statstrip {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--on-dark-line);
}
.statstrip > div { padding: 26px 30px; }
.statstrip > div:first-child { padding-left: 0; }
.statstrip > div + div { border-left: 1px solid var(--on-dark-line); }
.statstrip__k { font-family: var(--font-head); font-weight: 600; font-size: 1.55rem; color: #fff; letter-spacing: -0.01em; }
.statstrip__v {
  font-family: var(--font-mono); font-size: 0.66rem; letter-spacing: 0.1em;
  color: var(--on-dark-mut); margin-top: 5px; text-transform: uppercase;
}

/* ----- Section heads ---------------------------------------------------- */
.section-head { margin-bottom: clamp(32px, 4vw, 48px); }
.section-head .eyebrow { color: var(--cyan); }
.section-head h2 { margin-top: 14px; max-width: 20ch; }
.section-head p { margin-top: 14px; color: var(--text-dim); max-width: 56ch; }
.section-head--center { text-align: center; }
.section-head--center h2, .section-head--center p { margin-inline: auto; }
.section-head--center .eyebrow { justify-content: center; display: flex; }
/* split head: title left, intro right */
.head-split { display: flex; align-items: flex-end; justify-content: space-between; gap: 32px; flex-wrap: wrap; margin-bottom: clamp(32px, 4vw, 48px); }
.head-split .eyebrow { color: var(--cyan); }
.head-split h2 { margin-top: 14px; }
.head-split p { max-width: 38ch; color: var(--text-dim); font-size: 0.96rem; }

/* ----- Generic cards ---------------------------------------------------- */
.grid { display: grid; gap: 24px; }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }

.card {
  position: relative; background: var(--surface);
  border: 1px solid var(--border); border-radius: 10px;
  padding: 34px;
  transition: border-color 0.25s, box-shadow 0.25s, transform 0.25s var(--ease);
}
.card:hover { border-color: var(--border-blue); box-shadow: var(--shadow-soft); }
.card__icon {
  display: inline-grid; place-items: center;
  width: 46px; height: 46px; border-radius: 10px;
  background: rgba(22, 184, 204, 0.1); border: 1px solid var(--border-cyan);
  font-size: 1.4rem; margin-bottom: 16px;
}
.card h3 { margin-bottom: 10px; }
.card p { font-size: 0.95rem; color: var(--text-dim); }
.card__link {
  display: inline-flex; align-items: center; gap: 0.5em; margin-top: 18px;
  font-family: var(--font-mono); font-weight: 600; font-size: 0.74rem;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--blue);
}
.card:hover .card__link .arrow { transform: translateX(4px); }
.card__num { font-family: var(--font-mono); font-size: 0.82rem; font-weight: 600; color: var(--cyan); letter-spacing: 0.06em; }

/* numbered service card (deliverable style) */
.svc-card { display: flex; flex-direction: column; gap: 14px; }
.svc-card__top { display: flex; align-items: center; justify-content: space-between; }
.svc-card__icon { width: 34px; height: 34px; flex: none; }
.svc-card h3 { margin: 4px 0 0; font-size: 1.45rem; }
.svc-card p { margin: 0; }
.svc-card .card__link { margin-top: auto; padding-top: 6px; }

/* ----- Dark panel (industries / deliverables) --------------------------- */
.panel--dark {
  position: relative; overflow: hidden; color: var(--on-dark);
  background: var(--navy-2); border-radius: var(--radius-lg); padding: clamp(34px, 5vw, 56px);
}
.panel--dark::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 40px 40px;
}
.panel--dark > * { position: relative; }
.panel--dark h2 { color: #fff; }
.panel--dark .eyebrow { color: var(--on-dark-cyan); }
.panel--dark p { color: #b7c6d9; }
.panel-split { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: 48px; align-items: center; }
.panel-split h2 { margin: 14px 0 16px; font-size: clamp(1.6rem, 3vw, 2.2rem); }

.chips { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.chip {
  border: 1px solid var(--on-dark-line); border-radius: 8px; padding: 18px 20px;
  font-weight: 600; font-size: 0.98rem; color: #fff;
}
.cards-dark { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card-dark { border: 1px solid var(--on-dark-line); border-radius: 10px; padding: 28px; }
.card-dark h4 { color: #fff; font-size: 1.22rem; }
.card-dark p { color: #b7c6d9; font-size: 0.9rem; margin-top: 10px; }

/* ----- Process timeline ------------------------------------------------- */
.timeline {
  list-style: none; padding: 0; counter-reset: tl;
  display: grid; grid-template-columns: repeat(5, 1fr); border-top: 2px solid var(--border);
}
.timeline li {
  counter-increment: tl; position: relative; padding: 32px 26px 0 0; padding-inline-end: 26px;
}
.timeline li + li { border-left: 1px solid var(--border); padding-inline-start: 26px; }
.timeline li::before {
  content: ""; position: absolute; top: -9px; left: 0; width: 16px; height: 16px;
  border-radius: 50%; background: var(--blue); border: 3px solid var(--bg);
}
.timeline li:first-child::before { background: var(--cyan); }
.timeline li + li::before { left: 26px; }
.timeline__step { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.08em; color: var(--muted-2); text-transform: uppercase; }
.timeline h3 { font-size: 1.18rem; margin: 10px 0 8px; }
.timeline p { font-size: 0.9rem; color: var(--text-dim); }

/* ----- Keyword bar (replaces 'standards' row) -------------------------- */
.kbar {
  border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  padding: 30px 0; display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 20px;
}
.kbar__label { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.16em; color: var(--muted-2); text-transform: uppercase; }
.kbar__items { display: flex; align-items: center; gap: clamp(20px, 3vw, 40px); flex-wrap: wrap;
  font-family: var(--font-head); font-weight: 600; font-size: 1.05rem; color: var(--text-dim); }

/* ----- Feature / bullet lists ------------------------------------------ */
.ticks { list-style: none; padding: 0; display: grid; gap: 13px; }
.ticks li { position: relative; padding-left: 28px; color: var(--text-dim); }
.ticks li::before {
  content: ""; position: absolute; left: 0; top: 0.5em;
  width: 9px; height: 9px; background: var(--cyan); transform: rotate(45deg);
}
.ticks strong { color: var(--ink); }
.ticks a { color: var(--blue); border-bottom: 1px solid var(--border-cyan); }
.ticks a:hover { color: var(--cyan-deep); }

/* checklist (two-column diamond list, deliverable style) */
.checklist { list-style: none; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.checklist li { display: flex; align-items: center; gap: 12px; font-size: 0.96rem; font-weight: 500; color: var(--ink); }
.checklist li::before { content: ""; width: 8px; height: 8px; background: var(--cyan); transform: rotate(45deg); flex: none; }

/* numbered process (fallback / interior pages) */
.steps { list-style: none; padding: 0; counter-reset: s; display: grid; gap: 16px; }
.steps li {
  counter-increment: s; position: relative; padding: 20px 22px 20px 64px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 10px;
}
.steps li::before {
  content: counter(s, decimal-leading-zero); position: absolute; left: 22px; top: 18px;
  font-family: var(--font-mono); font-size: 0.95rem; font-weight: 600; color: var(--cyan-deep);
}
.steps strong { display: block; color: var(--ink); margin-bottom: 3px; }

/* ----- Quick-facts panel (service hero side) --------------------------- */
.qfacts {
  background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius); padding: 28px;
}
.qfacts__h { font-family: var(--font-mono); font-size: 0.69rem; letter-spacing: 0.16em; color: var(--on-dark-cyan); text-transform: uppercase; margin-bottom: 18px; }
.qfacts dl { display: grid; gap: 16px; font-family: var(--font-mono); font-size: 0.82rem; color: #fff; }
.qfacts dl > div { display: flex; justify-content: space-between; gap: 16px; padding-bottom: 14px; border-bottom: 1px solid rgba(255, 255, 255, 0.1); }
.qfacts dl > div:last-child { border-bottom: 0; padding-bottom: 0; }
.qfacts dt { color: var(--on-dark-mut); }

/* ----- Tables ----------------------------------------------------------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: 0.93rem; }
thead th {
  background: var(--surface-2); text-align: left;
  font-family: var(--font-mono); font-size: 0.72rem; font-weight: 500; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--blue); padding: 14px 18px; border-bottom: 1px solid var(--border);
}
tbody td { padding: 13px 18px; border-bottom: 1px solid var(--border); color: var(--text-dim); vertical-align: top; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: rgba(22, 184, 204, 0.04); }
td strong, th strong { color: var(--ink); }

/* ----- Diagram / code panel (ASCII) — dark terminal --------------------- */
.diagram {
  background: var(--navy-2); border: 1px solid var(--navy-2);
  border-radius: 10px; padding: 22px 24px; overflow-x: auto; position: relative;
}
.diagram::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--cyan); }
.diagram pre { font-family: var(--font-mono); font-size: 0.84rem; line-height: 1.7; color: var(--on-dark-cyan); white-space: pre; }

/* ----- Flow diagram ----------------------------------------------------- */
.flow { display: flex; flex-direction: column; align-items: center; gap: 0; margin-block: 8px; }
.flow__node { width: 100%; max-width: 440px; background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 18px 24px; text-align: center; }
.flow__node h4 { font-size: 1.06rem; color: var(--ink); }
.flow__node p { font-size: 0.85rem; color: var(--muted); margin-top: 5px; }
.flow__tag { display: block; font-family: var(--font-mono); font-size: 0.64rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--cyan-deep); margin-bottom: 6px; }
.flow__node--lead { border-color: var(--border-blue); box-shadow: 0 0 0 1px var(--border-blue); }
.flow__node--out { background: rgba(22, 184, 204, 0.07); border-color: var(--border-cyan); }
.flow__step { display: flex; align-items: center; gap: 14px; min-height: 44px; }
.flow__arrow { display: block; position: relative; width: 2px; height: 42px; background: linear-gradient(180deg, var(--cyan), rgba(22, 184, 204, 0.2)); }
.flow__arrow::after { content: ""; position: absolute; bottom: 0; left: 50%; width: 8px; height: 8px; border-right: 2px solid var(--cyan); border-bottom: 2px solid var(--cyan); transform: translate(-50%, 2px) rotate(45deg); }
.flow__note { font-family: var(--font-mono); font-size: 0.72rem; color: var(--muted); max-width: 30ch; }
.flow__pair { display: flex; align-items: center; justify-content: center; width: 100%; max-width: 800px; }
.flow__pair .flow__node { max-width: none; flex: 1 1 0; }
.flow__link { position: relative; flex: 0 0 auto; display: grid; place-items: center; width: 46px; height: 46px; margin: 0 18px; border-radius: 50%; background: rgba(22, 184, 204, 0.12); border: 1px solid var(--border-cyan); color: var(--cyan-deep); font-size: 1.2rem; z-index: 2; }
.flow__link::before, .flow__link::after { content: ""; position: absolute; top: 50%; width: 18px; height: 2px; background: var(--cyan); }
.flow__link::before { right: 100%; } .flow__link::after { left: 100%; }
@media (max-width: 620px) {
  .flow__pair { flex-direction: column; } .flow__pair .flow__node { width: 100%; }
  .flow__link { transform: rotate(90deg); margin: 14px 0; } .flow__link::before, .flow__link::after { display: none; }
  .flow__step { flex-direction: column; gap: 6px; text-align: center; } .flow__note { max-width: none; }
}

/* ----- Pipeline --------------------------------------------------------- */
.pipeline { list-style: none; padding: 0; margin-block: 10px; display: flex; flex-wrap: wrap; align-items: stretch; justify-content: center; gap: 18px 32px; }
.pipeline__step { position: relative; flex: 0 1 auto; display: flex; flex-direction: column; justify-content: center; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 12px 16px; min-height: 54px; }
.pipeline__step:not(:last-child)::before { content: ""; position: absolute; right: -30px; top: 50%; width: 21px; height: 2px; background: var(--cyan); transform: translateY(-50%); }
.pipeline__step:not(:last-child)::after { content: ""; position: absolute; right: -22px; top: 50%; width: 8px; height: 8px; border-top: 2px solid var(--cyan); border-right: 2px solid var(--cyan); transform: translateY(-50%) rotate(45deg); }
.pipeline__k { font-family: var(--font-head); font-weight: 600; font-size: 0.92rem; color: var(--ink); line-height: 1.25; }
.pipeline__sub { font-family: var(--font-mono); font-size: 0.66rem; color: var(--muted); margin-top: 4px; }
.pipeline__step--in { border-color: var(--border-blue); }
.pipeline__step--out { background: rgba(22, 184, 204, 0.07); border-color: var(--border-cyan); }
@media (max-width: 620px) {
  .pipeline { flex-direction: column; align-items: stretch; gap: 30px 0; }
  .pipeline__step:not(:last-child)::before { right: auto; left: 50%; top: auto; bottom: -22px; width: 2px; height: 14px; transform: translateX(-50%); }
  .pipeline__step:not(:last-child)::after { right: auto; left: 50%; top: auto; bottom: -19px; border-top: 0; border-left: 0; border-right: 2px solid var(--cyan); border-bottom: 2px solid var(--cyan); transform: translateX(-50%) rotate(45deg); }
}

/* ----- Note / callout --------------------------------------------------- */
.note { border-left: 3px solid var(--cyan); background: rgba(22, 184, 204, 0.07); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; padding: 18px 22px; color: var(--text-dim); }
.note strong { color: var(--blue); }

/* ----- Prose ------------------------------------------------------------ */
.prose { max-width: 78ch; }
.prose > * + * { margin-top: 1.1em; }
.prose > :first-child { margin-top: 0; padding-top: 0; }
.prose p { color: var(--text); }
.prose h2 { margin-top: 2.2em; padding-top: 0.4em; }
.prose h3 { margin-top: 1.8em; color: var(--blue); }
.prose h2 + p, .prose h3 + p, .prose h2 + .ticks, .prose h3 + .ticks { margin-top: 0.8em; }
.prose a:not(.btn):not(.card__link) { color: var(--blue); border-bottom: 1px solid var(--border-cyan); transition: color 0.2s, border-color 0.2s; }
.prose a:not(.btn):not(.card__link):hover { color: var(--cyan-deep); border-color: var(--cyan); }
.prose ul:not(.ticks):not(.steps):not(.checklist) { padding-left: 1.3em; display: grid; gap: 0.5em; }
.prose ul:not(.ticks):not(.steps):not(.checklist) li { color: var(--text-dim); }
.prose ul:not(.ticks):not(.steps):not(.checklist) li::marker { color: var(--cyan); }
.prose .table-wrap, .prose .diagram, .prose .note { margin-block: 1.6em; }
.prose code { font-family: var(--font-mono); font-size: 0.86em; background: var(--surface-2); padding: 0.15em 0.45em; border-radius: 5px; color: var(--blue); }

/* ----- Page hero (interior pages) — dark navy, template style ---------- */
.page-hero {
  position: relative; overflow: hidden; color: var(--on-dark);
  background: radial-gradient(120% 140% at 85% -20%, var(--navy-3) 0%, var(--navy-2) 52%, var(--navy) 100%);
  padding-block: clamp(40px, 6vw, 56px) clamp(56px, 8vw, 80px);
}
.page-hero::before {
  content: ""; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.045) 1px, transparent 1px);
  background-size: 46px 46px;
}
.page-hero::after {
  content: ""; position: absolute; right: -60px; top: -140px; z-index: 0;
  width: 480px; height: 480px; pointer-events: none;
  background: radial-gradient(circle, rgba(34,178,204,0.24) 0%, rgba(34,178,204,0) 60%);
}
.page-hero > .container { position: relative; z-index: 1; }
.page-hero h1, .page-hero h2 { color: #fff; }
.page-hero h1 { margin-top: 18px; max-width: 18ch; }
.page-hero p { color: var(--on-dark-dim); }
.page-hero .lead { color: var(--on-dark-dim); margin-top: 18px; }
.page-hero strong { color: #fff; }
.page-hero .eyebrow { color: var(--on-dark-cyan); }
.page-hero a:not(.btn):not(.breadcrumb a) { color: var(--on-dark-cyan); }
/* white bold text on all dark surfaces */
.cta strong, .panel--dark strong, .nf strong { color: #fff; }
.cta a:not(.btn), .panel--dark a:not(.btn) { color: var(--on-dark-cyan); }
.page-hero__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 32px; }
/* split service hero with quick-facts */
.page-hero__grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 56px; align-items: end; }
.breadcrumb { font-family: var(--font-mono); font-size: 0.74rem; letter-spacing: 0.06em; color: var(--on-dark-mut); display: flex; gap: 0.5em; flex-wrap: wrap; }
.breadcrumb a { color: var(--on-dark-mut); }
.breadcrumb a:hover { color: #fff; }
.breadcrumb span { color: var(--on-dark-cyan); }

/* ----- CTA band --------------------------------------------------------- */
.cta {
  position: relative; overflow: hidden; color: var(--on-dark);
  background: radial-gradient(110% 160% at 85% 0%, var(--cyan) 0%, var(--blue) 42%, var(--navy-2) 100%);
  border-radius: var(--radius-lg); padding: clamp(40px, 5vw, 64px);
}
.cta::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 44px 44px;
}
.cta > * { position: relative; }
.cta h2 { color: #fff; max-width: 20ch; }
.cta p { color: #d7e3f0; margin-top: 14px; max-width: 54ch; }
.cta .eyebrow { color: var(--on-dark-cyan); }
.cta__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; }
.cta--split { display: flex; align-items: center; justify-content: space-between; gap: 40px; flex-wrap: wrap; }
.cta--split .cta__actions { margin-top: 0; flex-direction: column; }

/* ----- Stats (interior) ------------------------------------------------- */
.stat { padding: 22px; }
.stat__k { font-family: var(--font-head); font-size: 1.9rem; font-weight: 600; color: var(--blue); }
.stat__v { color: var(--muted); font-size: 0.9rem; margin-top: 4px; }

/* ----- Footer ----------------------------------------------------------- */
.site-footer { background: var(--navy); color: #9db0c6; padding-block: clamp(48px, 6vw, 64px) 36px; margin-top: clamp(48px, 7vw, 88px); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; padding-bottom: 48px; border-bottom: 1px solid var(--on-dark-line); }
.site-footer .brand img { height: 32px; }
.footer-about p { margin-top: 20px; font-size: 0.88rem; color: #8295ad; max-width: 32ch; line-height: 1.6; }
.footer-col h4 { font-family: var(--font-mono); font-size: 0.69rem; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); margin-bottom: 16px; }
.footer-col ul { list-style: none; padding: 0; display: grid; gap: 10px; }
.footer-col a { color: var(--on-dark-dim); font-size: 0.88rem; transition: color 0.2s; }
.footer-col a:hover { color: #fff; }
.footer-col .muted { color: #8295ad; }
.footer-bottom { display: flex; flex-wrap: wrap; gap: 14px; justify-content: space-between; align-items: center; margin-top: 24px; font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.08em; color: var(--muted); }

/* utility */
.mt-s { margin-top: 14px; } .mt-m { margin-top: 28px; } .mt-l { margin-top: 48px; }
.center { text-align: center; }
.maxw-sm { max-width: 720px; }
.muted { color: var(--muted); }

/* ----- detector strip (subtle pixel motif, used in scope) -------------- */
.detector-strip { display: flex; gap: 3px; height: 6px; width: 100%; overflow: hidden; opacity: 0.9; }
.detector-strip i { flex: 1 1 auto; background: #1a4d82; }
.detector-strip i:nth-child(3n) { background: #1e9bba; }
.detector-strip i:nth-child(4n) { background: #16b8cc; }
.detector-strip i:nth-child(7n) { background: #22b2cc; }
.detector-strip i:nth-child(11n) { background: #45d8e8; }

/* ----- 404 -------------------------------------------------------------- */
.notfound { text-align: center; padding-block: clamp(64px, 10vw, 130px); }
.nf { margin-inline: auto; max-width: 760px; }
.nf .eyebrow { justify-content: center; display: flex; color: var(--on-dark-cyan); }
.nf__scanner { position: relative; display: inline-block; margin: 10px auto 2px; --lens: clamp(88px, 22vw, 180px); touch-action: none; cursor: crosshair; }
.nf__digits { font-family: var(--font-head); font-weight: 600; font-size: clamp(6.5rem, 30vw, 17rem); line-height: 0.92; letter-spacing: -0.045em; user-select: none; -webkit-user-select: none; }
.nf__digits--raw { color: transparent; -webkit-text-stroke: 1.5px rgba(255, 255, 255, 0.18); text-stroke: 1.5px rgba(255, 255, 255, 0.18); }
.nf__digits--xray { position: absolute; inset: 0; color: var(--on-dark-cyan); text-shadow: 0 0 22px rgba(22, 184, 204, 0.5), 0 0 64px rgba(22, 184, 204, 0.3); -webkit-mask: radial-gradient(circle var(--lens) at var(--mx, 50%) var(--my, 50%), #000 36%, transparent 68%); mask: radial-gradient(circle var(--lens) at var(--mx, 50%) var(--my, 50%), #000 36%, transparent 68%); }
.nf__readout { position: absolute; top: 10px; right: 10px; font-family: var(--font-mono); font-size: 0.62rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--on-dark-cyan); background: rgba(6, 24, 47, 0.6); border: 1px solid rgba(95, 211, 228, 0.3); border-radius: 6px; padding: 4px 9px; pointer-events: none; white-space: nowrap; }
.nf h1 { color: #fff; margin-top: 6px; max-width: 22ch; margin-inline: auto; }
.nf .lead { color: var(--on-dark-dim); margin-inline: auto; margin-top: 16px; }
.nf__path { font-family: var(--font-mono); font-size: 0.82rem; color: var(--on-dark-mut); margin-top: 18px; word-break: break-all; }
.nf__path b { color: var(--on-dark-cyan); font-weight: 500; }
.nf .page-hero__actions { justify-content: center; }

/* ----- Responsive ------------------------------------------------------- */
@media (max-width: 980px) {
  .hero__inner, .panel-split, .page-hero__grid { grid-template-columns: 1fr; gap: 36px; }
  .statstrip { grid-template-columns: repeat(2, 1fr); }
  .statstrip > div:nth-child(3) { border-left: 0; }
  .statstrip > div { border-top: 1px solid var(--on-dark-line); }
  .statstrip > div:nth-child(-n+2) { border-top: 0; }
  .grid--3, .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .chips, .cards-dark { grid-template-columns: repeat(2, 1fr); }
  .timeline { grid-template-columns: repeat(2, 1fr); border-top: 0; }
  .timeline li { border-left: 0 !important; padding-inline: 0 !important; border-top: 2px solid var(--border); }
  .timeline li::before { left: 0 !important; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .footer-about { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .nav { display: none; }
  .burger { display: block; }
  .site-header__bar { height: 64px; }
  .nav.is-mobile {
    display: flex; position: fixed; inset: 64px 0 auto 0; flex-direction: column; align-items: stretch;
    gap: 0; margin: 0; padding: 12px var(--gutter) 24px; background: rgba(245, 247, 249, 0.98);
    backdrop-filter: blur(16px); border-bottom: 1px solid var(--border);
    transform: translateY(-12px); opacity: 0; pointer-events: none;
    transition: opacity 0.25s, transform 0.25s var(--ease); max-height: calc(100vh - 64px); overflow-y: auto;
  }
  body.nav-open .nav.is-mobile { opacity: 1; transform: none; pointer-events: auto; }
  .nav.is-mobile a { padding: 0.95em 0.2em; font-size: 1.05rem; border-bottom: 1px solid var(--border); }
  .nav.is-mobile a.is-active::after { display: none; }
  .nav.is-mobile .btn--primary { margin-top: 16px; justify-content: center; }
  .checklist { grid-template-columns: 1fr; }
  .scope__view { height: 300px; }
  .scope__badge { left: 10px; bottom: -16px; }
}
@media (max-width: 560px) {
  .grid--2, .grid--3, .grid--4 { grid-template-columns: 1fr; }
  .statstrip, .chips, .cards-dark, .timeline { grid-template-columns: 1fr; }
  .statstrip > div { border-left: 0 !important; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero__actions .btn, .cta__actions .btn, .page-hero__actions .btn { width: 100%; justify-content: center; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto; }
}
