/* ═══════════════════════════════════════
   NEON COSMOS — Shared Design System
   Extracted from index.html (trekodarok.ru)
   ═══════════════════════════════════════ */

/* ─── CSS Variables ─── */
:root {
  --bg: #070512;
  --violet: #7C3AED;
  --gold: #F59E0B;
  --blue: #2563EB;
  --cta-from: #FF6A3D;
  --cta-to: #FF8A5C;
  --glass: rgba(255,255,255,0.05);
  --glass-border: rgba(255,255,255,0.10);
}

/* ─── Reset ─── */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: #fff;
  font-family: 'Inter', sans-serif;
  overflow-x: hidden;
  cursor: none;
}

body * { cursor: none; }

/* ─── Grain overlay ─── */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 200px 200px;
}

/* ─── Custom Cursor ─── */
#cursor-dot {
  position: fixed;
  width: 8px; height: 8px;
  background: #fff;
  border-radius: 50%;
  pointer-events: none;
  z-index: 10000;
  transform: translate(-50%, -50%);
  transition: transform 0.1s, width 0.2s, height 0.2s, background 0.2s;
}
#cursor-ring {
  position: fixed;
  width: 32px; height: 32px;
  border: 1.5px solid rgba(255,255,255,0.5);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: transform 0.08s linear, width 0.2s, height 0.2s, opacity 0.2s, border-color 0.2s;
}
body.cursor-on-button #cursor-dot { width: 40px; height: 40px; background: rgba(255,106,61,0.3); }
body.cursor-on-button #cursor-ring { opacity: 0; }

/* ─── WebGL Shader Canvas ─── */
#bg-canvas {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 0;
  opacity: 1;
  pointer-events: none;
}

/* ─── Aurora Blob CSS Fallback ─── */
#aurora-bg {
  position: fixed;
  inset: 0;
  z-index: 1;
  overflow: hidden;
  pointer-events: none;
}
.aurora-wave {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  will-change: transform;
}
.aurora-1 {
  width: 90vw; height: 80vh;
  background: radial-gradient(ellipse 60% 60% at 50% 50%, rgba(123,92,255,0.55) 0%, rgba(123,92,255,0.25) 45%, transparent 75%);
  top: -15%; left: -20%;
  filter: blur(55px);
  animation: blob-a 18s ease-in-out infinite;
}
.aurora-2 {
  width: 85vw; height: 75vh;
  background: radial-gradient(ellipse 60% 60% at 50% 50%, rgba(59,130,246,0.45) 0%, rgba(59,130,246,0.2) 50%, transparent 75%);
  top: 0%; right: -25%;
  filter: blur(60px);
  animation: blob-b 22s ease-in-out infinite;
}
.aurora-3 {
  width: 70vw; height: 65vh;
  background: radial-gradient(ellipse 65% 55% at 50% 50%, rgba(139,92,246,0.45) 0%, rgba(139,92,246,0.18) 55%, transparent 80%);
  bottom: 0%; left: 5%;
  filter: blur(65px);
  animation: blob-c 16s ease-in-out infinite;
}
.aurora-4 {
  width: 60vw; height: 55vh;
  background: radial-gradient(ellipse 60% 60% at 50% 50%, rgba(255,106,61,0.40) 0%, rgba(255,106,61,0.18) 50%, transparent 75%);
  top: 45%; right: 0%;
  filter: blur(70px);
  animation: blob-d 20s ease-in-out infinite;
}
.aurora-5 {
  width: 55vw; height: 45vh;
  background: radial-gradient(ellipse 55% 55% at 50% 50%, rgba(236,72,153,0.30) 0%, rgba(236,72,153,0.12) 55%, transparent 80%);
  bottom: -10%; left: -5%;
  filter: blur(80px);
  animation: blob-a 28s ease-in-out infinite reverse;
}
.aurora-6 {
  width: 130%; height: 40vh;
  background: linear-gradient(180deg, transparent, rgba(59,130,246,0.18) 40%, rgba(123,92,255,0.22) 60%, transparent);
  top: 20%; left: -15%;
  filter: blur(35px);
  animation: blob-stripe 30s ease-in-out infinite;
  border-radius: 0;
}

@keyframes blob-a {
  0%,100% { transform: translate(0,0) scale(1) rotate(0deg); }
  25% { transform: translate(100px,-80px) scale(1.15) rotate(10deg); }
  50% { transform: translate(70px, 70px) scale(0.92) rotate(-6deg); }
  75% { transform: translate(-60px, 90px) scale(1.08) rotate(5deg); }
}
@keyframes blob-b {
  0%,100% { transform: translate(0,0) scale(1); }
  33% { transform: translate(-120px, 70px) scale(1.12); }
  66% { transform: translate(60px,-80px) scale(0.9); }
}
@keyframes blob-c {
  0%,100% { transform: translate(0,0) scale(1) rotate(0deg); }
  50% { transform: translate(-80px,-100px) scale(1.22) rotate(-12deg); }
}
@keyframes blob-d {
  0%,100% { transform: translate(0,0) scale(1); }
  50% { transform: translate(80px, 55px) scale(1.15); }
}
@keyframes blob-stripe {
  0%,100% { transform: translateY(0) scaleY(1); opacity: 0.9; }
  50% { transform: translateY(80px) scaleY(1.4); opacity: 0.5; }
}

/* ─── Typography ─── */
.font-display { font-family: 'Unbounded', sans-serif; }

/* ─── Gradient Text ─── */
.text-gold {
  background: linear-gradient(135deg, var(--cta-from), var(--cta-to));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ─── CTA Button ─── */
.btn-cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, var(--cta-from), var(--cta-to));
  color: #fff;
  font-family: 'Unbounded', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  padding: 22px 52px;
  border-radius: 100px;
  border: none;
  text-decoration: none;
  position: relative;
  overflow: hidden;
  transition: transform 0.3s, box-shadow 0.3s;
  box-shadow: 0 0 50px rgba(255,106,61,0.55), 0 0 100px rgba(255,106,61,0.25);
}
.btn-cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.2), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}
.btn-cta::after {
  content: '';
  position: absolute;
  top: 0;
  left: -80%;
  width: 55%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.38), transparent);
  border-radius: inherit;
  animation: btn-shimmer 2.2s ease-in-out infinite;
  pointer-events: none;
}
@keyframes btn-shimmer {
  0% { left: -80%; }
  40%, 100% { left: 140%; }
}
.btn-cta:hover::before { opacity: 1; }
.btn-cta:hover {
  transform: scale(1.04) translateY(-2px);
  box-shadow: 0 0 60px rgba(255,106,61,0.6), 0 0 120px rgba(255,106,61,0.25), 0 20px 40px rgba(0,0,0,0.3);
}

/* ─── Secondary CTA — Liquid Glass ─── */
.btn-cta-secondary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-family: 'Unbounded', sans-serif;
  font-weight: 600;
  font-size: 1rem;
  padding: 19px 42px;
  border-radius: 100px;
  border: none;
  text-decoration: none;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.4s cubic-bezier(0.175,0.885,0.32,2.2),
              box-shadow 0.3s;
  box-shadow: 0 6px 6px rgba(0,0,0,0.25), 0 0 20px rgba(0,0,0,0.12);
}
.btn-cta-secondary::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  backdrop-filter: blur(4px) saturate(1.5);
  -webkit-backdrop-filter: blur(4px) saturate(1.5);
  filter: url(#glass-distortion);
  isolation: isolate;
  z-index: 0;
}
.btn-cta-secondary::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: rgba(255,255,255,0.10);
  box-shadow:
    inset 2px 2px 1px 0 rgba(255,255,255,0.45),
    inset -1px -1px 1px 1px rgba(255,255,255,0.25),
    inset 0 0 0 1px rgba(255,255,255,0.15);
  pointer-events: none;
  z-index: 1;
}
.btn-cta-secondary { isolation: isolate; }
.btn-cta-secondary:hover {
  transform: scale(1.05) translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.3), 0 0 40px rgba(123,92,255,0.25);
}

/* ─── Glass Card ─── */
.glass {
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.05);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: inset 0 0 20px rgba(123,92,255,0.06);
  transition: border-color 0.25s, box-shadow 0.25s, transform 0.25s;
}
.glass:hover {
  border-color: rgba(255,255,255,0.1);
  box-shadow: inset 0 0 30px rgba(123,92,255,0.1), 0 8px 32px rgba(0,0,0,0.3);
  transform: translateY(-2px);
}

/* ─── Section ─── */
section { position: relative; z-index: 2; }

/* ─── Hero Particle Canvas ─── */
#hero-particle-canvas {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* ─── SVG Icon System ─── */
.si { display: inline-block; flex-shrink: 0; vertical-align: middle; }
.nav-logo-icon { width: 16px; height: 16px; display: inline-block; vertical-align: -3px; margin-right: 4px; color: #FF6A3D; }
.btn-icon { width: 16px; height: 16px; flex-shrink: 0; display: inline-block; vertical-align: -2px; }

/* ─── Page Loader ─── */
#page-loader {
  position: fixed; inset: 0; z-index: 99999;
  background: #070512;
  display: flex; align-items: center; justify-content: center;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}
#page-loader.hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.loader-logo {
  font-family: 'Unbounded', sans-serif;
  font-size: 1.4rem; font-weight: 800; letter-spacing: -0.01em;
  background: linear-gradient(135deg, #FF6A3D, #FF8A5C);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text; margin-bottom: 28px; text-align: center;
}
.loader-wave { display: flex; align-items: flex-end; gap: 5px; height: 44px; justify-content: center; }
.lw-bar {
  width: 5px; border-radius: 3px;
  background: linear-gradient(to top, #FF6A3D, #7B5CFF);
  animation: lw-pulse 0.9s ease-in-out infinite;
}
.lw-bar:nth-child(1){height:16px;animation-delay:0s}
.lw-bar:nth-child(2){height:30px;animation-delay:.1s}
.lw-bar:nth-child(3){height:22px;animation-delay:.2s}
.lw-bar:nth-child(4){height:40px;animation-delay:.3s}
.lw-bar:nth-child(5){height:24px;animation-delay:.4s}
.lw-bar:nth-child(6){height:34px;animation-delay:.5s}
.lw-bar:nth-child(7){height:18px;animation-delay:.6s}
@keyframes lw-pulse {
  0%,100%{transform:scaleY(1);opacity:.5}
  50%{transform:scaleY(1.9);opacity:1}
}

/* ─── Live Counter ─── */
#live-counter-bar {
  display: flex; align-items: center; justify-content: center;
  gap: 10px; padding: 14px 24px;
  background: rgba(255,106,61,0.04);
  border-top: 1px solid rgba(255,106,61,0.1);
  border-bottom: 1px solid rgba(255,106,61,0.1);
  font-size: 0.85rem; color: rgba(255,255,255,0.6);
  position: relative; z-index: 2;
}
.live-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #FF6A3D; flex-shrink: 0;
  animation: live-pulse 2s ease-in-out infinite;
}
@keyframes live-pulse {
  0%,100%{transform:scale(1);box-shadow:0 0 0 0 rgba(255,106,61,0.5)}
  50%{transform:scale(1.25);box-shadow:0 0 0 6px rgba(255,106,61,0)}
}
#live-songs-count { color: #FF8A5C; font-weight: 700; }
.section-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,106,61,0.18) 30%, rgba(123,92,255,0.18) 70%, transparent);
  position: relative; z-index: 2;
}

/* ─── Sticky Mini-Player ─── */
#sticky-player {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 900;
  background: rgba(7,5,18,0.97);
  backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
  border-top: 1px solid rgba(123,92,255,0.3);
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.4,0,0.2,1);
  box-shadow: 0 -8px 40px rgba(0,0,0,0.6);
  padding: 12px 20px;
  padding-bottom: calc(12px + env(safe-area-inset-bottom, 0px));
}
#sticky-player.visible { transform: translateY(0); }
#sticky-player:not(.is-playing) .eq-bar { animation: none !important; height: 3px; }
.sticky-inner { max-width: 720px; margin: 0 auto; display: flex; align-items: center; gap: 14px; }
.sp-eq { display: flex; align-items: flex-end; gap: 2px; height: 18px; flex-shrink: 0; }
.sp-eq .eq-bar { width: 3px; }
.sp-info { flex: 1; min-width: 0; }
.sp-title { font-size: 0.8rem; font-weight: 600; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sp-sub { font-size: 0.68rem; color: rgba(255,255,255,0.4); margin-top: 2px; }
.sp-play {
  width: 40px; height: 40px; min-width: 40px;
  background: linear-gradient(135deg, #FF6A3D, #FF8A5C);
  border: none; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 0 16px rgba(255,106,61,0.5);
  transition: transform 0.2s; flex-shrink: 0; cursor: pointer;
}
.sp-play:hover { transform: scale(1.08); }
.sp-play svg { width: 16px; height: 16px; fill: #fff; margin-left: 2px; }
.sp-play.playing svg.play-icon { display: none; }
.sp-play:not(.playing) svg.pause-icon { display: none; }
.sp-progress { flex: 1; min-width: 0; }
.sp-bar { height: 3px; background: rgba(255,255,255,0.1); border-radius: 10px; cursor: pointer; margin-bottom: 4px; }
.sp-fill { height: 100%; background: linear-gradient(90deg, #FF6A3D, #FF8A5C); border-radius: 10px; width: 0%; transition: width 0.1s linear; }
.sp-time { font-size: 0.65rem; color: rgba(255,255,255,0.3); }
.sp-close { background: none; border: none; color: rgba(255,255,255,0.3); font-size: 1rem; cursor: pointer; padding: 4px; transition: color 0.2s; flex-shrink: 0; }
.sp-close:hover { color: rgba(255,255,255,0.7); }
@media (max-width: 768px) {
  #sticky-player { padding: 10px 14px; padding-bottom: calc(10px + env(safe-area-inset-bottom, 0px)); }
  .sp-progress { display: none; }
}

/* ─── Mobile Sticky CTA ─── */
#mobile-cta-bar {
  display: none;
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 800;
  padding: 10px 16px;
  padding-bottom: calc(10px + env(safe-area-inset-bottom, 0px));
  background: rgba(7,5,18,0.97);
  border-top: 1px solid rgba(255,106,61,0.15);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
}
@media (max-width: 768px) {
  #mobile-cta-bar { display: block; }
  body { padding-bottom: 76px; }
  body.sticky-player-visible #mobile-cta-bar { display: none; }
  body.sticky-player-visible { padding-bottom: 82px; }
}
.mob-cta-btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; padding: 14px;
  background: linear-gradient(135deg, #FF6A3D, #FF8A5C);
  color: #fff;
  font-family: 'Unbounded', sans-serif;
  font-size: 0.82rem; font-weight: 700;
  border-radius: 12px; text-decoration: none;
  box-shadow: 0 4px 20px rgba(255,106,61,0.4);
  transition: transform 0.15s;
}
.mob-cta-btn:active { transform: scale(0.98); }

/* ─── Reveal animation ─── */
.reveal { opacity: 0; transform: translateY(30px); }

/* ─── Responsive ─── */
@media (max-width: 768px) {
  .btn-cta { font-size: 0.9rem; padding: 16px 28px; }
  .btn-cta-secondary { font-size: 0.9rem; padding: 14px 28px; }
}

@media (pointer: coarse) {
  body, body * { cursor: auto; }
  #cursor-dot, #cursor-ring { display: none; }
}
