:root {
    --auth-blue: #0b72e7;
    --auth-blue-dark: #075fc4;
    --auth-black: #0a0a0a;
    --auth-white: #ffffff;
    --auth-page: #f7f7f7;
    --auth-line: #dedede;
    --auth-muted: #666666;
    --auth-faint: #8a8a8a;
    --auth-radius: 7px;
}

* { box-sizing: border-box; }

html { min-width: 320px; background: var(--auth-page); }

body.auth-body {
    margin: 0;
    min-height: 100vh;
    min-height: 100dvh;
    padding: 0;
    display: grid;
    place-items: center;
    overflow-x: hidden;
    color: var(--auth-black);
    background: var(--auth-page);
    font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.5;
}

body.auth-split-body { display: block; }

.auth-split {
    width: 100vw;
    max-width: none;
    min-height: 100vh;
    min-height: 100dvh;
    display: grid;
    grid-template-columns: minmax(300px, 38%) minmax(0, 62%);
    overflow-y: auto;
    border: 0;
    border-radius: 7px;
    background: var(--auth-white);
    box-shadow: none;
}

.auth-aside {
    position: relative;
    min-width: 0;
    padding: clamp(30px, 4vw, 54px);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
    color: var(--auth-white);
    background: var(--auth-blue);
}

.auth-aside::after {
    content: "";
    position: absolute;
    right: -150px;
    bottom: -150px;
    width: 340px;
    height: 340px;
    border: 54px solid rgb(255 255 255 / 10%);
    border-radius: 7px;
    pointer-events: none;
}

.auth-aside-brand,
.auth-aside-copy,
.auth-aside-foot { position: relative; z-index: 1; }

.auth-aside-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--auth-white);
    font-size: 0.945rem;
    font-weight: 700;
}

.auth-logo {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border: 1px solid rgb(255 255 255 / 35%);
    border-radius: 7px;
    background: rgb(255 255 255 / 13%);
}

.auth-logo svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; }

.auth-aside-copy { max-width: 34ch; }
.auth-aside-copy h2 { margin: 0 0 12px; color: inherit; font-size: clamp(1.45rem, 2.2vw, 2rem); line-height: 1.16; letter-spacing: -.035em; }
.auth-aside-copy p { margin: 0; color: rgb(255 255 255 / 82%); font-size: 0.987rem; }
.auth-aside-points { margin-top: 28px; display: grid; gap: 14px; }
.auth-aside-point { display: flex; align-items: center; gap: 10px; color: var(--auth-white); font-size: 0.903rem; font-weight: 600; }
.auth-aside-point::before { content: "\2713"; font-size: 1.05rem; }
.auth-aside-foot { display: flex; align-items: center; gap: 8px; color: rgb(255 255 255 / 85%); font-size: 0.819rem; }

.auth-main {
    min-width: 0;
    padding: clamp(34px, 6vw, 76px);
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--auth-white);
}

.auth-main-scroll { min-height: 0; align-items: flex-start; overflow-x: hidden; overflow-y: auto; scrollbar-gutter: stable; }
.auth-main-inner { width: min(100%, 480px); }
.auth-main-inner.auth-wide { width: min(100%, 660px); }

body.auth-body .brand { margin: 0 0 26px; text-align: left; }
body.auth-body .brand .brand-mark { display: none; }
body.auth-body .brand h1 { margin: 0; color: var(--auth-black); font-size: clamp(1.65rem, 3vw, 2.25rem); line-height: 1.13; letter-spacing: -.045em; }
body.auth-body .brand h1 span { color: inherit; }
body.auth-body .brand p { margin: 8px 0 0; color: var(--auth-muted); font-size: 0.945rem; }

body.auth-body .card,
body.auth-body .success-card {
    width: 100%;
    max-width: none;
    padding: 0;
    border: 0;
    border-radius: 7px;
    background: transparent;
    box-shadow: none;
}

body.auth-body .trial-pill {
    margin: 0 0 20px;
    padding: 6px 10px;
    border: 1px solid rgb(11 114 231 / 35%);
    border-radius: 7px;
    color: var(--auth-blue-dark);
    background: rgb(11 114 231 / 7%);
}

.auth-split-registration .auth-aside { padding-block: clamp(24px, 3vw, 42px); }
.auth-split-registration .auth-main { padding: 12px clamp(30px, 5vw, 68px); }
.auth-split-registration .auth-main-inner { margin: auto 0; }

@media (min-width: 700px) {
    .auth-split-registration .auth-main { overflow: hidden; scrollbar-gutter: auto; }
}
.auth-split-registration .brand { margin-bottom: 12px; }
.auth-split-registration .brand h1 { font-size: clamp(1.55rem, 2.5vw, 2rem); }
.auth-split-registration .brand p { margin-top: 4px; }
.auth-split-registration .trial-pill { margin-bottom: 10px; padding-block: 4px; }
.auth-split-registration .section-label { margin: 12px 0 7px; }
.auth-split-registration .plans { gap: 8px; }
.auth-split-registration .plan-option { min-height: 66px; padding: 8px; }
.auth-split-registration .plan-price { margin-top: 2px; }
.auth-split-registration .fg { margin-bottom: 8px; }
.auth-split-registration .fg label { margin-bottom: 3px; }
.auth-split-registration .fg input { min-height: 40px; padding-block: 7px; }
.auth-split-registration .country-select { min-height: 40px; padding-block: 7px; }
.auth-split-registration .workspace-lock { margin-top: 3px; }
.auth-split-registration .btn-submit { min-height: 44px; margin-top: 8px; padding: 9px; }
.auth-split-registration .footer-link { margin-top: 10px; }
.phone-input-group {
    display: flex;
    align-items: stretch;
    width: 100%;
    background: var(--auth-page);
    border: 1px solid var(--auth-line);
    border-radius: 11px;
    transition: border-color .15s, box-shadow .15s, background .15s;
    overflow: hidden;
}
.phone-input-group:focus-within {
    border-color: var(--auth-blue);
    background: var(--auth-white);
    box-shadow: 0 0 0 3px rgba(11, 114, 231, .12);
}
.country-select-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    flex-shrink: 0;
    border-right: 1px solid var(--auth-line);
    background: #f1f5f9;
    transition: background .13s;
}
.country-select-wrapper:hover {
    background: #e2e8f0;
}
.country-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    border: none;
    background: transparent;
    padding: 0 24px 0 10px;
    height: 100%;
    font-size: 0.945rem;
    font-weight: 600;
    color: var(--auth-black);
    cursor: pointer;
    outline: none;
}
.country-select-chevron {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    width: 0;
    height: 0;
    border-left: 3.5px solid transparent;
    border-right: 3.5px solid transparent;
    border-top: 4.5px solid #64748b;
}
.phone-input-group input[type="tel"] {
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    border-radius: 11px !important;
    padding: 8px 12px !important;
    font-size: 0.945rem !important;
    color: var(--auth-black) !important;
    outline: none !important;
    flex: 1;
    min-width: 0;
}
.registration-admin-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }

@media (min-width: 700px) and (max-width: 1050px) {
    .registration-admin-grid { display: grid !important; grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 14px; }
    .registration-admin-grid .registration-username { grid-column: 1 / -1; }
    .registration-admin-grid .registration-username + .fg { grid-column: 1; }
    .registration-admin-grid .registration-username + .fg + .fg { grid-column: 2; }
}

body.auth-body .section-label {
    margin: 25px 0 12px;
    color: var(--auth-black);
    font-size: 0.861rem;
    font-weight: 700;
    letter-spacing: .08em;
}
body.auth-body .section-label::after { background: var(--auth-line); }
body.auth-body .section-label:first-child { margin-top: 0; }

body.auth-body .fg { margin-bottom: 15px; }
body.auth-body .fg label,
body.auth-body main.card > label {
    margin: 0 0 6px;
    display: block;
    color: var(--auth-black);
    font-size: 0.861rem;
    font-weight: 650;
    letter-spacing: 0;
    text-transform: none;
}

body.auth-body .field-heading { margin-bottom: 6px; }
body.auth-body .field-heading label { margin: 0; }
body.auth-body .forgot-link,
body.auth-body a { color: var(--auth-blue-dark); }

body.auth-body .fg input,
body.auth-body input.field,
body.auth-body main.card > input,
body.auth-body .auth-input {
    width: 100%;
    min-height: 48px;
    padding: 0 13px;
    border: 1px solid #cfcfcf;
    border-radius: 11px;
    outline: 0;
    color: var(--auth-black);
    background: var(--auth-white);
    font: inherit;
    font-size: 0.945rem;
    letter-spacing: 0;
    transition: border-color .15s, box-shadow .15s;
}

body.auth-body .fg input:focus,
body.auth-body input.field:focus,
body.auth-body main.card > input:focus {
    border-color: var(--auth-blue);
    box-shadow: 0 0 0 3px rgb(11 114 231 / 13%);
}

body.auth-body .fg input[readonly] { color: #444; background: #f4f4f4; border-color: #d6d6d6; }
body.auth-body input::placeholder { color: var(--auth-faint); }
body.auth-body .workspace-lock { color: var(--auth-muted); }
body.auth-body .workspace-lock::before { filter: grayscale(1); }

body.auth-body .remember-row,
body.auth-body .remember { color: var(--auth-muted); }
body.auth-body input[type="checkbox"],
body.auth-body input[type="radio"] { accent-color: var(--auth-blue); }

body.auth-body .btn-submit,
body.auth-body .btn,
body.auth-body a.btn,
body.auth-body .btn-login {
    min-height: 48px;
    border: 0;
    border-radius: 11px;
    color: var(--auth-white);
    background: var(--auth-blue);
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: background .15s, transform .15s;
}
body.auth-body .btn-submit:hover,
body.auth-body .btn:hover,
body.auth-body a.btn:hover,
body.auth-body .btn-login:hover { color: var(--auth-white); background: var(--auth-blue-dark); }
body.auth-body .btn-submit:active,
body.auth-body .btn:active { transform: translateY(1px); }

body.auth-body .footer-link,
body.auth-body .footer,
body.auth-body .back { margin-top: 21px; color: var(--auth-muted); text-align: center; font-size: 0.84rem; }
body.auth-body .divider { height: 1px; margin: 24px 0 0; overflow: hidden; color: transparent; background: var(--auth-line); }

body.auth-body .plans { gap: 10px; }
body.auth-body .plan-option { min-height: 88px; border-color: var(--auth-line); border-radius: 12px; background: var(--auth-white); }
body.auth-body .plan-option:hover { border-color: rgb(11 114 231 / 50%); background: var(--auth-white); }
body.auth-body .plan-option.selected { border-color: var(--auth-blue); background: rgb(11 114 231 / 6%); box-shadow: inset 0 0 0 1px var(--auth-blue); }
body.auth-body .plan-name { color: var(--auth-black); }
body.auth-body .plan-option.selected .plan-name { color: var(--auth-black); }
body.auth-body .plan-price,
body.auth-body .plan-users { color: var(--auth-muted); }

body.auth-body .msg-error,
body.auth-body .error,
body.auth-body .msg.error {
    padding: 11px 13px;
    border: 1px solid var(--auth-black);
    border-radius: 7px;
    color: var(--auth-black);
    background: var(--auth-white);
    font-size: 0.945rem;
}

body.auth-body .msg,
body.auth-body .ok,
body.auth-body .msg.ok {
    padding: 11px 13px;
    border: 1px solid rgb(11 114 231 / 45%);
    border-radius: 7px;
    color: var(--auth-black);
    background: rgb(11 114 231 / 6%);
}

body.auth-body .secondary { color: var(--auth-blue-dark); background: var(--auth-white); border: 1px solid var(--auth-blue); }
body.auth-body .details,
body.auth-body .workspace { border: 1px solid var(--auth-line); border-radius: 11px; color: var(--auth-black); background: #f7f7f7; }
body.auth-body .success-icon { color: var(--auth-blue); background: rgb(11 114 231 / 7%); border-color: rgb(11 114 231 / 30%); }
body.auth-body .logout-icon { color: var(--auth-white); background: var(--auth-blue); box-shadow: 0 12px 28px rgb(11 114 231 / 22%); }
body.auth-body .progress-track { background: rgb(11 114 231 / 10%); }
body.auth-body .progress-bar { background: var(--auth-blue); }
body.auth-body .logout-container a { color: var(--auth-blue-dark); background: var(--auth-white); border-color: var(--auth-line); }

.auth-centered {
    width: min(100%, 480px);
    padding: clamp(28px, 5vw, 42px);
    border: 1px solid var(--auth-line);
    border-top: 4px solid var(--auth-blue);
    border-radius: 7px;
    background: var(--auth-white);
    box-shadow: 0 18px 55px rgb(0 0 0 / 8%);
}

body.auth-body .card.auth-centered,
body.auth-body main.auth-centered {
    width: min(100%, 480px);
    max-width: 480px;
    padding: clamp(28px, 5vw, 42px);
    border: 1px solid var(--auth-line);
    border-top: 4px solid var(--auth-blue);
    border-radius: 7px;
    background: var(--auth-white);
    box-shadow: 0 18px 55px rgb(0 0 0 / 8%);
}

body.auth-body .auth-workspace-form {
    width: 100%;
    max-width: none;
    padding: 0;
    border: 0;
    border-radius: 7px;
    background: transparent;
    box-shadow: none;
}

body.auth-body .auth-workspace-form .mark { display: none; }
body.auth-body .auth-workspace-form h1 { font-size: clamp(1.65rem, 3vw, 2.25rem); }
body.auth-body .auth-workspace-form .fg input { min-height: 48px; }

.auth-workspace-kicker {
    margin-bottom: 10px;
    color: var(--auth-blue-dark);
    font-size: 0.861rem;
    font-weight: 750;
    letter-spacing: .08em;
    text-transform: uppercase;
}

body.auth-body .auth-workspace-form .sub { margin-bottom: 18px; }

.auth-workspace-identity {
    width: 100%;
    margin: 0 0 22px;
    padding: 12px 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    border: 1px solid rgb(11 114 231 / 35%);
    border-radius: 7px;
    background: rgb(11 114 231 / 5%);
}

.auth-workspace-identity-icon {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 7px;
    color: var(--auth-white);
    background: var(--auth-blue);
}

.auth-workspace-identity-copy {
    min-width: 0;
    display: grid;
    gap: 2px;
}

.auth-workspace-identity-copy strong,
.auth-workspace-identity-copy small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.auth-workspace-identity-copy strong { color: var(--auth-black); font-size: 0.945rem; }
.auth-workspace-identity-copy small { color: var(--auth-muted); font-size: 0.861rem; }

body.auth-body .auth-workspace-footer {
    display: grid;
    justify-items: center;
    gap: 12px;
}

body.auth-body .auth-switch-workspace {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--auth-muted);
    font-size: 0.861rem;
    font-weight: 600;
    text-decoration: none;
}

body.auth-body .auth-switch-workspace:hover { color: var(--auth-blue-dark); text-decoration: underline; text-underline-offset: 3px; }

.auth-centered::before {
    content: "ComingSaaS";
    display: block;
    margin-bottom: 25px;
    color: var(--auth-blue);
    font-size: 0.945rem;
    font-weight: 750;
    letter-spacing: .02em;
}

body.auth-recovery .auth-centered::before { content: "Account recovery"; }
body.auth-workspace-recovery .auth-centered::before { content: "Workspace recovery"; }
body.auth-verification .auth-centered::before { content: "Email verification"; }
body.auth-password-reset .auth-centered::before { content: "Password security"; }
body.auth-session .auth-centered::before { content: "Session security"; }
body.auth-workspace-page .auth-centered::before { content: "Business workspace"; }

body.auth-body main.card h1,
body.auth-body .auth-centered h1 { margin: 0 0 8px; color: var(--auth-black); font-size: clamp(1.45rem, 4vw, 1.8rem); line-height: 1.2; letter-spacing: -.035em; }
body.auth-body main.card p,
body.auth-body .auth-centered p { color: var(--auth-muted); }

body.auth-body :focus-visible { outline: 3px solid rgb(11 114 231 / 22%); outline-offset: 3px; }

.auth-toast-region {
    position: fixed;
    z-index: 10000;
    top: 18px;
    right: 18px;
    width: min(390px, calc(100vw - 32px));
    display: grid;
    gap: 10px;
    pointer-events: none;
}

.auth-toast {
    min-height: 58px;
    padding: 12px 12px 12px 14px;
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr) 30px;
    align-items: center;
    gap: 10px;
    border: 1px solid var(--auth-line);
    border-radius: 11px;
    color: var(--auth-black);
    background: var(--auth-white);
    box-shadow: 0 16px 42px rgb(0 0 0 / 15%);
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity .18s, transform .18s;
    pointer-events: auto;
}

.auth-toast-error { border-color: #fca5a5; }
.auth-toast.is-visible { opacity: 1; transform: none; }
.auth-toast.is-leaving { opacity: 0; transform: translateY(-6px); }
.auth-toast-icon { width: 27px; height: 27px; display: grid; place-items: center; border-radius: 11px; color: var(--auth-white); background: var(--auth-blue); font-size: 0.819rem; font-weight: 800; }
.auth-toast-error .auth-toast-icon { background: var(--auth-black); }
.auth-toast-message { min-width: 0; font-size: 0.945rem; font-weight: 600; line-height: 1.42; }
.auth-toast-close { width: 30px; height: 30px; padding: 0; border: 0; border-radius: 11px; color: var(--auth-muted); background: transparent; font: 500 1.2rem/1 sans-serif; cursor: pointer; }
.auth-toast-close:hover { color: var(--auth-black); background: #f2f2f2; }

@media (max-width: 560px) {
    .auth-toast-region { top: 10px; right: 10px; left: 10px; width: auto; }
}

@media (max-width: 699px) {
    body.auth-body { padding: 0; place-items: stretch; }
    .auth-split { width: 100%; height: auto; min-height: 100dvh; grid-template-columns: 1fr; border: 0; border-radius: 7px; box-shadow: none; }
    .auth-aside { min-height: auto; padding: 20px 24px; }
    .auth-aside-copy, .auth-aside-foot { display: none; }
    .auth-aside::after { width: 150px; height: 150px; right: -80px; bottom: -105px; border-width: 28px; }
    .auth-main { padding: 38px 24px 48px; align-items: flex-start; }
    .auth-main-scroll { overflow: visible; }
    .auth-split-registration .auth-main { padding: 30px 18px 40px; }
    .auth-split-registration .brand { margin-bottom: 26px; }
    .auth-split-registration .trial-pill { margin-bottom: 20px; }
    .auth-split-registration .section-label { margin: 25px 0 12px; }
    .auth-split-registration .plan-option { min-height: 58px; }
    .auth-split-registration .fg { margin-bottom: 15px; }
    .auth-split-registration .fg label { margin-bottom: 6px; }
    .auth-split-registration .fg input { min-height: 48px; }
    .auth-split-registration .btn-submit { min-height: 48px; margin-top: 18px; }
    .auth-split-registration .footer-link { margin-top: 18px; }
    body.auth-body .row2,
    body.auth-body .registration-admin-grid { display: grid !important; grid-template-columns: 1fr !important; gap: 0; }
    body.auth-body .registration-admin-grid > .fg { grid-column: 1 !important; }
}

@media (min-width: 700px) and (max-height: 640px) {
}

@media (min-width: 700px) and (min-height: 641px) and (max-height: 740px) {
    .auth-split-registration .auth-main { padding-block: 12px; }
    .auth-split-registration .brand h1 { font-size: 1.523rem; }
    .auth-split-registration .brand p { font-size: 0.819rem; }
    .auth-split-registration .trial-pill { margin-bottom: 6px; }
    .auth-split-registration .section-label { margin: 8px 0 5px; }
    .auth-split-registration .plan-option { min-height: 54px; padding: 5px 8px; }
    .auth-split-registration .plan-price,
    .auth-split-registration .plan-users { margin-top: 0; font-size: 0.798rem; }
    .auth-split-registration .fg { margin-bottom: 5px; }
    .auth-split-registration .fg input { min-height: 36px; padding-block: 5px; }
    .auth-split-registration .workspace-lock { font-size: 0.798rem; }
    .auth-split-registration .btn-submit { min-height: 39px; margin-top: 5px; }
}

@media (min-width: 700px) and (min-height: 741px) and (max-height: 800px) {
}

@media (min-width: 700px) and (min-height: 801px) and (max-height: 900px) {
}

@media (min-width: 700px) and (min-height: 901px) and (max-height: 1050px) {
}

@media (max-width: 560px) {
    body.auth-body:not(.auth-split-body) { padding: 14px; place-items: center; }
    .auth-aside { padding: 17px 18px; }
    .auth-logo { width: 36px; height: 36px; border-radius: 11px; }
    .auth-main { padding: 30px 18px 40px; }
    body.auth-body .row2 { grid-template-columns: 1fr; gap: 0; }
    body.auth-body .plans { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
    body.auth-body .plan-option {
        min-width: 0;
        min-height: 72px;
        margin-bottom: 0;
        padding: 8px 4px;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 1px;
        text-align: center;
        touch-action: manipulation;
    }
    body.auth-body .plan-name { width: 100%; font-size: 0.819rem; }
    body.auth-body .plan-price { margin-top: 1px; font-size: 0.798rem; white-space: nowrap; }
    body.auth-body .plan-users { margin-top: 0; font-size: 0.798rem; white-space: nowrap; }
    body.auth-body .auth-centered { padding: 27px 20px; }
}

@media (max-width: 350px) {
    body.auth-body .plans { gap: 4px; }
    body.auth-body .plan-option { min-height: 68px; padding-inline: 2px; }
    body.auth-body .plan-name { font-size: 0.861rem; }
    body.auth-body .plan-price,
    body.auth-body .plan-users { font-size: 0.798rem; }
}

@media (prefers-reduced-motion: reduce) {
    body.auth-body *, body.auth-body *::before, body.auth-body *::after { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}
