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

/* EnergieProfis Design System - German Renewable Energy Platform */

@layer base {
  :root {
    /* Base System Colors */
    --background: 0 0% 100%;
    --foreground: 218 11% 15%;
    --card: 0 0% 100%;
    --card-foreground: 218 11% 15%;
    --popover: 0 0% 100%;
    --popover-foreground: 218 11% 15%;
    
    /* Energy Type Colors - Solar Orange */
    --solar-primary: 22 95% 58%;
    --solar-secondary: 31 95% 60%;
    --solar-light: 31 100% 85%;
    --solar-dark: 22 85% 45%;
    
    /* Energy Type Colors - Wind Blue */
    --wind-primary: 207 90% 54%;
    --wind-secondary: 207 90% 61%;
    --wind-light: 207 100% 85%;
    --wind-dark: 207 80% 41%;
    
    /* Brand Colors */
    --primary: 218 47% 18%;
    --primary-foreground: 210 40% 98%;
    --secondary: 210 20% 94%;
    --secondary-foreground: 218 47% 18%;
    
    /* Utility Colors */
    --muted: 210 20% 94%;
    --muted-foreground: 218 11% 50%;
    --accent: 210 20% 92%;
    --accent-foreground: 218 47% 18%;
    --destructive: 0 84% 60%;
    --destructive-foreground: 210 40% 98%;
    --border: 214 32% 91%;
    --input: 214 32% 91%;
    --ring: 218 47% 18%;
    
    /* Energy Gradients */
    --gradient-solar: linear-gradient(135deg, hsl(var(--solar-primary)) 0%, hsl(var(--solar-secondary)) 100%);
    --gradient-wind: linear-gradient(135deg, hsl(var(--wind-primary)) 0%, hsl(var(--wind-secondary)) 100%);
    --gradient-hero: linear-gradient(135deg, hsl(var(--primary)) 0%, hsl(218 47% 25%) 100%);
    
    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-solar: 0 8px 32px hsl(var(--solar-primary) / 0.25);
    --shadow-wind: 0 8px 32px hsl(var(--wind-primary) / 0.25);
    
    /* Animations */
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    
    --radius: 0.75rem;

    --sidebar-background: 0 0% 98%;

    --sidebar-foreground: 240 5.3% 26.1%;

    --sidebar-primary: 240 5.9% 10%;

    --sidebar-primary-foreground: 0 0% 98%;

    --sidebar-accent: 240 4.8% 95.9%;

    --sidebar-accent-foreground: 240 5.9% 10%;

    --sidebar-border: 220 13% 91%;

    --sidebar-ring: 217.2 91.2% 59.8%;
  }

  .dark {
    --background: 222.2 84% 4.9%;
    --foreground: 210 40% 98%;

    --card: 222.2 84% 4.9%;
    --card-foreground: 210 40% 98%;

    --popover: 222.2 84% 4.9%;
    --popover-foreground: 210 40% 98%;

    --primary: 210 40% 98%;
    --primary-foreground: 222.2 47.4% 11.2%;

    --secondary: 217.2 32.6% 17.5%;
    --secondary-foreground: 210 40% 98%;

    --muted: 217.2 32.6% 17.5%;
    --muted-foreground: 215 20.2% 65.1%;

    --accent: 217.2 32.6% 17.5%;
    --accent-foreground: 210 40% 98%;

    --destructive: 0 62.8% 30.6%;
    --destructive-foreground: 210 40% 98%;

    --border: 217.2 32.6% 17.5%;
    --input: 217.2 32.6% 17.5%;
    --ring: 212.7 26.8% 83.9%;
    --sidebar-background: 240 5.9% 10%;
    --sidebar-foreground: 240 4.8% 95.9%;
    --sidebar-primary: 224.3 76.3% 48%;
    --sidebar-primary-foreground: 0 0% 100%;
    --sidebar-accent: 240 3.7% 15.9%;
    --sidebar-accent-foreground: 240 4.8% 95.9%;
    --sidebar-border: 240 3.7% 15.9%;
    --sidebar-ring: 217.2 91.2% 59.8%;
  }
}

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

  body {
    @apply bg-background text-foreground font-sans;
  }

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

  ::-webkit-scrollbar-track {
    @apply bg-secondary;
  }

  ::-webkit-scrollbar-thumb {
    @apply bg-muted-foreground/30 rounded-full;
  }

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

  /* Smooth animations for all elements */
  * {
    transition: var(--transition-smooth);
  }

  /* Focus styles */
  *:focus-visible {
    @apply outline-none ring-2 ring-primary ring-offset-2 ring-offset-background;
  }

  /* Selection styles */
  ::selection {
    @apply bg-primary/20;
  }

  /* Custom gradient text utilities */
  .gradient-text-solar {
    background: var(--gradient-solar);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
  }

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

  /* Solar Calculator Animations */
  @keyframes float {
    0% { transform: translate(0, 0); }
    100% { transform: translate(-60px, -60px); }
  }

  @keyframes growUp {
    from { height: 0; }
  }

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

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

  /* Wind Calculator Animations */
  @keyframes windFlow {
    0% { transform: translate(0, 0) rotate(0deg); }
    100% { transform: translate(-60px, -60px) rotate(360deg); }
  }
}