.login-page {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px 16px 32px;
    position: relative;
}

.login-card__header {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-bottom: 24px;
}

.login-logos {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
}

.login-logos__divider {
    width: 1px;
    height: 28px;
    background: var(--app-border);
}

.login-logo {
    height: 36px;
    width: auto;
    object-fit: contain;
}

/* Fallback por si la imagen del logo no carga. */
.login-logo--fallback {
    display: none;
}

.login-logo--fallback + .login-suite::before {
    content: "VCO";
    display: block;
    font-size: 24px;
    font-weight: 700;
    color: var(--app-navy);
    letter-spacing: -0.02em;
    margin-bottom: 6px;
}

.login-suite {
    margin: 10px 0 0;
    font-size: 12.5px;
    font-weight: 500;
    color: var(--app-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.login-alert {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    line-height: 1.4;
    color: var(--app-danger);
    background: var(--app-danger-bg);
    border: 1px solid rgba(192, 57, 43, 0.25);
    border-radius: var(--app-radius);
    padding: 10px 12px;
}

.login-alert[hidden] {
    display: none;
}

.login-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.login-field__label {
    font-size: 12.5px;
    font-weight: 600;
    color: var(--app-navy);
}

.login-field__control {
    position: relative;
    display: flex;
}

.login-field__input {
    width: 100%;
    font: inherit;
    font-size: 14px;
    color: var(--app-navy);
    background: #fff;
    border: 1px solid var(--app-border);
    border-radius: var(--app-radius);
    padding: 10px 12px;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.login-field__control .login-field__input {
    padding-right: 40px;
}

.login-field__input::placeholder {
    color: #9aa9b6;
}

.login-field__input:focus {
    outline: none;
    border-color: var(--app-accent);
    box-shadow: 0 0 0 3px rgba(242, 150, 62, 0.18);
}

.login-field__input:user-invalid {
    border-color: var(--app-danger);
}

.login-field__toggle {
    position: absolute;
    top: 0;
    right: 0;
    height: 100%;
    width: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    color: #9aa9b6;
    cursor: pointer;
    padding: 0;
}

.login-field__toggle:hover {
    color: var(--app-ink);
}

.login-field__toggle:focus-visible {
    outline: 2px solid var(--app-accent);
    outline-offset: 2px;
    border-radius: 4px;
}

.login-submit {
    position: relative;
    margin-top: 4px;
}

.login-submit__spinner {
    display: none;
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-top-color: #fff;
    border-radius: 50%;
}

.login-submit.is-loading .login-submit__spinner {
    display: inline-block;
    animation: login-spin 0.6s linear infinite;
}

.login-submit.is-loading .login-submit__label {
    opacity: 0.85;
}

@keyframes login-spin {
    to {
        transform: rotate(360deg);
    }
}

.login-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin: 20px 0 0;
    font-size: 12px;
    color: var(--app-muted);
    text-align: center;
}

.login-footer__logo {
    height: 22px;
    width: auto;
    object-fit: contain;
    opacity: 0.92;
}

/* Fallback por si la imagen del logo no carga. */
.login-footer__logo--fallback {
    display: none;
}

.login-footer__logo--fallback::after {
    content: "osTicket";
    font-weight: 700;
    color: var(--app-ink);
}
