/* =============================================================
   SYSVEX — v4 · AI Console / Cursor-Anthropic aesthetic
   ============================================================= */

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 72px;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.55;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

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

/* ===== TOKENS ===== */
:root {
  /* Surfaces */
  --bg: #0a0a0b;
  --bg-2: #0f0f11;
  --bg-3: #16161a;
  --bg-4: #1c1c21;
  --bg-input: #0c0c0e;

  /* Lines */
  --line: rgba(255,255,255,0.07);
  --line-2: rgba(255,255,255,0.12);
  --line-3: rgba(255,255,255,0.18);

  /* Text */
  --text: #ededed;
  --text-2: #a6a6ad;
  --text-3: #6d6d75;
  --text-4: #45454c;

  /* Gold (signature) */
  --gold: #d4a554;
  --gold-2: #e0b66e;
  --gold-3: #f0cf94;
  --gold-glow: rgba(212, 165, 84, 0.18);

  /* Status colors */
  --green: #4ade80;
  --red: #f87171;
  --amber: #fbbf24;

  /* Fonts */
  --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', 'IBM Plex Mono', 'SF Mono', Menlo, monospace;

  /* Layout */
  --container: 1240px;
  --container-wide: 1320px;
  --gutter: 24px;

  /* Radii */
  --r: 6px;
  --r-md: 8px;
  --r-lg: 12px;

  /* Easing */
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-snappy: cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== TYPE ===== */
h1, h2, h3, h4 {
  margin: 0;
  font-family: var(--font-sans);
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1.1;
  color: var(--text);
}

h1 {
  font-size: clamp(2.4rem, 4vw, 3.6rem);
  letter-spacing: -0.035em;
  font-weight: 500;
}

h2 {
  font-size: clamp(1.7rem, 2.4vw, 2.2rem);
  letter-spacing: -0.025em;
}

h3 {
  font-size: 1.05rem;
  font-weight: 500;
  letter-spacing: -0.01em;
}

p { margin: 0 0 12px; color: var(--text-2); font-size: 0.95rem; }

p.lead {
  font-size: 1.05rem;
  color: var(--text-2);
  line-height: 1.55;
  max-width: 60ch;
}

a {
  color: var(--text);
  text-decoration: none;
  transition: color 0.18s var(--ease);
}

a:hover { color: var(--gold-2); }

code, .mono, .kbd {
  font-family: var(--font-mono);
  font-feature-settings: 'liga' 1, 'calt' 1;
}

::selection {
  background: var(--gold);
  color: #000;
}

/* ===== LAYOUT ===== */
.wrap {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.wrap-wide { max-width: var(--container-wide); }

.section {
  padding: 96px 0;
  position: relative;
}

.section-tight { padding: 64px 0; }

.section + .section { border-top: 1px solid var(--line); }

/* ===== TECHNICAL LABEL / EYEBROW ===== */
.label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
  font-weight: 500;
}

.label .dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 8px var(--gold-glow);
}

.label .dot.live {
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
  animation: livePulse 2s infinite;
}

@keyframes livePulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.label-gold { color: var(--gold); }

.section-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 32px;
  margin-bottom: 48px;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
}

.section-meta .index { color: var(--gold); }

/* ===== HEADER ===== */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(10, 10, 11, 0.7);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease);
}

.site-header.scrolled {
  background: rgba(10, 10, 11, 0.92);
  border-bottom-color: var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--text);
}

.brand-mark {
  width: 22px;
  height: 22px;
  border-radius: 5px;
  background: var(--bg-3);
  border: 1px solid var(--line-2);
  display: grid;
  place-items: center;
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 11px;
  color: var(--gold);
  position: relative;
  overflow: hidden;
}

.brand-mark::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 30%, var(--gold-glow), transparent 60%);
}

.brand-mark span { position: relative; z-index: 1; }

.main-nav {
  display: flex;
  gap: 2px;
  background: var(--bg-3);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 3px;
}

.main-nav a {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--text-2);
  padding: 6px 12px;
  border-radius: 4px;
  transition: background 0.18s var(--ease), color 0.18s var(--ease);
}

.main-nav a:hover {
  color: var(--text);
  background: var(--bg-4);
}

.main-nav a.active {
  background: var(--bg-4);
  color: var(--gold);
}

.header-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  padding: 8px 14px;
  background: var(--gold);
  color: #000;
  border-radius: var(--r);
  transition: background 0.18s var(--ease), transform 0.18s var(--ease);
}

.header-cta:hover {
  background: var(--gold-2);
  color: #000;
  transform: translateY(-1px);
}

/* Menu mobile */
.menu-toggle {
  display: none;
  width: 36px;
  height: 36px;
  background: var(--bg-3);
  border: 1px solid var(--line-2);
  border-radius: var(--r);
  cursor: pointer;
  position: relative;
}

.menu-toggle span {
  position: absolute;
  left: 9px;
  right: 9px;
  height: 1.5px;
  background: var(--text);
  transition: transform 0.25s var(--ease), opacity 0.25s var(--ease), top 0.25s var(--ease);
}

.menu-toggle span:nth-child(1) { top: 12px; }
.menu-toggle span:nth-child(2) { top: 17px; }
.menu-toggle span:nth-child(3) { top: 22px; }

.menu-toggle.open span:nth-child(1) { top: 17px; transform: rotate(45deg); }
.menu-toggle.open span:nth-child(2) { opacity: 0; }
.menu-toggle.open span:nth-child(3) { top: 17px; transform: rotate(-45deg); }

.mobile-nav {
  display: none;
  position: fixed;
  inset: 60px 0 0;
  background: var(--bg);
  padding: 24px;
  z-index: 99;
}

.mobile-nav.open { display: block; }

.mobile-nav a {
  display: block;
  padding: 14px 0;
  font-family: var(--font-mono);
  font-size: 14px;
  letter-spacing: 0.02em;
  border-bottom: 1px solid var(--line);
}

/* ===== HERO ===== */
.hero {
  padding: 120px 0 80px;
  position: relative;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(circle at 80% 20%, rgba(212, 165, 84, 0.06), transparent 50%),
    radial-gradient(circle at 20% 80%, rgba(212, 165, 84, 0.03), transparent 50%);
}

.hero-grid {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(to right, var(--line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--line) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 90% 70% at 50% 30%, black 30%, transparent);
  -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 30%, black 30%, transparent);
  opacity: 0.5;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 56px;
  align-items: center;
  position: relative;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 10px 5px 6px;
  background: var(--bg-3);
  border: 1px solid var(--line-2);
  border-radius: 100px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-2);
  letter-spacing: 0.02em;
  margin-bottom: 24px;
}

.hero-badge .pill {
  background: var(--gold);
  color: #000;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 100px;
  font-size: 10px;
  letter-spacing: 0.06em;
}

.hero h1 .gold {
  color: var(--gold);
  font-style: normal;
}

.hero-sub {
  font-size: 1.05rem;
  color: var(--text-2);
  margin: 24px 0 32px;
  max-width: 52ch;
  line-height: 1.55;
}

.hero-actions {
  display: flex;
  gap: 12px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}

.hero-meta {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-3);
}

.hero-meta-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.hero-meta-item::before {
  content: '';
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 6px var(--green);
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  padding: 10px 16px;
  border-radius: var(--r);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.18s var(--ease);
  text-decoration: none;
}

.btn-primary {
  background: var(--gold);
  color: #000;
  box-shadow: 0 0 0 0 var(--gold-glow);
}

.btn-primary:hover {
  background: var(--gold-2);
  color: #000;
  transform: translateY(-1px);
  box-shadow: 0 0 0 4px var(--gold-glow);
}

.btn-secondary {
  background: var(--bg-3);
  color: var(--text);
  border-color: var(--line-2);
}

.btn-secondary:hover {
  background: var(--bg-4);
  border-color: var(--line-3);
}

.btn .kbd {
  margin-left: 4px;
  padding: 1px 6px;
  background: rgba(0,0,0,0.2);
  border-radius: 3px;
  font-size: 10px;
  opacity: 0.7;
}

.btn-secondary .kbd { background: var(--bg-4); }

/* ===== TERMINAL ===== */
.terminal {
  background: var(--bg-2);
  border: 1px solid var(--line-2);
  border-radius: var(--r-md);
  font-family: var(--font-mono);
  font-size: 13px;
  overflow: hidden;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 20px 60px -20px rgba(0,0,0,0.8);
  position: relative;
}

.terminal-top {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: rgba(0,0,0,0.3);
  border-bottom: 1px solid var(--line);
}

.terminal-top .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--bg-4);
}

.terminal-top .dot:nth-child(1) { background: #ff5f57; opacity: 0.7; }
.terminal-top .dot:nth-child(2) { background: #ffbd2e; opacity: 0.7; }
.terminal-top .dot:nth-child(3) { background: #28c940; opacity: 0.7; }

.terminal-top .title {
  margin-left: 12px;
  font-size: 11px;
  color: var(--text-3);
  letter-spacing: 0.04em;
}

.terminal-top .status {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--green);
}

.terminal-top .status::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 6px var(--green);
  animation: livePulse 2s infinite;
}

.terminal-body {
  padding: 18px 20px;
  min-height: 280px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.terminal-line {
  display: flex;
  gap: 8px;
  white-space: pre-wrap;
  word-break: break-word;
  line-height: 1.55;
}

.terminal-line .prompt { color: var(--gold); user-select: none; flex-shrink: 0; }
.terminal-line .cmd { color: var(--text); }
.terminal-line .output { color: var(--text-2); padding-left: 16px; }
.terminal-line .comment { color: var(--text-3); }
.terminal-line .ok { color: var(--green); }
.terminal-line .warn { color: var(--amber); }
.terminal-line .err { color: var(--red); }
.terminal-line .key { color: var(--gold-2); }

.cursor {
  display: inline-block;
  width: 8px;
  height: 14px;
  background: var(--gold);
  vertical-align: middle;
  margin-left: 2px;
  animation: blink 1s steps(2) infinite;
}

@keyframes blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

/* ===== METRIC BAR ===== */
.metric-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--bg-2);
  overflow: hidden;
}

.metric {
  padding: 20px 24px;
  border-right: 1px solid var(--line);
  position: relative;
}

.metric:last-child { border-right: none; }

.metric .l {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 8px;
}

.metric .v {
  font-family: var(--font-mono);
  font-size: 1.6rem;
  font-weight: 500;
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1;
}

.metric .v .u {
  font-size: 0.6em;
  color: var(--gold);
  margin-left: 2px;
}

.metric .d {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--green);
  margin-top: 6px;
}

/* ===== CAPABILITY ROWS (technical table) ===== */
.cap-table {
  border-top: 1px solid var(--line);
}

.cap-row {
  display: grid;
  grid-template-columns: 80px 1.2fr 2fr auto;
  gap: 32px;
  padding: 24px 8px;
  align-items: center;
  border-bottom: 1px solid var(--line);
  transition: background 0.2s var(--ease);
  cursor: default;
}

.cap-row:hover {
  background: var(--bg-2);
}

.cap-row:hover .cap-arrow { color: var(--gold); transform: translateX(4px); }
.cap-row:hover .cap-tag { border-color: var(--gold); color: var(--gold); }

.cap-id {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--gold);
  letter-spacing: 0.06em;
}

.cap-name {
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--text);
}

.cap-desc {
  font-size: 0.92rem;
  color: var(--text-2);
  margin: 0;
}

.cap-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.cap-tag {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.04em;
  padding: 3px 8px;
  background: var(--bg-3);
  border: 1px solid var(--line-2);
  border-radius: 3px;
  color: var(--text-2);
  transition: all 0.2s var(--ease);
}

.cap-arrow {
  font-family: var(--font-mono);
  color: var(--text-4);
  transition: transform 0.2s var(--ease), color 0.2s var(--ease);
}

/* ===== FLOW DIAGRAM (4 nodes with live pulse) ===== */
.flow {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  position: relative;
  padding: 32px 0;
}

.flow-node {
  position: relative;
  padding: 20px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  z-index: 2;
  transition: border-color 0.25s var(--ease), transform 0.25s var(--ease);
}

.flow-node:hover {
  border-color: var(--line-3);
  transform: translateY(-2px);
}

.flow-node .step-id {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.flow-node .step-id::before {
  content: '';
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 6px var(--gold-glow);
}

.flow-node h3 {
  font-size: 1rem;
  margin-bottom: 6px;
}

.flow-node p {
  font-size: 0.88rem;
  margin: 0;
  color: var(--text-2);
}

/* Animated line connecting nodes */
.flow-line {
  position: absolute;
  top: 50%;
  left: 5%;
  right: 5%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--line-3) 15%, var(--line-3) 85%, transparent);
  z-index: 1;
  transform: translateY(-50%);
}

.flow-pulse {
  position: absolute;
  top: 50%;
  width: 6px;
  height: 6px;
  background: var(--gold);
  border-radius: 50%;
  box-shadow: 0 0 12px var(--gold), 0 0 24px var(--gold-glow);
  z-index: 3;
  transform: translateY(-50%);
  animation: flowPulse 4.5s linear infinite;
  pointer-events: none;
}

@keyframes flowPulse {
  0%, 100% { left: 5%; opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { left: 95%; opacity: 0; }
}

/* ===== PROBLEM CARDS ===== */
.problem-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.problem-card {
  position: relative;
  padding: 24px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  transition: border-color 0.25s var(--ease), background 0.25s var(--ease);
}

.problem-card:hover {
  border-color: var(--line-3);
  background: var(--bg-3);
}

.problem-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 24px;
  right: 24px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  opacity: 0;
  transition: opacity 0.3s var(--ease);
}

.problem-card:hover::before { opacity: 0.5; }

.problem-card .quote {
  font-size: 1rem;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 12px;
  line-height: 1.4;
}

.problem-card .quote::before {
  content: '"';
  color: var(--gold);
  margin-right: 2px;
}

.problem-card .quote::after {
  content: '"';
  color: var(--gold);
  margin-left: 2px;
}

.problem-card .resolution {
  font-size: 0.88rem;
  color: var(--text-2);
  margin: 0;
}

.problem-card .resolution::before {
  content: '→ ';
  color: var(--gold);
  font-family: var(--font-mono);
}

/* ===== CASE BLOCK ===== */
.case-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}

.case-block h2 { margin-bottom: 20px; }

.case-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin: 24px 0 32px;
  padding: 20px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.case-stat .v {
  font-family: var(--font-mono);
  font-size: 1.6rem;
  font-weight: 500;
  color: var(--gold);
  letter-spacing: -0.02em;
  line-height: 1;
  margin-bottom: 6px;
}

.case-stat .l {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
}

.case-image {
  border: 1px solid var(--line-2);
  border-radius: var(--r-md);
  box-shadow: 0 20px 60px -20px rgba(0,0,0,0.6);
}

/* ===== PRINCIPLES GRID ===== */
.principles {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.principle {
  padding: 28px 24px;
  border-right: 1px solid var(--line);
  position: relative;
}

.principle:last-child { border-right: none; }

.principle .num {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--gold);
  letter-spacing: 0.06em;
  margin-bottom: 12px;
  display: block;
}

.principle h3 {
  font-size: 1rem;
  margin-bottom: 8px;
}

.principle p {
  font-size: 0.88rem;
  margin: 0;
  color: var(--text-2);
}

/* ===== FAQ ===== */
.faq-item {
  border-top: 1px solid var(--line);
  padding: 0;
}

.faq-item:last-child { border-bottom: 1px solid var(--line); }

.faq-q {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 0;
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 0.98rem;
  font-weight: 500;
  color: var(--text);
  list-style: none;
  user-select: none;
}

.faq-q::-webkit-details-marker { display: none; }

.faq-q::after {
  content: '+';
  font-family: var(--font-mono);
  color: var(--gold);
  font-size: 18px;
  font-weight: 400;
  transition: transform 0.25s var(--ease);
}

.faq-item[open] .faq-q::after {
  content: '−';
}

.faq-a {
  padding: 0 0 22px;
  color: var(--text-2);
  font-size: 0.95rem;
  max-width: 65ch;
}

.faq-a code {
  font-family: var(--font-mono);
  font-size: 0.85em;
  padding: 1px 6px;
  background: var(--bg-3);
  border: 1px solid var(--line);
  border-radius: 3px;
  color: var(--gold-2);
}

/* ===== TICKER ===== */
.ticker {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 14px 0;
  overflow: hidden;
  background: var(--bg-2);
}

.ticker-track {
  display: flex;
  gap: 48px;
  animation: tickerScroll 35s linear infinite;
  white-space: nowrap;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-3);
  letter-spacing: 0.04em;
}

.ticker-track span { display: inline-flex; align-items: center; gap: 12px; }
.ticker-track span::before { content: '◆'; color: var(--gold); font-size: 8px; }

@keyframes tickerScroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ===== CTA BLOCK ===== */
.cta-block {
  padding: 64px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  position: relative;
  overflow: hidden;
}

.cta-block::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  opacity: 0.5;
}

.cta-block::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 80% 50%, var(--gold-glow), transparent 50%);
  opacity: 0.3;
  pointer-events: none;
}

.cta-block > * { position: relative; }

.cta-block h2 {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  margin-bottom: 16px;
  max-width: 20ch;
}

.cta-block p {
  max-width: 50ch;
  margin-bottom: 28px;
}

/* ===== FOOTER ===== */
.site-footer {
  padding: 80px 0 32px;
  border-top: 1px solid var(--line);
}

.footer-top {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 56px;
  border-bottom: 1px solid var(--line);
}

.footer-brand p {
  font-size: 0.92rem;
  color: var(--text-3);
  max-width: 28ch;
  margin: 16px 0 0;
}

.footer-col h4 {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 20px;
  font-weight: 500;
}

.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: 10px; }
.footer-col a {
  font-family: var(--font-sans);
  font-size: 0.9rem;
  color: var(--text-2);
}

.footer-col a:hover { color: var(--gold-2); }

.footer-bottom {
  margin-top: 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--text-3);
}

.footer-bottom .status {
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer-bottom .status::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 6px var(--green);
  animation: livePulse 2s infinite;
}

/* ===== REVEAL ===== */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.reveal.visible { opacity: 1; transform: translateY(0); }

.reveal-stagger > * {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}

.reveal-stagger.visible > * { opacity: 1; transform: translateY(0); }
.reveal-stagger.visible > *:nth-child(1) { transition-delay: 0.05s; }
.reveal-stagger.visible > *:nth-child(2) { transition-delay: 0.12s; }
.reveal-stagger.visible > *:nth-child(3) { transition-delay: 0.19s; }
.reveal-stagger.visible > *:nth-child(4) { transition-delay: 0.26s; }
.reveal-stagger.visible > *:nth-child(5) { transition-delay: 0.33s; }
.reveal-stagger.visible > *:nth-child(6) { transition-delay: 0.40s; }
.reveal-stagger.visible > *:nth-child(7) { transition-delay: 0.47s; }
.reveal-stagger.visible > *:nth-child(8) { transition-delay: 0.54s; }

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .hero-inner { grid-template-columns: 1fr; gap: 48px; }
  .case-block { grid-template-columns: 1fr; gap: 32px; }
  .problem-grid { grid-template-columns: repeat(2, 1fr); }
  .flow { grid-template-columns: repeat(2, 1fr); }
  .flow-line, .flow-pulse { display: none; }
  .principles { grid-template-columns: repeat(2, 1fr); }
  .principle:nth-child(2) { border-right: none; }
  .principle:nth-child(1), .principle:nth-child(2) { border-bottom: 1px solid var(--line); }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .main-nav { display: none; }
  .menu-toggle { display: block; }
  .header-cta { display: none; }
  .metric-bar { grid-template-columns: repeat(2, 1fr); }
  .metric:nth-child(2) { border-right: none; }
  .metric:nth-child(1), .metric:nth-child(2) { border-bottom: 1px solid var(--line); }
  .cap-row { grid-template-columns: 60px 1fr; }
  .cap-row .cap-desc, .cap-row .cap-tags, .cap-row .cap-arrow { grid-column: 2 / span 1; }
}

@media (max-width: 640px) {
  :root { --gutter: 18px; }
  .section { padding: 64px 0; }
  .problem-grid { grid-template-columns: 1fr; }
  .flow { grid-template-columns: 1fr; }
  .principles { grid-template-columns: 1fr; }
  .principle { border-right: none; border-bottom: 1px solid var(--line); }
  .principle:last-child { border-bottom: none; }
  .metric-bar { grid-template-columns: 1fr; }
  .metric { border-right: none; border-bottom: 1px solid var(--line); }
  .metric:last-child { border-bottom: none; }
  .footer-top { grid-template-columns: 1fr; }
  .case-stats { grid-template-columns: 1fr; gap: 12px; }
  .cta-block { padding: 32px 24px; }
  h1 { font-size: 2rem; }
  h2 { font-size: 1.5rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
