/* Layout principal - fond blanc avec hauteur parfaite */
.login-container {
    min-height: 100vh;
    height: 100vh;
    max-height: 100vh;
    overflow: hidden;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

/* Carte de connexion - avec hauteur adaptative */
.login-card {
    background: white;
    border-radius: 20px;
    padding: 2rem 2.5rem;
    width: 100%;
    max-width: 420px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(13, 148, 136, 0.15);
    animation: slideUp 0.5s ease;
    border: 1px solid #e5e7eb;
}

/* Masquer la scrollbar tout en gardant la fonctionnalité */
.login-card::-webkit-scrollbar {
    width: 4px;
}

.login-card::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.login-card::-webkit-scrollbar-thumb {
    background: #0D9488;
    border-radius: 4px;
}

.login-card::-webkit-scrollbar-thumb:hover {
    background: #0B7A6E;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* En-tête */
.login-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.login-header h1 {
    font-size: 2rem;
    font-weight: 700;
    color: #0B7A6E;
    margin-bottom: 0.25rem;
    line-height: 1.2;
}

.login-header .subtitle {
    color: #0D9488;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Logo ou icône */
.logo-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #0D9488, #0B7A6E);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    color: white;
    box-shadow: 0 4px 12px rgba(13, 148, 136, 0.2);
}

.logo-icon svg {
    width: 35px;
    height: 35px;
    stroke: currentColor;
    stroke-width: 1.5;
    fill: none;
}

/* Alerte d'erreur */
.alert {
    padding: 0.75rem 1rem;
    border-radius: 10px;
    margin-bottom: 1rem;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.alert-danger {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #f87171;
}

.alert-danger svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    flex-shrink: 0;
}

/* Message utilisateur connecté */
.user-logged {
    background: #F0FDFA;
    border: 1px solid #5EEAD4;
    border-radius: 10px;
    padding: 0.75rem 1rem;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    color: #0B7A6E;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.user-logged a {
    color: #0D9488;
    font-weight: 500;
    text-decoration: underline;
    font-size: 0.85rem;
}

.user-logged a:hover {
    color: #0B7A6E;
}

/* Formulaire */
.form-group {
    margin-bottom: 1.25rem;
}

.form-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.35rem;
}

.form-label i {
    color: #0D9488;
    margin-right: 0.25rem;
    font-style: normal;
}

.form-input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 0.95rem;
    transition: all 0.3s;
    background: #ffffff;
}

.form-input:focus {
    outline: none;
    border-color: #0D9488;
    background: white;
    box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.1);
}

.form-input::placeholder {
    color: #9ca3af;
    font-size: 0.9rem;
}

/* Options supplémentaires */
.form-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 1rem 0;
    font-size: 0.85rem;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    color: #4b5563;
    cursor: pointer;
}

.remember-me input[type="checkbox"] {
    width: 14px;
    height: 14px;
    accent-color: #0D9488;
    cursor: pointer;
    margin: 0;
}

.forgot-password {
    color: #0D9488;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
    font-size: 0.85rem;
}

.forgot-password:hover {
    color: #0B7A6E;
    text-decoration: underline;
}

/* Bouton de connexion */
.btn-login {
    width: 100%;
    padding: 0.875rem 1rem;
    background: linear-gradient(135deg, #0D9488, #0B7A6E);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(13, 148, 136, 0.25);
}

.btn-login svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    stroke-width: 2;
}

/* Pied de page */
.login-footer {
    margin-top: 1rem;
    text-align: center;
    font-size: 0.7rem;
    color: #9ca3af;
}

.login-footer span {
    color: #0D9488;
    font-weight: 600;
}

/* Version mobile - écrans petits */
@media (max-width: 480px) {
    .login-container {
        padding: 0.5rem;
    }

    .login-card {
        padding: 1.5rem 1.25rem;
        max-width: 100%;
        max-height: 95vh;
    }

    .logo-icon {
        width: 60px;
        height: 60px;
        margin-bottom: 0.75rem;
    }

    .logo-icon svg {
        width: 30px;
        height: 30px;
    }

    .login-header h1 {
        font-size: 1.75rem;
    }

    .form-input {
        padding: 0.7rem 0.875rem;
    }

    .btn-login {
        padding: 0.75rem 1rem;
    }
}

/* Version très petits écrans */
@media (max-width: 360px) {
    .login-card {
        padding: 1.25rem 1rem;
    }

    .login-header h1 {
        font-size: 1.5rem;
    }

    .subtitle {
        font-size: 0.8rem;
    }

    .form-options {
        flex-direction: column;
        gap: 0.5rem;
        align-items: flex-start;
    }
}

/* Version écrans moyens (tablettes) */
@media (min-width: 481px) and (max-width: 768px) {
    .login-card {
        padding: 2rem;
        max-width: 400px;
    }
}

/* Version écrans très grands */
@media (min-width: 1440px) {
    .login-card {
        max-width: 450px;
        padding: 2.5rem;
    }

    .logo-icon {
        width: 80px;
        height: 80px;
    }

    .logo-icon svg {
        width: 40px;
        height: 40px;
    }
}
