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

body {
  background: #0a0a0f;
  color: #e0e0e0;
  font-family: 'Rajdhani', sans-serif;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background:
    linear-gradient(rgba(10,10,15,0.97), rgba(10,10,15,0.97)),
    repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(255,255,255,0.015) 2px, rgba(255,255,255,0.015) 4px);
  pointer-events: none;
  z-index: 0;
}

body::after {
  content: '';
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background:
    linear-gradient(90deg, transparent 49.5%, rgba(255,255,255,0.02) 49.5%, rgba(255,255,255,0.02) 50.5%, transparent 50.5%),
    linear-gradient(0deg, transparent 49.5%, rgba(255,255,255,0.02) 49.5%, rgba(255,255,255,0.02) 50.5%, transparent 50.5%);
  background-size: 60px 60px;
  pointer-events: none;
  z-index: 0;
}

#root { position: relative; z-index: 1; }

@keyframes glowPulse {
  0%, 100% { text-shadow: 0 0 20px rgba(255,100,100,0.5), 0 0 40px rgba(255,100,100,0.3), 0 0 80px rgba(255,100,100,0.1); }
  50% { text-shadow: 0 0 30px rgba(255,100,100,0.8), 0 0 60px rgba(255,100,100,0.5), 0 0 120px rgba(255,100,100,0.2); }
}

@keyframes statFill {
  from { width: 0%; }
}

@keyframes votePopIn {
  0% { transform: scale(0.5) translateY(0); opacity: 1; }
  100% { transform: scale(1.5) translateY(-40px); opacity: 0; }
}

@keyframes crownBounce {
  0%, 100% { transform: translateY(0) rotate(-5deg); }
  50% { transform: translateY(-8px) rotate(5deg); }
}

@keyframes cardEntrance {
  from { opacity: 0; transform: translateY(30px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes sparkle {
  0%, 100% { opacity: 0; transform: scale(0); }
  50% { opacity: 1; transform: scale(1); }
}

@keyframes scanline {
  0% { top: -10%; }
  100% { top: 110%; }
}

@keyframes borderGlow {
  0%, 100% { border-color: rgba(255,255,255,0.1); }
  50% { border-color: rgba(255,255,255,0.2); }
}

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

@keyframes typing {
  from { width: 0; }
  to { width: 100%; }
}

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

.stat-bar-fill {
  animation: statFill 1.5s ease-out forwards;
}

.vote-pop {
  animation: votePopIn 0.8s ease-out forwards;
}

.crown-bounce {
  animation: crownBounce 1.5s ease-in-out infinite;
}

.card-entrance {
  animation: cardEntrance 0.6s ease-out forwards;
}

.card-entrance:nth-child(1) { animation-delay: 0.1s; opacity: 0; }
.card-entrance:nth-child(2) { animation-delay: 0.3s; opacity: 0; }
.card-entrance:nth-child(3) { animation-delay: 0.5s; opacity: 0; }

.float-anim {
  animation: float 3s ease-in-out infinite;
}

.fade-slide-up {
  animation: fadeSlideUp 0.5s ease-out forwards;
}

.grok-card {
  background: linear-gradient(135deg, #0d1117 0%, #0a1628 100%);
  border: 1px solid rgba(59,130,246,0.3);
  box-shadow: 0 0 30px rgba(59,130,246,0.1), inset 0 0 30px rgba(59,130,246,0.05);
}
.grok-card:hover {
  border-color: rgba(59,130,246,0.6);
  box-shadow: 0 0 50px rgba(59,130,246,0.2), inset 0 0 50px rgba(59,130,246,0.08);
  transform: scale(1.02) translateY(-4px);
}

.chatgpt-card {
  background: linear-gradient(135deg, #0d1117 0%, #0a1f1a 100%);
  border: 1px solid rgba(16,163,127,0.3);
  box-shadow: 0 0 30px rgba(16,163,127,0.1), inset 0 0 30px rgba(16,163,127,0.05);
}
.chatgpt-card:hover {
  border-color: rgba(16,163,127,0.6);
  box-shadow: 0 0 50px rgba(16,163,127,0.2), inset 0 0 50px rgba(16,163,127,0.08);
  transform: scale(1.02) translateY(-4px);
}

.gemini-card {
  background: linear-gradient(135deg, #0d1117 0%, #1a0d1f 100%);
  border: 1px solid rgba(168,85,247,0.3);
  box-shadow: 0 0 30px rgba(168,85,247,0.1), inset 0 0 30px rgba(168,85,247,0.05);
}
.gemini-card:hover {
  border-color: rgba(168,85,247,0.6);
  box-shadow: 0 0 50px rgba(168,85,247,0.2), inset 0 0 50px rgba(168,85,247,0.08);
  transform: scale(1.02) translateY(-4px);
}

.ai-card {
  transition: all 0.3s ease;
  border-radius: 16px;
  padding: 24px;
  position: relative;
  overflow: hidden;
}

.ai-card::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.02) 0%, transparent 70%);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}

.ai-card:hover::before { opacity: 1; }

.battle-btn {
  position: relative;
  overflow: hidden;
  transition: all 0.2s ease;
}

.battle-btn::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255,255,255,0.1);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.5s, height 0.5s;
}

.battle-btn:hover::after {
  width: 300px;
  height: 300px;
}

.battle-btn:active {
  transform: scale(0.95);
}

.speech-bubble {
  position: relative;
  border-radius: 16px;
  padding: 16px;
  min-height: 120px;
}

.speech-bubble::after {
  content: '';
  position: absolute;
  top: -8px;
  left: 24px;
  width: 16px;
  height: 16px;
  transform: rotate(45deg);
}

.grok-bubble { background: rgba(59,130,246,0.1); border: 1px solid rgba(59,130,246,0.2); }
.grok-bubble::after { background: rgba(59,130,246,0.1); border-left: 1px solid rgba(59,130,246,0.2); border-top: 1px solid rgba(59,130,246,0.2); }

.chatgpt-bubble { background: rgba(16,163,127,0.1); border: 1px solid rgba(16,163,127,0.2); }
.chatgpt-bubble::after { background: rgba(16,163,127,0.1); border-left: 1px solid rgba(16,163,127,0.2); border-top: 1px solid rgba(16,163,127,0.2); }

.gemini-bubble { background: rgba(168,85,247,0.1); border: 1px solid rgba(168,85,247,0.2); }
.gemini-bubble::after { background: rgba(168,85,247,0.1); border-left: 1px solid rgba(168,85,247,0.2); border-top: 1px solid rgba(168,85,247,0.2); }

.vote-btn {
  transition: all 0.2s ease;
  cursor: pointer;
}
.vote-btn:hover { transform: scale(1.05); }
.vote-btn:active { transform: scale(0.95); }

.challenge-btn {
  transition: all 0.2s ease;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}
.challenge-btn:hover { transform: translateY(-2px); }
.challenge-btn.active { transform: scale(0.98); }

.scoreboard-glow {
  background: linear-gradient(135deg, rgba(20,20,30,0.9) 0%, rgba(10,10,20,0.95) 100%);
  border: 1px solid rgba(255,255,255,0.1);
  backdrop-filter: blur(10px);
}

.section-divider {
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(255,100,100,0.3), rgba(100,100,255,0.3), transparent);
  margin: 40px 0;
}

.quiz-option {
  transition: all 0.2s ease;
  cursor: pointer;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 12px;
  padding: 12px 16px;
}
.quiz-option:hover {
  border-color: rgba(255,255,255,0.3);
  background: rgba(255,255,255,0.05);
  transform: translateX(4px);
}

::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #0a0a0f; }
::-webkit-scrollbar-thumb { background: #2a2a3f; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #3a3a5f; }