/* Base et corps de page */
body {
    font-family: 'Arial', sans-serif;
    max-width: 600px;
    margin: 2em auto;
    padding: 20px;
    background: linear-gradient(135deg, #1e1e2f, #2a2a40);
    color: #ffffff;
    line-height: 1.6;
    box-sizing: border-box;
}

/* Titre principal */
h1 {
    font-size: 2rem;
    color: #61dafb;
    text-align: center;
    margin-bottom: 1.5em;
    text-shadow: 0 1px 3px rgba(0,0,0,0.7);
}

/* Formulaire */
form {
    background: rgba(255, 255, 255, 0.1);
    padding: 20px 25px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.5);
}

/* Tous les champs */
input[type="text"],
input[type="email"],
textarea {
    width: 100%;
    padding: 12px 15px;
    margin-top: 1em;
    border-radius: 6px;
    border: none;
    background-color: #282c34;
    color: #dcdcdc;
    font-size: 1rem;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.6);
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
    resize: vertical;
}

/* Placeholder plus clair */
input::placeholder,
textarea::placeholder {
    color: #888ea8;
}

/* Focus sur les champs */
input[type="text"]:focus,
input[type="email"]:focus,
textarea:focus {
    background-color: #3a3f58;
    outline: none;
    box-shadow: 0 0 8px #61dafb;
    color: #ffffff;
}

/* Bouton d’envoi */
button[type="submit"] {
    margin-top: 1.5em;
    padding: 12px;
    width: 100%;
    background-color: #61dafb;
    border: none;
    border-radius: 6px;
    font-weight: bold;
    color: #282c34;
    font-size: 1.1rem;
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(33, 161, 241, 0.7);
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

button[type="submit"]:hover,
button[type="submit"]:focus {
    background-color: #21a1f1;
    box-shadow: 0 6px 10px rgba(33, 161, 241, 1);
    outline: none;
}

/* Résultat affiché sous le formulaire */
#result {
    margin-top: 1.5em;
    font-weight: bold;
    text-align: center;
    min-height: 1.5em;
}

/* Messages de succès */
.success {
    color: #4BB543; /* vert */
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}

/* Messages d’erreur */
.error {
    color: #FF4136; /* rouge vif */
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}

/* Widget reCAPTCHA : centrage et marge */
.g-recaptcha {
    margin-top: 1.5em;
    display: flex;
    justify-content: center;
}

/* Responsive - tablette et petit écran */
@media (max-width: 600px) {
    body {
        margin: 1em 1em 2em 1em;
        padding: 15px;
    }
    h1 {
        font-size: 1.5rem;
    }
    button[type="submit"] {
        font-size: 1rem;
        padding: 10px;
    }
}
/* Appliquer box-sizing à tous les éléments et pseudo-éléments */
*, *::before, *::after {
    box-sizing: border-box;
}

/* Bouton toggle Dark/Light */
#theme-toggle {
    position: fixed;
    top: 15px;
    left: 15px;
    padding: 8px 15px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    background-color: #61dafb;
    color: #282c34;
    font-weight: bold;
    z-index: 1000;
    transition: background 0.3s ease, color 0.3s ease;
}
#theme-toggle:hover { background-color: #21a1f1; }

/* Light Theme */
body.light-theme { background: linear-gradient(135deg, #f5f5f5, #e0e0e0); color: #282c34; }
body.light-theme form { background: rgba(255,255,255,0.9); color: #282c34; }
body.light-theme input[type="text"],
body.light-theme input[type="email"],
body.light-theme textarea { background-color: #f0f0f0; color: #282c34; box-shadow: inset 0 2px 4px rgba(0,0,0,0.1); }
body.light-theme input:focus, body.light-theme textarea:focus { background-color: #ffffff; color: #000000; box-shadow: 0 0 8px #0b3d91; }
body.light-theme button[type="submit"] { background-color: #0b3d91; color: #ffffff; }
body.light-theme button[type="submit"]:hover, body.light-theme button[type="submit"]:focus { background-color: #44475a; }


