* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Space Grotesk', sans-serif;
}

.font-mono {
  font-family: 'JetBrains Mono', monospace;
}

/* Noise texture overlay */
.bg-noise {
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

/* Wobble animation */
@keyframes wobble {
  0%, 100% { transform: rotate(-2deg); }
  50% { transform: rotate(2deg); }
}

.animate-wobble {
  animation: wobble 2s ease-in-out infinite;
}

/* Vibe slider styling */
.vibe-slider {
  -webkit-appearance: none;
  appearance: none;
  border-radius: 9999px;
  cursor: pointer;
}

.vibe-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: white;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
  transition: transform 0.2s;
}

.vibe-slider::-webkit-slider-thumb:hover {
  transform: scale(1.2);
}

.vibe-slider::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: white;
  cursor: pointer;
  border: none;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

/* Modal animation */
@keyframes modalIn {
  from {
    opacity: 0;
    transform: scale(0.9) translateY(20px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.animate-modal-in {
  animation: modalIn 0.3s ease-out;
}

/* Toast animation */
@keyframes bounceIn {
  0% {
    opacity: 0;
    transform: translateX(100px);
  }
  50% {
    transform: translateX(-10px);
  }
  100% {
    opacity: 1;
    transform: translateX(0);
  }
}

.animate-bounce-in {
  animation: bounceIn 0.4s ease-out;
}

/* Confetti */
@keyframes confettiFall {
  0% {
    transform: translateY(-100vh) rotate(0deg);
    opacity: 1;
  }
  100% {
    transform: translateY(100vh) rotate(720deg);
    opacity: 0;
  }
}

.confetti-container {
  overflow: hidden;
}

.confetti {
  position: absolute;
  top: 0;
  width: 10px;
  height: 10px;
  animation: confettiFall 2s linear forwards;
}

.confetti:nth-child(odd) {
  border-radius: 50%;
}

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

::-webkit-scrollbar-track {
  background: rgba(255,255,255,0.05);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb {
  background: rgba(139, 92, 246, 0.5);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(139, 92, 246, 0.7);
}

/* Focus states */
button:focus, input:focus, textarea:focus {
  outline: none;
  ring: 2px;
  ring-color: rgba(139, 92, 246, 0.5);
}

/* Selection */
::selection {
  background: rgba(236, 72, 153, 0.4);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .text-5xl {
    font-size: 2rem;
  }
  
  .text-3xl {
    font-size: 1.5rem;
  }
}

/* Glassmorphism card hover glow */
.hover\:shadow-lg:hover {
  box-shadow: 0 0 30px rgba(139, 92, 246, 0.2);
}

/* Star button animation */
button.text-xl {
  transition: transform 0.2s, opacity 0.2s;
}

button.text-xl:active {
  transform: scale(1.3);
}