/* ================= RESET ================= */

*{
    margin:0;
    padding:0;
    box-sizing:border-box;
}

/* ================= BODY ================= */

body{
    font-family:'Cairo',sans-serif;

    min-height:100vh;        /* FIX: allow scroll */
    display:flex;
    justify-content:center;
    align-items:center;

    background:
    linear-gradient(
        rgba(15,23,42,0.75),
        rgba(15,23,42,0.75)
    ),
    url('https://images.unsplash.com/photo-1587854692152-cbe660dbde88?q=80&w=1600');

    background-size:cover;
    background-position:center;

    padding:40px 15px;       /* IMPORTANT FIX */
    overflow-y:auto;         /* allow scroll */
}

/* ================= LOGIN CARD (GLASS EFFECT) ================= */

.login-box{
    width:420px;
    max-width:100%;

    background:rgba(255,255,255,0.15);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);

    border:1px solid rgba(255,255,255,0.25);

    padding:45px;

    border-radius:24px;

    box-shadow:
    0 10px 40px rgba(0,0,0,0.3);

    animation:fadeUp 0.6s ease;
}

/* ================= ANIMATION ================= */

@keyframes fadeUp{
    from{
        opacity:0;
        transform:translateY(30px);
    }
    to{
        opacity:1;
        transform:translateY(0);
    }
}

/* ================= LOGO ================= */

.logo{
    text-align:center;
    font-size:50px;
    margin-bottom:10px;
}

/* ================= TITLE ================= */

h2{
    text-align:center;
    color:white;
    margin-bottom:10px;
    font-size:30px;
}

.subtitle{
    text-align:center;
    color:#cbd5e1;
    margin-bottom:35px;
    line-height:1.8;
}

/* ================= INPUTS ================= */

.input-group{
    margin-bottom:18px;
}

.input-group label{
    display:block;
    margin-bottom:8px;
    color:#e2e8f0;
    font-weight:600;
}

input{
    width:100%;
    padding:15px;

    border:1px solid rgba(255,255,255,0.3);
    border-radius:14px;

    font-size:15px;
    font-family:'Cairo',sans-serif;

    transition:0.3s;

    background:rgba(255,255,255,0.08);
    color:white;
}

input::placeholder{
    color:#cbd5e1;
}

input:focus{
    border-color:#38bdf8;
    outline:none;

    background:rgba(255,255,255,0.15);

    box-shadow:0 0 0 4px rgba(56,189,248,0.2);
}

/* ================= BUTTONS ================= */

.buttons{
    display:flex;
    flex-direction:column;
    gap:15px;
    margin-top:25px;
}

.buttons button{
    width:100%;
    padding:15px;

    border:none;
    border-radius:14px;

    font-size:16px;
    font-family:'Cairo',sans-serif;

    cursor:pointer;
    transition:0.3s;
}

/* LOGIN BUTTON */

.login-btn{
    background:#2563eb;
    color:white;
}

.login-btn:hover{
    background:#1d4ed8;
    transform:translateY(-2px);
}

/* BACK BUTTON */

.back-btn{
    background:rgba(255,255,255,0.15);
    color:white;
    border:1px solid rgba(255,255,255,0.3);
}

.back-btn:hover{
    background:rgba(255,255,255,0.25);
    transform:translateY(-2px);
}

/* ================= ERROR ================= */

.error{
    background:rgba(254,226,226,0.9);
    color:#b91c1c;
    padding:14px;
    border-radius:12px;
    margin-top:20px;
    text-align:center;
    font-size:14px;
}

/* ================= FOOTER ================= */

.footer{
    text-align:center;
    margin-top:30px;
    color:#cbd5e1;
    font-size:14px;
}

/* ================= MOBILE ================= */

@media(max-width:500px){
    .login-box{
        padding:30px 20px;
    }

    h2{
        font-size:24px;
    }
}