/* 
  NatureScape - Animations Stylesheet
  Custom animations for a lively user experience
*/

/* ============= Bounce Animation ============= */
.bounce {
  animation: bounce 2s infinite;
}

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

/* ============= Leaf Decorations ============= */
.leaf-decoration {
  position: absolute;
  font-size: 1.5rem;
  color: var(--primary);
  opacity: 0.7;
  animation: float 4s ease-in-out infinite;
}

.leaf-1 {
  top: -15px;
  right: 20%;
  animation-delay: 0.5s;
}

.leaf-2 {
  bottom: 10%;
  left: -15px;
  animation-delay: 1s;
}

@keyframes float {
  0%, 100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-15px) rotate(10deg);
  }
}

/* ============= Image Hover Effect ============= */
.scale-on-hover {
  transition: transform 0.5s ease;
}

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

/* ============= Fade In Animation ============= */
.fade-in {
  animation: fadeIn 1s ease-in forwards;
  opacity: 0;
}

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

/* ============= Staggered Animations ============= */
.stagger-item {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.stagger-item.show {
  opacity: 1;
  transform: translateY(0);
}

/* ============= Pulse Animation ============= */
.pulse {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(76, 175, 80, 0.7);
  }
  70% {
    transform: scale(1.05);
    box-shadow: 0 0 0 10px rgba(76, 175, 80, 0);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(76, 175, 80, 0);
  }
}

/* ============= Spin Animation ============= */
.spin {
  animation: spin 10s linear infinite;
}

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

/* ============= AOS Custom Animations ============= */
[data-aos="leaf-fade-up"] {
  opacity: 0;
  transform: translateY(30px);
  transition-property: transform, opacity;
}

[data-aos="leaf-fade-up"].aos-animate {
  opacity: 1;
  transform: translateY(0);
}

[data-aos="zoom-fade"] {
  opacity: 0;
  transform: scale(0.9);
  transition-property: transform, opacity;
}

[data-aos="zoom-fade"].aos-animate {
  opacity: 1;
  transform: scale(1);
}

/* ============= Shake Animation ============= */
.shake {
  animation: shake 0.5s ease-in-out;
}

@keyframes shake {
  0%, 100% {
    transform: translateX(0);
  }
  20%, 60% {
    transform: translateX(-5px);
  }
  40%, 80% {
    transform: translateX(5px);
  }
}

/* ============= Transition Delays ============= */
.delay-1 {
  transition-delay: 0.1s;
}
.delay-2 {
  transition-delay: 0.2s;
}
.delay-3 {
  transition-delay: 0.3s;
}
.delay-4 {
  transition-delay: 0.4s;
}
.delay-5 {
  transition-delay: 0.5s;
}

/* ============= Button Hover Effects ============= */
.btn-hover-slide {
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.btn-hover-slide::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background-color: rgba(255, 255, 255, 0.2);
  transition: left 0.3s ease;
  z-index: -1;
}

.btn-hover-slide:hover::before {
  left: 0;
}

/* ============= Form Animations ============= */
.form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 0.25rem rgba(76, 175, 80, 0.25);
  transition: box-shadow 0.3s ease, border-color 0.3s ease;
}

.form-floating label {
  transition: all 0.3s ease;
}