:root {
    --background: #1a1a2e;
    --color: #ffffff;
    --primary-color: #0f3460;
}

* {
    box-sizing: border-box;
}

html,
body {
    scroll-behavior: smooth;
    height: 100%;
    overflow: hidden;
    /* Scrollni o'chirish faqat login sahifasida */
}

body {
    margin: 0;
    box-sizing: border-box;
    font-family: "poppins";
    background: var(--background);
    color: var(--color);
    letter-spacing: 1px;
    transition: background 0.2s ease;
    -webkit-transition: background 0.2s ease;
    -moz-transition: background 0.2s ease;
    -ms-transition: background 0.2s ease;
    -o-transition: background 0.2s ease;
}


h1 {
    font-size: 2.5rem;
}

/* Make container fixed to viewport so no page scrolling occurs (especially on mobile) */
.container {
    position: fixed;
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    /* remove height: 100vh to avoid mobile address-bar + vh issues */
    padding: 0 20px;
    /* Qo'shimcha padding */
}



.login-container {
    position: relative;
    width: 100%;
    /* 100% kenglik */
    max-width: 400px;
    /* Maksimal kenglik */
}

.form-container {
    border: 1px solid hsla(0, 0%, 65%, 0.158);
    box-shadow: 0 0 36px 1px rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    backdrop-filter: blur(20px);
    z-index: 99;
    padding: 2rem;
    -webkit-border-radius: 10px;
    -moz-border-radius: 10px;
    -ms-border-radius: 10px;
    -o-border-radius: 10px;
}



.login-container form {
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Default (desktop/tablet) input/button size */
.login-container form input {
    padding: 16px;
    /* Katta padding */
    display: block;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    margin: 1rem 0;
    color: var(--color);
    outline: none;
    background-color: #9191911f;
    border: none;
    border-radius: 5px;
    font-weight: 500;
    letter-spacing: 0.8px;
    font-size: 16px;
    /* Katta shrift o'lchami */
    backdrop-filter: blur(15px);
    -webkit-border-radius: 5px;
    -moz-border-radius: 5px;
    -ms-border-radius: 5px;
    -o-border-radius: 5px;
}


.login-container form input:focus {
    box-shadow: 0 0 16px 1px rgba(0, 0, 0, 0.2);
    animation: wobble 0.3s ease-in;
    -webkit-animation: wobble 0.3s ease-in;
}

.login-container form button {
    padding: 15px;
    /* Katta padding */
    background-color: var(--primary-color);
    color: var(--color);
    display: block;
    border-radius: 5px;
    outline: none;
    font-size: 20px;
    /* Katta shrift o'lchami */
    letter-spacing: 1.5px;
    font-weight: bold;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    cursor: pointer;
    margin-bottom: 2rem;
    transition: all 0.1s ease-in-out;
    border: none;
    -webkit-border-radius: 5px;
    -moz-border-radius: 5px;
    -ms-border-radius: 5px;
    -o-border-radius: 5px;
    -webkit-transition: all 0.1s ease-in-out;
    -moz-transition: all 0.1s ease-in-out;
    -ms-transition: all 0.1s ease-in-out;
    -o-transition: all 0.1s ease-in-out;
}

.login-container form button:hover {
    box-shadow: 0 0 10px 1px rgba(0, 0, 0, 0.15);
    transform: scale(1.02);
    -webkit-transform: scale(1.02);
    -moz-transform: scale(1.02);
    -ms-transform: scale(1.02);
    -o-transform: scale(1.02);
}

.circle {
    width: 8rem;
    height: 8rem;
    background: var(--primary-color);
    border-radius: 50%;
    -webkit-border-radius: 50%;
    -moz-border-radius: 50%;
    -ms-border-radius: 50%;
    -o-border-radius: 50%;
    position: absolute;
}



.circle-one {
    top: 0;
    left: 0;
    z-index: -1;
    transform: translate(-45%, -45%);
    -webkit-transform: translate(-45%, -45%);
    -moz-transform: translate(-45%, -45%);
    -ms-transform: translate(-45%, -45%);
    -o-transform: translate(-45%, -45%);
}

.circle-two {
    bottom: 0;
    right: 0;
    z-index: -1;
    transform: translate(45%, 45%);
    -webkit-transform: translate(45%, 45%);
    -moz-transform: translate(45%, 45%);
    -ms-transform: translate(45%, 45%);
    -o-transform: translate(45%, 45%);
}


.opacity {
    opacity: 0.6;
}


@keyframes wobble {
    0% {
        transform: scale(1.025);
        -webkit-transform: scale(1.025);
        -moz-transform: scale(1.025);
        -ms-transform: scale(1.025);
        -o-transform: scale(1.025);
    }

    25% {
        transform: scale(1);
        -webkit-transform: scale(1);
        -moz-transform: scale(1);
        -ms-transform: scale(1);
        -o-transform: scale(1);
    }

    75% {
        transform: scale(1.025);
        -webkit-transform: scale(1.025);
        -moz-transform: scale(1.025);
        -ms-transform: scale(1.025);
        -o-transform: scale(1.025);
    }

    100% {
        transform: scale(1);
        -webkit-transform: scale(1);
        -moz-transform: scale(1);
        -ms-transform: scale(1);
        -o-transform: scale(1);
    }
}

/* Ensure form fits small screens: reduce vertical spacing and padding on phones */
@media (max-width: 480px) {
    .form-container {
        padding: 1rem;
        max-height: calc(100vh - 20px);
        overflow: hidden;
    }

    .login-container form input {
        width: 80%;
        padding: 14px;
        font-size: 15px;
        margin: 0.5rem 0;
    }

    .login-container form button {
        width: 80%;
        padding: 14px;
        font-size: 18px;
        margin-bottom: 1.5rem; /* button ostida ko'proq bo'sh joy */
        margin-top: 1rem;      /* password inputdan keyin ko'proq bo'sh joy */
    }

    .login-container {
        max-width: 360px;
    }

    .form-container img,
    .form-container img[width] {
        max-width: 120px;
        height: auto;
    }
}

.error-msg {
    color: #d32f2f;
    font-weight: 600;
    text-align: center;
    margin-bottom: 10px;
    background: none;
    border: none;
    padding: 0;
    font-size: 1rem;
    box-shadow: none;
    letter-spacing: 0.5px;
}

/* Disable text selection for login page */
.container,
.login-container,
.form-container,
.form-container *,
.circle,
.circle-one,
.circle-two {
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}