/* Scroll Animations */
.scroll-animate {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.scroll-animate.animate {
  opacity: 1;
  transform: translateY(0);
}

.scroll-animate.slide-left {
  transform: translateX(-50px);
}

.scroll-animate.slide-left.animate {
  transform: translateX(0);
}

.scroll-animate.slide-right {
  transform: translateX(50px);
}

.scroll-animate.slide-right.animate {
  transform: translateX(0);
}

.scroll-animate.scale {
  transform: scale(0.8);
}

.scroll-animate.scale.animate {
  transform: scale(1);
}

.scroll-animate.rotate {
  transform: rotate(10deg);
}

.scroll-animate.rotate.animate {
  transform: rotate(0deg);
}

/* Stagger animation delays */
.scroll-animate:nth-child(1) {
  transition-delay: 0.1s;
}
.scroll-animate:nth-child(2) {
  transition-delay: 0.2s;
}
.scroll-animate:nth-child(3) {
  transition-delay: 0.3s;
}
.scroll-animate:nth-child(4) {
  transition-delay: 0.4s;
}
.scroll-animate:nth-child(5) {
  transition-delay: 0.5s;
}

/* Parallax effect */
.parallax {
  transform: translateY(0);
  transition: transform 0.1s ease-out;
}

/* Loading animations */
@keyframes shimmer {
  0% {
    background-position: -200px 0;
  }
  100% {
    background-position: calc(200px + 100%) 0;
  }
}

.loading-shimmer {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200px 100%;
  animation: shimmer 1.5s infinite;
}

/* Smooth reveal animations */
.reveal {
  position: relative;
  overflow: hidden;
}

.reveal::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.8), transparent);
  transition: left 0.8s ease;
}

.reveal.animate::before {
  left: 100%;
}

/* Bounce animation for scroll to top button */
@keyframes bounce {
  0%,
  20%,
  53%,
  80%,
  100% {
    transform: translate3d(0, 0, 0);
  }
  40%,
  43% {
    transform: translate3d(0, -15px, 0);
  }
  70% {
    transform: translate3d(0, -7px, 0);
  }
  90% {
    transform: translate3d(0, -2px, 0);
  }
}

.bounce {
  animation: bounce 0.6s ease;
}

/* Scroll to Top Button */
#scrollTopBtn {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 50px;
  height: 50px;
  background: var(--gradient-primary);
  color: white;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.2rem;
  transition: var(--transition);
  opacity: 0;
  visibility: hidden;
  z-index: 1000;
  box-shadow: var(--shadow-light);
}

#scrollTopBtn.show {
  opacity: 1;
  visibility: visible;
}

#scrollTopBtn:hover {
  transform: translateY(-3px) scale(1.1);
  box-shadow: var(--shadow-heavy);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-light);
}

::-webkit-scrollbar-thumb {
  background: var(--gradient-primary);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--primary-color);
}