/* ============================================
   SMARTGARTEN.DE - Design System 2026
   Modern, Premium, Glassmorphism
   ============================================ */

/* === CSS Reset === */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* === Root Variables - Light Mode === */
:root {
  /* Primary Colors */
  --color-primary: #10b981;
  --color-primary-dark: #059669;
  --color-primary-light: #34d399;
  --color-primary-glow: rgba(16, 185, 129, 0.4);

  /* Secondary Colors */
  --color-secondary: #3b82f6;
  --color-secondary-dark: #2563eb;
  --color-secondary-light: #60a5fa;

  /* Accent Colors */
  --color-accent: #f59e0b;
  --color-accent-dark: #d97706;
  --color-accent-light: #fbbf24;

  /* Neutrals */
  --color-bg: #fafafa;
  --color-bg-alt: #f4f4f5;
  --color-surface: #ffffff;
  --color-surface-elevated: #ffffff;
  --color-text: #18181b;
  --color-text-muted: #71717a;
  --color-text-subtle: #a1a1aa;
  --color-border: #e4e4e7;
  --color-border-subtle: #f4f4f5;

  /* Semantic Colors */
  --color-success: #22c55e;
  --color-warning: #eab308;
  --color-error: #ef4444;
  --color-info: #0ea5e9;

  /* Gradients */
  --gradient-primary: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  --gradient-surface: linear-gradient(180deg, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0.7) 100%);
  --gradient-hero: linear-gradient(135deg, #ecfdf5 0%, #eff6ff 50%, #fef3c7 100%);
  --gradient-mesh: radial-gradient(at 40% 20%, hsla(160, 100%, 76%, 0.3) 0px, transparent 50%),
    radial-gradient(at 80% 0%, hsla(217, 91%, 75%, 0.3) 0px, transparent 50%),
    radial-gradient(at 0% 50%, hsla(45, 100%, 70%, 0.2) 0px, transparent 50%);

  /* Typography */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-display: 'Outfit', var(--font-sans);
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  /* Font Sizes - Fluid Typography */
  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
  --text-sm: clamp(0.875rem, 0.8rem + 0.375vw, 1rem);
  --text-base: clamp(1rem, 0.9rem + 0.5vw, 1.125rem);
  --text-lg: clamp(1.125rem, 1rem + 0.625vw, 1.25rem);
  --text-xl: clamp(1.25rem, 1.1rem + 0.75vw, 1.5rem);
  --text-2xl: clamp(1.5rem, 1.3rem + 1vw, 2rem);
  --text-3xl: clamp(1.875rem, 1.5rem + 1.875vw, 2.5rem);
  --text-4xl: clamp(2.25rem, 1.75rem + 2.5vw, 3.5rem);
  --text-5xl: clamp(3rem, 2rem + 5vw, 5rem);

  /* Spacing */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;

  /* Border Radius */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-2xl: 1.5rem;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  --shadow-glow: 0 0 40px var(--color-primary-glow);

  /* Glassmorphism */
  --glass-bg: rgba(255, 255, 255, 0.7);
  --glass-border: rgba(255, 255, 255, 0.3);
  --glass-blur: blur(20px);

  /* Transitions */
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 350ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-spring: 500ms cubic-bezier(0.34, 1.56, 0.64, 1);

  /* Z-Index Scale */
  --z-dropdown: 100;
  --z-sticky: 200;
  --z-fixed: 300;
  --z-modal: 400;
  --z-popover: 500;
  --z-tooltip: 600;

  /* Container */
  --container-max: 1280px;
  --container-padding: var(--space-4);
}

/* === Dark Mode === */
[data-theme="dark"],
.dark {
  --color-bg: #0a0a0a;
  --color-bg-alt: #18181b;
  --color-surface: #1c1c1f;
  --color-surface-elevated: #27272a;
  --color-text: #fafafa;
  --color-text-muted: #a1a1aa;
  --color-text-subtle: #71717a;
  --color-border: #3f3f46;
  --color-border-subtle: #27272a;

  --gradient-hero: linear-gradient(135deg, #022c22 0%, #0c1929 50%, #1c1a00 100%);
  --gradient-surface: linear-gradient(180deg, rgba(28, 28, 31, 0.9) 0%, rgba(28, 28, 31, 0.7) 100%);
  --gradient-mesh: radial-gradient(at 40% 20%, hsla(160, 100%, 30%, 0.2) 0px, transparent 50%),
    radial-gradient(at 80% 0%, hsla(217, 91%, 40%, 0.2) 0px, transparent 50%),
    radial-gradient(at 0% 50%, hsla(45, 100%, 40%, 0.15) 0px, transparent 50%);

  --glass-bg: rgba(28, 28, 31, 0.8);
  --glass-border: rgba(63, 63, 70, 0.5);

  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -2px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -4px rgba(0, 0, 0, 0.3);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 8px 10px -6px rgba(0, 0, 0, 0.4);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --color-bg: #0a0a0a;
    --color-bg-alt: #18181b;
    --color-surface: #1c1c1f;
    --color-surface-elevated: #27272a;
    --color-text: #fafafa;
    --color-text-muted: #a1a1aa;
    --color-text-subtle: #71717a;
    --color-border: #3f3f46;
    --color-border-subtle: #27272a;
    --gradient-hero: linear-gradient(135deg, #022c22 0%, #0c1929 50%, #1c1a00 100%);
    --gradient-surface: linear-gradient(180deg, rgba(28, 28, 31, 0.9) 0%, rgba(28, 28, 31, 0.7) 100%);
    --gradient-mesh: radial-gradient(at 40% 20%, hsla(160, 100%, 30%, 0.2) 0px, transparent 50%),
      radial-gradient(at 80% 0%, hsla(217, 91%, 40%, 0.2) 0px, transparent 50%),
      radial-gradient(at 0% 50%, hsla(45, 100%, 40%, 0.15) 0px, transparent 50%);
    --glass-bg: rgba(28, 28, 31, 0.8);
    --glass-border: rgba(63, 63, 70, 0.5);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -2px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -4px rgba(0, 0, 0, 0.3);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 8px 10px -6px rgba(0, 0, 0, 0.4);
  }
}

/* === Base Styles === */
html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  min-height: 100vh;
  overflow-x: hidden;
}

/* === Typography === */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-text);
  text-wrap: balance;
}

h1 {
  font-size: var(--text-5xl);
}

h2 {
  font-size: var(--text-4xl);
}

h3 {
  font-size: var(--text-3xl);
}

h4 {
  font-size: var(--text-2xl);
}

h5 {
  font-size: var(--text-xl);
}

h6 {
  font-size: var(--text-lg);
}

p {
  max-width: 70ch;
  text-wrap: pretty;
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--color-primary-dark);
}

strong,
b {
  font-weight: 600;
}

/* === Layout === */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

.section {
  padding: var(--space-16) 0;
}

.section-lg {
  padding: var(--space-24) 0;
}

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

.text-muted {
  color: var(--color-text-muted);
}

.text-center {
  text-align: center;
}

.flex {
  display: flex;
}

.flex-col {
  flex-direction: column;
}

.items-center {
  align-items: center;
}

.justify-center {
  justify-content: center;
}

.justify-between {
  justify-content: space-between;
}

.gap-2 {
  gap: var(--space-2);
}

.gap-4 {
  gap: var(--space-4);
}

.gap-6 {
  gap: var(--space-6);
}

.gap-8 {
  gap: var(--space-8);
}

.grid {
  display: grid;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* === Glass Card === */
.glass {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl);
}

/* === Animations === */
@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

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

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes float {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-10px);
  }
}

@keyframes pulse-glow {

  0%,
  100% {
    box-shadow: 0 0 20px var(--color-primary-glow);
  }

  50% {
    box-shadow: 0 0 40px var(--color-primary-glow);
  }
}

@keyframes gradient-shift {
  0% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

.animate-fade-in {
  animation: fadeIn var(--transition-base) ease-out forwards;
}

.animate-slide-up {
  animation: slideUp var(--transition-slow) ease-out forwards;
}

.animate-slide-down {
  animation: slideDown var(--transition-slow) ease-out forwards;
}

.animate-scale-in {
  animation: scaleIn var(--transition-spring) forwards;
}

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

/* Stagger animations */
.stagger>* {
  animation: slideUp var(--transition-slow) ease-out forwards;
}

.stagger>*:nth-child(1) {
  animation-delay: 0ms;
}

.stagger>*:nth-child(2) {
  animation-delay: 100ms;
}

.stagger>*:nth-child(3) {
  animation-delay: 200ms;
}

.stagger>*:nth-child(4) {
  animation-delay: 300ms;
}

.stagger>*:nth-child(5) {
  animation-delay: 400ms;
}

.stagger>*:nth-child(6) {
  animation-delay: 500ms;
}

/* === Focus States === */
:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* === Selection === */
::selection {
  background: var(--color-primary);
  color: white;
}

/* === Scrollbar === */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: var(--color-bg-alt);
}

::-webkit-scrollbar-thumb {
  background: var(--color-border);
  border-radius: var(--radius-full);
  border: 2px solid var(--color-bg-alt);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-text-muted);
}

/* === Media Queries === */
@media (min-width: 640px) {
  :root {
    --container-padding: var(--space-6);
  }
}

@media (min-width: 1024px) {
  :root {
    --container-padding: var(--space-8);
  }
}

/* === Print Styles === */
@media print {
  .no-print {
    display: none !important;
  }
}