/* ============================================================
   TEREDA LABS — Design System
   teredalabs.com
   ============================================================
   Design DNA: CrowdStrike IA + Raycast skin + Anduril canvas + Raft hero
   ============================================================ */

/* --- FONTS --- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;700&display=swap');

/* --- CSS TOKENS --- */
:root {
  /* Backgrounds */
  --black: #000000;
  --black-raised: #0a0a0a;
  --black-elevated: #111111;

  /* Glass */
  --surface-glass: rgba(255,255,255,0.04);
  --surface-glass-hover: rgba(255,255,255,0.08);
  --border-glass: rgba(255,255,255,0.08);
  --border-glass-hover: rgba(255,255,255,0.16);

  /* Text */
  --text-primary: #ffffff;
  --text-secondary: #a1a1aa;
  --text-tertiary: #71717a;

  /* Brand */
  --brand-ember: #e8642c;
  --brand-ember-glow: rgba(232,100,44,0.15);
  --brand-ember-hot: #ff7a3d;

  /* Hell Hound */
  --hellhound-red: #dc2626;
  --hellhound-glow: rgba(220,38,38,0.2);

  /* Status */
  --success: #22c55e;

  /* Badge */
  --badge-gray: #d4d4d4;

  /* Spacing */
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --space-2xl: 48px;
  --space-3xl: 64px;
  --space-4xl: 80px;
  --space-5xl: 120px;
  --space-6xl: 160px;

  /* Layout */
  --max-width: 1280px;
  --nav-height: 72px;

  /* Type scale */
  --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

/* --- HOUDINI: Register custom angle property for ray animation --- */
@property --ray-angle {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}

/* --- RESET --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}
body {
  background: var(--black);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
a {
  color: inherit;
  text-decoration: none;
}
img, video {
  max-width: 100%;
  display: block;
}
button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}
ul, ol { list-style: none; }

/* --- ACCESSIBILITY --- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}
.skip-link {
  position: absolute;
  top: -100%;
  left: 50%;
  transform: translateX(-50%);
  background: var(--brand-ember);
  color: #fff;
  padding: 12px 24px;
  border-radius: 0 0 8px 8px;
  z-index: 10000;
  font-weight: 600;
  transition: top 0.2s;
}
.skip-link:focus {
  top: 0;
}
*:focus-visible {
  outline: 2px solid var(--brand-ember);
  outline-offset: 2px;
}

/* --- LAYOUT --- */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-lg);
}
section {
  padding: var(--space-5xl) 0;
  position: relative;
  overflow: hidden;
}

/* --- TYPOGRAPHY --- */
.display {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: clamp(36px, 5vw, 72px);
  line-height: 1.1;
  letter-spacing: -0.02em;
}
h1 {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: clamp(32px, 4vw, 48px);
  line-height: 1.15;
  letter-spacing: -0.02em;
}
h2 {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: clamp(24px, 3vw, 32px);
  line-height: 1.2;
}
h3 {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: clamp(18px, 2vw, 24px);
  line-height: 1.3;
}
.text-secondary { color: var(--text-secondary); }
.text-tertiary { color: var(--text-tertiary); }
.text-ember { color: var(--brand-ember); }
.text-red { color: var(--hellhound-red); }
.font-mono { font-family: var(--font-mono); }

.section-label {
  display: inline-block;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-tertiary);
  margin-bottom: var(--space-md);
}
.section-headline {
  margin-bottom: var(--space-md);
}
.section-sub {
  color: var(--text-secondary);
  font-size: 18px;
  max-width: 640px;
}

/* --- COMPONENTS: Glass Card --- */
.glass-card {
  background: var(--surface-glass);
  border: 1px solid var(--border-glass);
  border-radius: 12px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: var(--space-xl);
  transition: all 0.3s ease;
}
.glass-card:hover {
  background: var(--surface-glass-hover);
  border-color: var(--border-glass-hover);
}
.glass-card--lift:hover {
  transform: translateY(-2px);
}
/* --- Ray Border (Raycast-style rotating beam) --- */
.ray-border {
  position: relative;
  overflow: hidden;
  border: none;
  background: var(--black-raised);
}
.ray-border::before,
.ray-border::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
}
/* Spinning conic-gradient beam */
.ray-border::before {
  inset: -2px;
  background: conic-gradient(
    from var(--ray-angle),
    transparent 0%,
    transparent 70%,
    var(--brand-ember) 78%,
    var(--brand-ember-hot) 82%,
    var(--brand-ember) 86%,
    transparent 94%,
    transparent 100%
  );
  animation: ray-spin 4s linear infinite;
  z-index: -2;
}
/* Inner fill to mask the gradient, leaving only the border */
.ray-border::after {
  inset: 1px;
  background: var(--black-raised);
  z-index: -1;
}
/* Glow variant for hover */
.ray-border:hover::before {
  filter: blur(2px) brightness(1.3);
}
/* Red variant for Hell Hound */
.ray-border--red::before {
  background: conic-gradient(
    from var(--ray-angle),
    transparent 0%,
    transparent 70%,
    var(--hellhound-red) 78%,
    #ef4444 82%,
    var(--hellhound-red) 86%,
    transparent 94%,
    transparent 100%
  );
}
/* Transparent variant — for elements over video/image backgrounds */
.ray-border--transparent::after {
  background: rgba(0,0,0,0.85);
}
@keyframes ray-spin {
  from { --ray-angle: 0deg; }
  to { --ray-angle: 360deg; }
}

.glass-card--hellhound {
  border-color: rgba(220,38,38,0.3);
}
.glass-card--hellhound:hover {
  border-color: rgba(220,38,38,0.5);
  box-shadow: 0 0 30px var(--hellhound-glow);
}

/* --- COMPONENTS: Buttons --- */
.btn-ember {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--brand-ember);
  color: #ffffff;
  border: none;
  border-radius: 8px;
  padding: 14px 28px;
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 0 20px var(--brand-ember-glow);
  text-decoration: none;
}
.btn-ember:hover {
  background: var(--brand-ember-hot);
  box-shadow: 0 0 30px rgba(232,100,44,0.3);
  transform: translateY(-1px);
}
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: transparent;
  color: #ffffff;
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 8px;
  padding: 14px 28px;
  font-weight: 500;
  font-size: 16px;
  transition: all 0.3s ease;
  text-decoration: none;
}
.btn-ghost:hover {
  border-color: rgba(255,255,255,0.4);
  background: rgba(255,255,255,0.04);
}
.cta-group {
  display: flex;
  gap: var(--space-md);
  flex-wrap: wrap;
}

/* --- COMPONENTS: Divider --- */
.divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(232,100,44,0.3), transparent);
  margin: var(--space-4xl) 0;
  border: none;
}

/* --- COMPONENTS: Badge Pill --- */
.badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 100px;
  border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.03);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  white-space: nowrap;
}

/* --- WEBGL GLOW: Removed --- */

/* --- NAV --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  z-index: 1000;
  background: rgba(0,0,0,0.8);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-glass);
  transition: background 0.3s;
}
.nav__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-lg);
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
}
.nav__logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
}
.nav__logo-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1;
}
.nav__logo-tereda {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 24px;
  letter-spacing: 0.32em;
  color: #ffffff;
}
.nav__logo-labs {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 13px;
  letter-spacing: 0.45em;
  color: rgba(255,255,255,0.5);
  margin-top: 3px;
  text-indent: 0.45em;
}
.nav__links {
  display: flex;
  align-items: center;
  gap: var(--space-xl);
}
.nav__link {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color 0.2s;
  text-decoration: none;
  position: relative;
}
.nav__link:hover,
.nav__link--active {
  color: var(--text-primary);
}
.nav__link--active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--brand-ember);
  border-radius: 1px;
}

/* Dropdown */
.nav__dropdown {
  position: relative;
}
.nav__dropdown-trigger {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: color 0.2s;
  background: none;
  border: none;
  padding: 0;
}
.nav__dropdown-trigger:hover {
  color: var(--text-primary);
}
.nav__dropdown-trigger svg {
  width: 12px;
  height: 12px;
  transition: transform 0.2s;
}
.nav__dropdown.open .nav__dropdown-trigger svg {
  transform: rotate(180deg);
}
.nav__dropdown-menu {
  position: absolute;
  top: calc(100% + 16px);
  left: 50%;
  transform: translateX(-50%);
  min-width: 280px;
  background: var(--black-elevated);
  border: 1px solid var(--border-glass);
  border-radius: 12px;
  padding: var(--space-sm);
  opacity: 0;
  visibility: hidden;
  transform: translateX(-50%) translateY(-8px);
  transition: all 0.2s ease;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}
.nav__dropdown.open .nav__dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}
.nav__dropdown-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 14px;
  border-radius: 8px;
  transition: background 0.15s;
  text-decoration: none;
}
.nav__dropdown-item:hover {
  background: var(--surface-glass-hover);
}
.nav__dropdown-codename {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--brand-ember);
}
.nav__dropdown-codename--red {
  color: var(--hellhound-red);
}
.nav__dropdown-name {
  font-size: 14px;
  color: var(--text-secondary);
}

/* Hamburger */
.nav__hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  z-index: 1001;
}
.nav__hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: all 0.3s;
}
.nav__hamburger.open span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.nav__hamburger.open span:nth-child(2) {
  opacity: 0;
}
.nav__hamburger.open span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile nav overlay */
.nav__mobile-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.95);
  z-index: 999;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: var(--space-lg);
  padding: var(--space-2xl);
}
.nav__mobile-overlay.open {
  display: flex;
}
.nav__mobile-link {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-primary);
  text-decoration: none;
  transition: color 0.2s;
}
.nav__mobile-link:hover {
  color: var(--brand-ember);
}
.nav__mobile-sub {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  padding-left: var(--space-lg);
}
.nav__mobile-sub a {
  font-size: 16px;
  color: var(--text-secondary);
  text-decoration: none;
}
.nav__mobile-sub a:hover {
  color: var(--text-primary);
}
.nav__mobile-sub .text-red {
  color: var(--hellhound-red);
}

/* --- HERO --- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding-top: var(--nav-height);
}
.hero__video-wrap {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}
.hero__video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.6s ease;
}
.hero__video.video-ready {
  opacity: 1;
}
.hero__overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, rgba(0,0,0,0) 0%, rgba(0,0,0,0.25) 35%, rgba(0,0,0,0.7) 70%, rgba(0,0,0,0.85) 100%);
  z-index: 1;
}
.hero__content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 800px;
  padding: var(--space-2xl) var(--space-lg);
}
.hero__eyebrow {
  margin-bottom: var(--space-lg);
  text-shadow: 0 1px 8px rgba(0,0,0,0.8);
}
.hero__headline {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1.15;
  margin-bottom: var(--space-lg);
  min-height: 2.3em;
  text-shadow: 0 2px 20px rgba(0,0,0,0.8), 0 1px 3px rgba(0,0,0,0.9);
}
.hero__headline .cursor {
  display: inline-block;
  width: 3px;
  height: 1em;
  background: var(--brand-ember);
  margin-left: 2px;
  vertical-align: text-bottom;
  animation: blink 1s step-end infinite;
}
@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}
.hero__sub {
  color: var(--text-secondary);
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.6;
  margin-bottom: var(--space-xl);
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
  text-shadow: 0 1px 12px rgba(0,0,0,0.8), 0 1px 2px rgba(0,0,0,0.9);
}
.hero__cta {
  display: flex;
  gap: var(--space-md);
  justify-content: center;
  flex-wrap: wrap;
}
.hero__scroll {
  position: absolute;
  bottom: var(--space-xl);
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  animation: scrollBounce 2s ease infinite;
}
.hero__scroll svg {
  width: 24px;
  height: 24px;
  color: var(--text-tertiary);
}
@keyframes scrollBounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

/* --- BADGE CAROUSEL --- */
.carousel {
  position: relative;
  width: 100%;
  padding: var(--space-xl) 0;
  overflow: hidden;
}
.carousel__container {
  position: relative;
  margin: 0 20%;
  overflow: hidden;
}
.carousel__container::before,
.carousel__container::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  width: 1px;
  background: rgba(255,255,255,0.12);
  z-index: 2;
}
.carousel__container::before { left: 0; }
.carousel__container::after { right: 0; }
.carousel__fade-left,
.carousel__fade-right {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 60px;
  z-index: 1;
  pointer-events: none;
}
.carousel__fade-left {
  left: 0;
  background: linear-gradient(to right, #000 0%, transparent 100%);
}
.carousel__fade-right {
  right: 0;
  background: linear-gradient(to left, #000 0%, transparent 100%);
}
.carousel__track {
  display: flex;
  gap: var(--space-2xl);
  width: max-content;
  pointer-events: none;
  user-select: none;
  -webkit-user-select: none;
  will-change: transform;
}
/* carouselScroll keyframes kept as fallback if JS fails */
@keyframes carouselScroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
.carousel__badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.carousel__badge-icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.06);
  transition: all 0.3s ease;
}
/* No hover effects on carousel badges — carousel is non-interactive */
.carousel__badge-icon svg {
  width: 32px;
  height: 32px;
  color: var(--badge-gray);
}
.carousel__badge-icon--hellhound {
  border-color: rgba(200,0,0,0.15);
}
/* No hover on hellhound badge either — carousel is non-interactive */
.carousel__badge-label {
  font-size: 11.5px;
  font-weight: 500;
  color: var(--text-tertiary);
  text-align: center;
  max-width: 80px;
  line-height: 1.3;
}

/* --- CAPABILITY CARDS GRID --- */
/* --- SYSTEM MANIFEST: Full-width capability rows --- */
.sys-manifest {
  display: flex;
  flex-direction: column;
  border-top: 1px solid rgba(255,255,255,0.06);
}
.sys-row {
  display: grid;
  grid-template-columns: 40px 130px 1fr auto;
  grid-template-rows: auto 0fr;
  align-items: center;
  gap: 0 var(--space-lg);
  padding: var(--space-lg) var(--space-md);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  text-decoration: none;
  color: var(--text-primary);
  transition: background 0.3s, grid-template-rows 0.4s ease;
  position: relative;
}
.sys-row::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--brand-ember);
  opacity: 0;
  transition: opacity 0.3s;
}
.sys-row:hover {
  background: rgba(232,100,44,0.04);
  grid-template-rows: auto 1fr;
}
.sys-row:hover::before {
  opacity: 1;
}
.sys-row__index {
  font-family: var(--font-mono);
  font-size: 13px;
  color: rgba(255,255,255,0.2);
  font-weight: 500;
}
.sys-row:hover .sys-row__index {
  color: rgba(232,100,44,0.5);
}
.sys-row__codename {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--brand-ember);
}
.sys-row__title {
  font-size: 17px;
  font-weight: 500;
  color: var(--text-primary);
  line-height: 1.3;
}
.sys-row__arrow {
  font-size: 18px;
  color: rgba(255,255,255,0.15);
  transition: color 0.3s, transform 0.3s;
}
.sys-row:hover .sys-row__arrow {
  color: var(--brand-ember);
  transform: translateX(4px);
}
.sys-row__desc {
  grid-column: 1 / -1;
  overflow: hidden;
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  padding: 0 0 0 calc(40px + var(--space-lg));
  max-height: 0;
  opacity: 0;
  transition: max-height 0.4s ease, opacity 0.3s ease, padding 0.4s ease;
}
.sys-row:hover .sys-row__desc {
  max-height: 80px;
  opacity: 1;
  padding: var(--space-sm) 0 0 calc(40px + var(--space-lg));
}

/* Hell Hound row */
.sys-row--hellhound::before {
  background: var(--hellhound-red);
}
.sys-row--hellhound .sys-row__codename {
  color: var(--hellhound-red);
}
.sys-row--hellhound:hover {
  background: rgba(220,38,38,0.04);
}
.sys-row--hellhound:hover .sys-row__index {
  color: rgba(220,38,38,0.5);
}
.sys-row--hellhound:hover .sys-row__arrow {
  color: var(--hellhound-red);
}

/* --- INDUSTRY TILES --- */
.tiles-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-md);
}
.tile {
  position: relative;
  aspect-ratio: 1;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
}
.tile__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.tile__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.7);
  transition: background 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}
.tile:hover .tile__overlay {
  background: rgba(0,0,0,0.5);
}
.tile:hover .tile__img {
  transform: scale(1.02);
}
.tile__name {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  text-align: center;
  padding: var(--space-md);
  position: relative;
  z-index: 1;
}


/* --- BOTTOM CTA --- */
.bottom-cta {
  text-align: center;
  position: relative;
}
.bottom-cta h2 {
  margin-bottom: var(--space-md);
}
.bottom-cta .section-sub {
  margin: 0 auto var(--space-xl);
}

/* --- FOOTER --- */
.footer {
  border-top: 1px solid var(--border-glass);
  padding: var(--space-3xl) 0 var(--space-xl);
}
.footer__grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: var(--space-2xl);
  margin-bottom: var(--space-2xl);
}
.footer__brand-name {
  margin-bottom: var(--space-sm);
  display: flex;
  align-items: center;
}
.footer__brand-name svg,
.footer__brand-name img {
  height: 72px;
  width: auto;
  border-radius: 0;
  object-fit: contain;
}
.footer__brand-name img[src*="tfooter"] {
  filter: invert(1) contrast(3);
  mix-blend-mode: screen;
}
.footer__brand-legal {
  font-size: 13px;
  color: var(--text-tertiary);
  margin-bottom: var(--space-xs);
}
.footer__brand-location {
  font-size: 13px;
  color: var(--text-tertiary);
}
.footer__brand-email {
  font-size: 13px;
  color: var(--text-tertiary);
  margin: 2px 0 0;
}
.footer__brand-email a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.2s;
}
.footer__brand-email a:hover {
  color: var(--brand-ember);
}
.footer__col-title {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-tertiary);
  margin-bottom: var(--space-md);
}
.footer__col-links {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}
.footer__col-links a {
  font-size: 14px;
  color: var(--text-secondary);
  transition: color 0.2s;
  text-decoration: none;
}
.footer__col-links a:hover {
  color: var(--text-primary);
}
.footer__col-links .text-red:hover {
  color: var(--hellhound-red);
}
.footer__badges {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  justify-content: center;
  padding: var(--space-lg) 0;
  border-top: 1px solid var(--border-glass);
  margin-bottom: var(--space-lg);
}
.footer__copyright {
  text-align: center;
  font-size: 13px;
  color: var(--text-tertiary);
}

/* --- PAGE HERO (subpages) --- */
.page-hero {
  position: relative;
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding-top: var(--nav-height);
}
.page-hero__bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}
.page-hero__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.page-hero__overlay {
  display: none;
}

/* Video hero variant */
.page-hero--video { min-height: 70vh; }
.page-hero__video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.6s ease;
}
.page-hero__video.video-ready {
  opacity: 1;
}
@media (max-width: 768px) {
  #aiHeroVideo {
    object-position: center 20% !important;
  }
}
.page-hero__fade-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000;
  opacity: 0;
  z-index: 1;
  pointer-events: none;
  transition: opacity 1.2s ease;
}
.page-hero__fade-overlay--active {
  opacity: 1;
}
.page-hero__gradient-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 40%;
  background: linear-gradient(to top, #000 0%, transparent 100%);
  z-index: 1;
  pointer-events: none;
}

.page-hero__content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 800px;
  padding: var(--space-2xl) var(--space-lg);
}
.page-hero__content h1 {
  text-shadow: 0 0 20px #000, 0 0 40px #000, 0 2px 4px #000;
}
.page-hero__content .hero__sub,
.page-hero__content p {
  text-shadow: 0 0 16px #000, 0 0 32px #000, 0 1px 3px #000;
}
/* Hero system label — capability page codename above h1 */
.hero-system-label {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: clamp(13px, 1.6vw, 16px);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.85);
  padding: 10px 24px;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 100px;
  background: rgba(255,255,255,0.06);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  text-shadow: 0 0 20px #000, 0 0 40px #000;
  margin-bottom: var(--space-lg);
  transition: border-color 0.3s, background 0.3s;
}
.hero-system-label:hover {
  border-color: rgba(255,255,255,0.3);
  background: rgba(255,255,255,0.09);
}
.hero-system-label--red {
  color: var(--hellhound-red);
  border-color: rgba(220,38,38,0.3);
  background: rgba(220,38,38,0.06);
}
.hero-system-label--red:hover {
  border-color: rgba(220,38,38,0.5);
  background: rgba(220,38,38,0.1);
}

/* --- CAPABILITY PAGE COMPONENTS --- */
.cap-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-lg);
}
@media (max-width: 768px) {
  .cap-grid { grid-template-columns: 1fr; }
}
.cap-card {
  padding: var(--space-xl);
  border-left: 3px solid var(--brand-ember);
}
.cap-card:hover {
  box-shadow: 0 0 25px rgba(232, 100, 44, 0.08);
}
.cap-card__number {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--brand-ember);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: var(--space-sm);
}
.cap-card__title {
  font-size: 18px;
  font-weight: 600;
  color: #fff;
  margin-bottom: var(--space-sm);
}
.cap-card__desc {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* Pipeline flow */
.cap-flow {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-lg);
  max-width: 960px;
  margin: var(--space-2xl) auto 0;
}
@media (max-width: 768px) {
  .cap-flow { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .cap-flow { grid-template-columns: 1fr; }
}
.cap-flow-step {
  text-align: center;
  padding: var(--space-lg);
}
.cap-flow-step__number {
  font-family: var(--font-mono);
  font-size: 28px;
  font-weight: 700;
  color: var(--brand-ember);
  margin-bottom: var(--space-sm);
}
.cap-flow-step__title {
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  margin-bottom: var(--space-xs);
}
.cap-flow-step__desc {
  font-size: 13px;
  color: var(--text-tertiary);
  line-height: 1.6;
}

/* Stat row */
.cap-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-lg);
  max-width: 800px;
  margin: var(--space-2xl) auto 0;
}
@media (max-width: 640px) {
  .cap-stats { grid-template-columns: 1fr; }
}
.cap-stat {
  text-align: center;
  padding: var(--space-lg);
}
.cap-stat__value {
  font-family: var(--font-mono);
  font-size: 32px;
  font-weight: 700;
  color: var(--brand-ember);
  margin-bottom: var(--space-xs);
}
.cap-stat__label {
  font-size: 14px;
  color: var(--text-tertiary);
  line-height: 1.5;
}

/* Capability callout box */
.cap-callout {
  max-width: 900px;
  margin: 0 auto;
  padding: var(--space-2xl);
  border-left: 3px solid var(--brand-ember);
}
.cap-callout__label {
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--brand-ember);
}
.cap-callout__title {
  font-size: 22px;
  font-weight: 600;
  margin: var(--space-sm) 0 var(--space-md);
}
.cap-callout__desc {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.7;
}
.cap-callout__desc + .cap-callout__desc {
  margin-top: var(--space-md);
}

/* Section label - ember variant */
.section-label--ember {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--brand-ember);
  margin-bottom: var(--space-md);
  display: block;
}

/* --- SECURITY LAYERS STACK --- */
.security-layers {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  max-width: 900px;
  margin: 0 auto;
}
.security-layer {
  position: relative;
  padding-left: var(--space-xl);
}
.security-layer::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  border-radius: 4px;
}
.security-layer[data-layer="1"]::before { background: #3b82f6; }
.security-layer[data-layer="2"]::before { background: #6366f1; }
.security-layer[data-layer="3"]::before { background: #8b5cf6; }
.security-layer[data-layer="4"]::before { background: #a855f7; }
.security-layer[data-layer="5"]::before { background: #d97706; }
.security-layer[data-layer="6"]::before { background: var(--brand-ember); }
.security-layer__number {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-tertiary);
  margin-bottom: var(--space-xs);
}
.security-layer__title {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: var(--space-sm);
}
.security-layer__desc {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* --- HELL HOUND CALLOUT --- */
.hellhound-callout {
  display: flex;
  gap: var(--space-xl);
  align-items: flex-start;
  border-left: 4px solid var(--hellhound-red);
  box-shadow: 0 0 40px var(--hellhound-glow);
}
.hellhound-callout__badge {
  flex-shrink: 0;
  width: 80px;
  height: 80px;
  border-radius: 12px;
  overflow: hidden;
}
.hellhound-callout__badge img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  mix-blend-mode: lighten;
}
.hellhound-callout__codename {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--hellhound-red);
  margin-bottom: var(--space-xs);
}
.hellhound-callout__title {
  font-size: 22px;
  font-weight: 600;
  margin-bottom: var(--space-sm);
}
.hellhound-callout__desc {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: var(--space-md);
}
.hellhound-callout__cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 500;
  color: var(--hellhound-red);
  transition: gap 0.2s;
}
.hellhound-callout__cta:hover {
  gap: 10px;
}

/* --- BLACKSIEGE SECTION --- */
.blacksiege-details {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  margin-top: var(--space-md);
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-tertiary);
  line-height: 1.6;
}
.blacksiege-details li::before {
  content: '• ';
  color: var(--brand-ember);
}

/* --- COMPLIANCE POSTURE GRID --- */
.compliance-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-md);
}
.compliance-item {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  padding: var(--space-lg);
}
.compliance-item__framework {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}
.compliance-item__status {
  display: inline-flex;
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.compliance-item__status--green {
  background: rgba(34,197,94,0.12);
  color: var(--success);
}
.compliance-item__status--amber {
  background: rgba(232,100,44,0.12);
  color: var(--brand-ember);
}
.compliance-item__status--blue {
  background: rgba(59,130,246,0.12);
  color: #3b82f6;
}
.compliance-item__notes {
  font-size: 13px;
  color: var(--text-tertiary);
  line-height: 1.5;
}

/* --- AI ARCHITECTURE DIAGRAM --- */
.arch-diagram {
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-width: 800px;
  margin: 0 auto;
}
.arch-layer {
  border-left: 4px solid var(--brand-ember);
  padding: var(--space-md) var(--space-lg);
  transition: all 0.3s ease;
  cursor: default;
}
.arch-layer:hover {
  background: var(--surface-glass-hover);
  border-color: var(--brand-ember-hot);
}
.arch-layer__label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--brand-ember);
  margin-bottom: 2px;
}
.arch-layer__name {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
}
.arch-layer__desc {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 4px;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, opacity 0.3s ease;
  opacity: 0;
}
.arch-layer:hover .arch-layer__desc {
  max-height: 80px;
  opacity: 1;
}

/* --- AI PILLAR CARDS --- */
.pillar-card {
  padding: var(--space-2xl);
}
.pillar-card__icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: var(--brand-ember-glow);
  margin-bottom: var(--space-md);
}
.pillar-card__icon svg {
  width: 24px;
  height: 24px;
  color: var(--brand-ember);
}
.pillar-card__headline {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: var(--space-sm);
}
.pillar-card__desc {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: var(--space-md);
}
.pillar-card__compliance {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
}
.pillar-card__compliance .badge-pill {
  font-size: 10px;
  padding: 4px 10px;
  background: rgba(232,100,44,0.06);
  border-color: rgba(232,100,44,0.15);
  color: var(--brand-ember);
}
.pillar-card__why {
  margin-top: var(--space-md);
  padding: var(--space-sm) var(--space-md);
  background: rgba(232,100,44,0.04);
  border-left: 2px solid var(--brand-ember);
  border-radius: 0 6px 6px 0;
  font-size: 13px;
  color: var(--text-secondary);
  font-style: italic;
}

/* --- NERVE STATES --- */
.nerve-states {
  display: flex;
  justify-content: center;
  gap: var(--space-xl);
  align-items: flex-end;
  margin-top: var(--space-xl);
}
.nerve-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
}
.nerve-state__box {
  border: 1px solid var(--border-glass);
  border-radius: 8px;
  background: var(--surface-glass);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-tertiary);
  transition: all 0.3s ease;
}
.nerve-state__box--min {
  width: 40px;
  height: 40px;
}
.nerve-state__box--console {
  width: 140px;
  height: 180px;
}
.nerve-state__box--full {
  width: 220px;
  height: 240px;
}
.nerve-state__box:hover {
  border-color: var(--brand-ember);
  box-shadow: 0 0 20px var(--brand-ember-glow);
}
.nerve-state__label {
  font-size: 12px;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.nerve-arrow {
  display: flex;
  align-items: center;
  color: var(--text-tertiary);
  font-size: 24px;
  margin-bottom: 30px;
}

/* --- STATS ROW (AI page) --- */
.stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-lg);
}
.stat-card {
  text-align: center;
  padding: var(--space-xl);
}
.stat-card__value {
  font-family: var(--font-mono);
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 700;
  color: var(--brand-ember);
  margin-bottom: var(--space-xs);
}
.stat-card__label {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.4;
}

/* --- FRAMEWORK ALIGNMENT GRID (AI page) --- */
.framework-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-md);
}
.framework-item {
  padding: var(--space-lg);
}
.framework-item__name {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  color: var(--brand-ember);
  margin-bottom: var(--space-xs);
}
.framework-item__desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* --- RESPONSIVE: Subpage additions --- */
@media (max-width: 1023px) {
  .compliance-grid {
    grid-template-columns: 1fr;
  }
  .framework-grid {
    grid-template-columns: 1fr;
  }
  .stats-row {
    grid-template-columns: repeat(2, 1fr);
  }
  .nerve-states {
    flex-wrap: wrap;
  }
  .hellhound-callout {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .contact-layout {
    grid-template-columns: 1fr !important;
  }
}
@media (max-width: 639px) {
  .stats-row {
    grid-template-columns: 1fr;
  }
  .nerve-state__box--full {
    width: 180px;
    height: 200px;
  }
  .nerve-state__box--console {
    width: 120px;
    height: 150px;
  }
  .form-row {
    grid-template-columns: 1fr !important;
  }
}

/* --- ANIMATION: Fade in up --- */
.fade-up {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* --- RESPONSIVE: Tablet (640-1023px) --- */
@media (max-width: 1023px) {
  .nav__links { display: none; }
  .nav__hamburger { display: flex; position: absolute; right: var(--space-lg); }

  .sys-row {
    grid-template-columns: 32px 110px 1fr auto;
    gap: 0 var(--space-md);
  }
  .tiles-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  /* tiers and why-now removed from homepage */
  .footer__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* --- RESPONSIVE: Mobile (0-639px) --- */
@media (max-width: 639px) {
  section {
    padding: var(--space-3xl) 0;
  }
  .container {
    padding: 0 var(--space-md);
  }
  .glass-card {
    padding: 20px;
  }
  .sys-row {
    grid-template-columns: 28px 1fr auto;
    padding: var(--space-md) var(--space-sm);
  }
  .sys-row__codename {
    font-size: 12px;
  }
  .sys-row__title {
    display: none;
  }
  .sys-row__desc {
    padding-left: calc(28px + var(--space-md));
  }
  .sys-row:hover .sys-row__desc {
    padding-left: calc(28px + var(--space-md));
  }
  .tiles-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .tile {
    aspect-ratio: auto;
    min-height: 140px;
  }
  .hero__cta {
    flex-direction: column;
    align-items: center;
  }
  .cta-group {
    flex-direction: column;
    align-items: center;
  }
  .footer__grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
   HOMEPAGE: Core Systems — Premium card grid
   ============================================================ */
.section-systems {
  background: var(--black);
}
.section-header-centered {
  text-align: center;
  margin-bottom: var(--space-3xl);
}
.section-headline-lg {
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: var(--space-md);
}
.section-sub-centered {
  color: var(--text-secondary);
  font-size: 18px;
  max-width: 640px;
  margin: 0 auto;
  line-height: 1.6;
}

.sys-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-lg);
}
.sys-card {
  display: flex;
  flex-direction: column;
  background: var(--surface-glass);
  border: 1px solid var(--border-glass);
  border-radius: 16px;
  overflow: hidden;
  text-decoration: none;
  color: var(--text-primary);
  transition: transform 0.4s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}
.sys-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-glass-hover);
  box-shadow: 0 16px 48px rgba(0,0,0,0.5);
}
.sys-card__img-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
}
.sys-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}
.sys-card:hover .sys-card__img {
  transform: scale(1.06);
}
/* No overlay tints on photos — images shown at full quality */
.sys-card__body {
  padding: var(--space-xl) var(--space-xl) var(--space-2xl);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  flex: 1;
}
.sys-card__codename {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--brand-ember);
}
.sys-card__codename--red {
  color: var(--hellhound-red);
}
.sys-card__title {
  font-size: 20px;
  font-weight: 600;
  line-height: 1.25;
}
.sys-card__desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.65;
  flex: 1;
}
.sys-card__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--brand-ember);
  margin-top: var(--space-sm);
  transition: gap 0.2s ease;
}
.sys-card:hover .sys-card__link {
  gap: 10px;
}
.sys-card__link svg {
  transition: transform 0.2s ease;
}
.sys-card:hover .sys-card__link svg {
  transform: translateX(2px);
}
.sys-card__link--red {
  color: var(--hellhound-red);
}

/* Hell Hound card special treatment */
.sys-card--hellhound {
  border-color: rgba(220,38,38,0.2);
}
.sys-card--hellhound:hover {
  border-color: rgba(220,38,38,0.4);
  box-shadow: 0 16px 48px rgba(220,38,38,0.15), 0 0 60px rgba(220,38,38,0.08);
}

/* ============================================================
   STACKED DECK — Core Systems (scroll-pinned cards)
   ============================================================ */
/* ---- DECK: Base — sticky stacking at ALL sizes ---- */
.deck {
  padding: var(--space-3xl) 0 0;
  position: relative;
  overflow: clip;
}
.deck__header {
  text-align: center;
  margin-bottom: var(--space-2xl);
}
.deck__cards {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 var(--space-md) 30vh;
}
.deck__card {
  display: flex;
  flex-direction: column;
  position: sticky;
  top: calc(60px + var(--i, 0) * 22px);
  height: 420px;
  margin-bottom: 40px;
  border-radius: 14px;
  overflow: hidden;
  background: var(--black-elevated);
  border: 1px solid var(--border-glass);
  text-decoration: none;
  color: var(--text-primary);
  box-shadow: 0 4px 32px rgba(0,0,0,0.4), 0 0 0 1px rgba(255,255,255,0.03) inset;
  transform-origin: center top;
  will-change: transform;
  z-index: calc(var(--i, 0) + 1);
}
.deck__card:last-child {
  margin-bottom: 0;
}
.deck__card-img {
  position: relative;
  overflow: hidden;
  height: 180px;
  width: 100%;
  flex-shrink: 0;
}
.deck__card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.deck__card-img::after {
  display: none;
}
.deck__card-body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 20px 22px 24px;
  position: relative;
  flex: 1;
  overflow: hidden;
}
.deck__card-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}
.deck__card-num {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 400;
  color: var(--text-tertiary);
  letter-spacing: 0.05em;
  opacity: 0.6;
}
.deck__card-codename {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--brand-ember);
  text-transform: uppercase;
}
.deck__card--hellhound .deck__card-codename {
  color: var(--hellhound-red);
}
.deck__card-title {
  font-size: 20px;
  font-weight: 700;
  line-height: 1.15;
  color: var(--text-primary);
  margin: 0 0 14px;
  letter-spacing: -0.01em;
}
.deck__card-desc {
  font-size: 14px;
  line-height: 1.7;
  color: var(--text-secondary);
  margin: 0 0 20px;
}
.deck__card-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--brand-ember);
}
.deck__card-cta svg {
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.deck__card--hellhound .deck__card-cta {
  color: var(--hellhound-red);
}
.deck__card--hellhound {
  border-color: rgba(220,38,38,0.15);
}
/* Deck progress — hidden by default */
.deck__progress {
  display: none;
}

/* ---- DECK: Tablet (640px+) ---- */
@media (min-width: 640px) {
  .deck__cards {
    padding: 0 var(--space-lg);
  }
  .deck__card {
    margin-bottom: var(--space-lg);
    border-radius: 16px;
  }
  .deck__card-img {
    height: 260px;
  }
  .deck__card-body {
    padding: 28px 32px 32px;
  }
  .deck__card-title {
    font-size: 24px;
    margin-bottom: 18px;
  }
  .deck__card-desc {
    font-size: 15px;
    line-height: 1.75;
    margin-bottom: 28px;
  }
  .deck__card-meta {
    margin-bottom: 20px;
  }
  .deck__card-cta {
    font-size: 14px;
  }
}

/* ---- DECK: Desktop (1024px+) — grid layout + larger sizes ---- */
@media (min-width: 1024px) {
  .deck__cards {
    padding-bottom: 15vh;
  }
  .deck__card {
    top: calc(80px + var(--i, 0) * 28px);
    display: grid;
    grid-template-columns: 1.15fr 1fr;
    height: 500px;
    margin-bottom: 48px;
    border-radius: 20px;
  }
  .deck__card-body {
    padding: 52px 48px;
  }
  .deck__card-img {
    height: auto;
  }
  .deck__card-img img {
    transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  }
  .deck__card:hover .deck__card-img img {
    transform: scale(1.04);
  }
  .deck__card-title {
    font-size: clamp(24px, 2.4vw, 34px);
  }
  .deck__card-desc {
    margin-bottom: 32px;
    max-width: 420px;
  }
  .deck__card-cta {
    transition: gap 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  }
  .deck__card:hover .deck__card-cta {
    gap: 14px;
  }
  .deck__card:hover .deck__card-cta svg {
    transform: translateX(3px);
  }
  .deck__card--hellhound:hover {
    border-color: rgba(220,38,38,0.35);
    box-shadow: 0 4px 32px rgba(0,0,0,0.4), 0 0 80px rgba(220,38,38,0.06);
  }
  /* Progress indicator — desktop only */
  .deck__progress {
    display: flex;
    position: fixed;
    right: 28px;
    top: 50%;
    transform: translateY(-50%);
    flex-direction: column;
    align-items: center;
    gap: 0;
    z-index: 100;
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
  }
  .deck__progress.is-visible {
    opacity: 1;
    pointer-events: auto;
  }
}
.deck__progress-track {
  width: 2px;
  height: 180px;
  background: rgba(255,255,255,0.06);
  border-radius: 1px;
  position: relative;
  overflow: hidden;
}
.deck__progress-fill {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 0%;
  background: var(--brand-ember);
  border-radius: 1px;
  transition: height 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.deck__progress-count {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-tertiary);
  letter-spacing: 0.05em;
  margin-top: 12px;
  white-space: nowrap;
  transition: color 0.3s ease;
}

/* ============================================================
   HOMEPAGE: Industries — Typographic row grid
   ============================================================ */
.section-industries {
  background: var(--black);
}
.ind-grid {
  display: flex;
  flex-direction: column;
  border-top: 1px solid rgba(255,255,255,0.06);
  max-width: 900px;
  margin: 0 auto;
}
.ind-row {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  align-items: center;
  gap: var(--space-xl);
  padding: var(--space-lg) var(--space-md);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  text-decoration: none;
  color: var(--text-primary);
  transition: background 0.3s ease;
  position: relative;
}
.ind-row::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--brand-ember);
  opacity: 0;
  transition: opacity 0.3s ease;
}
.ind-row:hover {
  background: rgba(232,100,44,0.03);
}
.ind-row:hover::before {
  opacity: 1;
}
.ind-row__name {
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
  transition: color 0.3s ease;
}
.ind-row:hover .ind-row__name {
  color: var(--brand-ember);
}
.ind-row__desc {
  font-size: 14px;
  color: var(--text-tertiary);
  line-height: 1.5;
  transition: color 0.3s ease;
}
.ind-row:hover .ind-row__desc {
  color: var(--text-secondary);
}
.ind-row__arrow {
  color: rgba(255,255,255,0.1);
  display: flex;
  align-items: center;
  transition: color 0.3s ease, transform 0.3s ease;
}
.ind-row:hover .ind-row__arrow {
  color: var(--brand-ember);
  transform: translateX(4px);
}


/* ============================================================
   HOMEPAGE: Bottom CTA — Full-width with background
   ============================================================ */
.section-cta {
  position: relative;
  padding: var(--space-6xl) 0;
  text-align: center;
}
.section-cta__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.section-cta__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.section-cta__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.3), rgba(0,0,0,0.5));
}
.section-cta__inner {
  max-width: 640px;
  margin: 0 auto;
}
.section-cta__headline {
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 700;
  margin-bottom: var(--space-md);
}
.section-cta__sub {
  font-size: 18px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: var(--space-xl);
}

/* ============================================================
   RESPONSIVE: New homepage sections
   ============================================================ */
@media (max-width: 1023px) {
  .sys-cards {
    grid-template-columns: repeat(2, 1fr);
  }
  .ind-row {
    grid-template-columns: 1fr auto;
  }
  .ind-row__desc {
    display: none;
  }
}
@media (max-width: 639px) {
  .sys-cards {
    grid-template-columns: 1fr;
  }
  .sys-card__body {
    padding: var(--space-lg) var(--space-lg) var(--space-xl);
  }
  .ind-row {
    padding: var(--space-md) var(--space-sm);
  }
  .ind-row__name {
    font-size: 15px;
  }
  .section-cta {
    padding: var(--space-4xl) 0;
  }
}

/* --- REDUCED MOTION --- */
@media (prefers-reduced-motion: reduce) {
  *:not(.carousel__track), *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .hero__headline .cursor {
    animation: none;
    display: none;
  }
  /* Carousel driven by JS — no CSS animation to override */
  .fade-up {
    opacity: 1;
    transform: none;
  }
  .hero__video,
  .page-hero__video {
    opacity: 1;
  }
  /* glow-canvas removed */
  /* Stacked deck — disable sticky and animations */
  .deck__card {
    position: relative !important;
    top: 0 !important;
    transform: none !important;
    filter: none !important;
  }
  .deck__progress {
    display: none !important;
  }
}

/* ============================================================
   PAGE TRANSITION — Horizontal wipe
   ============================================================ */
.page-transition {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--black);
  z-index: 99999;
  pointer-events: none;
  transform: translateX(-100%);
}
.page-transition.covering {
  transform: translateX(0);
}
.page-transition.wipe-in {
  animation: wipeIn 0.4s cubic-bezier(0.7, 0, 0.3, 1) forwards;
}
.page-transition.wipe-out {
  animation: wipeOut 0.4s cubic-bezier(0.7, 0, 0.3, 1) forwards;
}
@keyframes wipeIn {
  from { transform: translateX(-100%); }
  to   { transform: translateX(0); }
}
@keyframes wipeOut {
  from { transform: translateX(0); }
  to   { transform: translateX(100%); }
}

/* ============================================================
   CIRCUIT SCHEMATIC DESIGN SYSTEM
   PCB-trace aesthetic for capability page enhancements
   ============================================================ */

/* --- CIRCUIT TRACE ANIMATION --- */
@keyframes tracePulse {
  0%   { stroke-dashoffset: 200; }
  100% { stroke-dashoffset: 0; }
}
@keyframes nodeGlow {
  0%, 100% { box-shadow: 0 0 0 0 rgba(232,100,44,0); }
  50%      { box-shadow: 0 0 12px 2px rgba(232,100,44,0.15); }
}
@keyframes dotPulse {
  0%, 100% { opacity: 0.4; }
  50%      { opacity: 1; }
}

/* --- ARCHITECTURE STACK (vertical layered diagram) --- */
.arch-stack {
  display: flex;
  flex-direction: column;
  gap: 2px;
  position: relative;
  padding: var(--space-lg) 0;
}
.arch-stack__layer {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: var(--space-md);
  align-items: center;
  padding: var(--space-md) var(--space-lg);
  background: var(--surface-glass);
  border: 1px solid var(--border-glass);
  border-left: 3px solid rgba(232,100,44,0.3);
  border-radius: 6px;
  transition: border-color 0.2s, transform 0.2s, background 0.2s;
  position: relative;
}
.arch-stack__layer:hover {
  border-left-color: var(--brand-ember);
  background: var(--surface-glass-hover);
  transform: translateY(-2px);
}
.arch-stack__layer-id {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  color: var(--brand-ember);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  opacity: 0.8;
}
.arch-stack__layer-content {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.arch-stack__layer-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
}
.arch-stack__layer-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}
/* Vertical trace connector between layers */
.arch-stack__connector {
  width: 2px;
  height: 12px;
  background: rgba(232,100,44,0.2);
  margin: 0 auto;
  position: relative;
}
.arch-stack__connector::after {
  content: '';
  position: absolute;
  bottom: -3px;
  left: 50%;
  transform: translateX(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(232,100,44,0.4);
}
/* Layer depth color ramp (top lighter → bottom deeper) */
.arch-stack__layer:nth-child(1)  { border-left-color: rgba(232,100,44,0.2); }
.arch-stack__layer:nth-child(3)  { border-left-color: rgba(232,100,44,0.3); }
.arch-stack__layer:nth-child(5)  { border-left-color: rgba(232,100,44,0.4); }
.arch-stack__layer:nth-child(7)  { border-left-color: rgba(232,100,44,0.5); }
.arch-stack__layer:nth-child(9)  { border-left-color: rgba(232,100,44,0.6); }
.arch-stack__layer:nth-child(11) { border-left-color: rgba(232,100,44,0.7); }

/* Hell Hound red variant */
.arch-stack--red .arch-stack__layer {
  border-left-color: rgba(220,38,38,0.3);
}
.arch-stack--red .arch-stack__layer:hover {
  border-left-color: var(--hellhound-red);
}
.arch-stack--red .arch-stack__layer-id {
  color: var(--hellhound-red);
}
.arch-stack--red .arch-stack__connector {
  background: rgba(220,38,38,0.2);
}
.arch-stack--red .arch-stack__connector::after {
  background: rgba(220,38,38,0.4);
}

/* --- INTEGRATION MAP (central hub + radial spokes) --- */
.integration-map {
  position: relative;
  width: 100%;
  max-width: 700px;
  margin: 0 auto;
  aspect-ratio: 4 / 3;
}
.integration-map__svg {
  width: 100%;
  height: 100%;
}
.integration-map__svg text {
  font-family: var(--font-mono);
  fill: var(--text-secondary);
  font-size: 10px;
}
.integration-map__svg .hub-label {
  fill: var(--brand-ember);
  font-weight: 700;
  font-size: 12px;
}
.integration-map__svg .spoke-line {
  stroke: rgba(232,100,44,0.25);
  stroke-width: 1.5;
  stroke-dasharray: 6 4;
  animation: tracePulse 3s linear infinite;
}
.integration-map__svg .spoke-line--red {
  stroke: rgba(220,38,38,0.25);
}
.integration-map__svg .hub-node {
  fill: rgba(232,100,44,0.12);
  stroke: var(--brand-ember);
  stroke-width: 1.5;
}
.integration-map__svg .ext-node {
  fill: var(--surface-glass);
  stroke: rgba(255,255,255,0.15);
  stroke-width: 1;
}
.integration-map__svg .protocol-label {
  font-size: 8px;
  fill: rgba(255,255,255,0.4);
  font-family: var(--font-mono);
}
/* Fallback list for small screens */
.integration-map__list {
  display: none;
  flex-direction: column;
  gap: var(--space-sm);
}
.integration-map__list-item {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-md);
  background: var(--surface-glass);
  border: 1px solid var(--border-glass);
  border-left: 3px solid rgba(232,100,44,0.3);
  border-radius: 6px;
  font-size: 14px;
  color: var(--text-primary);
}
.integration-map__list-item .protocol {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-tertiary);
  margin-left: auto;
}
@media (max-width: 639px) {
  .integration-map { display: none; }
  .integration-map__list { display: flex; }
}

/* --- METRIC DASHBOARD (stat cards) --- */
.metric-dashboard {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-md);
}
.metric-card {
  background: var(--surface-glass);
  border: 1px solid var(--border-glass);
  border-radius: 10px;
  padding: var(--space-lg);
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: border-color 0.2s, transform 0.2s;
  background-image: radial-gradient(circle, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 20px 20px;
}
.metric-card:hover {
  border-color: var(--border-glass-hover);
  transform: translateY(-2px);
}
.metric-card__value {
  font-family: var(--font-mono);
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.1;
  margin-bottom: var(--space-xs);
}
.metric-card__label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: var(--space-sm);
}
.metric-card__context {
  font-size: 12px;
  color: var(--text-tertiary);
  line-height: 1.4;
}
.metric-card__dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--success);
  margin-right: 4px;
  animation: dotPulse 2s ease infinite;
}
/* Red variant */
.metric-card--red {
  border-left: 3px solid rgba(220,38,38,0.3);
}
.metric-card--red .metric-card__value {
  color: var(--hellhound-red);
}
.metric-card--red .metric-card__dot {
  background: var(--hellhound-red);
}
@media (max-width: 767px) {
  .metric-dashboard {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 479px) {
  .metric-dashboard {
    grid-template-columns: 1fr;
  }
}

/* --- COMPLIANCE GRID (matrix table) --- */
.compliance-matrix {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}
.compliance-matrix th,
.compliance-matrix td {
  padding: var(--space-sm) var(--space-md);
  text-align: left;
  border-bottom: 1px solid var(--border-glass);
  font-size: 14px;
}
.compliance-matrix th {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-tertiary);
  background: rgba(255,255,255,0.02);
}
.compliance-matrix td {
  color: var(--text-secondary);
}
.compliance-matrix tr:hover td {
  background: rgba(255,255,255,0.02);
}
.compliance-matrix .framework-id {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-primary);
  font-weight: 500;
}
.compliance-matrix .status-aligned {
  color: var(--success);
}
.compliance-matrix .status-progress {
  color: #eab308;
}
.compliance-matrix .status-planned {
  color: var(--text-tertiary);
}
/* Red variant */
.compliance-matrix--red th {
  color: rgba(220,38,38,0.6);
}
.compliance-matrix--red tr:hover td {
  background: rgba(220,38,38,0.04);
}
@media (max-width: 639px) {
  .compliance-matrix,
  .stack-table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .compliance-matrix th:nth-child(3),
  .compliance-matrix td:nth-child(3) {
    display: none;
  }
  .compliance-matrix th,
  .compliance-matrix td,
  .stack-table th,
  .stack-table td {
    padding: var(--space-xs) var(--space-sm);
    font-size: 12px;
  }
  .compliance-matrix .framework-id {
    font-size: 11px;
  }
  .pipeline__stage,
  .data-flow__node {
    min-width: 80px;
    padding: var(--space-sm) var(--space-xs);
  }
  .pipeline__stage-name,
  .data-flow__node-name {
    font-size: 11px;
  }
}

/* --- TECH STACK TABLE --- */
.stack-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}
.stack-table th,
.stack-table td {
  padding: var(--space-sm) var(--space-md);
  text-align: left;
  border-bottom: 1px solid var(--border-glass);
  font-size: 14px;
}
.stack-table th {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-tertiary);
  background: rgba(255,255,255,0.02);
}
.stack-table td:first-child {
  color: var(--text-secondary);
  font-weight: 500;
  width: 35%;
}
.stack-table td:last-child {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-primary);
}
.stack-table tr:hover td {
  background: rgba(255,255,255,0.02);
}

/* --- CROSS-SYSTEM MESH (7-node constellation) --- */
.system-mesh {
  position: relative;
  width: 100%;
  max-width: 700px;
  margin: 0 auto;
  aspect-ratio: 16 / 9;
}
.system-mesh__svg {
  width: 100%;
  height: 100%;
}
.system-mesh__svg .mesh-line {
  stroke: rgba(255,255,255,0.08);
  stroke-width: 1;
  stroke-dasharray: 4 4;
}
.system-mesh__svg .mesh-line--active {
  stroke: rgba(232,100,44,0.3);
  stroke-width: 1.5;
  animation: tracePulse 4s linear infinite;
}
.system-mesh__svg .mesh-node {
  fill: rgba(255,255,255,0.06);
  stroke: rgba(255,255,255,0.2);
  stroke-width: 1;
  transition: fill 0.2s, stroke 0.2s;
}
.system-mesh__svg .mesh-node--current {
  fill: rgba(232,100,44,0.12);
  stroke: var(--brand-ember);
  stroke-width: 2;
  filter: drop-shadow(0 0 8px rgba(232,100,44,0.3));
}
.system-mesh__svg .mesh-node--red {
  fill: rgba(220,38,38,0.08);
  stroke: rgba(220,38,38,0.5);
}
.system-mesh__svg .mesh-label {
  font-family: var(--font-mono);
  font-size: 9px;
  fill: rgba(255,255,255,0.4);
  text-anchor: middle;
}
.system-mesh__svg .mesh-label--current {
  fill: var(--brand-ember);
  font-weight: 700;
  font-size: 10px;
}
/* Fallback for mobile */
.system-mesh__list {
  display: none;
  flex-wrap: wrap;
  gap: var(--space-sm);
  justify-content: center;
}
.system-mesh__tag {
  padding: 6px 14px;
  border-radius: 20px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.03em;
  background: var(--surface-glass);
  border: 1px solid var(--border-glass);
  color: var(--text-secondary);
}
.system-mesh__tag--current {
  border-color: var(--brand-ember);
  color: var(--brand-ember);
  background: rgba(232,100,44,0.08);
}
.system-mesh__tag--red {
  border-color: rgba(220,38,38,0.4);
  color: var(--hellhound-red);
}
@media (max-width: 639px) {
  .system-mesh { display: none; }
  .system-mesh__list { display: flex; }
}

/* --- DEVSECOPS PIPELINE DIAGRAM --- */
.pipeline {
  display: flex;
  align-items: center;
  gap: 0;
  overflow-x: auto;
  padding: var(--space-md) 0;
  -webkit-overflow-scrolling: touch;
}
.pipeline__stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-xs);
  min-width: 100px;
  padding: var(--space-md) var(--space-sm);
  background: var(--surface-glass);
  border: 1px solid var(--border-glass);
  border-radius: 8px;
  text-align: center;
  transition: border-color 0.2s, transform 0.2s;
  flex-shrink: 0;
}
.pipeline__stage:hover {
  border-color: var(--border-glass-hover);
  transform: translateY(-2px);
}
.pipeline__stage-id {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.pipeline__stage-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}
.pipeline__stage-type {
  font-size: 11px;
  color: var(--text-secondary);
}
/* Red pipeline */
.pipeline--red .pipeline__stage {
  border-left: 2px solid rgba(220,38,38,0.3);
}
.pipeline--red .pipeline__stage:hover {
  border-left-color: var(--hellhound-red);
}
.pipeline--red .pipeline__stage-id {
  color: rgba(220,38,38,0.6);
}
.pipeline__arrow {
  flex-shrink: 0;
  width: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.15);
}
.pipeline__arrow svg {
  width: 16px;
  height: 16px;
}
.pipeline--red .pipeline__arrow {
  color: rgba(220,38,38,0.3);
}

/* --- SECTION HEADERS FOR CAPABILITY ENHANCEMENTS --- */
.cap-section-header {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-bottom: var(--space-xl);
}
.cap-section-header__line {
  flex: 0 0 40px;
  height: 1px;
  background: rgba(232,100,44,0.3);
}
.cap-section-header__label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--brand-ember);
  white-space: nowrap;
}
.cap-section-header--red .cap-section-header__line {
  background: rgba(220,38,38,0.3);
}
.cap-section-header--red .cap-section-header__label {
  color: var(--hellhound-red);
}

/* --- DATA FLOW PIPELINE (horizontal animated) --- */
.data-flow {
  display: flex;
  align-items: stretch;
  gap: 0;
  overflow-x: auto;
  padding: var(--space-md) 0;
  -webkit-overflow-scrolling: touch;
}
.data-flow__node {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  min-width: 120px;
  padding: var(--space-lg) var(--space-md);
  background: var(--surface-glass);
  border: 1px solid var(--border-glass);
  border-radius: 10px;
  text-align: center;
  flex-shrink: 0;
  transition: border-color 0.2s;
  background-image: radial-gradient(circle, rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 16px 16px;
}
.data-flow__node:hover {
  border-color: rgba(232,100,44,0.3);
}
.data-flow__node-label {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.data-flow__node-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}
.data-flow__connector {
  flex-shrink: 0;
  width: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.data-flow__connector::before {
  content: '';
  width: 100%;
  height: 2px;
  background: rgba(232,100,44,0.2);
  position: absolute;
}
.data-flow__connector::after {
  content: '';
  width: 0;
  height: 0;
  border-left: 6px solid rgba(232,100,44,0.4);
  border-top: 4px solid transparent;
  border-bottom: 4px solid transparent;
  position: absolute;
  right: 0;
}

/* --- GLASS CARD ENHANCEMENTS FOR CAPABILITY SECTIONS --- */
.cap-enhance {
  padding: var(--space-3xl) 0;
}
.cap-enhance .glass-card {
  padding: var(--space-2xl);
  margin-bottom: var(--space-xl);
}
.cap-enhance .glass-card:last-child {
  margin-bottom: 0;
}

/* Scrollbar styling for overflow containers */
.pipeline::-webkit-scrollbar,
.data-flow::-webkit-scrollbar {
  height: 4px;
}
.pipeline::-webkit-scrollbar-track,
.data-flow::-webkit-scrollbar-track {
  background: transparent;
}
.pipeline::-webkit-scrollbar-thumb,
.data-flow::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,0.1);
  border-radius: 2px;
}

/* --- REDUCED MOTION OVERRIDES FOR CIRCUIT SYSTEM --- */
@media (prefers-reduced-motion: reduce) {
  .integration-map__svg .spoke-line,
  .system-mesh__svg .mesh-line--active,
  .metric-card__dot {
    animation: none;
  }
}

/* ============================================================
   MOBILE FIX: Legal pages — prevent word/sentence breakage
   ============================================================ */
@media (max-width: 768px) {
  .glass-card p,
  .glass-card li,
  .glass-card td,
  .glass-card dd {
    overflow-wrap: break-word;
    word-break: break-word;
    -webkit-hyphens: auto;
    hyphens: auto;
  }
  .glass-card {
    padding: var(--space-lg) var(--space-md) !important;
  }
  .container[style*="max-width:800px"] {
    padding-left: var(--space-sm);
    padding-right: var(--space-sm);
  }
}

/* ============================================================
   MOBILE FIX: Carousel — full width, no side lines, untouchable
   ============================================================ */
@media (max-width: 768px) {
  .carousel__container {
    margin: 0;
    padding: 0;
  }
  .carousel__container::before,
  .carousel__container::after {
    display: none;
  }
  .carousel__fade-left,
  .carousel__fade-right {
    display: none;
  }
  .carousel__track {
    pointer-events: none;
    touch-action: none;
    -webkit-user-select: none;
    user-select: none;
  }
  .carousel {
    padding: var(--space-lg) 0;
  }
}

/* ============================================================
   MOBILE FIX: Brand ember — redder on mobile displays
   Mobile screens (especially OLED/LCD with narrower gamuts)
   render #e8642c as orange. Override to a true red.
   ============================================================ */
@media (max-width: 768px) {
  :root {
    --brand-ember: #a81208;
    --brand-ember-glow: rgba(168,18,8,0.22);
    --brand-ember-hot: #bf1a0e;
  }
}
