/* ═══════════════════════════════════════════
   base.css — Reset & Global Styles
   RainByte Studios
═══════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;600;700;900&family=Exo+2:ital,wght@0,300;0,400;0,500;1,300&display=swap');

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  background: var(--black);
}

body {
  font-family: var(--font-body);
  background: var(--black);
  color: var(--text);
  overflow-x: hidden;
  cursor: none;
}

::selection {
  background: rgba(74, 144, 217, 0.35);
  color: var(--ice);
}

a    { color: inherit; text-decoration: none; }
img  { display: block; max-width: 100%; }
ul   { list-style: none; }
button { cursor: pointer; border: none; background: none; font: inherit; }

/* ── Noise grain overlay ── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 1;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
  opacity: 0.022;
  pointer-events: none;
}

/* ── Main Three.js canvas ── */
#threejs-bg {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* ── Glitch scanline ── */
.glitch-line {
  position: fixed;
  left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--blue-core), transparent);
  opacity: 0;
  z-index: 1;
  pointer-events: none;
  animation: glitch-sweep 14s ease-in-out infinite;
}
@keyframes glitch-sweep {
  0%, 100% { top: -2px; opacity: 0; }
  2%        { top: 15vh; opacity: 0.3; }
  4%        { top: 65vh; opacity: 0.15; }
  6%        { top: 101vh; opacity: 0; }
}

/* ── Scroll wrapper ── */
#scroll-wrap {
  position: relative;
  z-index: 2;
}

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--black); }
::-webkit-scrollbar-thumb { background: var(--blue-deep); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--blue-core); }

/* ════ SECTION COMMONS ════ */
.section-wrap {
  padding: var(--section-pad) var(--page-pad);
  max-width: var(--max-w);
  margin: 0 auto;
}

.section-label {
  font-family: var(--font-display);
  font-size: 0.55rem;
  letter-spacing: 0.45em;
  color: var(--blue-core);
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.section-label::before {
  content: '';
  display: block;
  width: 28px;
  height: 1px;
  background: var(--blue-core);
  flex-shrink: 0;
}
.section-label.center {
  justify-content: center;
}
.section-label.center::before { display: none; }

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 3.2rem);
  font-weight: 700;
  color: var(--ice);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin-bottom: 18px;
}

.section-desc {
  font-size: 1rem;
  font-weight: 300;
  color: var(--silver-dim);
  max-width: 520px;
  line-height: 1.8;
  letter-spacing: 0.025em;
}

/* ════ BUTTONS ════ */
.btn-primary {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.6rem;
  letter-spacing: 0.28em;
  padding: 16px 40px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--blue-core), var(--blue-deep));
  color: var(--ice);
  border: 1px solid rgba(109, 180, 255, 0.3);
  box-shadow: 0 4px 32px rgba(74, 144, 217, 0.35),
              inset 0 1px 0 rgba(255, 255, 255, 0.07);
  transition: transform var(--dur-base) var(--ease-smooth),
              box-shadow var(--dur-base);
  position: relative;
  overflow: hidden;
  cursor: pointer;
}
.btn-primary::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.09), transparent);
  opacity: 0;
  transition: opacity var(--dur-fast);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 50px rgba(74, 144, 217, 0.55);
}
.btn-primary:hover::before { opacity: 1; }

.btn-ghost {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.6rem;
  letter-spacing: 0.28em;
  padding: 16px 40px;
  border-radius: var(--radius);
  color: var(--silver-dim);
  border: 1px solid var(--border);
  transition: color var(--dur-fast),
              border-color var(--dur-fast),
              box-shadow var(--dur-fast);
  cursor: pointer;
}
.btn-ghost:hover {
  color: var(--ice);
  border-color: rgba(160, 185, 220, 0.35);
  box-shadow: 0 0 24px rgba(160, 185, 220, 0.08);
}

.btn-vp {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 0.6rem;
  letter-spacing: 0.24em;
  padding: 16px 36px;
  border-radius: 100px;
  background: linear-gradient(135deg, rgba(176, 106, 255, 0.2), rgba(66, 217, 200, 0.1));
  color: var(--ice);
  border: 1px solid rgba(176, 106, 255, 0.4);
  box-shadow: 0 0 40px rgba(176, 106, 255, 0.2),
              inset 0 1px 0 rgba(255,255,255,0.06);
  transition: transform var(--dur-base) var(--ease-smooth),
              box-shadow var(--dur-base);
  cursor: pointer;
}
.btn-vp:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 60px rgba(176, 106, 255, 0.4),
              inset 0 1px 0 rgba(255,255,255,0.08);
}

/* ════ REVEAL ANIMATION ════ */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity var(--dur-slow) var(--ease-smooth),
              transform var(--dur-slow) var(--ease-smooth);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ════ CHIP / TAG ════ */
.tag {
  font-family: var(--font-display);
  font-size: 0.48rem;
  letter-spacing: 0.22em;
  color: var(--blue-core);
  border: 1px solid rgba(74, 144, 217, 0.25);
  padding: 5px 10px;
  border-radius: 2px;
  background: rgba(74, 144, 217, 0.05);
}
.tag.vp {
  color: var(--vp-violet);
  border-color: rgba(176, 106, 255, 0.3);
  background: rgba(176, 106, 255, 0.06);
}
