/* Animations CSS pour Dental Area */

/* Animation de gradient */
@keyframes gradient-shift {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

.animate-gradient {
  animation: gradient-shift 8s ease infinite;
  background-size: 200% 200%;
}

.animate-gradient-reverse {
  animation: gradient-shift 8s ease-in-out infinite reverse;
  background-size: 200% 200%;
}

/* Animation de flottement */
@keyframes float {
  0% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
  100% {
    transform: translateY(0px);
  }
}

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

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

.animate-float-delay {
  animation: float 5s ease-in-out 1s infinite;
}

/* Particules flottantes */
.particles-container {
  position: absolute;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.particle {
  position: absolute;
  border-radius: 50%;
  opacity: 0.3;
  background: linear-gradient(to right, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.1));
}

.particle-1 {
  width: 100px;
  height: 100px;
  top: 10%;
  left: 10%;
  animation: float 8s ease-in-out infinite;
}

.particle-2 {
  width: 150px;
  height: 150px;
  top: 20%;
  right: 15%;
  animation: float 10s ease-in-out 1s infinite;
}

.particle-3 {
  width: 80px;
  height: 80px;
  bottom: 15%;
  left: 20%;
  animation: float 7s ease-in-out 0.5s infinite;
}

.particle-4 {
  width: 120px;
  height: 120px;
  bottom: 25%;
  right: 10%;
  animation: float 9s ease-in-out 2s infinite;
}

.particle-5 {
  width: 60px;
  height: 60px;
  top: 40%;
  left: 30%;
  animation: float 6s ease-in-out 1.5s infinite;
}

.particle-6 {
  width: 90px;
  height: 90px;
  top: 60%;
  right: 25%;
  animation: float 11s ease-in-out 0.7s infinite;
}

/* Effets 3D */
.perspective-1000 {
  perspective: 1000px;
}

.translate-z-0 {
  transform: translateZ(0px);
}

.translate-z-10 {
  transform: translateZ(10px);
}

.translate-z-20 {
  transform: translateZ(20px);
}

.rotate-y-5 {
  transform: rotateY(5deg);
}

.rotate-y-10 {
  transform: rotateY(10deg);
}

.rotate-y-15 {
  transform: rotateY(15deg);
}

.hover\:rotate-y-0:hover {
  transform: rotateY(0deg);
}

/* Animations pour les cartes de service */
@keyframes card-hover {
  0% {
    transform: translateY(0) scale(1);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  }
  100% {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  }
}

.service-card {
  transition: all 0.3s ease-out;
}

.service-card:hover {
  animation: card-hover 0.3s ease-out forwards;
}

/* Animation pour la galerie avant/après */
.before-after-slider {
  position: relative;
  overflow: hidden;
  border-radius: 0.75rem;
}

.before-after-slider .before-image,
.before-after-slider .after-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  transition: opacity 0.3s ease-in-out;
}

.before-after-slider .after-image {
  opacity: 0;
}

.before-after-slider:hover .after-image {
  opacity: 1;
}

.before-after-slider .slider-label {
  position: absolute;
  bottom: 1rem;
  padding: 0.5rem 1rem;
  background-color: rgba(0, 0, 0, 0.7);
  color: white;
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 600;
  z-index: 10;
  transition: opacity 0.3s ease-in-out;
}

.before-after-slider .before-label {
  left: 1rem;
}

.before-after-slider .after-label {
  right: 1rem;
  opacity: 0;
}

.before-after-slider:hover .before-label {
  opacity: 0;
}

.before-after-slider:hover .after-label {
  opacity: 1;
}

/* Animation pour les témoignages */
@keyframes testimonial-appear {
  0% {
    opacity: 0;
    transform: translateY(20px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.testimonial-card {
  opacity: 0;
  animation: testimonial-appear 0.5s ease-out forwards;
}

.testimonial-card:nth-child(1) {
  animation-delay: 0.1s;
}

.testimonial-card:nth-child(2) {
  animation-delay: 0.3s;
}

.testimonial-card:nth-child(3) {
  animation-delay: 0.5s;
}

/* Animation pour les statistiques */
@keyframes count-up {
  0% {
    opacity: 0;
    transform: translateY(10px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.stat-number {
  opacity: 0;
  animation: count-up 0.8s ease-out forwards;
  animation-delay: 0.5s;
}
