/* ==========================================================
   Enains: design system (tokens from the Stitch design)
   Colors, fonts and spacing live in :root.
   ========================================================== */

:root {
  /* Surfaces: near-black charcoal, from darkest to lightest */
  --bg: #121315;
  --bg-lowest: #0c0d0e;
  --surface-low: #18191b;
  --surface: #1e1f22;
  --surface-high: #27282c;
  --surface-highest: #303136;
  --surface-bright: #3a3b40;

  /* Text: neutral whites and greys */
  --text: #f0f0f2;
  --text-2: #b4b6bd;
  --muted: #7f818a;
  --outline: #36373c;

  /* Background dot grid: dot colour and spacing */
  --dot: rgba(255, 255, 255, 0.14);
  --dot-bright: rgba(255, 255, 255, 0.7); /* dots under the cursor spotlight */
  --dot-gap: 18px;

  /* Brand: gold and silver, taken from the logo */
  --primary: #e6c56b;      /* light gold: labels, highlights */
  --primary-c: #d4a937;    /* gold: buttons, active states */
  --secondary: #c9ccd3;    /* silver */
  --secondary-c: #6b7280;  /* steel */
  --tertiary: #d4a937;     /* gold: dots, checks, live states */
  --tertiary-c: #a8801f;
  --violet: #d4a937;
  --gradient-btn: linear-gradient(90deg, #b8892a, #e2bd5a);
  --gradient-text: linear-gradient(90deg, #d4a937, #f3dc95);
  --glow: rgba(212, 169, 55, 0.35);

  --font-head: "Plus Jakarta Sans", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --header-h: 64px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --card-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04), 0 10px 30px -12px rgba(0, 0, 0, 0.5);
}

/* ---------- Base ---------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 22px;
  letter-spacing: -0.006em;
  color: var(--text);
  background-color: var(--bg);
  background-image: radial-gradient(circle, var(--dot) 1px, transparent 1.5px);
  background-size: var(--dot-gap) var(--dot-gap);
  position: relative;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { margin: 0; font-family: var(--font-head); font-weight: 700; letter-spacing: -0.025em; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button, input, select, textarea { font: inherit; color: inherit; }
::selection { background: var(--primary-c); color: #121315; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; border-radius: 6px; }

main, .site-footer { position: relative; z-index: 1; }
.container { width: min(1280px, 100% - 64px); margin-inline: auto; }
.muted { color: var(--muted); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.gradient-text {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Cursor spotlight: a brighter copy of the dot grid, revealed only in a soft circle around the mouse.
   It covers the whole page and uses the same grid, so the bright dots sit exactly on the normal ones.
   --mx / --my (page position of the mouse) and --spot-o (visibility) are set by layout/base.js. */
.dot-spot {
  position: fixed; /* screen-sized, so moving the spotlight only redraws the screen, not the whole page */
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image: radial-gradient(circle, var(--dot-bright) 1.3px, transparent 1.8px);
  background-size: var(--dot-gap) var(--dot-gap);
  background-position: 0 var(--dy, 0px); /* follows the scroll so these dots sit on the page's dots (layout/base.js) */
  -webkit-mask-image: radial-gradient(circle 170px at var(--mx, -999px) var(--my, -999px), #000 0%, rgba(0, 0, 0, 0.45) 45%, transparent 100%);
  mask-image: radial-gradient(circle 170px at var(--mx, -999px) var(--my, -999px), #000 0%, rgba(0, 0, 0, 0.45) 45%, transparent 100%);
  opacity: var(--spot-o, 0);
  transition: opacity .4s;
}

.skip-link { position: absolute; left: 16px; top: -100px; z-index: 100; padding: 10px 16px; border-radius: 8px; background: var(--primary-c); color: #fff; }
.skip-link:focus { top: 16px; }

/* ---------- Buttons, badges, small UI ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 14px 24px;
  border: 0;
  border-radius: 999px;
  font-family: var(--font-head);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.015em;
  cursor: pointer;
  transition: transform .25s var(--ease), box-shadow .3s, background .25s;
}
.btn .icon { transition: transform .25s var(--ease); }
.btn:hover .icon { transform: translateX(3px); }
.btn-primary { background: var(--gradient-btn); color: #121315; box-shadow: 0 12px 30px -10px rgba(0, 0, 0, .6); }
.btn-primary:hover { box-shadow: 0 0 36px rgba(212, 169, 55, 0.5); }
.btn-solid { background: var(--primary-c); color: #121315; box-shadow: 0 0 24px rgba(212, 169, 55, 0.35); }
.btn-solid:hover { box-shadow: 0 0 32px rgba(212, 169, 55, 0.55); }
.btn-ghost { background: rgba(42, 43, 48, 0.8); color: var(--text); backdrop-filter: blur(12px); }
.btn-ghost .icon { color: var(--text-2); }
.btn-ghost:hover { background: var(--surface-highest); }
.btn-ghost:hover .icon { transform: translateY(2px); }
.btn-sm { padding: 7px 14px; font-size: 13.5px; }
.btn:disabled { opacity: .6; cursor: wait; }

.badge {
  display: inline-block;
  width: fit-content;
  padding: 4px 12px;
  border-radius: 999px;
  font-family: var(--font-head);
  font-size: 11px;
  line-height: 16px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--primary);
  background: rgba(212, 169, 55, 0.2);
}
.badge-secondary { color: var(--secondary); background: rgba(201, 204, 211, 0.2); }
.badge-tertiary { color: var(--tertiary); background: rgba(212, 169, 55, 0.2); }

.eyebrow {
  display: block;
  font-family: var(--font-head);
  font-size: 11px;
  line-height: 16px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
}

.icon-tile {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--surface-high);
  transition: transform .3s var(--ease);
}

.card {
  position: relative;
  border-radius: 16px;
  background: rgba(33, 34, 38, 0.6);
  box-shadow: var(--card-shadow);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: background .3s, transform .3s var(--ease);
}
.card:hover { background: var(--surface); }
.card:hover .icon-tile { transform: scale(1.1); }

/* ---------- Header ---------- */

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  background: rgba(14, 15, 17, 0.8);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  box-shadow: 0 1px 8px rgba(0, 0, 0, 0.4);
}
.header-inner {
  height: var(--header-h);
  display: grid;
  grid-template-columns: 1fr auto 1fr; /* logo | centered links | button */
  align-items: center;
  gap: 24px;
}
.header-line { position: relative; height: 2px; background: linear-gradient(90deg, var(--primary-c), var(--secondary), var(--primary-c)); }
.header-line::before { content: ""; position: absolute; inset: 0; background: var(--bg-lowest); opacity: .7; }

.logo { justify-self: start; display: inline-flex; transition: transform .2s var(--ease), filter .3s; }
.logo img { width: auto; height: 40px; object-fit: contain; }
.logo:hover { transform: scale(1.05); filter: drop-shadow(0 0 14px rgba(234, 179, 8, .35)); }

.nav-links { display: flex; align-items: center; gap: 22px; }
.nav-links a:not(.btn) {
  position: relative;
  padding: 6px 0;
  color: var(--text-2);
  font-size: 13.5px;
  transition: color .2s;
}
.nav-links a:not(.btn)::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 2px;
  border-radius: 2px;
  background: var(--gradient-text);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .3s var(--ease);
}
.nav-links a:not(.btn):hover { color: var(--text); }
.nav-links a.active { color: var(--text); font-weight: 600; }
.nav-links a.active::after { transform: scaleX(1); }

.header-cta { justify-self: end; }
.nav-cta-mobile { display: none; }
.menu-toggle { display: none; grid-column: 3; justify-self: end; padding: 8px; border: 0; background: none; cursor: pointer; }
.menu-toggle .when-open,
.site-header.open .menu-toggle .when-closed { display: none; }
.site-header.open .menu-toggle .when-open { display: block; }

/* ---------- Section headings (every homepage section and the legal pages) ---------- */

.section { padding: clamp(64px, 9vw, 104px) 0; position: relative; }
.section-tight { padding-block: 24px; }
.section h2 { font-size: 40px; line-height: 48px; letter-spacing: -0.025em; color: var(--text); }
/* Refined heading: smaller and lighter than the standard section heading, for a quieter, premium feel */
.section h2.heading-refined { font-size: 32px; line-height: 40px; font-weight: 600; letter-spacing: -0.015em; }
.section-head { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; max-width: 672px; margin-bottom: 40px; }
.section-head p { font-size: 16px; line-height: 26px; color: var(--text-2); }
.section-head.center { align-items: center; max-width: 768px; margin-inline: auto; text-align: center; }

/* Glitch: brief RGB-split bursts every few seconds, readable the rest of the time */
.glitch { position: relative; display: block; animation: glitch-skew 6s infinite; }
.glitch::before,
.glitch::after { content: attr(data-text); position: absolute; inset: 0; opacity: 0; pointer-events: none; mix-blend-mode: screen; }
.glitch::before { color: var(--tertiary); animation: glitch-a 6s infinite; }
.glitch::after { color: #d4a937; animation: glitch-b 6s infinite; }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  min-height: max(100vh, 860px);
  display: flex;
  align-items: center;
  padding: calc(var(--header-h) + 48px) 0 72px;
  overflow: hidden;
}

/* minmax(0, 1fr): columns never grow to fit content, so the headline's decode effect can't push the layout */
.hero-inner { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); align-items: center; gap: 40px; }
.hero-content { display: flex; flex-direction: column; align-items: flex-start; gap: 24px; }

.hero h1 { font-size: 56px; line-height: 64px; letter-spacing: -0.03em; font-weight: 700; color: var(--text); }
.rotator-line { display: block; white-space: nowrap; }
/* white-space: pre keeps a just-typed space, so the cursor advances exactly one character at a time.
   A fixed gradient width (in em, so it scales with the font) keeps each letter's colour steady while the text grows. */
.rotator { display: inline-block; min-height: 1em; white-space: pre; background-size: 11em 100%; background-repeat: no-repeat; }
/* Typewriter cursor after the rotating phrase: solid while typing, gently blinking at rest */
.type-caret {
  display: inline-block;
  width: 3px;
  height: .82em;
  margin-left: 6px;
  vertical-align: -0.06em;
  border-radius: 2px;
  background: var(--primary-c);
  box-shadow: 0 0 10px rgba(212, 169, 55, 0.45);
  animation: caret-blink 1.1s ease-in-out infinite;
}
.type-caret.typing { animation: none; opacity: 1; }
@keyframes caret-blink { 0%, 45% { opacity: 1; } 55%, 100% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .type-caret { display: none; } }
.hero-text { max-width: 576px; font-size: 16px; line-height: 26px; letter-spacing: -0.011em; color: var(--text-2); }
.actions { display: flex; flex-wrap: wrap; gap: 16px; padding-top: 4px; }

/* Trust points under the buttons: gold check marks, thin dividers, muted text */
.hero-highlights { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 0; padding-top: 12px; font-size: 13px; line-height: 20px; font-weight: 500; color: var(--text-2); }
.hero-highlights li { display: inline-flex; align-items: center; gap: 7px; }
.hero-highlights li + li { margin-left: 16px; padding-left: 16px; border-left: 1px solid rgba(255, 255, 255, 0.14); }
.hero-highlights .icon { flex-shrink: 0; color: var(--primary-c); stroke-width: 2.5; }

/* Hero visual: "ENA Product Engine" animation.
   Designed at 620 × 560 and scaled down to fit its column (hero.js sets --engine-scale).
   Everything is scoped under .engine so its class names never clash with the rest of the site. */
.hero-visual { position: relative; height: calc(560px * var(--engine-scale, 1)); }
.engine {
  --gold: var(--primary-c);
  --line: rgba(255, 255, 255, 0.12);
  position: absolute;
  top: 0;
  left: 50%;
  width: 620px;
  height: 560px;
  margin-left: -310px;
  transform: scale(var(--engine-scale, 1));
  transform-origin: top center;
}
.engine-glow { position: absolute; inset: 0; background: radial-gradient(circle at 50% 48%, rgba(212, 169, 55, 0.07), transparent 34%); }

/* Pulsing halo with two spinning rings */
.engine .halo {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  border: 1px solid rgba(212, 169, 55, 0.14);
  box-shadow: 0 0 80px rgba(212, 169, 55, 0.05), inset 0 0 50px rgba(212, 169, 55, 0.03);
  transform: translate(-50%, -50%);
  animation: engine-pulse 4.5s ease-in-out infinite;
}
.engine .halo::before,
.engine .halo::after { content: ""; position: absolute; inset: 24px; border-radius: 50%; border: 1px dashed rgba(255, 255, 255, 0.09); animation: engine-spin 22s linear infinite; }
.engine .halo::after { inset: 54px; border-style: solid; border-color: rgba(212, 169, 55, 0.12); animation-direction: reverse; animation-duration: 15s; }

/* Octagonal core with the ENA logo */
.engine .core {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 5;
  width: 150px;
  height: 150px;
  display: grid;
  place-items: center;
  transform: translate(-50%, -50%);
  background: linear-gradient(145deg, #1a1a1c, #0a0a0b 65%);
  box-shadow: 0 0 35px rgba(212, 169, 55, 0.15), inset 0 0 30px rgba(255, 255, 255, 0.03);
  clip-path: polygon(18% 0, 82% 0, 100% 18%, 100% 82%, 82% 100%, 18% 100%, 0 82%, 0 18%);
}
.engine .core { border: 1px solid rgba(212, 169, 55, 0.6); }
.engine .core::after { content: ""; position: absolute; inset: 12px; border: 1px solid rgba(255, 255, 255, 0.09); clip-path: inherit; }
.engine .core-label { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; text-transform: uppercase; white-space: nowrap; }
.engine .core-label strong { font-family: var(--font-head); font-size: 15px; font-weight: 800; letter-spacing: .18em; margin-right: -.18em; color: #fff; text-shadow: 0 0 16px rgba(212, 169, 55, 0.45); }
.engine .core-label small { font-size: 7.5px; font-weight: 600; letter-spacing: .3em; margin-right: -.3em; color: var(--primary); }

/* Connection lines with moving data packets */
.engine .links { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; overflow: visible; }
.engine .link { fill: none; stroke: rgba(212, 169, 55, 0.2); stroke-width: 1; }
.engine .packet { fill: var(--gold); filter: drop-shadow(0 0 5px rgba(212, 169, 55, 0.8)); }

/* Four product nodes in the corners */
.engine .node {
  position: absolute;
  z-index: 4;
  width: 148px;
  height: 72px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: linear-gradient(145deg, rgba(24, 24, 26, 0.96), rgba(10, 10, 11, 0.94));
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
}
.engine .node-eyebrow { font-size: 7px; letter-spacing: .18em; text-transform: uppercase; color: #888; }
.engine .node-title { margin-top: 5px; font-size: 11.5px; font-weight: 700; color: #eee; white-space: nowrap; }
.engine .node-bar { height: 3px; margin-top: 8px; border-radius: 4px; background: #262626; overflow: hidden; }
.engine .node-bar span { display: block; width: 65%; height: 100%; background: var(--gold); animation: engine-load 2.6s ease-in-out infinite; }
.engine .node-web { left: 5%; top: 20%; animation: engine-float-up 5.2s ease-in-out infinite; }
.engine .node-mobile { right: 5%; top: 21%; animation: engine-float-down 5.8s ease-in-out infinite; }
.engine .node-ai { left: 8%; bottom: 17%; animation: engine-float-down 6.2s ease-in-out infinite; }
.engine .node-automation { right: 8%; bottom: 16%; animation: engine-float-up 5.6s ease-in-out infinite; }

/* Phone and browser mock-ups */
.engine .phone {
  position: absolute;
  right: 18%;
  top: 42%;
  z-index: 3;
  width: 78px;
  height: 138px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 16px;
  background: #0b0b0c;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
  transform: rotate(7deg);
  animation: engine-phone 5.5s ease-in-out infinite;
}
.engine .phone::before {
  content: "";
  position: absolute;
  inset: 16px 9px 10px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 9px;
  background: linear-gradient(180deg, rgba(212, 169, 55, 0.17), transparent 35%), #111113;
}
.engine .phone-bar { position: absolute; left: 17px; right: 17px; top: 31px; height: 5px; border-radius: 4px; background: #303030; }
.engine .phone-chart { position: absolute; left: 17px; right: 17px; top: 51px; height: 35px; }
.engine .phone-chart path { fill: none; stroke: var(--gold); stroke-width: 2; }
.engine .phone-dot { position: absolute; right: 18px; top: 48px; width: 5px; height: 5px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 10px var(--gold); }

.engine .browser {
  position: absolute;
  left: 16%;
  top: 52%;
  z-index: 3;
  width: 128px;
  height: 88px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 10px;
  background: #0d0d0e;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.45);
  transform: rotate(-5deg);
  animation: engine-browser 6s ease-in-out infinite;
}
.engine .browser-top { display: flex; align-items: center; gap: 4px; height: 18px; padding-left: 8px; border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
.engine .browser-top i { width: 4px; height: 4px; border-radius: 50%; background: #555; }
.engine .browser-screen { height: 50px; margin: 9px; padding: 7px; border-radius: 5px; background: #141415; }
.engine .browser-screen b { display: block; width: 45%; height: 5px; margin-bottom: 8px; border-radius: 3px; background: #ddd; }
.engine .browser-screen span { display: block; height: 4px; margin: 5px 0; border-radius: 3px; background: #2a2a2a; }
.engine .browser-screen span.gold { width: 68%; background: var(--gold); }

@keyframes engine-pulse { 50% { transform: translate(-50%, -50%) scale(1.05); opacity: .78; } }
@keyframes engine-float-up { 50% { transform: translateY(-9px); } }
@keyframes engine-float-down { 50% { transform: translateY(8px); } }
@keyframes engine-phone { 50% { transform: rotate(4deg) translateY(-7px); } }
@keyframes engine-browser { 50% { transform: rotate(-2deg) translateY(7px); } }
@media (prefers-reduced-motion: reduce) { .engine .packet { display: none; } }

@media (max-width: 1024px) {
  .hero-inner { grid-template-columns: minmax(0, 1fr); }
  .hero { min-height: 0; padding-top: var(--header-h); }
  /* Stacked layout: the text starts well below the navbar (scaled to the screen height) and the animation
     follows a short, even distance below it, peeking in at the bottom of the first screen */
  .hero-content { padding-top: clamp(48px, 14vh, 140px); padding-top: clamp(48px, 14svh, 140px); }
  .hero-inner { gap: 32px; }
  .hero-visual { max-width: 640px; width: 100%; margin: calc(-96px * var(--engine-scale, 1)) auto calc(-72px * var(--engine-scale, 1)); } /* trims the empty bands above and below the animation's content */
}

@media (max-width: 640px) {
  .hero { padding-top: var(--header-h); }
  .hero h1 { font-size: min(32px, 8.4vw); line-height: 1.3; } /* scales so the longest phrase stays on one line */
  .hero .actions .btn { flex: 1 1 100%; }
  .hero-highlights { flex-direction: column; align-items: flex-start; gap: 8px; } /* stacked on phones, no dividers */
  .hero-highlights li + li { margin-left: 0; padding-left: 0; border-left: 0; }
}

/* ---------- About ---------- */

.about-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: 56px; align-items: center; }
.about-story { display: flex; flex-direction: column; gap: 16px; }
.about-story .values { margin-top: 12px; }
.about-visual { position: relative; }
.about-visual::before { /* soft gold glow behind the diagram, as behind the hero engine */
  content: ""; position: absolute; inset: -10% -6%; z-index: -1; pointer-events: none;
  background: radial-gradient(circle at 50% 62%, rgba(212, 169, 55, 0.09), transparent 60%);
}
.about-story .lead { font-size: 16px; line-height: 26px; color: var(--text); }
.about-story p { color: var(--text-2); }
/* Services stack: drawn in the same language as the hero engine. Three glass service nodes with small
   animated mock-ups, gold packets flowing up from the artificial intelligence core into each of them. */
.stack { display: flex; flex-direction: column; gap: 24px; }
.stack h3 { font-family: var(--font-body); font-size: 11px; line-height: 16px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; text-align: center; color: var(--muted); }
.stack-diagram { --gold: var(--primary-c); position: relative; display: flex; flex-direction: column; gap: 64px; }

.stack-nodes { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.stack-node {
  position: relative; display: flex; flex-direction: column; gap: 10px; padding: 16px 14px;
  border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 12px;
  background: linear-gradient(145deg, rgba(24, 24, 26, 0.96), rgba(10, 10, 11, 0.94));
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.4);
}
.stack-node::after { /* socket where the connector arrives */
  content: ""; position: absolute; left: 50%; bottom: -4px; width: 7px; height: 7px; margin-left: -3.5px; border-radius: 50%;
  border: 1px solid rgba(212, 169, 55, 0.7); background: #0b0b0c;
}
.stack-eyebrow { font-size: 8px; line-height: 12px; letter-spacing: .18em; text-transform: uppercase; color: #888; }
.stack-title { width: min-content; font-size: 13px; line-height: 18px; font-weight: 700; color: #eee; } /* one word per line, so all three names line up */
.stack-bar { height: 3px; margin-top: auto; border-radius: 4px; background: #262626; overflow: hidden; }
.stack-bar span { display: block; width: 60%; height: 100%; background: var(--gold); animation: engine-load 2.6s ease-in-out infinite; animation-delay: calc(var(--i) * -0.8s); }

/* Mock-ups: a browser, a phone with a live chart, a three-step workflow with a task moving through it */
.stack-mock { display: grid; place-items: center; height: 64px; }
.mock-browser { width: 100%; max-width: 132px; height: 60px; border: 1px solid rgba(255, 255, 255, 0.13); border-radius: 6px; background: #0d0d0e; overflow: hidden; }
.mock-browser-top { display: flex; align-items: center; gap: 3px; height: 12px; padding-left: 5px; border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
.mock-browser-top i { width: 3px; height: 3px; border-radius: 50%; background: #555; }
.mock-browser b { display: block; width: 45%; height: 5px; margin: 10px 9px 8px; border-radius: 3px; background: #ddd; }
.mock-browser span { display: block; height: 4px; margin: 6px 9px; border-radius: 3px; background: #2a2a2a; }
.mock-browser span.gold { background: var(--gold); animation: engine-load 3s ease-in-out infinite; }

.mock-phone { position: relative; width: 38px; height: 60px; padding: 12px 5px 0; border: 1px solid rgba(255, 255, 255, 0.18); border-radius: 7px; background: linear-gradient(180deg, rgba(212, 169, 55, 0.15), transparent 45%), #0b0b0c; }
.mock-phone svg { display: block; width: 100%; height: 18px; overflow: visible; }
.mock-phone path { fill: none; stroke: var(--gold); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 100; animation: stack-draw 3.2s ease-in-out infinite; }
.mock-phone span { display: block; height: 2.5px; margin-top: 4px; border-radius: 2px; background: #303030; }
.mock-phone span + span { width: 60%; }

.mock-flow { position: relative; width: 100%; max-width: 132px; height: 60px; }
.mock-flow::before { content: ""; position: absolute; left: 10%; right: 10%; top: 50%; height: 1px; background: rgba(255, 255, 255, 0.16); }
.mock-flow i { position: absolute; top: 50%; width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 3px; border: 1px solid rgba(255, 255, 255, 0.22); background: #141415; }
.mock-flow i:nth-child(1) { left: 10%; }
.mock-flow i:nth-child(2) { left: 50%; border-color: rgba(212, 169, 55, 0.6); }
.mock-flow i:nth-child(3) { left: 90%; }
.mock-flow span { position: absolute; top: 50%; left: 10%; width: 6px; height: 6px; margin: -3px 0 0 -3px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 8px var(--gold); animation: stack-travel 2.8s ease-in-out infinite; }

/* Connectors (paths are set by about.js) */
.stack-links { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.stack-link { fill: none; stroke: rgba(212, 169, 55, 0.25); stroke-width: 1; }
.stack-packet { fill: var(--gold); filter: drop-shadow(0 0 5px rgba(212, 169, 55, 0.8)); }

/* The artificial intelligence core */
.stack-core {
  position: relative; z-index: 1; overflow: hidden; display: flex; align-items: center; gap: 14px; padding: 18px 20px;
  border: 1px solid rgba(212, 169, 55, 0.55); border-radius: 16px;
  background: radial-gradient(120% 160% at 50% 0%, rgba(212, 169, 55, 0.16), transparent 60%), linear-gradient(145deg, #17171a, #0b0b0c);
  box-shadow: 0 0 0 4px rgba(212, 169, 55, 0.04), 0 12px 35px rgba(0, 0, 0, 0.45), 0 0 40px -12px rgba(212, 169, 55, 0.4);
}
.stack-core::before { content: ""; position: absolute; inset: 5px; border: 1px solid rgba(255, 255, 255, 0.06); border-radius: 12px; pointer-events: none; }
.stack-core::after { /* slow light sweep */
  content: ""; position: absolute; inset: 0; transform: translateX(-100%); pointer-events: none;
  background: linear-gradient(100deg, transparent 30%, rgba(255, 255, 255, 0.07) 50%, transparent 70%);
  animation: sweep 5s ease-in-out infinite;
}
.stack-core-icon { display: grid; place-items: center; flex-shrink: 0; width: 44px; height: 44px; border-radius: 50%; color: var(--gold); border: 1px solid rgba(212, 169, 55, 0.6); background: rgba(212, 169, 55, 0.12); animation: stack-pulse 2.8s ease-in-out infinite; }
.stack-core-label { display: flex; flex-direction: column; gap: 4px; min-width: 0; text-transform: uppercase; }
.stack-core-label strong { font-family: var(--font-head); font-size: 15px; line-height: 18px; font-weight: 800; letter-spacing: .16em; color: #fff; text-shadow: 0 0 16px rgba(212, 169, 55, 0.45); }
.stack-core-label small { font-size: 9px; line-height: 12px; font-weight: 600; letter-spacing: .26em; color: var(--primary); }
.stack-signal { display: flex; align-items: flex-end; gap: 3px; height: 22px; margin-left: auto; }
.stack-signal i { width: 3px; height: 30%; border-radius: 2px; background: var(--gold); animation: stack-signal 1.4s ease-in-out infinite; }
.stack-signal i:nth-child(2) { animation-delay: -0.3s; }
.stack-signal i:nth-child(3) { animation-delay: -0.6s; }
.stack-signal i:nth-child(4) { animation-delay: -0.9s; }
.stack-signal i:nth-child(5) { animation-delay: -1.2s; }

@keyframes sweep { 0%, 40% { transform: translateX(-100%); } 80%, 100% { transform: translateX(100%); } }
@keyframes stack-draw { 0% { stroke-dashoffset: 100; } 45%, 80% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: -100; } }
@keyframes stack-travel { 0%, 10% { left: 10%; } 45%, 55% { left: 50%; } 90%, 100% { left: 90%; } }
@keyframes stack-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(212, 169, 55, 0.35); } 50% { box-shadow: 0 0 0 6px rgba(212, 169, 55, 0); } }
@keyframes stack-signal { 0%, 100% { height: 25%; } 50% { height: 100%; } }
@media (prefers-reduced-motion: reduce) { .stack-packet { display: none; } }

/* The two principle cards overlap: the first sits top-left, the second is lifted over it, offset down-right */
/* The first card keeps extra space at its foot, and the second only ever overlaps that empty space,
   so no text is covered whatever its length */
.values { display: flex; flex-direction: column; }
.values .value-card { width: 62%; }
.values .value-card:nth-child(1) { padding-bottom: 84px; }
.values .value-card:nth-child(2) {
  z-index: 1; margin: -60px 0 0 auto;
  background-color: var(--surface); /* opaque, so the card underneath does not show through */
  box-shadow: var(--card-shadow), 0 24px 48px -16px rgba(0, 0, 0, 0.7);
}
.value-card { display: flex; flex-direction: column; gap: 8px; padding: 20px; }
.value-card .icon-tile { width: 40px; height: 40px; border-radius: 10px; }
.value-card h3 { font-size: 18px; line-height: 26px; letter-spacing: -0.015em; font-weight: 600; margin-top: 6px; }
.value-card p { font-size: 13px; line-height: 20px; color: var(--text-2); }

/* Principle cards: gold gradient edge, outlined number, a gold accent line that extends on hover,
   and a gold spotlight that follows the cursor (layout/base.js sets --x / --y). The card being looked at
   lifts forward while the other one recedes slightly. */
.values .value-card {
  overflow: hidden; isolation: isolate; outline: none;
  background-image: linear-gradient(90deg, var(--primary), rgba(212, 169, 55, 0));
  background-repeat: no-repeat; background-size: 44px 2px; background-position: 20px 0;
  transition: translate .45s var(--ease), scale .45s var(--ease), opacity .35s, box-shadow .45s var(--ease), background-size .6s var(--ease), background-color .3s;
}
.values .value-card::before { /* cursor spotlight */
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: 0; transition: opacity .35s;
  background: radial-gradient(360px circle at var(--x, 70%) var(--y, 0%), rgba(212, 169, 55, 0.14), transparent 45%);
}
.values .value-card::after { /* gradient edge: gold at the corners, quiet along the sides */
  content: ""; position: absolute; inset: 0; padding: 1px; border-radius: inherit; pointer-events: none; opacity: .45; transition: opacity .45s;
  background: linear-gradient(135deg, rgba(230, 197, 107, 0.7), rgba(255, 255, 255, 0.05) 35%, rgba(255, 255, 255, 0.03) 65%, rgba(212, 169, 55, 0.45));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
}
.value-num {
  position: absolute; top: 14px; right: 18px; font-family: var(--font-head); font-size: 56px; line-height: 1; font-weight: 800; letter-spacing: -0.04em;
  color: transparent; -webkit-text-stroke: 1px rgba(255, 255, 255, 0.09); pointer-events: none;
  transition: -webkit-text-stroke-color .45s, translate .45s var(--ease);
}
.values .value-card .icon-tile { background: rgba(212, 169, 55, 0.1); box-shadow: inset 0 0 0 1px rgba(212, 169, 55, 0.18); transition: transform .45s var(--ease), box-shadow .45s, background .45s; }

.values .value-card:is(:hover, :focus-visible) {
  z-index: 3; translate: 0 -6px; background-size: calc(100% - 40px) 2px;
  box-shadow: 0 30px 60px -22px rgba(0, 0, 0, 0.85), 0 0 48px -14px rgba(212, 169, 55, 0.35);
}
.values .value-card:is(:hover, :focus-visible)::before { opacity: 1; }
.values .value-card:is(:hover, :focus-visible)::after { opacity: 1; }
.values .value-card:is(:hover, :focus-visible) .value-num { -webkit-text-stroke-color: rgba(230, 197, 107, 0.45); translate: -4px 2px; }
.values .value-card:is(:hover, :focus-visible) .icon-tile {
  transform: rotate(-8deg) scale(1.08); background: rgba(212, 169, 55, 0.2);
  box-shadow: inset 0 0 0 1px rgba(212, 169, 55, 0.5), 0 0 22px -4px rgba(212, 169, 55, 0.55);
}
/* the other card steps back */
.values:has(.value-card:is(:hover, :focus-visible)) .value-card:not(:hover, :focus-visible) { opacity: .55; scale: .98; }

@media (max-width: 1024px) {
  .about-grid { grid-template-columns: minmax(0, 1fr); }
  .about-visual { width: 100%; max-width: 560px; margin-inline: auto; }
}

@media (max-width: 640px) {
  /* Phones: too narrow to overlap, so the cards stack with a slight stagger instead */
  .values { gap: 12px; }
  .values .value-card { width: calc(100% - 24px); }
  .values .value-card:nth-child(1) { padding-bottom: 20px; }
  .values .value-card:nth-child(2) { margin-top: 0; }
  .values .value-card { pointer-events: none; } /* phones: plain, static blocks; no hover, focus or tap effects */
  .stack-diagram { gap: 48px; }
  .stack-nodes { gap: 10px; }
  .stack-node { padding: 10px 8px; }
  .stack-mock { height: 50px; }
  .mock-browser, .mock-flow { height: 46px; }
  .mock-phone { width: 30px; height: 46px; padding-top: 9px; }
  .mock-phone svg { height: 14px; }
  .mock-browser b { margin: 7px 7px 6px; }
  .mock-browser span { margin: 4px 7px; height: 3px; }
  .stack-title { font-size: 11px; line-height: 15px; }
  .stack-core { gap: 12px; padding: 12px; }
  .stack-core-icon { width: 36px; height: 36px; }
  .stack-core-label strong { font-size: 11px; letter-spacing: .1em; }
  .stack-core-label small { font-size: 8px; }
  .stack-signal { display: none; }
}

/* ---------- Capabilities ---------- */

/* Capabilities carousel: equal glass cards travelling round a horizontal 3D arc. build.js positions every
   card and gives it --f (1 = in front, 0 = turned away), which drives its brightness and gold edge.
   Without JavaScript the cards sit in a simple scrolling row. */
.cap { --card-w: 400px; --card-h: 420px; position: relative; }
.cap-stage { display: flex; gap: 16px; overflow-x: auto; padding-block: 8px; }
.cap-card {
  position: relative; flex: 0 0 var(--card-w); width: var(--card-w); height: var(--card-h); overflow: hidden;
  display: flex; flex-direction: column; gap: 12px; padding: 28px; border-radius: 28px;
  background:
    linear-gradient(155deg, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0.02) 38%, rgba(255, 255, 255, 0) 60%),
    radial-gradient(120% 80% at 50% 0%, rgba(212, 169, 55, 0.1), transparent 60%),
    rgba(24, 25, 28, 0.94);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 30px 60px -28px rgba(0, 0, 0, 0.9);
}
.cap-card::after { /* gold glass edge, brightest on the front card */
  content: ""; position: absolute; inset: 0; padding: 1px; border-radius: inherit; pointer-events: none; opacity: calc(.25 + .75 * var(--f, 1));
  background: linear-gradient(140deg, rgba(240, 210, 130, 0.85), rgba(255, 255, 255, 0.08) 30%, rgba(255, 255, 255, 0.04) 70%, rgba(212, 169, 55, 0.6));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
}
.cap-card::before { /* glass sheen */
  content: ""; position: absolute; inset: -40% -60% auto auto; width: 70%; height: 90%; pointer-events: none;
  background: radial-gradient(closest-side, rgba(255, 255, 255, 0.06), transparent); transform: rotate(20deg);
}
.cap-top { display: flex; align-items: center; justify-content: space-between; }
.cap-icon { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 16px; color: var(--primary); background: rgba(212, 169, 55, 0.12); box-shadow: inset 0 0 0 1px rgba(212, 169, 55, 0.3), 0 0 24px -8px rgba(212, 169, 55, 0.5); }
.cap-num { font-family: var(--font-head); font-size: 56px; line-height: 1; font-weight: 800; letter-spacing: -0.04em; color: transparent; -webkit-text-stroke: 1px rgba(230, 197, 107, 0.3); }
.cap-label { margin-top: 6px; font-size: 11px; line-height: 16px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--primary); }
.cap-card h3 { margin-top: 4px; font-size: 26px; line-height: 34px; letter-spacing: -0.02em; font-weight: 700; }
.cap-card p { font-size: 14px; line-height: 22px; color: var(--text-2); }
.cap-points { display: flex; flex-direction: column; gap: 9px; margin-top: auto; padding-top: 14px; border-top: 1px solid rgba(255, 255, 255, 0.07); font-size: 13px; line-height: 18px; color: var(--text); }
.cap-points li { display: flex; align-items: center; gap: 9px; }
.cap-points .icon { flex-shrink: 0; color: var(--primary-c); stroke-width: 2.5; }

/* 3D arc (only when JavaScript runs) */
.js .cap { margin-inline: calc(50% - 50vw); overflow: hidden; }
.js .cap-stage { display: grid; place-items: center; overflow: visible; height: calc(var(--card-h) + 48px); perspective: 1800px; cursor: grab; touch-action: pan-y; user-select: none; }
.js .cap-stage:active { cursor: grabbing; }
.js .cap-ring { position: relative; width: var(--card-w); height: var(--card-h); transform-style: preserve-3d; }
.js .cap-card { position: absolute; inset: 0; will-change: transform, opacity; filter: brightness(calc(.4 + .6 * var(--f, 1))); }

/* Controls */
.cap-controls { display: flex; align-items: center; justify-content: center; gap: 18px; margin-top: 18px; }
.cap-arrow { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; color: var(--text); background: var(--surface); box-shadow: var(--card-shadow); transition: background .25s, color .25s, transform .25s var(--ease); }
.cap-arrow:hover { background: var(--surface-high); color: var(--primary); }
.cap-arrow[data-step="-1"] .icon { transform: rotate(180deg); }
.cap-dots { display: flex; gap: 8px; }
.cap-dots button { width: 8px; height: 8px; border-radius: 99px; background: rgba(255, 255, 255, 0.2); transition: width .35s var(--ease), background .35s; }
.cap-dots button.is-active { width: 26px; background: var(--primary-c); }

@media (max-width: 640px) {
  .cap { --card-w: min(300px, 78vw); --card-h: 456px; }
  .cap-card { padding: 22px; }
  .cap-card h3 { font-size: 22px; line-height: 30px; }
}

/* ---------- Process ---------- */

/* Process: 3D solar system (process3d.js). Hidden until WebGL starts; the stage list works on its own.
   Frameless and full-bleed: the scene spans the whole screen width directly on the dotted background.
   Only the canvas fades out at the edges, so the key and caption panel stay crisp. */
.orrery {
  --inset: calc((100vw - min(1280px, 100vw - 64px)) / 2); /* lines overlays up with the page content column */
  display: none;
  position: relative;
  width: 100vw;
  margin-left: calc(50% - 50vw);
  height: clamp(680px, 92vh, 980px); /* nearly a full screen tall, so the system can be large */
  margin-bottom: 24px;
  overflow: hidden;
  cursor: grab;
  touch-action: pan-y;
}
.js .orrery { display: block; }           /* space reserved from the start, so the page never jumps */
.orrery.no-3d { display: none; }          /* device without WebGL, or the library failed to load */
.orrery:active { cursor: grabbing; }
.orrery canvas {
  display: block;
  width: 100%;
  height: 100%;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent), linear-gradient(to bottom, transparent, #000 5%, #000 95%, transparent);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent), linear-gradient(to bottom, transparent, #000 5%, #000 95%, transparent);
  mask-composite: intersect;
}

/* Key: what the sun and planets represent (top-left, fixed) */
.orrery-key { position: absolute; top: 56px; left: var(--inset); display: flex; flex-direction: column; gap: 8px; font-size: 12px; color: var(--text-2); pointer-events: none; }
.orrery-key span { display: inline-flex; align-items: center; gap: 10px; }
.orrery-key i { width: 10px; height: 10px; border-radius: 50%; }
.key-sun { background: radial-gradient(circle, #fff7d6, #f59e0b 60%); box-shadow: 0 0 10px rgba(251, 191, 36, 0.7); }
.key-planet { width: 8px !important; height: 8px !important; margin: 0 1px; background: var(--secondary); box-shadow: 0 0 0 3px rgba(201, 204, 211, 0.15); }

/* Caption panel: the stage in focus (bottom-left, fixed; fades between stages) */
.orrery-caption {
  position: absolute;
  left: var(--inset);
  bottom: 64px;
  width: 340px;
  padding: 20px 22px;
  border-radius: 16px;
  background: rgba(24, 25, 27, 0.72);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.07), 0 20px 40px -16px rgba(0, 0, 0, 0.7);
  pointer-events: none;
}
.orrery-caption::before { content: ""; position: absolute; left: 0; top: 20px; bottom: 20px; width: 2px; border-radius: 2px; background: var(--c, var(--primary-c)); transition: background .4s; }
.orrery-caption > :not(.caption-dots) { transition: opacity .22s ease, transform .22s ease; }
.orrery-caption.is-changing > :not(.caption-dots) { opacity: 0; transform: translateY(4px); }
.caption-count { display: block; font-family: var(--font-head); font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--primary-c); }
.caption-title { margin: 6px 0 6px; font-size: 22px; line-height: 28px; letter-spacing: -0.02em; color: var(--text); }
.caption-text { font-size: 13px; line-height: 20px; color: var(--text-2); }
.caption-dots { display: flex; gap: 6px; margin-top: 16px; }
.caption-dots i { width: 6px; height: 6px; border-radius: 999px; background: rgba(255, 255, 255, 0.16); transition: width .4s var(--ease), background .4s; }
.caption-dots i.is-done { background: rgba(212, 169, 55, 0.45); }
.caption-dots i.is-active { width: 22px; background: var(--primary-c); }
.caption-hint { display: none; }

/* Lifecycle cards. The top line of each card is one segment of the delivery track: gold when the stage is
   complete, filling in gold while the stage is in focus (timed to the solar system), quiet when upcoming.
   Finish matches the About cards: gradient edge, outlined number, cursor spotlight (layout/base.js sets --x / --y).
   --c is the matching planet's colour (set by process3d.js) and is only used for the small planet dot. */
.stages { position: relative; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.stage {
  position: relative; isolation: isolate; overflow: hidden;
  display: flex; flex-direction: column; gap: 10px;
  padding: 22px 20px 20px; border-radius: 16px;
  background: rgba(33, 34, 38, 0.55); box-shadow: var(--card-shadow);
  cursor: pointer; outline: none;
  transition: translate .45s var(--ease), opacity .35s, background-color .3s, box-shadow .45s var(--ease);
}
.stage::before { /* cursor spotlight */
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: 0; transition: opacity .35s;
  background: radial-gradient(320px circle at var(--x, 70%) var(--y, 0%), rgba(212, 169, 55, 0.13), transparent 45%);
}
.stage::after { /* gradient edge */
  content: ""; position: absolute; inset: 0; padding: 1px; border-radius: inherit; pointer-events: none; opacity: .3; transition: opacity .45s;
  background: linear-gradient(135deg, rgba(230, 197, 107, 0.65), rgba(255, 255, 255, 0.05) 35%, rgba(255, 255, 255, 0.03) 65%, rgba(212, 169, 55, 0.4));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
}

/* Track segment */
.stage-line { position: absolute; left: 0; right: 0; top: 0; height: 2px; background: rgba(255, 255, 255, 0.07); }
.stage-line::after { content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 0; background: linear-gradient(90deg, var(--primary-c), var(--primary)); }
.stage.is-done .stage-line::after { width: 100%; opacity: .7; }
.stage.active .stage-line::after { width: 100%; box-shadow: 0 0 12px rgba(212, 169, 55, 0.7); animation: stage-fill var(--stage-time, 4.5s) linear both; }

/* Header: track node, stage label with planet dot, stage icon */
.stage-top { display: flex; align-items: center; gap: 10px; }
.stage-node {
  display: grid; place-items: center; flex-shrink: 0; width: 22px; height: 22px; border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: radial-gradient(circle, rgba(255, 255, 255, 0.35) 0 2px, transparent 2.5px), #141416;
  transition: border-color .35s, background .35s, box-shadow .35s;
}
.stage-node .icon { opacity: 0; color: #121315; stroke-width: 3; transition: opacity .3s; }
.stage.active .stage-node {
  border-color: var(--primary-c);
  background: radial-gradient(circle, var(--primary) 0 3.5px, transparent 4px), rgba(212, 169, 55, 0.12);
  animation: stage-pulse 2s ease-in-out infinite;
}
.stage.is-done .stage-node { border-color: var(--primary-c); background: linear-gradient(135deg, var(--primary), var(--primary-c)); }
.stage.is-done .stage-node .icon { opacity: 1; }
.stage-num { display: inline-flex; align-items: center; gap: 7px; font-size: 11px; line-height: 16px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
.stage-planet { width: 6px; height: 6px; border-radius: 50%; background: var(--c, var(--primary-c)); box-shadow: 0 0 6px var(--c, var(--primary-c)); }
.stage.active .stage-num { color: var(--primary); }
.stage.active .stage-num::after { content: "· In Progress"; }
.stage.is-done .stage-num { color: var(--text-2); }
.stage.is-done .stage-num::after { content: "· Complete"; }
.stage-icon { display: flex; margin-left: auto; color: var(--muted); transition: color .35s; }
.stage.active .stage-icon { color: var(--primary); }

.stage h3 { margin-top: 4px; font-size: 18px; line-height: 26px; letter-spacing: -0.015em; font-weight: 600; }
.stage p { font-size: 13px; line-height: 20px; color: var(--text-2); }
.stage-big {
  position: absolute; right: 14px; bottom: -12px; z-index: -1; pointer-events: none;
  font-family: var(--font-head); font-size: 76px; line-height: 1; font-weight: 800; letter-spacing: -0.04em;
  color: transparent; -webkit-text-stroke: 1px rgba(255, 255, 255, 0.05); transition: -webkit-text-stroke-color .45s;
}

/* Active and hovered states */
.stage.active { background-color: var(--surface); translate: 0 -4px; box-shadow: var(--card-shadow), 0 26px 44px -26px rgba(212, 169, 55, 0.5); }
.stage.active::after, .stage:is(:hover, :focus-visible)::after { opacity: 1; }
.stage.active .stage-big { -webkit-text-stroke-color: rgba(230, 197, 107, 0.28); }
.stage:is(:hover, :focus-visible) { background-color: var(--surface); translate: 0 -4px; }
.stage:is(:hover, :focus-visible)::before { opacity: 1; }
.stages:has(.stage:is(:hover, :focus-visible)) .stage:not(:hover, :focus-visible) { opacity: .6; }

/* All stages complete: a gold glow ripples across the cards, the success badge rises in, confetti plays above */
.stages-wrap { position: relative; }
.stages-confetti { position: absolute; left: 0; top: -140px; z-index: 5; width: 100%; height: calc(100% + 164px); pointer-events: none; }
.stages-done {
  position: absolute; left: 50%; top: 50%; z-index: 6; display: inline-flex; align-items: center; gap: 10px;
  padding: 12px 22px 12px 14px; border-radius: 999px; white-space: nowrap; pointer-events: none;
  font-family: var(--font-head); font-size: 14px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: #fff;
  border: 1px solid rgba(212, 169, 55, 0.65);
  background: radial-gradient(120% 200% at 50% 0%, rgba(212, 169, 55, 0.22), transparent 60%), rgba(14, 14, 16, 0.92);
  box-shadow: 0 0 0 6px rgba(212, 169, 55, 0.06), 0 20px 50px -12px rgba(0, 0, 0, 0.8), 0 0 50px -10px rgba(212, 169, 55, 0.55);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  opacity: 0; transform: translate(-50%, -50%) scale(.85);
  transition: opacity .45s var(--ease), transform .6s cubic-bezier(.2, 1.4, .4, 1);
}
.stages-done-icon { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; color: #121315; background: linear-gradient(135deg, var(--primary), var(--primary-c)); }
.stages-done-icon .icon { stroke-width: 3; }
.stages-wrap.is-complete .stages-done { opacity: 1; transform: translate(-50%, -50%) scale(1); transition-delay: .25s; }
.stages-wrap.is-complete .stage { animation: stage-celebrate 1.4s var(--ease) both; animation-delay: calc(var(--i) * 70ms); }
.stages-wrap.is-complete .stage::after { opacity: 1; }
@keyframes stage-celebrate {
  0% { box-shadow: var(--card-shadow); }
  35% { box-shadow: var(--card-shadow), 0 0 0 1px rgba(230, 197, 107, 0.7), 0 0 36px -6px rgba(212, 169, 55, 0.6); translate: 0 -6px; }
  100% { box-shadow: var(--card-shadow), 0 0 0 1px rgba(212, 169, 55, 0.3); translate: 0 0; }
}
@keyframes stage-fill { from { width: 0; } to { width: 100%; } }
@keyframes stage-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(212, 169, 55, 0.45); } 50% { box-shadow: 0 0 0 5px rgba(212, 169, 55, 0); } }

@media (max-width: 1024px) {
  .stages { grid-template-columns: repeat(2, 1fr); }
  .orrery { height: clamp(620px, 80vh, 860px); }
}

@media (max-width: 640px) {
  /* Lifecycle cards become a sideways swipe row; the active card is kept in view (process3d.js) */
  .stages { display: flex; gap: 12px; margin-inline: -16px; padding: 8px 16px 12px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: 16px; scrollbar-width: none; }
  .stages::-webkit-scrollbar { display: none; }
  .stage { flex: 0 0 82%; scroll-snap-align: start; }
  .orrery { --inset: 16px; height: clamp(480px, 70vh, 620px); height: clamp(480px, 70svh, 620px); }
  .orrery-key { top: 24px; font-size: 11px; }
  /* Phones: the stage card docks at the foot of the scene (process3d.js frames the planets above it), so the
     scene and its explanation share one screen; swipe the card or tap a dot to move between stages. The
     separate row of stage cards is not needed here. */
  .orrery-caption {
    left: 12px; right: 12px; bottom: 12px; width: auto; height: 158px; padding: 14px 16px 12px 18px;
    display: flex; flex-direction: column; pointer-events: auto; touch-action: pan-y; user-select: none;
  }
  .orrery-caption::before { top: 14px; bottom: 14px; }
  .caption-title { margin: 4px 0; font-size: 18px; line-height: 24px; }
  .caption-text { font-size: 12.5px; line-height: 18px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
  .caption-dots { margin-top: auto; padding-bottom: 4px; }
  .caption-dots i { position: relative; cursor: pointer; }
  .caption-dots i::before { content: ""; position: absolute; inset: -12px -3px; } /* invisible, larger tap target */
  .caption-hint { display: block; position: absolute; right: 16px; bottom: 15px; font-size: 10.5px; font-weight: 600; letter-spacing: .06em; color: var(--muted); }
  .stages-wrap { display: none; }
}

/* ---------- Business Automations: a live workflow window (automation.js runs it) ---------- */
.auto { display: flex; flex-direction: column; gap: 24px; }

/* The workflow sits directly on the page's dot background: no frame, border or panel of its own */
.auto-window { position: relative; }
.auto-bar { display: flex; align-items: center; gap: 14px; padding: 0 28px; font-size: 13px; color: var(--text-2); }
.auto-title b { font-weight: 600; color: var(--text); }

/* Workflow canvas: trigger → agent → if / else, then a three-step "true" route above and a
   shorter, offset "false" route below; the agent's tools sit beneath it. Labels hang outside the layout so
   the nodes line up. */
.auto-canvas {
  position: relative; display: grid; grid-template-columns: 0.9fr 1.35fr repeat(4, minmax(0, 1fr)); grid-template-rows: auto auto auto;
  justify-items: center; align-items: center; column-gap: 18px; row-gap: 104px; padding: 64px 28px 56px;
}
.auto-node-trigger { grid-column: 1; grid-row: 1 / 3; }
.auto-node-agent { grid-column: 2; grid-row: 1 / 3; }
.auto-node-decision { grid-column: 3; grid-row: 1 / 3; }
.auto-yes.auto-c0 { grid-column: 4; grid-row: 1; }
.auto-yes.auto-c1 { grid-column: 5; grid-row: 1; }
.auto-yes.auto-c2 { grid-column: 6; grid-row: 1; }
.auto-no.auto-c0 { grid-column: 4; grid-row: 2; transform: translate(14%, 18px); }  /* the false route sits offset, */
.auto-no.auto-c1 { grid-column: 5; grid-row: 2; transform: translate(24%, 18px); }  /* so the canvas reads naturally */
.auto-tools { grid-column: 2; grid-row: 3; justify-self: center; width: max-content; position: relative; z-index: 1; display: flex; gap: 26px; margin-top: -34px; } /* centred under the agent */

/* Connectors: rounded curves that turn gold once a packet has travelled them */
.auto-links { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.auto-link { fill: none; stroke: rgba(255, 255, 255, 0.2); stroke-width: 2.5; stroke-linecap: round; transition: stroke .5s, filter .5s; }
.auto-link.is-done { stroke: var(--primary-c); filter: drop-shadow(0 0 5px rgba(212, 169, 55, 0.55)); }
.auto-tool-link { fill: none; stroke: rgba(212, 169, 55, 0.3); stroke-width: 1.5; stroke-dasharray: 4 5; transition: stroke .4s; }
.auto-tool-link.is-active { stroke: var(--primary); animation: auto-dash .8s linear infinite; }
.auto-packet { fill: #fff3cc; opacity: 0; filter: drop-shadow(0 0 7px rgba(230, 197, 107, 1)); }

/* Nodes in the style of a workflow editor: rounded boxes with ports, a large icon, the name underneath */
.auto-node { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; transition: opacity .5s; }
.auto-box {
  position: relative; display: grid; place-items: center; width: 66px; height: 66px; border-radius: 14px;
  border: 1.5px solid rgba(255, 255, 255, 0.18);
  background: linear-gradient(160deg, #2a2b30, #18191c); box-shadow: 0 16px 30px -14px rgba(0, 0, 0, 0.95), inset 0 1px 0 rgba(255, 255, 255, 0.07);
  transition: border-color .45s, box-shadow .45s;
}
.auto-node-trigger .auto-box { border-radius: 33px 14px 14px 33px; } /* triggers are rounded on the starting side */
.auto-icon { display: grid; place-items: center; color: var(--text-2); transition: color .45s; }
.auto-port { position: absolute; top: 50%; z-index: 2; width: 11px; height: 11px; margin-top: -5.5px; border-radius: 50%; border: 1.5px solid rgba(255, 255, 255, 0.4); background: #18191c; transition: border-color .4s, background .4s; }
.auto-port-in { left: -6.5px; }
.auto-port-out { right: -6.5px; }
.auto-port-true { top: 30%; }
.auto-port-false { top: 70%; }
.auto-port-label { position: absolute; left: calc(100% + 10px); font-size: 9.5px; line-height: 12px; font-style: normal; font-weight: 600; letter-spacing: .06em; color: var(--muted); transition: color .4s; }
.auto-label-true { top: calc(30% - 18px); }
.auto-label-false { top: calc(70% + 6px); }
.auto-bolt { position: absolute; left: -24px; top: 50%; display: grid; color: var(--primary-c); transform: translateY(-50%); }
.auto-check {
  position: absolute; right: -7px; bottom: -7px; z-index: 3; display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%;
  color: #17140c; background: linear-gradient(135deg, var(--primary), var(--primary-c)); box-shadow: 0 0 0 3px #17181b, 0 0 10px rgba(212, 169, 55, 0.6);
  transform: scale(0); transition: transform .35s cubic-bezier(.2, 1.6, .4, 1);
}
.auto-check .icon { stroke-width: 3.5; }
.auto-box::after { /* spinner in the corner while the step runs */
  content: ""; position: absolute; right: 5px; top: 5px; width: 12px; height: 12px; border-radius: 50%;
  border: 2px solid rgba(212, 169, 55, 0.25); border-top-color: var(--primary); opacity: 0; transition: opacity .2s;
}
.auto-text { position: absolute; top: calc(100% + 12px); left: 50%; display: flex; flex-direction: column; align-items: center; width: 150px; text-align: center; transform: translateX(-50%); }
.auto-kind { font-size: 9px; line-height: 13px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.auto-text b { margin-top: 3px; font-size: 12.5px; line-height: 16px; font-weight: 600; color: var(--text); }
.auto-text small { margin-top: 2px; font-size: 11px; line-height: 15px; color: var(--muted); }

.auto-node.is-running .auto-box { border-color: var(--primary-c); animation: auto-glow 1.2s ease-in-out infinite; }
.auto-node.is-running .auto-icon { color: var(--primary); }
.auto-node.is-running .auto-box::after { opacity: 1; animation: engine-spin .8s linear infinite; }
.auto-node.is-done .auto-box { border-color: rgba(212, 169, 55, 0.7); box-shadow: 0 0 26px -8px rgba(212, 169, 55, 0.5); }
.auto-node.is-done .auto-icon { color: var(--primary); }
.auto-node.is-done .auto-check { transform: scale(1); }
.auto-node.is-done .auto-port { border-color: var(--primary-c); background: #2a2414; }
.auto-node.is-skipped { opacity: .35; }
.auto-node-decision.is-true .auto-label-true, .auto-node-decision.is-false .auto-label-false { color: var(--primary); }
.auto-node-decision .auto-check { right: auto; left: -7px; } /* keeps the true / false outputs clear */
.auto-node-decision.is-true .auto-port-false, .auto-node-decision.is-false .auto-port-true { border-color: rgba(255, 255, 255, 0.25); background: #18191c; }

/* The artificial intelligence agent: a wide node, as in a workflow editor, with Model, Memory and Tool
   sub-connections underneath leading to its tools; its title sits above */
.auto-node-agent .auto-box {
  display: flex; align-items: center; justify-content: flex-start; gap: 12px; width: 200px; height: 74px; padding: 0 16px;
  border-color: rgba(212, 169, 55, 0.5);
  background: radial-gradient(120% 160% at 0% 0%, rgba(212, 169, 55, 0.2), transparent 60%), linear-gradient(160deg, #2a2720, #17171a);
}
.auto-node-agent .auto-icon { color: var(--primary); }
.auto-agent-name { font-size: 12px; line-height: 15px; font-weight: 600; text-align: left; color: var(--text); }
.auto-node-agent .auto-text { top: auto; bottom: calc(100% + 16px); width: 220px; }
.auto-subports { position: absolute; left: 0; right: 0; top: calc(100% - 5px); }
.auto-subports span { position: absolute; display: flex; flex-direction: column; align-items: center; gap: 4px; transform: translateX(-50%); font-size: 8.5px; line-height: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.auto-subports span:nth-child(1) { left: 22%; }
.auto-subports span:nth-child(2) { left: 50%; }
.auto-subports span:nth-child(3) { left: 78%; }
.auto-subports i { width: 9px; height: 9px; border: 1.5px solid rgba(212, 169, 55, 0.7); background: #141416; transform: rotate(45deg); transition: background .4s; }
.auto-node-agent.is-running .auto-subports i, .auto-node-agent.is-done .auto-subports i { background: var(--primary-c); }

/* The agent's tools: round sub-nodes */
.auto-tool { display: flex; flex-direction: column; align-items: center; gap: 8px; width: 92px; text-align: center; }
.auto-tool-ring { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; color: var(--muted); border: 1.5px solid rgba(212, 169, 55, 0.35); background: linear-gradient(160deg, #26272b, #17181b); transition: color .4s, border-color .4s, box-shadow .4s; }
.auto-tool-name { font-size: 10.5px; line-height: 14px; font-weight: 600; color: var(--muted); transition: color .4s; }
.auto-tool.is-active .auto-tool-ring { color: var(--primary); border-color: var(--primary-c); box-shadow: 0 0 22px -4px rgba(212, 169, 55, 0.6); }
.auto-tool.is-active .auto-tool-name { color: var(--text-2); }

/* Benefits */
.auto-benefits { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.auto-benefit { display: flex; gap: 14px; padding: 20px; border-radius: 16px; background: rgba(33, 34, 38, 0.5); box-shadow: var(--card-shadow); }
.auto-benefit-icon { display: grid; place-items: center; flex-shrink: 0; width: 44px; height: 44px; border-radius: 12px; color: var(--primary); background: rgba(212, 169, 55, 0.1); box-shadow: inset 0 0 0 1px rgba(212, 169, 55, 0.22); }
.auto-benefit h3 { font-size: 16px; line-height: 24px; font-weight: 600; letter-spacing: -0.01em; }
.auto-benefit p { margin-top: 2px; font-size: 13px; line-height: 20px; color: var(--text-2); }

@keyframes auto-glow { 50% { box-shadow: 0 0 0 6px rgba(212, 169, 55, 0.12), 0 0 34px -6px rgba(212, 169, 55, 0.65); } }
@keyframes auto-dash { to { stroke-dashoffset: -18; } }

@media (max-width: 1024px) {
  .auto-canvas { column-gap: 12px; padding-inline: 20px; }
  .auto-text { width: 120px; }
  .auto-node-agent .auto-box { width: 170px; }
}

@media (max-width: 860px) {
  /* The workflow runs top to bottom; connectors become a rail through the nodes (automation.js) */
  .auto-canvas { display: flex; flex-direction: column; align-items: stretch; gap: 22px; padding: 26px 20px 26px 44px; }
  .auto-node { flex-direction: row; gap: 14px; }
  .auto-node-trigger { order: 1; } .auto-node-agent { order: 2; } .auto-tools { order: 3; } .auto-node-decision { order: 4; }
  .auto-yes { order: 5; } .auto-no { order: 6; }
  .auto-no.auto-c0, .auto-no.auto-c1 { transform: none; }
  .auto-box, .auto-node-agent .auto-box { flex-shrink: 0; width: 54px; height: 54px; padding: 0; justify-content: center; }
  .auto-node-trigger .auto-box { border-radius: 27px 14px 14px 27px; }
  .auto-check { width: 18px; height: 18px; }
  .auto-text, .auto-node-agent .auto-text { position: static; width: auto; align-items: flex-start; text-align: left; transform: none; }
  .auto-port, .auto-port-label, .auto-agent-name, .auto-subports, .auto-tool-link { display: none; }
  .auto-tools { width: auto; flex-wrap: wrap; justify-content: flex-start; gap: 8px; margin: 0 0 0 68px; }
  .auto-tool { width: auto; flex-direction: row; gap: 6px; padding: 5px 10px 5px 5px; border-radius: 999px; background: rgba(255, 255, 255, 0.03); box-shadow: inset 0 0 0 1px rgba(212, 169, 55, 0.2); }
  .auto-tool-ring { width: 24px; height: 24px; }
  .auto-tool-ring .icon { width: 12px; height: 12px; }
  .auto-tool-name { font-size: 10px; white-space: nowrap; }
}

@media (max-width: 640px) {
  .auto-bar { padding: 0 4px; }
  .auto-benefits { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- Contact ---------- */

/* Contact: the form and the three detail cards share the premium finish used across the site (gold gradient
   edge, soft glow); the two columns stand at the same height. */
.contact-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 32px; align-items: stretch; }
.contact-form, .info-card { position: relative; isolation: isolate; }
.contact-form::after, .info-card::after { /* gold gradient edge */
  content: ""; position: absolute; inset: 0; padding: 1px; border-radius: inherit; pointer-events: none; opacity: .5; transition: opacity .4s;
  background: linear-gradient(140deg, rgba(240, 210, 130, 0.7), rgba(255, 255, 255, 0.05) 32%, rgba(255, 255, 255, 0.03) 68%, rgba(212, 169, 55, 0.45));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
}
.contact-form {
  display: flex; flex-direction: column; gap: 20px; padding: 32px; border-radius: 24px;
  background: radial-gradient(120% 60% at 0% 0%, rgba(212, 169, 55, 0.08), transparent 55%), rgba(28, 29, 32, 0.85);
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.85);
}
.contact-form:hover { background: radial-gradient(120% 60% at 0% 0%, rgba(212, 169, 55, 0.08), transparent 55%), rgba(28, 29, 32, 0.85); }
.contact-form:focus-within::after { opacity: 1; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field > span { display: flex; justify-content: space-between; font-size: 11px; line-height: 16px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--text-2); }
.counter { font-weight: 500; letter-spacing: .04em; color: var(--muted); }
.counter b { font-weight: 500; }
.field input, .field textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: rgba(10, 11, 13, 0.7);
  outline: none;
  transition: border-color .25s, box-shadow .25s, background .25s;
}
.field input { height: 48px; padding-block: 0; }
.field textarea { resize: none; min-height: 140px; line-height: 22px; }
.field input::placeholder, .field textarea::placeholder { color: var(--muted); }
.field input:hover, .field textarea:hover { border-color: rgba(255, 255, 255, 0.16); }
.field input:focus, .field textarea:focus { border-color: var(--primary-c); background: rgba(10, 11, 13, 0.9); box-shadow: 0 0 0 4px rgba(212, 169, 55, 0.12); }
.field.invalid input, .field.invalid textarea { border-color: #ffb4ab; box-shadow: 0 0 0 4px rgba(255, 180, 171, 0.1); }
/* Service options: selectable cards built on radio buttons */
.choice-group { min-width: 0; margin: 0; padding: 0; border: 0; }
.choice-group legend { margin-bottom: 8px; padding: 0; font-size: 11px; line-height: 16px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--text-2); }
.choices { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.choice {
  position: relative; display: flex; align-items: center; gap: 12px; min-height: 60px; padding: 12px 30px 12px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08); border-radius: 12px; background: rgba(10, 11, 13, 0.7); cursor: pointer;
  transition: border-color .25s, background .25s, box-shadow .25s;
}
.choice input { position: absolute; opacity: 0; pointer-events: none; } /* still focusable and keyboard operable */
.choice-icon { display: grid; place-items: center; flex-shrink: 0; width: 36px; height: 36px; border-radius: 10px; color: var(--muted); background: rgba(255, 255, 255, 0.05); transition: color .25s, background .25s; }
.choice-title { font-size: 13px; line-height: 17px; font-weight: 600; color: var(--text-2); transition: color .25s; }
.choice-check {
  position: absolute; top: 8px; right: 8px; display: grid; place-items: center; width: 16px; height: 16px; border-radius: 50%;
  color: #17140c; background: linear-gradient(135deg, var(--primary), var(--primary-c)); transform: scale(0); transition: transform .3s cubic-bezier(.2, 1.6, .4, 1);
}
.choice-check .icon { stroke-width: 3.5; }
.choice:hover { border-color: rgba(255, 255, 255, 0.16); }
.choice:has(input:checked) { border-color: var(--primary-c); background: radial-gradient(120% 140% at 0% 0%, rgba(212, 169, 55, 0.14), transparent 60%), rgba(10, 11, 13, 0.85); box-shadow: 0 0 0 4px rgba(212, 169, 55, 0.1); }
.choice:has(input:checked) .choice-icon { color: var(--primary); background: rgba(212, 169, 55, 0.14); }
.choice:has(input:checked) .choice-title { color: var(--text); }
.choice:has(input:checked) .choice-check { transform: scale(1); }
.choice:has(input:focus-visible) { outline: 2px solid var(--primary); outline-offset: 2px; }

.contact-form .btn { align-self: flex-start; margin-top: 4px; padding: 14px 26px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.form-status { font-size: 13px; }
.form-status:empty { display: none; }
.form-status.ok { padding: 12px 16px; border-radius: 12px; background: rgba(212, 169, 55, 0.14); box-shadow: inset 0 0 0 1px rgba(212, 169, 55, 0.4); color: var(--text); }
.form-status.error { color: #ffb4ab; }
.form-note { display: flex; align-items: center; gap: 8px; padding-top: 16px; border-top: 1px solid rgba(255, 255, 255, 0.06); font-size: 12px; line-height: 18px; color: var(--muted); }
.form-note .icon { flex-shrink: 0; color: var(--primary-c); }
.form-note a { color: var(--text-2); text-decoration: underline; text-underline-offset: 3px; transition: color .2s; }
.form-note a:hover { color: var(--primary); }

.contact-info { display: flex; flex-direction: column; gap: 16px; }
.info-card {
  flex: 1; display: flex; align-items: center; gap: 18px; padding: 24px 26px; border-radius: 20px;
  transition: translate .4s var(--ease), background-color .3s, box-shadow .4s;
}
.info-card .icon-tile { width: 52px; height: 52px; border-radius: 14px; color: var(--primary); background: rgba(212, 169, 55, 0.1); box-shadow: inset 0 0 0 1px rgba(212, 169, 55, 0.25); transition: transform .4s var(--ease), box-shadow .4s; }
.info-card:hover { translate: 0 -3px; box-shadow: var(--card-shadow), 0 24px 40px -26px rgba(212, 169, 55, 0.45); }
.info-card:hover::after { opacity: 1; }
.info-card:hover .icon-tile { transform: scale(1.06); box-shadow: inset 0 0 0 1px rgba(212, 169, 55, 0.5), 0 0 22px -6px rgba(212, 169, 55, 0.6); }
.info-card .eyebrow { margin-bottom: 4px; }
.info-title { display: block; font-family: var(--font-head); font-size: 18px; line-height: 26px; font-weight: 600; letter-spacing: -0.015em; color: var(--text); word-break: break-word; transition: color .2s; }
a.info-title:hover { color: var(--primary); }
.info-card p { margin-top: 4px; font-size: 13px; line-height: 19px; color: var(--text-2); }

@media (max-width: 1024px) {
  .contact-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 640px) {
  .field-row, .choices { grid-template-columns: 1fr; }
  .contact-form .btn { align-self: stretch; }
}

/* ---------- Inner pages (legal, 404) ---------- */

.page-hero { padding: calc(var(--header-h) + 80px) 0 48px; }
.page-hero h1 { font-size: clamp(36px, 5vw, 56px); line-height: 1.15; letter-spacing: -0.03em; margin: 14px 0 10px; }
.page-hero.center { min-height: 80vh; display: grid; place-items: center; text-align: center; }
.page-hero.center .badge { margin-inline: auto; }
.page-hero.center .hero-text { margin-inline: auto; }
.page-hero.center .actions { justify-content: center; margin-top: 28px; }

.prose, .prose-width { max-width: 820px; } /* legal pages: the heading and the text share one reading column */
.prose { font-size: 15px; line-height: 26px; }
.prose h2 { font-size: 22px; line-height: 30px; margin: 36px 0 10px; }
.prose p, .prose li { color: var(--text-2); }
.prose p + p { margin-top: 14px; }
.prose a { color: var(--primary); text-decoration: underline; text-underline-offset: 3px; }
.prose ul { margin-top: 12px; padding-left: 20px; list-style: disc; }
.prose li + li { margin-top: 10px; }
.prose li::marker { color: var(--primary-c); }
.prose strong { color: var(--text); }

/* Loaded last: the footer, helpers that must win over components, scroll reveal, shared animations
   and the responsive rules for the shared layout. */

/* ---------- Footer ---------- */

.site-footer { position: relative; z-index: 1; margin-top: 40px; padding-top: 1px; background: rgb(14, 15, 17); box-shadow: 0 -1px 8px rgba(0, 0, 0, 0.4); } /* a solid base in the navbar's tone, above the dot pattern */
.site-footer::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 1px; background: linear-gradient(90deg, transparent, rgba(212, 169, 55, 0.4), transparent); }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr)); gap: 40px; padding: 40px 0; }
.footer-logo { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-head); font-size: 18px; font-weight: 700; letter-spacing: -0.015em; }
.footer-logo img { width: auto; height: 44px; object-fit: contain; }
.footer-brand p { max-width: 384px; margin: 16px 0; font-size: 12px; line-height: 20px; color: var(--text-2); }
.footer-col { display: flex; flex-direction: column; gap: 8px; justify-self: center; } /* each column centred in an equal share of the space */
.footer-col h4 { margin-bottom: 4px; font-size: 11px; line-height: 16px; letter-spacing: .08em; text-transform: uppercase; }
.footer-col a, .footer-col span { font-size: 12px; line-height: 18px; color: var(--text-2); transition: color .2s; word-break: break-word; }
.footer-col a:hover { color: var(--text); }
.socials { display: flex; gap: 8px; }
.socials a { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 8px; background: var(--surface); color: var(--text-2); transition: background .2s, color .2s; }
.socials a:hover { color: var(--text); background: var(--surface-high); }
.footer-bottom { display: flex; align-items: center; justify-content: center; text-align: center; flex-wrap: wrap; gap: 16px; padding: 24px 0 32px; font-size: 12px; color: var(--text-2); }

.to-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 40;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 50%;
  background: var(--gradient-btn);
  color: #121315;
  box-shadow: 0 10px 30px -8px var(--glow);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: all .3s var(--ease);
}
.to-top.visible { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { transform: translateY(-3px); }

/* ---------- Tone helpers: colour an icon or label with a brand colour (after components so they win) ---------- */

.tone-primary { color: var(--primary); }
.tone-violet { color: var(--primary-c); }

/* ---------- Scroll reveal (only when JS is running) ---------- */

.js .reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .8s var(--ease), transform .8s var(--ease);
  transition-delay: calc(var(--d, 0) * 90ms);
}
.js .reveal.visible { opacity: 1; transform: none; }

/* ---------- Animations ---------- */

@keyframes engine-spin { to { transform: rotate(360deg); } }
@keyframes engine-load { 0%, 100% { width: 32%; } 50% { width: 82%; } }
@keyframes glitch-skew {
  0%, 89%, 100% { transform: none; }
  90% { transform: skewX(-6deg) translateX(2px); }
  92% { transform: skewX(4deg) translateX(-2px); }
  94% { transform: none; }
}
@keyframes glitch-a {
  0%, 88%, 97%, 100% { opacity: 0; transform: none; clip-path: inset(0); }
  89% { opacity: .9; transform: translate(-5px, 2px); clip-path: inset(8% 0 62% 0); }
  91% { opacity: .9; transform: translate(5px, -1px); clip-path: inset(48% 0 22% 0); }
  93% { opacity: .9; transform: translate(-3px, 0); clip-path: inset(78% 0 4% 0); }
  95% { opacity: .9; transform: translate(4px, 1px); clip-path: inset(28% 0 50% 0); }
}
@keyframes glitch-b {
  0%, 88%, 97%, 100% { opacity: 0; transform: none; clip-path: inset(0); }
  89% { opacity: .9; transform: translate(5px, -2px); clip-path: inset(60% 0 12% 0); }
  91% { opacity: .9; transform: translate(-4px, 1px); clip-path: inset(15% 0 66% 0); }
  93% { opacity: .9; transform: translate(3px, 2px); clip-path: inset(38% 0 40% 0); }
  95% { opacity: .9; transform: translate(-5px, 0); clip-path: inset(85% 0 2% 0); }
}

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

/* ---------- Responsive (shared layout; each section keeps its own) ---------- */

@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 860px) {
  .menu-toggle { display: block; }
  .header-cta { display: none; }
  .nav-links {
    position: fixed;
    top: calc(var(--header-h) + 2px);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 12px 20px 24px;
    background: var(--bg-lowest);
    box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .8);
    transform: translateY(-12px);
    opacity: 0;
    visibility: hidden;
    transition: all .3s var(--ease);
  }
  .site-header.open .nav-links { transform: none; opacity: 1; visibility: visible; }
  .nav-links a:not(.btn) { padding: 14px 4px; font-size: 17px; border-bottom: 1px solid rgba(255, 255, 255, 0.06); }
  .nav-links a:not(.btn)::after { display: none; }
  .nav-cta-mobile { display: inline-flex; margin-top: 18px; }
}

@media (max-width: 640px) {
  :root { --header-h: 58px; }
  .container { width: calc(100% - 32px); }
  .logo img { height: 36px; }
  .section h2 { font-size: 28px; line-height: 36px; }
  .section h2.heading-refined { font-size: 24px; line-height: 32px; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .footer-col { justify-self: start; }
  .to-top { right: 16px; bottom: 16px; }
}
