/* ========== Importation des polices ========== */
@font-face {
    font-family: 'Borel';
    src: url('fonts/Borel-Regular.ttf');
}

@font-face {
    font-family: 'Roboto';
    src: url('fonts/Roboto-Regular.ttf');
}

@font-face {
    font-family: 'Geist';
    src: url('fonts/Geist-VariableFont_wght.ttf');
}

/* ========== Global Styles ========== */

body {
    
    font-family: 'Borel', sans-serif;
    font-size: 1.5rem;
    color: #F5F5F5;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    background-color: #6495ED;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-repeat: no-repeat;
    overflow-x: hidden; /* Empêche le débordement horizontal */
    cursor: url('3D/curseur.png'), auto;
    
}

h1, h2, h3 {
    font-family: 'Borel', sans-serif;
}

/* Header */
header {
    background-color: rgba(0, 0, 0, 0);
    color: #F5F5F5;
    padding: 20px;
    text-align: center;
}
/* Styles pour le contrôle de musique */
.music-controls {
  position: fixed;
  bottom: 6%;
  left: 5%;
  z-index: 999;
}

.music-button {
  background-color: #6495ED;
  color: #F5F5F5;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
}

.music-button:hover {
  background-color: #425EA2;
  transform: scale(1.1);
}

.music-icon {
  font-size: 18px;
}

/* Styles pour la fenêtre pop-up */
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999; /* Valeur très élevée pour être au-dessus de tout */
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.popup-overlay.active {
    opacity: 1;
    visibility: visible;
}

.popup-container {
    background-color: #FB8642;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5); /* Ombre plus prononcée */
    max-width: 475px;
    width: 70%;
    padding: 30px;
    text-align: center;
    position: relative;
    transform: scale(0.7);
    transition: transform 0.3s ease;
    z-index: 10000; /* Encore plus élevé que l'overlay */
}

.popup-overlay.active .popup-container {
    transform: scale(1);
}

.popup-content h2 {
    margin-top: 0;
    color: #F5F5F5;
    font-family: 'Borel', sans-serif;
}

.popup-content p {
    margin-bottom: 20px;
    color: #F5F5F5;
    font-family: 'Roboto', sans-serif;
}

.close-popup {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #F5F5F5;
    padding: 0;
    width: 30px;
    height: 30px;
    line-height: 30px;
    border-radius: 50%;
    transition: background-color 0.3s;
    z-index: 10001; /* Pour être sûr que le bouton de fermeture est toujours cliquable */
}

.close-popup:hover {
    background-color: #2C6E49;
}

.popup-button {
    display: inline-block;
    background-color: #f86e1b ;
    color: #F5F5F5;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 5px;
    font-family: 'Roboto', sans-serif;
    transition: background-color 0.3s;
}

.popup-button:hover {
    background-color: #2C6E49;
}

/* ========== Bouton À propos ========== */
#about-btn {
    position: fixed;
    top: 6%;
    right: 5%;
    background-color: transparent;
    border: none;
    border-radius: 50%;
    padding: 10px;
    z-index: 1000;
    cursor: pointer;
    display: inline-block;
}

#about-btn img {
    width: 30px;
    height: 30px;
    transition: transform 0.3s ease;
}

#about-btn:hover img {
    transform: scale(1.2);
}


/* Wrapper : Conteneur principal */
.wrapper {
    display: flex;
    flex-direction: column;
    min-height: 100vh; /* Hauteur totale de l'écran */
}

/* Contenu principal (le reste de la page) */
.image-container {
    flex-grow: 1;
    position: relative; /* Ajout de cette ligne */
    min-height: 50vh; /* Pour garantir une hauteur suffisante */
}

.caption {
    display: block;
    margin-top: 0px;
    text-align: center;
    font-family: 'Borel', sans-serif;
    color: #F5F5F5;
    font-size: 1.2rem;
    transition: opacity 0.3s ease;
}

.random-link {
    position: absolute; /* Maintenir le positionnement absolu */
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none; /* Enlever le soulignement des liens */
}

/* Positionnement des liens (au lieu des images) */
.random-link.atelier {
    width: 325px;
    top: 15%;
    left: 27%;
}

.random-link.graphiques {
    width: 200px;
    top: 60%;
    left: 60%;
}

.random-link.contact {
    width: 200px;
    top: -15%;
    left: 70%;
}

.random-link.liens {
    width: 250px;
    top: 0%;
    left: 8%;
}

.random-link.print {
    width: 200px;
    top: 80%;
    left: 15%;
}


/* Animation au survol */
.random-link img {
    width: 100%;
    position: static; /* Supprimer la position absolue des images */
    transition: transform 0.3s ease;
}

.random-link:hover img {
    transform: scale(1.1);
}

.random-link:hover .caption {
    /* Optionnel : rendre la légende plus visible au survol */
    text-shadow: 0 0 5px rgba(245, 245, 245, 0.5);
}


/* Footer */
footer {
    font-family: 'Borel', sans-serif;
    color: #F5F5F5;
    text-align: center;
    padding-top: 10px;
    height: 10vh;
    font-size: 1rem;
    margin-top: auto; /* Pousse le footer en bas */
    width: 100%;
}
/* Responsive */
@media (max-width: 768px) {
    
    .music-controls {
    display: none;
    }
  
    .popup-container {
        padding: 20px;
    }
    
    .popup-content h2 {
        font-size: 1.5rem;
    }
    
    .popup-content p {
        font-size: 1rem;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .popup-container {
        padding: 20px;
    }
    
    .popup-content h2 {
        font-size: 1.5rem;
    }
    
    .popup-content p {
        font-size: 1rem;
    }
}



/* ========== Petits écrans (moins de 600px) ========== */
@media (max-width: 600px) {
   
    header {
    flex-shrink: 0;
    width: 100%;
    text-align: center; /* Centre le texte */
    padding: 10px 0; /* Ajoute un peu d'espace */
    font-size: 1.5rem;
    }
    
    #about-btn {
    position: fixed;
    top: 82%;
    right: 8%;
    }

    body::before {
        width: 300px; /* Taille plus petite pour les mobiles */
        height: 300px; /* Taille plus petite pour les mobiles */
        background-size: contain; /* Garde les proportions */
    }

    .popup-container {
        padding: 20px 15px;
        width: 80%;
        max-height: 80vh; /* Limite la hauteur sur mobile */
        overflow-y: auto; /* Permet de défiler si nécessaire */
    }
    
    .popup-content h2 {
        font-size: 1.5rem;
        margin-bottom: 10px;
    }
    
    .popup-content h3 {
        font-size: 1.2rem;
        margin-bottom: 10px;
    }
    
    .popup-content p {
        font-size: 0.9rem;
        margin-bottom: 10px;
        line-height: 1.3;
    }
    
    .image-container {
        display: flex;
        flex-direction: column;
        align-items: center;
        padding: 0px 0;
        gap: 20px ;
    }
    
    .popup-button {
        padding: 10px 20px;
        font-size: 1.2rem;
        width: 80%; /* Plus large sur mobile pour faciliter le tap */
        margin: 5px auto 5px;
    }
    
    .random-link {
        position: static ;
        width: 100% ;
        max-width: 250px ;
        margin: 15px 0;
    }

   .random-link img {
        width: 100%;
    }

    .caption {
        font-size: 1.5rem;
        margin-top: 5px;
    }
    
   footer {
        font-size: 0.85rem; /* Réduit la taille du texte */
        text-align: center; /* Centrage du texte */
        white-space: normal; /* Permet le passage à la ligne */
        line-height: 1.4; /* Espacement entre les lignes */
        margin-top: auto ;
        width: 100%;
        flex-shrink: 0;
        height: 10vh;
        padding: 0;
    }

}
