/* CSS STYLES */
:root {
    --color-primary: #003884; /* Bleu Marine Australien */
    --color-secondary: #FFCD00; /* Jaune/Or Australien */
    --color-background: #e9ecf0; /* Fond légèrement gris */
    --color-text: #2c3e50; /* Gris foncé pour le texte */
    --color-card-bg: #ffffff;
    --color-success: #2ecc71;
    --color-error: #e74c3c;
}

body {
    font-family: 'Roboto', Arial, sans-serif;
    background-color: var(--color-background);
    color: var(--color-text);
    line-height: 1.6;
    margin: 0;
    padding: 0;
}

.container {
    width: 90%;
    max-width: 900px;
    margin: 40px auto;
    padding: 20px;
}

header {
    background-color: var(--color-primary);
    color: white;
    padding: 30px 0;
    text-align: center;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
    margin-bottom: 30px;
    font-family: 'Montserrat', sans-serif;
}

header h1 {
    font-size: 2.8em;
    margin: 0 0 5px 0;
}

header p {
    font-style: italic;
    opacity: 0.9;
    font-size: 1.1em;
}

h2 {
    color: var(--color-primary);
    border-bottom: 4px solid var(--color-secondary);
    padding-bottom: 10px;
    margin-top: 35px;
    margin-bottom: 25px;
    font-family: 'Montserrat', sans-serif;
}

/* --- Quick Facts Section --- */
#introduction {
    background-color: var(--color-card-bg);
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    margin-bottom: 40px;
}

.fact-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    list-style: none;
    padding: 0;
    font-size: 0.95em;
}

.fact-list li strong {
    color: var(--color-primary);
    font-weight: 700;
}

/* --- Quiz Section --- */
.question-card {
    background-color: var(--color-card-bg);
    border: 1px solid #ddd;
    border-radius: 10px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.3s;
}

.question-card:hover {
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.question-card p {
    font-weight: 600;
    font-size: 1.2em;
    margin-top: 0;
    color: var(--color-text);
}

.options label {
    display: flex;
    align-items: center;
    margin: 8px 0;
    padding: 12px;
    background-color: var(--color-background);
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.2s, border-color 0.2s;
    border: 2px solid transparent;
}

.options label:hover {
    background-color: #d8dee8;
}

.options input[type="radio"] {
    margin-right: 15px;
    min-width: 20px; 
    height: 20px;
    cursor: pointer;
}

/* Style for selected options (before submission) */
.options input[type="radio"]:checked + label {
    border-color: var(--color-secondary);
    background-color: #fffbe6;
}

/* --- Buttons and Results --- */
.main-btn {
    display: block;
    width: 100%;
    padding: 15px;
    background-color: var(--color-secondary);
    color: var(--color-primary);
    border: none;
    border-radius: 8px;
    font-size: 1.2em;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.1s;
    text-transform: uppercase;
    margin-top: 20px;
}

.main-btn:hover {
    background-color: #e6b900;
}

.main-btn:active {
    transform: scale(0.99);
}

.secondary-btn {
    background-color: var(--color-primary);
    color: white;
    margin-top: 15px;
}

.secondary-btn:hover {
    background-color: #002e6b;
}

#final-result-area {
    background-color: var(--color-primary);
    color: white;
    padding: 25px;
    border-radius: 10px;
    text-align: center;
    font-size: 1.2em;
    margin-top: 40px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.hidden {
    display: none !important;
}

#score-text {
    font-size: 2em;
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    margin: 10px 0;
}

/* Highlight correct/incorrect answers after submission */
.correct {
    background-color: #d4edda !important; /* Vert clair */
    border: 2px solid var(--color-success) !important;
}

.incorrect {
    background-color: #f8d7da !important; /* Rouge clair */
    border: 2px solid var(--color-error) !important;
}

/* Styles pour le classement */
#leaderboard-area {
    background-color: var(--color-card-bg);
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    margin-top: 40px;
}

#leaderboard-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

#leaderboard-table th, #leaderboard-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

#leaderboard-table thead th {
    background-color: var(--color-primary);
    color: white;
    font-family: 'Montserrat', sans-serif;
}

#leaderboard-table tbody tr:nth-child(even) {
    background-color: #f9f9f9;
}

#leaderboard-table tbody tr:hover {
    background-color: #f1f1f1;
}

#leaderboard-table tbody tr:first-child td {
    font-weight: bold;
    color: var(--color-secondary);
    background-color: #fff9e6;
}

/* Styles pour le champ de nom */
#player-name {
    width: 95%;
    padding: 10px;
    margin-bottom: 20px;
    border: 2px solid var(--color-primary);
    border-radius: 5px;
    font-size: 1em;
}

/* Styles pour la question unique */
#question-area {
    min-height: 250px; /* Assure une certaine hauteur pour l'affichage */
}