/* ============================================================
   login.css  –  sign-in pages (Login, Forgot password, Change password)
   A brand panel (the sidebar's colours) beside the form: 60 / 40 on desktop, a band above the form on
   smaller screens. Colours come only from the theme tokens in portal.css.
   ============================================================ */

.lg-body-page {
    margin: 0;
    min-height: 100vh;
    background: var(--ts-card);
    font-family: "Poppins", "Segoe UI", system-ui, sans-serif;
    color: var(--ts-text-dark);
}

/* ---------- Split ---------- */

.lg-page.lg-split {
    display: grid;
    grid-template-columns: minmax(0, 60fr) minmax(0, 40fr);
    min-height: 100vh;
}

/* ---------- Brand panel ---------- */

.lg-brand {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 32px;
    padding: 56px 64px;
    padding-top: calc(56px + env(safe-area-inset-top, 0px));
    box-sizing: border-box;
    background: var(--ts-auth-bg);
    color: var(--ts-auth-fg);
}

.lg-art {
    position: absolute;
    right: -40px;
    bottom: -120px;
    width: 560px;
    max-width: 90%;
    height: auto;
    pointer-events: none;
}

.lg-art-standard { stroke: var(--ts-auth-art-tube); stroke-width: 3; }
.lg-art-ledger   { stroke: var(--ts-auth-art-tube); stroke-width: 2; }
.lg-art-brace    { stroke: var(--ts-auth-art-brace); stroke-width: 2; }

/* The wordmark with "an Aayura Global company" under it, as in the portal's sidebar. */
.lg-brand-name {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
}

.lg-wordmark-tagline {
    font-size: 13px;
    font-weight: 500;
    line-height: 1.3;
    color: var(--ts-wordmark-tagline);
}

.lg-wordmark {
    position: relative;
    align-self: flex-start;
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -.3px;
    color: var(--ts-wordmark);
    text-decoration: none;
}

    .lg-wordmark:hover {
        color: var(--ts-wordmark);
        text-decoration: none;
    }

.lg-wordmark-accent {
    color: var(--ts-wordmark-accent);
}

.lg-brand-copy {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 22px;
    max-width: 520px;
}

.lg-brand-title {
    margin: 0;
    font-size: 36px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -.5px;
    color: var(--ts-auth-fg);
    text-wrap: balance;
}

.lg-points {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin: 0;
    padding: 0;
    list-style: none;
}

    .lg-points li {
        display: flex;
        align-items: center;
        gap: 12px;
        font-size: 15px;
        color: var(--ts-auth-fg-soft);
    }

.lg-point-icon {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: var(--ts-auth-point-bg);
    color: var(--ts-auth-point-fg);
}

.lg-brand-foot {
    position: relative;
    margin: 0;
    font-size: 12px;
    color: var(--ts-auth-fg-muted);
}

/* ---------- Form side ---------- */

.lg-main {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px;
    box-sizing: border-box;
    background: var(--ts-card);
}

.lg-card {
    width: 100%;
    max-width: 400px;
    border: 0;
    border-radius: 0;
    background: none;
    box-shadow: none;
    overflow: visible;
}

.lg-header {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 0 0 22px;
    background: none;
}

.lg-header-title {
    margin: 0;
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -.4px;
    line-height: 1.25;
    color: var(--ts-text-dark);
}

.lg-header-sub {
    margin: 0;
    font-size: 14px;
    line-height: 1.5;
    color: var(--ts-muted);
}

.lg-body {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 0;
}

/* ---------- Alerts ---------- */

.lg-alert {
    margin: 0;
    padding: 12px 14px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.45;
}

.lg-alert-warning {
    background: var(--ts-alert-warn-bg);
    border: 1px solid var(--ts-alert-warn-border);
    color: var(--ts-alert-warn-text);
}

.lg-alert-danger {
    background: var(--ts-danger-bg);
    border: 1px solid var(--ts-danger-border);
    color: var(--ts-danger);
}

.lg-alert-success {
    background: var(--ts-alert-success-bg);
    border: 1px solid var(--ts-alert-success-border);
    color: var(--ts-alert-success-text);
}

/* ---------- Fields ---------- */

.lg-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin: 0;
}

    .lg-field label {
        margin: 0;
        font-size: 13px;
        font-weight: 600;
        letter-spacing: 0;
        text-transform: none;
        color: var(--ts-text-dark);
    }

.lg-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.lg-input-icon {
    position: absolute;
    left: 14px;
    z-index: 1;
    font-size: 15px;
    color: var(--ts-muted);
    pointer-events: none;
}

.lg-input-wrap input {
    width: 100%;
    height: 46px;
    padding: 0 14px 0 42px;
    box-sizing: border-box;
    border: 1px solid var(--ts-border);
    border-radius: 10px;
    background: var(--ts-card);
    font-size: 14.5px;
    color: var(--ts-text-dark);
    outline: none;
    transition: border-color .15s, box-shadow .15s;
}

    .lg-input-wrap input:focus {
        border-color: var(--ts-accent-dark);
        box-shadow: 0 0 0 3px var(--ts-focus-halo);
    }

    .lg-input-wrap input::placeholder {
        color: var(--ts-muted);
        opacity: 1;
    }

.lg-input-wrap input[type="password"],
.lg-input-wrap #Password {
    padding-right: 46px;
}

.lg-show-password {
    position: absolute;
    right: 5px;
    min-width: 36px;
    min-height: 36px;
    border: 0;
    border-radius: 8px;
    background: none;
    color: var(--ts-muted);
    cursor: pointer;
}

    .lg-show-password:hover {
        color: var(--ts-text-dark);
    }

.lg-validation {
    display: block;
    font-size: 12.5px;
    color: var(--ts-danger);
}

/* ---------- Submit and links ---------- */

.lg-submit-wrap {
    margin-top: 4px;
}

.lg-btn {
    display: block;
    width: 100%;
    height: 48px;
    border: 0;
    border-radius: 10px;
    background: var(--ts-accent);
    color: var(--ts-on-accent);
    font: inherit;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: background .15s, box-shadow .15s;
}

    .lg-btn:hover {
        background: var(--ts-accent-hover);
        box-shadow: var(--ts-accent-shadow-hover);
    }

    .lg-btn:active {
        background: var(--ts-accent-dark);
        box-shadow: none;
    }

    .lg-btn:disabled {
        background: var(--ts-btn-disabled-bg);
        color: var(--ts-btn-disabled-fg);
        box-shadow: none;
        cursor: not-allowed;
    }

    /* A link styled as the main button (reset password page: "Sign in", "Request a new link"). */
    a.lg-btn {
        line-height: 48px;
        text-align: center;
        text-decoration: none;
    }

        a.lg-btn:hover {
            color: var(--ts-on-accent);
        }

    .lg-footer a:focus-visible,
    .lg-wordmark:focus-visible {
        outline: 3px solid var(--ts-focus-ring);
        outline-offset: 2px;
    }

    /* The main button: the same gap-and-ring as the portal's primary button. */
    .lg-btn:focus-visible {
        outline: none !important;
        box-shadow: 0 0 0 3px var(--ts-focus-gap), 0 0 0 5px var(--ts-btn-focus-ring);
    }

    /* The wordmark sits on the brand panel, which follows the sidebar. */
    .lg-wordmark:focus-visible {
        outline-color: var(--ts-nav-focus-ring) !important;
    }

.lg-footer {
    padding: 18px 0 0;
    text-align: center;
}

    .lg-footer a {
        font-size: 13px;
        font-weight: 600;
        color: var(--ts-primary);
        text-decoration: none;
    }

        .lg-footer a:hover {
            color: var(--ts-text-dark);
            text-decoration: underline;
        }

/* ---------- Tablets and phones: the brand panel as a band above the form ---------- */

@media (max-width: 991.98px) {
    .lg-page.lg-split {
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: auto 1fr;
    }

    .lg-brand {
        gap: 10px;
        padding: 28px 20px 24px;
        padding-top: calc(28px + env(safe-area-inset-top, 0px));
    }

    .lg-art {
        width: 260px;
        right: -30px;
        bottom: -40px;
    }

    .lg-wordmark {
        font-size: 20px;
    }

    .lg-brand-name {
        gap: 2px;
    }

    .lg-wordmark-tagline {
        font-size: 12px;
    }

    .lg-brand-title {
        font-size: 14px;
        font-weight: 400;
        letter-spacing: 0;
        color: var(--ts-auth-fg-soft);
    }

    .lg-points,
    .lg-brand-foot {
        display: none;
    }

    .lg-main {
        align-items: flex-start;
        padding: 28px 20px 40px;
    }

    .lg-card {
        max-width: 440px;
    }

    .lg-header-title {
        font-size: 24px;
    }
}
