html {
    scroll-behavior: smooth; /* Active un défilement fluide */
}

/* Conteneur principal */
.titreaudiovisuel {
    position: relative; /* Position relative pour l'alignement */
    text-align: center; /* Centre le texte horizontalement */
    background-color: #C6AEBC; /* Couleur de fond similaire */
    padding: 43px 0; /* Espacement vertical */
    font-size: 80px; /* Taille de police */
}

/* Texte en contour */
.contour2 ,.contourmoins2 {
    position: absolute; /* Superposition des titres */
    top: 0; /* Alignement en haut */
    left: 50%; /* Centre horizontalement */
    transform: translateX(-50%); /* Ajuste pour un centrage parfait */
    font-family: 'Roboto', sans-serif; /* Police utilisée */
    color: transparent; /* Texte transparent */
    -webkit-text-stroke: 0.5px white; /* Contour blanc */
    z-index: 1; /* Derrière le texte plein */
}

/* Positionnement spécifique des titres en contour */
.contourmoins2 {
    top: -13px; /* Légèrement déplacé vers le haut */
    left: 50%; /* Décalage à gauche */
    opacity: 0.2; /* Opacité réduite pour un effet atténué */
    margin-top:3%;
}

.contour2 {
    top: 13px; /* Légèrement déplacé vers le bas */
    left: 50%; /* Décalage à droite */
    opacity: 0.6; /* Opacité réduite pour un effet atténué */
    margin-top:3%;

}

/* Texte plein au premier plan */
.plein2 {
    position: relative; /* Superposé au texte contour */
    font-family: 'Roboto-Medium', sans-serif; /* Police utilisée */
    color: white; /* Texte blanc */
    z-index: 2; /* Devant les contours */
    margin-top:3%;

}


.audiovisuelprojet{
    height: 1050px;
    background-color: #C6AEBC;
}





.gridphoto {
    display: grid;
    grid-template-columns: 100px 405px 405px 405px 100px; /* Largeurs spécifiques pour chaque colonne */
    gap: 20px;
}

.cardphoto{
    grid-column-start: 2;
}






.cardphoto,.cardphoto2, .cardphoto3{
    height:219px;
    width:405px;
    border-radius: 15px;
    background-color: #FFFFFF;
    box-shadow: none;
    transition: box-shadow 0.3s ease-in-out; /* Transition douce de l'ombre */
    margin-top:6%;
}

/* Pas d'ombre au survol */
.cardphoto:hover, .cardphoto2:hover, .cardphoto3:hover{
    box-shadow: 7px 7px 0px 0px  rgb(0,0,0);
    transition: box-shadow 0.3s ease-in-out;
  }

 
#imgskop{
    height:100px;
    margin-top:4%;
    margin-left:15%;
    position: absolute;
}
#imgmotion{
    height:100px;
    margin-top:4%;
    margin-left:17%;
    position: absolute;
}
#imgrallye{
    height:260px;
    margin-left:4%;
    position: absolute;
}

#imgcannes{
    height:50px;
    margin-top:5%;
    margin-left:12%;
    position: absolute;
}

#imglondres{
    height:160px;
    margin-top:1.5%;
    margin-left:9%;
    position: absolute;
}


.grid a{
    text-decoration: none;
}

#titre{
    font-family: 'Roboto-Medium';
    position: absolute;
    text-align: center;
    color: #000000;
    font-size: 27px;
    margin-top:6%;
    margin-left:3%;
}




#flechegestion{
    position: absolute;
    margin-top:11.5%;
    margin-left:3%;
}

#decouvrir{
    color: #C6AEBC;
    font-family: 'Roboto-Regular';
    position:absolute;
    margin-top:11.65%;
    margin-left:5.5%;
}

/* Cacher la flèche et le texte "découvrir" par défaut */
#flechegestion,
#decouvrir {
    opacity: 0;
    transition: opacity 0.3s ease-in-out; /* Transition douce pour l'apparition */
}

/* Afficher la flèche et le texte au survol */
.cardphoto:hover #flechegestion,
.cardphoto:hover #decouvrir,.cardphoto2:hover #flechegestion,
.cardphoto2:hover #decouvrir,.cardphoto3:hover #flechegestion,
.cardphoto3:hover #decouvrir {
    opacity: 1; /* Rendre visible au survol */
}



.cardphoto:hover #flechegestion, .cardphoto2:hover #flechegestion , .cardphoto3:hover #flechegestion  {
    transform: translateY(0); /* Remonte à sa position initiale */
}


.flecheaudiovisuel{
    display: flex;
    margin-top:5%;
    animation: bounceArrow 2s infinite; /* Applique l'animation */
    justify-content: center;
    margin-right:10px;
    animation: bounceArrow 2s infinite; /* Applique l'animation */
}



.etoileaudiovisuel{
    display: flex;
}

#etoileblancheaudiovisuel{
    width:60px;
    margin-top:4%;
    position: absolute;
    margin-left:90%;
    z-index: 1;
    animation: scintillement 2.5s infinite; /* Animation continue avec un délai de 1.5 secondes */
    animation-delay: 0s; /* Début immédiat */

}
#etoilenoireaudiovisuel{
    width:60px;
    position: absolute;
    margin-left:91%;
    margin-top:4%;
    animation: scintillement 2.5s infinite; /* Animation continue avec un délai de 1.5 secondes */
    animation-delay: 0.7s; /* Début immédiat */


}



  /* Responsive pour les écrans de taille inférieure à 768px (mobile) */
  @media (max-width: 768px) {

    /* Modifier le style de .titre pour qu'il soit bien centré et visible */
    .titreaudiovisuel{
        font-size: 48px; /* Réduit la taille du texte sur mobile */
        margin-left: 5%;
        margin-right: 5%;
        text-align: center; /* Centre le texte pour les petits écrans */
    }

    .titreaudiovisuel h1{
        font-size:40px;
        white-space: nowrap;
        padding-top:5%;
    }
    .plein2{
        position: absolute;
        top:18%;
        left:19%;
    }
    .contour2{
        position: absolute;
        top:2%;
        left:50%;
    }
 
    .flecheaudiovisuel, .etoileaudiovisuel{
        display: none;
    }
    #audiovisuelprojet .grid{
        display: grid;
        grid-template-columns: repeat(1, 1fr);

    }
    #debut{
        grid-column-start:1;
    }

    
    .audiovisuelprojet .grid .card{
        width:80%;
        margin-left:10%;
        
    }
    
    .audiovisuelprojet .grid .card {
        position: relative;
        display: flex;
        justify-content: center;
    }

    .audiovisuelprojet .grid .cardphoto{
        width:80%;
        margin-left:10%;
        margin-top:15%;
        margin-bottom:2%;
        position: relative;
        display: flex;
        justify-content: center;
    }    
    .audiovisuelprojet .grid .cardphoto2{
        width:80%;
        margin-left:10%;
        position: relative;
        display: flex;
        justify-content: center;
    }
        
    .audiovisuelprojet{
        height:1280px;
    }

    .audiovisuelprojet .grid .card #titre{
        white-space: nowrap; /* Empêche les retours à la ligne */    
        margin-left:0;
    }
    .audiovisuelprojet .grid .cardphoto #titre{
        margin-left:0;
        white-space: nowrap; /* Empêche les retours à la ligne */       
    }
    .audiovisuelprojet .grid .cardphoto2 #titre{
        margin-left:0;
        white-space: nowrap; /* Empêche les retours à la ligne */       
    }

    .audiovisuelprojet .grid .card #imgmotion{
        position: absolute;
        bottom: 40px;
        margin:0;
     }

     .audiovisuelprojet .grid .card #imgrallye{
        position: absolute;
        bottom: -54px;
        left:-18%;
        margin:0;
         }

    .audiovisuelprojet .grid .cardphoto #imgcannes{
        position: absolute;
        bottom: 70px;
        margin:0;
    }
    .audiovisuelprojet .grid .cardphoto2 #imglondres{
        position: absolute;
        bottom: 20px;
        margin:0;
    }
}