/* Animations for Guam AI Support Site
 * These animations are designed to add subtle movement
 * without affecting layout or accessibility
 */

/* Fade in animation */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Slide up animation */
@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

/* Slide in from right animation */
@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Scale up animation */
@keyframes scaleUp {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Pulse animation for buttons */
@keyframes pulse {
  0% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(28, 126, 214, 0.4);
  }
  70% {
    transform: scale(1.02);
    box-shadow: 0 0 0 10px rgba(28, 126, 214, 0);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(28, 126, 214, 0);
  }
}

/* Gentle floating effect for cards */
@keyframes float {
  0% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-5px);
  }
  100% {
    transform: translateY(0px);
  }
}

/* Rotation animation */
@keyframes rotate {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

/* Animation classes that can be applied to elements */
.animate-fade-in {
  animation: fadeIn 0.8s ease-in-out forwards;
}

.animate-slide-up {
  animation: slideUp 0.8s ease-out forwards;
}

.animate-slide-in-left {
  animation: slideInLeft 0.8s ease-out forwards;
}

.animate-slide-in-right {
  animation: slideInRight 0.8s ease-out forwards;
}

.animate-scale-up {
  animation: scaleUp 0.8s ease-out forwards;
}

.animate-pulse {
  animation: pulse 2s infinite;
}

.animate-float {
  animation: float 3s ease-in-out infinite;
}

.animate-rotate {
  animation: rotate 10s linear infinite;
}

/* Animation delay classes */
.delay-100 {
  animation-delay: 100ms;
}

.delay-200 {
  animation-delay: 200ms;
}

.delay-300 {
  animation-delay: 300ms;
}

.delay-400 {
  animation-delay: 400ms;
}

.delay-500 {
  animation-delay: 500ms;
}

/* Add animations to section elements - except home */
section:not(#home) {
  opacity: 0;
}

section:not(#home).is-visible {
  animation: fadeIn 0.8s ease-out forwards;
}

/* Hero section animations - hero always visible */
#home h1 {
  opacity: 1;
  animation: slideInLeft 1s ease-out forwards;
}

#home p {
  opacity: 1;
  animation: slideInLeft 1s ease-out 0.2s forwards;
}

#home a.inline-block {
  opacity: 1;
  animation: slideInLeft 1s ease-out 0.4s forwards;
}

/* Card animations */
.pain-point-card {
  opacity: 0;
}

.pain-point-card.is-visible {
  animation: scaleUp 0.8s ease-out forwards;
}

/* Solution animations */
.solution-content {
  opacity: 0;
}

.solution-content.is-visible {
  animation: slideInLeft 0.8s ease-out forwards;
}

.solution-image {
  opacity: 0;
}

.solution-image.is-visible {
  animation: slideInRight 0.8s ease-out forwards;
}

/* Pricing card animations */
.pricing-card {
  opacity: 0;
}

.pricing-card.is-visible {
  animation: scaleUp 0.8s ease-out forwards;
}

/* Demo widget animations */
.demo-widget {
  opacity: 0;
}

.demo-widget.is-visible {
  animation: fadeIn 0.8s ease-out forwards;
}

/* FAQ animations */
.faq-item {
  opacity: 0;
}

.faq-item.is-visible {
  animation: slideInLeft 0.8s ease-out forwards;
}

/* Contact form animations */
.form-field {
  opacity: 0;
}

.form-field.is-visible {
  animation: slideUp 0.8s ease-out forwards;
}