/*
 * CapEx sign-in page in the WHPC split-screen login layout shared with the Home intranet and the Partner Portal
 * (owner, 2026-11-19: "make the login page style match home and partner"). The layout, colors and brand images are
 * WHPC's own, taken from Home's whpc-brand.css (login section) and Partner's partner.css (form controls). CapEx keeps
 * its own font (Poppins, already on the site): no web font is loaded from outside.
 */
.whpc-login-page {
    --whpc-navy:        #243746;
    --whpc-slate:       #4E738A;
    --whpc-slate-dark:  #3d5d70;
    --whpc-orange:      #FF8300;
    --whpc-orange-dark: #e57500;
    --whpc-ink:         #1f2d38;
    --whpc-muted:       #56656f;
    --whpc-line:        #e3e8ec;
    --whpc-bg:          #f4f6f8;
    --whpc-shadow-md:   0 4px 12px rgba(36,55,70,.08), 0 2px 6px rgba(36,55,70,.06);
    color: var(--whpc-ink);
    background: var(--whpc-bg);
    -webkit-font-smoothing: antialiased;
}

.whpc-login {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    min-height: 100vh;
}

/* --- Left brand panel --- */
.whpc-login__brand {
    position: relative;
    overflow: hidden;
    padding: 56px 64px;
    color: #fff;
    background:
        radial-gradient(1200px 600px at 100% 0%, rgba(255,131,0,.16), transparent 55%),
        linear-gradient(150deg, var(--whpc-navy) 0%, var(--whpc-slate-dark) 100%);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
.whpc-login__keyhole {
    position: absolute;
    right: -120px;
    bottom: -90px;
    width: 460px;
    height: auto;
    opacity: .10;
    pointer-events: none;
    transform: rotate(-8deg);
}
.whpc-login__brand-logo {
    height: 96px;
    width: auto;
    align-self: flex-start;
    position: relative;
    z-index: 1;
}
.whpc-login__brand-copy {
    position: relative;
    z-index: 1;
    max-width: 440px;
}
.whpc-login__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 1.15rem;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--whpc-orange);
    margin-bottom: 20px;
}
.whpc-login__eyebrow i { font-size: 1.3rem; }
.whpc-login__headline {
    font-size: 2.35rem;
    line-height: 1.12;
    font-weight: 700;
    letter-spacing: -.02em;
    margin: 0 0 16px;
    color: #fff;
}
.whpc-login__mission {
    font-size: 1.06rem;
    line-height: 1.6;
    color: rgba(255,255,255,.82);
    margin: 0;
}
.whpc-login__brand-footer {
    position: relative;
    z-index: 1;
    font-size: .85rem;
    color: rgba(255,255,255,.6);
}

/* --- Right sign-in panel --- */
.whpc-login__panel {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 40px;
}
.whpc-login__card {
    width: 100%;
    max-width: 400px;
}
.whpc-login__card-logo {
    height: 56px;
    width: auto;
    margin-bottom: 30px;
    display: none; /* shown only on small screens, where the brand panel hides */
}
.whpc-login__title {
    font-size: 1.6rem;
    font-weight: 700;
    letter-spacing: -.01em;
    margin: 0 0 6px;
    color: var(--whpc-navy);
}
.whpc-login__subtitle {
    font-size: .95rem;
    color: var(--whpc-muted);
    margin: 0 0 26px;
}

/* Sign in with Microsoft (Home's button) */
.whpc-sso-btn {
    width: 100%;
    box-sizing: border-box;
    border: 1px solid var(--whpc-line);
    background: #fff;
    border-radius: 12px;
    padding: 14px 18px;
    font-family: inherit;
    font-size: .98rem;
    font-weight: 600;
    color: var(--whpc-ink);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    text-decoration: none;
    transition: border-color .18s, box-shadow .18s, transform .18s;
}
.whpc-sso-btn:hover, .whpc-sso-btn:focus-visible {
    color: var(--whpc-ink);
    border-color: var(--whpc-slate);
    box-shadow: var(--whpc-shadow-md);
    transform: translateY(-1px);
    outline: none;
}
.whpc-sso-btn__icon { width: 20px; height: 20px; flex-shrink: 0; }
.whpc-login__sso-note {
    margin: 8px 0 0;
    font-size: .84rem;
    color: var(--whpc-muted);
    text-align: center;
}

.whpc-login__divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 22px 0;
    font-size: .78rem;
    font-weight: 600;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--whpc-muted);
}
.whpc-login__divider::before, .whpc-login__divider::after {
    content: "";
    flex: 1;
    border-top: 1px solid var(--whpc-line);
}

/* Email and password (Partner's form controls) */
.whpc-login__form { display: flex; flex-direction: column; gap: 6px; margin: 0; }
.whpc-login__field { margin-bottom: 10px; }
.whpc-login__label {
    display: block;
    margin-bottom: 6px;
    font-size: .9rem;
    font-weight: 600;
    color: var(--whpc-navy);
}
.whpc-login__input {
    width: 100%;
    box-sizing: border-box;
    padding: 12px 14px;
    font: inherit;
    font-size: 1rem;
    color: var(--whpc-ink);
    background: #fff;
    border: 1px solid #cfd8de;
    border-radius: 10px;
    transition: border-color .15s ease, box-shadow .15s ease;
}
.whpc-login__input:focus {
    outline: none;
    border-color: var(--whpc-slate);
    box-shadow: 0 0 0 3px rgba(78,115,138,.18);
}
.whpc-login__password { position: relative; }
.whpc-login__password .whpc-login__input { padding-right: 48px; }
.whpc-login__eye {
    position: absolute;
    top: 50%;
    right: 6px;
    transform: translateY(-50%);
    width: 38px;
    height: 38px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: var(--whpc-muted);
    font-size: 1.15rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}
.whpc-login__eye:hover, .whpc-login__eye:focus-visible { color: var(--whpc-navy); background: #eef2f5; outline: none; }
.whpc-login__form label.error { display: block; margin-top: 6px; font-size: .84rem; font-weight: 500; color: #b3261e; }

.whpc-login__submit {
    width: 100%;
    box-sizing: border-box;
    margin-top: 6px;
    padding: 12px 18px;
    font: inherit;
    font-size: 1rem;
    font-weight: 600;
    color: #fff;
    background: var(--whpc-orange);
    border: 1px solid transparent;
    border-radius: 10px;
    cursor: pointer;
    transition: background .15s ease;
}
.whpc-login__submit:hover, .whpc-login__submit:focus-visible { background: var(--whpc-orange-dark); outline: none; }
.whpc-login__submit[disabled] { opacity: .6; cursor: default; }

.whpc-login__links {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px 16px;
    margin-top: 16px;
    font-size: .9rem;
}
.whpc-login__links a { color: var(--whpc-slate); font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.whpc-login__links a:hover { color: var(--whpc-slate-dark); text-decoration: underline; }

.whpc-login__alert {
    margin: 0 0 20px;
    padding: 12px 14px;
    border-radius: 10px;
    border: 1px solid #f1c4c0;
    background: #fdf1f0;
    color: #8c1d18;
    font-size: .92rem;
}

.whpc-login__help {
    margin-top: 26px;
    padding-top: 22px;
    border-top: 1px solid var(--whpc-line);
    font-size: .86rem;
    color: var(--whpc-muted);
    line-height: 1.5;
}
.whpc-login__help a { color: var(--whpc-slate); font-weight: 600; text-decoration: none; }
.whpc-login__help a:hover { text-decoration: underline; }

/* Phones and narrow windows: the brand panel steps aside and the card shows the logo (as on Home and Partner). */
@media (max-width: 860px) {
    .whpc-login { grid-template-columns: 1fr; }
    .whpc-login__brand { display: none; }
    .whpc-login__card-logo { display: block; }
    .whpc-login__panel { padding: 40px 24px; min-height: 100vh; }
}
@media (prefers-reduced-motion: reduce) {
    .whpc-sso-btn, .whpc-login__input, .whpc-login__submit { transition: none; }
    .whpc-sso-btn:hover { transform: none; }
}
