/* Base Cinematic Dark Styling */
:root {
  --bg-primary: #090909;
  --bg-secondary: #141414;
  --bg-card: #1C1C1C;
  --accent-primary: #E50914;
  --accent-secondary: #B20710;
}

html, body {
  background-color: #090909;
  color: #FFFFFF;
  font-family: 'Inter', sans-serif;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, .font-display {
  font-family: 'Manrope', sans-serif;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: #090909;
}
::-webkit-scrollbar-thumb {
  background: #2A2A2A;
  border-radius: 9999px;
}
::-webkit-scrollbar-thumb:hover {
  background: #E50914;
}

/* Hide scrollbar for Netflix-style horizontal carousel */
.no-scrollbar::-webkit-scrollbar {
  display: none;
}
.no-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* Subtle Tech Grid Overlay */
.bg-tech-grid {
  background-size: 44px 44px;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
}

/* Smooth View Transitions */
.page-view {
  animation: pageFadeIn 0.42s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes pageFadeIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Streaming Card Hover Micro-interaction */
.stream-card {
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1),
              box-shadow 0.35s cubic-bezier(0.22, 1, 0.36, 1),
              border-color 0.35s ease;
}
.stream-card:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 18px 38px -12px rgba(229, 9, 20, 0.35), 0 12px 24px -10px rgba(0, 0, 0, 0.9);
  border-color: rgba(229, 9, 20, 0.6);
}
.stream-card:hover .stream-thumb {
  transform: scale(1.07);
}
.stream-thumb {
  transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Pulse Packet Animation for Server Simulation */
@keyframes packetPulse {
  0%, 100% {
    transform: scale(1);
    filter: drop-shadow(0 0 6px rgba(229, 9, 20, 0.8));
  }
  50% {
    transform: scale(1.25);
    filter: drop-shadow(0 0 14px rgba(229, 9, 20, 1));
  }
}
.packet-glow {
  animation: packetPulse 1.4s infinite ease-in-out;
}

/* Respect Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
