/* ═══════════════════════════════════════════════════════════
   STUNT NEURAL · style.css
   Single Surface · Obsidian Dark · Enterprise Grade
════════════════════════════════════════════════════════════ */

/* ── DESIGN TOKENS ──────────────────────────────────────── */
:root {
  --bg:             #070709;
  --surface:        rgba(12, 12, 18, 0.58);
  --surface-dock:   rgba(14, 14, 22, 0.72);
  --border:         rgba(255, 255, 255, 0.07);
  --border-hi:      rgba(255, 255, 255, 0.12);
  --border-accent:  rgba(200, 210, 255, 0.18);

  --text-primary:   #e4e4e9;
  --text-secondary: rgba(228, 228, 233, 0.40);
  --text-tertiary:  rgba(228, 228, 233, 0.22);
  --text-accent:    rgba(200, 212, 255, 0.65);

  --radius-card:    36px;
  --radius-btn:     50px;
  --radius-dock:    26px;

  --blur-card:      blur(52px) saturate(160%);
  --blur-dock:      blur(44px) saturate(200%);

  --shadow-card:
    0 0 0 1px rgba(255, 255, 255, 0.04) inset,
    0 1px 0 0 rgba(255, 255, 255, 0.09) inset,
    0 48px 96px rgba(0, 0, 0, 0.6),
    0 12px 32px rgba(0, 0, 0, 0.35);

  --shadow-dock:
    0 0 0 1px rgba(255, 255, 255, 0.05) inset,
    0 1px 0 0 rgba(255, 255, 255, 0.07) inset,
    0 24px 60px rgba(0, 0, 0, 0.55);

  --font-display: 'Cormorant Garamond', 'Georgia', 'Times New Roman', serif;
  --font-ui: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue", sans-serif;
}

/* ── RESET ──────────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  height: 100%;
  font-size: 16px;
}

body {
  height: 100%;
  background-color: var(--bg);
  color: var(--text-primary);
  font-family: var(--font-ui);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

a { text-decoration: none; }
button { cursor: pointer; appearance: none; border: none; background: none; }

/* ── BACKGROUND ORBS ────────────────────────────────────── */
.bg-orbs {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.orb {
  position: absolute;
  border-radius: 50%;
}

.orb-1 {
  width: 780px;
  height: 780px;
  top: -30%;
  left: -18%;
  background: radial-gradient(ellipse at center, rgba(34, 24, 88, 0.9) 0%, transparent 68%);
  filter: blur(100px);
  opacity: 0.55;
  animation: orbDrift 30s ease-in-out infinite alternate;
}

.orb-2 {
  width: 660px;
  height: 660px;
  bottom: -22%;
  right: -10%;
  background: radial-gradient(ellipse at center, rgba(8, 30, 55, 0.9) 0%, transparent 68%);
  filter: blur(90px);
  opacity: 0.5;
  animation: orbDrift 24s ease-in-out infinite alternate-reverse;
}

.orb-3 {
  width: 380px;
  height: 380px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: radial-gradient(ellipse at center, rgba(22, 10, 44, 0.8) 0%, transparent 70%);
  filter: blur(80px);
  opacity: 0.45;
  animation: orbPulse 18s ease-in-out infinite;
}

@keyframes orbDrift {
  from { transform: translate(0, 0) scale(1); }
  to   { transform: translate(70px, 50px) scale(1.1); }
}

@keyframes orbPulse {
  0%, 100% { opacity: 0.35; transform: translate(-50%, -50%) scale(1); }
  50%       { opacity: 0.55; transform: translate(-50%, -50%) scale(1.15); }
}

/* ── NOISE GRAIN OVERLAY ────────────────────────────────── */
.noise {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.030;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260'%3E%3Cfilter id='n' x='0' y='0'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='260' height='260' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 220px 220px;
}

/* ── SURFACE (CENTER STAGE) ─────────────────────────────── */
.surface {
  position: relative;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  padding: 80px 24px 100px; /* leave room for dock */
}

/* ── HERO CARD ──────────────────────────────────────────── */
.hero-card {
  position: relative;
  width: 100%;
  max-width: 548px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
  padding: 36px 44px 40px;

  background: var(--surface);
  backdrop-filter: var(--blur-card);
  -webkit-backdrop-filter: var(--blur-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);

  /* GPU layer for smooth tilt transforms */
  will-change: transform;
  transform-style: preserve-3d;
  transform: perspective(1000px);

  /* Entry animation */
  animation: cardReveal 1s cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* Top shimmer line — light leak effect */
.hero-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 18%;
  right: 18%;
  height: 1px;
  background: linear-gradient(90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.20) 40%,
    rgba(255, 255, 255, 0.20) 60%,
    transparent 100%
  );
  border-radius: 1px;
  pointer-events: none;
}

/* Faint inner glow for glass depth */
.hero-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: var(--radius-card);
  box-shadow: 0 0 40px rgba(200, 210, 255, 0.03) inset;
  pointer-events: none;
}

@keyframes cardReveal {
  from {
    opacity: 0;
    transform: perspective(1000px) translateY(28px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: perspective(1000px) translateY(0) scale(1);
  }
}

/* ── TOP STATUS BAR ─────────────────────────────────────── */
.card-topbar {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 8px;
}

.topbar-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--text-accent);
  opacity: 0.7;
  flex-shrink: 0;
}

.topbar-label {
  flex: 1;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-tertiary);
}

.topbar-badge {
  font-size: 9.5px;
  font-weight: 500;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--text-accent);
  border: 1px solid var(--border-accent);
  border-radius: 20px;
  padding: 3px 10px;
}

/* ── NEURAL MARK ────────────────────────────────────────── */
.hero-mark {
  width: 64px;
  height: 64px;
  margin-bottom: -6px;
}

.hero-mark svg {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 0 12px rgba(200, 210, 255, 0.15));
}

/* ── HERO TEXT ──────────────────────────────────────────── */
.hero-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  text-align: center;
}

.hero-eyebrow {
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-tertiary);
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(80px, 14vw, 108px);
  font-weight: 300;
  letter-spacing: -0.025em;
  line-height: 0.88;
  /* Silver-to-slate gradient */
  background: linear-gradient(
    168deg,
    rgba(240, 240, 246, 1.00) 0%,
    rgba(210, 215, 240, 0.85) 45%,
    rgba(155, 165, 210, 0.65) 100%
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  /* Prevent selection artifacts */
  user-select: none;
}

.hero-sub {
  font-size: 13.5px;
  font-weight: 400;
  line-height: 1.70;
  letter-spacing: 0.01em;
  color: var(--text-secondary);
  max-width: 340px;
}

/* ── DOWNLOAD CTA ───────────────────────────────────────── */
.hero-cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 11px;
  width: 100%;
}

.btn-download {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  width: 100%;
  max-width: 296px;
  padding: 13.5px 28px;

  background: rgba(240, 240, 248, 0.08);
  border: 1px solid var(--border-hi);
  border-radius: var(--radius-btn);

  font-family: var(--font-ui);
  font-size: 13.5px;
  font-weight: 500;
  letter-spacing: 0.025em;
  color: var(--text-primary);

  overflow: hidden;
  transition:
    background  0.28s ease,
    border-color 0.28s ease,
    box-shadow   0.28s ease,
    transform    0.14s ease,
    opacity      0.28s ease;
}

.btn-download:hover {
  background: rgba(240, 240, 248, 0.13);
  border-color: rgba(255, 255, 255, 0.20);
  box-shadow:
    0 0 0 1px rgba(200, 210, 255, 0.10),
    0 8px 28px rgba(0, 0, 0, 0.35);
}

.btn-download:active {
  transform: scale(0.965);
}

.btn-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* Sweep-shine on hover */
.btn-shine {
  position: absolute;
  top: 0;
  left: -100%;
  width: 55%;
  height: 100%;
  background: linear-gradient(
    100deg,
    transparent 0%,
    rgba(255, 255, 255, 0.07) 50%,
    transparent 100%
  );
  transform: skewX(-18deg);
  pointer-events: none;
  transition: left 0.55s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-download:hover .btn-shine {
  left: 165%;
}

.btn-meta {
  font-size: 10.5px;
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-tertiary);
}

/* ── STATS ROW ──────────────────────────────────────────── */
.hero-stats {
  width: 100%;
  display: flex;
  align-items: center;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.stat {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
}

.stat-val {
  font-size: 16px;
  font-weight: 500;
  color: var(--text-primary);
  letter-spacing: -0.02em;
  line-height: 1;
}

.stat-unit {
  font-size: 11px;
  font-weight: 400;
  color: var(--text-secondary);
  letter-spacing: 0;
}

.stat-lbl {
  font-size: 9.5px;
  font-weight: 500;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--text-tertiary);
}

.stat-divider {
  width: 1px;
  height: 30px;
  background: var(--border);
  flex-shrink: 0;
}

/* ── DOCK ───────────────────────────────────────────────── */
.dock {
  position: fixed;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  animation: dockReveal 1s 0.45s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes dockReveal {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

.dock-inner {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 8px 10px;

  background: var(--surface-dock);
  backdrop-filter: var(--blur-dock);
  -webkit-backdrop-filter: var(--blur-dock);
  border: 1px solid var(--border-hi);
  border-radius: var(--radius-dock);
  box-shadow: var(--shadow-dock);
}

/* Dock top shimmer */
.dock-inner::before {
  content: '';
  position: absolute;
  top: 0;
  left: 20%;
  right: 20%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.12), transparent);
  pointer-events: none;
}

.dock-item {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: var(--text-secondary);
  transition:
    background  0.20s ease,
    color       0.20s ease,
    transform   0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* Tooltip */
.dock-item::after {
  content: attr(data-label);
  position: absolute;
  bottom: calc(100% + 12px);
  left: 50%;
  transform: translateX(-50%) translateY(6px);

  background: rgba(18, 18, 28, 0.92);
  backdrop-filter: blur(24px);
  border: 1px solid var(--border-hi);
  border-radius: 9px;
  padding: 5px 11px;

  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--text-primary);
  white-space: nowrap;

  opacity: 0;
  pointer-events: none;
  transition:
    opacity   0.15s ease,
    transform 0.18s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.dock-item:hover::after {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.dock-item:hover {
  background: rgba(255, 255, 255, 0.07);
  color: var(--text-primary);
}

.dock-icon {
  display: flex;
  align-items: center;
  justify-content: center;
}

.dock-separator {
  width: 1px;
  height: 24px;
  background: var(--border-hi);
  margin: 0 4px;
  flex-shrink: 0;
}

.dock-item--accent {
  color: rgba(200, 212, 255, 0.55);
}

.dock-item--accent:hover {
  background: rgba(200, 212, 255, 0.08);
  color: rgba(200, 212, 255, 0.90);
}

/* ── LOADING SPINNER (injected by JS) ───────────────────── */
@keyframes spinIcon {
  to { transform: rotate(360deg); }
}

.spin-icon {
  animation: spinIcon 0.85s linear infinite;
}

/* ── DOWNLOAD SUCCESS STATE ─────────────────────────────── */
.btn-download.is-success {
  border-color: rgba(140, 210, 150, 0.30);
  background: rgba(140, 210, 150, 0.07);
}

/* ── RESPONSIVE ─────────────────────────────────────────── */
@media (max-width: 600px) {
  .hero-card {
    padding: 28px 28px 32px;
    gap: 24px;
    border-radius: 28px;
  }

  .hero-title {
    font-size: clamp(68px, 18vw, 88px);
  }

  .hero-sub {
    font-size: 13px;
  }

  .hero-sub br {
    display: none;
  }

  .stat-val {
    font-size: 14px;
  }

  .stat-lbl {
    font-size: 8.5px;
  }
}

@media (max-height: 700px) {
  .hero-card {
    gap: 20px;
    padding: 28px 40px 32px;
  }

  .hero-title {
    font-size: 72px;
  }

  .hero-mark {
    width: 48px;
    height: 48px;
  }
}
