@import url('https://fonts.googleapis.com/css2?family=Bangers&family=Cairo:wght@600&display=swap');

/* ================== RESET / BASE STYLING ================== */
html, body {
    margin: 0;
    padding: 0;
    width: 100vw;
    min-height: 100vh; /* Fix for white space issue */
    box-sizing: border-box;
    overflow: hidden;
}

body {
    direction: rtl;
    font-family: 'Cairo', sans-serif;
    background-image: url("/static/images/background-account.56e6ed74b0af.png");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;

    display: flex;
    justify-content: center;
    align-items: center;
}

/* ================== LOGIN CONTAINER ================== */
.login-container {
    width: 50vw;                /* For landscape/desktop, half the screen */
    display: flex;              /* Center the box inside */
    justify-content: center;
    align-items: center;
    padding: 2vh 2vw;
}

/* ================== LOGIN BOX ================== */
.login-box {
    position: relative;
    display: inline-block;
    padding: 4vh 3vw;
    text-align: center;
    box-sizing: border-box;
    background-color: rgba(255, 235, 170, 0.92);
    border: 3px solid #8B0000;
    border-radius: 1vw;
    box-shadow: 0.5vw 0.5vw 0 #000;
}

/* HEADER */
.login-box h2 {
    font-family: 'Bangers', cursive;
    font-size: 2.5vw;
    color: #8B0000;
    text-shadow: 1px 1px 1px black;
    margin-bottom: 2vh;
    background-color: #D4AF37;
    padding: 0.5vw 2vw;
    border-radius: 1vw;
    border: 2px solid black;
    display: inline-block;
}


/* FORM */
form {
    display: flex;
    flex-direction: column;
    gap: 1vh;
}

/* INPUT ROW */
.input-row {
    display: flex;
    flex-direction: row;
    justify-content: space-around;
    gap: 1vw;
}

.input-group {
    display: flex;
    flex-direction: column;
    width: 40%;
    text-align: right;
}

.input-group label {
    font-size: 1vw;
    font-weight: bold;
    margin-bottom: 1vh;
}

.input-group input {
    font-size: 1vw;
    padding: 1vh 1vw;
    border: 0.25vw solid #000;
    border-radius: 0.8vw;
    background-color: #fff;
    transition: 0.3s;
}

.input-group input:focus {
    outline: none;
    border-color: #D4AF37;
    background-color: #fffce8;
}


/* LOGIN BUTTON */
.btn-row {
    display: flex;
    justify-content: center;
}

.btn-confirm-login {
    background-color: #D4AF37;
    color: black;
    font-size: 1.2vw;
    font-weight: bold;
    padding: 1.2vh 2vw;
    border: 0.25vw solid black;
    border-radius: 1vw;
    cursor: pointer;
    transition: 0.3s ease-in-out;
}

.btn-confirm-login:hover {
    background-color: #8B0000;
    color: white;
    transform: scale(1.05);
}


/* OPTIONS ROW */
.options-row {
    display: flex;
    justify-content: center;
    gap: 2vw;
}

.forgot-password,
.register-link {
    color: black;
    background-color: #D4AF37;
    font-size: 1vw;
    font-weight: bold;
    padding: 1vh 1.5vw;
    border-radius: 1vw;
    border: 0.25vw solid black;
    transition: 0.3s;
    text-decoration: none;
}

.forgot-password:hover,
.register-link:hover {
    background-color: #8B0000;
    color: white;
}


/* ================== PORTRAIT MODE OVERRIDES ================== */
@media screen and (orientation: portrait) {
    /* Make the container fill the screen width and stay centered */
    .login-container {
        width: 90vw;
        margin: 0 auto;
        display: flex;
        justify-content: center;
        align-items: center;
        padding: 2vh 2vw;
        margin-top: -15vh;
    }

    .login-box {
        width: 90vw;
        padding: 5vh 4vw;
        margin: 0 auto;
        text-align: center;
    }

    /* Stack inputs vertically in portrait */
    .input-row {
        flex-direction: column;
        gap: 2vh; /* more vertical gap */

    }

    .input-group {
        width: 90%;
        margin: 0 auto;
        text-align: center;
    }

    .input-group input {
        text-align: center;
    }

    /* Larger fonts in portrait if desired */
    .login-box h2 {
        font-size: 4vw;
    }
    .input-group label,
    .input-group input,
    .btn-confirm-login,
    .forgot-password,
    .register-link {
        font-size: 4vw;
    }
}
