* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

:root {
  --bg-primary: #0a0a12;
  --bg-secondary: #12121f;
  --bg-card: rgba(255, 255, 255, 0.04);
  --border-glow: rgba(236, 72, 153, 0.3);
  --text-primary: #f0e6f6;
  --text-secondary: #8b7fa3;
  --neon-pink: #ec4899;
  --neon-cyan: #06b6d4;
  --neon-gold: #f59e0b;
  --neon-purple: #a855f7;
  --neon-green: #22c55e;
}

body {
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: 'Bricolage Grotesque', sans-serif;
  overflow-x: hidden;
  min-height: 100vh;
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(ellipse 80% 50% at 50% 0%, rgba(168, 85, 247, 0.12) 0%, transparent 60%),
    radial-gradient(ellipse 60% 40% at 80% 100%, rgba(236, 72, 153, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse 40% 30% at 10% 60%, rgba(6, 182, 212, 0.06) 0%, transparent 50%);
  pointer-events: none;
  z-index: 0;
}

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

/* Big button animations */
@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 30px rgba(236, 72, 153, 0.3), 0 0 60px rgba(168, 85, 247, 0.15); }
  50% { box-shadow: 0 0 50px rgba(236, 72, 153, 0.5), 0 0 100px rgba(168, 85, 247, 0.25); }
}

@keyframes button-press {
  0% { transform: scale(1); }
  40% { transform: scale(0.9); }
  70% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

@keyframes float-up {
  0% { opacity: 1; transform: translateY(0) scale(1); }
  50% { opacity: 0.8; }
  100% { opacity: 0; transform: translateY(-120px) scale(0.5); }
}

@keyframes score-pop {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-2px); }
  75% { transform: translateX(2px); }
}

@keyframes golden-float {
  0% { transform: translateX(-80px) translateY(0) rotate(0deg); opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { transform: translateX(calc(100vw + 80px)) translateY(-30px) rotate(360deg); opacity: 0; }
}

@keyframes confetti-fall {
  0% { transform: translateY(-10px) rotate(0deg); opacity: 1; }
  100% { transform: translateY(100vh) rotate(720deg); opacity: 0; }
}

@keyframes combo-fire {
  0%, 100% { text-shadow: 0 0 10px rgba(245, 158, 11, 0.8), 0 0 20px rgba(239, 68, 68, 0.4); }
  50% { text-shadow: 0 0 20px rgba(245, 158, 11, 1), 0 0 40px rgba(239, 68, 68, 0.8), 0 0 60px rgba(245, 158, 11, 0.3); }
}

@keyframes slide-in-right {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

@keyframes slide-in-up {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

@keyframes fade-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes ripple {
  0% { transform: scale(0); opacity: 0.6; }
  100% { transform: scale(4); opacity: 0; }
}

.big-button {
  animation: pulse-glow 2s ease-in-out infinite;
  transition: all 0.1s ease;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
}

.big-button:active, .big-button.pressed {
  animation: button-press 0.3s ease forwards;
}

.big-button .ripple-effect {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  animation: ripple 0.6s ease-out forwards;
  pointer-events: none;
}

.float-particle {
  position: absolute;
  animation: float-up 0.8s ease-out forwards;
  pointer-events: none;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  color: var(--neon-gold);
  text-shadow: 0 0 10px rgba(245, 158, 11, 0.5);
  z-index: 100;
}

.score-pop {
  animation: score-pop 0.15s ease-out;
}

.screen-shake {
  animation: shake 0.1s ease;
}

.golden-berry {
  position: fixed;
  animation: golden-float 6s linear forwards;
  cursor: pointer;
  z-index: 200;
  font-size: 48px;
  filter: drop-shadow(0 0 20px rgba(245, 158, 11, 0.8));
  transition: transform 0.1s;
}

.golden-berry:hover {
  transform: scale(1.3);
}

.confetti-piece {
  position: fixed;
  top: -10px;
  width: 10px;
  height: 10px;
  animation: confetti-fall 3s ease-in forwards;
  pointer-events: none;
  z-index: 300;
}

.combo-text {
  animation: combo-fire 0.5s ease-in-out infinite;
}

.glass-card {
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition: all 0.3s ease;
}

.glass-card:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.1);
}

.glass-card.affordable {
  border-color: rgba(236, 72, 153, 0.3);
  box-shadow: 0 0 15px rgba(236, 72, 153, 0.1);
}

.glass-card.affordable:hover {
  border-color: rgba(236, 72, 153, 0.5);
  box-shadow: 0 0 25px rgba(236, 72, 153, 0.2);
}

.achievement-toast {
  animation: slide-in-right 0.5s ease-out;
}

.upgrade-drawer {
  animation: slide-in-up 0.3s ease-out;
}

.fade-in {
  animation: fade-in 0.5s ease-out;
}

/* Scrollbar styling */
::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.02);
}

::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* Mobile bottom drawer */
@media (max-width: 768px) {
  .upgrade-panel {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    max-height: 60vh;
    border-radius: 20px 20px 0 0;
    z-index: 50;
  }
}

/* Button level colors */
.btn-level-1 { background: linear-gradient(135deg, #ec4899, #a855f7); }
.btn-level-2 { background: linear-gradient(135deg, #a855f7, #6366f1); }
.btn-level-3 { background: linear-gradient(135deg, #6366f1, #06b6d4); }
.btn-level-4 { background: linear-gradient(135deg, #06b6d4, #22c55e); }
.btn-level-5 { background: linear-gradient(135deg, #f59e0b, #ef4444); }