/* ===== Enhanced Home Page Animations ===== */

/* Keep hero and info animations; neutralize card extras to preserve original effect */

/* Hero Section Enhancements */
.hero {
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, transparent 30%, rgba(0, 255, 255, 0.1) 50%, transparent 70%);
  animation: heroShimmer 3s ease-in-out infinite;
  pointer-events: none;
}

@keyframes heroShimmer {
  0%, 100% {
    transform: translateX(-100%);
  }
  50% {
    transform: translateX(100%);
  }
}

/* Hero Text Animations */
.hero h1 {
  animation: heroTitleSlide 1.2s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}

@keyframes heroTitleSlide {
  from {
    opacity: 0;
    transform: translateY(-50px) scale(0.8);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.hero p {
  animation: heroSubtitleSlide 1.4s cubic-bezier(0.4, 0, 0.2, 1) 0.3s both;
}

@keyframes heroSubtitleSlide {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero small {
  animation: heroSmallSlide 1.6s cubic-bezier(0.4, 0, 0.2, 1) 0.6s both;
}

@keyframes heroSmallSlide {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Info Section Animations */
.info {
  animation: infoSlideUp 1s cubic-bezier(0.4, 0, 0.2, 1) 0.8s both;
  position: relative;
  overflow: hidden;
}

@keyframes infoSlideUp {
  from {
    opacity: 0;
    transform: translateY(50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.info::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(0, 255, 255, 0.1), transparent);
  animation: infoShimmer 2s ease-in-out infinite 1.5s;
}

@keyframes infoShimmer {
  0% {
    left: -100%;
  }
  100% {
    left: 100%;
  }
}

/* Neutralize card animations to keep original simpler effect */
.card { animation: none !important; }
.card:hover { animation: none !important; }
.card::before { display: none !important; }

/* Keep button slide-in minimal */
.card a,
.card button {
  animation: none !important;
}

/* Main Section Animation */
main {
  animation: mainSlideIn 1s cubic-bezier(0.4, 0, 0.2, 1) 0.5s both;
}

@keyframes mainSlideIn {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Footer Animation */
.footer-custom {
  animation: footerSlideUp 0.8s cubic-bezier(0.4, 0, 0.2, 1) 1.1s both;
}

@keyframes footerSlideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Particle Effects Enhancement */
#particles-js {
  animation: particlesFadeIn 2s ease-out;
}

@keyframes particlesFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* Scroll Indicator */
.scroll-indicator {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: rgba(0, 255, 255, 0.2);
  z-index: 1001;
}

.scroll-progress {
  height: 100%;
  background: linear-gradient(90deg, #00ffff, #00ffc3);
  width: 0%;
  transition: width 0.1s ease;
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.5);
}

/* Loading States */
.loading-shimmer {
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.1) 25%, rgba(255, 255, 255, 0.2) 50%, rgba(255, 255, 255, 0.1) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* Responsive Animations */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2rem;
  }
  
  .card {
    animation-delay: 0.1s !important;
  }
  
  .card:nth-child(n) {
    animation-delay: 0.1s !important;
  }
}

/* Performance Optimizations */
.card,
.hero,
.info {
  will-change: transform, opacity;
}

.card:hover {
  will-change: transform;
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
