.auth-page {
    --auth-brand: #6129e0;
    --auth-brand-hover: #4b1cb8;
    --auth-accent: var(--auth-brand);
    --auth-accent-hover: var(--auth-brand-hover);
    --auth-page-bg: #fbf9ff;
    --auth-ink: #281e3a;
    --auth-soft: #756b85;
    --auth-line: #e5dfee;
    --auth-input: #fff;
    --auth-tab: #f0ebf8;
    background: var(--auth-page-bg);
}

[data-theme="dark"] .auth-page {
    --auth-page-bg: #17121f;
    --auth-ink: #f6f1ff;
    --auth-soft: #b6aac8;
    --auth-line: #42354f;
    --auth-input: #241c30;
    --auth-tab: #2a2038;
    --auth-accent: #ba98ff;
    --auth-accent-hover: #d2bbff;
}

.auth-page .auth-shell {
    --app-primary: var(--auth-accent);
    --auth-text: var(--auth-ink);
    --auth-muted: var(--auth-soft);
    --auth-label: var(--auth-ink);
    --auth-link: var(--auth-accent);
    display: grid;
    grid-template-columns: minmax(350px, .92fr) minmax(0, 1.08fr);
    min-height: 100vh;
    min-height: 100svh;
    padding: 14px;
    gap: 0;
    background: var(--auth-page-bg);
}

.auth-page .auth-aside {
    position: relative;
    display: flex;
    border-radius: 24px;
    background: radial-gradient(ellipse at 50% 18%, #b58affb3 0, transparent 48%), radial-gradient(ellipse at 100% 90%, #8a4ff566 0, transparent 55%), linear-gradient(155deg, #7137e9 0%, #5620c6 55%, #291052 100%);
    color: #fff;
    box-shadow: inset 0 1px 0 #ffffff30;
    overflow: hidden;
}

.auth-page .auth-aside::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: radial-gradient(#fff3 .7px, transparent .7px);
    background-size: 26px 26px;
    opacity: .2;
    mask-image: linear-gradient(180deg, transparent, #000 40%, transparent);
    pointer-events: none;
}

.auth-page .auth-aside::after {
    content: "";
    position: absolute;
    inset: 12px;
    border: 1px solid #ffffff12;
    border-radius: 16px;
    pointer-events: none;
}

.auth-page .auth-aside-inner {
    position: relative;
    width: 100%;
    padding: 36px clamp(28px, 4.4vw, 76px) 26px;
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto auto minmax(0, 1fr) auto;
    align-items: start;
    gap: 28px;
    text-align: center;
}

.auth-page .auth-aside-logo { grid-row: 2; justify-self: center; align-self: center; }
.auth-page .auth-aside-logo img { display: block; width: 200px; max-height: 100px; max-width: 100%; padding: 0; background: transparent; border-radius: 0; box-shadow: none; filter: drop-shadow(0 8px 18px #27104d20); }
.auth-page .auth-aside-copy { grid-row: 3; justify-self: center; max-width: 430px; }
.auth-kicker { display: flex; justify-content: center; align-items: center; gap: 9px; width: fit-content; margin: 0 auto; padding: 8px 13px; border: 1px solid #ffffff26; border-radius: 50px; background: #ffffff0a; font-size: 9px; font-weight: 500; letter-spacing: .18em; color: #f4edff; }
.auth-kicker > span { width: 6px; height: 6px; border-radius: 50%; background: #e5d4ff; box-shadow: 0 0 0 4px #e5d4ff20; }
.auth-page .auth-aside-copy h2 { margin: 22px 0 18px; font-size: clamp(38px, 3.8vw, 58px); line-height: 1.09; letter-spacing: -.05em; font-weight: 600; text-wrap: balance; }
.auth-page .auth-aside-copy p { max-width: 330px; margin: 0 auto; font-size: 13px; line-height: 1.9; color: #eee3ff; text-wrap: pretty; }
.auth-page .auth-aside-copy::after { content: ""; display: block; width: 48px; height: 2px; margin: 24px auto 0; border-radius: 2px; background: linear-gradient(90deg, transparent, #d4b8ff, transparent); }
.auth-aside-footer { grid-row: 5; display: flex; justify-content: center; align-items: center; width: 100%; padding-top: 19px; border-top: 1px solid #ffffff20; font-size: 10px; letter-spacing: .04em; color: #e9dcff; }

.auth-page .auth-main { position: relative; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: space-between; padding: 20px clamp(24px, 4.5vw, 80px) 12px; gap: 34px; }
.auth-topbar { display: flex; justify-content: space-between; align-items: center; width: 100%; }
.auth-back { display: inline-flex; align-items: center; gap: 9px; color: var(--auth-soft); font-size: 11px; }
.auth-back:hover { color: var(--auth-ink); }
.auth-page .auth-theme-toggle { position: static; width: 36px; height: 36px; border-radius: 50%; background: var(--auth-input); border-color: var(--auth-line); color: var(--auth-ink); }
.auth-page .auth-form-col { width: min(400px, 100%); padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; color: var(--auth-ink); animation: auth-arrive .5s ease both; }
.auth-page .auth-form-col-wide { width: min(520px, 100%); }
.auth-portal-label { display: flex; align-items: center; gap: 7px; margin-bottom: 22px; color: var(--auth-soft); font-size: 10px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; }
.auth-portal-label > span { width: 6px; height: 6px; background: var(--auth-accent); border-radius: 50%; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; padding: 4px; gap: 4px; margin-bottom: 28px; border: 1px solid var(--auth-line); border-radius: 11px; background: var(--auth-tab); }
.auth-page .auth-tabs a { display: block; padding: 10px 8px; border-radius: 7px; text-align: center; color: var(--auth-soft); font-size: 12px; font-weight: 500; }
.auth-page .auth-tabs a[aria-current="page"] { color: var(--auth-ink); background: var(--auth-input); box-shadow: 0 2px 5px #2b16470c; }
.auth-page .auth-form-col h1 { margin: 0 0 10px; color: var(--auth-ink); font-size: clamp(27px, 2.6vw, 34px); font-weight: 600; letter-spacing: -.045em; line-height: 1.2; overflow-wrap: anywhere; }
.auth-page .auth-form-col .lead-lite { margin-bottom: 28px; font-size: 13px; line-height: 1.8; color: var(--auth-soft); }
.auth-page .auth-form-col .form-label { color: var(--auth-ink); font-size: 12px; font-weight: 500; margin-bottom: 8px; }
.auth-page .auth-form-col .form-control, .auth-page .auth-form-col .form-select { min-height: 49px; padding: 12px 14px; border: 1px solid var(--auth-line); border-radius: 9px; color: var(--auth-ink); background: var(--auth-input); font-size: 14px; box-shadow: 0 2px 3px #2b164703; color-scheme: light; }
[data-theme="dark"] .auth-page .form-control { color-scheme: dark; }
.auth-page .auth-form-col .form-control::placeholder { color: var(--auth-soft); opacity: .8; }
.auth-page .auth-form-col .form-control:focus { border-color: var(--auth-accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--auth-accent) 15%, transparent); }
.auth-page .auth-form-col .form-control.is-invalid { border-color: #dc3545; }
.auth-page .auth-form-col .btn-app-primary { gap: 12px; min-height: 49px; background: var(--auth-brand); color: #fff; border: 1px solid var(--auth-brand); border-radius: 9px; font-size: 12px; font-weight: 500; box-shadow: 0 5px 12px #6129e020; }
.auth-page .auth-form-col .btn-app-primary:hover { background: var(--auth-brand-hover); border-color: var(--auth-brand-hover); }
.auth-form-col .btn-app-primary i { font-size: 15px; }
.auth-password-label { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.auth-password-label a { font-size: 11px; }
.auth-page .auth-form-col .auth-foot { margin-top: 23px; font-size: 12px; line-height: 1.8; color: var(--auth-soft); }
.auth-foot a { font-weight: 500; }
.auth-field-note { display: block; margin-top: 7px; color: var(--auth-soft); font-size: 10px; line-height: 1.7; }
.auth-optional { color: var(--auth-soft); font-weight: 400; }
.auth-form-note { margin: 18px 0 0; color: var(--auth-soft); text-align: center; font-size: 10px; line-height: 1.8; }
.auth-registration-steps { display: flex; gap: 16px; list-style: none; padding: 0; margin: 0 0 24px; color: var(--auth-soft); font-size: 9px; }
.auth-registration-steps li { display: flex; align-items: center; gap: 6px; }
.auth-registration-steps span { display: grid; place-items: center; width: 21px; height: 21px; border: 1px solid var(--auth-line); border-radius: 50%; font-size: 9px; }
.auth-registration-steps [aria-current="step"] { color: var(--auth-accent); }
.auth-registration-steps [aria-current="step"] span { background: var(--auth-brand); color: #fff; border-color: var(--auth-brand); }
.auth-page-footer { display: flex; justify-content: space-between; align-items: center; gap: 14px; width: 100%; color: var(--auth-soft); font-size: 9px; }
.auth-page-footer > span, .auth-page-footer > div { display: flex; align-items: center; gap: 8px; }
.auth-page-footer i { font-size: 13px; }
.auth-page a:focus-visible, .auth-page button:focus-visible { outline: 2px solid var(--auth-accent); outline-offset: 4px; }
.auth-page .auth-aside a:focus-visible { outline-color: #fff; }
.auth-skip-link { position: fixed; top: -100px; left: 20px; z-index: 20; padding: 12px 18px; background: var(--auth-input); color: var(--auth-ink); border-radius: 8px; }
.auth-skip-link:focus { top: 15px; }
@keyframes auth-arrive { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }

@media (min-width: 1500px) {
    .auth-page .auth-shell { max-width: 1600px; margin: 0 auto; }
    .auth-page .auth-aside-inner { padding-top: 48px; padding-bottom: 36px; }
}

@media (max-width: 1050px) {
    .auth-page .auth-aside-inner { padding: 28px; }
    .auth-page .auth-main { padding-right: 26px; padding-left: 36px; }
}

@media (max-width: 800px) {
    .auth-page .auth-shell { grid-template-columns: 1fr; padding: 10px; }
    .auth-page .auth-aside { border-radius: 18px; }
    .auth-page .auth-aside::after { inset: 6px; border-radius: 12px; }
    .auth-page .auth-aside-copy::after { display: none; }
    .auth-page .auth-aside-inner { padding: 22px 26px; gap: 20px; }
    .auth-page .auth-aside-logo img { max-height: 43px; }
    .auth-page .auth-aside-copy { max-width: 540px; }
    .auth-page .auth-aside-copy h2 { font-size: 30px; margin: 10px 0; }
    .auth-page .auth-aside-copy p { max-width: 470px; font-size: 11px; }
    .auth-kicker { font-size: 8px; }
    .auth-aside-footer { display: none; }
    .auth-page .auth-main { padding: 19px 18px 12px; gap: 28px; }
    .auth-portal-label { margin-bottom: 16px; }
    .auth-tabs { margin-bottom: 24px; }
    .auth-page-footer { max-width: 520px; margin-top: 8px; }
}

@media (max-width: 400px) {
    .auth-page .auth-aside-inner { padding: 20px; }
    .auth-page .auth-aside-copy h2 { font-size: 26px; }
    .auth-page .auth-main { padding-right: 10px; padding-left: 10px; }
    .auth-page-footer { flex-wrap: wrap; justify-content: center; }
    .auth-registration-steps { gap: 10px; }
}

@media (max-width: 560px) {
    .auth-page .auth-aside-inner { flex-direction: row; align-items: center; gap: 18px; padding: 20px; }
    .auth-page .auth-aside-logo { flex: none; }
    .auth-page .auth-aside-logo img { max-width: 86px; }
    .auth-page .auth-aside-copy h2 { margin: 0; font-size: 21px; letter-spacing: -.04em; }
    .auth-page .auth-aside-copy p, .auth-kicker { display: none; }
    .auth-page .auth-form-col .form-control, .auth-page .auth-form-col .form-select { font-size: 16px; }
}

@media (min-width: 801px) and (max-height: 850px) {
    .auth-page .auth-shell { padding: 10px; }
    .auth-page .auth-aside-inner { padding: 24px 36px; gap: 20px; }
    .auth-page .auth-aside-copy h2 { font-size: clamp(32px, 3vw, 42px); margin: 14px 0; }
    .auth-page .auth-aside-copy p { font-size: 12px; line-height: 1.7; }
    .auth-page .auth-main { padding-top: 8px; padding-bottom: 8px; gap: 14px; }
    .auth-portal-label { margin-bottom: 12px; }
    .auth-tabs { margin-bottom: 18px; }
    .auth-page .auth-form-col h1 { font-size: 28px; }
    .auth-page .auth-form-col .lead-lite { margin-bottom: 18px; font-size: 12px; }
    .auth-page .auth-form-col .form-control { min-height: 44px; padding: 10px 12px; }
    .auth-page .auth-form-col .btn-app-primary { min-height: 44px; }
    .auth-page .auth-form-col .auth-foot { margin-top: 16px; }
    .auth-registration-steps { margin-bottom: 16px; }
    .auth-form-note { margin-top: 10px; }
}

@media (min-width: 801px) and (max-height: 700px) {
    .auth-page .auth-aside-inner { gap: 14px; padding-top: 20px; padding-bottom: 20px; }
    .auth-page .auth-aside-copy h2 { font-size: 32px; }
    .auth-page .auth-form-col h1 { font-size: 25px; }
    .auth-page .auth-form-col .lead-lite { margin-bottom: 12px; }
    .auth-page .auth-form-col .mb-3 { margin-bottom: 12px !important; }
    .auth-page .auth-form-col .mb-4 { margin-bottom: 16px !important; }
    .auth-tabs { margin-bottom: 14px; }
    .auth-portal-label { margin-bottom: 10px; }
    .auth-page .auth-form-col .auth-foot { margin-top: 12px; }
}

@media (max-width: 800px) {
    .auth-page .auth-shell { display: flex; flex-direction: column; gap: 0; }
    .auth-page .auth-aside-inner { display: flex; flex-direction: row; align-items: center; gap: 18px; padding: 16px 20px; text-align: left; }
    .auth-page .auth-aside-logo { flex: none; }
    .auth-page .auth-aside-logo img { max-width: 86px; }
    .auth-page .auth-aside-copy h2 { margin: 0; font-size: 21px; letter-spacing: -.04em; }
    .auth-page .auth-aside-copy p, .auth-kicker { display: none; }
    .auth-page .auth-main { flex: 1; padding-top: 12px; padding-bottom: 4px; gap: 16px; }
    .auth-page .auth-form-col h1 { font-size: 25px; }
    .auth-page .auth-form-col .lead-lite { margin-bottom: 16px; font-size: 12px; }
    .auth-portal-label { margin-bottom: 10px; }
    .auth-tabs { margin-bottom: 18px; }
    .auth-page .auth-form-col .row { --bs-gutter-y: 12px; }
    .auth-page .auth-form-col .row > .col-sm-6, .auth-page .auth-form-col .row > .col-md-6 { width: 50%; }
    .auth-page .auth-form-col .form-control { min-height: 44px; padding: 10px; }
    .auth-page .auth-form-col .form-label { font-size: 11px; }
    .auth-page .auth-form-col .mb-3 { margin-bottom: 12px !important; }
    .auth-page .auth-form-col .mb-4 { margin-bottom: 16px !important; }
    .auth-page .auth-form-col .btn-app-primary { min-height: 44px; }
    .auth-page .auth-form-col .auth-foot { margin-top: 14px; font-size: 11px; }
    .auth-page-footer { margin-top: 0; }
    .auth-registration-steps { margin-bottom: 16px; }
    .auth-form-note { margin-top: 10px; }
    .auth-page .auth-form-col #preferred_contact_at { min-width: 0; width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
    .auth-page .auth-form-col { animation: none; }
    .auth-page, .auth-page * { transition: none; }
}
