html:has(.rp-auth),
body.rp-auth-body,
.rp-auth {
    --rpa-bg0: #05070f;
    --rpa-bg1: #070b1a;
    --rpa-bg2: #0a1129;
    --rpa-bg3: #0f1832;
    --rpa-bg4: #141f3f;
    --rpa-border: rgba(86, 122, 200, 0.18);
    --rpa-border-hi: rgba(86, 122, 200, 0.34);
    --rpa-border-lo: rgba(86, 122, 200, 0.1);
    --rpa-text: #e7ecf8;
    --rpa-dim: #8a96b8;
    --rpa-muted: #5e6b8e;
    --rpa-blue: #4b8bff;
    --rpa-blue-hi: #6ba3ff;
    --rpa-blue-lo: #2d6be8;
    --rpa-cyan: #38d6f6;
    --rpa-violet: #8a6bff;
    --rpa-green: #35d8a0;
    --rpa-gold: #f5c451;
}

html:has(.rp-auth),
body.rp-auth-body {
    min-height: 100%;
    background: var(--rpa-bg1);
}

body.rp-auth-body {
    margin: 0;
    color: var(--rpa-text);
    font-family: Geist, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    overflow-x: hidden;
}

.rp-auth *,
.rp-auth *::before,
.rp-auth *::after {
    box-sizing: border-box;
}

.rp-auth svg {
    width: 1em;
    height: 1em;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.rp-auth {
    position: relative;
    min-height: 100vh;
    isolation: isolate;
    overflow: hidden;
    background: var(--rpa-bg1);
}

.rp-auth__bg {
    position: absolute;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(1000px 560px at 50% -10%, rgba(75, 139, 255, 0.18), transparent 60%),
        radial-gradient(900px 500px at 100% 100%, rgba(138, 107, 255, 0.11), transparent 62%),
        linear-gradient(180deg, #070b1a 0%, #060817 100%);
}

.rp-auth__bg::after {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0.34;
    background-image:
        linear-gradient(rgba(86, 122, 200, 0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(86, 122, 200, 0.06) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: radial-gradient(ellipse at 50% 40%, #000 28%, transparent 76%);
}

.rp-auth__top {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: min(100%, 1280px);
    margin: 0 auto;
    padding: 24px 40px;
}

.rp-auth__brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--rpa-blue);
    text-decoration: none;
}

.rp-auth__brand-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    font-size: 22px;
}

.rp-auth__brand-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 0 8px rgba(59, 130, 246, 0.28));
}

.rp-auth__brand-text {
    display: inline-flex;
    align-items: baseline;
    font-family: "Space Grotesk", Geist, sans-serif;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1;
    color: rgba(231, 236, 248, 0.92);
}

.rp-auth__brand-text strong {
    color: var(--rpa-blue);
}

.rp-auth__switch {
    display: flex;
    align-items: center;
    gap: 14px;
    color: var(--rpa-dim);
    font-size: 13px;
}

.rp-auth__switch-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 8px 14px;
    border: 1px solid var(--rpa-border-hi);
    border-radius: 9px;
    background: var(--rpa-bg3);
    color: var(--rpa-text);
    font-weight: 650;
    text-decoration: none;
}

.rp-auth__grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: 56px;
    align-items: center;
    width: min(100%, 1280px);
    min-height: calc(100vh - 90px);
    margin: 0 auto;
    padding: 18px 80px 52px;
}

.rp-auth__pitch {
    min-width: 0;
}

.rp-auth__pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 11px;
    border: 1px solid var(--rpa-border-hi);
    border-radius: 999px;
    background: rgba(75, 139, 255, 0.1);
    color: var(--rpa-blue-hi);
    font-size: 11.5px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.rp-auth__pill span {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: var(--rpa-green);
}

.rp-auth__pitch h1 {
    max-width: 560px;
    margin: 20px 0 14px;
    color: var(--rpa-text);
    font-family: "Space Grotesk", Geist, sans-serif;
    font-size: clamp(36px, 4vw, 52px);
    font-weight: 800;
    line-height: 1.04;
    letter-spacing: 0;
}

.rp-auth__pitch h1 span {
    color: var(--rpa-blue);
}

.rp-auth__pitch p {
    max-width: 460px;
    margin: 0;
    color: var(--rpa-dim);
    font-size: 15px;
    line-height: 1.6;
}

.rp-auth__benefits {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    max-width: 560px;
    margin-top: 32px;
}

.rp-auth-benefit,
.rp-auth-mobile-benefits article {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.rp-auth-benefit {
    min-width: 0;
    padding: 16px;
    border: 1px solid var(--rpa-border);
    border-radius: 12px;
    background: var(--rpa-bg2);
}

.rp-auth-benefit__icon,
.rp-auth-mobile-benefits article > span:first-child {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    border-radius: 9px;
    background: rgba(75, 139, 255, 0.12);
    color: var(--rpa-blue);
    border: 1px solid rgba(75, 139, 255, 0.22);
}

.rp-auth-benefit__icon.is-gold,
.rp-auth-mobile-benefits .is-gold { color: var(--rpa-gold); background: rgba(245, 196, 81, 0.12); border-color: rgba(245, 196, 81, 0.25); }
.rp-auth-benefit__icon.is-violet,
.rp-auth-mobile-benefits .is-violet { color: var(--rpa-violet); background: rgba(138, 107, 255, 0.13); border-color: rgba(138, 107, 255, 0.25); }
.rp-auth-benefit__icon.is-cyan,
.rp-auth-mobile-benefits .is-cyan { color: var(--rpa-cyan); background: rgba(56, 214, 246, 0.12); border-color: rgba(56, 214, 246, 0.25); }

.rp-auth-benefit strong,
.rp-auth-mobile-benefits strong {
    display: block;
    color: var(--rpa-text);
    font-size: 13.5px;
    font-weight: 700;
    line-height: 1.2;
}

.rp-auth-benefit small,
.rp-auth-mobile-benefits small {
    display: block;
    margin-top: 3px;
    color: var(--rpa-dim);
    font-size: 12px;
    line-height: 1.45;
}

.rp-auth__trust {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px 20px;
    margin-top: 24px;
    color: var(--rpa-dim);
    font-size: 12.5px;
}

.rp-auth__trust strong {
    color: var(--rpa-text);
}

.rp-auth__trust em {
    display: inline-block;
    width: 1px;
    height: 18px;
    margin: 0 4px;
    vertical-align: middle;
    background: var(--rpa-border);
}

.rp-auth__stars {
    display: inline-flex;
    gap: 2px;
    color: #00b67a;
}

.rp-auth__stars svg {
    fill: currentColor;
    stroke: currentColor;
    width: 14px;
    height: 14px;
}

.rp-auth__secure {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.rp-auth__secure svg {
    color: var(--rpa-blue);
}

.rp-auth-card {
    width: min(100%, 466px);
    justify-self: center;
    padding: 30px;
    border: 1px solid var(--rpa-border);
    border-radius: 18px;
    background: var(--rpa-bg2);
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.45);
}

.rp-auth-card__head {
    margin-bottom: 22px;
}

.rp-auth-card__head > span {
    display: block;
    margin-bottom: 8px;
    color: var(--rpa-blue-hi);
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.rp-auth-card__head h2 {
    margin: 0;
    color: var(--rpa-text);
    font-family: "Space Grotesk", Geist, sans-serif;
    font-size: 24px;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: 0;
}

.rp-auth-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.rp-auth-field {
    display: block;
}

.rp-auth-field > span:first-child {
    display: block;
    margin-bottom: 7px;
    color: var(--rpa-dim);
    font-size: 12.5px;
    font-weight: 600;
}

.rp-auth-field__box {
    display: flex;
    align-items: center;
    min-height: 43px;
    border: 1px solid var(--rpa-border);
    border-radius: 10px;
    background: var(--rpa-bg4);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.rp-auth-field__box:focus-within {
    border-color: var(--rpa-border-hi);
    box-shadow: 0 0 0 3px rgba(75, 139, 255, 0.15);
}

.rp-auth-field__box > svg {
    flex: 0 0 auto;
    margin-left: 14px;
    color: var(--rpa-muted);
    font-size: 18px;
}

.rp-auth-field input {
    min-width: 0;
    flex: 1;
    height: 42px;
    padding: 0 14px;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--rpa-text);
    font: inherit;
    font-size: 16px;
    line-height: 1.25;
}

.rp-auth .rp-auth-field__box input[type="text"],
.rp-auth .rp-auth-field__box input[type="email"],
.rp-auth .rp-auth-field__box input[type="password"],
.rp-auth .rp-auth-field__box input[type="search"],
.rp-auth .rp-auth-field__box input[type="tel"],
.rp-auth .rp-auth-field__box input[type="url"],
.rp-auth .rp-auth-field__box input[type="number"],
.rp-auth .rp-auth-field__box textarea,
.rp-auth .rp-auth-field__box select {
    font-size: 16px !important;
    line-height: 1.25;
}

.rp-auth-field input::placeholder {
    color: var(--rpa-muted);
}

.rp-auth-field input:-webkit-autofill,
.rp-auth-field input:-webkit-autofill:hover,
.rp-auth-field input:-webkit-autofill:focus,
.rp-auth-field input:-webkit-autofill:active {
    -webkit-text-fill-color: var(--rpa-text) !important;
    caret-color: var(--rpa-text);
    box-shadow: 0 0 0 1000px var(--rpa-bg4) inset !important;
    transition: background-color 9999s ease-out, color 9999s ease-out;
}

.rp-auth-field input:autofill {
    color: var(--rpa-text);
    background: var(--rpa-bg4);
}

.rp-auth-field__peek {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border: 0;
    background: transparent;
    color: var(--rpa-muted);
    cursor: pointer;
}

.rp-auth-form__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 1px;
}

.rp-auth-form__row a {
    color: var(--rpa-blue-hi);
    font-size: 13px;
    font-weight: 650;
    text-decoration: none;
    white-space: nowrap;
}

.rp-auth-check {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    min-width: 0;
    color: var(--rpa-dim);
    font-size: 13px;
    cursor: pointer;
}

.rp-auth-check input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.rp-auth-check span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
    border: 1.5px solid var(--rpa-blue);
    border-radius: 5px;
    background: var(--rpa-blue);
}

.rp-auth-check span::after {
    content: "";
    width: 8px;
    height: 5px;
    border-left: 2px solid #fff;
    border-bottom: 2px solid #fff;
    transform: rotate(-45deg) translate(1px, -1px);
}

.rp-auth-check input:not(:checked) + span {
    background: transparent;
    border-color: var(--rpa-border-hi);
}

.rp-auth-check input:not(:checked) + span::after {
    content: none;
}

.rp-auth-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    min-height: 44px;
    padding: 13px 22px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 10px;
    background: linear-gradient(180deg, var(--rpa-blue), var(--rpa-blue-lo));
    color: #fff;
    box-shadow: 0 6px 18px rgba(75, 139, 255, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.2);
    font: inherit;
    font-size: 14.5px;
    font-weight: 750;
    cursor: pointer;
}

.rp-auth-primary:hover {
    background: linear-gradient(180deg, var(--rpa-blue-hi), var(--rpa-blue));
    box-shadow: 0 8px 26px rgba(75, 139, 255, 0.42), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.rp-auth-primary:disabled {
    opacity: 0.58;
    cursor: not-allowed;
    background: rgba(75, 139, 255, 0.2);
    box-shadow: none;
}

.rp-auth-primary svg {
    width: 17px;
    height: 17px;
}

.rp-auth-divider {
    display: flex;
    align-items: center;
    gap: 14px;
    color: var(--rpa-muted);
    font-size: 11.5px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.rp-auth-divider::before,
.rp-auth-divider::after {
    content: "";
    height: 1px;
    flex: 1;
    background: var(--rpa-border-lo);
}

.rp-auth-social {
    display: flex;
    gap: 9px;
}

.rp-auth-social a,
.rp-auth-social button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-width: 0;
    min-height: 39px;
    flex: 1;
    padding: 10px 12px;
    border: 1px solid var(--rpa-border);
    border-radius: 10px;
    background: var(--rpa-bg3);
    color: var(--rpa-text);
    font: inherit;
    font-size: 13px;
    font-weight: 650;
    text-decoration: none;
    transition: border-color 0.16s ease, background 0.16s ease, transform 0.16s ease;
}

.rp-auth-social a:hover {
    border-color: rgba(84, 141, 255, 0.55);
    background: rgba(67, 126, 246, 0.12);
    transform: translateY(-1px);
}

.rp-auth-social button:disabled {
    opacity: 0.72;
    cursor: not-allowed;
}

.rp-auth-social svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
    stroke: none;
}

.rp-auth-form__note {
    display: none;
    margin: -4px 0 0;
    color: var(--rpa-blue-hi);
    font-size: 12px;
    line-height: 1.4;
}

.rp-auth-form__note.is-visible {
    display: block;
}

.rp-auth-form__note.is-error {
    padding: 10px 12px;
    border: 1px solid rgba(255, 107, 168, 0.26);
    border-radius: 10px;
    background: rgba(255, 107, 168, 0.09);
    color: #ffadc9;
}

.rp-auth-form__note.is-success {
    padding: 10px 12px;
    border: 1px solid rgba(53, 216, 160, 0.28);
    border-radius: 10px;
    background: rgba(53, 216, 160, 0.09);
    color: #7ff0c7;
}

.rp-auth-card__foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid var(--rpa-border-lo);
    color: var(--rpa-dim);
    font-size: 12.5px;
}

.rp-auth-card__foot a {
    color: var(--rpa-blue-hi);
    font-weight: 650;
    text-decoration: none;
}

.rp-auth-card__encrypted {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: var(--rpa-muted);
    white-space: nowrap;
}

.rp-auth-card__encrypted svg {
    width: 14px;
    height: 14px;
}

.rp-auth-mobile-benefits {
    display: none;
}

@media (max-width: 900px) {
    body.rp-auth-body {
        background: #020512;
    }

    .rp-auth {
        width: 100%;
        max-width: none;
        min-height: 100vh;
        min-height: 100svh;
        margin: 0;
        /* Small buffer only — nav space is reserved once by body.rbp-header-active
           (below the footer); this override just opened a gap above the footer. */
        padding-bottom: 24px;
        border-inline: 0;
    }

    .rp-auth__top {
        width: 100%;
        padding: 44px 20px 0;
    }

    .rp-auth__switch span {
        display: none;
    }

    .rp-auth__switch-btn {
        min-height: auto;
        padding: 0;
        border: 0;
        background: transparent;
        color: var(--rpa-dim);
        font-size: 13px;
    }

    .rp-auth__grid {
        display: block;
        width: 100%;
        min-height: 0;
        padding: 0;
    }

    .rp-auth__pitch {
        padding: 28px 20px 18px;
    }

    .rp-auth__pill {
        padding: 5px 10px;
        font-size: 10.5px;
    }

    .rp-auth__pitch h1 {
        margin: 14px 0 10px;
        font-size: 30px;
        line-height: 1.08;
    }

    .rp-auth__pitch p {
        font-size: 14px;
        line-height: 1.5;
    }

    .rp-auth__benefits,
    .rp-auth__trust {
        display: none;
    }

    .rp-auth-card {
        width: auto;
        margin: 8px 16px 18px;
        padding: 20px;
        border-radius: 16px;
    }

    .rp-auth-card__head {
        margin-bottom: 16px;
    }

    .rp-auth-card__head > span {
        font-size: 10.5px;
    }

    .rp-auth-card__head h2 {
        font-size: 20px;
    }

    .rp-auth-form {
        gap: 13px;
    }

    .rp-auth-form__row {
        align-items: flex-start;
    }

    .rp-auth-check {
        font-size: 12.5px;
    }

    .rp-auth-form__row a {
        font-size: 12.5px;
    }

    .rp-auth-social button {
        padding: 10px;
    }

    .rp-auth-social span {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        white-space: nowrap;
    }

    .rp-auth-card__foot {
        margin-top: 16px;
        padding-top: 14px;
        font-size: 12px;
    }

    .rp-auth-mobile-benefits {
        display: block;
        margin: 0 16px 28px;
    }

    .rp-auth-mobile-benefits > button {
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        padding: 14px 16px;
        border: 1px solid var(--rpa-border);
        border-radius: 12px;
        background: var(--rpa-bg2);
        color: var(--rpa-text);
        font: inherit;
        font-size: 13px;
        font-weight: 750;
        text-align: left;
    }

    .rp-auth-mobile-benefits > button span {
        display: inline-flex;
        align-items: center;
        gap: 8px;
    }

    .rp-auth-mobile-benefits > button svg {
        color: var(--rpa-blue-hi);
    }

    .rp-auth-mobile-benefits > div {
        display: none;
        border: 1px solid var(--rpa-border);
        border-top: 0;
        border-radius: 0 0 12px 12px;
        background: var(--rpa-bg2);
        overflow: hidden;
    }

    .rp-auth-mobile-benefits.is-open > button {
        border-radius: 12px 12px 0 0;
    }

    .rp-auth-mobile-benefits.is-open > div {
        display: block;
    }

    .rp-auth-mobile-benefits article {
        padding: 13px 14px;
        border-top: 1px solid var(--rpa-border-lo);
    }

    .rp-auth-mobile-benefits article > span:first-child {
        width: 30px;
        height: 30px;
        flex-basis: 30px;
    }
}

@media (max-width: 1180px) and (min-width: 901px) {
    .rp-auth__grid {
        gap: 34px;
        padding-inline: 40px;
    }
}

/* ===========================================================================
 * Register consent block (marketing opt-in + required terms).
 * ========================================================================= */

.rp-auth-form__row--stack {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
}

.rp-auth-form__row--stack .rp-auth-check {
    align-items: flex-start;
    line-height: 1.45;
}

.rp-auth-check__note {
    margin: 0 0 4px 25px;
    color: var(--rpa-dim);
    font-size: 12px;
    line-height: 1.4;
    opacity: .85;
}

.rp-auth-check a {
    color: var(--rpa-blue-hi);
    font-weight: 650;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.rp-auth-check a:hover {
    text-decoration: none;
}

.rp-auth-check--required {
    color: inherit;
}

.rp-auth-check--required span {
    border-color: var(--rpa-blue-hi, #3b82f6);
}
