* { box-sizing: border-box; margin: 0; padding: 0; }

body.onboarding-page {
    min-height: 100vh;
    min-height: 100dvh;
    font-family: Inter, Arial, sans-serif;
    background: #f6f4f2;
    color: #1f2937;
    margin: 0;
    overflow: hidden;
}

body.onboarding-page--split {
    display: flex;
    align-items: stretch;
    padding: 0;
}

.onboarding-split {
    display: flex;
    width: 100%;
    min-height: 100vh;
    min-height: 100dvh;
}

.onboarding-welcome {
    flex: 0 0 42%;
    max-width: 520px;
    background: #91796e;
    color: #fff;
    display: flex;
    flex-direction: column;
    padding: 1.6rem 1.8rem 1.4rem;
    position: relative;
}

.onboarding-welcome .welcome-home-logo {
    display: inline-flex;
    margin-bottom: auto;
}

.onboarding-welcome .welcome-home-logo img {
    width: 82px;
    height: auto;
}

.onboarding-welcome .welcome-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 1rem 0.5rem 2rem;
    max-width: 380px;
    margin: 0 auto;
}

.onboarding-welcome h2 {
    font-size: 1.65rem;
    font-weight: 700;
    margin-bottom: 0.85rem;
    line-height: 1.25;
}

.onboarding-welcome .welcome-text {
    font-size: 0.95rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.92);
    margin-bottom: 1.1rem;
}

.onboarding-welcome .welcome-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.65rem 1.25rem;
    border-radius: 999px;
    background: #fff;
    color: #91796e;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.92rem;
    margin-bottom: 0.85rem;
}

.onboarding-welcome .welcome-note {
    font-size: 0.72rem;
    line-height: 1.4;
    color: rgba(255, 255, 255, 0.82);
    max-width: 320px;
}

.onboarding-welcome .welcome-faq {
    margin-top: auto;
    text-align: center;
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.88rem;
    text-decoration: underline;
}

.onboarding-welcome .welcome-faq:hover {
    color: #fff;
}

.onboarding-page--split .onboarding-main {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px 20px;
    overflow: hidden;
}

.onboarding-page {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.onboarding {
    width: 100%;
    max-width: 480px;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, .08);
    padding: 28px 24px 22px;
}

.onboarding--signup {
    max-width: 560px;
    width: 100%;
}

.onboarding .signup-fields--grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 12px;
    margin-bottom: 8px;
}

.onboarding .form-group--full {
    grid-column: 1 / -1;
}

.onboarding .signup-meta-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.onboarding .signup-meta-row .terms-text {
    flex: 1 1 180px;
    margin: 0;
    min-width: 0;
}

.onboarding .signup-meta-row .google-btn {
    flex: 0 1 auto;
    width: auto;
    min-width: 150px;
    margin: 0;
    padding: 8px 12px;
    font-size: 0.82rem;
}

.onboarding .signup-meta-row .login-link {
    flex: 0 0 auto;
    margin: 0;
    white-space: nowrap;
    font-size: 0.78rem;
}

.onboarding .signup-meta-row .login-link a {
    display: block;
}

.onboarding .logo {
    text-align: center;
    margin-bottom: 18px;
}

.onboarding .logo img {
    height: 34px;
}

.onboarding .steps {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 22px;
    font-size: .82rem;
    color: #6b7280;
}

.onboarding .step {
    display: flex;
    align-items: center;
    gap: 6px;
}

.onboarding .step-dot {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: .72rem;
    font-weight: 700;
    background: #e5e7eb;
    color: #6b7280;
}

.onboarding .step.done .step-dot,
.onboarding .step.active .step-dot {
    background: #91796e;
    color: #fff;
}

.onboarding .step-line {
    width: 36px;
    height: 2px;
    background: #e5e7eb;
}

.onboarding .step-line.done {
    background: #91796e;
}

.onboarding h1 {
    text-align: center;
    font-size: 1.35rem;
    margin-bottom: 8px;
    font-weight: 700;
}

.onboarding .subtitle {
    text-align: center;
    color: #6b7280;
    font-size: .92rem;
    line-height: 1.45;
    margin-bottom: 18px;
}

.onboarding .error {
    color: #b91c1c;
    font-size: .85rem;
    text-align: center;
    min-height: 1.2rem;
    margin-bottom: 8px;
}

.onboarding .country-options {
    display: grid;
    gap: 10px;
    margin-bottom: 22px;
}

.onboarding .country-option {
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    padding: 14px 16px;
    background: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: border-color .2s, background .2s;
    text-align: left;
    width: 100%;
    font: inherit;
}

.onboarding .country-option:hover {
    border-color: #c9b8b0;
}

.onboarding .country-option.selected {
    border-color: #91796e;
    background: #faf7f5;
}

.onboarding .country-flag {
    font-size: 1.5rem;
    line-height: 1;
}

.onboarding .country-label {
    font-weight: 600;
    font-size: 1rem;
    color: #111827;
}

.onboarding .country-code {
    font-weight: 700;
    font-size: .9rem;
    color: #6b7280;
    min-width: 1.6rem;
}

.onboarding .signup-fields {
    display: grid;
    gap: 8px;
    margin-bottom: 10px;
}

.onboarding .form-group label {
    display: block;
    margin-bottom: 4px;
    color: #374151;
    font-size: .78rem;
    font-weight: 500;
}

.onboarding .form-group label.required::after {
    content: " *";
    color: #b91c1c;
}

.onboarding .form-group input {
    width: 100%;
    padding: 10px 12px;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: .9rem;
    font-family: inherit;
    background: #fff;
    transition: border-color .2s;
}

.onboarding .form-group input:focus {
    outline: none;
    border-color: #91796e;
}

.onboarding .form-group .hint {
    font-size: .7rem;
    color: #9ca3af;
    margin-top: 3px;
    line-height: 1.25;
}

.onboarding .terms-text {
    font-size: .58rem;
    color: #6b7280;
    line-height: 1.35;
    margin-bottom: 10px;
}

.onboarding .terms-text p + p {
    margin-top: 4px;
}

.onboarding .divider {
    text-align: center;
    margin: 10px 0;
    position: relative;
    color: #9ca3af;
    font-size: .8rem;
}

.onboarding .divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #e5e7eb;
}

.onboarding .divider span {
    background: #fff;
    padding: 0 10px;
    position: relative;
}

.onboarding .google-btn {
    width: 100%;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    padding: 10px 14px;
    background: #fff;
    color: #374151;
    font-size: .9rem;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 10px;
    transition: border-color .2s;
}

.onboarding .google-btn:hover {
    border-color: #c9b8b0;
}

.onboarding .google-btn img {
    width: 18px;
    height: 18px;
}

.onboarding .login-link {
    text-align: center;
    font-size: .82rem;
    color: #6b7280;
    margin-bottom: 14px;
}

.onboarding .login-link a {
    color: #91796e;
    text-decoration: none;
    font-weight: 600;
}

.onboarding .login-link a:hover {
    text-decoration: underline;
}

.onboarding .actions {
    display: flex;
    gap: 10px;
}

.onboarding .btn {
    flex: 1;
    border: none;
    border-radius: 10px;
    padding: 11px 14px;
    font-size: .95rem;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
}

.onboarding .btn-back {
    background: #f3f4f6;
    color: #374151;
}

.onboarding .btn-next {
    background: #91796e;
    color: #fff;
}

.onboarding .btn-next:disabled {
    opacity: .55;
    cursor: not-allowed;
}

@media (max-width: 900px) {
    body.onboarding-page--split {
        overflow: auto;
    }

    .onboarding-split {
        flex-direction: column;
        min-height: auto;
    }

    .onboarding-welcome {
        flex: none;
        max-width: none;
        min-height: auto;
        padding: 1.2rem 1rem 1rem;
    }

    .onboarding-welcome .welcome-content {
        padding: 0.5rem 0 0.75rem;
    }

    .onboarding-welcome h2 {
        font-size: 1.25rem;
    }

    .onboarding-page--split .onboarding-main {
        padding: 12px;
    }

    .onboarding .signup-fields--grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 520px) {
    body.onboarding-page {
        align-items: flex-start;
        padding-top: 12px;
        overflow: auto;
    }

    .onboarding {
        padding: 22px 18px 18px;
    }
}
