/* Importation d'une police robuste type Montserrat ou Arial Black pour le look graphique */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@700;900&display=swap');

.modal {
    display: none; 
    position: fixed;
    z-index: 9999 !important;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
}

.modal-content {
    background-color: #ffffff;
    /* Création du quadrillage en arrière-plan */
    background-image: 
        linear-gradient(#f0f0f0 1px, transparent 1px),
        linear-gradient(90deg, #f0f0f0 1px, transparent 1px);
    background-size: 20px 20px;
    
    margin: 5% auto;
    padding: 0; /* On gère le padding à l'intérieur pour les onglets */
    border: 3px solid #000;
    border-radius: 25px;
    width: 90%;
    max-width: 400px;
    position: relative;
    font-family: 'Montserrat', sans-serif;
    overflow: hidden;
    box-shadow: 10px 10px 0px #000; /* Ombre nette typique */
}

/* Système d'onglets en haut */
.modal-header {
    display: flex;
    border-bottom: 3px solid #000;
}

.tab-btn {
    flex: 1;
    padding: 15px;
    text-align: center;
    font-weight: 900;
    cursor: pointer;
    text-transform: uppercase;
    transition: 0.2s;
}

.tab-btn.active {
    background-color: #D68DFF; /* Violet de la maquette */
}

.tab-btn:not(.active) {
    background-color: #fff;
}

.tab-btn:first-child {
    border-right: 3px solid #000;
}

/* Corps de la modale */
.modal-body {
    padding: 30px 25px;
    text-align: center;
}

.modal-body img.trophy {
    width: 80px;
    margin-bottom: 15px;
}

#modalTitle {
    font-size: 1.4rem;
    font-weight: 900;
    color: #000;
    margin-bottom: 10px;
    line-height: 1.2;
}

.modal-body p.description {
    font-family: Arial, sans-serif;
    font-size: 0.9rem;
    color: #444;
    margin-bottom: 25px;
    font-weight: normal;
}

/* Formulaire */
#authForm {
    text-align: left;
}

#authForm label {
    display: block;
    font-weight: 900;
    margin-bottom: 5px;
    font-size: 1rem;
}

#authForm input[type="email"],
#authForm input[type="password"] {
    width: 100%;
    padding: 15px;
    margin-bottom: 20px;
    border: 2px solid #000;
    border-radius: 15px;
    font-size: 1rem;
    box-sizing: border-box;
    background: #fff;
}

/* Checkbox RGPD */
#rgpd-container {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    margin-bottom: 25px;
    font-weight: bold;
}

#rgpd-container input[type="checkbox"] {
    width: 20px;
    height: 20px;
    border: 2px solid #000;
    cursor: pointer;
}

/* Bouton S'inscrire / Se connecter */
#authSubmitBtn {
    display: block;
    width: 80%;
    margin: 0 auto;
    background-color: #FFF200; /* Jaune vif */
    color: #000;
    font-weight: 900;
    padding: 15px;
    border: 3px solid #000;
    border-radius: 50px;
    cursor: pointer;
    font-size: 1.1rem;
    box-shadow: 0px 5px 0px #000;
    transition: all 0.1s;
}

#authSubmitBtn:active {
    transform: translateY(3px);
    box-shadow: 0px 2px 0px #000;
}

/* Bouton de fermeture discret */
.close {
    position: absolute;
    right: 15px;
    top: 60px; /* Ajusté pour ne pas être sur les onglets */
    font-size: 30px;
    font-weight: bold;
    color: #000;
    cursor: pointer;
    z-index: 10;
}

/* Masquer les éléments selon le mode */
.hidden {
    display: none;
}