/* style.css – styles simples et responsifs du quiz */
body {
    margin: 0;
    font-family: "Comic Sans MS", "Arial", Helvetica, sans-serif; /* touche festive */
    background: linear-gradient(180deg, #e0f7fa 0%, #fff1e0 100%); /* dégradé pastel hiver */
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    /* arrière‑plan de flocons de neige */
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64"><circle cx="32" cy="32" r="2" fill="%23ffffff"/><circle cx="16" cy="16" r="1.5" fill="%23ffffff"/><circle cx="48" cy="48" r="1.5" fill="%23ffffff"/></svg>');
    background-repeat: repeat;
}

.quiz-container {
    background: #fff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    max-width: 500px;
    width: 100%;
    text-align: center;
    border: 3px solid #c62828; /* bordure rouge festive */
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="200" height="200"><polygon points="100,10 120,80 190,80 130,120 150,190 100,150 50,190 70,120 10,80 80,80" fill="%23c62828" opacity="0.05"/></svg>');
    background-repeat: no-repeat;
    background-position: center;
}

#photo {
    max-width: 100%;
    height: auto;
    margin: 1rem 0;
    border-radius: 4px;
    border: 2px solid #ddd;
}

.options button {
    display: block;
    width: 100%;
    margin: 0.5rem 0;
    padding: 0.6rem;
    background: #d0f0c0; /* vert menthe de Noël */
    border: 1px solid #8bc34a; /* bordure verte */
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    color: #2e7d32; /* texte vert foncé */
}

.options button:hover {
    background: #b2dfdb; /* vert plus sombre au survol */
}

.feedback {
    font-weight: bold;
    margin-top: 1rem;
}

.next-btn {
    margin-top: 1rem;
    padding: 0.6rem 1.2rem;
    background: #c62828; /* rouge Noël */
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}
.next-btn:hover {
    background: #b71c1c; /* rouge plus sombre au survol */
}

/* -----------------------------------------------------------------
   Styles pour la page d'accueil et le formulaire
   ----------------------------------------------------------------- */
.name-form {
    margin-top: 2rem;
}

.name-form label {
    display: block;
    font-size: 1.1rem;
    color: #2e7d32;
    margin-bottom: 0.5rem;
    font-weight: bold;
}

.name-form input {
    width: 100%;
    padding: 0.8rem;
    font-size: 1rem;
    border: 2px solid #8bc34a;
    border-radius: 4px;
    margin-bottom: 1rem;
    box-sizing: border-box;
    font-family: "Comic Sans MS", "Arial", Helvetica, sans-serif;
}

.name-form input:focus {
    outline: none;
    border-color: #2e7d32;
    box-shadow: 0 0 5px rgba(46, 125, 50, 0.3);
}

/* -----------------------------------------------------------------
   Styles pour l'affichage de l'utilisateur
   ----------------------------------------------------------------- */
.user-info {
    background: #e8f5e9;
    padding: 0.8rem;
    border-radius: 4px;
    margin-bottom: 1rem;
    font-weight: bold;
    color: #2e7d32;
    border: 2px solid #8bc34a;
}

/* -----------------------------------------------------------------
   Styles pour les résultats du vote
   ----------------------------------------------------------------- */
.results {
    text-align: left;
    margin-top: 1rem;
}

.results h3 {
    color: #c62828;
    margin-bottom: 1rem;
}

.vote-summary {
    list-style: none;
    padding: 0;
}

.vote-summary li {
    padding: 0.8rem;
    margin: 0.5rem 0;
    border-radius: 4px;
    border: 2px solid #8bc34a;
    background: #e8f5e9;
}

.vote-summary li.vote-item {
    background: #e8f5e9;
    border-color: #8bc34a;
}
/* -----------------------------------------------------------------
   Snowfall effect – flocons qui tombent
   ----------------------------------------------------------------- */
.snowfall {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
    z-index: 10; /* au‑dessus du contenu du quiz */
}

/* chaque flocon */
.snowfall span {
    position: absolute;
    top: -10px;
    width: 8px;
    height: 8px;
    background: #fff;
    border-radius: 50%;
    opacity: 0.9;
    animation: fall linear infinite;
}

/* positions et vitesses aléatoires */
.snowfall span:nth-child(1) { left: 10%;  animation-duration: 12s; animation-delay: -2s; }
.snowfall span:nth-child(2) { left: 25%;  animation-duration: 9s;  animation-delay: -4s; }
.snowfall span:nth-child(3) { left: 40%;  animation-duration: 11s; animation-delay: -1s; }
.snowfall span:nth-child(4) { left: 55%;  animation-duration: 13s; animation-delay: -3s; }
.snowfall span:nth-child(5) { left: 70%;  animation-duration: 8s;  animation-delay: -5s; }
.snowfall span:nth-child(6) { left: 85%;  animation-duration: 10s; animation-delay: -2s; }

/* animation de chute */
@keyframes fall {
    0%   { transform: translateY(0) rotate(0deg); }
    100% { transform: translateY(110vh) rotate(360deg); }
}