/* Modern Animations & Effects */

/* Slide-in animations */
@keyframes slideInFromLeft {
  from {
    opacity: 0;
    transform: translateX(-50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInFromRight {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

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

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

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Animation classes */
.animate-slide-in-left {
  animation: slideInFromLeft 0.8s ease-out forwards;
}

.animate-slide-in-right {
  animation: slideInFromRight 0.8s ease-out forwards;
}

.animate-slide-in-bottom {
  animation: slideInFromBottom 0.8s ease-out forwards;
}

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

.animate-scale-in {
  animation: scaleIn 0.6s ease-out forwards;
}

/* Stagger delays for sequential animations */
.animate-delay-1 {
  animation-delay: 0.1s;
  opacity: 0;
}

.animate-delay-2 {
  animation-delay: 0.2s;
  opacity: 0;
}

.animate-delay-3 {
  animation-delay: 0.3s;
  opacity: 0;
}

.animate-delay-4 {
  animation-delay: 0.4s;
  opacity: 0;
}

.animate-delay-5 {
  animation-delay: 0.5s;
  opacity: 0;
}

.animate-delay-6 {
  animation-delay: 0.6s;
  opacity: 0;
}

.animate-delay-7 {
  animation-delay: 0.7s;
  opacity: 0;
}

.animate-delay-8 {
  animation-delay: 0.8s;
  opacity: 0;
}

/* Intersection Observer support for scroll-triggered animations */
.animate-on-scroll {
  opacity: 0;
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0) !important;
}

/* Hover effects */
.hover-lift {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.hover-scale {
  transition: transform 0.3s ease;
}

.hover-scale:hover {
  transform: scale(1.05);
}

/* Smooth section backgrounds with gradients */
.section-gradient {
  position: relative;
  overflow: hidden;
}

.section-gradient::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0) 0%, rgba(0,0,0,0.02) 100%);
  pointer-events: none;
}

/* Rounded section with modern borders */
.section-rounded {
  position: relative;
  padding: var(--spacing-2xl) 0;
}

.section-rounded .container {
  background: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
}

/* Accent borders */
.border-accent-top {
  border-top: 4px solid var(--color-primary);
  border-radius: var(--radius-lg);
}

.border-accent-left {
  border-left: 4px solid var(--color-primary);
  padding-left: var(--spacing-md);
}

/* Animated gradient background */
@keyframes gradientShift {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

.bg-animated-gradient {
  background: linear-gradient(270deg, var(--color-primary), var(--color-accent), var(--color-secondary));
  background-size: 600% 600%;
  animation: gradientShift 15s ease infinite;
}

/* Pulse animation for CTAs */
@keyframes pulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(17, 109, 255, 0.4);
  }
  50% {
    transform: scale(1.02);
    box-shadow: 0 0 0 10px rgba(17, 109, 255, 0);
  }
}

.pulse-on-hover:hover {
  animation: pulse 1.5s infinite;
}

/* Mobile optimization */
@media (max-width: 767px) {
  .section-rounded .container {
    padding: var(--spacing-md);
  }

  /* Reduce motion for mobile */
  .animate-slide-in-left,
  .animate-slide-in-right,
  .animate-slide-in-bottom {
    animation-duration: 0.5s;
  }
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
