/* ======== FOND ANIMÉ ======== */
body {
    margin: 0;
    height: 100vh;
    overflow: hidden;
    font-family: 'Poppins', sans-serif;
}

.background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #007bff, #00b4d8);
    z-index: -1;
    overflow: hidden;
}

/* bulles animées */
.bubbles {
    position: absolute;
    bottom: -100px;
    display: flex;
    justify-content: space-around;
    width: 100%;
}

.bubbles span {
    position: relative;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.25);
    margin: 0 10px;
    border-radius: 50%;
    animation: rise 12s linear infinite;
    animation-duration: calc(120s / var(--i));
}

@keyframes rise {
    0% {
        transform: translateY(0) scale(1);
        opacity: 0.7;
    }
    100% {
        transform: translateY(-100vh) scale(1.3);
        opacity: 0;
    }
}

/* ======== FORMULAIRE ======== */
.login-container {
    position: relative;
    z-index: 10;
    height: 100vh;
}

.login-card {
    background: #fff;
    padding: 40px 30px;
    width: 100%;
    max-width: 400px;
    border: none;
    animation: fadeIn 0.8s ease forwards;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(40px); }
    to { opacity: 1; transform: translateY(0); }
}

.logo {
    width: 90px;
}

.form-control {
    border-radius: 12px;
    border: 1px solid #ced4da;
    padding: 12px;
    transition: all 0.3s ease;
}

.form-control:focus {
    border-color: #007bff;
    box-shadow: 0 0 10px rgba(0,123,255,0.2);
}

.btn-primary {
    background: linear-gradient(135deg, #007bff, #00b4d8);
    border: none;
    border-radius: 12px;
    padding: 12px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #0056b3, #007bff);
    transform: translateY(-2px);
}

.alert {
    border-radius: 10px;
    font-size: 0.9rem;
}

.animate-fade {
    animation: fadeError 0.6s ease-in-out;
}
@keyframes fadeError {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

/* ======== RESPONSIVE ======== */
@media (max-width: 480px) {
    .login-card {
        margin: 0 20px;
        padding: 30px 20px;
    }

    .logo {
        width: 70px;
    }
}