/* --- Typographie Globale Unifiée --- */
#gamotel-app, #gamotel-app * {
    font-family: 'Montserrat', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    box-sizing: border-box;
}

#gamotel-app {
    font-weight: 300;
    max-width: 800px;
    margin: 0 auto;
    color: #FFFBF6;
}

/* --- Boutons à bascule (Style Pilules Compact) --- */
.gamotel-toggles-wrapper {
    display: flex;
    flex-direction: column;
    margin-bottom: 0; 
}

/* Espacement uniforme de 40px au dessus de chaque grande section */
.gamotel-toggle-group {
    display: flex;
    flex-direction: column;
    gap: 10px; 
    margin-top: 40px; 
}

.gamotel-toggle-group:first-child {
    margin-top: 0; /* Pas de marge tout en haut */
}

.gamotel-toggle-label {
    font-weight: 400;
    font-size: 1em;
    color: #FFFBF6;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-align: center;
}

.gamotel-segmented-control {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px; 
}

.gamotel-segmented-control input[type="radio"] {
    display: none;
}

.gamotel-segmented-control label {
    padding: 10px 20px; 
    cursor: pointer;
    background: #FFFBF6;
    color: #152943;
    font-weight: 400;
    border-radius: 40px;
    transition: all 0.3s ease;
    font-size: 0.95em; 
    text-align: center;
}

.gamotel-segmented-control input[type="radio"]:checked + label {
    background: #9B5D42;
    color: #FFFBF6;
    box-shadow: 0 4px 10px rgba(0,0,0,0.4);
}

/* --- Calendrier et Overlay --- */
#gamotel-calendar-wrapper {
    background-color: transparent;
    position: relative;
    padding: 5px 0;
}

#gamotel-interaction-overlay {
    display: none;
    position: absolute;
    top: 30px; /* <-- C'est ici : on descend l'ombre pour libérer les boutons */
    left: -10px; 
    right: -10px; 
    bottom: -10px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 8px;
    z-index: 10;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    backdrop-filter: blur(3px);
}

#gamotel-calendar-wrapper.needs-interaction #gamotel-interaction-overlay {
    display: flex;
}

.gamotel-overlay-msg {
    background: #9B5D42;
    color: #FFFBF6;
    padding: 12px 20px;
    border-radius: 30px;
    font-weight: 400;
    font-size: 0.9em;
    box-shadow: 0 4px 15px rgba(0,0,0,0.4);
    pointer-events: none;
    text-align: center;
}

/* En-tête du mois (Espace uniforme de 40px au dessus) */
.gamotel-date-label {
    text-align: center;
    font-weight: 400;
    font-size: 1em;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 40px; 
    margin-bottom: 10px;
}

.gamotel-cal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #FFFBF6;
    padding: 8px 15px; 
    margin-bottom: 15px; 
    border-radius: 4px;
}

.gamotel-cal-header h3 {
    margin: 0;
    font-size: 1em; 
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #152943 !important; 
}

.gamotel-cal-header button {
    background: transparent;
    color: #9B5D42 !important; 
    border: none;
    font-size: 1.5em; 
    cursor: pointer;
    font-weight: 300;
    padding: 0 10px;
    transition: transform 0.2s;
}

.gamotel-cal-header button:hover { transform: scale(1.2); }

.gamotel-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    font-weight: 400;
    margin-bottom: 8px;
    color: #FFFBF6;
    font-size: 0.85em; 
    letter-spacing: 1px;
}

#gamotel-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 6px; 
    margin-bottom: 20px; 
    transition: opacity 0.3s ease; 
}

/* Cases des jours */
.gamotel-day {
    height: 55px; 
    padding: 2px;
    text-align: center;
    cursor: pointer;
    font-weight: 400;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s, box-shadow 0.2s;
    font-size: 1em; 
    border-radius: 2px;
}

.gamotel-day.empty { background-color: transparent; cursor: default; }

/* Couleurs des cases */
.gamotel-day.disponible { background-color: #FFFBF6 !important; color: #152943 !important; } 
.gamotel-day.partagee { background-color: #FFB219B8 !important; color: #FFFBF6 !important; } /* NOUVEAU JAUNE */
.gamotel-day.complet { background-color: #970B0BD1 !important; color: #FFFBF6 !important; cursor: not-allowed; } 
.gamotel-day.indisponible { background-color: #FFFBF6A1 !important; color: #152943 !important; cursor: not-allowed; } 

.gamotel-day.selected {
    background-color: #9B5D42 !important;
    color: #FFFBF6 !important;
    transform: scale(1.08);
    box-shadow: 0 5px 15px rgba(0,0,0,0.5);
    z-index: 2;
}

.gamotel-seats-count {
    font-size: 0.65em; 
    font-weight: 300;
    margin-top: 2px;
    line-height: 1;
}

/* Légende */
.gamotel-legend {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
    font-size: 0.85em;
    font-weight: 300;
    color: #FFFBF6;
    margin-bottom: 20px;
}

.gamotel-legend span { display: flex; align-items: center; }
.gamotel-legend span::before {
    content: ''; display: inline-block; width: 10px; height: 10px; margin-right: 6px; border-radius: 2px;
}

.leg-dispo::before { background-color: #FFFBF6; }
.leg-complet::before { background-color: #970B0BD1; }
.leg-partagee::before { background-color: #FFB219B8; } /* NOUVEAU JAUNE */

/* Récapitulatif */
#gamotel-selection-summary {
    text-align: center;
    font-size: 0.95em; 
    margin-top: 20px;
    color: #FFFBF6;
    font-weight: 300;
    background: rgba(21, 41, 67, 0.4);
    padding: 12px;
    border-radius: 8px;
}

#gamotel-selection-summary strong { font-weight: 400; color: #FFFBF6; }

/* Bouton VALIDER (Espace uniforme de 40px au dessus) */
.gamotel-action-wrapper { 
    text-align: center; 
    margin-top: 40px; 
}

#gamotel-valider-btn {
    background: #FFFBF6;
    color: #152943;
    border: none;
    padding: 12px 40px; 
    border-radius: 40px;
    font-size: 1em;
    font-weight: 400;
    cursor: pointer;
    transition: all 0.3s;
    text-transform: uppercase;
    letter-spacing: 1px;
}

#gamotel-valider-btn:disabled { opacity: 0.5; cursor: not-allowed; }
#gamotel-valider-btn:not(:disabled):hover { transform: scale(1.05); box-shadow: 0 4px 15px rgba(255, 251, 246, 0.3); }

/* =========================================
   📱 RESPONSIVE MOBILE (Smartphones)
   ========================================= */
@media (max-width: 600px) {
    .gamotel-segmented-control {
        gap: 10px;
    }
    .gamotel-segmented-control label {
        padding: 10px 5px;
        font-size: 0.85em;
    }

    /* Mise en avant de "Session privatisée" sur Mobile */
    label[for="type_privatisee"] {
        flex: 1 1 100%;
        order: 1;
    }
    label[for="type_partagee"] {
        flex: 1 1 45%;
        order: 2;
    }
    label[for="type_journee"] {
        flex: 1 1 45%;
        order: 3;
    }

    /* Grille calendrier mobile */
    .gamotel-day {
        height: 45px; 
        font-size: 0.9em;
    }
    .gamotel-seats-count {
        font-size: 0.6em;
    }
    .gamotel-cal-header {
        padding: 5px 10px;
    }
    .gamotel-legend {
        gap: 10px;
        font-size: 0.75em;
    }
    #gamotel-selection-summary {
        font-size: 0.85em;
    }
    #gamotel-valider-btn {
        width: 100%; 
        padding: 15px;
    }
}
