/* Hallmark · macrostructure: Workbench · tone: cinematic forensic · anchor hue: cyan */
/* Hallmark · pre-emit critique: P5 H5 E4 S5 R4 V4 */

@font-face {
  font-family: "Satoshi";
  src: url("../fonts/satoshi-400.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Satoshi";
  src: url("../fonts/satoshi-500.woff2") format("woff2");
  font-style: normal;
  font-weight: 500;
  font-display: swap;
}

@font-face {
  font-family: "Satoshi";
  src: url("../fonts/satoshi-700.woff2") format("woff2");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

@font-face {
  font-family: "Satoshi";
  src: url("../fonts/satoshi-900.woff2") format("woff2");
  font-style: normal;
  font-weight: 900;
  font-display: swap;
}

@font-face {
  font-family: "JetBrains Mono";
  src: url("../fonts/jetbrains-mono-500-latin.woff2") format("woff2");
  font-style: normal;
  font-weight: 500;
  font-display: swap;
}

@font-face {
  font-family: "Montserrat";
  src: url("../fonts/montserrat-latin-variable.woff2") format("woff2");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --forge-black: #05080a;
  --carbon: #081015;
  --gunmetal: #11191e;
  --steel: #24333b;
  --quartz: #e9f5fa;
  --mist: #9aadb7;
  --signal: #27b9ff;
  --signal-hot: #7bd9ff;
  --interlock: #e8a74c;
  --line: rgba(163, 211, 233, 0.16);
  --line-strong: rgba(163, 211, 233, 0.32);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-ui: cubic-bezier(0.22, 0.8, 0.32, 1);
  --nav-height: 78px;
  --font-heading: "Montserrat", "Segoe UI", sans-serif;
  --font-header: "JetBrains Mono", monospace;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  overflow-x: clip;
  color-scheme: dark;
  scroll-behavior: smooth;
  background: var(--forge-black);
}

[id] {
  scroll-margin-top: calc(var(--nav-height) + 24px);
}

body {
  margin: 0;
  min-width: 320px;
  overflow-x: clip;
  color: var(--quartz);
  background:
    radial-gradient(circle at 66% 10%, rgba(39, 185, 255, 0.08), transparent 34rem),
    var(--forge-black);
  font-family: "Satoshi", sans-serif;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body::before {
  position: fixed;
  z-index: 100;
  inset: 0;
  pointer-events: none;
  content: "";
  opacity: 0.18;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 160 160' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.2'/%3E%3C/svg%3E");
  mix-blend-mode: soft-light;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
a {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

button {
  font: inherit;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  min-width: 0;
  overflow-wrap: anywhere;
  font-family: var(--font-heading);
}

button,
.primary-action,
.quiet-action,
.nav-action {
  white-space: nowrap;
}

button:focus-visible,
a:focus-visible {
  outline: 2px solid var(--signal-hot);
  outline-offset: 4px;
}

.skip-link {
  position: fixed;
  z-index: 200;
  top: 12px;
  left: 12px;
  padding: 10px 14px;
  color: #041016;
  background: var(--quartz);
  transform: translateY(-160%);
  transition: transform 180ms ease-out;
}

.skip-link:focus {
  transform: translateY(0);
}

.engine-nav {
  position: fixed;
  z-index: 80;
  top: 0;
  left: 0;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto minmax(220px, 1fr);
  align-items: center;
  width: 100%;
  min-height: var(--nav-height);
  padding: 14px clamp(20px, 3.4vw, 58px);
  border-bottom: 1px solid var(--line);
  background: rgba(5, 8, 10, 0.72);
  backdrop-filter: blur(22px) saturate(130%);
  font-family: var(--font-header);
  transition: transform 420ms var(--ease-out), background 240ms ease;
}

.engine-nav.is-hidden {
  transform: translateY(-110%);
}

.engine-brand {
  display: inline-flex;
  align-items: center;
  width: max-content;
  gap: 12px;
}

.engine-brand img {
  display: block;
  width: 32px;
  height: 38px;
  object-fit: contain;
}

.engine-brand span {
  display: grid;
  gap: 2px;
}

.engine-brand strong {
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.18em;
}

.engine-brand small {
  color: var(--mist);
  font-family: "JetBrains Mono", monospace;
  font-size: 0.58rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.engine-nav nav {
  display: flex;
  align-items: center;
  gap: clamp(20px, 2.5vw, 42px);
}

.engine-nav nav a {
  position: relative;
  padding: 10px 0;
  color: #c6d5dc;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.engine-nav nav a::after {
  position: absolute;
  right: 0;
  bottom: 4px;
  left: 0;
  height: 1px;
  content: "";
  background: var(--signal);
  transform: scaleX(0);
  transform-origin: right center;
  transition: transform 220ms var(--ease-out);
}

.engine-nav nav a:hover::after,
.engine-nav nav a:focus-visible::after {
  transform: scaleX(1);
  transform-origin: left center;
}

.nav-action {
  justify-self: end;
  padding: 11px 16px;
  border: 1px solid var(--line-strong);
  color: var(--quartz);
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  transition: border-color 180ms ease, background 180ms ease, transform 180ms ease;
}

.nav-action:hover {
  border-color: rgba(39, 185, 255, 0.72);
  background: rgba(39, 185, 255, 0.1);
  transform: translateY(-2px);
}

main {
  width: 100%;
  max-width: 100%;
  overflow-x: clip;
}

.signal-kicker {
  margin: 0 0 18px;
  color: var(--signal-hot);
  font-family: "JetBrains Mono", monospace;
  font-size: clamp(0.66rem, 0.72vw, 0.78rem);
  font-weight: 500;
  letter-spacing: 0.13em;
  line-height: 1.45;
  text-transform: uppercase;
}

.engine-hero {
  position: relative;
  min-height: max(100svh, 800px);
  isolation: isolate;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(circle at 66% 46%, rgba(32, 172, 241, 0.12), transparent 28%),
    linear-gradient(120deg, rgba(5, 8, 10, 0.98) 0 29%, rgba(5, 8, 10, 0.3) 48%, rgba(5, 8, 10, 0.72) 100%);
}

.engine-hero::after {
  position: absolute;
  z-index: 12;
  top: var(--nav-height);
  bottom: 0;
  left: clamp(20px, 3.4vw, 58px);
  width: 1px;
  content: "";
  background: linear-gradient(transparent, var(--line-strong) 14%, var(--line) 80%, transparent);
}

.engine-hero__copy {
  position: absolute;
  z-index: 20;
  top: clamp(132px, 16vh, 180px);
  left: clamp(38px, 6.2vw, 112px);
  width: min(43vw, 680px);
  pointer-events: none;
  transition: opacity 420ms var(--ease-out), transform 620ms var(--ease-out);
}

.engine-hero__copy > * {
  pointer-events: auto;
}

.engine-hero h1 {
  max-width: 14ch;
  margin: 0;
  font-size: clamp(3.25rem, 6.25vw, 7.25rem);
  font-weight: 500;
  letter-spacing: -0.07em;
  line-height: 0.9;
  text-wrap: balance;
}

.engine-hero__lede {
  max-width: 520px;
  margin: 28px 0 0;
  color: #a8bbc4;
  font-size: clamp(1rem, 1.15vw, 1.25rem);
  line-height: 1.62;
}

.engine-hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  margin-top: 34px;
}

.primary-action,
.quiet-action {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid transparent;
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.primary-action {
  overflow: hidden;
  color: #021018;
  background: var(--signal-hot);
  box-shadow: 0 0 42px rgba(39, 185, 255, 0.14);
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.primary-action::after {
  position: absolute;
  top: -120%;
  bottom: -120%;
  left: -60%;
  width: 26%;
  content: "";
  background: rgba(255, 255, 255, 0.72);
  transform: translate3d(0, 0, 0) rotate(18deg);
  transition: transform 620ms var(--ease-out);
}

.primary-action:hover {
  box-shadow: 0 0 52px rgba(39, 185, 255, 0.32);
  transform: translateY(-3px);
}

.primary-action:hover::after {
  transform: translate3d(770%, 0, 0) rotate(18deg);
}

.quiet-action {
  color: var(--quartz);
  border-color: var(--line-strong);
  background: rgba(5, 8, 10, 0.45);
  transition: border-color 180ms ease, background 180ms ease;
}

.quiet-action:hover {
  border-color: var(--signal);
  background: rgba(39, 185, 255, 0.08);
}

.engine-stage {
  position: absolute;
  z-index: 2;
  inset: 0;
  overflow: hidden;
}

.engine-stage::after {
  position: absolute;
  z-index: 8;
  inset: 0;
  content: "";
  pointer-events: none;
  background: linear-gradient(
    90deg,
    rgba(5, 8, 10, 0.98) 0%,
    rgba(5, 8, 10, 0.88) 21%,
    rgba(5, 8, 10, 0.46) 35%,
    rgba(5, 8, 10, 0.08) 48%,
    transparent 61%
  );
  transition: opacity 520ms var(--ease-out);
}

.engine-hero.is-inspecting .engine-stage::after {
  opacity: 0.16;
}

.engine-hero.is-inspecting .engine-hero__copy {
  opacity: 0;
  pointer-events: none;
  transform: translate3d(-44px, 0, 0);
}

.engine-hero.is-inspecting .engine-hero__copy > * {
  pointer-events: none;
}

.engine-stage__field {
  position: absolute;
  inset: 0;
  opacity: 0.34;
  background-image:
    linear-gradient(rgba(124, 180, 204, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 180, 204, 0.08) 1px, transparent 1px);
  background-size: 52px 52px;
  mask-image: radial-gradient(circle at 68% 50%, black 12%, transparent 68%);
}

.engine-stage__field::before,
.engine-stage__field::after {
  position: absolute;
  top: 50%;
  left: 68%;
  width: min(58vw, 820px);
  aspect-ratio: 1;
  border: 1px solid rgba(80, 194, 246, 0.12);
  border-radius: 50%;
  content: "";
  transform: translate(-50%, -50%);
}

.engine-stage__field::after {
  width: min(40vw, 570px);
  border-style: dashed;
}

.engine-canvas,
.engine-fallback {
  position: absolute;
  z-index: 2;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}

.engine-fallback {
  object-fit: contain;
  object-position: 72% 48%;
  padding: 9vh 2vw 10vh 34vw;
  filter: saturate(0.9) contrast(1.08);
}

.engine-scan {
  position: absolute;
  z-index: 6;
  top: 8%;
  bottom: 11%;
  left: 31%;
  width: 1px;
  pointer-events: none;
  opacity: 0;
  background: linear-gradient(transparent, rgba(102, 211, 255, 0.92), transparent);
  box-shadow: 0 0 18px rgba(39, 185, 255, 0.65);
}

.engine-stage.is-ready .engine-scan {
  opacity: 0.65;
  animation: scan-engine 7s ease-in-out infinite;
}

@keyframes scan-engine {
  0%, 16% { transform: translateX(0); opacity: 0; }
  26% { opacity: 0.66; }
  74% { opacity: 0.4; }
  86%, 100% { transform: translateX(60vw); opacity: 0; }
}

.engine-loader {
  position: absolute;
  z-index: 40;
  top: 50%;
  left: 68%;
  display: grid;
  justify-items: center;
  width: min(300px, 72vw);
  padding: 28px;
  border: 1px solid var(--line);
  background: rgba(5, 8, 10, 0.88);
  backdrop-filter: blur(20px);
  transform: translate(-50%, -50%);
  transition: opacity 500ms ease, visibility 500ms ease;
}

.engine-loader.is-complete {
  opacity: 0;
  visibility: hidden;
}

.engine-loader__mark {
  position: relative;
  width: 52px;
  height: 46px;
  margin-bottom: 18px;
}

.engine-loader__mark span {
  position: absolute;
  width: 34px;
  height: 3px;
  background: var(--signal);
  box-shadow: 0 0 14px rgba(39, 185, 255, 0.6);
  transform-origin: left center;
}

.engine-loader__mark span:nth-child(1) { top: 8px; left: 8px; transform: rotate(30deg); }
.engine-loader__mark span:nth-child(2) { top: 8px; right: 8px; transform: rotate(150deg); transform-origin: right center; }
.engine-loader__mark span:nth-child(3) { top: 23px; left: 25px; transform: rotate(90deg); }

.engine-loader p {
  margin: 0 0 16px;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.engine-loader small {
  margin-top: 8px;
  color: var(--mist);
  font-family: "JetBrains Mono", monospace;
  font-size: 0.66rem;
}

.engine-loader__track {
  width: 100%;
  height: 2px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.1);
}

.engine-loader__track span {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--signal);
  box-shadow: 0 0 12px rgba(39, 185, 255, 0.8);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 180ms var(--ease-out);
}

.hotspot-layer {
  position: absolute;
  z-index: 14;
  inset: 0;
  pointer-events: none;
}

.engine-hotspot {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0;
  border: 0;
  color: var(--quartz);
  background: transparent;
  cursor: pointer;
  pointer-events: auto;
  transform: translate(-50%, -50%);
}

.engine-hotspot__node {
  position: relative;
  display: block;
  width: 13px;
  height: 13px;
  flex: 0 0 auto;
  border: 1px solid rgba(202, 236, 250, 0.84);
  border-radius: 50%;
  background: rgba(4, 22, 30, 0.88);
  box-shadow: 0 0 0 6px rgba(39, 185, 255, 0.08), 0 0 22px rgba(39, 185, 255, 0.25);
  transition: background 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.engine-hotspot__node::after {
  position: absolute;
  inset: 3px;
  border-radius: inherit;
  content: "";
  background: var(--signal);
}

.engine-hotspot__label {
  padding: 7px 9px;
  border: 1px solid rgba(148, 202, 226, 0.2);
  color: #dbe9ef;
  background: rgba(5, 8, 10, 0.72);
  font-family: "JetBrains Mono", monospace;
  font-size: clamp(0.52rem, 0.58vw, 0.64rem);
  letter-spacing: 0.08em;
  line-height: 1;
  text-transform: uppercase;
  backdrop-filter: blur(10px);
  transition: border-color 160ms ease, color 160ms ease, background 160ms ease;
  white-space: nowrap;
}

.engine-hotspot:hover .engine-hotspot__node,
.engine-hotspot.is-active .engine-hotspot__node,
.engine-hotspot:focus-visible .engine-hotspot__node {
  background: var(--signal);
  box-shadow: 0 0 0 9px rgba(39, 185, 255, 0.12), 0 0 28px rgba(39, 185, 255, 0.72);
  transform: scale(1.22);
}

.engine-hotspot:hover .engine-hotspot__label,
.engine-hotspot.is-active .engine-hotspot__label,
.engine-hotspot:focus-visible .engine-hotspot__label {
  border-color: rgba(39, 185, 255, 0.7);
  color: var(--quartz);
  background: rgba(4, 22, 30, 0.9);
}

.engine-stage.is-inspecting .engine-hotspot:not(.is-active) {
  opacity: 0.22 !important;
}

.engine-stage.is-inspecting .engine-hotspot:not(.is-active) .engine-hotspot__label {
  opacity: 0;
  transform: translate3d(0, 5px, 0);
}

.engine-stage.is-locked .engine-hotspot.is-active .engine-hotspot__label::after {
  margin-left: 7px;
  color: var(--signal-hot);
  content: "LOCKED";
  font-size: 0.48rem;
}

.engine-readout {
  position: absolute;
  z-index: 24;
  top: clamp(98px, 11vh, 124px);
  right: clamp(24px, 3.6vw, 66px);
  bottom: 76px;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  width: min(430px, 32vw);
  max-height: 790px;
  overflow: hidden;
  border: 1px solid rgba(151, 208, 233, 0.23);
  border-top-color: rgba(39, 185, 255, 0.75);
  background: linear-gradient(160deg, rgba(10, 20, 25, 0.88), rgba(5, 8, 10, 0.7));
  box-shadow: 0 24px 90px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(20px) saturate(130%);
  transform-origin: right top;
  transition: opacity 240ms ease, transform 240ms var(--ease-out), visibility 240ms ease;
}

.engine-readout.is-collapsed {
  opacity: 0;
  visibility: hidden;
  transform: translateX(22px) scale(0.98);
}

.engine-readout__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--line);
  background: rgba(5, 8, 10, 0.48);
}

.engine-readout__head span {
  color: var(--signal-hot);
  font-family: "JetBrains Mono", monospace;
  font-size: 0.63rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.engine-readout__head button {
  padding: 7px 9px;
  border: 0;
  color: #80949d;
  background: none;
  cursor: pointer;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.58rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: color 160ms ease, background 160ms ease;
}

.engine-readout__head button:hover,
.engine-readout__head button:focus-visible {
  color: var(--quartz);
  background: rgba(39, 185, 255, 0.08);
}

.engine-readout__scroll {
  min-height: 0;
  padding: 20px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-color: rgba(63, 175, 226, 0.48) transparent;
  scrollbar-width: thin;
}

.engine-readout__position {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 10px;
  align-items: center;
  color: #708690;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.55rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.engine-readout__position i {
  height: 1px;
  background: linear-gradient(90deg, var(--signal), transparent);
}

.engine-readout__position strong {
  color: var(--signal-hot);
  font-weight: 500;
}

.engine-readout h2 {
  margin: 22px 0 12px;
  font-size: clamp(1.75rem, 2.35vw, 2.7rem);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: 1;
  text-wrap: balance;
}

.engine-readout__scroll > p {
  margin: 0;
  color: #a8bac3;
  font-size: 0.88rem;
  line-height: 1.6;
}

.engine-readout__section {
  margin-top: 24px;
  padding-top: 17px;
  border-top: 1px solid var(--line);
}

.engine-readout__section > span,
.engine-readout__connections > span,
.engine-readout__evidence > span,
.engine-readout__details article > span {
  color: #6f8691;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.53rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.engine-readout__path {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}

.engine-readout__path li {
  position: relative;
  min-width: 0;
  padding: 0 9px 0 10px;
  border-left: 1px solid rgba(39, 185, 255, 0.28);
}

.engine-readout__path li::after {
  position: absolute;
  top: 4px;
  right: -2px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  content: "";
  background: var(--signal);
  box-shadow: 0 0 10px var(--signal);
}

.engine-readout__path li:last-child::after { display: none; }

.engine-readout__path b {
  display: block;
  margin-bottom: 6px;
  color: var(--signal-hot);
  font-family: "JetBrains Mono", monospace;
  font-size: 0.5rem;
  font-weight: 500;
}

.engine-readout__path span {
  display: block;
  color: #bdcdd4;
  font-size: 0.65rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.engine-readout__section ul {
  display: grid;
  gap: 9px;
  margin: 13px 0 0;
  padding: 0;
  list-style: none;
}

.engine-readout__section ul li {
  position: relative;
  padding-left: 17px;
  color: #d2e1e7;
  font-size: 0.75rem;
}

.engine-readout__section ul li::before {
  position: absolute;
  top: 0.55em;
  left: 0;
  width: 6px;
  height: 1px;
  content: "";
  background: var(--signal);
  box-shadow: 0 0 8px var(--signal);
}

.engine-readout__details {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  margin-top: 24px;
  background: var(--line);
  border: 1px solid var(--line);
}

.engine-readout__details article {
  min-width: 0;
  padding: 13px;
  background: rgba(5, 12, 16, 0.76);
}

.engine-readout__details article p {
  margin: 7px 0 0;
  color: #bdcbd1;
  font-size: 0.68rem;
  line-height: 1.46;
  overflow-wrap: anywhere;
}

.engine-readout__connections,
.engine-readout__evidence {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.engine-readout__connections > div {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.engine-readout__connections b {
  padding: 6px 8px;
  color: #cfe5ed;
  background: rgba(39, 185, 255, 0.07);
  font-size: 0.61rem;
  font-weight: 500;
}

.engine-readout__evidence p {
  margin: 9px 0 0;
  color: #91a7b1;
  font-size: 0.68rem;
  line-height: 1.5;
}

.engine-instruction {
  position: absolute;
  z-index: 22;
  right: clamp(24px, 3.6vw, 66px);
  bottom: 30px;
  left: max(480px, 42vw);
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.engine-instruction__pulse {
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--signal);
  box-shadow: 0 0 16px var(--signal);
  animation: instruction-pulse 2s ease-in-out infinite;
}

@keyframes instruction-pulse {
  50% { opacity: 0.38; transform: scale(0.7); }
}

.engine-instruction p,
.engine-instruction > span:last-child {
  margin: 0;
  font-size: 0.66rem;
  letter-spacing: 0.05em;
}

.engine-instruction p { color: #8ca0aa; }
.engine-instruction p strong { color: #cfdee4; font-weight: 700; }
.engine-instruction > span:last-child { margin-left: auto; color: #61747d; font-family: "JetBrains Mono", monospace; text-transform: uppercase; }

.engine-control {
  position: absolute;
  z-index: 28;
  bottom: 30px;
  left: clamp(38px, 6.2vw, 112px);
  width: min(370px, 34vw);
}

.engine-control > p {
  margin: 0 0 10px;
  color: #768a93;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.57rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.engine-control__rail {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid var(--line-strong);
  border-left: 1px solid var(--line);
}

.engine-control__rail button {
  display: grid;
  grid-template-columns: 24px 1fr;
  gap: 8px;
  align-items: center;
  min-height: 42px;
  padding: 8px 10px;
  border: 0;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  color: #93a7b0;
  background: rgba(5, 8, 10, 0.58);
  cursor: pointer;
  text-align: left;
  transition: color 160ms ease, background 160ms ease;
}

.engine-control__rail button span:first-child {
  color: #536771;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.55rem;
}

.engine-control__rail button span:last-child {
  font-size: 0.68rem;
  font-weight: 700;
}

.engine-control__rail button:hover,
.engine-control__rail button.is-active,
.engine-control__rail button:focus-visible {
  color: #fff;
  background: rgba(39, 185, 255, 0.11);
}

.engine-control__rail button.is-active span:first-child {
  color: var(--signal-hot);
}

.signal-marquee {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: #071015;
}

.signal-marquee::before,
.signal-marquee::after {
  position: absolute;
  z-index: 2;
  top: 0;
  bottom: 0;
  width: 14vw;
  content: "";
  pointer-events: none;
}

.signal-marquee::before { left: 0; background: linear-gradient(90deg, #071015, transparent); }
.signal-marquee::after { right: 0; background: linear-gradient(-90deg, #071015, transparent); }

.signal-marquee__track {
  display: flex;
  width: max-content;
  animation: signal-marquee 42s linear infinite;
}

.signal-marquee:hover .signal-marquee__track,
.signal-marquee:focus-visible .signal-marquee__track {
  animation-play-state: paused;
}

.signal-marquee__track > div {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 72px;
  padding-right: 24px;
}

.signal-marquee span {
  color: #a3b5bd;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.66rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.signal-marquee i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--signal);
  box-shadow: 0 0 12px rgba(39, 185, 255, 0.65);
}

@keyframes signal-marquee {
  to { transform: translateX(-50%); }
}

.operating-flow {
  position: relative;
  padding: clamp(130px, 18vw, 260px) clamp(22px, 5vw, 84px) clamp(170px, 20vw, 310px);
  background:
    linear-gradient(90deg, transparent calc(50% - 0.5px), rgba(126, 181, 204, 0.12) 50%, transparent calc(50% + 0.5px)),
    #071015;
}

.operating-flow__intro {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.4fr);
  gap: clamp(40px, 8vw, 150px);
  align-items: end;
  max-width: 1460px;
  margin: 0 auto clamp(100px, 12vw, 190px);
}

.operating-flow__intro .signal-kicker {
  grid-column: 1;
  align-self: start;
}

.operating-flow__intro h2 {
  grid-column: 2;
  margin: 0;
  font-size: clamp(3rem, 6.4vw, 7.2rem);
  font-weight: 500;
  letter-spacing: -0.068em;
  line-height: 0.94;
}

.scrub-copy {
  grid-column: 2;
  max-width: 850px;
  margin: 34px 0 0;
  color: #9db0ba;
  font-size: clamp(1.15rem, 1.8vw, 1.8rem);
  line-height: 1.55;
}

.scrub-copy span {
  opacity: 0.16;
  transition: opacity 120ms linear;
}

.flow-stack {
  display: grid;
  max-width: 1320px;
  margin: 0 auto;
}

.flow-card {
  position: sticky;
  top: 11vh;
  display: grid;
  grid-template-columns: minmax(240px, 0.75fr) minmax(360px, 1.15fr) minmax(260px, 0.7fr);
  gap: clamp(34px, 5vw, 90px);
  align-items: center;
  min-height: 72vh;
  margin-bottom: 13vh;
  padding: clamp(34px, 5vw, 78px);
  overflow: hidden;
  border: 1px solid rgba(154, 203, 224, 0.22);
  background: #0b151a;
  box-shadow: 0 48px 130px rgba(0, 0, 0, 0.42);
  transform-origin: center top;
}

.flow-card:nth-child(2) { top: 14vh; background: #0e1a20; }
.flow-card:nth-child(3) { top: 17vh; margin-bottom: 0; background: #e6ecee; color: #071015; }

.flow-card::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 2px;
  content: "";
  background: linear-gradient(90deg, transparent, var(--signal), transparent);
  opacity: 0.7;
}

.flow-card > div:nth-child(2) > p:first-child {
  margin: 0 0 16px;
  color: var(--signal-hot);
  font-family: "JetBrains Mono", monospace;
  font-size: 0.64rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.flow-card--control > div:nth-child(2) > p:first-child { color: #0f75a4; }

.flow-card h3 {
  max-width: 13ch;
  margin: 0;
  font-size: clamp(2.6rem, 4.6vw, 5.7rem);
  font-weight: 500;
  letter-spacing: -0.065em;
  line-height: 0.96;
}

.flow-card > div:nth-child(2) > p:last-child {
  max-width: 650px;
  margin: 26px 0 0;
  color: #9eb0b8;
  font-size: clamp(0.96rem, 1.16vw, 1.18rem);
  line-height: 1.65;
}

.flow-card--control > div:nth-child(2) > p:last-child { color: #4f6068; }

.flow-card ol {
  align-self: stretch;
  display: grid;
  align-content: center;
  gap: 0;
  margin: 0;
  padding: 0;
  border-top: 1px solid rgba(159, 207, 228, 0.2);
  list-style: none;
}

.flow-card li {
  display: grid;
  gap: 7px;
  padding: 18px 0;
  border-bottom: 1px solid rgba(159, 207, 228, 0.2);
}

.flow-card li span {
  color: #6e858f;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.55rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.flow-card li strong {
  font-size: 0.85rem;
  font-weight: 700;
}

.flow-card__signal,
.flow-card__rings {
  position: relative;
  width: min(20vw, 270px);
  aspect-ratio: 1;
  justify-self: center;
}

.flow-card__signal span {
  position: absolute;
  top: 50%;
  left: 50%;
  border: 1px solid rgba(70, 197, 255, 0.34);
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.flow-card__signal span:nth-child(1) { width: 28%; height: 28%; background: rgba(39, 185, 255, 0.18); box-shadow: 0 0 42px rgba(39, 185, 255, 0.2); }
.flow-card__signal span:nth-child(2) { width: 62%; height: 62%; animation: signal-ring 3.2s ease-in-out infinite; }
.flow-card__signal span:nth-child(3) { width: 100%; height: 100%; animation: signal-ring 3.2s 800ms ease-in-out infinite; }

@keyframes signal-ring {
  50% { opacity: 0.28; transform: translate(-50%, -50%) scale(0.88); }
}

.flow-card__wave {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 180px;
}

.flow-card__wave i {
  width: 5px;
  height: 22%;
  background: var(--signal);
  box-shadow: 0 0 18px rgba(39, 185, 255, 0.45);
  animation: wave-bar 1.8s ease-in-out infinite alternate;
}

.flow-card__wave i:nth-child(2), .flow-card__wave i:nth-child(7) { animation-delay: -0.6s; height: 44%; }
.flow-card__wave i:nth-child(3), .flow-card__wave i:nth-child(6) { animation-delay: -1.1s; height: 76%; }
.flow-card__wave i:nth-child(4), .flow-card__wave i:nth-child(5) { animation-delay: -1.5s; height: 100%; }

@keyframes wave-bar {
  to { transform: scaleY(0.28); opacity: 0.32; }
}

.flow-card__rings span {
  position: absolute;
  inset: 12%;
  border: 2px solid rgba(7, 16, 21, 0.24);
  border-radius: 50%;
}

.flow-card__rings span:nth-child(2) { inset: 28%; border-color: rgba(15, 117, 164, 0.5); }
.flow-card__rings span:nth-child(3) { inset: 43%; background: #0f75a4; border: 0; box-shadow: 0 0 38px rgba(15, 117, 164, 0.32); }

.operator-lenses {
  padding: clamp(130px, 16vw, 240px) clamp(22px, 5vw, 84px);
  color: #071015;
  background: #e6ecee;
}

.operator-lenses__heading,
.operator-lenses__console {
  max-width: 1460px;
  margin-right: auto;
  margin-left: auto;
}

.operator-lenses .signal-kicker { color: #0d6f9d; }

.operator-lenses__heading {
  display: grid;
  grid-template-columns: 0.7fr 1.4fr;
  gap: clamp(40px, 8vw, 150px);
  align-items: start;
}

.operator-lenses h2 {
  max-width: 14ch;
  margin: 0;
  font-size: clamp(3rem, 6vw, 7rem);
  font-weight: 500;
  letter-spacing: -0.07em;
  line-height: 0.94;
}

.operator-lenses__console {
  display: grid;
  grid-template-columns: minmax(260px, 0.72fr) minmax(0, 1.5fr);
  gap: clamp(28px, 5vw, 84px);
  margin-top: clamp(80px, 10vw, 150px);
  border-top: 1px solid rgba(7, 16, 21, 0.18);
}

.lens-tabs {
  display: flex;
  flex-direction: column;
  border-left: 1px solid rgba(7, 16, 21, 0.18);
}

.lens-tabs button {
  position: relative;
  display: grid;
  align-items: center;
  min-height: 76px;
  padding: 0 22px;
  overflow: hidden;
  border: 0;
  border-right: 1px solid rgba(7, 16, 21, 0.18);
  border-bottom: 1px solid rgba(7, 16, 21, 0.18);
  color: #67777f;
  background: transparent;
  cursor: pointer;
  text-align: left;
  font-size: clamp(0.95rem, 1.1vw, 1.14rem);
  font-weight: 700;
  transition: min-height 420ms var(--ease-out), color 180ms ease, background 180ms ease;
}

.lens-tabs button::before {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 3px;
  content: "";
  background: var(--signal);
  transform: scaleY(0);
  transition: transform 240ms var(--ease-out);
}

.lens-tabs button[aria-selected="true"] {
  min-height: 126px;
  color: #071015;
  background: rgba(255, 255, 255, 0.5);
}

.lens-tabs button[aria-selected="true"]::before { transform: scaleY(1); }

.lens-panel {
  display: grid;
  align-content: center;
  min-height: 510px;
  padding: clamp(34px, 6vw, 90px) 0;
}

.lens-panel > p:first-child {
  max-width: 38ch;
  margin: 0 0 28px;
  color: #0d6f9d;
  font-family: "JetBrains Mono", monospace;
  font-size: clamp(0.72rem, 0.8vw, 0.86rem);
  letter-spacing: 0.04em;
}

.lens-panel h3 {
  max-width: 15ch;
  margin: 0;
  font-size: clamp(2.6rem, 5vw, 6rem);
  font-weight: 500;
  letter-spacing: -0.066em;
  line-height: 0.95;
}

.lens-panel > p:nth-of-type(2) {
  max-width: 760px;
  margin: 30px 0 0;
  color: #52636b;
  font-size: clamp(1rem, 1.3vw, 1.25rem);
  line-height: 1.65;
}

.lens-panel__route {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 16px;
  align-items: center;
  max-width: 720px;
  margin-top: 42px;
  padding-top: 18px;
  border-top: 1px solid rgba(7, 16, 21, 0.18);
  font-family: "JetBrains Mono", monospace;
  font-size: 0.62rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.lens-panel__route span { color: #64767e; }
.lens-panel__route i { height: 1px; background: linear-gradient(90deg, #0d6f9d, transparent); }
.lens-panel__route strong { color: #071015; font-weight: 500; }

.engine-close {
  position: relative;
  display: grid;
  justify-items: center;
  min-height: 88vh;
  padding: clamp(150px, 18vw, 270px) 24px;
  overflow: hidden;
  text-align: center;
  background:
    radial-gradient(circle at 50% 42%, rgba(39, 185, 255, 0.12), transparent 23rem),
    var(--forge-black);
}

.engine-close__core {
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(74vw, 880px);
  aspect-ratio: 1;
  opacity: 0.55;
  transform: translate(-50%, -50%);
}

.engine-close__core span {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(39, 185, 255, 0.12);
  border-radius: 50%;
}

.engine-close__core span:nth-child(2) { inset: 17%; border-style: dashed; animation: close-spin 28s linear infinite; }
.engine-close__core span:nth-child(3) { inset: 35%; border-color: rgba(39, 185, 255, 0.34); box-shadow: inset 0 0 50px rgba(39, 185, 255, 0.07); animation: close-spin 18s linear infinite reverse; }

@keyframes close-spin { to { transform: rotate(360deg); } }

.engine-close > *:not(.engine-close__core) { position: relative; z-index: 2; }

.engine-close h2 {
  max-width: 13ch;
  margin: 0;
  font-size: clamp(3.4rem, 7vw, 8rem);
  font-weight: 500;
  letter-spacing: -0.075em;
  line-height: 0.9;
  text-wrap: balance;
}

.engine-close > p:not(.signal-kicker) {
  max-width: 760px;
  margin: 34px 0 0;
  color: #95a9b2;
  font-size: clamp(1rem, 1.35vw, 1.3rem);
  line-height: 1.65;
}

.engine-close .primary-action { margin-top: 42px; }

.primary-action--light {
  color: #031117;
  background: var(--quartz);
}

.engine-footer {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  padding: 36px clamp(20px, 4vw, 72px);
  border-top: 1px solid var(--line);
  background: #030506;
}

.engine-footer > p {
  margin: 0;
  color: #657982;
  font-size: 0.7rem;
}

.engine-footer > div {
  display: flex;
  justify-content: flex-end;
  gap: 24px;
}

.engine-footer > div a {
  color: #92a4ac;
  font-size: 0.7rem;
}

.noscript-note {
  position: fixed;
  z-index: 300;
  right: 20px;
  bottom: 20px;
  left: 20px;
  margin: 0;
  padding: 18px;
  color: #071015;
  background: var(--quartz);
  text-align: center;
}

@media (max-width: 1180px) {
  .engine-nav {
    grid-template-columns: 1fr auto;
  }

  .engine-nav nav { display: none; }

  .engine-hero__copy {
    width: min(48vw, 590px);
  }

  .engine-readout {
    width: min(390px, 35vw);
  }

  .engine-control {
    width: min(340px, 38vw);
  }

  .engine-instruction {
    left: 44vw;
  }

  .flow-card {
    grid-template-columns: 0.55fr 1.1fr;
  }

  .flow-card ol {
    grid-column: 1 / -1;
    grid-template-columns: repeat(3, 1fr);
  }

  .flow-card li {
    padding-right: 18px;
    border-right: 1px solid rgba(159, 207, 228, 0.2);
  }
}

@media (max-width: 860px) {
  :root { --nav-height: 68px; }

  .engine-nav {
    padding: 10px 18px;
  }

  .engine-brand small,
  .nav-action { display: none; }

  .engine-hero {
    display: flex;
    flex-direction: column;
    min-height: 0;
    padding-top: var(--nav-height);
  }

  .engine-hero::after { display: none; }

  .engine-hero__copy {
    position: relative;
    top: auto;
    left: auto;
    order: 1;
    width: auto;
    padding: 74px 22px 34px;
  }

  .engine-hero h1 {
    max-width: 13ch;
    font-size: clamp(3rem, 12vw, 5.4rem);
  }

  .engine-stage {
    position: relative;
    order: 2;
    height: 74svh;
    min-height: 590px;
    border-top: 1px solid var(--line);
  }

  .engine-stage::after { display: none; }

  .engine-stage__field::before,
  .engine-stage__field::after,
  .engine-loader {
    left: 50%;
  }

  .engine-fallback {
    object-position: center 42%;
    padding: 11vh 2vw 20vh;
  }

  .engine-readout {
    top: auto;
    right: 16px;
    bottom: 76px;
    left: 16px;
    width: auto;
    max-height: 48%;
  }

  .engine-readout__head { padding: 12px 14px; }
  .engine-readout__scroll { padding: 14px; }
  .engine-readout h2 { margin-top: 15px; font-size: clamp(1.6rem, 7vw, 2.2rem); }
  .engine-readout__scroll > p { font-size: 0.78rem; }
  .engine-readout__path span { font-size: 0.58rem; }
  .engine-readout__section { margin-top: 18px; padding-top: 13px; }
  .engine-readout__details { margin-top: 18px; }

  .engine-instruction {
    right: 16px;
    bottom: 18px;
    left: 16px;
  }

  .engine-instruction p { display: none; }

  .engine-control {
    position: relative;
    z-index: 30;
    order: 3;
    bottom: auto;
    left: auto;
    width: auto;
    padding: 20px 16px 28px;
    background: #071015;
  }

  .engine-control__rail {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: thin;
  }

  .engine-control__rail button {
    min-width: 158px;
    scroll-snap-align: start;
  }

  .engine-hotspot__label { display: none; }

  .operating-flow,
  .operator-lenses {
    padding-right: 22px;
    padding-left: 22px;
  }

  .operating-flow__intro,
  .operator-lenses__heading,
  .operator-lenses__console {
    grid-template-columns: 1fr;
  }

  .operating-flow__intro .signal-kicker,
  .operating-flow__intro h2,
  .scrub-copy {
    grid-column: 1;
  }

  .flow-card {
    top: 9vh;
    grid-template-columns: 1fr;
    min-height: 78vh;
    padding: 28px;
  }

  .flow-card:nth-child(2) { top: 11vh; }
  .flow-card:nth-child(3) { top: 13vh; }

  .flow-card__signal,
  .flow-card__rings {
    width: 160px;
  }

  .flow-card__wave { height: 130px; }

  .flow-card ol {
    grid-column: auto;
    grid-template-columns: 1fr;
  }

  .flow-card li {
    border-right: 0;
  }

  .operator-lenses__console {
    gap: 0;
  }

  .lens-tabs {
    flex-direction: row;
    overflow-x: auto;
  }

  .lens-tabs button,
  .lens-tabs button[aria-selected="true"] {
    min-width: 145px;
    min-height: 64px;
  }

  .lens-panel { min-height: 460px; }

  .engine-footer {
    grid-template-columns: 1fr;
  }

  .engine-footer > p { display: none; }
  .engine-footer > div { justify-content: flex-start; flex-wrap: wrap; }
}

@media (max-width: 520px) {
  .engine-hero__actions {
    align-items: stretch;
    flex-direction: column;
  }

  .primary-action,
  .quiet-action {
    width: 100%;
  }

  .engine-stage {
    height: 68svh;
    min-height: 520px;
  }

  .engine-readout__path,
  .engine-readout__details {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .engine-readout__path {
    row-gap: 12px;
  }

  .engine-instruction > span:last-child {
    margin-left: 0;
  }

  .operator-lenses h2,
  .operating-flow__intro h2 {
    font-size: clamp(3rem, 14vw, 4.5rem);
  }

  .flow-card h3,
  .lens-panel h3 {
    font-size: clamp(2.7rem, 12vw, 4rem);
  }

  .engine-close h2 {
    font-size: clamp(3.4rem, 16vw, 5.4rem);
  }
}

/* Embedded product-page mode. The standalone engine keeps its full narrative. */
html.engine-embedded,
html.engine-embedded body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: transparent;
}

.engine-embedded body::before,
.engine-embedded .skip-link,
.engine-embedded .engine-nav,
.engine-embedded main > :not(.engine-hero),
.engine-embedded .engine-hero__copy,
.engine-embedded .engine-hero::after,
.engine-embedded .engine-stage::after,
.engine-embedded .engine-footer,
.engine-embedded .noscript-note {
  display: none !important;
}

.engine-embedded main,
.engine-embedded .engine-hero {
  width: 100%;
  height: 100%;
  min-height: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  background: transparent;
}

.engine-embedded .engine-stage {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  min-height: 0;
  border: 0;
}

.engine-embedded .engine-instruction {
  right: auto;
  bottom: 22px;
  left: 22px;
  width: min(21rem, calc(100% - 25rem));
}

@media (min-width: 861px) {
  .engine-embedded .engine-hero {
    --engine-embed-gutter: clamp(14px, 1.8vw, 24px);
    --engine-embed-panel-gap: clamp(12px, 1.4vw, 20px);
    --engine-embed-panel-top: clamp(76px, 9vh, 96px);
    --engine-embed-rail-width: clamp(144px, 14.5vw, 178px);
  }

  .engine-embedded .engine-readout {
    top: var(--engine-embed-panel-top);
    right: calc(var(--engine-embed-gutter) + var(--engine-embed-rail-width) + var(--engine-embed-panel-gap));
    bottom: var(--engine-embed-gutter);
    width: clamp(320px, 37vw, 430px);
    max-height: none;
  }

  .engine-embedded .engine-control {
    position: absolute;
    top: var(--engine-embed-panel-top);
    right: var(--engine-embed-gutter);
    bottom: var(--engine-embed-gutter);
    left: auto;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    width: var(--engine-embed-rail-width);
    padding: 0;
    background: transparent;
  }

  .engine-embedded .engine-control__rail {
    grid-template-columns: minmax(0, 1fr);
    align-content: start;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-color: rgba(63, 175, 226, 0.48) transparent;
    scrollbar-width: thin;
  }
}

@media (max-width: 860px) {
  .engine-embedded .engine-hero { display: block; }
  .engine-embedded .engine-readout,
  .engine-embedded .engine-control,
  .engine-embedded .engine-instruction { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .scrub-copy span { opacity: 1; }
}

@media (forced-colors: active) {
  .engine-hotspot__node,
  .engine-loader__track span,
  .engine-instruction__pulse {
    forced-color-adjust: none;
  }
}
