/* Client portal sign-in and register pages (client/login.tpl, client/register.tpl).
   Neutral page; the company's own logo is the only branding and the main
   button is the only colour. These pages load login/client_root.tpl, not
   client.css, so the portal tokens are repeated here under the same names --
   keep the values in step with client.css. */
:root {
    --lp-portal-green: #4a7a10;
    --lp-portal-green-hover: #3d6a0c;
    --lp-portal-ink: #1a1f1c;
    --lp-portal-muted: #525866;
    --lp-portal-border: #c9d0c8;
    --lp-portal-bg: #f5f7fa;
}

body {
    margin: 0;
    background: var(--lp-portal-bg);
    color: var(--lp-portal-ink);
    font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* client_root.tpl wraps the page in .container-fluid; .lp-login sets its own gutters. */
body > .container-fluid {
    padding: 0;
}

.lp-login {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 56px 16px 32px;
    box-sizing: border-box;
}

.lp-login-card {
    width: 100%;
    max-width: 440px;
    background: #fff;
    border: 1px solid #e1e4e1;
    border-radius: 16px;
    box-shadow: 0 12px 40px rgba(26, 31, 28, 0.06);
    padding: 36px 36px 32px;
    box-sizing: border-box;
}

.lp-login-head {
    text-align: center;
    margin-bottom: 26px;
}

.lp-login-logo {
    display: block;
    max-width: 240px;
    max-height: 96px;
    width: auto;
    height: auto;
    margin: 0 auto 18px;
    object-fit: contain;
}

.lp-login-company {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.01em;
    margin-bottom: 18px;
}

.lp-login-head h1 {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.01em;
    margin: 0 0 6px;
}

.lp-login-head p {
    font-size: 15px;
    line-height: 1.5;
    color: var(--lp-portal-muted);
    margin: 0;
}

.lp-login .form-group {
    margin-bottom: 18px;
}

.lp-login label {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 6px;
}

.lp-login-label-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
}

.lp-login .form-control {
    height: 48px;
    padding: 0 14px;
    font-size: 16px; /* 16px stops iOS zooming into the field */
    color: var(--lp-portal-ink);
    border: 1px solid var(--lp-portal-border);
    border-radius: 10px;
}

.lp-login .form-control:focus {
    border-color: var(--lp-portal-ink);
    box-shadow: 0 0 0 2px rgba(26, 31, 28, 0.15);
}

.lp-login a,
.lp-login-link {
    color: var(--lp-portal-ink);
    font-weight: 600;
    text-decoration: underline;
}

.lp-login a:hover,
.lp-login-link:hover {
    color: #000;
}

.lp-login-password {
    position: relative;
}

.lp-login-password .form-control {
    padding-right: 52px;
}

.lp-login-toggle {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    background: transparent;
    color: var(--lp-portal-muted);
    cursor: pointer;
}

.lp-login-toggle[aria-pressed="true"] {
    color: var(--lp-portal-ink);
}

.lp-login-submit,
.lp-login-submit:focus {
    width: 100%;
    height: 50px;
    margin-top: 6px;
    border: 0;
    border-radius: 10px;
    background: var(--lp-portal-green);
    color: #fff;
    font-size: 16px;
    font-weight: 700;
}

.lp-login-submit:hover,
.lp-login-submit:focus-visible {
    background: var(--lp-portal-green-hover);
    color: #fff;
}

/* The main action as a link (e.g. "Back to sign in"); beats `.lp-login a`. */
.lp-login a.lp-login-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-decoration: none;
}

/* forget.js / reset.js write errors and success into #msg; hide it until they do. */
.lp-login-msg:empty {
    display: none;
}

/* jquery.validate's inline field errors (reset password). */
.lp-login label.error {
    display: block;
    margin: 6px 0 0;
    font-size: 14px;
    font-weight: 500;
    color: #b42318;
}

.lp-login-hint {
    font-size: 14px;
    line-height: 1.5;
    color: var(--lp-portal-muted);
    margin: 0 0 18px;
}

.lp-login-error {
    font-size: 15px;
    border-radius: 10px;
    margin-bottom: 18px;
}

.lp-login-switch {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 6px;
    margin-top: 22px;
    padding-top: 14px;
    border-top: 1px solid #eceeec;
    font-size: 15px;
    color: var(--lp-portal-muted);
}

.lp-login-switch a {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
}

.lp-login-footer {
    margin: 24px 0 0;
    font-size: 13px;
    color: #5f665f;
}

@media (max-width: 480px) {
    .lp-login {
        padding: 32px 0 24px;
        background: #fff;
    }

    .lp-login-card {
        border: 0;
        box-shadow: none;
        padding: 16px 24px 24px;
    }
}
