/* Shared by the startup shell and JavaScript-owned media inside Blazor. */
.login-design { position: relative; overflow: hidden; isolation: isolate; }
.login-design::before, .login-design::after { display: none; }
.login-video-host, .login-background-video { position: absolute; inset: 0; width: 100%; height: 100%; }
.login-video-host { z-index: 0; }
.login-background-video { object-fit: cover; opacity: 0; transition: opacity 900ms ease; }
.login-background-video.is-playing { opacity: 1; }
.login-color-layer { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.login-image-layer { position: absolute; inset: 0; display: flex; padding: 2rem; z-index: 2; pointer-events: none; }
.login-image-layer img { max-width: 85%; max-height: 85%; width: auto; height: auto; object-fit: contain; }
.login-startup .loading-progress { margin: 0 auto; }
.login-startup .loading-progress-text { position: relative; top: auto; }
.login-video-action { position: absolute; bottom: 1.5rem; left: 50%; transform: translateX(-50%); z-index: 3; color: #fff; text-align: center; }
button.login-video-action { color: #172d4a; }
.auth-login-fullscreen { position: relative; min-height: 100dvh; background: #172d4a; padding: 32px 24px; isolation: isolate; }
.auth-login-fullscreen > .auth-form-side { background: transparent; width: 100%; padding: 0; min-height: 0; z-index: 2; }
.auth-login-fullscreen .auth-container { margin: auto; }
.auth-login-fullscreen .auth-card {
    color-scheme: light;
    --accent-color: var(--brand-blue, #29467D);
    --accent-rgb: 41, 70, 125;
    --contrast-color: #FFFFFF;
    --default-color: #000;
    --heading-color: #000;
    --muted-color: #000;
    --light-color: #000;
    --input-bg: #fff;
    --surface-color: #fff;
    --background-color: #fff;
    color: #000;
}
.auth-login-fullscreen .auth-card .form-control { color: #000; background-color: #fff; }
.auth-login-fullscreen .auth-card .auth-link { color: #000; }
.auth-login-fullscreen .auth-card .btn-outline-secondary {
    --bs-btn-color: #000;
    --bs-btn-hover-color: #000;
    --bs-btn-active-color: #000;
    --bs-btn-disabled-color: #000;
}
.auth-tenant-logo { display: flex; justify-content: center; width: 100%; margin-bottom: 16px; }
.auth-tenant-logo img { width: var(--tenant-logo-width, 120px); height: auto; max-width: 100%; max-height: var(--tenant-logo-max-height, 64px); object-fit: contain; }
.auth-login-fullscreen > .login-fullscreen-background { position: fixed; inset: 0; display: block; width: 100%; height: 100%; padding: 0; background: radial-gradient(ellipse at 75% 10%, #4769a4 0, transparent 55%), radial-gradient(ellipse at 5% 90%, #29467d 0, transparent 65%), #172d4a; z-index: -1; }
.auth-corner-logo { position: fixed; top: 24px; left: 24px; max-width: calc(100% - 100px); z-index: 3; }
.auth-corner-logo img { width: 100%; height: auto; object-fit: contain; object-position: left top; }
.auth-login-fullscreen .footer-copyright { color: #fff; }
.auth-login-fullscreen .footer-centered { position: absolute; left: 0; right: 0; bottom: 8px; margin: 0; padding: 0; }
.auth-login-fullscreen .otp-card { padding: 0; }
.auth-otp-screen .auth-container { max-width: 400px; }
.auth-otp-screen .auth-card { padding: 20px 24px; }
.auth-otp-screen .footer-centered { position: static; margin-top: 12px; }
@media (max-width: 575px) {
    .auth-otp-screen .auth-card { padding: 16px; }
}
.auth-login-fullscreen .otp-card .btn-primary:disabled { color: var(--heading-color, #172d4a); background: var(--surface-color, #fff); opacity: .65; }
@media (max-width: 575px) {
    .auth-login-fullscreen { padding: 110px 16px 24px; }
    .auth-corner-logo { top: 16px; left: 16px; max-width: min(45vw, calc(100% - 100px)); }
}

/* The same complete visual surface is painted by index.html before WebAssembly
   or tenant media arrives. Video is a progressive enhancement, never a loader. */
.auth-login-modern {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    padding: 120px clamp(24px, 5.5vw, 96px) 64px;
}
.auth-login-modern::after {
    content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none;
    background: linear-gradient(90deg, #101f3bd9 0%, #172d4aa3 48%, #29467d66 100%);
}
.auth-login-modern > .auth-form-side {
    display: grid; grid-template-columns: minmax(0, 1fr) minmax(360px, 440px);
    gap: clamp(48px, 7vw, 120px); max-width: 1320px; margin: auto; align-items: center;
}
.auth-login-modern .auth-welcome { color: #faf9f6; max-width: 650px; padding: 24px 0 64px; }
.auth-welcome-eyebrow { display: flex; align-items: center; gap: 12px; font-size: 11px; font-weight: 600; letter-spacing: .19em; margin: 0 0 32px; color: #d9e3f5; }
.auth-welcome-eyebrow span { width: 8px; height: 8px; border-radius: 50%; background: #f6d495; box-shadow: 0 0 0 5px #f6d49518; }
.auth-welcome h2 { margin: 0; font-family: inherit; font-size: clamp(46px, 5.1vw, 78px); font-weight: 500; line-height: 1.07; letter-spacing: -.055em; color: inherit; }
.auth-welcome h2 span { color: #f6d495; }
.auth-welcome-description { max-width: 350px; margin: 28px 0 0; font-size: 17px; line-height: 1.7; color: #d9e3f5; }
.auth-welcome-rule { width: 48px; height: 1px; background: #f6d49588; margin: 38px 0 18px; }
.auth-welcome-note { color: #c7d5ed; font-size: 12px; letter-spacing: .025em; margin: 0; }
.auth-login-modern .auth-container { width: 100%; max-width: 440px; margin: 0; }
.auth-login-modern .auth-card {
    --default-color: #172d4a; --heading-color: #172d4a; --muted-color: #53647b;
    color: #172d4a; padding: 34px; border: 1px solid #ffffff90; border-radius: 24px;
    box-shadow: 0 28px 80px #0c1b3340, 0 1px 0 #ffffff55 inset;
    backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
}
.auth-login-modern .auth-card-header { text-align: left; margin-bottom: 26px; }
.auth-workspace-badge { display: inline-flex; max-width: 100%; gap: 7px; align-items: center; font-size: 11px; padding: 6px 10px; border: 1px solid #29467d1c; border-radius: 7px; color: #53647b; background: #29467d08; margin-bottom: 20px; }
.auth-workspace-badge > span { width: 5px; height: 5px; border-radius: 50%; background: #4769a4; flex-shrink: 0; }
.auth-workspace-badge strong { color: #29467d; font-weight: 600; overflow-wrap: anywhere; min-width: 0; }
.auth-login-modern .auth-title { font-family: inherit; font-size: 32px; font-weight: 600; letter-spacing: -.04em; line-height: 1.2; margin-bottom: 10px; color: #172d4a; }
.auth-login-modern .auth-subtitle { font-size: 14px; color: #53647b; line-height: 1.6; }
.auth-login-modern .auth-form .form-group { margin-bottom: 20px; }
.auth-login-modern .auth-form .form-label { color: #29467d; font-size: 12px; font-weight: 600; margin-bottom: 9px; }
.auth-input-wrap { position: relative; }
.auth-input-wrap > i { position: absolute; left: 15px; top: 50%; transform: translateY(-50%); color: #687c99; pointer-events: none; font-size: 16px; }
.auth-login-modern .auth-form .form-control { min-height: 50px; padding: 12px 14px 12px 43px; border: 1px solid #d4dce8; background: #ffffffd9; color: #172d4a; border-radius: 9px; font-size: 14px; box-shadow: 0 1px 2px #172d4a04; }
.auth-login-modern .auth-form .form-control:focus { border-color: #4769a4; box-shadow: 0 0 0 3px #29467d1c; background: #fff; }
.auth-login-modern .auth-form .form-control::placeholder { color: #6a7c96; }
.auth-login-modern .auth-form .auth-link { font-size: 11px; font-weight: 600; color: #29467d; margin-bottom: 9px; }
.auth-login-modern .auth-form .btn-block { min-height: 50px; display: flex; align-items: center; justify-content: center; gap: 10px; font-size: 13px; font-weight: 600; border-radius: 9px; margin-top: 6px; }
.auth-login-modern .auth-form .btn-primary { --bs-btn-bg: #29467d; --bs-btn-border-color: #29467d; --bs-btn-hover-bg: #1d355f; --bs-btn-hover-border-color: #1d355f; --bs-btn-active-bg: #1d355f; --bs-btn-active-border-color: #1d355f; --bs-btn-disabled-bg: #29467d; --bs-btn-disabled-border-color: #29467d; box-shadow: 0 4px 12px #1d355f1a; }
.auth-login-modern .auth-form .btn-outline-secondary { --bs-btn-color: #29467d; --bs-btn-border-color: #d4dce8; --bs-btn-hover-bg: #f2f4f8; --bs-btn-hover-color: #172d4a; --bs-btn-hover-border-color: #a4b5d0; background: #ffffffb3; }
.auth-login-modern .auth-divider { margin: 22px 0; font-size: 10px; color: #53647b; }
.auth-login-modern .auth-divider::before, .auth-login-modern .auth-divider::after { background: #dce2e9; }
.auth-login-modern .auth-footer-text { display: flex; align-items: center; justify-content: center; gap: 7px; font-size: 10px; color: #53647b; margin-top: 24px; line-height: 1.5; }
.auth-login-modern .auth-footer-text i { color: #4769a4; font-size: 13px; }
.auth-login-modern .auth-tenant-logo { justify-content: center; margin-bottom: 22px; }
.auth-login-modern .auth-corner-logo { top: 28px; left: clamp(24px, 5.5vw, 96px); }
.auth-login-modern .auth-corner-logo img { max-height: 72px; object-position: left center; }
body:has(.auth-login-modern) .auth-theme-toggle { top: 28px; right: 28px; border-radius: 12px; background: #172d4ab3; border: 1px solid #ffffff40; color: #eff4fc; }
body:has(.auth-login-modern) .auth-theme-toggle i { color: inherit; }
.auth-login-modern .footer-centered { position: static; margin-top: 22px; }
.auth-login-modern .footer-copyright { color: #d4dff1; font-size: 10px; }
.auth-login-modern.auth-otp-screen .auth-container { max-width: 440px; }
.auth-login-modern.auth-otp-screen .auth-card { padding: 30px; }
.auth-login-modern .login-video-action { position: fixed; left: auto; right: 28px; bottom: 22px; z-index: 4; transform: none; display: inline-flex; align-items: center; gap: 6px; padding: 9px 13px; border-radius: 8px; border: 1px solid #ffffff40; background: #172d4a70; backdrop-filter: blur(12px); color: #eff4fc; font: inherit; font-size: 11px; cursor: pointer; }
.auth-login-modern .login-video-action:focus-visible { outline: 3px solid #f6d495; outline-offset: 3px; }
.auth-login-modern .login-video-action i { font-size: 17px; }
.auth-startup-card { min-height: 480px; }
.auth-startup-card .auth-subtitle { margin-bottom: 30px; }
.auth-startup-lines { display: grid; gap: 18px; margin: 30px 0; }
.auth-startup-lines span { display: block; height: 50px; border: 1px solid #dce2e9; border-radius: 9px; background: #edf1f8; }
.auth-startup-lines span:last-child { background: #d6e1f2; }
.auth-startup-progress { height: 3px; overflow: hidden; border-radius: 3px; background: #dce2e9; }
.auth-startup-progress span { display: block; height: 100%; width: var(--blazor-load-percentage, 12%); background: #4769a4; transition: width 180ms ease; }
.auth-startup-status { color: #53647b; margin: 14px 0 0; font-size: 12px; }
@media (max-width: 1000px) {
    .auth-login-modern { padding: 120px 28px 70px; }
    .auth-login-modern > .auth-form-side { grid-template-columns: minmax(0, 1fr) minmax(340px, 410px); gap: 36px; }
    .auth-welcome h2 { font-size: 52px; }
    .auth-welcome-description { font-size: 15px; }
    .auth-login-modern .auth-card { padding: 28px; }
}
@media (max-width: 767px) {
    .auth-login-modern { padding: 112px 20px 72px; }
    .auth-login-modern > .auth-form-side { display: block; max-width: 440px; }
    .auth-login-modern .auth-welcome { display: none; }
    .auth-login-modern .auth-container { margin: auto; }
    .auth-login-modern .auth-corner-logo { top: 22px; left: 22px; }
    .auth-login-modern .auth-corner-logo img { max-height: 62px; }
    .auth-login-modern::after { background: linear-gradient(145deg, #172d4ab3, #29467d70); }
    .auth-login-modern .login-video-action { position: relative; bottom: auto; right: auto; align-self: flex-end; margin: 16px 0 -40px; }
}
@media (max-width: 380px) {
    .auth-login-modern { padding-inline: 14px; }
    .auth-login-modern .auth-card, .auth-login-modern.auth-otp-screen .auth-card { padding: 23px; border-radius: 18px; }
    .auth-login-modern .auth-title { font-size: 28px; }
}
@media (prefers-reduced-motion: reduce) {
    .login-background-video, .auth-startup-progress span { transition: none; }
}

/* Team shares authentication, with its own portal design from the first paint. */
.auth-login-team .auth-tenant-logo img { background: transparent; border: 0; border-radius: 0; padding: 0; }
.login-team-copy { display: none; }
html[data-login-portal="team"] .login-startup .login-admin-copy { display: none; }
html[data-login-portal="team"] .login-startup .login-team-copy { display: block; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) { padding: 24px; background: var(--brand-paper); }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) > .auth-form-side { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; max-width: none; min-height: calc(100dvh - 48px); }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-container { grid-column: 1; grid-row: 1; width: 100%; max-width: 600px; padding: 96px clamp(24px, 4vw, 72px) 32px; margin: auto; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) > .login-fullscreen-background { position: absolute; inset: 24px 24px 24px calc(50% + 12px); width: auto; height: auto; border-radius: 30px; background: radial-gradient(ellipse at 80% 5%, #7396AE, transparent 65%), var(--brand-blue); }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup)::after { position: absolute; inset: 24px 24px 24px calc(50% + 12px); border-radius: 30px; background: linear-gradient(180deg, #3E5C8225, #1D344CCF 75%); }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-welcome { grid-column: 2; grid-row: 1; align-self: stretch; display: flex; flex-direction: column; justify-content: flex-end; max-width: none; min-height: calc(100dvh - 48px); padding: 240px clamp(32px, 4.4vw, 84px) 64px; position: relative; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-welcome h2 { font-size: clamp(46px, 4.6vw, 74px); font-weight: 500; line-height: 1.05; letter-spacing: -.055em; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-welcome h2 span { color: var(--brand-highlight); }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-welcome-eyebrow { color: #E0EDE8; letter-spacing: .17em; margin-bottom: 28px; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-welcome-eyebrow span { background: var(--brand-highlight); box-shadow: 0 0 0 5px #C4DFD018; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-welcome-description { max-width: 390px; color: #E0EDE8; font-size: 16px; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-welcome-rule { background: #C4DFD080; margin-top: 30px; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-welcome-note { color: #D4E5DE; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-card { --accent-color: var(--brand-blue); --accent-rgb: 62, 92, 130; --accent-hover-color: #2D4667; border: 1px solid #D6E2E3; box-shadow: 0 16px 52px #1D344C0B; border-radius: 22px; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-title { color: var(--brand-navy); font-size: 30px; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-workspace-badge { background: #EEF4F1; color: #546A79; border-color: #D6E2E3; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-workspace-badge strong { color: var(--brand-blue); }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-form .btn-primary { --bs-btn-bg: var(--brand-blue); --bs-btn-border-color: var(--brand-blue); --bs-btn-hover-bg: #2D4667; --bs-btn-hover-border-color: #2D4667; --bs-btn-active-bg: #2D4667; --bs-btn-active-border-color: #2D4667; --bs-btn-disabled-bg: var(--brand-blue); --bs-btn-disabled-border-color: var(--brand-blue); }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-form .form-control:focus { border-color: #5F809D; box-shadow: 0 0 0 3px #3E5C8224; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-corner-logo { position: absolute; top: 42px; left: 48px; padding: 0; box-sizing: content-box; border-radius: 0; background: transparent; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-corner-logo img { max-height: 48px; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .footer-copyright { color: #546A79; }
:is(.auth-login-team, html[data-login-portal="team"] .login-startup) .login-video-action { right: 44px; bottom: 44px; background: #1D344CA6; }
.auth-team-orbit { position: absolute; top: 64px; right: 12%; width: 190px; height: 190px; border: 1px solid #C4DFD042; border-radius: 50%; display: grid; place-items: center; transform: rotate(-18deg); }
.auth-team-orbit::before, .auth-team-orbit::after { content: ""; position: absolute; border: 1px solid #C4DFD030; border-radius: 50%; }
.auth-team-orbit::before { inset: 24px -22px; }
.auth-team-orbit::after { inset: -22px 24px; }
.auth-team-orbit i { font-size: 60px; color: var(--brand-highlight); transform: rotate(18deg); }
.auth-team-orbit span { position: absolute; width: 12px; height: 12px; border: 3px solid var(--brand-highlight); background: #5F809D; border-radius: 50%; }
.auth-team-orbit span:nth-child(1) { top: 6px; left: 36px; }
.auth-team-orbit span:nth-child(2) { right: -5px; top: 80px; }
.auth-team-orbit span:nth-child(3) { bottom: -4px; left: 80px; }
body:has(.auth-login-team) .auth-theme-toggle { position: absolute; top: 44px; right: 44px; }
@media (max-width: 1000px) and (min-width: 768px) {
    :is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-container { padding-inline: 12px; padding-top: 112px; }
    :is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-welcome { padding-inline: 28px; }
    :is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-welcome h2 { font-size: 44px; }
    .auth-team-orbit { width: 140px; height: 140px; right: 18%; }
}
@media (max-width: 767px) {
    :is(.auth-login-team, html[data-login-portal="team"] .login-startup) { padding: 132px 20px 64px; }
    :is(.auth-login-team, html[data-login-portal="team"] .login-startup) > .auth-form-side { display: block; min-height: 0; max-width: 440px; }
    :is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-container { padding: 0; }
    :is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-welcome { display: none; }
    :is(.auth-login-team, html[data-login-portal="team"] .login-startup) > .login-fullscreen-background,
    :is(.auth-login-team, html[data-login-portal="team"] .login-startup)::after { position: absolute; inset: 0 0 auto; height: 230px; width: 100%; border-radius: 0 0 30px 30px; }
    :is(.auth-login-team, html[data-login-portal="team"] .login-startup) .auth-corner-logo { top: 22px; left: 22px; padding: 0; }
    :is(.auth-login-team, html[data-login-portal="team"] .login-startup) .login-video-action { position: relative; right: auto; bottom: auto; margin: 16px 0 -32px; background: var(--brand-navy); }
    body:has(.auth-login-team) .auth-theme-toggle { top: 28px; right: 22px; }
}

/* Transparent supplied artwork: no logo tiles or colour filters. */
.auth-corner-logo, .auth-corner-logo img, .auth-tenant-logo, .auth-tenant-logo img { background: transparent; border: 0; box-shadow: none; }
.login-startup #startup-team-logo { display: none; }
html[data-login-portal="team"] .login-startup #startup-tenant-logo:not([data-custom-logo="true"]) { display: none; }
html[data-login-portal="team"] .login-startup #startup-team-logo:not([hidden]) { display: block; }
