/* Resets & Base */
* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  padding: 0;
}
html {
  scroll-behavior: smooth;
}
body {
  font-family: Inter, system-ui, Segoe UI, Roboto, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-touch-callout: none;
  position: relative;
}

/* Replaced gradient backgrounds with particle animations */
/* Particle container for seasonal animations */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  pointer-events: none;
}

/* Optimized particle styling with better performance */
.particle {
  position: fixed;
  display: inline-block;
  line-height: 1;
  pointer-events: none;
  z-index: 9999999;
  will-change: transform, opacity;
  transform: translate3d(0, 0, 0);
  backface-visibility: hidden;
  -webkit-font-smoothing: antialiased;
  contain: layout style paint;
}

/* Improved particle animations with natural cubic-bezier easing */
.particle-winter {
  color: white;
  text-shadow: 0 0 5px rgba(255, 255, 255, 0.8);
  animation: particle-fall-winter 30s cubic-bezier(0.25, 0.46, 0.45, 0.94) infinite;
}

.particle-spring {
  color: #ff69b4;
  text-shadow: 0 0 5px rgba(255, 105, 180, 0.6);
  animation: particle-fall-spring 35s cubic-bezier(0.33, 0.05, 0.35, 1) infinite;
}

.particle-summer {
  color: #ffd700;
  text-shadow: 0 0 8px rgba(255, 215, 0, 0.8);
  animation: particle-fall-summer 40s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

.particle-autumn {
  color: #ff8c00;
  text-shadow: 0 0 5px rgba(255, 140, 0, 0.6);
  animation: particle-fall-autumn 32s cubic-bezier(0.45, 0.05, 0.55, 0.95) infinite;
}

/* Optimized keyframes - only transform and opacity for best performance */
@keyframes particle-fall-winter {
  0% {
    transform: translate3d(0, -25px, 0) rotate(0deg);
    opacity: 0;
  }
  10% {
    opacity: 0.9;
  }
  85% {
    opacity: 0.8;
  }
  100% {
    /* Extended fall distance from 100vh to 120vh to prevent particle accumulation at bottom */
    transform: translate3d(-15px, 120vh, 0) rotate(360deg);
    opacity: 0;
  }
}

@keyframes particle-fall-spring {
  0% {
    transform: translate3d(0, -25px, 0) rotate(0deg) scale(0.8);
    opacity: 0;
  }
  10% {
    opacity: 0.85;
  }
  50% {
    transform: translate3d(25px, 50vh, 0) rotate(180deg) scale(1);
  }
  85% {
    opacity: 0.7;
  }
  100% {
    /* Extended fall distance from 100vh to 120vh */
    transform: translate3d(-20px, 120vh, 0) rotate(360deg) scale(0.9);
    opacity: 0;
  }
}

@keyframes particle-fall-summer {
  0% {
    transform: translate3d(0, -25px, 0) rotate(0deg) scale(1);
    opacity: 0;
  }
  15% {
    opacity: 0.95;
  }
  50% {
    transform: translate3d(30px, 50vh, 0) rotate(90deg) scale(1.1);
  }
  80% {
    opacity: 0.9;
  }
  100% {
    /* Extended fall distance from 100vh to 120vh */
    transform: translate3d(-25px, 120vh, 0) rotate(180deg) scale(0.95);
    opacity: 0;
  }
}

@keyframes particle-fall-autumn {
  0% {
    transform: translate3d(0, -25px, 0) rotate(0deg) rotateY(0deg);
    opacity: 0;
  }
  10% {
    opacity: 0.85;
  }
  50% {
    transform: translate3d(35px, 50vh, 0) rotate(180deg) rotateY(180deg);
  }
  85% {
    opacity: 0.75;
  }
  100% {
    /* Extended fall distance from 100vh to 120vh */
    transform: translate3d(-30px, 120vh, 0) rotate(360deg) rotateY(360deg);
    opacity: 0;
  }
}

/* Added prefers-reduced-motion support for accessibility */
@media (prefers-reduced-motion: reduce) {
  .particle {
    animation: none !important;
    opacity: 0.3;
  }
}

/* Responsive particle adjustments */
@media (max-width: 768px) {
  .particle {
    opacity: 0.6;
    font-size: 0.8em !important;
  }

  .particle-winter,
  .particle-spring,
  .particle-summer,
  .particle-autumn {
    animation-duration: 22s !important;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .particle {
    opacity: 0.7;
  }
}

body.ready::before {
  opacity: 1;
}

img {
  max-width: 100%;
  display: block;
}
a {
  color: var(--text);
  text-decoration: none;
}
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 24px;
}
strong {
  font-weight: 600;
  color: var(--text);
}
footer {
  margin: 40px 0;
  color: var(--muted);
  font-size: 14px;
  text-align: center;
}
.small {
  font-size: 13px;
  color: var(--muted);
}
::selection {
  background: transparent;
}

/* Harcopy / Anti-Drag (wie gehabt) */
* {
  -webkit-user-select: none !important;
  -ms-user-select: none !important;
  user-select: none !important;
}
img {
  -webkit-user-drag: none;
  pointer-events: none !important;
}
@media screen {
  body:after {
    content: "";
    pointer-events: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(.5px);
    /* Reduced z-index so particles can appear on top */
    z-index: 1;
  }
}
