/* ===== Beorgan — SOC theme tokens ===== */

:root {
  /* Palette: Clean · Premium · Timeless */
  --black: #0B0B0B;
  --black-2: #141414;
  --black-3: #1E1E1E;
  --crimson: #8B0D1A;
  --crimson-d: #6E0914;
  --crimson-l: #E05260;
  --off-white: #F5F2ED;
  --off-white-2: #ECE7DF;
  --stone: #D8D2C7;

  /* Semantic aliases */
  --c-blue: var(--crimson); --c-blue-d: var(--crimson-d); --c-blue-l: var(--crimson-l);
  --c-red: var(--crimson); --c-red-d: var(--crimson-d);
  --c-amber: var(--crimson); --c-violet: var(--crimson); --c-green: var(--crimson); --c-cyan: var(--crimson);
  --vanilla: var(--off-white);
  --sage: var(--stone);
  --bloodstone: var(--black);
  --bloodstone-2: var(--black-2);
  --ink: var(--black);

  /* role tokens */
  --cream: var(--off-white);
  --sand: var(--stone);
  --green: var(--black);
  --green-2: var(--black-2);
  --bordo: var(--crimson);
  --palladian: var(--off-white);
  --oatmeal: #B8B1A6;
  --blue-fantastic: var(--black-2);
  --flame: var(--crimson-l);
  --truffle: var(--crimson);
  --abyssal: var(--black);

  --bg: var(--off-white);
  --bg-2: var(--off-white-2);
  --fg: var(--black);
  --muted: #5C5750;
  --border: var(--stone);
  --accent: var(--crimson);
  --accent-2: var(--crimson-l);
  --panel: var(--black);
  --panel-ink: var(--off-white);
  --panel-muted: #A8A298;
  --canvas: #080808;
  --panel-border: #F5F2ED1f;
  --depth: #000000;
  --font-body: "DM Sans", system-ui, sans-serif;
  --font-label: "DM Sans", system-ui, sans-serif;
  --font-display: "DM Serif Display", Georgia, serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
}
* { box-sizing: border-box; }
html { caret-color: var(--crimson); scrollbar-color: var(--crimson) var(--off-white); }
html, body { margin: 0; background: var(--bg); color: var(--fg); font-family: var(--font-body); -webkit-font-smoothing: antialiased; }
::selection { background: var(--crimson); color: var(--off-white); }
a { color: inherit; text-decoration: none; }
svg { width: 20px; height: 20px; }
h1, h2, h3, p { margin-top: 0; }
em { font-style: italic; color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 5px; }

.skip { position: fixed; top: -100px; left: 20px; background: var(--fg); color: var(--bg); padding: 14px; z-index: 200; }
.skip:focus { top: 10px; }

/* ===== Nav ===== */
.site-nav {
  position: fixed; inset: 0 0 auto 0; z-index: 100; height: 68px;
  display: flex; align-items: center; gap: 40px; padding: 0 6%;
  background: #F5F2EDF2; border-bottom: 1px solid #0B0B0B14; backdrop-filter: blur(8px);
}
.brand { display: flex; align-items: center; gap: 10px; font: 400 23px var(--font-display); letter-spacing: 0; }
.brand svg { color: var(--accent); width: 24px; height: 24px; }
.site-nav nav { display: flex; gap: 28px; font-size: 13px; color: var(--muted); }
.site-nav nav a:hover { color: var(--fg); }
.nav-cta { margin-left: auto; display: flex; align-items: center; gap: 9px; font: 600 10px var(--font-label); letter-spacing: .18em; text-transform: uppercase; border: 1px solid var(--black); padding: 9px 14px; border-radius: 6px; background: var(--black); color: var(--off-white); }
.live-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--crimson-l); box-shadow: 0 0 0 0 var(--crimson-l); animation: pulse 1.8s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 #8B0D1A99; } 70% { box-shadow: 0 0 0 9px #8B0D1A00; } 100% { box-shadow: 0 0 0 0 #8B0D1A00; } }

/* ===== Shared ===== */
.eyebrow { font: 600 10px var(--font-label); letter-spacing: .24em; text-transform: uppercase; color: var(--muted); margin: 0 0 22px; display: flex; align-items: center; gap: 10px; }
.eyebrow > span { width: 6px; height: 6px; background: var(--accent); border-radius: 50%; }
.primary { display: inline-flex; align-items: center; gap: 28px; padding: 15px 22px; border-radius: 6px; background: var(--crimson); color: var(--off-white); font-size: 13px; font-weight: 600; border: 0; box-shadow: 0 2px 6px #0B0B0B24; transition: background .2s, transform .2s, box-shadow .2s; }
.primary:hover { background: var(--crimson-d); transform: translateY(-1px); box-shadow: 0 6px 14px -4px #0B0B0B33; }
.primary span { font-size: 17px; color: var(--off-white); }
.secondary { display: inline-flex; align-items: center; padding: 14px 20px; border-radius: 6px; border: 1px solid var(--stone); background: var(--off-white); color: var(--black); font-size: 13px; font-weight: 500; box-shadow: 0 1px 2px #0B0B0B0D; transition: border-color .2s, color .2s; }
.secondary:hover { border-color: var(--crimson); color: var(--crimson); }

/* ===== Hero experience ===== */
.af-experience { position: relative; width: 100%; }
.af-experience .viewport { height: 100svh; min-height: 650px; position: relative; overflow: clip; }
.af-experience .scene { position: absolute; inset: 0; }
.af-experience .ambient {
  position: absolute; inset: 0; pointer-events: none;
  background:
    var(--bg);
}
.af-experience .grid-bg {
  position: absolute; inset: 0; pointer-events: none; opacity: .35;
  background-image: linear-gradient(#D4D4D466 1px, transparent 1px), linear-gradient(90deg, #D4D4D466 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse at 60% 50%, #000 20%, transparent 75%);
}
.af-experience .intro { position: absolute; left: 6%; top: clamp(84px, 15vh, 170px); z-index: 5; width: min(620px, 42%); }
.af-experience h1 { font: 400 clamp(36px, min(4.7vw, 7.4vh), 76px)/1.02 var(--font-display); letter-spacing: -.015em; margin-bottom: clamp(14px, 2.4vh, 24px); }
.af-experience .intro-description { font-size: 15.5px; line-height: 1.65; color: var(--muted); max-width: 540px; margin-bottom: clamp(18px, 3vh, 28px); }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; }
.intro-stats { list-style: none; padding: 0; margin: clamp(20px, 4vh, 36px) 0 0; display: flex; gap: 34px; }
.intro-stats li { display: flex; flex-direction: column; gap: 4px; }
.intro-stats b { font: 400 clamp(26px, 3.8vh, 34px)/1 var(--font-display); color: var(--fg); }
.intro-stats span { font: 600 9px var(--font-label); letter-spacing: .18em; color: var(--muted); text-transform: uppercase; }

.af-experience .stage { position: absolute; left: 70%; top: 46%; width: 800px; height: 500px; transform: translate(-50%, -50%); perspective: 1500px; z-index: 3; pointer-events: none; }
.af-experience .world { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; }

/* panel */
.flow-panel {
  position: absolute; left: 50%; top: 50%; width: 800px; height: 470px;
  background: var(--panel); color: var(--panel-ink); border: 1px solid var(--panel-border); border-radius: 15px;
  transform-style: preserve-3d;
  box-shadow: 0 0 0 1px #0F172A0A, 0 1px 2px #0F172A0F, 0 12px 24px -8px #0F172A1F, 0 40px 80px -24px #0F172A40;
}
.panel-top { height: 55px; border-bottom: 1px solid var(--panel-border); display: flex; align-items: center; padding: 0 22px; gap: 12px; border-radius: 14px 14px 0 0; background: var(--panel); }
.panel-top strong { font-size: 13px; font-weight: 500; }
.panel-mark { color: var(--pc); display: flex; }
.panel-status { margin-left: auto; font: 10px var(--font-mono); color: var(--panel-muted); padding: 6px 10px; border: 1px solid var(--panel-border); border-radius: 5px; background: #FFFFFF0d; }
.panel-status b { display: inline-block; width: 5px; height: 5px; background: var(--pc); border-radius: 50%; margin-right: 7px; }
.panel-menu { font-size: 22px; margin-left: 8px; color: var(--panel-muted); }
.panel-body { height: 370px; display: flex; transform-style: preserve-3d; }
.rail { width: 47px; flex-shrink: 0; border-right: 1px solid var(--panel-border); padding: 22px 14px; display: flex; flex-direction: column; gap: 26px; color: var(--panel-muted); }
.rail svg { width: 17px; height: 17px; }
.rail svg:nth-child(2) { color: var(--pc); }
.rail span { flex: 1; }
.canvas { position: relative; flex: 1; background-color: var(--canvas); background-image: radial-gradient(#D4D4D426 1px, transparent 1px); background-size: 18px 18px; transform-style: preserve-3d; }
.canvas-caption { display: flex; align-items: center; gap: 8px; padding: 18px 24px; font: 9px var(--font-mono); letter-spacing: 1.3px; color: var(--panel-ink); }
.canvas-caption svg { width: 13px; height: 13px; color: var(--pc); }
.connections { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; fill: none; }
.connections .main-wire { stroke-width: 2.4; stroke-linecap: round; }
.connections .main-wire { opacity: .35; }
.connections .signal { stroke-dasharray: 10 140; stroke-width: 3; stroke-linecap: round; }
.nodes { position: absolute; inset: 0; transform-style: preserve-3d; }
.node { position: absolute; width: 150px; height: 91px; transform-style: preserve-3d; }
.node-face {
  position: absolute; inset: 0; border: 1px solid #E2E8F0; border-radius: 10px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: var(--panel);
  box-shadow: 0 1px 2px #0F172A0F, 0 6px 16px -4px #0F172A1F;
  transform-style: preserve-3d;
}
.node-glow { position: absolute; inset: -1.5px; border-radius: inherit; box-shadow: 0 0 0 2px var(--nc), 0 18px 36px -10px color-mix(in srgb, var(--nc) 55%, transparent); opacity: 0; pointer-events: none; }
.node-icon { color: var(--nc); margin-bottom: 7px; width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; background: color-mix(in srgb, var(--nc) 12%, #fff); }
.node-icon svg { width: 18px; height: 18px; }
.node strong { font-size: 12px; font-weight: 550; }
.node small { font: 7px var(--font-mono); letter-spacing: 1.4px; margin-top: 5px; color: var(--panel-muted); }
.port { position: absolute; top: 50%; width: 7px; height: 7px; margin-top: -3.5px; background: #fff; border: 2px solid var(--pc); border-radius: 50%; z-index: 2; }
.port.left { left: -4px; } .port.right { right: -4px; }
.port.top { top: -4px; margin-top: 0; left: calc(50% - 3.5px); }
.port.bottom { top: auto; bottom: -4px; margin-top: 0; left: calc(50% - 3.5px); }
.diagram-note { position: absolute; bottom: 8px; left: 5%; margin: 0; font: 8px var(--font-mono); letter-spacing: 1.2px; color: var(--panel-muted); }
.panel-bottom { height: 44px; display: flex; gap: 16px; align-items: center; padding: 0 18px; color: var(--panel-muted); font: 9px var(--font-mono); border-top: 1px solid var(--panel-border); }
.panel-bottom > span { display: flex; align-items: center; gap: 6px; }
.panel-bottom svg { width: 13px; height: 13px; color: var(--pc); }
.panel-bottom > span:nth-child(2) { margin-left: auto; }
.run-mark { border: 1px solid var(--panel-border); border-radius: 4px; padding: 5px; }

/* chapter copy */
.chapter-copy, .service-chapter { display: contents; }
.flow-copy { position: absolute; inset: clamp(84px, 15vh, 170px) auto auto 6%; width: 30%; z-index: 6; }
.flow-copy h2 i { font-style: italic; }
.flow-copy .eyebrow { color: var(--truffle); font-size: 9px; }
.flow-copy h2 { font: 400 clamp(30px, 2.8vw, 44px)/1.06 var(--font-display); letter-spacing: -.01em; margin-bottom: 18px; }
.flow-description { font-size: 14px; line-height: 1.65; color: var(--muted); max-width: 380px; }
.flow-copy ol { list-style: none; padding: 0; margin: 18px 0 0; }
.flow-copy li { display: flex; gap: 14px; padding: 10px 0; border-top: 1px solid var(--border); }
.flow-copy li > span { font: italic 15px/1 var(--font-display); color: var(--truffle); padding-top: 3px; }
.flow-copy li h3 { font-size: 13px; font-weight: 600; margin-bottom: 3px; }
.flow-copy li p { font-size: 11.5px; color: var(--muted); line-height: 1.5; margin: 0; max-width: 320px; }

.chapter-nav { position: absolute; bottom: 82px; left: 6%; right: 6%; display: flex; gap: 32px; z-index: 12; }
.chapter-nav button { flex: 1; min-height: 44px; background: none; border: 0; border-top: 1px solid var(--border); padding: 16px 0 10px; text-align: left; font: 500 12px var(--font-body); color: var(--muted); cursor: pointer; position: relative; }
.chapter-nav button i { position: absolute; left: 0; top: -1px; height: 2px; width: 0; background: var(--truffle); transition: width .35s; }
.chapter-nav button.active, .chapter-nav button:hover { color: var(--fg); }
.chapter-nav button.active i { width: 100%; }
.experience-footer { position: absolute; bottom: 28px; left: 6%; right: 6%; display: flex; gap: 25px; font: 600 8.5px var(--font-label); letter-spacing: .2em; color: var(--muted); z-index: 12; }
.scroll-hint { margin-left: auto; }
.scroll-hint b { font-size: 16px; margin-left: 12px; }

.flow-finale { position: absolute; inset: 0; z-index: 10; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 70px 5%; opacity: 0; visibility: hidden; }
.flow-finale::before { content: none; }
.flow-finale .eyebrow { justify-content: center; color: var(--accent); }
.flow-finale h2 { font: 400 clamp(40px, 5.4vw, 86px)/1.02 var(--font-display); letter-spacing: -.015em; margin: 0 0 34px; }

/* ===== Simple (reduced motion / no JS) layout ===== */
.af-experience.simple .viewport { height: auto; min-height: 0; overflow: visible; }
.af-experience.simple .scene { position: relative; }
.af-experience.simple .intro { position: relative; left: auto; top: auto; padding: 150px 6% 50px; max-width: none; }
.af-experience.simple .chapter-copy { display: block; padding: 0 6%; }
.af-experience.simple .service-chapter { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1.5fr); gap: 40px; padding: 60px 0; border-top: 1px solid var(--border); }
.af-experience.simple .flow-copy { position: relative; inset: auto; width: auto; }
.af-experience.simple .stage { position: relative; left: auto; top: auto; width: 100%; height: auto; transform: none; perspective: none; }
.af-experience.simple .flow-panel { position: relative; left: auto; top: auto; zoom: var(--panel-scale, .8); }
.af-experience.simple .chapter-nav, .af-experience.simple .scroll-hint { display: none; }
.af-experience.simple .experience-footer { position: relative; inset: auto; padding: 20px 6%; }
.af-experience.simple .flow-finale { position: relative; opacity: 1; visibility: visible; }


/* ===== Hero: Black, Crimson Red & Off White ===== */
.af-experience {
  --hero-blue: var(--crimson); --hero-red: var(--crimson-l); --hero-green: var(--black);
  --panel: var(--black); --panel-ink: var(--off-white); --panel-muted: #A8A298;
  --canvas: #080808; --panel-border: #F5F2ED1F; --depth: #000000;
}
.af-experience .grid-bg { display: none; }
.af-experience .ambient { background: var(--off-white); }
.af-experience .intro .eyebrow { color: var(--crimson); }
.af-experience .intro .eyebrow > span { background: var(--crimson); }
.af-experience h1 em, .flow-finale h2 em { color: var(--crimson); }
.af-experience .intro-stats li { padding-left: 14px; border-left: 1px solid var(--stone); }
.af-experience .intro-stats li:nth-child(1) { --sc: var(--crimson); }
.af-experience .intro-stats li:nth-child(2) { --sc: var(--black); }
.af-experience .intro-stats li:nth-child(3) { --sc: var(--crimson-d); }
.af-experience .intro-stats b { color: var(--sc); }
.af-experience .primary { background: var(--crimson); color: var(--off-white); box-shadow: 0 2px 6px #0B0B0B24; }
.af-experience .primary:hover { background: var(--crimson-d); }
.af-experience .primary span { color: var(--off-white); }
.af-experience .secondary { border-color: var(--stone); background: var(--off-white); box-shadow: 0 1px 2px #0B0B0B0D; }
.af-experience .secondary:hover { border-color: var(--black); background: var(--off-white); color: var(--black); }
.flow-copy .eyebrow, .flow-copy li > span { color: var(--crimson); }
.flow-copy h2 i { color: var(--crimson); }
.flow-copy li { border-top-color: var(--stone); }
.chapter-nav button { border-top-color: var(--stone); }
.chapter-nav button i { background: var(--crimson); }
.chapter-nav button:nth-child(2) i { background: var(--crimson); }
.chapter-nav button:nth-child(3) i { background: var(--black); }
.flow-panel { box-shadow: 0 0 0 1px #F5F2ED14, 0 20px 50px -12px #0B0B0B66, 0 40px 80px -24px #0B0B0B80; }
.panel-top { border-bottom: 1px solid var(--panel-border); background: var(--black); }
.panel-mark { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; background: var(--crimson); color: var(--off-white); }
.panel-mark svg { width: 15px; height: 15px; }
.panel-status { background: var(--black-2); color: var(--off-white); border-color: var(--panel-border); box-shadow: none; }
.panel-status b { background: var(--crimson-l); }
.rail { background: var(--black); border-right-color: var(--panel-border); color: var(--panel-muted); }
.canvas { background-image: radial-gradient(#F5F2ED1A 1px, transparent 1px); }
.canvas-caption { color: var(--panel-muted); }
.diagram-note { color: var(--panel-muted); }
.panel-bottom { border-top-color: var(--panel-border); color: var(--panel-muted); }
.run-mark { background: var(--crimson); border-color: var(--crimson); color: var(--off-white); }
.run-mark svg { color: var(--off-white); }
.node-face { background: var(--black-2); border: 1px solid #F5F2ED24; border-top: 3px solid var(--nc); box-shadow: 0 4px 14px -4px #00000080; }
.node-icon { background: color-mix(in srgb, var(--nc) 18%, var(--black-2)); }
.node strong { color: var(--off-white); font-weight: 600; }
.port { background: var(--black-2); }

/* ===== Our Services — stacking numbered rows ===== */
.services { --bar: 76px; --nav: 68px; position: relative; padding: 140px 6% 0; background: var(--bg); border-top: 1px solid var(--border); }
.svc-head { display: grid; grid-template-columns: 1.2fr 1fr; gap: 24px 60px; align-items: end; margin-bottom: 80px; }
.svc-head .eyebrow { grid-column: 1 / -1; color: var(--truffle); margin: 0; }
.svc-head .eyebrow > span { background: var(--truffle); }
.svc-title { font: 400 clamp(40px, 4.6vw, 74px)/1.02 var(--font-display); letter-spacing: -.015em; margin: 0; }
.svc-title i { color: var(--truffle); }
.svc-intro p { font-size: 15px; line-height: 1.7; color: var(--muted); margin: 0 0 18px; max-width: 440px; }
.svc-meta { font: 500 10px var(--font-mono); letter-spacing: .12em; color: var(--fg); }

.svc-list { list-style: none; margin: 0; padding: 0; }
.svc {
  position: sticky; top: calc(var(--nav) + var(--i) * var(--bar));
  background: var(--bg); border-top: 1px solid var(--abyssal);
  /* each row spans from its sticky slot to the viewport bottom, so the whole stack releases together */
  min-height: calc(100vh - var(--nav) - var(--i) * var(--bar));
}
.svc-bar { height: var(--bar); display: grid; grid-template-columns: 120px 1fr auto; align-items: center; gap: 24px; }
.svc-num { font: 400 clamp(30px, 3vw, 44px)/1 var(--font-display); color: var(--truffle); }
.svc-name { margin: 0; overflow: hidden; font: 700 clamp(24px, 3vw, 46px)/1 var(--font-body); letter-spacing: -.03em; text-transform: uppercase; }
.svc-name span { display: inline-block; }
.svc-sub { font: italic 400 clamp(17px, 1.6vw, 24px) var(--font-display); color: var(--muted); }
.svc-body { display: grid; grid-template-columns: 120px minmax(0, 1.1fr) minmax(0, 1fr); gap: 24px 60px; padding: 30px 0 56px; }
.svc-stat { grid-column: 1; display: flex; flex-direction: column; gap: 6px; }
.svc-stat b { font: 400 30px/1 var(--font-display); color: var(--fg); }
.svc-stat small { font: 600 8.5px var(--font-label); letter-spacing: .18em; text-transform: uppercase; color: var(--muted); }
.svc-desc { margin: 0; font-size: 16px; line-height: 1.7; color: var(--fg); max-width: 520px; }
.svc-caps small { display: block; font: 500 10px var(--font-mono); letter-spacing: .12em; color: var(--truffle); margin-bottom: 14px; }
.svc-caps ul { list-style: none; margin: 0; padding: 0; }
.svc-caps li { font-size: 14px; padding: 9px 0; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 12px; }
.svc-caps li::before { content: ""; width: 5px; height: 5px; background: var(--bordo); border-radius: 50%; flex-shrink: 0; }
.svc:hover .svc-name { color: var(--blue-fantastic); }

@media (max-height: 820px) and (min-width: 901px) {
  .services { --bar: 56px; }
  .svc-body { padding: 18px 0 36px; }
  .svc-desc { font-size: 14.5px; line-height: 1.6; }
  .svc-caps li { padding: 6px 0; font-size: 13px; }
}
@media (max-width: 900px) {
  .svc-head { grid-template-columns: 1fr; margin-bottom: 50px; }
  .services { --bar: 60px; padding-top: 100px; }
  .svc-bar { grid-template-columns: 52px 1fr; }
  .svc-sub { display: none; }
  .svc-body { grid-template-columns: 1fr; gap: 20px; }
  .svc-stat { flex-direction: row; align-items: baseline; gap: 10px; }
}
@media (max-width: 600px), (max-height: 600px) {
  .svc { position: relative; top: auto; min-height: 0; }
}

/* ===== About ===== */
.about { padding: 140px 6% 120px; background: var(--bg); border-top: 1px solid var(--border); }
.about-hero { text-align: center; max-width: 720px; margin: 0 auto; padding-bottom: 80px; }
.about-title { font: 400 clamp(46px, 5.2vw, 82px)/1.02 var(--font-display); letter-spacing: -.015em; margin: 0 0 22px; }
.about-title i { color: var(--truffle); }
.about-lede { font-size: 16px; line-height: 1.65; color: var(--muted); max-width: 500px; margin: 0 auto 30px; }
.about-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; padding-top: 70px; border-top: 1px solid var(--border); }
.tile { position: relative; margin: 0; aspect-ratio: 1.12; overflow: hidden; border-radius: 4px; background: var(--blue-fantastic); }
.tile img { width: 100%; height: 100%; object-fit: cover; display: block; filter: grayscale(1) contrast(1.05); }
.tile figcaption { position: absolute; left: 18px; bottom: 16px; font: 500 10px var(--font-mono); letter-spacing: .12em; color: var(--palladian); text-shadow: 0 1px 8px #0A0A0A99; }
.tile-dark { background: var(--abyssal); color: var(--palladian); padding: 28px 28px 24px; display: flex; flex-direction: column; justify-content: space-between; }
.tile-dark p { margin: 0; font-size: 15px; line-height: 1.6; max-width: 340px; text-indent: 2.2em; color: var(--oatmeal); }
.tile-stat { align-self: flex-end; display: flex; align-items: baseline; gap: 10px; }
.tile-stat small { font: 600 9px var(--font-label); letter-spacing: .18em; text-transform: uppercase; color: var(--oatmeal); }
.tile-stat b { font: 400 clamp(44px, 4.4vw, 68px)/1 var(--font-display); color: var(--flame); }

.about-reach { text-align: center; padding-top: 150px; }
.pill { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 26px; padding: 6px 12px; border-radius: 4px; background: var(--bg-2); border: 1px solid var(--border); font: 600 10px var(--font-label); letter-spacing: .16em; text-transform: uppercase; }
.pill span { width: 6px; height: 6px; border-radius: 50%; background: var(--truffle); }
.reach-title { font: 400 clamp(34px, 3.8vw, 58px)/1.06 var(--font-display); letter-spacing: -.01em; margin: 0 0 22px; }
.reach-title i { color: var(--truffle); }
.reach-copy { font-size: 15.5px; line-height: 1.7; color: var(--muted); max-width: 620px; margin: 0 auto 60px; }
.worldmap { max-width: 1240px; margin: 0 auto; }
.worldmap svg { width: 100%; height: auto; display: block; overflow: visible; }
.worldmap .dots circle { fill: #D4D4D4; }
.pin-body { fill: var(--truffle); stroke: #000000; stroke-width: .15; }
.pin-eye { fill: var(--palladian); }
.pin-shadow { fill: #0A0A0A33; }
.pin-drop { transform-box: fill-box; transform-origin: 50% 100%; transition: transform .25s; }
.pin:hover .pin-drop { transform: translateY(-.6px) scale(1.15); }
.worldmap-note { margin: 26px 0 0; font: 600 9px var(--font-label); letter-spacing: .2em; color: var(--muted); }

@media (max-width: 900px) {
  .about-tiles { grid-template-columns: 1fr 1fr; }
  .tile-dark { grid-column: 1 / -1; grid-row: 1; aspect-ratio: auto; min-height: 240px; }
  .about-reach { padding-top: 100px; }
}
@media (max-width: 600px) {
  .about { padding: 100px 6% 80px; }
  .about-tiles { grid-template-columns: 1fr; }
}

/* ===== Contact ===== */
.contact { padding: 140px 6% 130px; background: var(--bg-2); border-top: 1px solid var(--border); }
.contact-grid { display: grid; grid-template-columns: 1fr 1.05fr; gap: 80px; align-items: start; max-width: 1320px; margin: 0 auto; }
.contact .eyebrow { color: var(--truffle); }
.contact .eyebrow > span { background: var(--truffle); }
.contact-title { font: 400 clamp(38px, 4.2vw, 64px)/1.04 var(--font-display); letter-spacing: -.015em; margin: 0 0 22px; }
.contact-title i { color: var(--truffle); }
.contact-lede { font-size: 15.5px; line-height: 1.7; color: var(--muted); max-width: 460px; margin: 0 0 40px; }
.contact-list { list-style: none; padding: 0; margin: 0 0 36px; border-top: 1px solid var(--oatmeal); }
.contact-list li { display: grid; grid-template-columns: 130px 1fr; align-items: center; padding: 18px 0; border-bottom: 1px solid var(--oatmeal); }
.contact-list small { font: 600 10px var(--font-label); letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
.contact-list a, .contact-list span { font: 400 22px var(--font-display); display: inline-flex; align-items: center; gap: 10px; }
.contact-list a:hover { color: var(--truffle); }
.incident-card { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 24px 26px; border-radius: 8px; background: var(--abyssal); color: var(--palladian); }
.incident-label { font: 500 10px var(--font-mono); letter-spacing: .14em; color: var(--flame); margin: 0 0 8px; }
.incident-text { margin: 0; font-size: 14px; line-height: 1.55; color: var(--oatmeal); max-width: 330px; }
.incident-btn { flex-shrink: 0; display: inline-flex; gap: 12px; align-items: center; padding: 13px 18px; border-radius: 6px; background: var(--c-red); color: #fff; font-weight: 600; font-size: 13px; box-shadow: 0 8px 20px -6px #E11D4899; transition: transform .2s, background .2s; }
.incident-btn:hover { background: var(--c-red-d); transform: translateY(-1px); }

.contact-form { background: var(--palladian); border: 1px solid var(--oatmeal); border-radius: 12px; padding: 38px; box-shadow: 0 30px 60px -30px #0A0A0A40; }
.form-head { font: 400 26px var(--font-display); margin: 0 0 28px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { display: flex; flex-direction: column; gap: 8px; margin: 0 0 20px; border: 0; padding: 0; min-width: 0; }
.field > span, .field legend { font: 600 10px var(--font-label); letter-spacing: .18em; text-transform: uppercase; color: var(--muted); padding: 0; margin-bottom: 8px; }
.field input, .field textarea { font: 400 15px var(--font-body); color: var(--fg); background: transparent; border: 0; border-bottom: 1px solid var(--oatmeal); padding: 8px 0 10px; outline: none; resize: vertical; transition: border-color .2s; }
.field input:focus, .field textarea:focus { border-color: var(--abyssal); }
.field.invalid input, .field.invalid textarea { border-color: var(--truffle); }
.field.invalid > span { color: var(--truffle); }
.chips { flex-direction: row; flex-wrap: wrap; gap: 8px; }
.chips legend { width: 100%; }
.chips label { cursor: pointer; }
.chips input { position: absolute; opacity: 0; pointer-events: none; }
.chips label span { display: inline-block; padding: 8px 14px; border: 1px solid var(--oatmeal); border-radius: 999px; font-size: 13px; transition: background .2s, color .2s, border-color .2s; }
.chips label:hover span { border-color: var(--abyssal); }
.chips input:checked + span { background: var(--abyssal); border-color: var(--abyssal); color: var(--palladian); }
.chips input:focus-visible + span { outline: 2px solid var(--truffle); outline-offset: 2px; }
.form-foot { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 8px; }
.form-note { margin: 0; font-size: 12.5px; color: var(--muted); max-width: 250px; line-height: 1.5; }
.contact-form button.primary { border: 0; cursor: pointer; font-family: var(--font-body); }
.form-status { margin: 16px 0 0; font-size: 13.5px; min-height: 1em; }
.form-status[data-state=ok] { color: #0A0A0A; }
.form-status[data-state=error] { color: var(--truffle); }

/* ===== Footer ===== */
.site-nav { transition: background .3s, color .3s; }
.site-nav.on-dark { background: #0A0A0AF2; border-bottom-color: #FFFFFF14; color: var(--palladian); }
.site-nav.on-dark nav { color: var(--oatmeal); }
.site-nav.on-dark nav a:hover { color: var(--palladian); }
.site-nav.on-dark .nav-cta { background: var(--palladian); color: var(--abyssal); border-color: var(--palladian); }
.site-footer { background: var(--abyssal); color: var(--palladian); padding: 100px 6% 32px; overflow: hidden; }
.footer-top { display: grid; grid-template-columns: 1.6fr 1fr .7fr .9fr; gap: 50px; padding-bottom: 70px; border-bottom: 1px solid #FFFFFF1f; }
.footer-tag { font: 400 clamp(36px, 3.6vw, 54px)/1.05 var(--font-display); margin: 0 0 18px; }
.footer-tag i { color: var(--flame); }
.footer-blurb { font-size: 14px; line-height: 1.7; color: var(--oatmeal); max-width: 380px; margin: 0 0 28px; }
.footer-cta { display: inline-flex; gap: 14px; align-items: center; font-size: 13px; font-weight: 600; padding-bottom: 6px; border-bottom: 2px solid var(--c-blue-l); }
.footer-cta span { color: var(--c-blue-l); transition: transform .2s; }
.footer-cta:hover span { transform: translateX(4px); }
.footer-col { display: flex; flex-direction: column; gap: 12px; font-size: 14px; }
.footer-col small { font: 600 10px var(--font-label); letter-spacing: .2em; text-transform: uppercase; color: var(--flame); margin-bottom: 6px; }
.footer-col a { color: var(--oatmeal); transition: color .2s; width: fit-content; }
.footer-col a:hover { color: var(--palladian); }
.footer-live { display: inline-flex; align-items: center; gap: 9px; font-size: 13px; color: var(--oatmeal); margin-top: 6px; }
.footer-word { overflow: hidden; line-height: .8; padding-top: 40px; }
.footer-word span { display: block; font: 400 clamp(90px, 21vw, 340px)/.8 var(--font-display); letter-spacing: -.03em; color: var(--blue-fantastic); text-align: center; white-space: nowrap; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding-top: 26px; border-top: 1px solid #FFFFFF1f; font: 500 11.5px var(--font-body); color: var(--oatmeal); }
.footer-legal { display: flex; gap: 22px; }
.footer-bottom a:hover { color: var(--palladian); }
.to-top span { color: var(--flame); }

@media (max-width: 1000px) {
  .contact-grid { grid-template-columns: 1fr; gap: 56px; }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 600px) {
  .contact { padding: 100px 6% 90px; }
  .contact-form { padding: 26px 20px; }
  .field-row { grid-template-columns: 1fr; gap: 0; }
  .contact-list li { grid-template-columns: 1fr; gap: 6px; }
  .incident-card, .form-foot { flex-direction: column; align-items: flex-start; }
  .footer-top { grid-template-columns: 1fr; gap: 36px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}

/* ===== Short viewports: keep copy clear of the bottom chapter tabs ===== */
@media (min-width: 901px) and (max-height: 860px) {
  .af-experience .intro-description { font-size: 14px; line-height: 1.55; }
  .af-experience .primary, .af-experience .secondary { padding-top: 12px; padding-bottom: 12px; }
  .flow-copy h2 { font-size: clamp(26px, 4.8vh, 40px); margin-bottom: 12px; }
  .flow-description { font-size: 13px; line-height: 1.55; }
  .flow-copy li { padding: 7px 0; }
  .flow-copy li p { display: none; }
  .chapter-nav { bottom: 60px; }
  .experience-footer { bottom: 20px; }
}
@media (min-width: 901px) and (max-height: 700px) {
  .af-experience .intro-stats { display: none; }
  .flow-description { display: none; }
}

/* ===== Responsive ===== */
@media (max-width: 1100px) {
  .af-experience .stage { left: 74%; }
  .service-grid { grid-template-columns: repeat(2, 1fr); }
  .timeline { grid-template-columns: repeat(3, 1fr); row-gap: 40px; }
}
@media (max-width: 900px) {
  .site-nav nav { display: none; }
  .af-experience[data-layout=phone] .intro,
  .af-experience[data-layout=phone] .flow-copy { left: 6%; top: 90px; width: 88%; max-width: none; }
  .af-experience[data-layout=phone] h1 { font-size: clamp(34px, 9vw, 46px); letter-spacing: -.01em; }
  .af-experience[data-layout=phone] .intro-description { font-size: 14px; }
  .af-experience[data-layout=phone] .intro-stats { display: none; }
  .af-experience[data-layout=phone] .flow-copy li p,
  .af-experience[data-layout=phone] .flow-copy li > span { display: none; }
  .af-experience[data-layout=phone] .flow-copy ol { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
  .af-experience[data-layout=phone] .flow-copy li { display: block; }
  .af-experience[data-layout=phone] .flow-copy li h3 { font-size: 11px; }
  .af-experience[data-layout=phone] .stage { left: 50%; top: var(--stage-y, 66%); }
  .af-experience[data-layout=phone] .chapter-nav { bottom: 16px; gap: 10px; }
  .af-experience[data-layout=phone] .chapter-nav button { font-size: 11px; }
  .af-experience[data-layout=phone] .experience-footer { display: none; }
  .af-experience.simple .service-chapter { grid-template-columns: 1fr; }
  .about-grid, .contact-card { grid-template-columns: 1fr; gap: 40px; }
  .contact-card { padding: 34px; }
}
@media (max-width: 600px) {
  .service-grid, .timeline, .pillars { grid-template-columns: 1fr; }
  .timeline::before { display: none; }
  .section { padding: 90px 6%; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* ===== Section colour accents (Black, Crimson Red & Off White) ===== */
/* Services: unified crimson accent */
.svc-list .svc { --rc: var(--crimson); }
.svc { border-top: 1px solid var(--stone); }
.svc-bar { position: relative; }
.svc-bar::before { content: ""; position: absolute; left: 0; top: -1px; width: 120px; height: 3px; background: var(--rc); }
.svc-num { color: var(--rc); }
.svc-sub { color: var(--muted); }
.svc-stat b { color: var(--black); }
.svc-caps small { color: var(--rc); }
.svc-caps li { border-bottom-color: var(--stone); }
.svc-caps li::before { background: var(--rc); border-radius: 2px; }
.svc:hover .svc-name { color: var(--rc); }
.svc-title i, .svc-head .eyebrow { color: var(--crimson); }
.svc-head .eyebrow > span { background: var(--crimson); }

/* About */
.about-title i, .reach-title i { color: var(--crimson); }
.tile-dark { background: var(--black); border: 1px solid var(--black-3); }
.tile-dark p { color: var(--stone); }
.tile-stat small { color: var(--oatmeal); }
.tile-stat b { color: var(--crimson-l); }
.pill { background: var(--off-white-2); border-color: var(--stone); color: var(--black); }
.pill span { background: var(--crimson); }
.worldmap .dots circle { fill: #CEC7BB; }
.worldmap .pin .pin-body { fill: var(--crimson); }
.worldmap .pin:nth-child(2n) .pin-body { fill: var(--black); }
.pin-body { stroke: var(--off-white); stroke-width: .25; }
.pin-eye { fill: var(--off-white); }
.tile figcaption { background: #0B0B0BCC; color: var(--off-white); padding: 5px 8px; border-radius: 4px; text-shadow: none; }

/* Contact */
.contact { background: var(--off-white-2); }
.contact .eyebrow { color: var(--crimson); }
.contact .eyebrow > span { background: var(--crimson); }
.contact-title i { color: var(--crimson); }
.contact-list { border-top-color: var(--stone); }
.contact-list li { border-bottom-color: var(--stone); }
.contact-list a:hover { color: var(--crimson); }
.incident-card { background: var(--black); color: var(--off-white); border: 1px solid #8B0D1A55; }
.incident-label { color: var(--crimson-l); }
.incident-btn { background: var(--crimson); color: var(--off-white); box-shadow: 0 2px 8px #0B0B0B40; }
.incident-btn:hover { background: var(--crimson-d); }
.contact-form { background: var(--off-white); border-color: var(--stone); box-shadow: none; }
.field input, .field textarea { border-bottom-color: var(--stone); }
.field input:focus, .field textarea:focus { border-color: var(--crimson); }
.chips label span { border-color: var(--stone); }
.chips label:hover span { border-color: var(--crimson); color: var(--crimson); }
.chips input:checked + span { background: var(--crimson); border-color: var(--crimson); color: var(--off-white); }
.field.invalid input, .field.invalid textarea { border-color: var(--crimson); }
.field.invalid > span, .form-status[data-state=error] { color: var(--crimson); }
.form-status[data-state=ok] { color: var(--black); }

/* Footer */
.site-nav.on-dark { background: #0B0B0BF2; border-bottom-color: #F5F2ED1A; color: var(--off-white); }
.site-nav.on-dark .nav-cta { background: var(--crimson); color: var(--off-white); border-color: var(--crimson); }
.nav-cta { background: var(--black); color: var(--off-white); border-color: var(--black); }
.footer-tag i { color: var(--crimson-l); }
.footer-cta { border-bottom-color: var(--crimson); }
.footer-cta span { color: var(--crimson-l); }
.footer-col small { color: var(--crimson-l); }
.footer-word span { color: var(--black-2); }
.to-top span { color: var(--crimson-l); }

/* ===== Navbar: centered black pill docked to the top edge ===== */
.site-nav, .site-nav.on-dark {
  inset: 0 0 auto 0; margin: 0 auto; width: min(760px, calc(100% - 64px)); height: 58px; gap: 48px; padding: 0 26px;
  justify-content: space-between;
  background: var(--black); color: var(--off-white);
  border: 1px solid #F5F2ED14; border-top: 0;
  border-radius: 0 0 22px 22px;
  backdrop-filter: none;
  box-shadow: 0 1px 2px #0B0B0B29, 0 12px 28px -10px #0B0B0B59;
}
/* concave "ears" so the pill flows out of the top edge */
.site-nav::before, .site-nav::after {
  content: ""; position: absolute; top: 0; width: 22px; height: 22px; pointer-events: none;
  background: radial-gradient(circle at 0 100%, transparent 21.5px, var(--black) 22px);
}
.site-nav::before { left: -22px; background: radial-gradient(circle at 0 100%, transparent 21.5px, var(--black) 22px); }
.site-nav::after { right: -22px; background: radial-gradient(circle at 100% 100%, transparent 21.5px, var(--black) 22px); }
.brand { gap: 10px; font: 600 17px var(--font-body); letter-spacing: -.01em; color: var(--off-white); }
.brand-mark { width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; background: var(--crimson); box-shadow: inset 0 -2px 0 #0000002e, 0 2px 6px #8B0D1A66; }
.brand .brand-mark svg { width: 18px; height: 18px; color: var(--off-white); }
.site-nav nav, .site-nav.on-dark nav { display: flex; gap: 36px; font: 500 14px var(--font-body); color: #F5F2EDB3; }
.site-nav nav a { transition: color .2s; }
.site-nav nav a:hover, .site-nav.on-dark nav a:hover { color: var(--off-white); }
.nav-btn { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 12px; background: var(--off-white); color: var(--black); font: 600 13px var(--font-body); transition: background .2s, transform .2s; }
.nav-btn svg { width: 15px; height: 15px; color: var(--crimson); }
.nav-btn:hover { background: #fff; transform: translateY(-1px); }
@media (max-width: 900px) {
  .site-nav, .site-nav.on-dark { gap: 14px; }
  .site-nav nav { display: none !important; }
}
