/* ==========================================================================
   SPEED1 API & K-GAMES - UNIQUE CYBER-LUXURY DESIGN SYSTEM
   ========================================================================== */

:root {
  --bg-base: #060911;
  --bg-surface: #0c1220;
  --bg-card: rgba(16, 24, 40, 0.75);
  --bg-card-hover: rgba(24, 36, 60, 0.9);
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(139, 92, 246, 0.4);
  --border-cyan: rgba(6, 182, 212, 0.4);
  --border-gold: rgba(251, 191, 36, 0.4);

  --accent-purple: #8b5cf6;
  --accent-purple-glow: rgba(139, 92, 246, 0.25);
  --accent-cyan: #06b6d4;
  --accent-cyan-glow: rgba(6, 182, 212, 0.25);
  --accent-gold: #fbbf24;
  --accent-gold-glow: rgba(251, 191, 36, 0.25);
  --accent-green: #10b981;
  --accent-rose: #f43f5e;

  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-sub: #64748b;

  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Plus Jakarta Sans', sans-serif;
}

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

body {
  background-color: var(--bg-base);
  color: var(--text-main);
  font-family: var(--font-body);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
}

/* Background Animated Gradient Mesh */
.cyber-bg-mesh {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  pointer-events: none;
  background: 
    radial-gradient(circle at 15% 15%, rgba(139, 92, 246, 0.12) 0%, transparent 40%),
    radial-gradient(circle at 85% 20%, rgba(6, 182, 212, 0.10) 0%, transparent 45%),
    radial-gradient(circle at 50% 80%, rgba(251, 191, 36, 0.06) 0%, transparent 50%),
    linear-gradient(180deg, #060911 0%, #0a0e1a 100%);
}

.cyber-grid-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  pointer-events: none;
  background-image: 
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: radial-gradient(ellipse at center, black 40%, transparent 80%);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #090d16;
}
::-webkit-scrollbar-thumb {
  background: #25334e;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--accent-purple);
}

/* Glass Panels */
.glass-panel {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-subtle);
  border-radius: 16px;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.glass-panel:hover {
  border-color: rgba(255, 255, 255, 0.15);
}

.glass-card-glow {
  position: relative;
}
.glass-card-glow::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.5), transparent, rgba(6, 182, 212, 0.4));
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

/* Glowing Badges */
.badge-glow-purple {
  background: rgba(139, 92, 246, 0.15);
  border: 1px solid rgba(139, 92, 246, 0.35);
  color: #c4b5fd;
  box-shadow: 0 0 15px rgba(139, 92, 246, 0.2);
}

.badge-glow-cyan {
  background: rgba(6, 182, 212, 0.15);
  border: 1px solid rgba(6, 182, 212, 0.35);
  color: #67e8f9;
  box-shadow: 0 0 15px rgba(6, 182, 212, 0.2);
}

.badge-glow-gold {
  background: rgba(251, 191, 36, 0.15);
  border: 1px solid rgba(251, 191, 36, 0.35);
  color: #fde68a;
  box-shadow: 0 0 15px rgba(251, 191, 36, 0.2);
}

.badge-glow-green {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.35);
  color: #6ee7b7;
  box-shadow: 0 0 15px rgba(16, 185, 129, 0.2);
}

/* Gradient Texts */
.text-gradient-purple-cyan {
  background: linear-gradient(135deg, #c084fc 0%, #38bdf8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.text-gradient-gold {
  background: linear-gradient(135deg, #fef08a 0%, #f59e0b 50%, #d97706 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.text-gradient-white {
  background: linear-gradient(180deg, #ffffff 30%, #94a3b8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Cyber Buttons */
.btn-cyber-primary {
  background: linear-gradient(135deg, #7c3aed 0%, #4f46e5 100%);
  color: #ffffff;
  font-weight: 700;
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 0 25px rgba(124, 58, 237, 0.45);
  border-radius: 12px;
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
}
.btn-cyber-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 35px rgba(124, 58, 237, 0.65);
}

.btn-cyber-gold {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #0f172a;
  font-weight: 800;
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 0 25px rgba(245, 158, 11, 0.4);
  border-radius: 12px;
  transition: all 0.25s ease;
}
.btn-cyber-gold:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 35px rgba(245, 158, 11, 0.65);
}

.btn-cyber-outline {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-main);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  font-weight: 600;
  backdrop-filter: blur(8px);
  transition: all 0.25s ease;
}
.btn-cyber-outline:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-2px);
}

/* Game Card Styles */
.game-card {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.07);
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}

.game-card:hover {
  transform: translateY(-6px) scale(1.02);
  border-color: rgba(139, 92, 246, 0.5);
  box-shadow: 0 14px 30px -8px rgba(0, 0, 0, 0.7), 0 0 20px rgba(139, 92, 246, 0.3);
}

.game-card .poster-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #111827;
}

.game-card .poster-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.game-card:hover .poster-wrapper img {
  transform: scale(1.08);
}

.game-card .play-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(12, 18, 32, 0.2) 0%, rgba(12, 18, 32, 0.95) 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  opacity: 0;
  gap: 8px;
  transition: opacity 0.25s ease;
  backdrop-filter: blur(3px);
  padding: 12px;
}

.game-card:hover .play-overlay {
  opacity: 1;
}

/* Category Filter Tabs */
.cat-tab {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
  border-radius: 30px;
  padding: 8px 18px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.cat-tab:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
}

.cat-tab.active {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.35) 0%, rgba(6, 182, 212, 0.35) 100%);
  border-color: var(--accent-purple);
  color: #ffffff;
  box-shadow: 0 0 15px rgba(139, 92, 246, 0.35);
}

/* Reseller Pricing Cards */
.pricing-card {
  position: relative;
  background: rgba(15, 23, 42, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  padding: 32px 24px;
  transition: all 0.35s ease;
}

.pricing-card:hover {
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-4px);
}

.pricing-card.featured {
  background: linear-gradient(180deg, rgba(30, 27, 75, 0.75) 0%, rgba(15, 23, 42, 0.85) 100%);
  border: 2px solid var(--accent-purple);
  box-shadow: 0 0 35px rgba(139, 92, 246, 0.25);
}

/* Live Simulator / Demo Modal */
.demo-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(3, 7, 18, 0.88);
  backdrop-filter: blur(14px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.demo-modal.active {
  opacity: 1;
  pointer-events: auto;
}

.demo-modal-dialog {
  background: #0d1322;
  border: 1px solid rgba(139, 92, 246, 0.35);
  border-radius: 20px;
  width: 100%;
  max-width: 980px;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.9), 0 0 40px rgba(139, 92, 246, 0.2);
  transform: scale(0.95);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.demo-modal.active .demo-modal-dialog {
  transform: scale(1);
}

/* Slot Canvas & Aviator Canvas */
.game-viewport {
  width: 100%;
  min-height: 480px;
  background: radial-gradient(circle at center, #131c31 0%, #080c16 100%);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* Animated Pulse Dot */
.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-green);
  box-shadow: 0 0 10px var(--accent-green);
  display: inline-block;
  animation: pulse-glow 1.5s infinite;
}

@keyframes pulse-glow {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

@keyframes float-chip {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-10px) rotate(4deg); }
}

.floating-anim {
  animation: float-chip 6s ease-in-out infinite;
}
