/* Custom Utility - Login Manager: modern staff login page. Applies only once login_page.js adds body.cu-lp. */

:root { --cu-lp-accent: #2563eb; }

/* ---------- always (also without the new layout): password button, welcome-back card ---------- */
.cu-lp-pw { position: relative; display: block; }
.cu-lp-pw > input { padding-right: 46px !important; }
.cu-lp-pw-btn {
    position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
    width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center;
    border: 0; border-radius: 8px; background: transparent; color: #64748b; cursor: pointer; padding: 0;
}
.cu-lp-pw-btn:hover { background: #f1f5f9; color: #0f172a; }
.cu-lp-pw-btn:focus-visible { outline: 2px solid var(--cu-lp-accent); outline-offset: 1px; }

.cu-lp-staff {
    display: flex; align-items: center; gap: 12px; text-align: left;
    margin: 14px 0 20px; padding: 10px 14px;
    background: #f8fafc; border: 1px solid #e8edf3; border-radius: 14px;
}
.cu-lp-avatar {
    flex: 0 0 48px; width: 48px; height: 48px; border-radius: 50%; overflow: hidden;
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-weight: 700; font-size: 17px; letter-spacing: .02em;
    box-shadow: 0 0 0 3px #fff, 0 0 0 5px var(--cu-lp-accent);
}
.cu-lp-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cu-lp-staff-text { min-width: 0; }
.cu-lp-staff-hi { font-weight: 600; color: #0f172a; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cu-lp-notyou { font-size: 12.5px; color: var(--cu-lp-accent) !important; }

.cu-lp-preview-bar {
    position: fixed; z-index: 50; left: 50%; top: 10px; transform: translateX(-50%);
    background: #0f172a; color: #fff; font-size: 12px; padding: 5px 14px; border-radius: 999px; letter-spacing: .03em;
}

/* ---------- the new layout ---------- */
body.cu-lp {
    margin: 0 !important; padding: 0 !important; min-height: 100vh; min-height: 100dvh;
    background: #f6f8fb !important;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-family: var(--cu-lp-font, Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif);
    color: #0f172a;
}
body.cu-lp > .container:empty, body.cu-lp > .container > .row:empty { display: none; }

.cu-lp-shell { position: relative; min-height: 100vh; min-height: 100dvh; display: grid; grid-template-columns: 1fr; overflow: hidden; }
.cu-lp-main { position: relative; z-index: 2; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 48px 20px; }

/* the original wrapper becomes the card */
body.cu-lp .cu-lp-card {
    position: relative; width: 100% !important; max-width: 430px !important;
    margin: 0 !important; padding: 40px 36px 30px !important; float: none !important; left: auto !important;
    background: #fff; border: 1px solid #e8edf3; border-radius: 20px; border-radius: var(--cu-lp-radius, 20px);
    box-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 24px 48px -24px rgba(15, 23, 42, .25);
}
/* Perfex's own inner box (3.x .tw-bg-white, 2.x .authentication-form) melts into the card */
body.cu-lp .cu-lp-card > .tw-bg-white,
body.cu-lp .cu-lp-card .authentication-form {
    background: transparent !important; box-shadow: none !important; border: 0 !important;
    padding: 0 !important; margin: 0 !important;
}
body.cu-lp .cu-lp-card .company-logo { text-align: center; margin: 0 0 18px !important; padding: 0 !important; background: none !important; }
body.cu-lp .cu-lp-card .company-logo img { max-height: 56px; max-width: 210px; width: auto; height: auto; display: inline-block; }
body.cu-lp .cu-lp-card h1 {
    /* no !important: already stronger than Perfex's classes, and Custom CSS must be able to override it */
    font-size: 22px; font-size: var(--cu-lp-title, 22px); line-height: 1.3; font-weight: 700; color: #0f172a;
    text-align: center; margin: 0 0 6px; letter-spacing: -.01em;
}
body.cu-lp .cu-lp-card .control-label,
body.cu-lp .cu-lp-card label { font-size: 13px; font-size: calc(var(--cu-lp-fs, 15px) - 2px); font-weight: 600; color: #334155; }
body.cu-lp .cu-lp-card { font-size: var(--cu-lp-fs, 15px); }
body.cu-lp .cu-lp-card .checkbox label { font-weight: 500; color: #475569; }
body.cu-lp .cu-lp-card .checkbox { display: block; margin: 2px 0 20px; }
body.cu-lp .cu-lp-card .form-group { margin-bottom: 16px; }
body.cu-lp .cu-lp-card, body.cu-lp .cu-lp-card .form-control, body.cu-lp .cu-lp-card .btn { font-family: inherit; }
body.cu-lp .cu-lp-card .form-control {
    height: 46px; height: calc(var(--cu-lp-fs, 15px) * 3.07); border-radius: 10px !important; border: 1px solid #d7dee8 !important;
    box-shadow: none !important; font-size: 15px; font-size: var(--cu-lp-fs, 15px); padding: 10px 14px; background: #fff; transition: border-color .15s, box-shadow .15s;
}
body.cu-lp .cu-lp-card .form-control:focus {
    border-color: var(--cu-lp-accent) !important;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, .14) !important;
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--cu-lp-accent) 18%, transparent) !important;
}
body.cu-lp .cu-lp-card .btn-primary {
    height: 48px; height: calc(var(--cu-lp-fs, 15px) * 3.2); border-radius: 10px !important; border: 0 !important; font-weight: 600;
    font-size: 15px; font-size: var(--cu-lp-fs, 15px); letter-spacing: .01em;
    background: var(--cu-lp-accent) !important; color: #fff !important;
    box-shadow: 0 8px 18px -8px var(--cu-lp-accent);
    transition: filter .15s, transform .05s;
}
body.cu-lp .cu-lp-card .btn-primary:hover { filter: brightness(1.08); }
body.cu-lp .cu-lp-card .btn-primary:active { transform: translateY(1px); }
body.cu-lp .cu-lp-card a:not(.btn) { color: #64748b; }
body.cu-lp .cu-lp-card a:not(.btn):hover { color: var(--cu-lp-accent); }
body.cu-lp .cu-lp-card .alert { border-radius: 10px; }
.cu-lp-under { position: relative; z-index: 2; max-width: 430px; text-align: center; color: #64748b; margin: 18px 0 0; font-size: 13.5px; font-size: calc(var(--cu-lp-fs, 15px) - 1.5px); }

/* decorative orbs */
.cu-lp-orb { position: absolute; border-radius: 50%; pointer-events: none; filter: blur(2px); }

/* ---------- Split: brand panel + form ---------- */
body.cu-lp--split .cu-lp-shell { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); }
.cu-lp-brand {
    position: relative; overflow: hidden; color: #fff; padding: 56px 60px;
    display: flex; flex-direction: column; justify-content: space-between;
    background: var(--cu-lp-accent);
    background: linear-gradient(145deg, var(--cu-lp-accent) 0%, color-mix(in srgb, var(--cu-lp-accent) 55%, #0f172a) 100%);
}
.cu-lp-brand-inner { position: relative; z-index: 2; margin: auto 0; max-width: 520px; }
.cu-lp-brand-company {
    display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
    padding: 6px 12px; border-radius: 999px; background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .22); margin-bottom: 26px;
}
.cu-lp-brand-headline { font-size: clamp(30px, 3.4vw, 46px); font-size: clamp(calc(var(--cu-lp-headline, 46px) * .65), 3.4vw, var(--cu-lp-headline, 46px)); line-height: 1.12; font-weight: 700; letter-spacing: -.025em; margin: 0 0 16px; color: #fff; }
.cu-lp-brand-tagline { font-size: 17px; line-height: 1.6; opacity: .85; margin: 0; max-width: 440px; }
.cu-lp-brand-foot { position: relative; z-index: 2; font-size: 12.5px; opacity: .7; }
.cu-lp--split .cu-lp-orb-1, .cu-lp--splitleft .cu-lp-orb-1, .cu-lp--panel .cu-lp-orb-1, .cu-lp--custom .cu-lp-brand .cu-lp-orb-1 { width: 420px; height: 420px; right: -140px; top: -120px; background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, .28), rgba(255, 255, 255, 0) 70%); }
.cu-lp--split .cu-lp-orb-2, .cu-lp--splitleft .cu-lp-orb-2, .cu-lp--panel .cu-lp-orb-2, .cu-lp--custom .cu-lp-brand .cu-lp-orb-2 { width: 300px; height: 300px; left: -90px; bottom: -80px; background: radial-gradient(circle, rgba(255, 255, 255, .18), rgba(255, 255, 255, 0) 70%); }
.cu-lp--split .cu-lp-orb-3, .cu-lp--splitleft .cu-lp-orb-3, .cu-lp--panel .cu-lp-orb-3, .cu-lp--custom .cu-lp-brand .cu-lp-orb-3 { width: 140px; height: 140px; right: 18%; bottom: 16%; border: 1px solid rgba(255, 255, 255, .25); filter: none; }

/* ---------- Split left: the same as Split, mirrored - login card on the left, brand / picture on the right ---------- */
body.cu-lp--splitleft .cu-lp-shell { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); }
body.cu-lp--splitleft .cu-lp-main { order: 1; }
body.cu-lp--splitleft .cu-lp-brand { order: 2; }

/* ---------- Panel: wide brand / picture on the left, a full-height login panel on the right ---------- */
body.cu-lp--panel { background: #fff !important; }
body.cu-lp--panel .cu-lp-shell { grid-template-columns: minmax(0, 1.55fr) minmax(360px, 1fr); }
body.cu-lp--panel .cu-lp-main { background: #fff; padding: 48px clamp(28px, 5vw, 72px); box-shadow: -24px 0 60px -36px rgba(15, 23, 42, .35); }
body.cu-lp--panel .cu-lp-card {
    max-width: 380px !important; padding: 0 !important; background: transparent !important;
    border: 0 !important; border-radius: 0 !important; box-shadow: none !important;
}
body.cu-lp--panel .cu-lp-card .company-logo { text-align: left; margin-bottom: 26px !important; }
body.cu-lp--panel .cu-lp-card h1 { text-align: left; font-size: 26px; font-size: calc(var(--cu-lp-title, 22px) + 4px); margin-bottom: 22px; }
body.cu-lp--panel .cu-lp-under { text-align: left; max-width: 380px; width: 100%; }
body.cu-lp--panel .cu-lp-brand { padding: 64px 72px; }

/* ---------- Centered: soft tinted background ---------- */
body.cu-lp--centered { background: #f3f6fb !important; }
body.cu-lp--centered .cu-lp-card { overflow: hidden; }
body.cu-lp--centered .cu-lp-card::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 5px; background: var(--cu-lp-accent); }
.cu-lp--centered .cu-lp-orb-1 { width: 620px; height: 620px; left: -220px; top: -260px; background: radial-gradient(circle, rgba(37, 99, 235, .16), transparent 65%); background: radial-gradient(circle, color-mix(in srgb, var(--cu-lp-accent) 20%, transparent), transparent 65%); }
.cu-lp--centered .cu-lp-orb-2 { width: 520px; height: 520px; right: -180px; bottom: -220px; background: radial-gradient(circle, rgba(124, 58, 237, .12), transparent 65%); }
.cu-lp--centered .cu-lp-orb-3 { display: none; }

/* ---------- Glass: frosted card over a deep gradient ---------- */
body.cu-lp--glass { background: #0f172a !important; }
body.cu-lp--glass .cu-lp-shell {
    background: #0f172a;
    background: linear-gradient(135deg, color-mix(in srgb, var(--cu-lp-accent) 70%, #0f172a) 0%, #0f172a 75%);
}
body.cu-lp--glass .cu-lp-card {
    background: rgba(255, 255, 255, .78) !important; border: 1px solid rgba(255, 255, 255, .55);
    -webkit-backdrop-filter: blur(22px) saturate(160%); backdrop-filter: blur(22px) saturate(160%);
    box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .55);
}
body.cu-lp--glass .cu-lp-under { color: rgba(255, 255, 255, .7); }
.cu-lp--glass .cu-lp-orb-1 { width: 460px; height: 460px; left: 8%; top: 6%; background: radial-gradient(circle, var(--cu-lp-accent), transparent 68%); opacity: .75; filter: blur(30px); }
.cu-lp--glass .cu-lp-orb-2 { width: 380px; height: 380px; right: 6%; bottom: 4%; background: radial-gradient(circle, #a855f7, transparent 68%); opacity: .5; filter: blur(30px); }
.cu-lp--glass .cu-lp-orb-3 { width: 240px; height: 240px; right: 26%; top: 10%; background: radial-gradient(circle, #22d3ee, transparent 68%); opacity: .35; filter: blur(30px); }


/* ---------- Colour schemes (Login Page > Colour scheme): over any layout; the accent comes from the accent field ---------- */
body.cu-lp-scheme-black_friday {
    --cs-page: #ececec; --cs-brand-ink: #0b0b0b; --cs-under: #6b6b6b; --cs-orb2: #e5231b; --cs-orb3: #ffffff;
    --cs-brand: radial-gradient(ellipse 60% 55% at 62% 48%, rgba(255, 255, 255, .55), rgba(255, 255, 255, 0) 70%), linear-gradient(90deg, #9c9c9c 0%, #c4c4c4 38%, #dedede 72%, #ececec 100%);
    --cs-glass: linear-gradient(135deg, #8e8e8e 0%, #2b2b2b 75%);
}
body.cu-lp-scheme-ocean    { --cs-page: #f0f9ff; --cs-brand: linear-gradient(145deg, #0369a1, #0c4a6e); --cs-glass: linear-gradient(135deg, #0369a1 0%, #082f49 75%); --cs-orb2: #06b6d4; --cs-orb3: #38bdf8; }
body.cu-lp-scheme-emerald  { --cs-page: #ecfdf5; --cs-brand: linear-gradient(145deg, #059669, #064e3b); --cs-glass: linear-gradient(135deg, #047857 0%, #022c22 75%); --cs-orb2: #14b8a6; --cs-orb3: #a3e635; }
body.cu-lp-scheme-royal    { --cs-page: #f5f3ff; --cs-brand: linear-gradient(145deg, #7c3aed, #3b0764); --cs-glass: linear-gradient(135deg, #6d28d9 0%, #1e1b4b 75%); --cs-orb2: #ec4899; --cs-orb3: #818cf8; }
body.cu-lp-scheme-sunset   { --cs-page: #fff7ed; --cs-brand: linear-gradient(145deg, #f97316, #be123c); --cs-glass: linear-gradient(135deg, #c2410c 0%, #4c0519 75%); --cs-orb2: #f43f5e; --cs-orb3: #fbbf24; }
body.cu-lp-scheme-midnight { --cs-page: #0b1020; --cs-brand: linear-gradient(145deg, #1e1b4b, #0b1020); --cs-glass: linear-gradient(135deg, #312e81 0%, #020617 75%); --cs-orb2: #a855f7; --cs-orb3: #22d3ee; --cs-under: rgba(255, 255, 255, .65); }
body.cu-lp-scheme-navy_red { --cs-page: #f6f8fb; --cs-brand: linear-gradient(160deg, #113a50 0%, #102e43 50%, #10263a 100%); --cs-glass: linear-gradient(135deg, #163f57 0%, #0b1d2c 75%); --cs-orb2: #ff3b3b; --cs-orb3: #4f7a95; }
body.cu-lp-scheme-graphite { --cs-page: #f4f4f5; --cs-brand: linear-gradient(145deg, #3f3f46, #09090b); --cs-glass: linear-gradient(135deg, #3f3f46 0%, #09090b 75%); --cs-orb2: #71717a; --cs-orb3: #d4d4d8; }

body.cu-lp.cu-lp-schemed:not(.cu-lp--custom):not(.cu-lp--glass):not(.cu-lp-plain-bg) { background: var(--cs-page) !important; }
body.cu-lp.cu-lp-schemed:not(.cu-lp-has-bg) .cu-lp-brand { background: var(--cs-brand); color: var(--cs-brand-ink, #fff); }
body.cu-lp.cu-lp-schemed .cu-lp-brand-headline { color: var(--cs-brand-ink, #fff); }
body.cu-lp.cu-lp-schemed.cu-lp--glass:not(.cu-lp-has-bg) .cu-lp-shell { background: var(--cs-glass); }
body.cu-lp.cu-lp-schemed:not(.cu-lp--glass) .cu-lp-under { color: var(--cs-under, #64748b); }
body.cu-lp.cu-lp-schemed.cu-lp--glass .cu-lp-orb-2,
body.cu-lp.cu-lp-schemed.cu-lp--centered .cu-lp-orb-2 { background: radial-gradient(circle, var(--cs-orb2), transparent 68%); }
body.cu-lp.cu-lp-schemed.cu-lp--centered .cu-lp-orb-2 { opacity: .22; }
body.cu-lp.cu-lp-schemed.cu-lp--glass .cu-lp-orb-3 { background: radial-gradient(circle, var(--cs-orb3), transparent 68%); }

/* Navy & Red: deep navy panel, red company badge, soft grey card */
body.cu-lp-scheme-navy_red:not(.cu-lp-has-bg) .cu-lp-brand-company { background: var(--cu-lp-accent); border-color: var(--cu-lp-accent); color: #fff; }
body.cu-lp.cu-lp-scheme-navy_red:not(.cu-lp--panel):not(.cu-lp--glass):not(.cu-lp-cl-card-flat):not(.cu-lp-cl-card-glass) .cu-lp-card {
    background: #e0e5ec; border-color: #d4dae3; box-shadow: 0 2px 4px rgba(15, 23, 42, .06), 0 18px 40px -12px rgba(15, 23, 42, .35);
}
body.cu-lp.cu-lp-scheme-navy_red .cu-lp-card .btn-primary { box-shadow: 0 8px 18px -8px color-mix(in srgb, var(--cu-lp-accent) 70%, transparent); }

/* Black Friday: the banner's look - dark text on the grey panel, red capitals, an upper-case button with an arrow, confetti */
body.cu-lp-scheme-black_friday .cu-lp-brand-headline { font-weight: 800; }
body.cu-lp-scheme-black_friday .cu-lp-brand-tagline { color: #333; opacity: 1; }
body.cu-lp-scheme-black_friday:not(.cu-lp-has-bg) .cu-lp-brand-company {
    background: none; border: 0; padding: 0; color: var(--cu-lp-accent); text-transform: uppercase; letter-spacing: .06em; font-weight: 700;
}
body.cu-lp-scheme-black_friday:not(.cu-lp-has-bg) .cu-lp-brand .cu-lp-orb { display: none; }
body.cu-lp-scheme-black_friday .cu-lp-card .btn-primary,
body.cu-lp-scheme-black_friday .cu-lp-expired .btn-primary { position: relative; text-transform: uppercase; font-weight: 700; padding-right: 44px; }
body.cu-lp-scheme-black_friday .cu-lp-card .btn-primary::after,
body.cu-lp-scheme-black_friday .cu-lp-expired .btn-primary::after {
    content: ""; position: absolute; right: 20px; top: 50%; width: 9px; height: 9px; margin-top: -5px;
    border-right: 2.5px solid currentColor; border-top: 2.5px solid currentColor; transform: rotate(45deg);
}
body.cu-lp-scheme-black_friday .cu-lp-shell { position: relative; }
body.cu-lp-scheme-black_friday .cu-lp-shell::before {   /* confetti down the left edge: one 11x6 piece, repeated by its shadows */
    content: ""; position: absolute; z-index: 1; left: 0; top: 0; width: 11px; height: 6px; pointer-events: none; transform: rotate(-30deg);
    box-shadow: 30px 190px 0 #e5231b, 14px 300px 0 #7a1712, 60px 420px 0 rgba(140, 140, 140, .8), 22px 520px 0 #e5231b,
        84px 610px 0 #7a1712, 36px 720px 0 #e5231b, 120px 110px 0 rgba(150, 150, 150, .8), 8px 860px 0 #e5231b;
}

/* ---------- Custom: built from Login Page > Custom layout (form position, brand panel, card look, background) ---------- */
body.cu-lp--custom { background: var(--cu-lp-bg1, #eef2ff) !important; }
body.cu-lp--custom .cu-lp-shell { background: linear-gradient(145deg, var(--cu-lp-bg1, #eef2ff), var(--cu-lp-bg2, #f8fafc)); }
body.cu-lp--custom .cu-lp-shell > .cu-lp-orb { display: none; }
body.cu-lp--custom.cu-lp-cl-panel-left .cu-lp-shell { grid-template-columns: var(--cu-lp-panel-w, 50%) minmax(0, 1fr); }
body.cu-lp--custom.cu-lp-cl-panel-right .cu-lp-shell { grid-template-columns: minmax(0, 1fr) var(--cu-lp-panel-w, 50%); }
body.cu-lp--custom.cu-lp-cl-panel-right .cu-lp-main { order: 1; }
body.cu-lp--custom.cu-lp-cl-panel-right .cu-lp-brand { order: 2; }
body.cu-lp--custom .cu-lp-brand { color: var(--cu-lp-panel-text, #fff); }
body.cu-lp--custom .cu-lp-brand-headline { color: inherit; }
/* where the form sits in its area */
body.cu-lp--custom.cu-lp-cl-pos-left .cu-lp-main { align-items: flex-start; padding-left: clamp(24px, 6vw, 96px); }
body.cu-lp--custom.cu-lp-cl-pos-right .cu-lp-main { align-items: flex-end; padding-right: clamp(24px, 6vw, 96px); }
body.cu-lp--custom.cu-lp-cl-pos-left .cu-lp-under { text-align: left; }
body.cu-lp--custom.cu-lp-cl-pos-right .cu-lp-under { text-align: right; }
body.cu-lp--custom .cu-lp-card, body.cu-lp--custom .cu-lp-under { max-width: var(--cu-lp-card-w, 430px) !important; width: 100%; }
/* card look */
body.cu-lp--custom.cu-lp-cl-card-flat .cu-lp-card { background: transparent !important; border: 0 !important; box-shadow: none !important; padding: 8px 0 !important; }
body.cu-lp--custom.cu-lp-cl-card-glass .cu-lp-card {
    background: rgba(255, 255, 255, .72) !important; border: 1px solid rgba(255, 255, 255, .6);
    -webkit-backdrop-filter: blur(20px) saturate(160%); backdrop-filter: blur(20px) saturate(160%);
    box-shadow: 0 24px 60px -20px rgba(15, 23, 42, .4);
}
/* background picture: in the panel when there is one, otherwise over the whole page */
body.cu-lp--custom.cu-lp-has-bg .cu-lp-brand {
    background: linear-gradient(145deg, color-mix(in srgb, var(--cu-lp-accent) var(--cu-lp-ov, 45%), transparent), rgba(15, 23, 42, var(--cu-lp-ov-a, .45))), var(--cu-lp-bg) center / cover no-repeat;
}
body.cu-lp--custom.cu-lp-cl-panel-none.cu-lp-has-bg .cu-lp-shell {
    background: linear-gradient(rgba(15, 23, 42, var(--cu-lp-ov-a, .45)), rgba(15, 23, 42, var(--cu-lp-ov-a, .45))), var(--cu-lp-bg) center / cover no-repeat;
}
body.cu-lp--custom.cu-lp-has-bg .cu-lp-brand .cu-lp-orb-3 { display: block; }

/* ---------- background picture (Login Manager > Login Page) ---------- */
/* Split: the picture fills the brand panel, under the accent colour at the chosen strength. */
body.cu-lp--split.cu-lp-has-bg .cu-lp-brand,
body.cu-lp--splitleft.cu-lp-has-bg .cu-lp-brand,
body.cu-lp--panel.cu-lp-has-bg .cu-lp-brand {
    background: linear-gradient(145deg, rgba(15, 23, 42, var(--cu-lp-ov-a, .45)), rgba(15, 23, 42, var(--cu-lp-ov-a, .45))), var(--cu-lp-bg) center / cover no-repeat;
    background: linear-gradient(145deg, color-mix(in srgb, var(--cu-lp-accent) var(--cu-lp-ov, 45%), transparent), rgba(15, 23, 42, var(--cu-lp-ov-a, .45))), var(--cu-lp-bg) center / cover no-repeat;
}
/* Centered / Glass: the picture fills the whole page. */
body.cu-lp--centered.cu-lp-has-bg .cu-lp-shell,
body.cu-lp--glass.cu-lp-has-bg .cu-lp-shell {
    background: linear-gradient(rgba(15, 23, 42, var(--cu-lp-ov-a, .45)), rgba(15, 23, 42, var(--cu-lp-ov-a, .45))), var(--cu-lp-bg) center / cover no-repeat;
}
body.cu-lp-has-bg .cu-lp-orb { display: none; }
body.cu-lp--split.cu-lp-has-bg .cu-lp-orb-3,
body.cu-lp--splitleft.cu-lp-has-bg .cu-lp-orb-3,
body.cu-lp--panel.cu-lp-has-bg .cu-lp-orb-3 { display: block; }
body.cu-lp--centered.cu-lp-has-bg .cu-lp-under { color: rgba(255, 255, 255, .85); }
/* Modern layout switched off: the picture behind Perfex's own page. */
body.cu-lp-plain-bg {
    background: linear-gradient(rgba(15, 23, 42, var(--cu-lp-ov-a, .45)), rgba(15, 23, 42, var(--cu-lp-ov-a, .45))), var(--cu-lp-bg) center / cover no-repeat fixed !important;
    min-height: 100vh;
}

/* ---------- phones / small screens ---------- */
@media (max-width: 900px) {
    body.cu-lp--split .cu-lp-shell, body.cu-lp--splitleft .cu-lp-shell, body.cu-lp--panel .cu-lp-shell,
    body.cu-lp--custom.cu-lp-cl-panel-left .cu-lp-shell, body.cu-lp--custom.cu-lp-cl-panel-right .cu-lp-shell { grid-template-columns: 1fr; }
    body.cu-lp--custom.cu-lp-cl-panel-right .cu-lp-brand, body.cu-lp--custom.cu-lp-cl-panel-right .cu-lp-main { order: 0; }
    body.cu-lp--custom .cu-lp-main { align-items: center !important; padding-left: 16px !important; padding-right: 16px !important; }
    body.cu-lp--custom .cu-lp-under { text-align: center !important; }
    body.cu-lp--splitleft .cu-lp-brand, body.cu-lp--splitleft .cu-lp-main { order: 0; }
    .cu-lp-brand, body.cu-lp--panel .cu-lp-brand { padding: 26px 22px 30px; }
    body.cu-lp--panel .cu-lp-main { box-shadow: none; padding: 28px 22px 40px; }
    body.cu-lp--panel .cu-lp-card .company-logo, body.cu-lp--panel .cu-lp-card h1 { text-align: center; }
    .cu-lp-brand-company { margin-bottom: 14px; }
    .cu-lp-brand-headline { font-size: 26px; font-size: calc(var(--cu-lp-headline, 46px) * .57); margin-bottom: 6px; }
    .cu-lp-brand-tagline { font-size: 14.5px; }
    .cu-lp-brand-foot { display: none; }
    .cu-lp-main { padding: 28px 16px 40px; justify-content: flex-start; }
}
/* tablets in portrait (and wide phones): the brand band on top, the form centred in the rest of the screen */
@media (min-width: 601px) and (max-width: 900px) {
    body.cu-lp--split .cu-lp-shell, body.cu-lp--splitleft .cu-lp-shell, body.cu-lp--panel .cu-lp-shell,
    body.cu-lp--custom.cu-lp-cl-panel-left .cu-lp-shell, body.cu-lp--custom.cu-lp-cl-panel-right .cu-lp-shell { grid-template-rows: auto 1fr; }
    .cu-lp-main { justify-content: center; padding: 40px 32px 56px; }
    .cu-lp-brand, body.cu-lp--panel .cu-lp-brand { padding: 40px 44px 44px; }
    .cu-lp-brand-headline { font-size: 32px; font-size: calc(var(--cu-lp-headline, 46px) * .7); }
    body.cu-lp .cu-lp-card { max-width: 460px !important; }
}
/* small laptops: a little less padding in the brand panel */
@media (min-width: 901px) and (max-width: 1180px) {
    .cu-lp-brand { padding: 44px 40px; }
    body.cu-lp--panel .cu-lp-brand { padding: 48px 48px; }
    body.cu-lp--panel .cu-lp-shell { grid-template-columns: minmax(0, 1.2fr) minmax(360px, 1fr); }
}
/* phones held sideways / short screens: a slim brand band so the form is reachable */
@media (max-width: 900px) and (max-height: 500px) {
    .cu-lp-brand, body.cu-lp--panel .cu-lp-brand { padding: 14px 22px 16px; }
    .cu-lp-brand-company { margin-bottom: 6px; }
    .cu-lp-brand-tagline, .cu-lp-brand .cu-lp-orb { display: none; }
    .cu-lp-brand-headline { font-size: 20px; margin: 0; }
    .cu-lp-main { padding-top: 18px; }
}
@media (max-height: 640px) and (min-width: 901px) {
    .cu-lp-main { padding-top: 24px; padding-bottom: 24px; }
    body.cu-lp .cu-lp-card { padding-top: 28px !important; padding-bottom: 22px !important; }
}
@media (max-width: 480px) {
    body.cu-lp .cu-lp-card { padding: 30px 20px 22px !important; border-radius: 16px; }
    body.cu-lp--panel .cu-lp-main { padding-left: 16px; padding-right: 16px; }
    body.cu-lp--panel .cu-lp-card { padding-left: 0 !important; padding-right: 0 !important; }
    .cu-lp-main { padding-left: 12px; padding-right: 12px; }
    /* iPhone zooms into fields under 16px when they are tapped */
    body.cu-lp .cu-lp-card .form-control { font-size: 16px; }
}
/* big screens: the form, the brand words and the line under the card grow with the screen */
@media (min-width: 1800px) {
    body.cu-lp .cu-lp-card, .cu-lp-under, .cu-lp-brand-inner, .cu-lp-brand-foot { zoom: 1.15; }
    .cu-lp-brand { padding: 72px 88px; }
}
@media (min-width: 2400px) {
    body.cu-lp .cu-lp-card, .cu-lp-under, .cu-lp-brand-inner, .cu-lp-brand-foot { zoom: 1.35; }
    .cu-lp-brand { padding: 96px 120px; }
}

/* ---------- Session expired card: the 419 page (views/errors/html/expired_419.php) and the card login_page.js swaps in for the form ---------- */
body.cu-lp .cu-lp-card.cu-lp-expired { text-align: center; }
.cu-lp-card[hidden] { display: none !important; }
.cu-lp-exp-ico {
    width: 64px; height: 64px; margin: 4px auto 18px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
    color: var(--cu-lp-accent); background: rgba(37, 99, 235, .12);
    background: color-mix(in srgb, var(--cu-lp-accent) 12%, #fff);
}
.cu-lp-exp-ico svg { width: 30px; height: 30px; }
body.cu-lp .cu-lp-expired h1 { margin: 0 0 10px; }
body.cu-lp .cu-lp-expired .cu-lp-exp-msg { margin: 0 0 26px; color: #475569; }
body.cu-lp .cu-lp-expired .btn { display: flex; align-items: center; justify-content: center; width: 100%; text-decoration: none; height: 48px; height: calc(var(--cu-lp-fs, 15px) * 3.2); border-radius: 10px; font-weight: 600; font-size: 15px; font-size: var(--cu-lp-fs, 15px); }
body.cu-lp .cu-lp-expired .btn + .btn { margin-top: 10px; }
body.cu-lp .cu-lp-expired .cu-lp-exp-back {
    background: transparent; color: var(--cu-lp-accent); border: 1px solid var(--cu-lp-accent); transition: background .15s;
}
body.cu-lp .cu-lp-expired .cu-lp-exp-back:hover, body.cu-lp .cu-lp-expired .cu-lp-exp-back:focus {
    background: rgba(37, 99, 235, .08); background: color-mix(in srgb, var(--cu-lp-accent) 8%, #fff); color: var(--cu-lp-accent); outline: 0;
}
body.cu-lp .cu-lp-expired .btn.is-busy { opacity: .7; pointer-events: none; }
body.cu-lp--panel .cu-lp-card.cu-lp-expired { text-align: center; }

/* "Sign-in failed" popup: one line per message */
.cu-lp-msg + .cu-lp-msg { margin-top: 6px; }
.cu-lp-msg p { margin: 0; }

/* Staff Mentions chat bubble (module staff_mentions): appended to <body> and fixed, so it sits above every layout.
   Not part of the Login Manager preview (nothing in a preview can be used). */
body.cu-lp .sm-guest { z-index: 99999; }

/* "Do not let the browser save staff passwords" (login_page.js noPwStore()): a text field drawn as dots */
input.cu-lp-masked { -webkit-text-security: disc; text-security: disc; }
/* one-click sign-in on a remembered computer (Login Manager > Computers) */
