/* STYLE GÉNÉRAL */
body {
    font-family: 'Comic Sans MS', 'Arial', sans-serif;
    background-color: #fff7e6;
    color: #333;
    margin: 0;
    padding: 2rem;
    background-image: url('./background.png');
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    /* flou subtil */
    /* texture subtile */
}

h1 {
    text-align: center;
    color: #d63384;
    font-size: 2.5rem;
    margin-bottom: 1rem;
    text-shadow: 1px 1px 0 #ffb6c1;
}

p {
    text-align: center;
    font-size: 1.1rem;
    margin: 0.3rem 0;
}

form {
    background-color: #ffffff;
    padding: 2rem;
    margin: 2rem auto;
    max-width: 600px;
    border-radius: 15px;
    box-shadow: 0 0 15px rgba(214, 51, 132, 0.2);
    border: 2px dashed #d63384;
    position: relative;
}

/* CHAMPS DE FORMULAIRE */
label {
    display: block;
    margin-top: 1.2rem;
    font-weight: bold;
    color: #cc3366;
}

input[type="text"],
input[type="number"],
textarea,
select {
    width: 100%;
    padding: 10px;
    margin-top: 5px;
    border: 2px solid #ffd6e8;
    border-radius: 8px;
    background-color: #fff0f5;
    font-family: inherit;
    font-size: 1rem;
}

textarea {
    resize: vertical;
}

/* Style pour les boutons radio et leurs labels */
input[type="radio"] {
    margin-right: 8px;
    transform: scale(1.3);
    cursor: pointer;
    vertical-align: middle;
}

.for-allergie {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
    margin-right: 20px;
    font-size: 16px;
}

.radio-group {
    margin-top: 0.5rem;
    display: flex;
    gap: 1.5rem;
}

/* Utilisez flexbox pour aligner les éléments horizontalement */
form p {
    display: flex;
    align-items: center;
    margin: 0.5rem 0;
    color: #555;
    font-weight: normal;
}

form p input[type="radio"] {
    margin-right: 10px;
}

/* BOUTON */
button {
    display: block;
    margin: 2rem auto 0;
    background-color: #ff69b4;
    color: white;
    padding: 12px 25px;
    border: none;
    border-radius: 8px;
    font-size: 1.2rem;
    cursor: pointer;
    transition: 0.2s ease-in-out;
    box-shadow: 2px 2px 0 #b02a66;
}

button:hover {
    background-color: #d63384;
    transform: scale(1.05);
    animation: tremble 0.2s ease-in-out infinite;
}

.emoji-top-left,
.emoji-top-right,
.emoji-bottom-left,
.emoji-bottom-right {
    position: absolute;
    font-size: 1.8rem;
    opacity: 0.8;
}

.emoji-top-left {
    top: -10px;
    left: -10px;
}

.emoji-top-right {
    top: -10px;
    right: -10px;
}

.emoji-bottom-left {
    bottom: -10px;
    left: -10px;
}

.emoji-bottom-right {
    bottom: -10px;
    right: -10px;
}

@keyframes tremble {

    0%,
    100% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(-3px);
    }

    50% {
        transform: translateX(3px);
    }

    75% {
        transform: translateX(-1px);
    }
}

/* RESPONSIVE */
@media (max-width: 600px) {
    body {
        padding: 1rem;
    }

    form {
        padding: 1.5rem;
    }

    h1 {
        font-size: 2rem;
    }

    /* Style pour les boutons radio sur mobile */
    input[type="radio"] {
        transform: scale(1.8);
        /* Augmente légèrement la taille des boutons */
        margin: 0.5rem 1rem 0.5rem 0;
        /* Ajoute un peu de marge pour faciliter le clic */
    }

    /* Augmente la taille de la zone cliquable */
    label {
        padding: 0.5rem;
        /* Ajoute du padding pour agrandir la zone cliquable */
    }

    /* Utilisez flexbox pour aligner les éléments horizontalement */
    form p {
        display: flex;
        align-items: center;
        margin: 0.5rem 0;
    }

    /* Assurez-vous que les labels sont correctement associés aux boutons radio */
    .for-allergie {
        margin-right: 1rem;
        font-size: 16px;
    }
}
