/* ═══════════════════════════════════════════
   base.css — Reset + Global Utilities
═══════════════════════════════════════════ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
img  { display: block; max-width: 100%; }
button, input, textarea { font: inherit; }

body {
  background: var(--c-void);
  color: var(--c-star);
  font-family: var(--font-sans);
  font-weight: 300;
  line-height: 1.75;
  overflow-x: hidden;
  cursor: none;
}
@media (max-width: 600px) { body { cursor: auto; } }

/* ── Scrollbar ── */
::-webkit-scrollbar       { width: 3px; }
::-webkit-scrollbar-track { background: var(--c-abyss); }
::-webkit-scrollbar-thumb { background: var(--c-teal); border-radius: 2px; }
::-webkit-scrollbar-thumb:hover { background: var(--c-biolume-soft); }

/* ── Selection ── */
::selection { background: rgba(61,255,208,0.18); color: var(--c-biolume); }

/* ── Focus ── */
:focus-visible {
  outline: 1.5px solid var(--c-biolume);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ── Grain overlay ── */
.grain {
  position: fixed; inset: 0; z-index: 3;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23g)'/%3E%3C/svg%3E");
  background-size: 180px;
  opacity: 0.028;
  mix-blend-mode: overlay;
}

/* ── Stars canvas ── */
#stars {
  position: fixed; inset: 0; z-index: 0;
  pointer-events: none;
}

/* ── Cursor ── */
#cursor-ring, #cursor-dot {
  position: fixed; z-index: 9999;
  border-radius: 50%; pointer-events: none;
  transform: translate(-50%, -50%);
  will-change: left, top;
}
#cursor-ring {
  width: 32px; height: 32px;
  border: 1px solid rgba(61,255,208,0.3);
  transition: width var(--fast), height var(--fast),
              border-color var(--fast), background var(--fast);
}
#cursor-dot {
  width: 5px; height: 5px;
  background: var(--c-biolume);
  box-shadow: 0 0 8px var(--c-biolume);
}
#cursor-ring.hov {
  width: 52px; height: 52px;
  border-color: rgba(61,255,208, 0.5);
  background: rgba(61,255,208, 0.05);
}

/* ── Layout ── */
.container { max-width: 1200px; margin: 0 auto; }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center;
  padding: 0.72rem 1.9rem;
  font-family: var(--font-mono); font-size: var(--t-sm);
  letter-spacing: 0.14em; text-transform: uppercase;
  text-decoration: none; border: none; border-radius: var(--radius);
  transition: all var(--mid) var(--ease);
  cursor: none; position: relative; overflow: hidden;
}
.btn::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(130deg, transparent 40%, rgba(255,255,255,0.08) 50%, transparent 60%);
  transform: translateX(-100%);
  transition: transform 0.5s var(--ease);
}
.btn:hover::after { transform: translateX(100%); }
.btn-primary {
  background: linear-gradient(130deg, var(--c-teal), var(--c-thermal));
  color: var(--c-void);
  box-shadow: 0 0 22px rgba(29,136,112,0.2);
}
.btn-primary:hover {
  box-shadow: 0 0 40px rgba(61,255,208,0.35);
  transform: translateY(-2px);
}
.btn-ghost {
  background: transparent; color: var(--c-biolume-soft);
  border: 1px solid var(--c-deep);
}
.btn-ghost:hover {
  border-color: var(--c-biolume); color: var(--c-biolume);
  box-shadow: 0 0 18px rgba(61,255,208,0.1);
  transform: translateY(-2px);
}

/* ── Shared typography ── */
.eyebrow {
  font-family: var(--font-mono); font-size: var(--t-sm);
  letter-spacing: 0.3em; text-transform: uppercase;
  color: var(--c-biolume); margin-bottom: var(--s1);
}
.eyebrow-nebula { color: var(--c-nebula); }

.section-title {
  font-family: var(--font-serif); font-size: var(--t-xl);
  font-weight: 600; line-height: 1.1; color: var(--c-star);
  margin-bottom: var(--s2);
}
.section-rule {
  width: 48px; height: 1.5px;
  background: linear-gradient(to right, var(--c-biolume), transparent);
}
.section-rule-nebula {
  background: linear-gradient(to right, var(--c-nebula), transparent);
}
.section-header { margin-bottom: var(--s12); }

/* ── Zone dividers ── */
.zone-div {
  position: relative; z-index: 2; height: 1px; overflow: visible;
}
.zone-div::before {
  content: ''; position: absolute; left: 0; right: 0; top: 0; height: 1px;
  background: linear-gradient(to right, transparent, var(--c-biolume), var(--c-biolume-soft), var(--c-biolume), transparent);
  opacity: 0.12;
}
.zone-div::after {
  content: attr(data-depth);
  position: absolute; right: 3rem; top: -10px;
  font-family: var(--font-mono); font-size: var(--t-xs);
  letter-spacing: 0.2em; color: var(--c-mist); text-transform: uppercase;
}

/* ── Scroll reveal ── */
.reveal {
  opacity: 0; transform: translateY(20px);
  transition: opacity var(--slow) var(--ease), transform var(--slow) var(--ease);
}
.reveal.in { opacity: 1; transform: none; }

/* ── Marquee ── */
.marquee {
  position: relative; z-index: 2; overflow: hidden;
  border-top: 1px solid var(--c-deep); border-bottom: 1px solid var(--c-deep);
  padding: 0.75rem 0; background: rgba(5,14,28,0.7);
}
.marquee-track { display: flex; }
.marquee-content {
  font-family: var(--font-mono); font-size: var(--t-sm);
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--c-mist); white-space: nowrap;
  animation: marquee-scroll 40s linear infinite;
}
.marquee:hover .marquee-content { animation-play-state: paused; }
@keyframes marquee-scroll { to { transform: translateX(-50%); } }

/* ── Footer ── */
.site-footer {
  position: relative; z-index: 2;
  padding: var(--s3) var(--s6);
  border-top: 1px solid var(--c-deep);
  text-align: center;
}
.footer-text {
  font-family: var(--font-mono); font-size: var(--t-xs);
  letter-spacing: 0.2em; text-transform: lowercase; color: var(--c-mist);
}
.footer-accent { color: var(--c-biolume-soft); }

/* ── Live dot ── */
.live-dot {
  width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0;
  background: var(--c-biolume); box-shadow: 0 0 6px var(--c-biolume);
  animation: live-pulse 2.5s ease-in-out infinite;
}
@keyframes live-pulse {
  0%,100% { box-shadow: 0 0 4px var(--c-biolume); }
  50%      { box-shadow: 0 0 14px var(--c-biolume), 0 0 28px rgba(61,255,208,0.25); }
}

/* ── Responsive ── */
@media (max-width: 720px) {
  .zone-div::after { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}
