/* Animations for the entire website */

/* General entrance animations */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Pulsing effect for buttons or highlights */
@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(105, 45, 243, 0.7);
  }
  70% {
    box-shadow: 0 0 0 15px rgba(105, 45, 243, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(105, 45, 243, 0);
  }
}

/* Floating animation */
@keyframes float {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

/* Glowing text effect */
@keyframes textGlow {
  0%, 100% {
    text-shadow: 0 0 10px rgba(105, 45, 243, 0.3);
  }
  50% {
    text-shadow: 0 0 20px rgba(105, 45, 243, 0.8), 
                 0 0 30px rgba(31, 222, 253, 0.6);
  }
}

/* Background shimmer */
@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

/* Rotation animation */
@keyframes rotate {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

/* Scale animation */
@keyframes scale {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.1);
  }
}

/* Typing text effect */
@keyframes typing {
  from {
    width: 0;
  }
  to {
    width: 100%;
  }
}

@keyframes blink {
  0%, 100% {
    border-right-color: transparent;
  }
  50% {
    border-right-color: var(--secondary-color);
  }
}

/* Gradient movement */
@keyframes gradientMove {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

/* Pop-in animation for buttons or icons */
@keyframes popIn {
  0% {
    transform: scale(0);
    opacity: 0;
  }
  80% {
    transform: scale(1.1);
    opacity: 1;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

/* CSS animation utility classes */

.animate {
  animation-duration: 1s;
  animation-fill-mode: both;
}

.animate--infinite {
  animation-iteration-count: infinite;
}

.animate--delay-1 {
  animation-delay: 0.2s;
}

.animate--delay-2 {
  animation-delay: 0.4s;
}

.animate--delay-3 {
  animation-delay: 0.6s;
}

.animate--delay-4 {
  animation-delay: 0.8s;
}

.animate--delay-5 {
  animation-delay: 1s;
}

.animate--fast {
  animation-duration: 0.5s;
}

.animate--slow {
  animation-duration: 1.5s;
}

.animate--very-slow {
  animation-duration: 2s;
}

/* Animation classes */
.fade-in {
  animation-name: fadeIn;
}

.fade-in-up {
  animation-name: fadeInUp;
}

.fade-in-left {
  animation-name: fadeInLeft;
}

.fade-in-right {
  animation-name: fadeInRight;
}

.pulse {
  animation-name: pulse;
}

.float {
  animation-name: float;
}

.text-glow {
  animation-name: textGlow;
}

.shimmer {
  background: linear-gradient(90deg, 
    rgba(255, 255, 255, 0) 0%, 
    rgba(255, 255, 255, 0.05) 50%, 
    rgba(255, 255, 255, 0) 100%);
  background-size: 200% 100%;
  animation-name: shimmer;
}

.rotate {
  animation-name: rotate;
  transform-origin: center;
}

.scale {
  animation-name: scale;
}

.pop-in {
  animation-name: popIn;
}

.typing {
  display: inline-block;
  overflow: hidden;
  white-space: nowrap;
  animation: 
    typing 3.5s steps(40, end),
    blink .75s step-end infinite;
  border-right: 2px solid;
}

.gradient-move {
  background-size: 200% 200%;
  animation-name: gradientMove;
}
