@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

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

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

@keyframes spin-slow {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.fade-up {
  opacity: 0;
  animation: fadeUp 0.8s ease-out forwards;
}

.animate-floating {
  position: relative;
  animation: floating 4s ease-in-out infinite;
}

.animate-spin-slow {
  animation: spin-slow 8s linear infinite;
}

.animate-floating::before {
  content: '';
  position: absolute;
  inset: -40px;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.4) 0%, rgba(168, 85, 247, 0.4) 50%, transparent 70%);
  filter: blur(40px);
  opacity: 0.4;
  z-index: -1;
  border-radius: 50%;
}

.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Typography Scale */
h1 {
  letter-spacing: -0.02em;
}

/* Spacing Consistency */
:root {
  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 1.5rem;
  --spacing-lg: 2rem;
  --spacing-xl: 3rem;
  --spacing-2xl: 4rem;
}

/* Smooth scroll behavior for anchor links */
html {
  scroll-behavior: smooth;
}

/* Improved focus states for accessibility */
a:focus,
button:focus {
  outline: 2px solid transparent;
  outline-offset: 2px;
}

.dark a:focus,
.dark button:focus {
  outline-color: rgba(255, 255, 255, 0.3);
}

a:focus,
button:focus {
  outline-color: rgba(15, 23, 42, 0.3);
}
