/* Login foundation */

/* NEXORA_LOGIN_ISOLATED_SHELL_START
   This stylesheet is loaded only by /Account/Login.
   Keep the login page independent from the authenticated application shell.
*/
.nexora-shell {
    display: block !important;
    min-height: 100dvh !important;
}

.nexora-sidebar,
.nexora-topbar {
    display: none !important;
}

.nexora-main {
    width: 100% !important;
    max-width: 100vw !important;
    min-width: 0 !important;
    min-height: 100dvh !important;
    margin: 0 !important;
}

.nexora-content {
    width: 100% !important;
    min-height: 100dvh !important;
    margin: 0 !important;
}
/* NEXORA_LOGIN_ISOLATED_SHELL_END */

/* NEXORA_LOGIN_VIEWPORT_FIT_START
   Keep the login experience inside the available NEXORA content viewport.
   The content pane remains the scroll owner only on genuinely short screens.
*/
.nexora-content {
    padding: clamp(8px, 1.35vh, 14px) !important;
    scrollbar-gutter: auto !important;
    scrollbar-width: thin;
    scrollbar-color: rgba(124, 234, 240, .44) transparent;
}

.nexora-content::-webkit-scrollbar {
    width: 7px;
    height: 7px;
}

.nexora-content::-webkit-scrollbar-track {
    background: transparent;
}

.nexora-content::-webkit-scrollbar-thumb {
    border-radius: 999px;
    background: rgba(124, 234, 240, .44);
    border: 2px solid transparent;
    background-clip: padding-box;
}

.nexora-content::-webkit-scrollbar-thumb:hover {
    background: rgba(124, 234, 240, .68);
    background-clip: padding-box;
}

.login-page {
    width: 100%;
    min-height: 100%;
    display: grid;
    place-items: center;
    padding: clamp(10px, 1.8vh, 18px) clamp(14px, 2vw, 24px);
}

.login-card {
    width: min(420px, 100%);
    background: var(--sa-surface);
    border: 1px solid var(--sa-border);
    border-radius: 22px;
    box-shadow: var(--sa-shadow);
    padding: clamp(18px, 2.4vh, 24px);
    text-align: center;
}

.login-logo {
    width: 54px;
    height: 54px;
    border-radius: 17px;
    margin: 0 auto 10px;
    background: var(--sa-primary);
    color: #fff;
    display: grid;
    place-items: center;
    font-weight: 1000;
    font-size: 20px;
}

.login-card h1 {
    margin: 0;
    color: var(--sa-text);
    font-size: 24px;
    line-height: 1.2;
    font-weight: 1000;
}

.login-card p {
    color: var(--sa-muted);
    font-weight: 850;
    font-size: 14px;
    line-height: 1.4;
    margin: 5px 0 13px;
}

.login-form {
    display: grid;
    gap: 9px;
    text-align: start;
}

.login-field {
    display: grid;
    gap: 5px;
}

.login-field label,
.login-check span {
    color: var(--sa-text);
    font-weight: 1000;
    font-size: 13px;
}

.login-field input {
    min-height: 40px;
    border-radius: 12px;
    border: 1px solid var(--sa-border);
    background: var(--sa-input);
    color: var(--sa-text);
    padding: 0 12px;
    font-weight: 900;
}

.login-check {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 22px;
}

.login-button {
    min-height: 42px;
    border-radius: 13px;
    border: 1px solid var(--sa-primary);
    background: var(--sa-primary);
    color: #fff;
    font-family: inherit;
    font-weight: 1000;
    cursor: pointer;
}

.login-error {
    background: var(--sa-danger-soft);
    color: var(--sa-danger);
    border: 1px solid rgba(239, 68, 68, .28);
    border-radius: 13px;
    padding: 10px;
    font-weight: 900;
    margin-bottom: 10px;
}

.login-note {
    margin-top: 10px;
    color: var(--sa-muted);
    font-weight: 850;
    font-size: 12px;
    line-height: 1.35;
}

.login-note strong {
    color: var(--sa-text);
}

html[data-theme="dark"] .login-card {
    background: #111a2c !important;
    border-color: #30415f !important;
}

html[data-theme="dark"] .login-field input {
    background: #162238 !important;
    border-color: #30415f !important;
}

@media (max-width: 980px) {
    .login-page {
        min-height: auto;
        padding: 16px 10px;
    }

    .login-card {
        width: min(400px, 100%);
    }
}

@media (max-height: 640px) and (min-width: 981px) {
    .login-page {
        padding-block: 6px;
    }

    .login-card {
        padding-block: 16px;
    }

    .login-logo {
        width: 48px;
        height: 48px;
        margin-bottom: 8px;
        font-size: 18px;
    }

    .login-card h1 {
        font-size: 22px;
    }

    .login-card p {
        margin-bottom: 10px;
    }

    .login-form {
        gap: 8px;
    }
}
/* NEXORA_LOGIN_VIEWPORT_FIT_END */
