.onboarding-page {
    min-height: 100vh;
    background: #f5f8fc;
    color: #172335;
}

.onboarding-page .site-header {
    position: relative;
    background: rgba(255, 255, 255, 0.96);
    border-bottom: 1px solid #e2e8f0;
}

.auth-exit {
    color: #617087;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
}

.auth-exit:hover {
    color: #1557c0;
}

.onboarding-main {
    min-height: calc(100vh - 72px);
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 48px 20px 72px;
}

.onboarding-container {
    width: 100%;
    max-width: 700px;
}

.onboarding-card {
    overflow: hidden;
    width: 100%;
    background: #fff;
    border: 1px solid #dce5f0;
    border-radius: 12px;
    box-shadow: 0 18px 45px rgba(21, 61, 112, 0.07);
}

.card-header {
    padding: 38px 42px 30px;
    border-bottom: 1px solid #e6edf5;
    background: #fbfcfe;
}

.card-header h1 {
    margin: 0 0 10px;
    color: #172335;
    font-size: 28px;
    line-height: 1.15;
    letter-spacing: -0.7px;
}

.card-description {
    max-width: 560px;
    margin: 0 0 25px;
    color: #65748a;
    font-size: 14px;
    line-height: 1.65;
}

.onboarding-progress {
    margin: 0;
}

.progress-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 9px;
    color: #718097;
    font-size: 11px;
    font-weight: 700;
}

.progress-track {
    width: 100%;
    height: 6px;
    overflow: hidden;
    border-radius: 999px;
    background: #e3eaf3;
}

.progress-fill {
    width: 20%;
    height: 100%;
    border-radius: inherit;
    background: #1557c0;
    transition: width 0.25s ease;
}

.card-body {
    padding: 38px 42px 32px;
}

.signup-step {
    display: none;
}

.signup-step.active {
    display: block;
}

.signup-step[hidden] {
    display: none !important;
}

.step-eyebrow {
    color: #1557c0;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1px;
}

.signup-step h1 {
    margin: 10px 0 11px;
    color: #172335;
    font-size: 27px;
    line-height: 1.15;
    letter-spacing: -0.7px;
}

.step-description {
    max-width: 560px;
    margin: 0 0 28px;
    color: #65748a;
    font-size: 14px;
    line-height: 1.65;
}

.signup-step .field {
    margin-bottom: 19px;
}

.signup-step .field > label {
    display: block;
    margin-bottom: 8px;
    color: #344258;
    font-size: 13px;
    font-weight: 700;
}

.signup-step .field label span {
    margin-left: 5px;
    color: #8a98aa;
    font-size: 11px;
    font-weight: 400;
}

.signup-step .field input,
.signup-step .field select {
    width: 100%;
    height: 50px;
    padding: 0 14px;
    border: 1px solid #d4deea;
    border-radius: 7px;
    background: #fff;
    color: #172335;
    font-size: 14px;
}

.signup-step .field input:focus,
.signup-step .field select:focus {
    border-color: #1557c0;
    box-shadow: 0 0 0 3px rgba(21, 87, 192, 0.1);
    outline: none;
}

.signup-step .field small {
    display: block;
    margin-top: 7px;
    color: #7a8799;
    font-size: 11px;
}

.choice-list {
    display: grid;
    gap: 10px;
}

.choice {
    min-height: 52px;
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 12px 14px;
    border: 1px solid #dce5f0;
    border-radius: 8px;
    color: #344258;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition:
        border-color 0.15s ease,
        background-color 0.15s ease,
        box-shadow 0.15s ease;
}

.choice:hover {
    border-color: #a9bee0;
    background: #f8fbff;
}

.choice:has(input:checked) {
    border-color: #1557c0;
    background: #f4f8ff;
    box-shadow: inset 3px 0 0 #1557c0;
}

.choice input[type="radio"] {
    appearance: none;
    -webkit-appearance: none;

    width: 18px;
    height: 18px;

    flex: 0 0 18px;

    margin: 0;

    border: 2px solid #b8c0cc;
    border-radius: 50%;

    background: #ffffff;

    cursor: pointer;

    transition:
        border-color 0.15s ease,
        background 0.15s ease,
        box-shadow 0.15s ease;
}

.choice input[type="radio"]:checked {
    border-color: #1f56c5;
    background: #1f56c5;

    box-shadow:
        inset 0 0 0 4px #ffffff;
}

.choice input[type="radio"]:focus-visible {
    outline: none;

    box-shadow:
        0 0 0 3px rgba(31, 86, 197, 0.18);
}

.choice input[type="radio"]:checked:focus-visible {
    box-shadow:
        inset 0 0 0 4px #ffffff,
        0 0 0 3px rgba(31, 86, 197, 0.18);
}

.step-buttons {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 32px;
    padding-top: 22px;
    border-top: 1px solid #e8edf3;
}

.next-button,
.create-button,
.back-button {
    min-height: 48px;
    padding: 0 20px;
    border-radius: 7px;
    font-size: 13px;
    font-weight: 700;
}

.next-button,
.create-button {
    border: 1px solid #1557c0;
    background: #1557c0;
    color: #fff;
}

.next-button:hover,
.create-button:hover {
    border-color: #0e3f8f;
    background: #0e3f8f;
}

.back-button {
    border: 1px solid #d4deea;
    background: #fff;
    color: #4f5f75;
}

.back-button:hover {
    border-color: #1557c0;
    color: #1557c0;
}

.next-button:disabled,
.create-button:disabled {
    opacity: 0.7;
    cursor: wait;
}

.terms-check {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    color: #65748a;
    font-size: 12px;
    line-height: 1.55;
    cursor: pointer;
}

.terms-check input {
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
    margin: 1px 0 0;
    accent-color: #1557c0;
}

.form-error {
    margin-top: 18px;
    padding: 11px 13px;
    border: 1px solid #e7caca;
    border-radius: 7px;
    background: #fff7f7;
    color: #a23d3d;
    font-size: 12px;
    line-height: 1.5;
}

.form-error[hidden] {
    display: none;
}

.account-modal[hidden] {
    display: none;
}

.account-modal {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: grid;
    place-items: center;
    padding: 20px;
}

.account-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(12, 31, 59, 0.5);
    backdrop-filter: blur(3px);
}

.account-modal-dialog {
    position: relative;
    width: min(100%, 440px);
    padding: 34px;
    border: 1px solid #dce5f0;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 24px 60px rgba(9, 34, 70, 0.18);
}

.account-modal-close {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: #718097;
    font-size: 24px;
}

.account-modal-close:hover {
    background: #f1f5fa;
}

.account-modal-dialog h2 {
    margin: 10px 0 10px;
    color: #172335;
    font-size: 24px;
    line-height: 1.2;
}

.account-modal-dialog p {
    margin: 0 0 24px;
    color: #65748a;
    font-size: 14px;
    line-height: 1.6;
}

.account-modal-button {
    width: 100%;
}

.account-modal-open {
    overflow: hidden;
}

@media (max-width: 768px) {
    .onboarding-main {
        padding: 32px 16px 56px;
    }

    .card-header,
    .card-body {
        padding-left: 28px;
        padding-right: 28px;
    }
}

@media (max-width: 600px) {
    .onboarding-main {
        padding: 22px 12px 46px;
    }

    .card-header {
        padding: 28px 20px 24px;
    }

    .card-body {
        padding: 28px 20px 24px;
    }

    .card-header h1,
    .signup-step h1 {
        font-size: 24px;
    }

    .step-buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .next-button,
    .create-button,
    .back-button {
        width: 100%;
    }
}

@media (max-width: 420px) {
    .step-buttons {
        flex-direction: column-reverse;
    }

    .account-modal-dialog {
        padding: 28px 22px;
    }
}