/* Mobile-specific animations */
@media (max-width: 991px) {
  /* Hero section adjustments for mobile */
  .hero-section {
    min-height: 100vh !important;
    min-height: 100dvh !important;
    padding-top: 70px !important;
    padding-bottom: 40px !important;
    display: flex !important;
    align-items: center !important;
  }
  
  .hero-content {
    padding-top: 20px !important;
    padding-bottom: 40px !important;
  }
  /* Base animation styles */
  [data-aos] {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: opacity, transform;
  }
  
  [data-aos].aos-animate {
    opacity: 1;
    transform: translateY(0);
  }
  /* Base animation styles */
  [data-aos] {
    opacity: 0;
    transition-property: opacity, transform;
    transition-duration: 0.6s;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  [data-aos].aos-animate {
    opacity: 1;
    transform: translate3d(0, 0, 0) !important;
  }
  
  /* Fade up animation */
  [data-aos="fade-up"] {
    transform: translate3d(0, 30px, 0);
  }
  
  /* Fade down animation */
  [data-aos="fade-down"] {
    transform: translate3d(0, -30px, 0);
  }
  
  /* Fade left animation */
  [data-aos="fade-left"] {
    transform: translate3d(30px, 0, 0);
  }
  
  /* Fade right animation */
  [data-aos="fade-right"] {
    transform: translate3d(-30px, 0, 0);
  }
  
  /* Zoom in animation */
  [data-aos="zoom-in"] {
    transform: scale(0.9);
  }
  
  /* Staggered animations */
  [data-aos^="stagger-"] {
    opacity: 0;
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  [data-aos^="stagger-"].aos-animate {
    opacity: 1;
    transform: none !important;
  }
  /* Smooth page load */
  body {
    opacity: 1;
    transition: opacity 0.3s ease-in-out;
  }
  /* Parallax effect for hero */
  .hero-section {
    position: relative;
    overflow: hidden;
  }
  
  .hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 120%;
    background-size: cover;
    background-position: center;
    will-change: transform;
    transform: translate3d(0, 0, 0);
    transition: transform 0.3s ease-out; /* Simplified transition */
  }
  
  .hero-overlay {
    position: relative;
    z-index: 1;
  }
  /* Fade-in animation for sections */
  @keyframes fadeInUpMobile {
    from {
      opacity: 0;
      transform: translateY(30px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }

  /* Slide-in from left */
  @keyframes slideInLeftMobile {
    from {
      opacity: 0;
      transform: translateX(-30px);
    }
    to {
      opacity: 1;
      transform: translateX(0);
    }
  }

  /* Slide-in from right */
  @keyframes slideInRightMobile {
    from {
      opacity: 0;
      transform: translateX(30px);
    }
    to {
      opacity: 1;
      transform: translateX(0);
    }
  }

  /* Bounce effect */
  @keyframes bounceInMobile {
    0% {
      opacity: 0;
      transform: scale(0.9);
    }
    50% {
      transform: scale(1.05);
    }
    100% {
      opacity: 1;
      transform: scale(1);
    }
  }

  /* Pulse effect for CTA buttons */
  @keyframes pulseMobile {
    0% {
      transform: scale(1);
      box-shadow: 0 0 0 0 rgba(0, 0, 0, 0.1);
    }
    70% {
      transform: scale(1.02);
      box-shadow: 0 0 0 10px rgba(0, 0, 0, 0);
    }
    100% {
      transform: scale(1);
      box-shadow: 0 0 0 0 rgba(0, 0, 0, 0);
    }
  }

  /* Apply animations to elements */
  .hero-content {
    animation: fadeInUpMobile 0.8s ease-out forwards;
  }

  .service {
    animation: bounceInMobile 0.6s ease-out forwards;
    opacity: 0;
    animation-fill-mode: forwards;
  }

  .service:nth-child(odd) {
    animation-name: slideInLeftMobile;
    animation-duration: 0.6s;
  }

  .service:nth-child(even) {
    animation-name: slideInRightMobile;
    animation-duration: 0.6s;
  }

  .btn.primary {
    animation: pulseMobile 2s infinite;
  }

  /* Stagger animations for services */
  .service {
    animation-delay: calc(var(--index) * 0.1s);
  }

  /* Add animation delay to CTA buttons */
  .hero-cta {
    animation: fadeInUpMobile 0.8s 0.3s ease-out both;
  }

  /* Animate the contact form */
  .form {
    animation: fadeInUpMobile 0.8s 0.2s ease-out both;
  }

  /* Add hover effect for mobile */
  .service:active {
    transform: scale(0.98);
    transition: transform 0.2s;
  }

  /* Animate the mobile menu */
  .nav {
    animation: slideInLeftMobile 0.3s ease-out;
  }

  /* Animation delays */
  [data-aos-delay="100"] { transition-delay: 0.1s; }
  [data-aos-delay="200"] { transition-delay: 0.2s; }
  [data-aos-delay="300"] { transition-delay: 0.3s; }
  [data-aos-delay="400"] { transition-delay: 0.4s; }
  [data-aos-delay="500"] { transition-delay: 0.5s; }
  
  /* Card hover/tap effects */
  .service,
  .testimonial-card,
  .process-step,
  .btn {
    transition: transform 0.3s ease, 
                box-shadow 0.3s ease,
                opacity 0.3s ease;
  }
  
  .service:active,
  .testimonial-card:active,
  .process-step:active,
  .btn:active {
    transform: scale(0.97);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1) !important;
  }
  
  /* Specific section animations */
  .section-header,
  .about-header,
  .services-header,
  .process-header,
  .testimonials-header,
  .contact-header {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.8s ease-out;
  }
  
  .section-header.visible,
  .about-header.visible,
  .services-header.visible,
  .process-header.visible,
  .testimonials-header.visible,
  .contact-header.visible {
    opacity: 1;
    transform: translateY(0);
  }
  
  /* Card animations */
  .service, 
  .testimonial-card,
  .process-step {
    transition: transform 0.3s ease, box-shadow 0.3s ease, opacity 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
  }
  
  .service.animate,
  .testimonial-card.animate,
  .process-step.animate {
    opacity: 1;
    transform: translateY(0);
  }
  
  .service:active, 
  .testimonial-card:active,
  .process-step:active {
    transform: scale(0.98);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  }
  
  /* Fade in up for content */
  .fade-up {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
  }
  
  .fade-up.visible {
    opacity: 1;
    transform: translateY(0);
  }
  
  /* Slide in from sides */
  .slide-in-left {
    opacity: 0;
    transform: translateX(-30px);
    transition: all 0.8s ease-out;
  }
  
  .slide-in-right {
    opacity: 0;
    transform: translateX(30px);
    transition: all 0.8s ease-out;
  }
  
  .slide-in-left.visible,
  .slide-in-right.visible {
    opacity: 1;
    transform: translateX(0);
  }
  
  /* Staggered animations */
  .staggered-item {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease-out;
  }
  
  .staggered-item.visible {
    opacity: 1;
    transform: translateY(0);
  }
}
