/* style.css */

:root {
    --primary-color: #0055aa;       /* Couleur principale (Bleu) */
    --primary-hover: #003d7a;       /* Couleur au survol */
    --error-bg: #fdecea;            /* Fond pour l'erreur */
    --error-text: #d32f2f;          /* Texte d'erreur */
    --border-color: #ccc;
    --bg-color: #f4f6f8;
    --text-color: #333;
    --white: #ffffff;
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Liberation Sans', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    background-color: var(--bg-color);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    color: var(--text-color);
    line-height: 1.6;
}

/* Conteneur principal */
.login-container {
    background: var(--white);
    padding: 2.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 400px;
    margin: 1rem; /* Marge pour les petits écrans */
}

/* En-tête */
.login-header {
    text-align: center;
    margin-bottom: 2rem;
}

.login-header h1 {
    font-size: 1.5rem;
    margin: 0;
    color: var(--primary-color);
    font-weight: 700;
}

.login-header p {
    color: #666;
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

/* Champs du formulaire */
.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-color);
}

.form-group input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-group input:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 85, 170, 0.1);
}

/* Message d'erreur */
.error-message {
    background-color: var(--error-bg);
    color: var(--error-text);
    padding: 0.75rem;
    border-radius: 4px;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    border-left: 4px solid var(--error-text);
    text-align: center;
}

/* Bouton */
.btn-submit {
    width: 100%;
    padding: 0.75rem;
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s;
    margin-top: 0.5rem;
}

.btn-submit:hover {
    background-color: var(--primary-hover);
}

.btn-submit:active {
    transform: translateY(1px);
}

/* Pied de page du formulaire */
.login-footer {
    margin-top: 1.5rem;
    text-align: center;
    font-size: 0.85rem;
    color: #888;
}

/* Responsive : ajustements pour très petits écrans */
@media (max-width: 480px) {
    .login-container {
        padding: 1.5rem;
        box-shadow: none; /* Plus plat sur mobile */
        background: transparent;
    }
    
    body {
        background-color: var(--white);
        align-items: flex-start; /* Remonter le contenu */
        padding-top: 2rem;
    }
}