/* ============================================================
   ijsound studio — 2026 design system
   Dark, violet-neon AV/IT integrator aesthetic
   ============================================================ */

:root {
  color-scheme: dark;
  /* ijsound brand palette — vivid purple accent system on a black→anthracite base */
  --primary: #9900FF;
  --accent: #CC33FF;
  --background: #330066;
  --secondary: #6600CC;
  --light-accent: #CC66FF;
  --soft-purple: #9966FF;

  /* Base surfaces: black → anthracite (the palette above is layered on top as glow/accent, not a flat page bg) */
  --bg: #050506;
  --bg-anthracite: #1c1b22;
  --bg-alt: #0e0a16;
  --surface: #150f1e;
  --surface-2: #1f1830;
  --surface-glass: rgba(21, 15, 30, 0.62);
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.14);

  --text: #f5f2fb;
  --text-muted: #b0a6c7;
  --text-faint: #756a92;

  /* Legacy aliases — existing components/content reference these names; values now resolve to the palette above */
  --violet: var(--primary);
  --violet-bright: var(--accent);
  --violet-deep: var(--secondary);
  --blue: var(--soft-purple);
  --pink: var(--light-accent);

  --grad-primary: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
  --grad-glow: linear-gradient(135deg, var(--light-accent) 0%, var(--primary) 55%, var(--secondary) 100%);
  --grad-surface: linear-gradient(180deg, rgba(153, 0, 255, 0.08) 0%, rgba(153, 0, 255, 0) 100%);

  --shadow-glow: 0 0 40px rgba(153, 0, 255, 0.38);
  --shadow-card: 0 20px 60px rgba(0, 0, 0, 0.5);

  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-pill: 999px;

  --font-head: 'Sora', 'Inter', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;

  --container: 1220px;
  --nav-h: 90px;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --dur-fast: 180ms;
  --dur-med: 320ms;
}

* { box-sizing: border-box; }
/* Lock the page to the viewport width — nothing (off-canvas drawer, decorative
   glows, animations) may ever widen the scrollable area on mobile. `clip` is
   used where supported because, unlike `hidden`, it never creates a scroll
   container, so the sticky header keeps working. */
html { scroll-behavior: smooth; overflow-x: hidden; }
body { overflow-x: hidden; }
@supports (overflow: clip) {
  html, body { overflow-x: clip; }
}
/* Never allow sideways panning/zoom-jitter from touch — vertical pan and
   pinch-zoom only. Elements that scroll horizontally on purpose (tables,
   the open nav drawer) keep their own touch-action. */
html, body { touch-action: pan-y pinch-zoom; }
table { touch-action: auto; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}

body {
  margin: 0;
  background: linear-gradient(160deg, #000000 0%, var(--bg-anthracite) 100%);
  background-attachment: fixed;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(680px 480px at 85% -10%, rgba(153, 0, 255, 0.24), transparent 60%),
    radial-gradient(600px 500px at -10% 20%, rgba(51, 0, 102, 0.55), transparent 60%),
    radial-gradient(500px 420px at 60% 100%, rgba(204, 51, 255, 0.1), transparent 65%);
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { font-family: var(--font-head); font-weight: 700; line-height: 1.15; margin: 0 0 0.5em; letter-spacing: -0.01em; }
p { margin: 0 0 1em; color: var(--text-muted); }
ul { padding-left: 1.2em; color: var(--text-muted); }
b, strong { color: var(--text); font-weight: 600; }

.container { max-width: var(--container); margin: 0 auto; padding: 0 24px; position: relative; z-index: 1; }
section { position: relative; z-index: 1; padding: 110px 0; }
section.tight { padding: 70px 0; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-head);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--violet-bright);
  margin-bottom: 16px;
}
.eyebrow::before {
  content: "";
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--grad-primary);
  box-shadow: 0 0 12px var(--violet);
}

h1 { font-size: clamp(2.4rem, 4.6vw, 4.2rem); }
h2 { font-size: clamp(1.9rem, 3vw, 2.7rem); }
h3 { font-size: 1.3rem; }
.section-head { max-width: 680px; margin-bottom: 56px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.gradient-text {
  background: var(--grad-glow);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---------- Buttons ---------- */
.btn {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.01em;
  padding: 14px 28px;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: transform var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out);
}
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.btn:active { transform: translateY(0) scale(0.98); }
.btn-primary {
  background: var(--grad-primary);
  color: #fff;
  /* Crisp top highlight + fine-stepped glow — a high-resolution falloff. */
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    inset 0 -1px 0 rgba(51, 0, 102, 0.35),
    0 2px 6px rgba(0, 0, 0, 0.35),
    0 8px 24px rgba(153, 0, 255, 0.34),
    0 18px 48px rgba(102, 0, 204, 0.22);
}
/* Sheen sweep on hover — state feedback, not decoration. */
.btn-primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, 0.22) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform 560ms var(--ease-out);
  pointer-events: none;
}
.btn-primary:hover::after { transform: translateX(120%); }
.btn-primary:hover {
  transform: translateY(-2px);
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  /* Deep-purple glow, layered in fine steps for a smooth, high-resolution falloff. */
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.26),
    inset 0 -1px 0 rgba(51, 0, 102, 0.4),
    0 4px 12px rgba(102, 0, 204, 0.5),
    0 8px 22px rgba(102, 0, 204, 0.42),
    0 14px 36px rgba(76, 0, 153, 0.36),
    0 0 28px rgba(51, 0, 102, 0.4);
}
.btn-ghost {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  border-color: var(--border-strong);
  backdrop-filter: blur(8px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}
.btn-ghost:hover {
  border-color: var(--primary);
  background: rgba(153, 0, 255, 0.1);
  transform: translateY(-2px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 8px 24px rgba(153, 0, 255, 0.18);
}
.btn-sm { padding: 10px 20px; font-size: 13px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  background: rgba(5, 5, 6, 0.55);
  backdrop-filter: blur(16px) saturate(140%);
  border-bottom: 1px solid transparent;
  transition: background var(--dur-med) var(--ease-out), border-color var(--dur-med) var(--ease-out), height var(--dur-med) var(--ease-out);
}
.site-header.scrolled {
  background: rgba(5, 5, 6, 0.86);
  border-bottom-color: var(--border);
}
.site-header .container { display: flex; align-items: center; justify-content: space-between; width: 100%; }

.brand { display: flex; align-items: center; }
.brand-mark {
  display: block;
  height: 58px;
  width: auto;
  filter: drop-shadow(0 0 5px rgba(153, 0, 255, 0.4)) drop-shadow(0 0 14px rgba(153, 0, 255, 0.18));
  transition: filter var(--dur-med) var(--ease-out), transform var(--dur-med) var(--ease-out), height var(--dur-med) var(--ease-out);
}
.brand:hover .brand-mark,
.brand:focus-visible .brand-mark {
  /* Deep-purple glow, layered in fine steps. Radii scaled to 30% of the previous
     values — the halo now sits tight on the mark's edge instead of blooming outward. */
  filter:
    drop-shadow(0 0 0.2px rgba(153, 0, 255, 0.55))
    drop-shadow(0 0 0.2px rgba(102, 0, 204, 0.5))
    drop-shadow(0 0 0.4px rgba(102, 0, 204, 0.42))
    drop-shadow(0 0 0.4px rgba(76, 0, 153, 0.36))
    drop-shadow(0 0 0.7px rgba(51, 0, 102, 0.32))
    drop-shadow(0 0 0.9px rgba(51, 0, 102, 0.24));
  transform: scale(1.04);
}
.brand-mark-footer { height: 52px; }

.nav-main { display: flex; align-items: center; gap: 18px; }
.nav-main a {
  white-space: nowrap;
  font-size: 14.5px;
  font-weight: 500;
  color: var(--text-muted);
  position: relative;
  padding: 6px 0;
  transition: color var(--dur-fast);
}
.nav-main a:hover, .nav-main a.active { color: var(--text); }
.nav-main a.active::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: -4px;
  height: 2px; border-radius: 2px;
  background: var(--grad-primary);
}
.nav-right { display: flex; align-items: center; gap: 14px; }

.lang-switch { position: relative; }
.lang-switch button {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-strong);
  color: var(--text);
  font-family: var(--font-head);
  font-size: 13px;
  font-weight: 600;
  padding: 11px 14px;
  border-radius: var(--radius-pill);
  display: flex; align-items: center; gap: 6px;
  cursor: pointer;
}
.lang-menu {
  position: absolute; top: calc(100% + 8px); right: 0;
  background: var(--surface); border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  min-width: 150px;
  box-shadow: var(--shadow-card);
  opacity: 0; visibility: hidden; transform: translateY(-6px);
  transition: all var(--dur-fast) var(--ease-out);
  overflow: hidden;
  z-index: 200;
}
.lang-switch.open .lang-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.lang-menu a { display: flex; align-items: center; gap: 8px; padding: 10px 14px; font-size: 13.5px; color: var(--text-muted); }
.lang-menu a:hover { background: rgba(153, 0, 255, 0.14); color: var(--text); }

.nav-toggle {
  display: none;
  width: 44px; height: 44px;
  border-radius: 10px;
  border: 1px solid var(--border-strong);
  background: rgba(255, 255, 255, 0.03);
  align-items: center; justify-content: center;
  cursor: pointer;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  content: ""; display: block; width: 18px; height: 2px; background: var(--text); border-radius: 2px; position: relative; transition: all var(--dur-fast);
}
.nav-toggle span::before { position: absolute; top: -6px; }
.nav-toggle span::after { position: absolute; top: 6px; }

@media (max-width: 960px) {
  .site-header { height: 76px; }
  .brand-mark { height: 46px; }
  .nav-main { position: fixed; inset: 76px 0 0 0; height: calc(100dvh - 76px); background: rgba(5,5,6,0.98); backdrop-filter: blur(20px); flex-direction: column; justify-content: flex-start; padding: 40px 24px; gap: 6px; transform: translateX(100%); visibility: hidden; transition: transform var(--dur-med) var(--ease-out), visibility 0s linear var(--dur-med); overflow-y: auto; overscroll-behavior: contain; touch-action: pan-y; -webkit-overflow-scrolling: touch; }
  .nav-main.open { transform: translateX(0); visibility: visible; transition: transform var(--dur-med) var(--ease-out); }
  /* While the drawer is open the page underneath is pinned in place
     (position:fixed + JS offset restore) so iOS can't drag or zoom it */
  body.nav-open { position: fixed; left: 0; right: 0; width: 100%; overflow: hidden; }
  /* The header is sticky *inside* body, so once body is pinned it must become
     fixed itself — otherwise it would scroll off-screen with the offset body */
  body.nav-open .site-header { position: fixed; top: 0; left: 0; right: 0; }
  /* iOS mis-renders fixed backgrounds while scrolling (jank/quality jumps) —
     fall back to a scrolling background on small screens */
  body { background-attachment: scroll; }
  .nav-main a { font-size: 20px; padding: 14px 0; width: 100%; border-bottom: 1px solid var(--border); }
  .nav-toggle { display: flex; }
  .nav-right .btn-primary.desktop-only { display: none; }
}

/* ---------- Hero opener: 3D device + slogan ---------- */
.hero-opener {
  position: relative;
  min-height: 88vh;
  min-height: 88dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 30px 0 90px;
  overflow: hidden;
}
.opener-bg {
  position: absolute; inset: 0; z-index: 0;
  background:
    radial-gradient(60% 55% at 50% 38%, rgba(153,0,255,0.22), transparent 70%),
    radial-gradient(45% 45% at 80% 85%, rgba(102,0,204,0.28), transparent 70%);
}
.opener-bg::after {
  content: "";
  position: absolute; inset: 0;
  background-image: linear-gradient(rgba(153,0,255,0.08) 1px, transparent 1px), linear-gradient(90deg, rgba(153,0,255,0.08) 1px, transparent 1px);
  background-size: 46px 46px;
  -webkit-mask-image: radial-gradient(60% 60% at 50% 45%, #000, transparent 75%);
  mask-image: radial-gradient(60% 60% at 50% 45%, #000, transparent 75%);
}
.opener-inner {
  position: relative; z-index: 3;
  display: block;
  text-align: center;
}
.opener-text { max-width: 760px; margin: 0 auto; }
.opener-text h1 { margin-bottom: 20px; }
.opener-text .lead { font-size: 18px; margin-bottom: 32px; max-width: 620px; margin-left: auto; margin-right: auto; }
.opener-text .hero-cta { justify-content: center; }

/* -- Audio waveform (brand signature visual) — live canvas visualizer with a breathing,
      center-weighted amplitude envelope (calibrated against reference EQ footage) -- */
.wave-stage {
  position: relative;
  width: 100%;
}
.wave-stage::before {
  content: "";
  position: absolute; inset: -25% -8%;
  background: radial-gradient(50% 55% at 50% 50%, rgba(153,0,255,0.26), transparent 72%);
  pointer-events: none;
  z-index: 0;
}
.wave-viewport {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 1;
}
.wave-canvas {
  display: block;
  width: 100%;
  height: 100%;
}

/* Large — full-bleed background layer filling the homepage opener;
   the headline, lead and CTAs float directly on top of the animation. */
.wave-stage.wave-large {
  position: absolute;
  inset: 0;
  z-index: 1;
  margin-bottom: 0;
  pointer-events: none;
  opacity: 0.92;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}
.wave-stage.wave-large .wave-viewport {
  transform: perspective(1200px) rotateX(12deg) scale(1.05);
  transform-origin: 50% 62%;
}
/* Soft scrim between the waveform and the copy — keeps the text perfectly
   readable while the animation stays fully visible around and behind it. */
.hero-opener::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: radial-gradient(48% 44% at 50% 52%, rgba(4, 3, 8, 0.6), rgba(4, 3, 8, 0.26) 55%, transparent 78%);
}
.opener-text h1 { text-shadow: 0 2px 34px rgba(0, 0, 0, 0.6), 0 0 90px rgba(153, 0, 255, 0.28); }
.opener-text .lead { text-shadow: 0 1px 18px rgba(0, 0, 0, 0.75); }
.opener-text .eyebrow { text-shadow: 0 1px 14px rgba(0, 0, 0, 0.7); }

/* Homepage hero video opener — the clip is blue/cyan by nature; a hue shift
   pulls it into the site's violet palette and a slight dim keeps the motto
   perfectly readable on top of it. */
.wave-video-stage { opacity: 1; }
.hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  filter: hue-rotate(48deg) saturate(1.15) brightness(0.82);
}

/* Slow-hypnotic variant — the clip is already deep navy with cyan/violet
   ribbons, i.e. natively in the site palette, so no hue shift; only a dim
   for motto legibility and a small saturation lift. */
.hero-video-hypnotic {
  filter: saturate(1.08) brightness(0.72);
}

/* Boardroom-scene variant — the clip contains people/skin tones, so NO hue
   rotation (it would turn faces green). The scene is bright (white table,
   daylight windows), so it needs a stronger dim than the abstract clips to
   keep the overlaid motto perfectly readable. */
.hero-video-scene {
  filter: brightness(0.6) saturate(1.05) contrast(1.03);
}

/* Inner-page band variant — the waveform clip is natively in the site's
   violet palette, so no hue shift; just a slight dim to blend into the
   page-hero background and keep headings readable. */
.hero-video-band {
  filter: brightness(0.85) saturate(1.05);
}

/* Compact / inline — full-width band across the top of inner page-hero sections */
.wave-stage.wave-compact,
.wave-stage.wave-inline {
  position: static;
  width: 100%;
  max-width: 100%;
  height: 210px;
  margin-bottom: 38px;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
}
.wave-stage.wave-compact .wave-viewport,
.wave-stage.wave-inline .wave-viewport {
  transform: perspective(900px) rotateX(14deg) scale(1.05);
  transform-origin: 50% 100%;
}

.scroll-cue {
  position: absolute; left: 50%; bottom: 28px; z-index: 4;
  transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  background: none; border: none; cursor: pointer;
  color: var(--text-faint);
  font-family: var(--font-head); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase;
}
.scroll-cue span.chevron { width: 20px; height: 20px; animation: scroll-bounce 1.8s ease-in-out infinite; color: var(--accent); }
@keyframes scroll-bounce { 0%, 100% { transform: translateY(0); opacity: .6; } 50% { transform: translateY(8px); opacity: 1; } }

@media (max-width: 900px) {
  .hero-opener { padding-top: 20px; min-height: 74vh; min-height: 74dvh; }
}
@media (max-width: 960px) {
  .wave-stage.wave-compact, .wave-stage.wave-inline { height: 130px; margin-bottom: 26px; }
}
@media (prefers-reduced-motion: reduce) {
  .scroll-cue span.chevron { animation: none !important; }
}

/* ---------- Hero slideshow ---------- */
.hero { padding-top: 56px; padding-bottom: 0; }
.hero-shell {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  min-height: 640px;
  display: flex;
  align-items: flex-end;
  border: 1px solid var(--border-strong);
  box-shadow: var(--shadow-card);
}
.hero-slides { position: absolute; inset: 0; }
.hero-slide {
  position: absolute; inset: 0;
  opacity: 0;
  transition: opacity 1400ms var(--ease-out);
}
.hero-slide.active { opacity: 1; }
.hero-slide .scene { position: absolute; inset: 0; }
.hero-slide .photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; filter: saturate(1.05) contrast(1.03); }
.hero-slide::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(0deg, rgba(6,5,10,0.92) 0%, rgba(6,5,10,0.55) 42%, rgba(6,5,10,0.25) 70%, rgba(6,5,10,0.55) 100%);
}
.hero-content { position: relative; z-index: 3; padding: 60px 56px; max-width: 720px; }
.hero-content h1, .hero-content h2 { margin-bottom: 20px; font-size: clamp(2.4rem, 4.6vw, 4.2rem); }
.hero-content .lead { font-size: 18px; color: var(--text-muted); max-width: 560px; margin-bottom: 32px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 40px; }

.hero-dots { position: absolute; z-index: 4; right: 40px; bottom: 40px; display: flex; gap: 8px; }
.hero-dots button { width: 26px; height: 4px; border-radius: 2px; border: none; background: rgba(255,255,255,0.25); cursor: pointer; padding: 0; transition: all var(--dur-fast); }
.hero-dots button.active { background: var(--grad-primary); width: 40px; }

.hero-stats { display: grid; grid-template-columns: repeat(3, 1fr); position: relative; z-index: 3; margin: 0 56px; transform: translateY(50%); border-radius: var(--radius-md); background: rgba(14, 10, 20, 0.86); backdrop-filter: blur(20px); border: 1px solid var(--border-strong); box-shadow: var(--shadow-card); }
.hero-stat { padding: 26px 20px; text-align: center; border-right: 1px solid var(--border); }
.hero-stat:last-child { border-right: none; }
.hero-stat .num { font-family: var(--font-head); font-size: 30px; font-weight: 800; background: var(--grad-glow); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-stat .label { font-size: 13px; color: #d6cceb; font-weight: 500; margin-top: 4px; text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5); }

@media (max-width: 760px) {
  .hero-shell { min-height: 560px; border-radius: var(--radius-md); }
  .hero-content { padding: 36px 24px; }
  .hero-stats { grid-template-columns: repeat(3, 1fr); margin: 0 16px; transform: translateY(30px); }
  .hero-stat { padding: 18px 8px; }
}

/* Abstract "room scene" generator classes used by hero + project cards */
.scene { background-color: #0c0a16; }
.scene-grid { background-image: linear-gradient(rgba(153,0,255,0.14) 1px, transparent 1px), linear-gradient(90deg, rgba(153,0,255,0.14) 1px, transparent 1px); background-size: 42px 42px; }
.scene-glow-a { background: radial-gradient(60% 60% at 75% 20%, rgba(153,0,255,0.55), transparent), radial-gradient(50% 50% at 15% 80%, rgba(153,102,255,0.4), transparent), #0c0a16; }
.scene-glow-b { background: radial-gradient(55% 55% at 20% 15%, rgba(204,102,255,0.45), transparent), radial-gradient(60% 60% at 85% 75%, rgba(102,0,204,0.4), transparent), #0a0912; }
.scene-glow-c { background: radial-gradient(70% 70% at 50% 0%, rgba(153,0,255,0.5), transparent), #0b0a14; }
.scene-panel { position: absolute; border-radius: 12px; background: linear-gradient(160deg, rgba(255,255,255,0.06), rgba(255,255,255,0.01)); border: 1px solid rgba(255,255,255,0.1); box-shadow: 0 0 60px rgba(153,0,255,0.25) inset; }
.scene-screen { position: absolute; border-radius: 10px; overflow: hidden; background: #05040a; border: 1px solid rgba(153,0,255,0.4); box-shadow: 0 0 50px rgba(153,0,255,0.45); }
.scene-screen::before { content: ""; position: absolute; inset: 0; background: linear-gradient(120deg, rgba(153,0,255,0.55), rgba(102,0,204,0.4), rgba(204,102,255,0.4)); opacity: 0.85; animation: sheen 7s ease-in-out infinite; }
.scene-bars { position: absolute; display: flex; align-items: flex-end; gap: 5px; }
.scene-bars i { display: block; width: 6px; background: var(--grad-glow); border-radius: 3px; opacity: 0.8; animation: eq 1.8s ease-in-out infinite; }
.scene-dot { position: absolute; border-radius: 50%; background: var(--grad-glow); filter: blur(1px); opacity: 0.9; }
.scene-line { position: absolute; height: 1px; background: linear-gradient(90deg, transparent, rgba(153,0,255,0.6), transparent); }
.scene-ring { position: absolute; border-radius: 50%; border: 1px solid rgba(153,0,255,0.35); }

@keyframes sheen { 0%,100% { filter: hue-rotate(0deg) brightness(1); } 50% { filter: hue-rotate(30deg) brightness(1.15); } }
@keyframes eq { 0%,100% { transform: scaleY(0.4); } 50% { transform: scaleY(1); } }
@keyframes float-slow { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-14px); } }
@keyframes spin-slow { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }

/* ---------- Cards / grids ---------- */
.grid { display: grid; gap: 24px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-5 { grid-template-columns: repeat(5, 1fr); }
@media (max-width: 960px) { .grid-3, .grid-4, .grid-5 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .grid-3, .grid-4, .grid-2, .grid-5 { grid-template-columns: 1fr; } }

.card {
  background: linear-gradient(160deg, var(--surface) 0%, var(--bg-alt) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 32px 28px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.045), 0 10px 30px rgba(0, 0, 0, 0.28);
  transition: transform var(--dur-med) var(--ease-out), border-color var(--dur-med), box-shadow var(--dur-med);
}
.card:hover {
  transform: translateY(-6px);
  border-color: rgba(153, 0, 255, 0.38);
  /* Crisp elevation + a fine violet halo, layered in small steps. */
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 14px 34px rgba(0, 0, 0, 0.5),
    0 26px 64px rgba(0, 0, 0, 0.42),
    0 0 0 1px rgba(153, 0, 255, 0.1),
    0 0 44px rgba(153, 0, 255, 0.14);
}
/* Card cover image — pulled out to the card edges (card padding is 32/28)
   with a fixed cinematic crop so mixed source photos read as one set. */
.card-media {
  margin: -32px -28px 20px;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: calc(var(--radius-md) - 1px) calc(var(--radius-md) - 1px) 0 0;
  border-bottom: 1px solid var(--border);
}
.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform var(--dur-med) var(--ease-out);
}
.card:hover .card-media img { transform: scale(1.04); }
.card .icon {
  width: 52px; height: 52px;
  border-radius: 14px;
  background: rgba(153, 0, 255, 0.14);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 20px;
  color: var(--accent);
}
.card .icon svg { width: 26px; height: 26px; }
.card h3 { margin-bottom: 10px; }
.card p { margin-bottom: 0; font-size: 14.5px; }
.card .link { display: inline-flex; align-items: center; gap: 6px; margin-top: 16px; font-size: 13.5px; font-weight: 600; color: var(--violet-bright); }
/* Whole service tile as a hyperlink to its detail page */
a.card-link { display: block; color: inherit; text-decoration: none; }
/* Service detail rows alternate image/text on desktop; on phones the image
   always leads so each subject opens with its visual */
@media (max-width: 620px) { .svc-media { order: -1; } }

/* ---------- Reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 700ms var(--ease-out), transform 700ms var(--ease-out); }
.reveal.in { opacity: 1; transform: translateY(0); }
.reveal-stagger > * { opacity: 0; transform: translateY(24px); transition: opacity 600ms var(--ease-out), transform 600ms var(--ease-out); }
.reveal-stagger.in > * { opacity: 1; transform: translateY(0); }
.reveal-stagger.in > *:nth-child(1) { transition-delay: 0ms; }
.reveal-stagger.in > *:nth-child(2) { transition-delay: 70ms; }
.reveal-stagger.in > *:nth-child(3) { transition-delay: 140ms; }
.reveal-stagger.in > *:nth-child(4) { transition-delay: 210ms; }
.reveal-stagger.in > *:nth-child(5) { transition-delay: 280ms; }
.reveal-stagger.in > *:nth-child(6) { transition-delay: 350ms; }

/* ---------- Brand marquee ---------- */
.marquee-wrap { position: relative; overflow: hidden; padding: 6px 0; -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.marquee-track { display: flex; align-items: center; gap: 26px; width: max-content; animation: marquee 85s linear infinite; }
.marquee-wrap:hover .marquee-track { animation-play-state: paused; }
.marquee-track.reverse { animation-direction: reverse; }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.brand-logo {
  --glow-rgb: 153, 0, 255; /* fallback purple; overridden per-logo via inline style from brands.js */
  display: flex; align-items: center; justify-content: center;
  height: 68px; width: 152px; flex-shrink: 0;
  padding: 12px 18px;
  border-radius: 16px;
  /* Light glass chip — dark logos stay perfectly readable on the dark page. */
  background: linear-gradient(165deg, #ffffff 0%, #efeaf8 58%, #e2dcf0 100%);
  border: 1px solid rgba(255, 255, 255, 0.65);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 6px 18px rgba(0, 0, 0, 0.38),
    0 2px 6px rgba(0, 0, 0, 0.3);
  transition: transform var(--dur-med) var(--ease-out), box-shadow var(--dur-med) var(--ease-out);
}
.brand-logo:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    0 12px 28px rgba(0, 0, 0, 0.48),
    0 0 22px rgba(var(--glow-rgb), 0.55),
    0 0 46px rgba(var(--glow-rgb), 0.28);
}
.brand-logo img { max-height: 100%; max-width: 100%; width: auto; object-fit: contain; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--border); padding: 80px 0 30px; background: var(--bg-alt); }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 40px; margin-bottom: 60px; }
.footer-grid h4 { font-size: 14px; color: var(--text); margin-bottom: 18px; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 2px; }
.footer-grid a { color: var(--text-muted); font-size: 14px; display: inline-block; padding: 10px 0; }
.footer-grid a:hover { color: var(--violet-bright); }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; padding-top: 30px; border-top: 1px solid var(--border); font-size: 13px; color: var(--text-faint); flex-wrap: wrap; gap: 12px; }
.footer-bottom a { display: inline-block; padding: 8px 0; }
.social-row { display: flex; gap: 10px; }
.social-row a { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--border-strong); display: flex; align-items: center; justify-content: center; }
.social-row a:hover { border-color: var(--primary); background: rgba(153,0,255,0.14); }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } }

/* ---------- Forms ---------- */
.field { margin-bottom: 20px; }
.field label { display: block; font-size: 13.5px; font-weight: 600; margin-bottom: 8px; color: var(--text); }
.field .req { color: var(--violet-bright); }
.field input, .field select, .field textarea {
  width: 100%;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border-strong);
  color: var(--text);
  border-radius: var(--radius-sm);
  padding: 13px 16px;
  font-family: var(--font-body);
  font-size: 16px;
  transition: border-color var(--dur-fast), box-shadow var(--dur-fast);
}
.field input::placeholder, .field textarea::placeholder { color: var(--text-faint); }
.field select option { background-color: var(--surface-2); color: var(--text); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 4px rgba(153,0,255,0.18); }
.field .hint { font-size: 12.5px; color: var(--text-faint); margin-top: 6px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 620px) { .field-row { grid-template-columns: 1fr; } }
.checkbox-row { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: var(--text-muted); }
.checkbox-row input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--violet); }
.form-note { font-size: 13px; color: var(--text-faint); margin-top: 14px; }
.form-success { display: none; padding: 20px; border-radius: var(--radius-sm); background: rgba(153,0,255,0.14); border: 1px solid var(--primary); color: var(--text); }
.form-error { display: none; padding: 16px 18px; border-radius: var(--radius-sm); background: rgba(239,68,68,0.12); border: 1px solid #ef4444; color: var(--text); margin-top: 16px; font-size: 13.5px; }

/* ---------- Misc ---------- */
.page-hero { padding: 34px 0 90px; text-align: left; position: relative; overflow: hidden; }
.page-hero .container { position: relative; z-index: 1; }
.page-hero.center { text-align: center; }
.breadcrumb { font-size: 13px; color: var(--text-faint); margin-bottom: 18px; }
.breadcrumb a:hover { color: var(--violet-bright); }
.badge { display: inline-block; font-size: 12px; font-weight: 600; padding: 5px 12px; border-radius: var(--radius-pill); background: rgba(153,0,255,0.16); color: var(--accent); border: 1px solid rgba(153,0,255,0.32); }
.divider { height: 1px; background: var(--border); margin: 0; }
table { width: 100%; border-collapse: collapse; margin: 24px 0; }
table th, table td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--border); font-size: 14px; }
table th { color: var(--text); font-family: var(--font-head); font-size: 13px; text-transform: uppercase; letter-spacing: 0.04em; }
blockquote { border-left: 3px solid var(--primary); padding: 4px 0 4px 20px; color: var(--text); font-style: italic; margin: 24px 0; }
code { background: rgba(255,255,255,0.06); padding: 2px 6px; border-radius: 4px; font-size: 13px; }

.cta-band { border-radius: var(--radius-lg); background: linear-gradient(135deg, rgba(153,0,255,0.2), rgba(51,0,102,0.5)); border: 1px solid var(--border-strong); padding: 64px; text-align: center; position: relative; overflow: hidden; }
.cta-band h2 { margin-bottom: 14px; }
.cta-band p { max-width: 520px; margin: 0 auto 30px; }
.cta-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

.back-to-top { position: fixed; right: 24px; bottom: 24px; width: 46px; height: 46px; border-radius: 50%; background: var(--surface); border: 1px solid var(--border-strong); display: flex; align-items: center; justify-content: center; opacity: 0; visibility: hidden; transform: translateY(10px); transition: all var(--dur-fast); z-index: 90; cursor: pointer; }
.back-to-top.show { opacity: 1; visibility: visible; transform: translateY(0); }
.back-to-top:hover { border-color: var(--primary); }

::selection { background: var(--primary); color: #fff; }
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--surface-2); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: var(--secondary); }

/* ---------- Mobile hardening (phones) ---------- */
/* Long words/URLs inside article bodies wrap instead of forcing horizontal scroll */
article { overflow-wrap: break-word; }

/* TL;DR answer box at the top of every article (GEO: self-contained summary
   that generative search engines can quote verbatim) */
.tldr-box {
  border-left: 3px solid var(--primary);
  background: rgba(153, 0, 255, 0.08);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 16px 20px;
  margin: 0 0 28px;
  font-size: 15.5px;
  color: var(--text);
}
.tldr-box strong { color: var(--accent); }

@media (max-width: 620px) {
  /* Footer stacks to one column — two-up columns get cramped below ~400px */
  .footer-grid { grid-template-columns: 1fr; gap: 28px; margin-bottom: 40px; }
  /* Wide tables scroll inside their own box instead of breaking page width */
  table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  /* CTA bands keep breathing room without eating the small screen (overrides inline padding) */
  .cta-band { padding: 34px 22px !important; }
  /* Slightly tighter section rhythm on phones */
  section { padding: 72px 0; }
  section.tight { padding: 48px 0; }
}


/* ============================================================
   Footer line animation — the violet equalizer clip fills the
   ENTIRE footer as a background layer under the text. The whole
   video frame stays visible (object-fit: fill stretches it to the
   footer box); dark-on-dark blending + soft fades melt it into the
   footer surface while the content floats above it.
   ============================================================ */
.site-footer { position: relative; overflow: hidden; }
.site-footer > .container { position: relative; z-index: 1; }
.footer-line-anim {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
  pointer-events: none;
}
.footer-line-anim video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: fill;
  object-position: center;
  opacity: 0.5;
  filter: saturate(1.05) brightness(0.9);
  mix-blend-mode: screen;
}
/* Gentle fades on every edge so the clip melts into the footer
   background instead of ending in hard lines. */
.footer-line-anim::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, var(--bg-alt) 0%, transparent 22%, transparent 82%, var(--bg-alt) 100%),
    linear-gradient(90deg, var(--bg-alt) 0%, transparent 10%, transparent 90%, var(--bg-alt) 100%);
  pointer-events: none;
}
@media (prefers-reduced-motion: reduce) {
  .footer-line-anim video { display: none; }
}

/* ============================================================
   Cookie consent banner — minimal, fixed to the bottom, matches
   the dark violet design system. Rendered by analytics-consent.js
   only when no consent choice is stored yet.
   ============================================================ */
.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
  padding: 14px 18px calc(14px + env(safe-area-inset-bottom, 0px));
  background: rgba(14, 10, 22, 0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid var(--border-strong);
}
.cookie-banner-inner {
  max-width: 1080px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 22px;
}
.cookie-banner-text {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--text-muted);
  flex: 1 1 auto;
}
.cookie-banner-link {
  color: var(--violet-bright);
  text-decoration: underline;
  white-space: nowrap;
}
.cookie-banner-actions {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}
@media (max-width: 720px) {
  .cookie-banner-inner { flex-direction: column; align-items: stretch; gap: 12px; }
  .cookie-banner-actions { justify-content: flex-end; }
}
