/* ----- STYLE GLOBAL ----- */
body {
    background: linear-gradient(135deg, #eceff1 0%, #f6f7f8 100%);
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

/* Header */
header {
    text-align: center;
    padding: 25px 0;
}

header h1 {
    font-weight: 700;
    margin: 0;
    color: #3a3a3a;
}

/* ----- CARD PRINCIPALE ----- */
.main-card {
    width: 90vw;
    max-width: 800px;
    border-radius: 15px !important;
}

/* ----- CARD DU BAS (STATISTIQUES) ----- */
.stats-card {
    border-radius: 12px !important;
    background: #ffffff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 25px;
    padding: 15px 20px;
    margin-top: 20px;
    font-size: 1.1rem;
}

.stats-item {
    text-align: center;
    flex: 1;
}

.stats-oui {
    color: #0d6efd; /* bleu */
    font-weight: bold;
}

.stats-non {
    color: #dc3545; /* rouge */
    font-weight: bold;
}

/* Pourcentages */
.stat-number {
    font-size: 1.3rem;
    font-weight: 700;
}

/* Timer */
#refresh-timer {
    color: #6c757d;
    font-size: 0.9rem;
    margin-bottom: 10px;
}

/* ----- STYLE ADMIN PAGE ----- */
.admin-page {
    flex-direction: column;
    gap: 25px;
    padding: 20px;
    background: #f8f9fa;
    min-height: 80vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Card principale contenant le graphique et chiffres */
.admin-page .card {
    width: 90vw;
    max-width: 800px;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 6px 18px rgba(0,0,0,0.1);
    background: #ffffff;
    text-align: center;
    transition: transform 0.2s ease;
}

.admin-page .card:hover {
    transform: translateY(-3px);
}

/* Canvas graphique */
.admin-page canvas#voteChart {
    display: block;
    margin: 20px auto;
    max-width: 100%;
}

/* Paragraphes des résultats */
.admin-page p {
    font-size: 1.1rem;
    margin: 5px 0;
    font-weight: 500;
}

/* Formulaires des boutons */
.admin-page form {
    width: 100%;
    margin: 8px 0;
}

/* Boutons avec couleurs distinctes et grande surface clicable */
.admin-page form button {
    width: 100%;
    padding: 12px 0;
    font-size: 1.2rem;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

/* Couleurs des boutons */
#buttonoui { background-color: #28a745; color: dodgerblue; }  /* OUI */
#buttonnon { background-color: #dc3545; color: darkred; }  /* NON */
#buttonnv { background-color: #ffc107; color: gray; }  /* NON VALIDE */

/* Effet au survol */
.admin-page form button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 12px rgba(0,0,0,0.2);
}

/* Responsive mobile: boutons empilés et espacés */
@media (max-width: 600px) {
    .admin-page .card {
        padding: 15px;
    }

    .admin-page form button {
        font-size: 1rem;
        padding: 10px 0;
    }
}
