:root {
    --auth-brand-blue: #0875e1;
    --auth-brand-bright: #0b9ef2;
    --auth-navy: #022b62;
    --auth-navy-deep: #001b43;
    --auth-ice: #f4faff;
    --auth-text: #071536;
    --auth-muted: #667694;
    --auth-card-radius: 18px;
    --auth-card-width: 587px;
    --auth-control-height: 64px;
    --auth-shadow: 0 18px 48px rgba(0, 18, 50, .22);
}

html, body.hyralis-auth, .hyralis-auth-shell { height: 100%; min-height: 100%; min-height: 100dvh; }
html { overflow: hidden; }
body.hyralis-auth { margin: 0; overflow: hidden; background: var(--auth-navy-deep); color: var(--auth-text); }
.hyralis-auth-shell {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    background:
        linear-gradient(134deg, transparent 0 67%, rgba(9, 75, 165, .26) 67.15% 75%, transparent 75.15%),
        linear-gradient(315deg, transparent 0 70%, rgba(10, 77, 169, .24) 70.15% 80%, transparent 80.15%),
        linear-gradient(145deg, #0a438f 0%, #053575 34%, var(--auth-navy-deep) 100%);
}
.hyralis-auth-shell::before,
.hyralis-auth-shell::after {
    position: absolute;
    z-index: 0;
    content: "";
    pointer-events: none;
}
.hyralis-auth-shell::before {
    inset: 0;
    background: linear-gradient(125deg, #098fec 0%, #096bd2 55%, #074a9f 100%);
    clip-path: polygon(56.8% 0, 61.3% 0, 39.1% 100%, 34.3% 100%, 36.4% 95.6%, 40.7% 85%, 44% 74.4%, 46.7% 63.8%, 48.4% 53.1%, 50.1% 42.5%, 51.8% 31.9%, 53.4% 21.3%, 55% 10.6%);
}
.hyralis-auth-shell::after {
    inset: 0;
    background:
        linear-gradient(134deg, transparent 0 69%, rgba(6, 82, 181, .24) 69.1% 78%, transparent 78.1%),
        linear-gradient(315deg, transparent 0 71%, rgba(5, 66, 151, .23) 71.1% 81%, transparent 81.1%);
}

.hyralis-auth-brand {
    position: absolute;
    inset: 0;
    z-index: 1;
    min-width: 0;
    box-sizing: border-box;
    overflow: hidden;
    background:
        linear-gradient(145deg, rgba(185, 225, 255, .62), transparent 20%),
        linear-gradient(25deg, rgba(195, 228, 253, .66), transparent 27%),
        radial-gradient(circle at 33% 45%, #fff 0, #fbfdff 38%, var(--auth-ice) 100%);
    clip-path: polygon(0 0, 56.8% 0, 55% 10.6%, 53.4% 21.3%, 51.8% 31.9%, 50.1% 42.5%, 48.4% 53.1%, 46.7% 63.8%, 44% 74.4%, 40.7% 85%, 36.4% 95.6%, 34.3% 100%, 0 100%);
}
.hyralis-auth-brand::after {
    position: absolute;
    z-index: -1;
    inset: 0;
    content: "";
    pointer-events: none;
    background:
        linear-gradient(151deg, transparent 0 11%, rgba(28, 154, 243, .12) 11.2% 16.5%, transparent 16.7%),
        linear-gradient(28deg, transparent 0 11%, rgba(43, 151, 235, .13) 11.2% 17%, transparent 17.2%);
}
.hyralis-auth-geometry { position: absolute; z-index: -1; display: block; pointer-events: none; transform: rotate(-29deg); background: rgba(74, 169, 244, .11); }
.hyralis-auth-geometry-one { top: -20rem; left: 3rem; width: 10rem; height: 43rem; }
.hyralis-auth-geometry-two { bottom: -22rem; left: 4rem; width: 13rem; height: 45rem; }
.hyralis-auth-logo { display: block; position: absolute; top: 23.25%; left: calc(6.75% + 40px); width: min(31.8vw, 610px); max-width: 43%; height: auto; }
.hyralis-auth-brand-copy { position: absolute; z-index: 2; top: 57%; left: 6.75%; width: min(42%, 760px); }
.hyralis-auth-brand-heading { max-width: 760px; margin: 0 0 1.35rem; color: #06143a; font-size: clamp(44px, 3vw, 58px); font-weight: 800; letter-spacing: -.045em; line-height: 1.08; text-wrap: balance; }
.hyralis-auth-brand-support { margin: 0; color: #5b6e91; font-size: clamp(18px, 1.35vw, 26px); line-height: 1.45; }

.hyralis-auth-stage {
    position: absolute;
    z-index: 3;
    inset: 0 0 0 52.65%;
    display: flex;
    min-width: 0;
    height: 100%;
    min-height: 100%;
    align-items: flex-start;
    justify-content: center;
    box-sizing: border-box;
    padding: clamp(28px, 14vh, 152px) clamp(24px, 3vw, 56px) 48px;
    overflow-y: auto;
    overscroll-behavior: contain;
}
.hyralis-auth-stage-content {
    display: flex;
    width: min(100%, var(--auth-card-width));
    min-width: 0;
    flex-direction: column;
    border: 1px solid rgba(8, 38, 81, .1);
    border-radius: var(--auth-card-radius);
    background: #fff;
    box-shadow: var(--auth-shadow);
}

.hyralis-auth-card {
    position: relative;
    z-index: 2;
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0 auto;
    padding: clamp(36px, 5.6vh, 60px);
    border: 0;
    border-radius: var(--auth-card-radius);
    background: #fff;
    box-shadow: none;
}
.hyralis-auth-card.auth-card-login { display: flex; min-height: 700px; flex: 1 1 auto; flex-direction: column; padding-top: 80px; padding-bottom: 24px; }
.hyralis-auth-card.auth-card-wide { --auth-card-width: 587px; }
.hyralis-auth-heading { margin-bottom: 1.6rem; text-align: center; }
.auth-card-login .hyralis-auth-heading { margin-bottom: 42px; }
.hyralis-auth-eyebrow { margin: 0 0 19px; color: var(--auth-brand-blue); font-size: 13px; font-weight: 800; letter-spacing: .075em; }
.hyralis-auth-heading h1 { margin: 0 0 21px; color: var(--auth-text); font-size: clamp(32px, 2.05vw, 36px); font-weight: 800; letter-spacing: -.04em; line-height: 1.12; }
.hyralis-auth-description { margin: 0; color: var(--auth-muted); font-size: 20px; font-weight: 500; line-height: 1.5; }
.hyralis-auth-status-icon { display: grid; width: 64px; height: 64px; margin: 0 auto 1.25rem; place-items: center; border-radius: 50%; }
.hyralis-auth-status-icon i { font-size: 2rem; color: currentColor; }

.hyralis-auth-card .form-label { margin-bottom: 5px; color: #34415a; font-size: 16px; }
.hyralis-auth-card .text-gray-500 { color: var(--auth-muted) !important; }
.hyralis-auth-card .text-gray-600, .hyralis-auth-card .text-gray-700 { color: #52617d !important; }
.hyralis-auth-card a { color: var(--auth-brand-blue); }
.hyralis-auth-control, .hyralis-auth-primary, .hyralis-auth-secondary { min-height: var(--auth-control-height); }
.hyralis-auth-control { border: 1px solid #cbd6e6 !important; border-radius: 10px; background: #f1f6fd !important; color: #17223a; font-size: 1rem; }
.hyralis-auth-control::placeholder { color: #8290a8; opacity: 1; }
.hyralis-auth-control:focus { border-color: var(--auth-brand-blue) !important; box-shadow: 0 0 0 .22rem rgba(8, 117, 225, .14) !important; }
.hyralis-auth-control[readonly] { background: #eef4fb !important; }
.hyralis-password-field { position: relative; }
.hyralis-password-field .form-control { padding-right: 3.75rem; }
.hyralis-password-toggle { position: absolute; top: 50%; right: .25rem; width: 44px; height: 44px; transform: translateY(-50%); }
.hyralis-password-toggle i { color: #697895; }
.hyralis-auth-primary, .hyralis-auth-secondary { display: inline-flex; min-width: 44px; align-items: center; justify-content: center; border-radius: 10px; font-size: 1rem; font-weight: 600; line-height: 1.2; text-align: center; }
.hyralis-auth-card .hyralis-auth-primary { border: 1px solid transparent !important; background-color: #075ebc !important; background-image: linear-gradient(105deg, #075ebc, #0876d1) !important; box-shadow: 0 9px 20px rgba(0, 86, 181, .2); color: #fff !important; }
.hyralis-auth-card .hyralis-auth-primary:hover, .hyralis-auth-card .hyralis-auth-primary:focus-visible { border-color: transparent !important; background-color: #054f9f !important; background-image: linear-gradient(105deg, #054f9f, #0665b5) !important; color: #fff !important; }
.hyralis-auth-card .hyralis-auth-primary:active { background: #044b98 !important; box-shadow: 0 4px 10px rgba(0, 63, 133, .24); color: #fff !important; }
.hyralis-auth-card .hyralis-auth-secondary { border: 1px solid #aeb9c8 !important; background: #f1f4f8 !important; color: #18243a !important; box-shadow: 0 2px 5px rgba(15, 35, 62, .08); }
.hyralis-auth-card .hyralis-auth-secondary:hover, .hyralis-auth-card .hyralis-auth-secondary:focus-visible { border-color: #7f8da1 !important; background: #e5eaf1 !important; color: #0c172b !important; }
.hyralis-auth-card .hyralis-auth-secondary:active { border-color: #6f7d91 !important; background: #d7dee8 !important; color: #081326 !important; box-shadow: inset 0 1px 2px rgba(15, 35, 62, .12); }
.hyralis-auth-primary:disabled, .hyralis-auth-primary.disabled, .hyralis-auth-secondary:disabled, .hyralis-auth-secondary.disabled { cursor: not-allowed; opacity: .58; box-shadow: none; pointer-events: none; }
.hyralis-auth-actions { display: flex; gap: .75rem; }
.hyralis-auth-actions > * { flex: 1 1 0; }
.hyralis-auth-choice { min-height: 72px; border: 1px solid #d8e1ee; border-radius: 12px; }
.hyralis-auth-choice:hover { border-color: var(--auth-brand-blue); background: #f4f9ff; }
.hyralis-auth-help { color: var(--auth-muted); font-size: .86rem; line-height: 1.55; }
.hyralis-auth-validation:empty, .hyralis-auth-validation.validation-summary-valid { display: none; }
.hyralis-auth-validation ul { margin-bottom: 0; padding-left: 1.15rem; }
.hyralis-auth-footer { display: flex; padding: 0 clamp(36px, 5.6vh, 60px) 32px; align-items: center; justify-content: space-between; gap: 1rem; color: #71809c; font-size: .84rem; }
.hyralis-auth-footer-links { display: flex; gap: 1.25rem; }
.hyralis-auth-footer a { display: inline-flex; min-height: 44px; align-items: center; }
.hyralis-auth :is(a, button, input, select):focus-visible { outline: 3px solid rgba(8, 117, 225, .34); outline-offset: 3px; }
.hyralis-auth :is(a, button, input, select) { touch-action: manipulation; }

/* Corporate fixed-theme policy: auth keeps the approved light card and controls in both application themes. */
[data-bs-theme="dark"] .hyralis-auth-stage-content, [data-bs-theme="dark"] .hyralis-auth-card { border-color: rgba(8, 38, 81, .1); background: #fff; }
[data-bs-theme="dark"] .hyralis-auth-heading h1 { color: var(--auth-text); }
[data-bs-theme="dark"] .hyralis-auth-description, [data-bs-theme="dark"] .hyralis-auth-card .text-gray-500 { color: var(--auth-muted) !important; }
[data-bs-theme="dark"] .hyralis-auth-card .text-gray-600, [data-bs-theme="dark"] .hyralis-auth-card .text-gray-700 { color: #52617d !important; }
[data-bs-theme="dark"] .hyralis-auth-card .form-label { color: #34415a !important; }
[data-bs-theme="dark"] .hyralis-auth-control { border-color: #cbd6e6 !important; background: #f1f6fd !important; color: #17223a; }
[data-bs-theme="dark"] .hyralis-auth-control[readonly] { background: #eef4fb !important; }
[data-bs-theme="dark"] .hyralis-auth-card a { color: var(--auth-brand-blue); }
[data-bs-theme="dark"] .hyralis-auth-choice:hover { background: #f4f9ff; }

@media (max-width: 1199.98px) {
    .hyralis-auth-logo { left: calc(5.5% + 24px); }
    .hyralis-auth-brand-copy { left: 5.5%; }
    .hyralis-auth-brand-heading { font-size: 2.5rem; }
    .hyralis-auth-stage { left: 50%; padding-right: 1.5rem; padding-left: 1.5rem; }
}
@media (max-width: 991.98px) {
    html { overflow-x: hidden; overflow-y: auto; }
    body.hyralis-auth { background: var(--auth-navy-deep); }
    body.hyralis-auth { overflow-x: hidden; overflow-y: auto; }
    .hyralis-auth-shell { display: flex; height: auto; min-height: 100dvh; flex-direction: column; overflow: visible; }
    .hyralis-auth-shell::before, .hyralis-auth-shell::after { display: none; }
    .hyralis-auth-brand { display: flex; position: relative; inset: auto; width: 100%; min-height: calc(148px + env(safe-area-inset-top)); padding-top: env(safe-area-inset-top); flex: 0 0 calc(148px + env(safe-area-inset-top)); align-items: center; justify-content: center; box-sizing: border-box; clip-path: polygon(0 0, 100% 0, 100% 80%, 0 100%); }
    .hyralis-auth-brand::after { z-index: 0; }
    .hyralis-auth-geometry { z-index: 0; }
    .hyralis-auth-geometry-one { top: -6rem; left: 8%; width: 3.75rem; height: 16rem; }
    .hyralis-auth-geometry-two { right: 8%; bottom: -8rem; left: auto; width: 4.75rem; height: 17rem; }
    .hyralis-auth-logo { position: relative; z-index: 1; top: auto; left: auto; width: min(220px, 54vw); max-width: none; margin-top: -8px; }
    .hyralis-auth-brand-copy { position: relative; top: auto; left: auto; width: min(100%, 620px); box-sizing: border-box; padding: 24px max(20px, env(safe-area-inset-right)) 20px max(20px, env(safe-area-inset-left)); text-align: center; }
    .hyralis-auth-brand-heading { max-width: 520px; margin: 0 auto 10px; color: #fff; font-size: clamp(24px, 4vw, 32px); line-height: 1.14; }
    .hyralis-auth-brand-support { color: #d8ebff; font-size: 15px; line-height: 1.45; }
    .hyralis-auth-stage { position: relative; inset: auto; width: 100%; height: auto; min-height: 0; flex: 1 0 auto; padding: 0 max(20px, env(safe-area-inset-right)) max(20px, env(safe-area-inset-bottom)) max(20px, env(safe-area-inset-left)); overflow: visible; }
    .hyralis-auth-stage-content { width: min(100%, 590px); border: 0; background: transparent; box-shadow: none; }
    [data-bs-theme="dark"] .hyralis-auth-stage-content { border: 0; background: transparent; }
    .hyralis-auth-card, .hyralis-auth-card.auth-card-login { width: 100%; min-height: 0; margin: 0; padding: 2rem; border: 1px solid rgba(8, 38, 81, .1); background: #fff; box-shadow: var(--auth-shadow); }
    .hyralis-auth-control, .hyralis-auth-primary, .hyralis-auth-secondary { min-height: 52px; }
    .hyralis-auth-footer { padding: 14px 4px 0; color: #d7e9ff; }
    .hyralis-auth-footer a { color: #fff; }
}
@media (max-width: 575.98px) {
    .hyralis-auth-brand { min-height: 132px; flex-basis: 132px; }
    .hyralis-auth-logo { width: min(190px, 56vw); }
    .hyralis-auth-brand-copy { padding: 18px max(20px, env(safe-area-inset-right)) 18px max(20px, env(safe-area-inset-left)); }
    .hyralis-auth-brand-heading { max-width: 350px; font-size: 23px; line-height: 1.14; }
    .hyralis-auth-brand-support { max-width: 330px; margin: 0 auto; font-size: 13.5px; }
    .hyralis-auth-stage { padding-right: max(16px, env(safe-area-inset-right)); padding-bottom: max(16px, env(safe-area-inset-bottom)); padding-left: max(16px, env(safe-area-inset-left)); }
    .hyralis-auth-card, .hyralis-auth-card.auth-card-login { padding: 24px 18px; border-radius: 18px; }
    .hyralis-auth-heading, .auth-card-login .hyralis-auth-heading { margin-bottom: 24px; }
    .hyralis-auth-eyebrow { margin-bottom: 12px; font-size: 12px; }
    .hyralis-auth-heading h1 { margin-bottom: 12px; font-size: 1.45rem; }
    .hyralis-auth-description { font-size: 15px; }
    .auth-card-login .hyralis-auth-description { display: none; }
    .hyralis-auth-card .form-label { font-size: 15px; }
    .auth-card-login .fv-row.mb-7 { margin-bottom: 20px !important; }
    .auth-card-login .fv-row.mb-4 { margin-bottom: 14px !important; }
    .hyralis-auth-actions { flex-direction: column; }
    .hyralis-auth-footer { flex-wrap: wrap; justify-content: center; gap: 0 14px; padding-top: 12px; text-align: center; font-size: 12px; }
    .hyralis-auth-footer-links { gap: 14px; }
    .hyralis-auth-footer a { min-height: 36px; }
}
@media (min-width: 992px) and (max-height: 700px) {
    .hyralis-auth-card { --auth-control-height: 50px; }
    .hyralis-auth-logo { top: 17%; width: clamp(300px, 28vw, 430px); }
    .hyralis-auth-brand-copy { top: 49%; }
    .hyralis-auth-brand-heading { max-width: 570px; font-size: clamp(1.8rem, 2.35vw, 2.35rem); }
    .hyralis-auth-brand-support { font-size: 1rem; }
    .hyralis-auth-stage { padding-top: 12px; padding-bottom: 12px; }
    .hyralis-auth-stage-content { min-height: 0; }
    .hyralis-auth-card, .hyralis-auth-card.auth-card-login { min-height: 0; padding: 12px 2rem; }
    .hyralis-auth-heading, .auth-card-login .hyralis-auth-heading { margin-bottom: 12px; }
    .hyralis-auth-eyebrow { margin-bottom: 8px; }
    .hyralis-auth-heading h1 { margin-bottom: 8px; font-size: 1.7rem; }
    .hyralis-auth-description { font-size: 1.05rem; line-height: 1.4; }
    .auth-card-login .fv-row.mb-7 { margin-bottom: 18px !important; }
    .auth-card-login .fv-row.mb-4 { margin-bottom: 12px !important; }
    .auth-card-login form > .d-flex.flex-stack { margin-bottom: 12px !important; }
    .auth-card-login form > p.mt-8 { margin-top: 12px !important; }
    .hyralis-auth-footer { padding: 0 2rem 4px; }
}

@media (min-width: 992px) and (min-height: 701px) and (max-height: 950px) {
    .hyralis-auth-stage { padding-top: clamp(28px, 8vh, 76px); padding-bottom: 24px; }
}

@media (max-width: 575.98px) and (max-height: 650px) {
    .hyralis-auth-brand { min-height: 104px; flex-basis: 104px; }
    .hyralis-auth-logo { width: min(160px, 52vw); margin-top: -6px; }
    .hyralis-auth-brand-copy { padding-top: 10px; padding-bottom: 12px; }
    .hyralis-auth-brand-heading { margin-bottom: 0; font-size: 22px; }
    .hyralis-auth-brand-support { display: none; }
    .hyralis-auth-card, .hyralis-auth-card.auth-card-login { padding: 20px 16px; }
    .hyralis-auth-heading, .auth-card-login .hyralis-auth-heading { margin-bottom: 18px; }
    .hyralis-auth-eyebrow { margin-bottom: 8px; }
    .hyralis-auth-heading h1 { margin-bottom: 8px; font-size: 1.4rem; }
}

@media (min-width: 1200px) and (min-height: 701px) {
    .auth-card-login .fv-row.mb-7 { margin-bottom: 31px !important; }
    .auth-card-login .fv-row.mb-4 { margin-bottom: 24px !important; }
}
@media (prefers-reduced-motion: reduce) {
    .hyralis-auth *, .hyralis-auth *::before, .hyralis-auth *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
