/*
|----------------------------------------------------------
| Configuration de Base
|----------------------------------------------------------
*/

/* Masque tout ce qui dépasse horizontalement (défilement indésirable) */
body {
    overflow-x: hidden;
}

/* Polices personnalisées */
.font-lora {
    font-family: 'Lora', Georgia, 'Times New Roman', Times, serif;
}

.font-montserrat {
    font-family: 'Montserrat', Arial, Helvetica, sans-serif;
}


/*
|----------------------------------------------------------
| Keyframes Globales pour l'Apparition (Entrance)
|----------------------------------------------------------
*/

/* Apparition glissant vers le haut (Fade Up) */
@keyframes slide-in-up {
    0% { opacity: 0; transform: translateY(50px); }
    100% { opacity: 1; transform: translateY(0); }
}

/* Apparition glissant vers le bas (Fade Down) */
@keyframes slide-in-down {
    0% { opacity: 0; transform: translateY(-20px); }
    100% { opacity: 1; transform: translateY(0); }
}

/* Apparition glissant vers la gauche */
@keyframes slide-in-left {
    0% { opacity: 0; transform: translateX(-50px); }
    100% { opacity: 1; transform: translateX(0); }
}

/* Apparition glissant vers la droite */
@keyframes slide-in-right {
    0% { opacity: 0; transform: translateX(50px); }
    100% { opacity: 1; transform: translateX(0); }
}

/* Apparition simple en fondu */
@keyframes fade-in {
    0% { opacity: 0; }
    100% { opacity: 1; }
}

/* Pop-in pour les cartes (effet rebond) */
@keyframes pop-in {
    0% { opacity: 0; transform: scale(0.8) translateY(20px); }
    100% { opacity: 1; transform: scale(1) translateY(0); }
}

/* Marquee / défilement horizontal */
@keyframes marquee {
    0% { transform: translateX(0%); }
    100% { transform: translateX(-50%); }
}

/* Zoom lent sur l'image */
@keyframes slowZoom {
    0% { transform: scale(1); }
    100% { transform: scale(1.1); }
}

/* Fade-in vers le haut (pour uniformiser fade-up et slide-in-up) */
@keyframes fade-in-up {
    0% { opacity: 0; transform: translateY(50px); }
    100% { opacity: 1; transform: translateY(0); }
}


/*
|----------------------------------------------------------
| Classes d'Animation
|----------------------------------------------------------
*/

/* Défilement et Zoom */
.animate-marquee-css { animation: marquee 60s linear infinite; }
.animate-slow-zoom { animation: slowZoom 30s ease-out forwards; }

/* Apparitions */
.animate-slide-in-up   { animation: slide-in-up 1s ease-out forwards; }
.animate-slide-in-down { animation: slide-in-down 1s ease-out forwards; }
.animate-slide-in-left { animation: slide-in-left 1s ease-out forwards; }
.animate-slide-in-right{ animation: slide-in-right 1s ease-out forwards; }
.animate-fade-in       { animation: fade-in 0.8s ease-out forwards; }
.animate-fade-in-up    { animation: fade-in-up 1s forwards; }

/* Pop-in cartes / titres */
.do-animate-card { animation: pop-in 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards; }
.do-animate-title { animation: slide-in-down 1s ease-out forwards; }

/* Délais */
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-500 { animation-delay: 0.5s; }
.delay-700 { animation-delay: 0.7s; }
.delay-900 { animation-delay: 0.9s; }

/* Masquer éléments animés avant déclenchement */
.animate-slide-in-up,
.animate-slide-in-down,
.animate-slide-in-left,
.animate-slide-in-right,
.animate-fade-in,
.animate-fade-in-up,
.do-animate-card,
.do-animate-title {
    opacity: 0;
}


/*
|----------------------------------------------------------
| Navigation Active Link
|----------------------------------------------------------
*/

.active-link {
    color: #4B9B00;
    position: relative;
}

.active-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: #4B9B00;
    transform: scaleX(1);
    transform-origin: bottom left;
    transition: transform 0.3s ease-out;
}


/*
|----------------------------------------------------------
| Styles Statistiques
|----------------------------------------------------------
*/

.flex-col > .flex-col:not(:last-child) {
    margin-bottom: 1rem;
}

@media (min-width: 768px) {
    .flex-col > .flex-col:not(:last-child) {
        margin-bottom: 0;
    }
}


.fade-in-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: all 1s ease-out;
}

.fade-in-right {
    opacity: 0;
    transform: translateX(50px);
    transition: all 1s ease-out;
}

.fade-in-up {
    opacity: 0;
    transform: translateY(20px);
    transition: all 1s ease-out;
}

.animate {
    opacity: 1 !important;
    transform: translateX(0) translateY(0) !important;
}






/* Ajout d'une animation simple de fondu enchaîné (Tailwind n'a pas cette utilité par défaut pour les transitions longues) */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-fadeIn {
    animation: fadeIn 0.8s ease-out forwards;
}

.delay-100 {
    animation-delay: 0.1s; /* Retarde l'animation du paragraphe */
}

/* Utilitaires pour l'ombre du texte (drop-shadow dans Tailwind est utilisé pour les filtres SVG et non le CSS text-shadow) */
/* Bien que drop-shadow-lg soit inclus, text-shadow est souvent préférable pour le texte */
.drop-shadow-lg {
    filter: drop-shadow(0 4px 3px rgb(0 0 0 / 0.2)) drop-shadow(0 2px 2px rgb(0 0 0 / 0.1));
}
.drop-shadow-md {
    filter: drop-shadow(0 2px 2px rgb(0 0 0 / 0.1)) drop-shadow(0 1px 1px rgb(0 0 0 / 0.06));
}







/* Animation de fondu pour le texte */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-fadeIn {
    animation: fadeIn 0.8s ease-out forwards;
}

.delay-100 {
    animation-delay: 0.1s;
}

/* Animation de zoom lent pour l'image de fond */
@keyframes zoomIn {
    from { transform: scale(1); }
    to { transform: scale(1.05); } /* Zoom de 5% */
}

.animate-zoomIn {
    animation: zoomIn 10s ease-out forwards infinite alternate; /* Zoom lent sur 10 secondes, puis retourne à la taille initiale */
}

/* Utilitaires pour l'ombre du texte */
.drop-shadow-lg {
    filter: drop-shadow(0 4px 3px rgb(0 0 0 / 0.2)) drop-shadow(0 2px 2px rgb(0 0 0 / 0.1));
}
.drop-shadow-md {
    filter: drop-shadow(0 2px 2px rgb(0 0 0 / 0.1)) drop-shadow(0 1px 1px rgb(0 0 0 / 0.06));
}



/* Animation : glissement vers le bas */
@keyframes slideInDown {
  0% {
    opacity: 0;
    transform: translateY(-50px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Animation : fondu + zoom léger */
@keyframes fadeInZoom {
  0% {
    opacity: 0;
    transform: scale(0.9);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

/* Classes d’animation */
.animate-slide-in-down {
  animation: slideInDown 0.8s ease forwards;
}

.animate-fade-in-zoom {
  animation: fadeInZoom 1s ease forwards;
}
