.onboarding-body {
    min-height: 100dvh;
    background: #080b10;
}

.onboarding-body::before {
    opacity: 1;
    animation: none;
    background:
        radial-gradient(ellipse at 50% 25%, rgba(58, 135, 204, 0.08), transparent 36rem),
        linear-gradient(180deg, #0c1118 0%, #080b10 100%);
}

.onboarding-body::after {
    content: none;
}

.onboarding-page {
    position: relative;
    z-index: 1;
    display: grid;
    width: min(100% - 48px, 920px);
    min-height: 100dvh;
    margin: 0 auto;
    padding: 120px 0 64px;
    place-items: center;
}

.onboarding-page [hidden] {
    display: none !important;
}

.onboarding-page > section.onboarding-auth,
.onboarding-page > section.onboarding-workspace {
    --section-pad-top: 0;
    --section-pad-bottom: 0;
    width: 100%;
    padding: 0;
}

.onboarding-auth,
.onboarding-workspace {
    animation: onboardingReveal 440ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.onboarding-auth {
    max-width: 840px;
    text-align: center;
}

.onboarding-auth h1,
.onboarding-intro h1 {
    color: #f5f7fd;
    font-size: clamp(46px, 5.4vw, 62px);
    line-height: 1.02;
    letter-spacing: -0.045em;
    text-wrap: balance;
}

.onboarding-title-accent {
    background: linear-gradient(90deg, #d9f5ff 0%, #4d91dc 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
}

.onboarding-auth__lead,
.onboarding-intro > p {
    color: rgba(180, 194, 214, 0.78);
    font-size: clamp(17px, 1.7vw, 19px);
    line-height: 1.6;
    text-wrap: balance;
}

.onboarding-auth__lead {
    margin: 22px auto 0;
}

.account-actions {
    display: grid;
    grid-template-columns: repeat(2, 150px);
    gap: 12px;
    width: fit-content;
    margin: 42px auto 0;
}

.onboarding-button {
    display: inline-flex;
    min-height: 52px;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 0 22px;
    border: 1px solid transparent;
    border-radius: 12px;
    cursor: pointer;
    color: #f4f7ff;
    font-family: var(--font-body);
    font-size: 14px;
    font-weight: 700;
    line-height: 1;
    transition: transform 150ms ease, background-color 150ms ease, border-color 150ms ease, box-shadow 150ms ease;
}

.onboarding-button svg {
    width: 17px;
    height: 17px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.onboarding-button:hover:not(:disabled) {
    transform: translateY(-1px);
}

.onboarding-button:focus-visible {
    outline: 2px solid #69c7ff;
    outline-offset: 3px;
}

.onboarding-button:disabled {
    cursor: not-allowed;
    opacity: 0.42;
}

.onboarding-button--primary {
    border-color: rgba(139, 211, 255, 0.42);
    background: linear-gradient(90deg, #d9f5ff 0%, #4f9ce8 100%);
    color: #0a1320;
    box-shadow: inset 0 0 0 1px rgba(47, 127, 186, 0.32), 0 10px 26px rgba(35, 119, 202, 0.14);
}

.onboarding-button--primary:hover:not(:disabled) {
    border-color: rgba(188, 231, 255, 0.68);
    box-shadow: inset 0 0 0 1px rgba(47, 127, 186, 0.34), 0 13px 30px rgba(35, 119, 202, 0.2);
    filter: brightness(1.03);
}

.onboarding-button--secondary {
    border-color: rgba(222, 236, 255, 0.13);
    background: rgba(255, 255, 255, 0.025);
    color: rgba(226, 234, 246, 0.76);
}

.onboarding-button--secondary:hover:not(:disabled) {
    border-color: rgba(222, 236, 255, 0.24);
    background: rgba(255, 255, 255, 0.05);
    color: #f4f7ff;
}

.onboarding-workspace {
    max-width: 840px;
}

.onboarding-intro {
    text-align: center;
}

.onboarding-intro > p {
    width: min(100%, 650px);
    margin: 22px auto 0;
}

.agent-instruction-card {
    position: relative;
    overflow: hidden;
    margin-top: 38px;
    border: 1px solid rgba(151, 188, 220, 0.24);
    border-radius: 16px;
    background: rgba(7, 12, 18, 0.52);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.025), 0 24px 64px rgba(0, 0, 0, 0.2);
}

.agent-instruction-card__prompt {
    margin: 0;
    padding: 32px 82px 32px 34px;
    overflow: visible;
    white-space: pre-wrap;
}

.agent-instruction-card__prompt code {
    color: rgba(226, 234, 245, 0.91);
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
    font-size: clamp(15px, 1.45vw, 17px);
    font-weight: 400;
    line-height: 1.7;
}

.agent-instruction-card__status {
    margin: 0;
    padding: 0 82px 22px 34px;
    color: #f29a9a;
    font-size: 12px;
    line-height: 1.6;
}

.agent-instruction-card__status:empty {
    display: none;
}

.agent-instruction-card__status.is-error {
    color: #f29a9a;
}

.onboarding-copy {
    position: absolute;
    top: 50%;
    right: 18px;
    display: grid;
    width: 42px;
    height: 42px;
    padding: 0;
    place-items: center;
    border: 0;
    border-radius: 50%;
    cursor: pointer;
    background: transparent;
    color: rgba(188, 203, 223, 0.62);
    transform: translateY(-50%);
    transition: color 150ms ease, background-color 150ms ease;
}

.onboarding-copy:hover {
    background: rgba(255, 255, 255, 0.045);
    color: rgba(226, 234, 245, 0.9);
}

.onboarding-copy:focus-visible {
    outline: 2px solid #69c7ff;
    outline-offset: 2px;
}

.onboarding-copy svg {
    position: absolute;
    width: 22px;
    height: 22px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: opacity 140ms ease, transform 180ms ease;
}

.onboarding-copy__check {
    opacity: 0;
    transform: scale(0.72);
}

.onboarding-copy.is-copied {
    background: transparent;
    color: #65d6ad;
}

.onboarding-copy.is-copied .onboarding-copy__copy {
    opacity: 0;
    transform: scale(0.72);
}

.onboarding-copy.is-copied .onboarding-copy__check {
    opacity: 1;
    transform: scale(1);
}

.compatible-agents {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    margin-top: 38px;
}

.compatible-agents > p {
    color: rgba(147, 163, 185, 0.58);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.compatible-agents ul {
    display: flex;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.compatible-agent {
    display: grid;
    width: 48px;
    height: 48px;
    place-items: center;
    border: 1px solid rgba(222, 236, 255, 0.12);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.025);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.025);
    color: inherit;
    text-decoration: none;
    transition: border-color 150ms ease, background-color 150ms ease, transform 150ms ease;
}

.compatible-agent:hover {
    border-color: rgba(130, 198, 255, 0.3);
    background: rgba(71, 142, 207, 0.07);
    transform: translateY(-1px);
}

.compatible-agent:focus-visible {
    outline: 2px solid #69c7ff;
    outline-offset: 3px;
}

.compatible-agent img {
    width: 23px;
    height: 23px;
    filter: brightness(0) invert(1);
    opacity: 0.74;
}

@keyframes onboardingReveal {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 760px) {
    .onboarding-page {
        width: min(100% - 32px, 920px);
        padding: 108px 0 48px;
    }

    .onboarding-auth h1,
    .onboarding-intro h1 {
        font-size: clamp(38px, 11vw, 48px);
    }

    .agent-instruction-card {
        margin-top: 30px;
    }

    .compatible-agents {
        margin-top: 30px;
    }

    .agent-instruction-card__prompt {
        padding: 24px 64px 24px 22px;
    }

    .agent-instruction-card__prompt code {
        font-size: 14px;
        line-height: 1.68;
    }

    .onboarding-copy {
        right: 10px;
    }

    .agent-instruction-card__status {
        padding: 0 64px 20px 22px;
    }
}

@media (max-width: 520px) {
    .account-actions {
        grid-template-columns: 1fr;
        width: 100%;
        margin-top: 34px;
    }

    .compatible-agents {
        align-items: center;
        flex-direction: column;
        gap: 12px;
    }

    .compatible-agents ul {
        gap: 8px;
    }

    .compatible-agent {
        width: 46px;
        height: 46px;
    }

}

@media (prefers-reduced-motion: reduce) {
    .onboarding-auth,
    .onboarding-workspace {
        animation: none;
    }

    .onboarding-button {
        transition: none;
    }

    .onboarding-copy,
    .onboarding-copy svg {
        transition: none;
    }

    .compatible-agent {
        transition: none;
    }
}
