/* Enhanced Animations for Portfolio V2 */

/* Fade in animation */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Slide up animation */
@keyframes slideUp {
  from { 
    transform: translateY(40px);
    opacity: 0;
  }
  to { 
    transform: translateY(0);
    opacity: 1;
  }
}

/* Slide in from left animation */
@keyframes slideInLeft {
  from { 
    transform: translateX(-40px);
    opacity: 0;
  }
  to { 
    transform: translateX(0);
    opacity: 1;
  }
}

/* Slide in from right animation */
@keyframes slideInRight {
  from { 
    transform: translateX(40px);
    opacity: 0;
  }
  to { 
    transform: translateX(0);
    opacity: 1;
  }
}

/* Pulse animation */
@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

/* Bounce animation */
@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
  40% { transform: translateY(-20px); }
  60% { transform: translateY(-10px); }
}

/* Rotate animation */
@keyframes rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Shadow pulse for buttons and interactive elements */
@keyframes shadowPulse {
  0% { box-shadow: 0 0 0 0 rgba(22, 154, 194, 0.4); }
  70% { box-shadow: 0 0 0 10px rgba(22, 154, 194, 0); }
  100% { box-shadow: 0 0 0 0 rgba(22, 154, 194, 0); }
}

/* Apply classes */
.fade-in {
  animation: fadeIn 1s ease forwards;
}

.slide-up {
  animation: slideUp 0.7s ease forwards;
}

.slide-in-left {
  animation: slideInLeft 0.7s ease forwards;
}

.slide-in-right {
  animation: slideInRight 0.7s ease forwards;
}

.pulse {
  animation: pulse 2s infinite;
}

.bounce {
  animation: bounce 2s infinite;
}

.rotate {
  animation: rotate 8s linear infinite;
}

.shadow-pulse {
  animation: shadowPulse 2s infinite;
}

/* Staggered animations for multiple elements */
.stagger-fade-in > * {
  opacity: 0;
  animation: fadeIn 0.5s ease forwards;
}

.stagger-fade-in > *:nth-child(1) { animation-delay: 0.1s; }
.stagger-fade-in > *:nth-child(2) { animation-delay: 0.2s; }
.stagger-fade-in > *:nth-child(3) { animation-delay: 0.3s; }
.stagger-fade-in > *:nth-child(4) { animation-delay: 0.4s; }
.stagger-fade-in > *:nth-child(5) { animation-delay: 0.5s; }
.stagger-fade-in > *:nth-child(6) { animation-delay: 0.6s; }
.stagger-fade-in > *:nth-child(7) { animation-delay: 0.7s; }
.stagger-fade-in > *:nth-child(8) { animation-delay: 0.8s; }
.stagger-fade-in > *:nth-child(9) { animation-delay: 0.9s; }
.stagger-fade-in > *:nth-child(10) { animation-delay: 1s; }

/* Scroll reveal animation */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}
