@tailwind base;
@tailwind components;
@tailwind utilities;

@layer base {
  :root {
    /* Background colors - Dark gaming theme */
    --background: 222 47% 6%;
    --foreground: 210 40% 98%;

    /* Card surfaces */
    --card: 222 47% 9%;
    --card-foreground: 210 40% 98%;

    /* Popover */
    --popover: 222 47% 8%;
    --popover-foreground: 210 40% 98%;

    /* Primary - Electric Cyan */
    --primary: 187 100% 42%;
    --primary-foreground: 222 47% 6%;

    /* Secondary - Muted dark */
    --secondary: 222 30% 14%;
    --secondary-foreground: 210 40% 90%;

    /* Muted surfaces */
    --muted: 222 30% 12%;
    --muted-foreground: 215 20% 55%;

    /* Accent - Orange CTA */
    --accent: 16 100% 50%;
    --accent-foreground: 0 0% 100%;

    /* Destructive */
    --destructive: 0 84% 60%;
    --destructive-foreground: 210 40% 98%;

    /* Borders & inputs */
    --border: 222 30% 18%;
    --input: 222 30% 16%;
    --ring: 187 100% 42%;

    --radius: 0.75rem;

    /* Custom colors */
    --success: 142 76% 36%;
    --warning: 38 92% 50%;
    --info: 199 89% 48%;

    /* Gradients */
    --gradient-primary: linear-gradient(135deg, hsl(187 100% 42%) 0%, hsl(199 89% 48%) 100%);
    --gradient-accent: linear-gradient(135deg, hsl(16 100% 50%) 0%, hsl(38 92% 50%) 100%);
    --gradient-dark: linear-gradient(180deg, hsl(222 47% 8%) 0%, hsl(222 47% 4%) 100%);
    --gradient-card: linear-gradient(145deg, hsl(222 47% 11%) 0%, hsl(222 47% 7%) 100%);
    --gradient-glow: radial-gradient(ellipse at center, hsl(187 100% 42% / 0.15) 0%, transparent 70%);

    /* Shadows */
    --shadow-sm: 0 2px 8px -2px hsl(222 47% 4% / 0.6);
    --shadow-md: 0 8px 24px -8px hsl(222 47% 4% / 0.8);
    --shadow-lg: 0 16px 48px -16px hsl(222 47% 4% / 0.9);
    --shadow-glow: 0 0 40px hsl(187 100% 42% / 0.3);
    --shadow-accent: 0 4px 24px hsl(16 100% 50% / 0.4);

    /* Sidebar */
    --sidebar-background: 222 47% 8%;
    --sidebar-foreground: 210 40% 90%;
    --sidebar-primary: 187 100% 42%;
    --sidebar-primary-foreground: 222 47% 6%;
    --sidebar-accent: 222 30% 14%;
    --sidebar-accent-foreground: 210 40% 90%;
    --sidebar-border: 222 30% 18%;
    --sidebar-ring: 187 100% 42%;
  }
}

@layer base {
  * {
    @apply border-border;
  }

  html {
    scroll-behavior: smooth;
  }

  body {
    @apply bg-background text-foreground font-sans antialiased;
    font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
  }

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

  ::-webkit-scrollbar-track {
    @apply bg-muted/30;
  }

  ::-webkit-scrollbar-thumb {
    @apply bg-border rounded-full;
  }

  ::-webkit-scrollbar-thumb:hover {
    @apply bg-muted-foreground/50;
  }
}

@layer components {
  /* Card hover effects */
  .card-hover {
    @apply transition-all duration-300 ease-out;
  }
  
  .card-hover:hover {
    @apply -translate-y-1;
    box-shadow: var(--shadow-md), 0 0 20px hsl(187 100% 42% / 0.1);
  }

  /* Glow effects */
  .glow-primary {
    box-shadow: var(--shadow-glow);
  }

  .glow-accent {
    box-shadow: var(--shadow-accent);
  }

  /* Text gradients */
  .text-gradient-primary {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
  }

  .text-gradient-accent {
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
  }

  /* Background patterns */
  .bg-grid {
    background-image: 
      linear-gradient(hsl(var(--border) / 0.3) 1px, transparent 1px),
      linear-gradient(90deg, hsl(var(--border) / 0.3) 1px, transparent 1px);
    background-size: 40px 40px;
  }

  /* Animation utilities */
  .animate-float {
    animation: float 3s ease-in-out infinite;
  }

  .animate-pulse-glow {
    animation: pulseGlow 2s ease-in-out infinite;
  }

  .animate-slide-up {
    animation: slideUp 0.5s ease-out forwards;
  }

  .animate-fade-in {
    animation: fadeIn 0.4s ease-out forwards;
  }
}

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

@keyframes pulseGlow {
  0%, 100% { 
    box-shadow: 0 0 20px hsl(187 100% 42% / 0.3);
  }
  50% { 
    box-shadow: 0 0 40px hsl(187 100% 42% / 0.5);
  }
}

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

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Staggered animations */
.stagger-1 { animation-delay: 0.1s; }
.stagger-2 { animation-delay: 0.2s; }
.stagger-3 { animation-delay: 0.3s; }
.stagger-4 { animation-delay: 0.4s; }
.stagger-5 { animation-delay: 0.5s; }
.stagger-6 { animation-delay: 0.6s; }
