/* ==========================================================================
   NextOps — shared UI styles (index / login / brand)
   Owner: UI agent. Tokens follow BRIEF §2.
   ========================================================================== */

:root {
  /* Brand palette (sampled from the mark) */
  --abyss: #000C3C;
  --navy: #00246F;
  --royal: #013D96;
  --brand: #0158B6;
  --azure: #0287D8;
  --cyan: #04BAF4;
  --ice: #44DFF9;
  --ops: #0154CF;
  --ops-on-dark: #1F6FE5;
  --text: #F2F4F7;
  --bg: #05060A;
  --bg-2: #07080D;
  --bg-3: #0A0E1A;
  --success: #04BAF4;
  --error: #FF5A6E;

  /* Derived */
  --text-2: rgba(242, 244, 247, 0.72);
  --text-3: rgba(242, 244, 247, 0.6);
  --text-4: rgba(242, 244, 247, 0.48);
  --line: rgba(255, 255, 255, 0.07);
  --line-2: rgba(255, 255, 255, 0.11);
  --line-3: rgba(255, 255, 255, 0.18);
  --panel: rgba(255, 255, 255, 0.025);
  --glass: rgba(8, 11, 20, 0.62);
  --cyan-a10: rgba(4, 186, 244, 0.10);
  --cyan-a20: rgba(4, 186, 244, 0.20);
  --cyan-a35: rgba(4, 186, 244, 0.35);

  /* Type */
  --font-display: "Exo 2", "Saira", "Titillium Web", system-ui, sans-serif;
  --font-ui: "Inter", "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Consolas, monospace;

  /* Layout */
  --container: 1200px;
  --gutter: clamp(20px, 4vw, 40px);
  --nav-h: 68px;
  --radius-sm: 10px;
  --radius: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;

  /* Motion */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);      /* expo-ish out */
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --dur: 0.5s;

  color-scheme: dark;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 16px); }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.6 var(--font-ui);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg, video, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, h4, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
::selection { background: rgba(4, 186, 244, 0.32); color: #fff; }

:focus-visible {
  outline: 2px solid var(--ice);
  outline-offset: 3px;
  border-radius: 8px;
}

.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

.skip-link {
  position: fixed; top: 12px; left: 12px; z-index: 100;
  padding: 10px 16px; border-radius: 10px;
  background: var(--text); color: var(--bg); font-weight: 600; font-size: 14px;
  transform: translateY(-160%);
  transition: transform 0.3s var(--ease-out);
}
.skip-link:focus { transform: none; }

.container {
  width: min(var(--container), 100% - 2 * var(--gutter));
  margin-inline: auto;
}

/* ---------- Type ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font: 500 12px/1 var(--font-mono);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--cyan);
}
.eyebrow::before {
  content: ""; width: 18px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--cyan));
}
.display {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.04;
  text-wrap: balance;
}
.h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2rem, 1.35rem + 2.2vw, 3.25rem);
  line-height: 1.08;
  letter-spacing: -0.015em;
  text-wrap: balance;
}
.lede {
  color: var(--text-2);
  font-size: clamp(1.02rem, 0.95rem + 0.35vw, 1.2rem);
  line-height: 1.65;
  text-wrap: pretty;
}
.muted { color: var(--text-3); }
.mono { font-family: var(--font-mono); }
.grad-text {
  background: linear-gradient(100deg, #F2F4F7 0%, #BFEFFF 38%, var(--ice) 70%, var(--cyan) 100%);
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
}

/* ---------- Buttons ---------- */
.btn {
  --h: 48px;
  position: relative;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: var(--h);
  padding: 0 22px;
  border-radius: 12px;
  border: 1px solid transparent;
  font: 500 15px/1 var(--font-ui);
  letter-spacing: 0.005em;
  white-space: nowrap;
  transition: transform 0.35s var(--ease-out), box-shadow 0.45s var(--ease-out),
              background-color 0.35s var(--ease-out), border-color 0.35s var(--ease-out), color 0.35s var(--ease-out), filter 0.35s var(--ease-out);
  -webkit-tap-highlight-color: transparent;
}
.btn svg { width: 16px; height: 16px; flex: none; transition: transform 0.45s var(--ease-out); }
.btn:hover svg.arrow, .btn:focus-visible svg.arrow { transform: translateX(3px); }
.btn:active { transform: translateY(1px) scale(0.99); }
.btn-sm { --h: 38px; padding: 0 15px; font-size: 14px; border-radius: 10px; }
.btn-lg { --h: 54px; padding: 0 26px; font-size: 16px; border-radius: 14px; }

.btn-primary {
  color: #fff;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.16), rgba(255,255,255,0) 52%),
    linear-gradient(180deg, #0A8FE0 0%, var(--brand) 100%);
  border-color: rgba(68, 223, 249, 0.38);
  box-shadow:
    0 0 0 1px rgba(1, 88, 182, 0.35),
    0 10px 30px -10px rgba(4, 186, 244, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.22);
}
.btn-primary:hover, .btn-primary:focus-visible {
  filter: brightness(1.08);
  box-shadow:
    0 0 0 1px rgba(4, 186, 244, 0.45),
    0 14px 40px -10px rgba(4, 186, 244, 0.7),
    inset 0 1px 0 rgba(255, 255, 255, 0.28);
}
.btn-ghost {
  color: var(--text);
  background: rgba(255, 255, 255, 0.035);
  border-color: var(--line-2);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.btn-ghost:hover, .btn-ghost:focus-visible {
  background: rgba(255, 255, 255, 0.07);
  border-color: var(--line-3);
}
.btn-quiet { color: var(--text-2); padding-inline: 12px; }
.btn-quiet:hover, .btn-quiet:focus-visible { color: var(--text); background: rgba(255,255,255,0.05); }
.btn[disabled], .btn[aria-disabled="true"] { cursor: default; }

.link {
  color: var(--text-2);
  text-decoration: underline;
  text-decoration-color: rgba(242, 244, 247, 0.25);
  text-underline-offset: 3px;
  transition: color 0.3s, text-decoration-color 0.3s;
}
.link:hover, .link:focus-visible { color: var(--text); text-decoration-color: var(--cyan); }

/* ---------- <nextops-logo> + fallback (until MARK's component is defined) ---------- */
nextops-logo {
  display: inline-flex;
  align-items: center;
  line-height: 0;
  vertical-align: middle;
  flex: none;
}
nextops-logo:defined .nl-fb { display: none !important; }
.nl-fb {
  display: inline-flex;
  align-items: center;
  gap: calc(var(--nl-size, 28px) * 0.3);
  line-height: 1;
}
.nl-fb img {
  height: var(--nl-size, 28px);
  width: auto;
  aspect-ratio: 1.762;           /* crop to the symbol's alpha bbox (370x210 of 395x395) */
  object-fit: cover;
  object-position: 50% 46.8%;
}
.nl-fb .nl-word {
  font: 600 calc(var(--nl-size, 28px) * 0.56)/1 var(--font-display);
  letter-spacing: 0.005em;
  color: var(--text);
}
.nl-fb .nl-word b { font-weight: 600; color: var(--ops-on-dark); }
.nl-fb.is-loader img { animation: nl-fb-pulse 1.4s var(--ease-in-out) infinite; }
@keyframes nl-fb-pulse { 0%, 100% { opacity: 0.45; } 50% { opacity: 1; } }

/* ---------- Status pill + telemetry ---------- */
.status-pill {
  display: inline-flex; align-items: center; gap: 10px;
  height: 32px; padding: 0 14px 0 12px;
  border-radius: 999px;
  background: rgba(4, 186, 244, 0.06);
  border: 1px solid rgba(4, 186, 244, 0.20);
  color: var(--text-2);
  font: 500 13px/1 var(--font-ui);
  transition: border-color 0.3s, background-color 0.3s, color 0.3s;
}
a.status-pill:hover, a.status-pill:focus-visible { color: var(--text); border-color: rgba(4, 186, 244, 0.38); background: rgba(4, 186, 244, 0.09); }
.status-dot {
  position: relative; width: 8px; height: 8px; flex: none;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 10px rgba(4, 186, 244, 0.8);
}
.status-dot::after {
  content: ""; position: absolute; inset: -4px;
  border-radius: 50%;
  border: 1px solid rgba(4, 186, 244, 0.55);
  animation: status-ring 2.8s var(--ease-out) infinite;
}
@keyframes status-ring {
  0% { transform: scale(0.5); opacity: 0.9; }
  70%, 100% { transform: scale(1.8); opacity: 0; }
}

.telemetry {
  display: flex; flex-wrap: wrap; gap: 8px;
}
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  height: 30px; padding: 0 12px;
  border-radius: 8px;
  background: rgba(10, 14, 26, 0.55);
  border: 1px solid var(--line-2);
  font: 400 11.5px/1 var(--font-mono);
  letter-spacing: 0.06em;
  color: var(--text-3);
  text-transform: uppercase;
  white-space: nowrap;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.chip strong { font-weight: 500; color: var(--text); letter-spacing: 0.02em; }
.chip .tick { width: 5px; height: 5px; border-radius: 1px; background: var(--cyan); box-shadow: 0 0 8px var(--cyan); }

/* ==========================================================================
   NAV
   ========================================================================== */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  height: var(--nav-h);
  background: rgba(5, 6, 10, 0.38);
  backdrop-filter: blur(18px) saturate(150%);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
  border-bottom: 1px solid transparent;
  transition: background-color 0.5s var(--ease-out), border-color 0.5s var(--ease-out);
}
.nav.is-scrolled {
  background: rgba(6, 8, 14, 0.72);
  border-bottom-color: var(--line);
}
.nav-inner {
  height: 100%;
  display: flex; align-items: center; gap: 28px;
}
.nav-brand {
  display: inline-flex; align-items: center;
  padding: 6px 4px; margin-left: -4px;
  border-radius: 10px;
}
.nav-links {
  display: flex; align-items: center; gap: 4px;
  margin-left: 8px;
}
.nav-links a {
  position: relative;
  padding: 8px 12px;
  border-radius: 8px;
  color: var(--text-3);
  font-size: 14px; font-weight: 500;
  transition: color 0.3s, background-color 0.3s;
}
.nav-links a:hover, .nav-links a:focus-visible { color: var(--text); background: rgba(255, 255, 255, 0.04); }
.nav-links a[aria-current="page"] { color: var(--text); }
.nav-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.nav-toggle {
  display: none;
  width: 40px; height: 40px;
  align-items: center; justify-content: center;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line-2);
}
.nav-toggle svg { width: 18px; height: 18px; }
.nav-toggle .i-close { display: none; }
.nav-toggle[aria-expanded="true"] .i-open { display: none; }
.nav-toggle[aria-expanded="true"] .i-close { display: block; }
.nav-sheet {
  display: none;
}

@media (max-width: 900px) {
  .nav-links, .nav-actions .btn-primary { display: none; }
  .nav-toggle { display: inline-flex; }
  .nav-sheet {
    position: fixed; inset: var(--nav-h) 0 auto 0;
    display: grid; gap: 4px;
    padding: 12px var(--gutter) 22px;
    background: rgba(6, 8, 14, 0.94);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-bottom: 1px solid var(--line);
    transform-origin: top;
    transition: opacity 0.35s var(--ease-out), transform 0.45s var(--ease-out), visibility 0.35s;
  }
  .nav-sheet[hidden] { display: grid; visibility: hidden; opacity: 0; transform: translateY(-8px); pointer-events: none; }
  .nav-sheet a:not(.btn) {
    padding: 14px 4px;
    border-bottom: 1px solid var(--line);
    color: var(--text-2); font-size: 16px; font-weight: 500;
  }
  .nav-sheet .btn { margin-top: 14px; }
}

/* ==========================================================================
   SCENE MEDIA (shared by hero / login / brand frames)
   ========================================================================== */
.scene-media {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(60% 55% at var(--glow-x, 50%) 52%, rgba(1, 61, 150, 0.30), rgba(0, 36, 111, 0.10) 45%, transparent 75%),
    var(--bg);
  isolation: isolate;
}
.scene-host {
  position: absolute; inset: 0;
  z-index: 1;
  opacity: 0;
  transition: opacity 1.2s var(--ease-out);
}
.scene-host > canvas { width: 100% !important; height: 100% !important; display: block; }
.scene-media.is-live .scene-host { opacity: 1; }

/* Static fallback composition (no WebGL / module missing / slow network) */
.scene-fallback {
  position: absolute; inset: 0;
  z-index: 0;
  display: grid; place-items: center;
  opacity: 0;
  transition: opacity 1.2s var(--ease-out);
  pointer-events: none;
}
.scene-media.is-fallback .scene-fallback { opacity: 1; }
.scene-media.is-fallback .scene-host { opacity: 0; }
.scene-fallback .fb-mark {
  position: relative;
  width: var(--fb-w, min(46%, 520px));
  translate: var(--fb-x, 0) var(--fb-y, 0);
}
.scene-fallback .fb-mark img {
  width: 100%; height: auto;
  filter: drop-shadow(0 30px 60px rgba(1, 88, 182, 0.35));
}
.scene-fallback .fb-mark::after {   /* soft reflection on the glossy floor */
  content: "";
  position: absolute; left: 0; right: 0; top: 100%;
  height: 60%;
  background: var(--fb-src) center top / 100% auto no-repeat;
  transform: scaleY(-1);
  opacity: 0.16;
  -webkit-mask-image: linear-gradient(to top, rgba(0,0,0,0.9), transparent 55%);
          mask-image: linear-gradient(to top, rgba(0,0,0,0.9), transparent 55%);
  margin-top: -13%;
  filter: blur(1px);
}
.scene-fallback .fb-poster {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover;
}

/* ==========================================================================
   HERO (index)
   ========================================================================== */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex; align-items: center;
  overflow: hidden;
  --p: 0;  /* scroll progress 0..1 (set by ui.js) */
}
.hero-media {
  position: absolute; inset: 0;
  --glow-x: 72%;
  --fb-x: 22vw;
  --fb-w: min(36vw, 600px);
  opacity: calc(1 - var(--p) * 0.85);
  transform: translate3d(0, calc(var(--p) * 10vh), 0) scale(calc(1 - var(--p) * 0.04));
  transform-origin: 70% 50%;
  will-change: opacity, transform;
}
.hero-scrim {
  position: absolute; inset: 0; z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(5, 6, 10, 0.78) 0%, rgba(5, 6, 10, 0.45) 34%, rgba(5, 6, 10, 0) 58%),
    linear-gradient(0deg, var(--bg) 0%, rgba(5, 6, 10, 0) 24%),
    linear-gradient(180deg, rgba(5, 6, 10, 0.55) 0%, rgba(5, 6, 10, 0) 18%);
}
.hero-content {
  position: relative; z-index: 2;
  padding-top: calc(var(--nav-h) + 48px);
  padding-bottom: 120px;
  opacity: calc(1 - var(--p) * 1.5);
  transform: translate3d(0, calc(var(--p) * -6vh), 0);
}
.hero-copy { max-width: 620px; }
.hero h1 {
  margin-top: 28px;
  font-size: clamp(2.6rem, 1.4rem + 3.7vw, 5.1rem);
}
.hero h1 .line { display: block; }
.hero .lede { margin-top: 24px; max-width: 540px; }
.cta-row { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 12px; }
.hero .telemetry { margin-top: 44px; }
.hero-foot {
  position: absolute; z-index: 2; left: 0; right: 0; bottom: 28px;
  opacity: calc(1 - var(--p) * 3);
}
.hero-foot .container { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.scroll-cue {
  display: inline-flex; align-items: center; gap: 12px;
  font: 400 11px/1 var(--font-mono); letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--text-4);
}
.scroll-cue::before {
  content: ""; width: 1px; height: 28px;
  background: linear-gradient(180deg, rgba(4,186,244,0), rgba(4,186,244,0.8));
  animation: cue 2.6s var(--ease-in-out) infinite;
  transform-origin: top;
}
@keyframes cue { 0% { transform: scaleY(0); opacity: 0; } 40% { transform: scaleY(1); opacity: 1; } 100% { transform: scaleY(1) translateY(10px); opacity: 0; } }
.hero-coords { font: 400 11px/1 var(--font-mono); letter-spacing: 0.14em; color: var(--text-4); text-transform: uppercase; }

/* Reveal-on-load for hero copy */
.js .rise { opacity: 0; transform: translateY(14px); filter: blur(4px); }
.is-ready .rise {
  opacity: 1; transform: none; filter: none;
  transition: opacity 1.1s var(--ease-out), transform 1.1s var(--ease-out), filter 1.1s var(--ease-out);
  transition-delay: calc(var(--i, 0) * 90ms + 150ms);
}

@media (max-width: 900px) {
  .hero { display: block; min-height: auto; }
  .hero-media {
    position: relative; inset: auto;
    height: clamp(400px, 118vw, 560px);
    --glow-x: 50%;
    --fb-x: 0%;
    --fb-y: calc(clamp(400px, 118vw, 560px) * -0.12);   /* match the 3D portrait framing (cy = 0.38) */
    --fb-w: min(78vw, 460px);
    transform-origin: 50% 40%;
  }
  .hero-scrim {
    height: clamp(400px, 118vw, 560px); bottom: auto; top: 0;
    background:
      linear-gradient(0deg, var(--bg) 0%, rgba(5, 6, 10, 0) 30%),
      linear-gradient(180deg, rgba(5, 6, 10, 0.6) 0%, rgba(5, 6, 10, 0) 26%);
  }
  .hero-content { padding-top: 0; padding-bottom: 72px; margin-top: calc(clamp(400px, 118vw, 560px) * -0.2); }
  .hero h1 { margin-top: 22px; }
  .hero-foot { display: none; }
}

/* ==========================================================================
   SECTIONS
   ========================================================================== */
.section { position: relative; padding-block: clamp(88px, 9vw, 136px); }
.section-head { max-width: 720px; }
.section-head .h2 { margin-top: 20px; }
.section-head .lede { margin-top: 20px; }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head.center .eyebrow { justify-content: center; }
.divider {
  height: 1px; border: 0; margin-block: 0;
  background: linear-gradient(90deg, transparent, var(--line-2) 20%, var(--line-2) 80%, transparent);
}

/* Reveal on scroll */
.js .reveal { opacity: 0; transform: translateY(18px); }
.reveal.is-in { opacity: 1; transform: none; transition: opacity 1s var(--ease-out), transform 1s var(--ease-out); transition-delay: calc(var(--i, 0) * 80ms); }

/* ---------- Services ---------- */
.services-grid {
  margin-top: clamp(48px, 6vw, 72px);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.card {
  position: relative;
  border-radius: var(--radius-lg);
  background:
    radial-gradient(420px circle at var(--mx, 50%) var(--my, -20%), rgba(4, 186, 244, 0.07), transparent 60%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.012));
  border: 1px solid var(--line);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  transition: border-color 0.5s var(--ease-out), transform 0.6s var(--ease-out);
}
.card:hover { border-color: var(--line-2); }
.service {
  padding: clamp(26px, 3vw, 38px);
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  min-height: 330px;
}
.service-top { display: flex; align-items: center; justify-content: space-between; }
.icon-tile {
  width: 46px; height: 46px;
  display: grid; place-items: center;
  border-radius: 12px;
  color: var(--ice);
  background:
    linear-gradient(180deg, rgba(4, 186, 244, 0.16), rgba(1, 61, 150, 0.12));
  border: 1px solid rgba(4, 186, 244, 0.22);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08), 0 10px 30px -12px rgba(4, 186, 244, 0.45);
}
.icon-tile svg { width: 22px; height: 22px; }
.service .idx { font: 400 12px/1 var(--font-mono); color: var(--text-4); letter-spacing: 0.12em; }
.service h3 {
  margin-top: 28px;
  font: 600 1.5rem/1.2 var(--font-display);
  letter-spacing: -0.005em;
}
.service p { margin-top: 12px; color: var(--text-3); font-size: 15.5px; line-height: 1.65; max-width: 46ch; }
.service ul { margin-top: 26px; display: grid; gap: 10px; padding-top: 22px; border-top: 1px solid var(--line); }
.service li {
  display: flex; align-items: center; gap: 12px;
  font-size: 14.5px; color: var(--text-2);
}
.service li::before {
  content: ""; width: 6px; height: 6px; flex: none;
  border-radius: 2px;
  background: linear-gradient(135deg, var(--ice), var(--azure));
  box-shadow: 0 0 10px rgba(4, 186, 244, 0.55);
}
.service li .mono { color: var(--text-4); font-size: 12px; margin-left: auto; letter-spacing: 0.04em; }

@media (max-width: 760px) {
  .services-grid { grid-template-columns: 1fr; }
  .service { min-height: 0; }
}

/* ---------- Process loop ---------- */
.process { overflow: hidden; }
.process::before {
  content: ""; position: absolute; inset: 10% -10% auto; height: 70%;
  background: radial-gradient(50% 50% at 50% 50%, rgba(1, 61, 150, 0.16), transparent 70%);
  pointer-events: none;
}
.loop-stage {
  position: relative;
  margin: clamp(40px, 6vw, 72px) auto 0;
  max-width: 980px;
  aspect-ratio: 2.24 / 1.44;
}
.loop-stage svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.loop-track { fill: none; stroke: rgba(255, 255, 255, 0.07); stroke-width: 0.034; stroke-linecap: round; stroke-linejoin: round; }
.loop-line { fill: none; stroke: url(#loopGrad); stroke-width: 0.006; stroke-linecap: round; opacity: 0.9; }
.loop-ticks { fill: none; stroke: rgba(68, 223, 249, 0.18); stroke-width: 0.0035; }
.loop-tail { fill: none; stroke-linecap: round; }
.loop-tail.t1 { stroke: rgba(4, 186, 244, 0.10); stroke-width: 0.03; }
.loop-tail.t2 { stroke: rgba(4, 186, 244, 0.35); stroke-width: 0.012; }
.loop-tail.t3 { stroke: rgba(160, 240, 255, 0.95); stroke-width: 0.008; }
.loop-head { fill: #E9FBFF; filter: drop-shadow(0 0 0.02px #fff); }
.loop-node .halo { fill: rgba(4, 186, 244, 0.0); stroke: rgba(4, 186, 244, 0.0); stroke-width: 0.004; transition: fill 0.6s var(--ease-out), stroke 0.6s var(--ease-out); }
.loop-node .core { fill: var(--bg); stroke: rgba(242, 244, 247, 0.38); stroke-width: 0.006; transition: stroke 0.6s var(--ease-out), fill 0.6s var(--ease-out); }
.loop-node.is-active .halo { fill: rgba(4, 186, 244, 0.12); stroke: rgba(4, 186, 244, 0.45); }
.loop-node.is-active .core { fill: var(--cyan); stroke: var(--ice); }

.loop-label {
  position: absolute;
  transform: translate(-50%, -50%);
  display: grid; justify-items: center; gap: 6px;
  padding: 10px 16px;
  background: radial-gradient(closest-side, rgba(5, 6, 10, 0.92), rgba(5, 6, 10, 0.6) 60%, rgba(5, 6, 10, 0));
  pointer-events: none;
  white-space: nowrap;
  text-align: center;
}
.loop-label[data-anchor="right"] { transform: translate(-100%, -50%); justify-items: end; text-align: right; }
.loop-label[data-anchor="left"] { transform: translate(0, -50%); justify-items: start; text-align: left; }
.loop-label[data-anchor="top"] { transform: translate(-50%, -100%); }
.loop-label[data-anchor="bottom"] { transform: translate(-50%, 0); }
.loop-label .k { font: 500 10.5px/1 var(--font-mono); letter-spacing: 0.18em; color: var(--text-4); transition: color 0.5s; }
.loop-label .v { font: 600 15px/1 var(--font-display); color: var(--text-2); transition: color 0.5s; }
.loop-label.is-active .k { color: var(--cyan); }
.loop-label.is-active .v { color: var(--text); }

.steps {
  margin-top: clamp(40px, 5vw, 64px);
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  counter-reset: step;
}
.step {
  position: relative;
  padding: 22px 20px 24px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255,255,255,0.025), rgba(255,255,255,0.008));
  transition: border-color 0.6s var(--ease-out), background-color 0.6s var(--ease-out), box-shadow 0.6s var(--ease-out);
  outline: none;
}
.step::before {
  content: ""; position: absolute; left: 20px; right: 20px; top: -1px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--cyan), transparent);
  opacity: 0; transition: opacity 0.6s var(--ease-out);
}
.step.is-active { border-color: rgba(4, 186, 244, 0.28); background-color: rgba(4, 186, 244, 0.035); box-shadow: 0 20px 50px -30px rgba(4, 186, 244, 0.5); }
.step.is-active::before { opacity: 1; }
.step:focus-visible { outline: 2px solid var(--ice); outline-offset: 3px; }
.step .k { display: flex; justify-content: space-between; align-items: center; font: 500 11px/1 var(--font-mono); letter-spacing: 0.14em; color: var(--text-4); }
.step.is-active .k .en { color: var(--cyan); }
.step h3 { margin-top: 18px; font: 600 1.15rem/1.2 var(--font-display); }
.step p { margin-top: 10px; font-size: 14px; line-height: 1.6; color: var(--text-3); }
.step .meta { margin-top: 16px; font: 400 11.5px/1 var(--font-mono); color: var(--text-4); letter-spacing: 0.04em; }

@media (max-width: 1080px) {
  .steps { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .steps { grid-template-columns: 1fr; }
  .loop-label .v, .loop-label .en { display: none; }
  .loop-label .k { font-size: 10px; letter-spacing: 0.1em; }
  .loop-label { padding: 6px 8px; }
}

/* ---------- CTA ---------- */
.cta-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-xl);
  border: 1px solid var(--line-2);
  background:
    radial-gradient(70% 90% at 85% 10%, rgba(1, 88, 182, 0.30), transparent 60%),
    radial-gradient(60% 80% at 0% 100%, rgba(0, 36, 111, 0.35), transparent 60%),
    linear-gradient(180deg, #0A0E1A, #07080D);
  padding: clamp(32px, 5.5vw, 72px);
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}
.cta-card::after {   /* fine telemetry grid */
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: radial-gradient(80% 80% at 80% 20%, #000, transparent 75%);
          mask-image: radial-gradient(80% 80% at 80% 20%, #000, transparent 75%);
}
.cta-card > * { position: relative; z-index: 1; min-width: 0; }
.cta-card .h2 { margin-top: 20px; }
.cta-card .lede { margin-top: 18px; max-width: 520px; }
.cta-stats { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 28px 40px; }
.cta-stats div { display: grid; gap: 8px; }
.cta-stats strong { font: 600 1.9rem/1 var(--font-display); color: var(--text); }
.cta-stats span { font: 400 11.5px/1 var(--font-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-4); }
.cta-side {
  border-radius: var(--radius-lg);
  padding: 28px;
  background: var(--glass);
  border: 1px solid var(--line-2);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
.cta-side h3 { font: 500 12px/1 var(--font-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-3); }
.cta-side ol { margin-top: 20px; display: grid; gap: 16px; counter-reset: c; }
.cta-side li {
  display: grid; grid-template-columns: 30px 1fr; gap: 14px; align-items: start;
  color: var(--text-2); font-size: 15px; line-height: 1.5;
  counter-increment: c;
}
.cta-side li::before {
  content: counter(c, decimal-leading-zero);
  display: grid; place-items: center;
  width: 30px; height: 30px; border-radius: 8px;
  font: 500 11px/1 var(--font-mono);
  color: var(--ice);
  background: rgba(4, 186, 244, 0.08);
  border: 1px solid rgba(4, 186, 244, 0.2);
}
.cta-side .actions { margin-top: 26px; display: grid; gap: 10px; }
.cta-side .actions .btn { width: 100%; }

@media (max-width: 900px) {
  .cta-card { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 520px) {
  .cta-card { padding: 30px 20px 22px; border-radius: 22px; }
  .cta-side { padding: 22px 18px; margin-inline: -4px; }
  .cta-stats { gap: 22px 28px; }
  .cta-side .actions .btn { white-space: normal; text-align: center; line-height: 1.25; height: auto; min-height: var(--h); padding-block: 12px; }
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.footer {
  position: relative;
  padding-top: clamp(56px, 6vw, 88px);
  border-top: 1px solid var(--line);
  background:
    radial-gradient(60% 120% at 10% 0%, rgba(0, 36, 111, 0.18), transparent 60%),
    var(--bg);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, minmax(0, 1fr));
  gap: 48px 32px;
}
.footer-brand p { margin-top: 22px; max-width: 34ch; color: var(--text-3); font-size: 14.5px; line-height: 1.7; }
.footer-brand .status-pill { margin-top: 26px; }
.footer h4 { font: 500 11.5px/1 var(--font-mono); letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-4); }
.footer ul { margin-top: 20px; display: grid; gap: 12px; }
.footer ul a { color: var(--text-3); font-size: 14.5px; transition: color 0.3s; display: inline-flex; align-items: center; gap: 10px; }
.footer ul a:hover, .footer ul a:focus-visible { color: var(--text); }
.footer ul svg { width: 16px; height: 16px; color: var(--text-4); }
.footer-bottom {
  margin-top: clamp(56px, 7vw, 88px);
  padding-block: 26px 32px;
  border-top: 1px solid var(--line);
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 28px;
  color: var(--text-4); font-size: 13px;
}
.footer-bottom nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.footer-bottom a:hover, .footer-bottom a:focus-visible { color: var(--text-2); }
.footer-word {
  margin-top: clamp(40px, 6vw, 80px);
  font: 700 clamp(4rem, 17vw, 15rem)/0.78 var(--font-display);
  letter-spacing: -0.03em;
  text-align: center;
  color: transparent;
  background: linear-gradient(180deg, rgba(242,244,247,0.07), rgba(242,244,247,0) 85%);
  -webkit-background-clip: text; background-clip: text;
  user-select: none;
  overflow: hidden;
  white-space: nowrap;
}
@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 420px) {
  .footer-grid { grid-template-columns: 1fr; }
}

/* ==========================================================================
   LOGIN
   ========================================================================== */
.login-body { background: var(--bg); }
.login {
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(420px, 0.92fr);
}
.login-visual {
  position: relative;
  min-height: 100%;
  --glow-x: 50%;
  --fb-w: min(62%, 520px);
  border-right: 1px solid var(--line);
}
.login-visual-top, .login-visual-bottom {
  position: absolute; left: 0; right: 0; z-index: 3;
  padding: 28px clamp(24px, 3.4vw, 48px);
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  pointer-events: none;
}
.login-visual-top { top: 0; }
.login-visual-top a { pointer-events: auto; }
.login-visual-bottom { bottom: 0; align-items: flex-end; }
.login-visual-bottom .tag { max-width: 420px; }
.login-visual-bottom .tag .tag-title { margin: 0; color: var(--text); font: 600 clamp(1.5rem, 1rem + 1.4vw, 2.2rem)/1.15 var(--font-display); letter-spacing: -0.01em; text-wrap: balance; }
.login-visual-bottom .tag p { margin-top: 10px; color: var(--text-3); font-size: 15px; }
.login-visual .scene-media { position: absolute; inset: 0; }
.login-visual::after {
  content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none;
  background:
    linear-gradient(0deg, rgba(5,6,10,0.85) 0%, rgba(5,6,10,0) 32%),
    linear-gradient(180deg, rgba(5,6,10,0.6) 0%, rgba(5,6,10,0) 20%);
}
.state-readout {
  display: grid; gap: 8px; justify-items: end;
  font: 400 11px/1 var(--font-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-4);
}
.state-readout b { font-weight: 500; color: var(--cyan); transition: color 0.4s; }
.state-readout b[data-state="error"] { color: var(--error); }

.login-panel {
  position: relative;
  display: grid; place-items: center;
  padding: clamp(28px, 5vw, 64px) clamp(20px, 4vw, 56px);
  background:
    radial-gradient(70% 60% at 50% 0%, rgba(1, 61, 150, 0.16), transparent 70%),
    var(--bg-2);
}
.login-card {
  width: min(440px, 100%);
  padding: clamp(28px, 3.6vw, 40px);
  border-radius: var(--radius-xl);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0.015)),
    rgba(9, 12, 22, 0.6);
  border: 1px solid var(--line-2);
  box-shadow:
    0 40px 120px -40px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(0,0,0,0.3),
    inset 0 1px 0 rgba(255,255,255,0.06);
  backdrop-filter: blur(22px) saturate(140%);
  -webkit-backdrop-filter: blur(22px) saturate(140%);
}
.login-card h1 { margin-top: 28px; font: 600 1.85rem/1.15 var(--font-display); letter-spacing: -0.01em; }
.login-card .sub { margin-top: 8px; color: var(--text-3); font-size: 15px; }
.form { margin-top: 30px; display: grid; gap: 18px; }
.field { display: grid; gap: 8px; }
.field label, .field .label { font-size: 13.5px; font-weight: 500; color: var(--text-2); }
.field-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.input-wrap { position: relative; }
.input {
  width: 100%;
  height: 50px;
  padding: 0 16px;
  border-radius: 12px;
  background: rgba(5, 6, 10, 0.55);
  border: 1px solid var(--line-2);
  color: var(--text);
  font-size: 15.5px;
  outline: none;
  transition: border-color 0.3s var(--ease-out), box-shadow 0.4s var(--ease-out), background-color 0.3s;
  -webkit-appearance: none; appearance: none;
}
.input::placeholder { color: rgba(242, 244, 247, 0.28); }
.input:hover { border-color: var(--line-3); }
.input:focus {
  border-color: rgba(4, 186, 244, 0.65);
  background: rgba(5, 6, 10, 0.75);
  box-shadow: 0 0 0 4px rgba(4, 186, 244, 0.12), 0 0 24px -6px rgba(4, 186, 244, 0.35);
}
.input:-webkit-autofill { -webkit-text-fill-color: var(--text); box-shadow: 0 0 0 100px #0B1020 inset; caret-color: var(--text); }
.input.has-toggle { padding-right: 52px; }
.pw-toggle {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  width: 40px; height: 40px;
  display: grid; place-items: center;
  border-radius: 9px; border: 0;
  background: transparent; color: var(--text-3);
  transition: color 0.3s, background-color 0.3s;
}
.pw-toggle:hover, .pw-toggle:focus-visible { color: var(--text); background: rgba(255,255,255,0.06); }
.pw-toggle svg { width: 18px; height: 18px; }
.pw-toggle .i-hide { display: none; }
.pw-toggle[aria-pressed="true"] .i-show { display: none; }
.pw-toggle[aria-pressed="true"] .i-hide { display: block; }
.field-error {
  display: none;
  align-items: center; gap: 8px;
  color: #FF8C9A; font-size: 13px;
}
.field-error svg { width: 14px; height: 14px; flex: none; }
.field.has-error .field-error { display: flex; }
.field.has-error .input { border-color: rgba(255, 90, 110, 0.6); box-shadow: 0 0 0 4px rgba(255, 90, 110, 0.10); }

.form-meta { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 2px; }
.check { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; color: var(--text-2); cursor: pointer; user-select: none; }
.check input {
  -webkit-appearance: none; appearance: none;
  width: 18px; height: 18px; margin: 0;
  border-radius: 5px;
  border: 1px solid var(--line-3);
  background: rgba(5, 6, 10, 0.6);
  display: grid; place-items: center;
  transition: background-color 0.25s, border-color 0.25s;
  cursor: pointer;
}
.check input::after {
  content: ""; width: 9px; height: 5px;
  border: 2px solid #fff; border-top: 0; border-right: 0;
  transform: rotate(-45deg) translate(1px, -1px) scale(0.6);
  opacity: 0; transition: opacity 0.2s, transform 0.3s var(--ease-out);
}
.check input:checked { background: var(--brand); border-color: var(--cyan); }
.check input:checked::after { opacity: 1; transform: rotate(-45deg) translate(1px, -1px) scale(1); }
.check input:focus-visible { outline: 2px solid var(--ice); outline-offset: 2px; }
.form .link { font-size: 14px; }

.btn-submit { width: 100%; margin-top: 8px; }
.btn-submit .btn-state { display: inline-flex; align-items: center; gap: 10px; }
.btn-submit .s-loading, .btn-submit .s-success { display: none; }
.btn-submit[data-state="loading"] .s-idle, .btn-submit[data-state="success"] .s-idle { display: none; }
.btn-submit[data-state="loading"] .s-loading { display: inline-flex; }
.btn-submit[data-state="success"] .s-success { display: inline-flex; }
.btn-submit[data-state="loading"], .btn-submit[data-state="success"] { filter: none; cursor: progress; }
.btn-processing, .btn-submit[data-state="loading"] {
  color: var(--text);
  background: linear-gradient(180deg, rgba(255,255,255,0.06), rgba(255,255,255,0.015)), #0A1224;
  border-color: rgba(4, 186, 244, 0.38);
  box-shadow: 0 0 0 1px rgba(4, 186, 244, 0.18), 0 14px 40px -16px rgba(4, 186, 244, 0.55), inset 0 1px 0 rgba(255,255,255,0.06);
}
.btn-submit[data-state="success"] {
  background: linear-gradient(180deg, rgba(255,255,255,0.18), rgba(255,255,255,0) 52%), linear-gradient(180deg, var(--cyan), var(--azure));
  box-shadow: 0 0 0 1px rgba(68,223,249,0.6), 0 16px 50px -12px rgba(4,186,244,0.85);
}
.form-status { min-height: 20px; font-size: 13.5px; color: var(--text-3); text-align: center; }
.form-status.is-error { color: #FF8C9A; }
.login-alt { margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--line); font-size: 14px; color: var(--text-3); text-align: center; }
.login-alt a { color: var(--text); font-weight: 500; }
.login-alt a:hover { color: var(--ice); }
.secure-note {
  margin-top: 22px;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  font: 400 11px/1.4 var(--font-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-4);
}
.secure-note svg { width: 13px; height: 13px; }
.demo-hint {
  margin-top: 14px;
  font: 400 12px/1.5 var(--font-mono); color: var(--text-4); text-align: center;
}
.shake { animation: shake 0.5s var(--ease-out); }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-6px); }
  40% { transform: translateX(5px); }
  60% { transform: translateX(-3px); }
  80% { transform: translateX(1.5px); }
}

/* Page exit cover (used after success) */
.page-cover {
  position: fixed; inset: 0; z-index: 200;
  background: var(--bg);
  opacity: 0; pointer-events: none;
  transition: opacity 0.6s var(--ease-out);
}
.is-leaving .page-cover { opacity: 1; }
.page-enter .page-cover { opacity: 1; transition: none; }

@media (min-width: 981px) {
  .login-visual { position: sticky; top: 0; height: 100vh; height: 100svh; min-height: 0; align-self: start; }
}
@media (min-width: 981px) and (max-height: 840px) {
  .login-panel { padding-block: 28px; }
  .login-card { padding: 28px 34px 26px; }
  .login-card h1 { margin-top: 20px; font-size: 1.7rem; }
  .form { margin-top: 22px; gap: 14px; }
  .login-alt { margin-top: 18px; padding-top: 16px; }
  .secure-note { margin-top: 14px; }
  .demo-hint { margin-top: 8px; }
}
@media (max-width: 980px) {
  .login { grid-template-columns: 1fr; }
  .login-visual { min-height: 44svh; height: 44svh; border-right: 0; border-bottom: 1px solid var(--line); --fb-w: min(64vw, 380px); }
  .login-visual-bottom { display: none; }
  .login-panel { padding-top: 0; place-items: start center; background: var(--bg); }
  .login-card { margin-top: -72px; position: relative; z-index: 4; }
}
@media (max-width: 420px) {
  .login-visual { min-height: 300px; height: 38svh; }
  .login-card { padding: 24px 20px; border-radius: 22px; }
  .form-meta { flex-direction: row; }
}

/* ==========================================================================
   BRAND SHOWCASE
   ========================================================================== */
.brand-hero { padding-top: calc(var(--nav-h) + clamp(56px, 8vw, 112px)); padding-bottom: clamp(40px, 5vw, 64px); }
.brand-hero h1 { margin-top: 22px; font-size: clamp(2.5rem, 1.6rem + 3.4vw, 4.6rem); }
.brand-hero .lede { margin-top: 22px; max-width: 640px; }
.toc { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 8px; }
.toc a {
  display: inline-flex; align-items: center; gap: 8px;
  height: 34px; padding: 0 14px; border-radius: 999px;
  border: 1px solid var(--line-2);
  background: rgba(255,255,255,0.02);
  color: var(--text-3); font-size: 13.5px;
  transition: color 0.3s, border-color 0.3s, background-color 0.3s;
}
.toc a:hover, .toc a:focus-visible { color: var(--text); border-color: var(--line-3); background: rgba(255,255,255,0.05); }
.toc a .mono { font-size: 11px; color: var(--text-4); }

.spec {
  padding-block: clamp(48px, 6vw, 80px);
  border-top: 1px solid var(--line);
}
.spec-head {
  display: grid; grid-template-columns: 220px 1fr; gap: 24px 48px; align-items: start;
}
.spec-num { font: 500 12px/1 var(--font-mono); letter-spacing: 0.14em; color: var(--cyan); text-transform: uppercase; }
.spec-num span { display: block; margin-top: 10px; color: var(--text-4); letter-spacing: 0.08em; text-transform: none; font-size: 12px; }
.spec h2 { font: 600 clamp(1.6rem, 1.2rem + 1.2vw, 2.25rem)/1.15 var(--font-display); letter-spacing: -0.01em; }
.spec-head .lede { margin-top: 12px; font-size: 16px; max-width: 70ch; }
.spec-body { margin-top: 32px; display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; }
.spec-body.wide { grid-template-columns: 1fr; }

.frame {
  position: relative;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line-2);
  background: var(--bg-2);
  overflow: hidden;
  box-shadow: 0 30px 80px -40px rgba(0,0,0,0.9);
}
.frame-bar {
  display: flex; align-items: center; gap: 12px;
  height: 38px; padding: 0 14px;
  border-bottom: 1px solid var(--line);
  background: rgba(255,255,255,0.02);
  font: 400 11px/1 var(--font-mono); letter-spacing: 0.08em; color: var(--text-4);
}
.frame-bar .dots { display: flex; gap: 6px; }
.frame-bar .dots i { width: 9px; height: 9px; border-radius: 50%; background: rgba(255,255,255,0.12); }
.frame-bar .url { flex: 1; text-align: center; }
.frame-hero { aspect-ratio: 16 / 8.2; }
.frame-hero .scene-media { position: absolute; inset: 38px 0 0 0; --glow-x: 70%; --fb-x: 52%; --fb-w: 40%; }
.frame-overlay {
  position: absolute; z-index: 3; left: 5%; top: calc(38px + 16%);
  max-width: 44%;
  pointer-events: none;
}
.frame-overlay .mini-h { font: 600 clamp(1.1rem, 0.6rem + 1.6vw, 2.2rem)/1.08 var(--font-display); letter-spacing: -0.01em; }
.frame-overlay .mini-p { margin-top: 10px; color: var(--text-3); font-size: clamp(11px, 0.6rem + 0.4vw, 14px); line-height: 1.5; }
.frame-overlay .mini-btns { margin-top: 14px; display: flex; gap: 8px; }
.frame-overlay .mini-btns i { display: block; height: clamp(18px, 2vw, 28px); border-radius: 7px; width: clamp(64px, 9vw, 120px); background: linear-gradient(180deg, #0A8FE0, var(--brand)); }
.frame-overlay .mini-btns i + i { width: clamp(48px, 6vw, 84px); background: rgba(255,255,255,0.06); border: 1px solid var(--line-2); }

.notes {
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.01));
  padding: 22px 22px 24px;
}
.notes dl { display: grid; gap: 16px; margin: 0; }
.notes dt { font: 500 11px/1 var(--font-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-4); }
.notes dd { margin: 7px 0 0; color: var(--text-2); font-size: 14.5px; line-height: 1.6; }
.notes code, .code {
  font: 400 12.5px/1.6 var(--font-mono);
  color: #BFEFFF;
  background: rgba(4, 186, 244, 0.06);
  border: 1px solid rgba(4, 186, 244, 0.14);
  border-radius: 6px;
  padding: 1px 6px;
  word-break: break-word;
}
pre.code {
  display: block; margin: 0; padding: 14px 16px;
  white-space: pre-wrap; overflow-x: auto;
  border-radius: 12px;
}

.console {
  display: flex; flex-wrap: wrap; gap: 6px;
  padding: 12px;
  border-top: 1px solid var(--line);
  background: rgba(255,255,255,0.015);
}
.console .lbl { width: 100%; font: 400 10.5px/1 var(--font-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-4); padding: 4px 4px 8px; }
.console button {
  height: 32px; padding: 0 12px;
  border-radius: 8px;
  border: 1px solid var(--line-2);
  background: rgba(255,255,255,0.03);
  color: var(--text-2);
  font: 400 12px/1 var(--font-mono);
  transition: color 0.25s, border-color 0.25s, background-color 0.25s;
}
.console button:hover, .console button:focus-visible { color: var(--text); border-color: var(--line-3); }
.console button[aria-pressed="true"] { color: var(--ice); border-color: rgba(4,186,244,0.5); background: rgba(4,186,244,0.08); }
.console button.danger[aria-pressed="true"] { color: #FF8C9A; border-color: rgba(255,90,110,0.5); background: rgba(255,90,110,0.08); }

.frame-login { display: grid; grid-template-columns: 1.1fr 0.9fr; aspect-ratio: 16 / 9; }
.frame-login .scene-media { position: relative; height: 100%; --glow-x: 50%; --fb-w: 64%; }
.frame-login .mock-form {
  display: grid; align-content: center; gap: 12px;
  padding: 8% 9%;
  background: var(--bg-2);
  border-left: 1px solid var(--line);
}
.mock-form .mf-h { font: 600 clamp(14px, 1.4vw, 20px)/1.2 var(--font-display); }
.mock-form .mf-i { height: clamp(24px, 2.6vw, 38px); border-radius: 8px; border: 1px solid var(--line-2); background: rgba(5,6,10,0.6); }
.mock-form .mf-i.focus { border-color: rgba(4,186,244,0.6); box-shadow: 0 0 0 3px rgba(4,186,244,0.12); }
.mock-form .mf-b { height: clamp(26px, 2.8vw, 40px); border-radius: 9px; background: linear-gradient(180deg, #0A8FE0, var(--brand)); margin-top: 6px; }

.stage {
  position: relative;
  display: grid; place-items: center;
  min-height: 220px;
  padding: 40px 28px;
  background:
    radial-gradient(60% 80% at 50% 0%, rgba(1, 61, 150, 0.14), transparent 70%),
    var(--bg-2);
}
.stage.light { background: #F4F6FA; color: #0A0E1A; }
.stage-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 40px 56px; }
.stage-cap { font: 400 11px/1 var(--font-mono); letter-spacing: 0.12em; color: var(--text-4); text-transform: uppercase; text-align: center; margin-top: 14px; }
.stage.light .stage-cap { color: rgba(10,14,26,0.45); }
.stage-item { display: grid; justify-items: center; }

.mock-nav {
  width: 100%;
  display: flex; align-items: center; gap: 24px;
  height: 64px; padding: 0 22px;
  border-radius: 14px;
  background: rgba(6, 8, 14, 0.72);
  border: 1px solid var(--line);
  backdrop-filter: blur(16px);
}
.mock-nav .links { display: flex; gap: 18px; font-size: 13.5px; color: var(--text-3); }
.mock-nav .right { margin-left: auto; display: flex; gap: 8px; }
.mock-footer {
  width: 100%;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px;
  padding: 28px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: radial-gradient(60% 120% at 10% 0%, rgba(0, 36, 111, 0.22), transparent 60%), var(--bg);
}
.mock-footer p { color: var(--text-4); font-size: 13px; }

.fav-row { display: flex; flex-wrap: wrap; align-items: end; justify-content: center; gap: 28px; }
.fav-row img { image-rendering: auto; }
.fav-tile { display: grid; place-items: center; padding: 6px; border-radius: 6px; border: 1px dashed var(--line-3); background: rgba(255,255,255,0.02); }
.tab-mock {
  display: inline-flex; align-items: center; gap: 10px;
  height: 40px; padding: 0 16px 0 12px;
  border-radius: 12px 12px 0 0;
  background: #1A1D26;
  border: 1px solid var(--line-2); border-bottom: 0;
  font-size: 13px; color: var(--text-2);
  min-width: 220px;
}
.tab-mock img { width: 16px; height: 16px; }
.tab-mock .x { margin-left: auto; color: var(--text-4); font-size: 14px; }

.frame-compact { width: min(360px, 100%); aspect-ratio: 4 / 3; margin-inline: auto; }
.frame-compact .scene-media { position: absolute; inset: 0; --glow-x: 50%; --fb-w: 70%; }
.compact-wrap { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; align-items: center; }
.compact-card {
  position: relative; overflow: hidden;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line-2);
  background: var(--bg-2);
}
.compact-card .scene-media { aspect-ratio: 4 / 3; --glow-x: 50%; --fb-w: 66%; }
.compact-card .cc-body { padding: 18px 20px 20px; border-top: 1px solid var(--line); }
.compact-card .cc-body strong { display: block; font: 600 16px/1.3 var(--font-display); }
.compact-card .cc-body span { display: block; margin-top: 6px; font-size: 13.5px; color: var(--text-3); }

.film {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line-2);
  background: var(--bg);
}
.film video { width: 100%; height: 100%; object-fit: cover; }
.film-empty {
  position: absolute; inset: 0;
  display: grid; place-items: center; align-content: center; gap: 18px;
  text-align: center;
  padding: 24px;
  background:
    radial-gradient(50% 60% at 50% 50%, rgba(1, 61, 150, 0.22), transparent 70%),
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px) 0 0 / 40px 40px,
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px) 0 0 / 40px 40px,
    var(--bg);
}
.film-empty strong { font: 600 1.2rem/1.3 var(--font-display); }
.film-empty span { color: var(--text-3); font-size: 14px; max-width: 46ch; }
.film-empty .chip { justify-self: center; }
.film.has-video .film-empty { display: none; }
.film.has-poster:not(.has-video) .film-empty {
  background: linear-gradient(180deg, rgba(5, 6, 10, 0.45), rgba(5, 6, 10, 0.8)), url("assets/hero_poster.jpg") center / cover no-repeat;
}
.film-corner {
  position: absolute; z-index: 2; left: 14px; top: 14px;
}

.swatches { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.swatch {
  display: grid; grid-template-rows: 84px auto;
  border-radius: 14px; overflow: hidden;
  border: 1px solid var(--line);
  background: var(--bg-2);
  text-align: left; padding: 0;
  transition: border-color 0.3s, transform 0.4s var(--ease-out);
}
.swatch:hover, .swatch:focus-visible { border-color: var(--line-3); }
.swatch .chipcol { display: block; }
.swatch .meta { padding: 10px 12px 12px; display: grid; gap: 4px; }
.swatch .meta b { font: 500 13px/1.2 var(--font-ui); color: var(--text); }
.swatch .meta span { font: 400 11.5px/1.2 var(--font-mono); color: var(--text-3); }
.type-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.type-card { padding: 24px; border-radius: var(--radius-lg); border: 1px solid var(--line); background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.01)); }
.type-card .sample { font-size: 44px; line-height: 1.05; margin-top: 18px; }
.type-card p { margin-top: 12px; color: var(--text-3); font-size: 14px; }

.toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 120;
  transform: translate(-50%, 20px);
  padding: 10px 16px; border-radius: 10px;
  background: rgba(10, 14, 26, 0.92); border: 1px solid var(--line-2);
  font: 400 12.5px/1 var(--font-mono); color: var(--text);
  opacity: 0; pointer-events: none;
  transition: opacity 0.35s var(--ease-out), transform 0.45s var(--ease-out);
}
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 1000px) {
  .spec-head { grid-template-columns: 1fr; gap: 16px; }
  .spec-body { grid-template-columns: 1fr; }
  .type-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .frame-hero { aspect-ratio: 4 / 5; }
  .frame-hero .scene-media { --glow-x: 50%; --fb-x: 0%; --fb-w: 70%; }
  .frame-overlay { left: 6%; right: 6%; top: auto; bottom: 6%; max-width: none; }
  .frame-login { grid-template-columns: 1fr; aspect-ratio: auto; }
  .frame-login .scene-media { aspect-ratio: 4 / 3; height: auto; }
  .frame-login .mock-form { border-left: 0; border-top: 1px solid var(--line); padding: 24px; }
  .mock-nav .links { display: none; }
  .mock-nav { padding: 0 14px; }
  .stage { padding: 32px 16px; }
}

/* JS present but ui.js never booted (blocked / failed): never leave content hidden */
.no-ui .rise, .no-ui .reveal { opacity: 1 !important; transform: none !important; filter: none !important; }

/* Dev-only (?devshot): stable layout for tall full-page screenshots */
.devshot .hero { min-height: 900px; }
.devshot .login { min-height: 900px; }

/* ==========================================================================
   Reduced motion
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.2s !important; transition-delay: 0s !important; }
  .js .rise, .js .reveal { opacity: 1; transform: none; filter: none; }
  .hero-media, .hero-content { transform: none !important; }
  .status-dot::after, .scroll-cue::before { display: none; }
}

/* ==========================================================================
   LANDING PAGE — conversion layer (index)
   ========================================================================== */
.hero h1.display { font-size: clamp(2.4rem, 1.35rem + 3.3vw, 4.5rem); }
.hero .lede strong { color: var(--text); font-weight: 600; }
.nav-phone { font-variant-numeric: tabular-nums; }
@media (max-width: 1100px) { .nav-phone { display: none; } }

/* Static (poster-first) hero: no fade-in delay on the composition */
.hero-media.is-fallback .scene-fallback { transition: none; }
.hero-media.is-live .scene-fallback { opacity: 0; }

.assurances {
  margin-top: 22px;
  display: flex; flex-wrap: wrap; gap: 8px 22px;
  list-style: none; padding: 0;
  color: var(--text-2); font-size: 14px;
}
.assurances li { display: inline-flex; align-items: center; gap: 8px; }
.assurances svg { width: 16px; height: 16px; fill: none; stroke: var(--cyan); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }

.quickstart { margin-top: 40px; padding-top: 26px; border-top: 1px solid var(--line); max-width: 560px; }
.quickstart-label { font-size: 14.5px; color: var(--text); font-weight: 500; }
.quickstart-label span { color: var(--text-3); font-weight: 400; }
.qs-chips { margin-top: 14px; display: flex; flex-wrap: wrap; gap: 8px; }
.qs-chip {
  height: 38px; padding: 0 15px;
  border-radius: 999px;
  border: 1px solid var(--line-2);
  background: rgba(10, 14, 26, 0.6);
  color: var(--text-2);
  font: 500 14px/1 var(--font-ui);
  cursor: pointer;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  transition: border-color 0.3s var(--ease-out), color 0.3s, background-color 0.3s, transform 0.3s var(--ease-out);
}
.qs-chip:hover, .qs-chip:focus-visible { border-color: rgba(4, 186, 244, 0.55); color: var(--text); background: rgba(4, 186, 244, 0.08); }
.qs-chip:focus-visible { outline: 2px solid var(--ice); outline-offset: 2px; }
.qs-chip:active { transform: scale(0.98); }

@media (max-width: 900px) {
  .hero-media { height: clamp(260px, 72vw, 400px); --fb-w: min(62vw, 340px); --fb-y: 0px; }
  .hero-scrim { height: clamp(260px, 72vw, 400px); }
  .hero-content { margin-top: calc(clamp(260px, 72vw, 400px) * -0.22); }
  .hero .cta-row .btn-lg { flex: 1 1 100%; }
  .hero .cta-row .btn-ghost { display: none; }
}

/* ---------- Pains ---------- */
.pains { padding-top: clamp(72px, 7vw, 112px); }
.pain-grid {
  margin-top: clamp(36px, 4.5vw, 56px);
  list-style: none; padding: 0;
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px;
}
.pain {
  display: flex; gap: 14px; align-items: flex-start;
  padding: 22px 22px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.01));
  color: var(--text-2); font-size: 15.5px; line-height: 1.55;
}
.pain-x {
  flex: none; width: 22px; height: 22px; margin-top: 1px;
  border-radius: 7px;
  background: rgba(255, 90, 110, 0.10);
  border: 1px solid rgba(255, 90, 110, 0.28);
  position: relative;
}
.pain-x::before, .pain-x::after {
  content: ""; position: absolute; left: 50%; top: 50%; width: 9px; height: 1.6px; border-radius: 1px;
  background: #FF8C9A; translate: -50% -50%;
}
.pain-x::before { rotate: 45deg; } .pain-x::after { rotate: -45deg; }
.pains-foot {
  margin-top: 32px;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px 32px;
  padding: 24px 28px;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(4, 186, 244, 0.22);
  background: linear-gradient(90deg, rgba(4, 186, 244, 0.07), rgba(1, 61, 150, 0.05));
}
.pains-foot p { color: var(--text-2); font-size: 16.5px; max-width: 60ch; }
.pains-foot strong { color: var(--text); font-weight: 600; }
@media (max-width: 960px) { .pain-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .pain-grid { grid-template-columns: 1fr; } .pains-foot .btn { width: 100%; } }

/* ---------- Services (compact) + technical proof ---------- */
#solucoes .service { min-height: 0; grid-template-rows: auto auto 1fr; }
.h3 { font: 600 clamp(1.45rem, 1.1rem + 1vw, 2rem)/1.15 var(--font-display); letter-spacing: -0.01em; text-wrap: balance; }
@media (max-width: 900px) {  }

/* ---------- Testimonials (activate when real content exists) ---------- */
.quote-grid { margin-top: 40px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.quote { padding: 28px; margin: 0; display: grid; gap: 20px; align-content: space-between; }
.quote blockquote { margin: 0; color: var(--text); font-size: 16px; line-height: 1.6; }
.quote figcaption { display: grid; gap: 4px; font-size: 14px; color: var(--text-3); }
.quote figcaption strong { color: var(--text); font-weight: 600; }
.logo-row { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 28px 44px; align-items: center; opacity: 0.7; }
@media (max-width: 900px) { .quote-grid { grid-template-columns: 1fr; } }

/* ---------- Lead section ---------- */
.lead-section { padding-top: clamp(48px, 6vw, 96px); }
.lead-card {
  position: relative; overflow: hidden;
  display: grid; grid-template-columns: 0.95fr 1.05fr; gap: clamp(28px, 5vw, 72px); align-items: start;
  padding: clamp(28px, 5vw, 64px);
  border-radius: var(--radius-xl);
  border: 1px solid var(--line-2);
  background:
    radial-gradient(70% 90% at 0% 0%, rgba(1, 88, 182, 0.28), transparent 60%),
    radial-gradient(60% 80% at 100% 100%, rgba(0, 36, 111, 0.35), transparent 60%),
    linear-gradient(180deg, #0A0E1A, #07080D);
}
.lead-card > * { position: relative; min-width: 0; }
.lead-offer .h2 { margin-top: 18px; }
.lead-offer .lede { margin-top: 18px; }
.lead-offer .lede strong { color: var(--text); }
.gains { margin-top: 20px; list-style: none; padding: 0; display: grid; gap: 12px; }
.gains li { position: relative; padding-left: 32px; color: var(--text-2); font-size: 15.5px; line-height: 1.55; }
.gains li b { color: var(--text); font-weight: 600; }
.gains li::before {
  content: ""; position: absolute; left: 0; top: 2px; width: 20px; height: 20px; border-radius: 6px;
  background: rgba(4, 186, 244, 0.12) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2344DFF9' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 12.5 4.2 4L19 7'/%3E%3C/svg%3E") center / 13px no-repeat;
  border: 1px solid rgba(4, 186, 244, 0.3);
}
.lead-contact { margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px; }
.lead-contact p { width: 100%; color: var(--text-3); font-size: 14px; }
.lead-contact a { display: inline-flex; align-items: center; gap: 9px; color: var(--text); font-weight: 500; font-size: 15px; }
.lead-contact a:hover, .lead-contact a:focus-visible { color: var(--ice); }
.lead-contact svg { width: 17px; height: 17px; color: var(--cyan); }

.lead-form-wrap {
  border-radius: var(--radius-lg);
  padding: clamp(22px, 3vw, 34px);
  background: var(--glass);
  border: 1px solid var(--line-2);
  box-shadow: 0 30px 80px -40px rgba(4, 186, 244, 0.35), inset 0 1px 0 rgba(255,255,255,0.05);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  scroll-margin-top: calc(var(--nav-h) + 16px);
}
.lead-progress { height: 4px; border-radius: 4px; background: rgba(255,255,255,0.07); overflow: hidden; }
.lead-progress span { display: block; height: 100%; width: 33.33%; border-radius: inherit; background: linear-gradient(90deg, var(--brand), var(--cyan), var(--ice)); transition: width 0.6s var(--ease-out); box-shadow: 0 0 12px rgba(4, 186, 244, 0.6); }
.lead-step-label { margin-top: 12px; font: 500 11.5px/1 var(--font-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-4); }
.lead-step-label b { color: var(--cyan); font-weight: 500; }
.lead-step { border: 0; padding: 0; margin: 22px 0 0; min-width: 0; display: grid; gap: 18px; }
.lead-step[hidden] { display: none; }
.lead-step:not([hidden]) { animation: step-in 0.5s var(--ease-out); }
@keyframes step-in { from { opacity: 0; transform: translateX(10px); } to { opacity: 1; transform: none; } }
.lead-q { padding: 0; font: 600 clamp(1.3rem, 1.1rem + 0.6vw, 1.6rem)/1.2 var(--font-display); color: var(--text); letter-spacing: -0.005em; }
.lead-hint { margin-top: -10px; color: var(--text-3); font-size: 14px; }
.opt-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.opt-grid-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.opt { position: relative; display: block; cursor: pointer; }
.opt input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.opt span {
  display: flex; align-items: center; gap: 10px;
  min-height: 50px; padding: 10px 14px;
  border-radius: 12px; border: 1px solid var(--line-2);
  background: rgba(5, 6, 10, 0.5);
  color: var(--text-2); font-size: 14.5px; line-height: 1.3; font-weight: 500;
  transition: border-color 0.25s, background-color 0.25s, color 0.25s, box-shadow 0.3s;
}
.opt input[type="checkbox"] + span::before {
  content: ""; flex: none; width: 18px; height: 18px; border-radius: 5px;
  border: 1px solid var(--line-3); background: rgba(5,6,10,0.6) center / 12px no-repeat;
  transition: background-color 0.25s, border-color 0.25s;
}
.opt-grid-5 .opt span { justify-content: center; text-align: center; font-variant-numeric: tabular-nums; padding-inline: 6px; }
.opt:hover span { border-color: var(--line-3); color: var(--text); }
.opt input:focus-visible + span { outline: 2px solid var(--ice); outline-offset: 2px; }
.opt input:checked + span {
  border-color: rgba(4, 186, 244, 0.7); color: var(--text);
  background: rgba(4, 186, 244, 0.10);
  box-shadow: 0 0 0 3px rgba(4, 186, 244, 0.10);
}
.opt input[type="checkbox"]:checked + span::before {
  background-color: var(--brand); border-color: var(--cyan);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 12.5 4.2 4L19 7'/%3E%3C/svg%3E");
}
.opt-tag { color: var(--text-4); font-weight: 400; font-size: 12.5px; margin-left: 4px; }
.textarea { height: auto; min-height: 76px; padding: 13px 16px; resize: vertical; line-height: 1.5; font-family: inherit; }
.field-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.lead-actions { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 4px; }
.lead-actions .lead-next, .lead-actions .lead-submit { margin-left: auto; }
.lead-step[data-step="1"] .lead-actions .btn { width: 100%; }
.lead-submit .spin { display: none; width: 18px; height: 18px; border-radius: 50%; border: 2px solid rgba(255,255,255,0.35); border-top-color: #fff; animation: spin 0.8s linear infinite; }
.lead-submit.is-busy .spin { display: inline-block; }
.lead-submit.is-busy { opacity: 0.85; }
@keyframes spin { to { transform: rotate(360deg); } }
.lead-legal { color: var(--text-4); font-size: 12.5px; line-height: 1.55; }
.lead-fail { padding: 12px 14px; border-radius: 12px; border: 1px solid rgba(255, 90, 110, 0.35); background: rgba(255, 90, 110, 0.08); color: #FFC2CA; font-size: 14px; line-height: 1.55; }
.lead-fail[hidden] { display: none; }
.lead-done { text-align: center; padding: 28px 8px; display: grid; justify-items: center; gap: 12px; outline: none; }
.lead-done[hidden] { display: none; }
.lead-done h3 { font: 600 1.7rem/1.2 var(--font-display); }
.lead-done p { color: var(--text-2); max-width: 40ch; line-height: 1.6; }
.lead-done strong { color: var(--text); }
.done-mark { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle, rgba(4,186,244,0.25), rgba(4,186,244,0.06)); border: 1px solid rgba(4,186,244,0.5); box-shadow: 0 0 40px -6px rgba(4,186,244,0.6); animation: done-pop 0.7s var(--ease-out); }
.done-mark svg { width: 30px; height: 30px; fill: none; stroke: var(--ice); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
@keyframes done-pop { from { transform: scale(0.6); opacity: 0; } to { transform: none; opacity: 1; } }
@media (max-width: 960px) { .lead-card { grid-template-columns: 1fr; } }
@media (max-width: 560px) {
  .lead-card { padding: 22px 16px; border-radius: 22px; }
  .lead-form-wrap { padding: 20px 16px; }
  .field-2 { grid-template-columns: 1fr; }
  .opt-grid { grid-template-columns: 1fr; }
  .opt-grid-5 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .lead-actions .btn-lg { flex: 1; }
  .lead-actions { flex-wrap: wrap-reverse; }
  .lead-actions .lead-back { width: 100%; }
}

/* ---------- FAQ ---------- */
.faq-inner { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: clamp(28px, 5vw, 72px); align-items: start; }
.faq-list { display: grid; gap: 10px; }
.faq-item { border-radius: var(--radius); border: 1px solid var(--line); background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.01)); transition: border-color 0.3s; }
.faq-item[open] { border-color: rgba(4, 186, 244, 0.28); }
.faq-item summary {
  list-style: none; cursor: pointer;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 20px 22px; font-weight: 600; font-size: 16px; color: var(--text);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: ""; flex: none; width: 22px; height: 22px; border-radius: 7px; border: 1px solid var(--line-2);
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2344DFF9' stroke-width='2.2' stroke-linecap='round'%3E%3Cpath d='M12 6v12M6 12h12'/%3E%3C/svg%3E") center / 12px no-repeat;
  transition: transform 0.4s var(--ease-out);
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item summary:focus-visible { outline: 2px solid var(--ice); outline-offset: 2px; border-radius: var(--radius); }
.faq-item p { padding: 0 22px 20px; color: var(--text-2); line-height: 1.7; font-size: 15.5px; }
@media (max-width: 900px) { .faq-inner { grid-template-columns: 1fr; } }

/* ---------- Final CTA ---------- */
.final-cta { padding-top: 0; }
.final-card {
  text-align: center; display: grid; justify-items: center; gap: 18px;
  padding: clamp(40px, 6vw, 80px) clamp(22px, 4vw, 48px);
  border-radius: var(--radius-xl); border: 1px solid rgba(4, 186, 244, 0.22);
  background: radial-gradient(60% 120% at 50% 0%, rgba(4, 186, 244, 0.14), transparent 65%), linear-gradient(180deg, #0A0E1A, #07080D);
}
.final-card .h2 { max-width: 20ch; }
.final-card .btn { margin-top: 8px; }

/* ---------- Sticky mobile CTA ---------- */
.sticky-cta { display: none; }
@media (max-width: 900px) {
  .sticky-cta {
    position: fixed; z-index: 60; left: 0; right: 0; bottom: 0;
    display: flex; gap: 8px;
    padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
    background: rgba(5, 6, 10, 0.86);
    border-top: 1px solid var(--line-2);
    backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
    transform: translateY(110%); transition: transform 0.45s var(--ease-out);
  }
  .sticky-cta.is-on { transform: none; }
  .sticky-cta .btn-primary { flex: 1; }
  .sticky-call { width: 48px; padding: 0; }
  .sticky-call svg { width: 20px; height: 20px; }
  .footer { padding-bottom: 80px; }
}

/* Conditional copy: 3D live (desktop) vs static */
.done-actions { margin-top: 6px; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.done-actions .btn[hidden] { display: none; }

/* Tightening pass */
.lead-q { margin-bottom: 4px; }
.lead-hint { margin-top: 0; }
.lead-step > .lead-q + .lead-hint { margin-top: 0; }
.hero h1.display { font-size: clamp(2.3rem, 1.3rem + 3vw, 4.1rem); }
.hero .lede { max-width: 580px; }
.hero .cta-row { margin-top: 30px; }
.quickstart { margin-top: 30px; padding-top: 22px; }
@media (min-width: 901px) and (max-height: 820px) {
  .hero-content { padding-top: calc(var(--nav-h) + 28px); padding-bottom: 64px; }
}

/* Mobile: form right after the headline (less scrolling to convert) */
@media (max-width: 960px) {
  .lead-card { gap: 0; }
  .lead-offer { display: contents; }
  .lead-offer > .eyebrow, .lead-offer > .h2, .lead-offer > .lede { order: 1; }
  .lead-form-wrap { order: 2; margin-top: 24px; }
  .lead-offer > .gains { order: 3; margin-top: 28px; }
  .lead-offer > .lead-contact { order: 4; }
  .lead-offer > .lede { margin-top: 14px; }
}
@media (max-width: 520px) {
  .hero .status-pill { height: auto; min-height: 32px; padding: 7px 12px; font-size: 12.5px; line-height: 1.3; }
}

.btn-quiet { background: transparent; }
.lead-back { color: var(--text-3); }

.hero .qs-chip { backdrop-filter: none; -webkit-backdrop-filter: none; background: rgba(10, 14, 26, 0.85); }

.footer h3.footer-h { font: 500 11.5px/1 var(--font-mono); letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-4); }

/* ==========================================================================
   v3 — services grid (linked), founder, service pages
   ========================================================================== */
.services-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.services-grid-3 .service { min-height: 0; grid-template-rows: auto auto 1fr auto; padding: clamp(24px, 2.4vw, 32px); }
.services-grid-3 .service h3 { margin-top: 22px; font-size: 1.3rem; }
.services-grid-3 .service p { font-size: 15px; }
.service-link { color: inherit; text-decoration: none; }
.service-link:hover { border-color: rgba(4, 186, 244, 0.35); transform: translateY(-2px); }
.service-link:focus-visible { outline: 2px solid var(--ice); outline-offset: 3px; }
.service-more { margin-top: 20px; display: inline-flex; align-items: center; gap: 8px; color: var(--cyan); font-size: 14.5px; font-weight: 500; }
.service-more svg { width: 15px; height: 15px; transition: transform 0.4s var(--ease-out); }
.service-link:hover .service-more svg { transform: translateX(3px); }
.service-products { color: var(--text-3); font-weight: 400; gap: 6px; flex-wrap: wrap; }
.service-products a { color: var(--text-2); text-decoration: underline; text-decoration-color: rgba(4,186,244,0.4); text-underline-offset: 3px; }
.service-products a:hover { color: var(--text); }
@media (max-width: 1020px) { .services-grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .services-grid-3 { grid-template-columns: 1fr; } }

/* Founder */
.founder { padding-bottom: 0; }
.founder-card {
  display: grid; grid-template-columns: auto 1fr; gap: clamp(24px, 4vw, 56px); align-items: center;
  padding: clamp(26px, 4vw, 48px);
  border-radius: var(--radius-xl); border: 1px solid var(--line-2);
  background: radial-gradient(50% 120% at 0% 50%, rgba(1, 88, 182, 0.22), transparent 65%), linear-gradient(180deg, #0A0E1A, #07080D);
}
.founder-photo { margin: 0; position: relative; width: clamp(140px, 16vw, 200px); aspect-ratio: 1; }
.founder-photo::before {
  content: ""; position: absolute; inset: -10px; border-radius: 50%;
  background: conic-gradient(from 200deg, rgba(68,223,249,0.0), rgba(68,223,249,0.55), rgba(1,61,150,0.0) 70%);
  filter: blur(14px); opacity: 0.55;
}
.founder-photo img { position: relative; width: 100%; height: 100%; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 1px rgba(4,186,244,0.35), 0 24px 60px -20px rgba(4,186,244,0.45); }
.founder-copy .h2 { margin-top: 16px; font-size: clamp(1.7rem, 1.2rem + 1.6vw, 2.5rem); }
.founder-copy p:not(.eyebrow) { margin-top: 14px; color: var(--text-2); font-size: 16.5px; line-height: 1.7; max-width: 62ch; }
.founder-sign { margin-top: 20px; display: grid; gap: 4px; }
.founder-sign strong { font: 600 1.1rem/1.2 var(--font-display); color: var(--text); }
.founder-sign span { font: 400 12px/1 var(--font-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-4); }
@media (max-width: 700px) { .founder-card { grid-template-columns: 1fr; justify-items: start; } }

.lead-who { margin-top: 28px; display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: var(--radius); border: 1px solid var(--line-2); background: rgba(5,6,10,0.4); }
.lead-who img { width: 44px; height: 44px; border-radius: 50%; flex: none; box-shadow: 0 0 0 1px rgba(4,186,244,0.35); }
.lead-who p { color: var(--text-2); font-size: 14.5px; line-height: 1.5; }
.lead-who strong { color: var(--text); font-weight: 600; }
@media (max-width: 960px) { .lead-offer > .lead-who { order: 4; } .lead-offer > .lead-contact { order: 5; } }

/* ---------- Service pages ---------- */
.svc-hero { position: relative; overflow: hidden; padding-top: calc(var(--nav-h) + clamp(36px, 5vw, 72px)); padding-bottom: clamp(56px, 6vw, 96px); }
.svc-hero::before {
  content: ""; position: absolute; inset: -20% -10% auto auto; width: 70vw; height: 80vh; pointer-events: none;
  background: radial-gradient(closest-side, rgba(1, 88, 182, 0.28), rgba(0, 36, 111, 0.10) 55%, transparent);
}
.svc-hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(rgba(255,255,255,0.022) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.022) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(60% 70% at 80% 30%, #000, transparent 75%); mask-image: radial-gradient(60% 70% at 80% 30%, #000, transparent 75%);
}
.svc-hero .container { position: relative; z-index: 1; display: grid; grid-template-columns: 1.15fr 0.85fr; gap: clamp(32px, 5vw, 72px); align-items: center; }
.svc-hero h1 { margin-top: 22px; font-size: clamp(2.2rem, 1.3rem + 2.8vw, 3.9rem); }
.svc-hero .lede { margin-top: 22px; max-width: 600px; }
.svc-hero .cta-row { margin-top: 30px; }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 0 0 22px; font: 400 12.5px/1 var(--font-mono); letter-spacing: 0.04em; color: var(--text-4); }
.crumbs li + li::before { content: "/"; margin-right: 8px; color: var(--text-4); }
.crumbs a { color: var(--text-3); }
.crumbs a:hover { color: var(--text); }
.crumbs [aria-current] { color: var(--text-2); }
@media (max-width: 960px) { .svc-hero .container { grid-template-columns: 1fr; } .svc-hero .cta-row .btn-lg { flex: 1 1 100%; } }

/* "Mapa de Ganhos" preview card */
.map-card {
  position: relative; border-radius: var(--radius-lg); padding: 24px;
  border: 1px solid var(--line-2); background: var(--glass);
  box-shadow: 0 40px 100px -40px rgba(4,186,244,0.4), inset 0 1px 0 rgba(255,255,255,0.05);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
}
.map-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.map-head b { font: 600 1.05rem/1.2 var(--font-display); color: var(--text); }
.map-head span { font: 500 10.5px/1 var(--font-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--cyan); padding: 6px 8px; border-radius: 6px; background: rgba(4,186,244,0.08); border: 1px solid rgba(4,186,244,0.25); }
.map-rows { list-style: none; padding: 0; margin: 6px 0 0; }
.map-rows li { display: grid; grid-template-columns: 22px 1fr auto; gap: 12px; align-items: center; padding: 13px 0; border-bottom: 1px dashed var(--line); }
.map-rows .n { font: 500 11px/1 var(--font-mono); color: var(--text-4); }
.map-rows .t { color: var(--text); font-size: 14.5px; font-weight: 500; }
.map-rows .bar { display: block; margin-top: 8px; height: 5px; border-radius: 5px; background: rgba(255,255,255,0.06); overflow: hidden; }
.map-rows .bar i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--brand), var(--cyan)); }
.map-rows .tag { font: 500 10.5px/1 var(--font-mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); padding: 6px 8px; border-radius: 6px; border: 1px solid var(--line-2); white-space: nowrap; }
.map-foot { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 16px; }
.map-foot div { padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line); background: rgba(5,6,10,0.45); display: grid; gap: 6px; }
.map-foot dt { font: 500 10.5px/1 var(--font-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-4); }
.map-foot dd { margin: 0; font: 600 0.98rem/1.2 var(--font-display); color: var(--text); }
.map-note { margin-top: 12px; font-size: 12.5px; color: var(--text-4); }

/* What / why grids */
.feat-grid { margin-top: clamp(36px, 4.5vw, 56px); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.feat { padding: 26px; }
.feat .icon-tile { width: 40px; height: 40px; border-radius: 11px; }
.feat .icon-tile svg { width: 19px; height: 19px; }
.feat h3 { margin-top: 18px; font: 600 1.15rem/1.25 var(--font-display); }
.feat p { margin-top: 8px; color: var(--text-3); font-size: 15px; line-height: 1.6; }
.why-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.why-grid .feat h3 { margin-top: 0; }
@media (max-width: 1020px) { .feat-grid, .why-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .feat-grid, .why-grid { grid-template-columns: 1fr; } }

/* Examples: before → after */
.ex-grid { margin-top: clamp(32px, 4vw, 52px); display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.ex { padding: 24px; display: grid; gap: 14px; align-content: start; }
.ex-sector { font: 500 11.5px/1 var(--font-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--cyan); }
.ex-row { display: grid; grid-template-columns: 74px 1fr; gap: 12px; align-items: start; }
.ex-row b { font: 500 10.5px/1.6 var(--font-mono); letter-spacing: 0.1em; text-transform: uppercase; }
.ex-row.before b { color: #FF8C9A; }
.ex-row.after b { color: var(--ice); }
.ex-row p { color: var(--text-2); font-size: 15px; line-height: 1.6; }
.ex-row.after p { color: var(--text); }
@media (max-width: 760px) { .ex-grid { grid-template-columns: 1fr; } }

/* 4 steps */
.steps-4 { margin-top: clamp(36px, 4.5vw, 56px); display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; list-style: none; padding: 0; counter-reset: s; }
.steps-4 .step { counter-increment: s; }
@media (max-width: 1020px) { .steps-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .steps-4 { grid-template-columns: 1fr; } }

/* Related services */
.related { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 28px; }
.related a { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 20px 22px; border-radius: var(--radius); border: 1px solid var(--line-2); background: rgba(255,255,255,0.02); color: var(--text); font-weight: 600; transition: border-color 0.3s, background-color 0.3s; }
.related a:hover, .related a:focus-visible { border-color: rgba(4,186,244,0.45); background: rgba(4,186,244,0.05); }
.related svg { width: 16px; height: 16px; color: var(--cyan); flex: none; }
@media (max-width: 860px) { .related { grid-template-columns: 1fr; } }

.founder-photo picture, .lead-who picture { display: contents; }
.founder-photo img { object-position: 50% 30%; }

/* Cookie consent */
.cookie-box {
  position: fixed; z-index: 90; right: 20px; bottom: 20px; width: min(420px, calc(100% - 24px));
  padding: 18px 18px 16px; border-radius: 18px;
  background: rgba(8, 11, 20, 0.94); border: 1px solid var(--line-2);
  box-shadow: 0 30px 80px -30px rgba(0,0,0,0.8);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  transform: translateY(16px); opacity: 0; transition: transform 0.5s var(--ease-out), opacity 0.5s var(--ease-out);
}
.cookie-box.is-on { transform: none; opacity: 1; }
.cookie-box p { color: var(--text-3); font-size: 13px; line-height: 1.55; }
.cookie-box p strong { display: block; color: var(--text); font-size: 14px; margin-bottom: 4px; }
.cookie-actions { margin-top: 14px; display: flex; gap: 8px; }
.cookie-actions .btn { flex: 1; }
@media (max-width: 900px) { .cookie-box { left: 12px; right: 12px; bottom: calc(80px + env(safe-area-inset-bottom)); width: auto; } }
