

.regv2-billing-option .regv2-btn {
    align-self: stretch;
    justify-content: center;
}

.regv2-billing-option--plan .regv2-btn--ghost {
    border-color: var(--emerald-alpha-45);
    color: var(--accent-text-emerald);
}

:root[data-theme="light"] .regv2-billing-option--plan .regv2-btn--ghost {
    color: var(--emerald-700);
}

.regv2-plan-card--active .regv2-form__hint,
.regv2-plan-card--active .regv2-plan-card__features {
    color: var(--color-text-primary);
}

/* Stripe Embedded Checkout container */
#stripe-checkout-mount {
    min-height: 300px;
    margin-bottom: var(--space-4);
}

.regv2-billing-junction .regv2-btn--primary {
    /* Trial: primary emerald — already styled via .regv2-btn--primary */
}

/* --- Plan selector layout -------------------------------------------------- */

#planSelector .regv2-form__group {
    margin-bottom: var(--space-1);
}

#planSelector > .regv2-form__actions {
    margin-top: var(--space-4);
}.regv2-sources__actions .regv2-btn {
    width: 100%;
    justify-content: center;
    align-self: auto;
}#stepDActions .regv2-back-btn {
    margin-left: auto;
}

#billingJunction {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
}

.regv2-billing-stage__actions .regv2-btn {
    width: 100%;
    min-width: 0;
    max-width: none;
    min-height: 48px;
    justify-content: center;
    align-self: stretch;
}

.regv2-billing-stage__actions .regv2-btn--primary {
    box-shadow: var(--shadow-md), var(--glow-accent-subtle);
}

.regv2-billing-stage__actions .regv2-btn--primary:hover:not(:disabled) {
    box-shadow: var(--shadow-lg), var(--glow-accent);
}

.regv2-billing-stage__secondary .regv2-btn {
    align-self: stretch;
    justify-content: center;
    margin-top: auto;
    min-height: 48px;
}

#billingJunction > .regv2-back-btn {
    align-self: flex-start;
}

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

/* --- Inline link button --------------------------------------------------- */

.regv2-btn-link {
    display: inline-flex;
    align-items: center;
    background: none;
    border: none;
    padding: 0;
    color: var(--accent-text-emerald);
    font-size: inherit;
    font-weight: var(--font-weight-medium);
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.regv2-btn-link:hover {
    color: var(--accent-text-emerald);
}

:root[data-theme="light"] .regv2-btn-link {
    color: var(--accent-text-emerald);
}

:root[data-theme="light"] .regv2-btn-link:hover {
    color: var(--emerald-700);
}

.regv2-success .regv2-btn {
    align-self: center;
}

@keyframes regv2AuroraFloat {
    0% { transform: translate(0, 0) scale(1); opacity: 0.6; }
    50% { transform: translate(-3%, 2%) scale(1.05); opacity: 0.8; }
    100% { transform: translate(2%, -2%) scale(1); opacity: 0.6; }
}

@keyframes regv2SuccessPulse {
    0%, 100% { transform: translate(-50%, 0) scale(0.8); opacity: 0; }
    50% { transform: translate(-50%, 0) scale(1.5); opacity: 0.6; }
}

@keyframes regv2SuccessProgress {
    0% { width: 0; }
    100% { width: 100%; }
}

body.regv2-body--billing .regv2 {
    box-sizing: border-box;
    min-height: 100dvh;
    height: auto;
    width: 100%;
    overflow: visible;
    display: flex;
    flex-direction: column;
}

body.regv2-body--billing .regv2-journey-hero {
    flex: 0 0 auto;
    width: 100%;
}

body.regv2-body--billing .regv2-content {
    flex: 1 1 auto;
    width: 100%;
    min-height: auto;
    align-items: stretch;
    overflow: visible;
}

body.regv2-body--billing #stepF.regv2-step--active {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    min-height: auto;
    overflow: visible;
}

body.regv2-body--billing #stepF.regv2-step--active > .regv2-card {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    min-height: auto;
    height: auto;
    max-height: none;
    overflow: visible;
}

body.regv2-body--checkout .regv2 {
    overflow: visible;
}

body.regv2-body--checkout .regv2-journey-hero {
    flex: 0 0 auto;
}

body.regv2-body--checkout .regv2-content {
    flex: 1 1 auto;
    min-height: auto;
    align-items: stretch;
    overflow: visible;
}

body.regv2-body--checkout #stepF.regv2-step--active {
    display: flex;
    flex-direction: column;
    min-height: auto;
    overflow: visible;
}

body.regv2-body--checkout #stepF.regv2-step--active > .regv2-card {
    display: flex;
    flex-direction: column;
    min-height: auto;
    height: auto;
    max-height: none;
    overflow: visible;
}

body.regv2-body--checkout #stripeCheckout > .regv2-form__actions {
    flex: 0 0 auto;
}

/* --- Billing desktop fit & polish ------------------------------------------ */

@media (min-width: 1024px) {
    /* Give Step F more usable vertical space on standard desktop viewports. */
    body.regv2-body--billing .regv2 {
        padding-top: var(--space-3);
        padding-bottom: var(--space-4);
    }

    body.regv2-body--billing .regv2-journey-hero {
        padding: clamp(var(--space-3), 1.8vw, var(--space-4));
    }

    body.regv2-body--billing .regv2-journey-hero__utility {
        min-height: 36px;
        margin-bottom: var(--space-3);
    }

    body.regv2-body--billing .regv2-journey-hero__intro {
        margin-bottom: var(--space-3);
    }

    body.regv2-body--billing .regv2-progress__item {
        min-height: 56px;
        padding: var(--space-2) var(--space-3);
    }

    /* Keep billing content reachable on normal 100% zoom and shorter desktops. */
    body.regv2-body--billing .regv2-content {
        overflow-x: hidden;
        overflow-y: auto;
    }

    body.regv2-body--billing #registerV2App:not([data-billing-section="checkout"]) #stepF.regv2-step--active > .regv2-card {
        display: flex;
        flex-direction: column;
        height: auto;
        max-height: none;
        overflow: visible;
        /* Pehmuste poistettu 26.8.2026: kortteja ei ole, ja tämä sääntö
           voitti tarkkuudellaan (2,4,1) `shell.css`:n nollauksen (1,2,0).
           Laskutusnäytön sisältö istui 16 px sisempänä kuin sivun otsikko,
           eli sivulla oli kaksi vasenta reunaa. */
    }

    body.regv2-body--billing #registerV2App:not([data-billing-section="checkout"]) #planSelector > .regv2-form__actions {
        margin-top: var(--space-4);
        padding-top: var(--space-3);
    }}

@media (min-width: 1024px) and (max-height: 860px) {
    body.regv2-body--billing .regv2 {
        padding-top: var(--space-2);
        padding-bottom: var(--space-3);
    }

    body.regv2-body--billing .regv2-journey-hero {
        padding: var(--space-3);
    }

    body.regv2-body--billing .regv2-journey-hero__utility {
        margin-bottom: var(--space-2);
    }

    body.regv2-body--billing .regv2-journey-hero__intro {
        margin-bottom: var(--space-2);
    }

    body.regv2-body--billing .regv2-journey-hero__subtitle {
        font-size: var(--font-size-sm);
        line-height: 1.4;
    }

    body.regv2-body--billing .regv2-progress__item {
        min-height: 52px;
        padding: var(--space-2);
    }}

/* --- Responsive (mobile) --------------------------------------------------- */

@media (max-width: 640px) {

    #stepDActions .regv2-form__actions {
        display: grid;
        grid-template-columns: 1fr;
    }

    #stepDActions .regv2-back-btn {
        margin-left: 0;
    }}

@media (max-width: 900px) {

    .regv2-billing-stage__actions .regv2-btn,
    .regv2-billing-stage__secondary .regv2-btn {
        width: 100%;
        justify-content: center;
    }}