/* =============================================================
   EIPME — shared site styles
   Built on the EIPME design system (colors_and_type.css).
   Light mode is default; dark mode via [data-theme="dark"].
   ============================================================= */

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

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

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--fg-1);
  font-family: var(--font-body);
  overflow-x: clip;
}
body { position: relative; }

img { max-width: 100%; display: block; }

.wrap { width: 100%; max-width: 1208px; margin: 0 auto; padding: 0 32px; }
@media (max-width: 640px) { .wrap { padding: 0 20px; } }

main { position: relative; z-index: 1; }

/* visually hidden */
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* =============================================================
   ANIMATED BACKGROUND
   A fixed canvas behind everything: drifting aurora blobs +
   a faint network-node layer + grain. Parallax & mood handled
   in eipme.js. Pointer-events none, z-index 0; content sits at 1.
   ============================================================= */
.site-bg {
  position: fixed;
  inset: -10vh -10vw;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  /* base canvas tint */
  background:
    radial-gradient(1200px 900px at 50% -10%, var(--bg-tint-top), transparent 70%),
    var(--bg);
}

/* drifting aurora blobs
   Drift is owned by CSS keyframes (transform). Parallax is applied by JS
   through the INDEPENDENT `translate` property, which composes with
   `transform` instead of fighting it. */
.aurora {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: calc(var(--aurora-opacity, 0.55) * var(--bg-scroll-aurora, 1));
  will-change: transform, translate;
  mix-blend-mode: var(--aurora-blend, normal);
  transition: opacity 0.4s linear;
}
.aurora.a1 {
  width: 52vw; height: 52vw; left: -6vw; top: -8vh;
  background: radial-gradient(circle at 40% 40%, var(--au-blue), transparent 66%);
  animation: drift1 30s ease-in-out infinite alternate;
}
.aurora.a2 {
  width: 46vw; height: 46vw; right: -8vw; top: 14vh;
  background: radial-gradient(circle at 50% 50%, var(--au-orange), transparent 64%);
  animation: drift2 36s ease-in-out infinite alternate;
}
.aurora.a3 {
  width: 60vw; height: 60vw; left: 18vw; top: 56vh;
  background: radial-gradient(circle at 50% 50%, var(--au-blue2), transparent 62%);
  animation: drift3 42s ease-in-out infinite alternate;
}
.aurora.a4 {
  width: 40vw; height: 40vw; right: 6vw; bottom: -6vh;
  background: radial-gradient(circle at 50% 50%, var(--au-red), transparent 60%);
  animation: drift2 48s ease-in-out infinite alternate-reverse;
  opacity: calc(var(--aurora-opacity, 0.55) * 0.5 * var(--bg-scroll-aurora, 1));
}

@keyframes drift1 {
  0%   { transform: translate3d(0,0,0) scale(1); }
  100% { transform: translate3d(11vw, 8vh, 0) scale(1.2); }
}
@keyframes drift2 {
  0%   { transform: translate3d(0,0,0) scale(1.06); }
  100% { transform: translate3d(-10vw, 10vh, 0) scale(0.9); }
}
@keyframes drift3 {
  0%   { transform: translate3d(0,0,0) scale(0.94); }
  100% { transform: translate3d(9vw, -9vh, 0) scale(1.22); }
}

/* faint network-node canvas */
#net-canvas {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  opacity: var(--net-opacity, 0.5);
  will-change: translate;
}

/* ---- Scroll-driven infrastructure layers (injected by JS) ---- */
/* technical grid that fades in past the hero */
.bg-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(to right, rgba(var(--net-color), 0.6) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(var(--net-color), 0.6) 1px, transparent 1px);
  background-size: 64px 64px;
  opacity: calc(0.06 * var(--bg-grid-op, 0));
  -webkit-mask-image: radial-gradient(120% 78% at 50% 42%, #000 22%, transparent 70%);
          mask-image: radial-gradient(120% 78% at 50% 42%, #000 22%, transparent 70%);
  transition: opacity 0.3s linear;
}

/* long curved network paths with flowing data points */
.bg-circuit {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  opacity: var(--bg-circuit-op, 0);
  transition: opacity 0.4s linear;
}
.bg-circuit path { fill: none; stroke: rgba(var(--net-color), 0.62); stroke-width: 1.1; }
.bg-circuit .flow {
  stroke: rgba(var(--net-color), 0.9);
  stroke-width: 2; stroke-linecap: round;
  stroke-dasharray: 2 170;
  animation: circuitFlow linear infinite;
}
@keyframes circuitFlow { to { stroke-dashoffset: -172; } }

/* depth veil: darkens the canvas toward the lower/security part of the page */
.bg-veil {
  position: absolute; inset: 0;
  background: linear-gradient(180deg,
    rgba(8,11,20,0) 0%,
    rgba(8,11,20,0) 40%,
    rgba(8,11,20,0.30) 68%,
    rgba(8,11,20,0.62) 86%,
    rgba(8,11,20,0.78) 100%);
  opacity: var(--bg-veil-op, 0);
  transition: opacity 0.35s linear;
}

/* film grain to stop banding */
.site-bg::after {
  content: "";
  position: absolute; inset: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.05 0'/></filter><rect width='200' height='200' filter='url(%23n)'/></svg>");
  opacity: var(--grain-opacity, 0.5);
  mix-blend-mode: overlay;
}

/* aurora palette — light theme */
:root {
  --bg-tint-top: rgba(31, 94, 255, 0.06);
  --au-blue:  rgba(42, 102, 255, 0.34);
  --au-blue2: rgba(90, 130, 255, 0.26);
  --au-orange:rgba(255, 122, 26, 0.18);
  --au-red:   rgba(255, 59, 71, 0.11);
  --aurora-opacity: 0.78;
  --net-opacity: 0.45;
  --net-color: 31, 94, 255;
  --grain-opacity: 0.35;
}
[data-theme="dark"] {
  --bg-tint-top: rgba(42, 102, 255, 0.20);
  --au-blue:  rgba(42, 102, 255, 0.55);
  --au-blue2: rgba(90, 130, 255, 0.34);
  --au-orange:rgba(255, 122, 26, 0.34);
  --au-red:   rgba(255, 59, 71, 0.18);
  --aurora-opacity: 0.8;
  --net-opacity: 0.6;
  --net-color: 120, 150, 255;
  --grain-opacity: 0.6;
}

/* reduce / disable motion */
@media (prefers-reduced-motion: reduce) {
  .aurora { animation: none !important; }
  .bg-circuit .flow { animation: none !important; }
  /* quiet the remaining decorative loops too (design-system: respect
     reduced motion — no purely-decorative infinite animation). */
  .lab-card .lab-label .live { animation: none !important; }
  .lab-viz .lab-flow { animation: none !important; }
}
@media (max-width: 760px) {
  /* lighter background on mobile for perf + legibility */
  .aurora { filter: blur(60px); animation-duration: 46s; }
  .aurora.a4 { display: none; }
  #net-canvas { display: none; }
  .bg-circuit { display: none; }
  .bg-grid { background-size: 48px 48px; }
  :root { --aurora-opacity: 0.5; }
}

/* =============================================================
   NAV — floating glass capsule
   ============================================================= */
.nav-shell {
  position: fixed;
  top: 18px; left: 0; right: 0;
  z-index: 100;
  display: flex; justify-content: center;
  padding: 0 16px;
  pointer-events: none;
}
.nav {
  pointer-events: auto;
  display: flex; align-items: center; gap: 8px;
  width: 100%; max-width: 1100px;
  padding: 10px 12px 10px 16px;
  border-radius: var(--r-pill);
  background: var(--glass-dark-fill-strong);
  border: 1px solid var(--glass-dark-stroke);
  backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-saturate));
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-saturate));
  box-shadow: var(--glass-dark-shadow);
  position: relative;
  transition: transform var(--dur-med) var(--ease-out), box-shadow var(--dur-med) var(--ease-out);
}
.nav.hide { transform: translateY(-130%); }
.nav::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px;
  background: linear-gradient(180deg, rgba(255,255,255,0.22) 0%, transparent 30%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude; pointer-events: none;
}
.nav-brand { display: flex; align-items: center; gap: 10px; margin-right: 8px; flex-shrink: 0; }
.nav-brand img { width: 28px; height: 28px; border-radius: 8px; }
.nav-brand .name {
  font-family: var(--font-display); font-weight: 800; font-style: italic;
  letter-spacing: 0.01em; color: #fff; font-size: 17px;
}
.nav-links { display: flex; align-items: center; gap: 2px; margin-left: 4px; }
.nav-links a {
  color: rgba(255,255,255,0.74); font-size: 14px; font-weight: 500;
  padding: 8px 13px; border-radius: var(--r-pill); text-decoration: none;
  transition: background var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
  white-space: nowrap;
}
.nav-links a:hover { color: #fff; background: rgba(255,255,255,0.08); text-decoration: none; }
.nav-links a.active { color: #fff; background: rgba(255,255,255,0.14); }
.nav-right { margin-left: auto; display: flex; align-items: center; gap: 8px; }

.theme-toggle, .nav-burger {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: var(--r-pill);
  background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.12);
  color: #fff; cursor: pointer; transition: background var(--dur-fast) var(--ease-out);
  flex-shrink: 0;
}
.theme-toggle:hover, .nav-burger:hover { background: rgba(255,255,255,0.16); }
.theme-toggle svg, .nav-burger svg { width: 20px; height: 20px; }
.theme-toggle .icon-sun { display: none; }
[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
.nav-burger { display: none; }

/* buttons
   NO inset hairline ring, NO transparent rim, NO diagonal gradient.
   - background-clip stays at the default border-box so the fill covers
     the full box (the 1px transparent border never reveals the page
     background → kills the stray orange/blue rim near auroras).
   - the gradient is strictly HORIZONTAL so every vertical column is a
     single color: the left edge is fully blue, the right edge fully
     orange, and the rounded pill tips can't catch a neighbouring hue. */
.btn {
  position: relative;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font-body); font-size: 14px; font-weight: 600;
  padding: 11px 18px; border-radius: var(--r-pill);
  border: 1px solid transparent;
  cursor: pointer; text-decoration: none;
  isolation: isolate;
  transition: transform var(--dur-fast) var(--ease-out), box-shadow var(--dur-med) var(--ease-out), filter var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out);
  white-space: nowrap;
}
.btn svg { width: 16px; height: 16px; flex-shrink: 0; }
.btn:hover { text-decoration: none; }
.btn:active { transform: scale(0.98); }
.btn:focus-visible { outline: none; box-shadow: 0 0 0 3px rgba(31,94,255,0.30); }

/* Consistent keyboard-focus ring across interactive elements that don't
   already carry one (links + icon buttons). :focus-visible only, so mouse
   and touch users see no change. Mirrors the design-system focus rule
   (alpha-blue ring) and follows each element's own border-radius. */
a:not(.btn):focus-visible,
.theme-toggle:focus-visible,
.nav-burger:focus-visible {
  outline: 2px solid rgba(31, 94, 255, 0.6);
  outline-offset: 3px;
}

.btn-primary {
  background: var(--blue-500); color: #fff;
  box-shadow: 0 8px 22px -8px rgba(31,94,255,0.55);
}
.btn-primary:hover { background: var(--blue-600); box-shadow: 0 12px 28px -8px rgba(31,94,255,0.6); }
.btn-primary:active { background: var(--blue-700); }

/* Gradient CTA — horizontal blue→orange, one clean surface, no edge ring. */
.btn-grad {
  background-color: var(--blue-500);
  background-image: linear-gradient(90deg, #2A66FF 0%, #3D78FF 28%, #FF8A2E 74%, #FF7A1A 100%);
  color: #fff;
  box-shadow: 0 8px 22px -8px rgba(31,94,255,0.45);
}
.btn-grad:hover { filter: brightness(1.05); box-shadow: 0 12px 30px -8px rgba(255,122,26,0.42); }

.btn-ghost {
  background: var(--glass-dark-fill); color: #fff; border-color: rgba(255,255,255,0.18);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
}
.btn-ghost:hover { background: rgba(255,255,255,0.14); border-color: rgba(255,255,255,0.28); }
.btn-outline {
  background: transparent; color: var(--fg-1); border-color: var(--line-strong);
}
.btn-outline:hover { background: var(--bg-sunken); border-color: var(--accent); color: var(--accent); }
.btn-lg { padding: 14px 24px; font-size: 15px; }

/* nav button sizing */
.nav .btn { padding: 10px 16px; }

/* mobile menu panel */
.mobile-menu {
  position: fixed; inset: 0; z-index: 99;
  background: rgba(8,9,12,0.55);
  backdrop-filter: blur(8px);
  display: none; opacity: 0;
  transition: opacity var(--dur-med) var(--ease-out);
}
.mobile-menu.open { display: block; opacity: 1; }
.mobile-menu-inner {
  position: absolute; top: 84px; left: 16px; right: 16px;
  padding: 12px;
  border-radius: var(--r-2xl);
  background: var(--glass-dark-fill-strong);
  border: 1px solid var(--glass-dark-stroke);
  backdrop-filter: blur(var(--glass-blur-strong)) saturate(var(--glass-saturate));
  box-shadow: var(--glass-dark-shadow);
}
.mobile-menu-inner a {
  display: block; color: #fff; font-size: 17px; font-weight: 500;
  padding: 14px 16px; border-radius: var(--r-lg); text-decoration: none;
}
.mobile-menu-inner a:hover, .mobile-menu-inner a.active { background: rgba(255,255,255,0.1); }
.mobile-menu-inner .btn { width: 100%; justify-content: center; margin-top: 8px; }

/* =============================================================
   HERO + section bands
   ============================================================= */
.hero {
  position: relative;
  color: #fff;
  padding: 184px 0 120px;
  border-radius: 0 0 var(--r-3xl) var(--r-3xl);
  overflow: hidden;
  background:
    radial-gradient(900px 600px at 16% 0%, rgba(42,102,255,0.55), transparent 60%),
    radial-gradient(700px 540px at 92% 36%, rgba(31,94,255,0.30), transparent 62%),
    radial-gradient(620px 520px at 78% 96%, rgba(255,122,26,0.16), transparent 62%),
    linear-gradient(165deg, #0A1226 0%, #070A14 52%, #0B0E16 100%);
}
.hero::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 160px;
  background: linear-gradient(180deg, transparent, var(--bg));
  pointer-events: none;
}
.hero .wrap { position: relative; z-index: 2; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--font-mono); font-size: 12px; font-weight: 500;
  text-transform: uppercase; letter-spacing: 0.16em; color: rgba(255,255,255,0.6);
  margin-bottom: 22px;
}
.eyebrow .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--blue-400); box-shadow: 0 0 12px var(--blue-400); }
section .eyebrow { color: var(--accent); }
/* halo of page-background colour around accent dots so background grid/
   circuit lines can never appear to touch or collide with them */
section .eyebrow .dot { background: var(--accent); box-shadow: 0 0 0 4px var(--bg); }
section .eyebrow .dot { background: var(--accent); }

.hero h1 {
  font-family: var(--font-display); font-weight: 500; color: #fff;
  font-size: var(--t-display-l); line-height: 1.0; letter-spacing: -0.03em;
  margin: 0 0 24px; max-width: 16ch; text-wrap: balance;
}
.hero .sub {
  font-size: clamp(17px, 2vw, 21px); line-height: 1.5; color: rgba(255,255,255,0.78);
  max-width: 56ch; margin: 0 0 32px;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 30px; }
.trust-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase;
  color: rgba(255,255,255,0.72);
  padding: 7px 13px; border-radius: var(--r-pill);
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.12);
}

/* hero layout with lab side-card */
.hero-grid { display: grid; grid-template-columns: 1.5fr 0.9fr; gap: 40px; align-items: end; }
@media (max-width: 920px) { .hero-grid { grid-template-columns: 1fr; gap: 28px; } }

/* lab teaser card (glass) */
.lab-card {
  position: relative;
  padding: 22px;
  border-radius: var(--r-2xl);
  background: var(--glass-blue-fill);
  border: 1px solid var(--glass-blue-stroke);
  backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-saturate));
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-saturate));
  box-shadow: var(--glass-blue-shadow);
  color: #fff;
  animation: floaty 7s ease-in-out infinite alternate;
}
@media (prefers-reduced-motion: reduce) { .lab-card { animation: none; } }
@keyframes floaty { from { transform: translateY(0); } to { transform: translateY(-10px); } }
.lab-card::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px;
  background: linear-gradient(180deg, rgba(255,255,255,0.4) 0%, transparent 30%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude; pointer-events: none;
}
.lab-card .lab-label {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--blue-200); display: flex; align-items: center; gap: 8px; margin-bottom: 12px;
}
.lab-card .lab-label .live { width: 7px; height: 7px; border-radius: 50%; background: var(--blue-300); box-shadow: 0 0 10px var(--blue-300); animation: pulse 2.2s ease-in-out infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.4; } }
.lab-card h3 { font-size: 19px; font-weight: 600; margin: 0 0 8px; color: #fff; }
.lab-card p { font-size: 14px; color: rgba(255,255,255,0.78); margin: 0 0 16px; line-height: 1.5; }
.lab-card .lab-viz { margin-bottom: 16px; padding: 14px 12px 10px; border-radius: var(--r-lg); background: rgba(8,12,28,0.4); border: 1px solid rgba(255,255,255,0.08); }
.lab-card .lab-viz svg { width: 100%; height: 74px; display: block; }
/* wires */
.lab-viz .lab-wire path { fill: none; stroke: rgba(138,168,255,0.45); stroke-width: 1.4; stroke-linecap: round; }
/* flowing current along the wires — a visible moving strip between devices */
.lab-viz .lab-flow {
  fill: none;
  stroke: #9fc0ff;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-dasharray: 5 17;
  filter: drop-shadow(0 0 3px rgba(120,160,255,0.8));
}
/* devices */
.lab-viz .lab-dev rect, .lab-viz .lab-dev path, .lab-viz .lab-dev circle { vector-effect: non-scaling-stroke; }
.lab-viz .lab-dev > rect { fill: rgba(90,130,255,0.14); stroke: rgba(138,168,255,0.7); stroke-width: 1.3; }
.lab-viz .lab-dev .fw { fill: rgba(31,94,255,0.30); stroke: var(--blue-300); }
.lab-viz .lab-dev .ln { stroke: rgba(200,215,255,0.8); stroke-width: 1.2; fill: none; stroke-linecap: round; }
.lab-viz .lab-dev .scr { fill: rgba(138,168,255,0.45); stroke: none; }
.lab-viz .lab-dev .dot { fill: var(--blue-300); }
.lab-viz .lab-dev .brick { stroke: rgba(180,205,255,0.7); stroke-width: 1; fill: none; }
.lab-viz .lab-dev .cloud { fill: rgba(255,122,26,0.18); stroke: var(--orange-300); stroke-width: 1.3; }
/* packets flowing along the chain (SVG SMIL animate on cx — reliable everywhere) */
.lab-viz .lab-pkt {
  fill: #eaf1ff;
  filter: drop-shadow(0 0 5px rgba(150,180,255,1));
}
.lab-viz .lab-cap { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: 8px; }
.lab-viz .lab-cap span { font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.06em; text-transform: uppercase; color: rgba(255,255,255,0.6); text-align: center; }

/* =============================================================
   SECTIONS
   ============================================================= */
section { position: relative; z-index: 1; padding: 96px 0; }
@media (max-width: 760px) { section { padding: 64px 0; } }
.section-head { max-width: 60ch; margin-bottom: 48px; }
.section-head h2 { font-family: var(--font-display); font-weight: 500; font-size: var(--t-display-m); line-height: 1.05; letter-spacing: -0.03em; color: var(--fg-1); margin: 12px 0 0; }
.section-head p { margin-top: 18px; font-size: var(--t-body-l); color: var(--fg-2); }

/* generic card */
.card {
  background: var(--bg-elev); border: 1px solid var(--line);
  border-radius: var(--r-xl); box-shadow: var(--shadow-2);
  padding: 28px;
}
.card-glass {
  background: var(--glass-bright-fill-strong);
  border: 1px solid var(--glass-bright-stroke);
  backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-saturate));
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-saturate));
  box-shadow: var(--glass-bright-shadow);
}
[data-theme="dark"] .card-glass { background: var(--glass-dark-fill-strong); border-color: var(--glass-dark-stroke); box-shadow: var(--glass-dark-shadow); }

/* teaser grid */
.cards-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
@media (max-width: 900px) { .cards-3 { grid-template-columns: 1fr; } }
.teaser { display: flex; flex-direction: column; gap: 14px; transition: transform var(--dur-med) var(--ease-out), box-shadow var(--dur-med) var(--ease-out); }
.teaser:hover { transform: translateY(-4px); box-shadow: var(--shadow-4); }
.teaser .ic { width: 46px; height: 46px; border-radius: var(--r-md); display: inline-flex; align-items: center; justify-content: center; background: var(--blue-50); color: var(--blue-600); border: 1px solid var(--line); }
[data-theme="dark"] .teaser .ic { background: rgba(31,94,255,0.16); color: var(--blue-300); }
.teaser .ic svg { width: 24px; height: 24px; }
.teaser h3 { font-size: 20px; font-weight: 600; }
.teaser p { font-size: 15px; color: var(--fg-2); }
.teaser .more { margin-top: auto; font-size: 14px; font-weight: 600; color: var(--accent); display: inline-flex; align-items: center; gap: 6px; }

/* problem / two-col */
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: start; }
@media (max-width: 860px) { .two-col { grid-template-columns: 1fr; gap: 32px; } }

/* Align a right-column body to the left column's HEADING (not its eyebrow).
   A hidden eyebrow mirror reserves the exact eyebrow height; the body then
   gets the same top margin as the heading, so their tops line up at any
   width. On stacked mobile the spacer collapses. */
.align-to-heading .heading-spacer { visibility: hidden; user-select: none; }
.align-to-heading .align-to-heading-body { margin-top: 12px; }
@media (max-width: 860px) {
  .align-to-heading .heading-spacer { display: none; }
  .align-to-heading .align-to-heading-body { margin-top: 0; }
}

/* check list */
.check-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 14px; }
.check-list li { display: flex; align-items: flex-start; gap: 12px; font-size: 15px; color: var(--fg-1); }
.check-list li svg { width: 18px; height: 18px; color: var(--accent); flex-shrink: 0; margin-top: 2px; }

/* tag pills */
.tags { display: flex; flex-wrap: wrap; gap: 10px; }
.tag {
  font-size: 14px; color: var(--fg-1); padding: 9px 16px; border-radius: var(--r-pill);
  background: var(--bg); border: 1px solid var(--line-strong);
}
[data-theme="dark"] .tag { background: var(--bg-sunken); }

/* price box */
.notebox {
  font-family: var(--font-mono); font-size: 13px; line-height: 1.55; color: var(--fg-2);
  background: var(--bg-sunken); border: 1px solid var(--line);
  border-radius: var(--r-lg); padding: 16px 18px;
}
.infobox {
  display: flex; gap: 12px; align-items: flex-start;
  background: var(--bg-sunken); border: 1px solid var(--line);
  border-radius: var(--r-lg); padding: 16px 18px; font-size: 14px; color: var(--fg-2);
}
.infobox svg { width: 18px; height: 18px; color: var(--fg-3); flex-shrink: 0; margin-top: 2px; }
.pricebox {
  background: var(--brand-gradient-soft); color: #fff;
  border-radius: var(--r-xl); padding: 28px; box-shadow: var(--shadow-glow);
}
.pricebox .label { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; opacity: 0.85; }
.pricebox .amount { font-family: var(--font-display); font-size: 44px; font-weight: 500; letter-spacing: -0.03em; margin: 6px 0; }
.pricebox p { color: rgba(255,255,255,0.85); font-size: 14px; }

/* priority legend */
.prio-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
@media (max-width: 760px) { .prio-grid { grid-template-columns: 1fr 1fr; } }
.prio { padding: 18px; border-radius: var(--r-lg); border: 1px solid var(--line); background: var(--bg-elev); }
.prio .dot { width: 10px; height: 10px; border-radius: 50%; margin-bottom: 12px; }
.prio h4 { font-size: 15px; font-weight: 600; }
.prio p { font-size: 13px; color: var(--fg-3); margin-top: 4px; }
.prio.k .dot { background: var(--red-500); } .prio.w .dot { background: var(--orange-500); }
.prio.s .dot { background: var(--blue-500); } .prio.o .dot { background: var(--ink-300); }

/* numbered service rows (leistungen) */
.svc-row { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: start; padding: 56px 0; border-top: 1px solid var(--line); }
.svc-row:first-of-type { border-top: none; }
@media (max-width: 860px) { .svc-row { grid-template-columns: 1fr; gap: 28px; padding: 40px 0; } }
.svc-row .kicker { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); margin-bottom: 16px; }
.svc-row h2 { font-family: var(--font-display); font-weight: 500; font-size: var(--t-display-m); line-height: 1.05; letter-spacing: -0.03em; margin: 0 0 16px; }
.svc-row .desc { font-size: 16px; color: var(--fg-2); margin-bottom: 22px; max-width: 44ch; }

/* CTA band */
.cta-band {
  position: relative; overflow: hidden;
  border-radius: var(--r-3xl); color: #fff;
  padding: 72px 64px;
  background:
    radial-gradient(700px 400px at 14% 10%, rgba(42,102,255,0.5), transparent 60%),
    radial-gradient(600px 420px at 96% 100%, rgba(255,59,71,0.18), transparent 60%),
    linear-gradient(150deg, #0B1430 0%, #070A12 60%, #1A0E10 100%);
  box-shadow: var(--shadow-4);
}
@media (max-width: 640px) { .cta-band { padding: 44px 28px; border-radius: var(--r-2xl); } }
.cta-band h2 { font-family: var(--font-display); font-weight: 500; font-size: var(--t-display-m); line-height: 1.05; letter-spacing: -0.03em; margin: 0 0 14px; color: #fff; }
.cta-band p { color: rgba(255,255,255,0.78); font-size: var(--t-body-l); max-width: 50ch; margin: 0 0 28px; }

/* =============================================================
   FOOTER
   ============================================================= */
.footer { position: relative; z-index: 1; border-top: 1px solid var(--line); padding: 64px 0 40px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 40px; }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; gap: 32px; } }
.footer-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.footer-brand img { width: 30px; height: 30px; border-radius: 8px; }
.footer-brand .name { font-family: var(--font-display); font-weight: 800; font-style: italic; font-size: 18px; color: var(--fg-1); }

/* Registered-trademark mark on the EIPME wordmark (nav, footer, intro). */
.rtm {
  font-style: normal; font-weight: 600; letter-spacing: 0;
  font-size: 0.42em; vertical-align: super; line-height: 0;
  margin-left: 0.06em; opacity: 0.8;
}
.intro-word .rtm { font-size: 0.3em; margin-left: 0.05em; opacity: 0.85; }
.footer p.about { font-size: 14px; color: var(--fg-3); max-width: 40ch; line-height: 1.6; }
.footer h5 { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--fg-3); margin: 0 0 16px; font-weight: 500; }
.footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 12px; }
.footer ul a { color: var(--fg-2); font-size: 14px; text-decoration: none; }
.footer ul a:hover { color: var(--fg-1); }
.footer-bottom { margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; font-size: 13px; color: var(--fg-3); }
.footer-bottom .region { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.04em; }

/* =============================================================
   SCROLL REVEAL (subtle)
   ============================================================= */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out); }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: 0.07s; }
.reveal.d2 { transition-delay: 0.14s; }
.reveal.d3 { transition-delay: 0.21s; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
}

/* parallax helper — JS sets --py */
.parallax { transform: translate3d(0, var(--py, 0px), 0); will-change: transform; }

/* =============================================================
   LEGAL POPUP (first visit)
   ============================================================= */
.legal-overlay {
  position: fixed; inset: 0; z-index: 200;
  display: none; align-items: center; justify-content: center;
  padding: 20px;
  background: rgba(8,9,12,0.5); backdrop-filter: blur(6px);
}
.legal-overlay.show { display: flex; }
.legal-card {
  width: 100%; max-width: 460px; padding: 28px;
  border-radius: var(--r-2xl);
  background: var(--glass-bright-fill-strong);
  border: 1px solid var(--glass-bright-stroke);
  backdrop-filter: blur(var(--glass-blur-strong)) saturate(var(--glass-saturate));
  box-shadow: var(--glass-bright-shadow);
  position: relative;
}
[data-theme="dark"] .legal-card { background: var(--glass-dark-fill-strong); border-color: var(--glass-dark-stroke); box-shadow: var(--glass-dark-shadow); color: #fff; }
.legal-card .label { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--accent); }
.legal-card h3 { font-size: 21px; font-weight: 600; margin: 10px 0 10px; }
.legal-card p { font-size: 14px; color: var(--fg-2); line-height: 1.55; margin: 0 0 18px; }
[data-theme="dark"] .legal-card p { color: rgba(255,255,255,0.78); }
.legal-card .links { display: flex; gap: 16px; margin-bottom: 20px; font-size: 13px; }
.legal-card .btn { width: 100%; justify-content: center; }

/* =============================================================
   FORMS
   ============================================================= */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }
.field { display: flex; flex-direction: column; gap: 7px; }
.field.full { grid-column: 1 / -1; }
.field label { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--fg-3); }
.field input, .field select, .field textarea {
  font-family: var(--font-body); font-size: 15px; color: var(--fg-1);
  padding: 13px 15px; border-radius: var(--r-md);
  background: var(--bg-elev); border: 1px solid var(--line-strong);
  transition: border-color var(--dur-fast), box-shadow var(--dur-fast);
  width: 100%;
}
.field textarea { min-height: 130px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(31,94,255,0.18);
}
.checkbox { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; color: var(--fg-2); }
.checkbox input { width: 20px; height: 20px; margin-top: 2px; flex-shrink: 0; accent-color: var(--blue-500); }

/* legal/long-form pages */
.legal-page { max-width: 760px; }
.legal-page h1 { font-family: var(--font-display); font-weight: 500; font-size: var(--t-display-m); letter-spacing: -0.03em; margin-bottom: 12px; }
.legal-page h2 { font-size: 22px; font-weight: 600; margin: 40px 0 12px; }
.legal-page h3 { font-size: 17px; font-weight: 600; margin: 24px 0 8px; }
.legal-page p, .legal-page li { font-size: 15px; color: var(--fg-2); line-height: 1.65; }
.legal-page ul { padding-left: 20px; display: flex; flex-direction: column; gap: 6px; }
.placeholder {
  display: inline-block; font-family: var(--font-mono); font-size: 12px;
  color: var(--orange-700); background: var(--orange-50); border: 1px dashed var(--orange-300);
  border-radius: var(--r-xs); padding: 1px 7px;
}
[data-theme="dark"] .placeholder { color: var(--orange-300); background: rgba(255,122,26,0.12); border-color: rgba(255,122,26,0.4); }
.legal-note {
  margin: 24px 0; padding: 16px 18px; border-radius: var(--r-lg);
  border-left: 3px solid var(--orange-500); background: var(--orange-50); color: var(--orange-800); font-size: 14px;
}
[data-theme="dark"] .legal-note { background: rgba(255,122,26,0.1); color: var(--orange-200); }

/* page hero (smaller than home hero) */
.page-hero { padding: 168px 0 88px; color: #fff; position: relative; overflow: hidden;
  border-radius: 0 0 var(--r-3xl) var(--r-3xl);
  background:
    radial-gradient(820px 520px at 18% 0%, rgba(42,102,255,0.5), transparent 60%),
    radial-gradient(620px 460px at 90% 60%, rgba(255,122,26,0.14), transparent 62%),
    linear-gradient(165deg, #0A1226 0%, #070A14 60%, #0B0E16 100%);
}
.page-hero::after { content:""; position:absolute; left:0; right:0; bottom:0; height:140px; background: linear-gradient(180deg, transparent, var(--bg)); }
.page-hero .wrap { position: relative; z-index: 2; }
.page-hero h1 { font-family: var(--font-display); font-weight: 500; color: #fff; font-size: var(--t-display-l); line-height: 1.0; letter-spacing: -0.03em; margin: 18px 0 0; max-width: 18ch; }
.page-hero .sub { font-size: clamp(16px,1.8vw,20px); color: rgba(255,255,255,0.78); max-width: 54ch; margin-top: 22px; }

@media (max-width: 860px) {
  .nav-links { display: none; }
  .nav-burger { display: inline-flex; }
  .hero { padding: 150px 0 90px; }
  .page-hero { padding: 140px 0 72px; }
}

/* =============================================================
   LOGO INTRO — cinematic entry with scroll-transition (index only)
   Default (no JS / reduced-motion): a static full-viewport logo
   banner that simply scrolls away. JS adds `.intro-scroll` on <html>
   to upgrade it to a pinned overlay that morphs out on scroll.
   ============================================================= */
.intro-sentinel { display: none; }

.intro {
  position: relative;
  z-index: 80;
  min-height: 100vh;
  display: grid; place-items: center;
  padding: 96px 24px;
  text-align: center;
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(1000px 680px at 50% -12%, rgba(42,102,255,0.55), transparent 62%),
    radial-gradient(720px 560px at 84% 92%, rgba(255,122,26,0.16), transparent 60%),
    radial-gradient(560px 460px at 12% 88%, rgba(255,59,71,0.10), transparent 62%),
    linear-gradient(165deg, #0A1226 0%, #070A14 55%, #0B0E16 100%);
}
@supports (height: 100svh) { .intro { min-height: 100svh; } }

/* faint drifting grid texture inside the intro panel */
.intro::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(to right, rgba(138,168,255,0.10) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(138,168,255,0.10) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: radial-gradient(120% 90% at 50% 40%, #000 8%, transparent 66%);
          mask-image: radial-gradient(120% 90% at 50% 40%, #000 8%, transparent 66%);
}

.intro-inner {
  position: relative; z-index: 1;
  display: flex; flex-direction: column; align-items: center; gap: clamp(18px, 3vw, 30px);
  transform: translateY(calc(var(--intro-p, 0) * -6vh)) scale(calc(1 - var(--intro-p, 0) * 0.16));
  will-change: transform;
}
.intro-logo {
  width: clamp(92px, 12vw, 148px); height: auto;
  filter: drop-shadow(0 20px 52px rgba(31,94,255,0.45));
  transform: translateY(calc(var(--intro-p, 0) * -2vh));
}
.intro-word {
  font-family: var(--font-display); font-weight: 800; font-style: italic;
  letter-spacing: 0.012em; line-height: 0.86; margin: 0;
  font-size: clamp(68px, 16.5vw, 216px);
  color: #fff;
  text-shadow: 0 2px 40px rgba(31,94,255,0.30);
}
.intro-tag {
  font-family: var(--font-mono); text-transform: uppercase; font-weight: 500;
  letter-spacing: 0.3em; padding-left: 0.3em;
  font-size: clamp(9.5px, 1.3vw, 13px);
  color: rgba(255,255,255,0.62);
  text-wrap: balance;
}
.intro-hint {
  position: absolute; left: 0; right: 0; bottom: clamp(20px, 4vh, 40px);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  font-family: var(--font-mono); text-transform: uppercase; letter-spacing: 0.2em;
  font-size: 11px; color: rgba(255,255,255,0.55);
  opacity: clamp(0, calc(1 - var(--intro-p, 0) * 2.4), 1);
  pointer-events: none;
}
.intro-hint svg { width: 20px; height: 20px; }
@media (prefers-reduced-motion: no-preference) {
  .intro-hint svg { animation: introChevron 2s var(--ease-in-out) infinite; }
}
@keyframes introChevron { 0%,100% { transform: translateY(0); opacity: 0.7; } 50% { transform: translateY(5px); opacity: 1; } }

/* ---- JS upgrade: pinned overlay that fades on scroll ---- */
html.intro-scroll .intro-sentinel { display: block; height: 100vh; }
@supports (height: 100svh) { html.intro-scroll .intro-sentinel { height: 100svh; } }
html.intro-scroll .intro {
  position: fixed; inset: 0; min-height: 0; height: 100vh;
  opacity: clamp(0, calc(1.12 - var(--intro-p, 0) * 1.12), 1);
  will-change: opacity;
}
@supports (height: 100svh) { html.intro-scroll .intro { height: 100svh; } }
html.intro-done .intro { pointer-events: none; }

/* nav stays hidden until the intro has mostly cleared, then eases in */
html.intro-scroll .nav-shell {
  transition: opacity var(--dur-med) var(--ease-out), transform var(--dur-med) var(--ease-out);
}
html.intro-scroll[data-intro="in"] .nav-shell {
  opacity: 0; transform: translateY(-10px); pointer-events: none;
}

@media (max-width: 760px) {
  .intro { padding: 80px 20px; }
  .intro-word { font-size: clamp(58px, 19vw, 110px); }
}

/* =============================================================
   COHESIVE DARK CLOSING AREA (home)
   A document-anchored dark sheet that rises from the bottom as you
   scroll into the lower part of the page, so the closing region reads
   as one continuous dark surface (CTA band + footer) rather than a few
   detached dark elements. Injected + positioned by eipme.js (top edge
   anchored just above the closing block), so the top fade always blends
   harmoniously into the page background above it.
   ============================================================= */
.bg-closer {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  z-index: 0;                 /* above .site-bg (auroras), below content (z1) */
  pointer-events: none;
  background: linear-gradient(180deg,
    rgba(7, 9, 15, 0) 0%,
    rgba(7, 9, 15, 0.55) 30%,
    rgba(8, 10, 16, 0.92) 56%,
    #070A12 78%,
    #070A12 100%);
  opacity: 0;
  transition: opacity 0.5s var(--ease-out);
}
body.has-closer .bg-closer { opacity: 1; }

/* Footer sits on the dark closing surface — flip its ink to read on dark. */
body.has-closer .footer { border-top-color: rgba(255,255,255,0.10); }
body.has-closer .footer-brand .name { color: #fff; }
body.has-closer .footer p.about { color: rgba(255,255,255,0.62); }
body.has-closer .footer h5 { color: rgba(255,255,255,0.52); }
body.has-closer .footer ul a { color: rgba(255,255,255,0.74); }
body.has-closer .footer ul a:hover { color: #fff; }
body.has-closer .footer-bottom {
  border-top-color: rgba(255,255,255,0.10);
  color: rgba(255,255,255,0.58);
}
