* {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    height: 100%;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    display: flex;
    justify-content: center;
    align-items: center;

    background: linear-gradient(370deg, #3498db, #6dd5fa, #5f9cff, #4facfe);
    background-size: 600% 600%; /* important for animation */

    position: relative;
    overflow: hidden;

    animation: gradientMove 12s ease infinite;
}

@keyframes gradientMove {
    0%   { background-position: 0% 50%; }
    25%  { background-position: 50% 100%; }
    50%  { background-position: 100% 50%; }
    75%  { background-position: 50% 0%; }
    100% { background-position: 0% 50%; }
}

body::before {
    content: "";
    position: absolute;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 20% 30%, rgba(255,255,255,0.15), transparent 40%),
                radial-gradient(circle at 80% 70%, rgba(255,255,255,0.1), transparent 40%);
    animation: floatBg 12s infinite linear;
}

@keyframes floatBg {
    0% { transform: translate(0,0); }
    50% { transform: translate(-5%, -5%); }
    100% { transform: translate(0,0); }
}

.login-container {
    position: relative;
    z-index: 2;

    width: 100%;
    max-width: 380px;

    padding: 30px 25px;
    border-radius: 16px;

    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);

    box-shadow: 0 20px 50px rgba(0,0,0,0.15);
}

.login-container h2 {
    text-align: center;
    margin-bottom: 8px;
    color: #2c3e50;
    font-size: 1.6rem;
    font-weight: 600;
}

.login-container .description {
    text-align: center;
    color: #7f8c8d;
    margin-bottom: 20px;
    font-size: 0.85rem;
}

.login-container label {
    font-size: 0.75rem;
    color: #7f8c8d;
    text-transform: uppercase;
    margin-bottom: 5px;
    display: block;
}

.login-container input {
    width: 100%;
    padding: 12px;
    margin-bottom: 14px;

    border-radius: 10px;
    border: 1px solid #ddd;

    font-size: 0.9rem;
    transition: 0.2s;
}

.login-container input:focus {
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52,152,219,0.15);
    outline: none;
}

.login-container button {
    width: 100%;
    padding: 12px;

    border: none;
    border-radius: 10px;

    background: linear-gradient(135deg, #3498db, #2980b9);
    color: #fff;

    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;

    transition: 0.2s ease;
}

.login-container button:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.error {
    background: #fdecea;
    color: #e74c3c;
    padding: 10px;
    border-radius: 8px;
    text-align: center;
    margin-bottom: 12px;
    font-size: 0.8rem;
}

.divider {
    text-align: center;
    margin: 15px 0;
    font-size: 11px;
    color: #aaa;
    position: relative;
}

.divider::before,
.divider::after {
    content: "";
    height: 1px;
    width: 40%;
    background: #ddd;
    position: absolute;
    top: 50%;
}

.divider::before { left: 0; }
.divider::after { right: 0; }

.google-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;

    padding: 10px;
    border-radius: 10px;

    background: #fff;
    border: 1px solid #ddd;

    font-size: 0.85rem;
    font-weight: 500;
    color: #444;
    text-decoration: none;

    transition: 0.2s;
}

.google-btn:hover {
    background: #f5f5f5;
}

.google-icon {
    width: 18px;
    height: 18px;
    min-width: 18px;   /* prevents stretching */
    object-fit: contain;
    display: block;
}

@media (max-width: 480px) {

    html, body {
        height: 100%;
        overflow: hidden; /* 🚀 prevents scroll */
    }

    body {
        display: flex;
        justify-content: center;
        align-items: center; /* ✅ center vertically again */
        padding: 0; /* remove push-down */
    }

    .login-container {
        width: 92%;
        max-width: 360px;
        padding: 22px 18px;
        border-radius: 14px;
    }

    .login-container h2 {
        font-size: 1.4rem;
    }
}