/* ===================================
   CSS Animations
   =================================== */

/* Fade In Up Animation */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Logo Float Animation */
@keyframes logoFloat {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

/* Rotate Animation (for construction icon) */
@keyframes rotate {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

/* Pulse Animation */
@keyframes pulse {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.7;
    transform: scale(1.05);
  }
}

/* Gradient Shift Animation */
@keyframes gradientShift {
  0%, 100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

/* Float Animation for background elements */
@keyframes float {
  0%, 100% {
    transform: translate(0, 0);
  }
  33% {
    transform: translate(30px, -30px);
  }
  66% {
    transform: translate(-20px, 20px);
  }
}

/* Slide In From Left */
@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Slide In From Right */
@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Scale In Animation */
@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.8);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Progress Bar Animation */
@keyframes progressAnimation {
  0%, 100% {
    width: 75%;
  }
  50% {
    width: 80%;
  }
}

/* ===================================
   Animation Classes
   =================================== */

/* Apply animations to elements */
.animate-fadeInUp {
  animation: fadeInUp 0.8s ease-out forwards;
}

.animate-slideInLeft {
  animation: slideInLeft 0.8s ease-out forwards;
}

.animate-slideInRight {
  animation: slideInRight 0.8s ease-out forwards;
}

.animate-scaleIn {
  animation: scaleIn 0.6s ease-out forwards;
}

/* Delay classes for staggered animations */
.delay-1 {
  animation-delay: 0.1s;
}

.delay-2 {
  animation-delay: 0.2s;
}

.delay-3 {
  animation-delay: 0.3s;
}

.delay-4 {
  animation-delay: 0.4s;
}

.delay-5 {
  animation-delay: 0.5s;
}

/* ===================================
   Component Specific Animations
   =================================== */

/* Hero Content Animation */
.hero-content .construction-badge {
  animation: fadeInUp 0.8s ease-out 0.2s backwards;
}

.hero-content .hero-title {
  animation: fadeInUp 1s ease-out 0.4s backwards;
}

.hero-content .hero-subtitle {
  animation: fadeInUp 1s ease-out 0.6s backwards;
}

.hero-content .hero-description {
  animation: fadeInUp 1s ease-out 0.8s backwards;
}

.hero-content .cta-button {
  animation: fadeInUp 1s ease-out 1s backwards;
}

/* Logo Animation */
.logo h2 {
  animation: logoFloat 3s ease-in-out infinite;
}

/* Construction Icon Rotation */
.construction-icon i {
  display: inline-block;
  animation: rotate 4s linear infinite;
}

/* Construction Badge Pulse */
.construction-badge {
  animation: pulse 2s ease-in-out infinite;
}

/* Service Cards - Hidden by default, will be animated on scroll */
.service-card {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.service-card.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Section Title Animation */
.section-title {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.section-title.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Under Construction Content */
.construction-content {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.construction-content.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Footer Animation */
.footer-content {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.footer-content.visible {
  opacity: 1;
  transform: translateY(0);
}


/* ===================================
   Performance Optimizations
   =================================== */

/* GPU Acceleration for animated elements */
.hero-background,
.construction-icon i,
.logo h2,
.service-card,
.cta-button {
  will-change: transform;
}

/* Remove will-change after animation completes */
.service-card.visible,
.section-title.visible,
.construction-content.visible,
.footer-content.visible {
  will-change: auto;
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  .hero-background::before {
    animation: none;
  }
  
  .construction-icon i {
    animation: none;
  }
  
  .logo h2 {
    animation: none;
  }
}
