/* Tunnel d'inscription 2 étapes — partagé index + quien-somos */
.hidden { display: none !important; }

body.modal-scroll-lock { overflow: hidden !important; }

.landing-modal {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    z-index: 1000;
}

.maxpro-overlay {
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.maxpro-overlay.is-active {
    opacity: 1;
    visibility: visible;
}

.registro-box.maxpro-modal {
    position: relative;
    background: #18181b;
    border: none;
    border-top: 4px solid var(--gold, #ffd700);
    border-radius: 8px;
    padding: 40px;
    width: 100%;
    max-width: 650px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.05);
    opacity: 0;
    transform: scale(0.8) translateY(30px);
    transition: opacity 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.maxpro-overlay.is-active .maxpro-modal {
    opacity: 1;
    transform: scale(1) translateY(0);
}

.maxpro-modal-header {
    padding-right: 40px;
}

.maxpro-modal-header h2 {
    color: var(--gold, #ffd700);
    font-size: 2.15rem;
    font-weight: 800;
    line-height: 1.12;
    letter-spacing: -0.02em;
    margin: 0 0 8px;
    white-space: nowrap;
}

.maxpro-modal-header p {
    color: #a1a1aa;
    font-size: 0.95rem;
    line-height: 1.5;
    margin: 0 0 30px;
}

.landing-close,
.maxpro-close-btn {
    position: absolute;
    top: 18px;
    right: 18px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: #71717a;
    font-size: 1.8rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, color 0.2s ease;
}

.maxpro-close-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.registro-tunnel { position: relative; width: 100%; }

.registro-form.maxpro-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.maxpro-form .input-group,
.maxpro-form .full-width,
.maxpro-form #zona-presencial,
.maxpro-form #btn-registro-online,
.maxpro-form #registro-message {
    grid-column: 1 / -1;
}

.registro-step-form {
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.registro-step-form.is-hidden-step {
    opacity: 0;
    transform: translateY(-12px);
    pointer-events: none;
    position: absolute;
    left: 0;
    right: 0;
    visibility: hidden;
}

.registro-step-pago {
    display: none;
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.2s ease, transform 0.2s ease;
    text-align: center;
    padding: 8px 0 4px;
}

.registro-step-pago.is-active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.registro-pago-title {
    color: var(--gold, #ffd700);
    font-size: 1.45rem;
    font-weight: 800;
    margin: 0 0 12px;
}

.registro-pago-amount {
    color: #e4e4e7;
    font-weight: 700;
    font-size: 1.05rem;
    margin: 0 0 20px;
    line-height: 1.5;
}

.registro-step-pago .registro-payment-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    width: 100%;
}

.registro-step-pago .registro-payment-zone {
    width: 100%;
}

.registro-step-pago .pay-btn {
    min-height: 52px;
    width: 100%;
    box-sizing: border-box;
    border-radius: 10px;
    border: none;
    font-weight: 800;
    font-size: 0.95rem;
    line-height: 1.2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 16px;
    cursor: pointer;
    text-decoration: none;
    transition: transform 0.25s ease, box-shadow 0.25s ease, filter 0.2s ease;
}

.registro-step-pago .pay-btn span {
    white-space: nowrap;
}

.registro-step-pago .pay-btn i {
    flex-shrink: 0;
    font-size: 1.05rem;
}

.registro-step-pago .pay-btn:hover {
    transform: translateY(-2px);
}

.registro-step-pago .pay-btn:focus-visible {
    outline: 2px solid var(--gold, #ffd700);
    outline-offset: 2px;
}

.registro-step-pago .pay-btn.flow,
.registro-step-pago .btn-flow {
    background: #f27830;
    color: #fff;
    box-shadow: 0 4px 15px rgba(242, 120, 48, 0.35);
}

.registro-step-pago .pay-btn.paypal,
.registro-step-pago .btn-paypal {
    background: #ffc439;
    color: #003087;
    box-shadow: 0 4px 15px rgba(255, 196, 57, 0.35);
    text-decoration: none;
}

.registro-back-btn {
    margin-top: 8px;
    width: 100%;
    padding: 12px 16px;
    border-radius: 8px;
    border: 1px solid #3f3f46;
    background: transparent;
    color: #a1a1aa;
    font-weight: 700;
    font-size: 0.92rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.registro-back-btn:hover {
    color: #fff;
    border-color: var(--gold, #ffd700);
    background: rgba(255, 255, 255, 0.04);
}

.maxpro-form .input-group:nth-child(-n+6) { grid-column: auto; }

.maxpro-form .login-input,
.maxpro-form input,
.maxpro-form select {
    width: 100%;
    margin: 0;
    background: #27272a;
    border: 1px solid #3f3f46;
    color: #e4e4e7;
    padding: 14px 16px;
    border-radius: 8px;
    font-size: 0.95rem;
    box-sizing: border-box;
}

.maxpro-form input::placeholder { color: #71717a; }

.maxpro-form input:focus,
.maxpro-form select:focus {
    outline: none;
    border-color: var(--gold, #ffd700);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.15);
    background: #1f1f22;
}

.registro-field-label {
    color: var(--gold, #ffd700);
    display: block;
    font-size: 0.78rem;
    font-weight: 800;
    margin-bottom: 8px;
    text-transform: uppercase;
}

.maxpro-form .registro-mode-note {
    color: #a1a1aa;
    line-height: 1.5;
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.035);
    border: 1px solid rgba(212, 175, 55, 0.18);
    border-radius: 8px;
    text-align: center;
}

.maxpro-submit-btn {
    grid-column: 1 / -1;
    background: var(--gold, #ffd700);
    color: #18181b;
    font-weight: 800;
    font-size: 1.05rem;
    padding: 16px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    width: 100%;
}

.maxpro-submit-btn:hover {
    background: #f1c40f;
    transform: translateY(-2px);
}

.form-message {
    padding: 12px;
    border-radius: 8px;
    font-size: 0.9rem;
    text-align: center;
}

/* Offre Pack — synchronisée avec la landing */
.registro-pack-offer {
    margin: -12px 0 24px;
    padding: 18px 16px;
    border-radius: 14px;
    background: linear-gradient(145deg, rgba(255, 215, 0, 0.12), rgba(30, 58, 138, 0.2));
    border: 1px solid rgba(255, 215, 0, 0.35);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.25);
    text-align: center;
}

.registro-pack-offer-top {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.registro-pack-badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border-radius: 999px;
    background: linear-gradient(135deg, #1e3a8a, #2563eb);
    color: #fff;
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.registro-pack-discount {
    display: inline-flex;
    padding: 6px 11px;
    border-radius: 999px;
    background: #dc2626;
    color: #fff;
    font-weight: 900;
    font-size: 0.9rem;
}

.registro-pack-prices {
    display: flex;
    align-items: baseline;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
}

.registro-pack-original {
    color: #71717a;
    text-decoration: line-through;
    font-weight: 700;
    font-size: 1rem;
}

.registro-pack-sale {
    font-size: 2rem;
    font-weight: 900;
    color: var(--gold, #ffd700);
    line-height: 1;
}

.registro-pack-currency {
    font-size: 0.75rem;
    font-weight: 800;
    color: #a1a1aa;
    letter-spacing: 0.08em;
}

.registro-pack-note {
    margin: 10px 0 0;
    color: #d4d4d8;
    font-size: 0.88rem;
    font-weight: 600;
}

.pack-registration-mode .registro-pack-offer {
    display: block !important;
}

.pack-registration-mode #reg-modalidad,
.pack-registration-mode #reg-curso-label,
.pack-registration-mode #reg-curso {
    display: none !important;
}

.pack-registration-mode #registro-intro {
    margin-bottom: 12px;
}

.registro-pago-amount .pack-pay-original {
    display: block;
    color: #71717a;
    text-decoration: line-through;
    font-size: 0.95rem;
    margin-bottom: 4px;
}

.registro-pago-amount .pack-pay-sale {
    display: block;
    color: var(--gold, #ffd700);
    font-size: 1.5rem;
    font-weight: 900;
}

@media (max-width: 900px) {
    .landing-modal {
        padding: max(10px, env(safe-area-inset-top, 0px)) max(10px, env(safe-area-inset-right, 0px)) max(10px, env(safe-area-inset-bottom, 0px)) max(10px, env(safe-area-inset-left, 0px));
        align-items: center;
    }

    .registro-box.maxpro-modal {
        padding: 24px 16px 20px;
        max-height: min(92dvh, 92vh);
        border-radius: 12px;
    }

    .maxpro-modal-header h2 {
        font-size: clamp(0.72rem, 3.5vw, 1.12rem);
        white-space: nowrap;
    }

    .maxpro-modal-header p {
        font-size: 0.88rem;
        margin-bottom: 22px;
    }

    .registro-step-pago .registro-payment-actions {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .registro-step-pago .pay-btn {
        min-height: 54px;
        font-size: clamp(0.9rem, 3.8vw, 1rem);
        padding: 14px 14px;
    }

    .registro-pago-title {
        font-size: 1.25rem;
    }
}

@media (min-width: 901px) {
    .maxpro-modal-header h2 {
        font-size: 2.25rem;
    }
}

@media (max-width: 640px) {
    .registro-form.maxpro-form { grid-template-columns: 1fr; }
    .maxpro-form .input-group:nth-child(-n+6) { grid-column: 1 / -1; }
}

/* =========================================================
   Architecture "Medios de pago" — étape de paiement
   (stepper + carte de méthodes + résumé + CTA)
   ========================================================= */
.registro-step-pago {
    --checkout-purple: #6d28d9;
    --checkout-pink: #e0136b;
}

.registro-step-pago.is-active {
    text-align: left;
    padding: 0;
}

/* Indicateur d'étape */
.checkout-stepper {
    display: flex;
    align-items: center;
    gap: 14px;
    margin: 0 0 18px;
}

.checkout-step-badge {
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--checkout-purple);
    color: #fff;
    font-weight: 800;
    font-size: 0.95rem;
    box-shadow: 0 0 0 4px rgba(109, 40, 217, 0.25);
}

.checkout-step-head {
    display: flex;
    flex-direction: column;
}

.checkout-step-title {
    color: #fff;
    font-size: 1.5rem;
    font-weight: 800;
    line-height: 1.1;
}

.checkout-step-next {
    color: #a1a1aa;
    font-size: 0.85rem;
    margin-top: 2px;
}

/* Carte blanche */
.checkout-card,
.checkout-summary {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    margin-bottom: 18px;
}

.checkout-card {
    position: relative;
    z-index: 0;
    padding: 22px;
    overflow: hidden;
}

/* Contorno animado (gradiente púrpura / rosa / dorado) */
.checkout-card::before {
    content: "";
    position: absolute;
    inset: -3px;
    border-radius: 18px;
    background: linear-gradient(
        90deg,
        #6d28d9,
        #a855f7,
        #e0136b,
        #fbbf24,
        #6d28d9
    );
    background-size: 300% 300%;
    animation: checkoutCardBorderFlow 4s linear infinite;
    z-index: -2;
}

.checkout-card::after {
    content: "";
    position: absolute;
    inset: 2px;
    border-radius: 14px;
    background: #fff;
    z-index: -1;
}

@keyframes checkoutCardBorderFlow {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .checkout-card::before {
        animation: none;
        background: linear-gradient(90deg, #6d28d9, #a855f7);
    }
}

.checkout-card-head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 4px;
}

.checkout-card-icon {
    display: inline-flex;
    color: var(--checkout-purple);
    font-size: 1.2rem;
}

.checkout-card-title {
    color: #1f2433;
    font-size: 1.25rem;
    font-weight: 800;
}

.checkout-card-sub {
    color: #6b7280;
    font-size: 0.92rem;
    margin: 0 0 16px;
}

/* Méthodes de paiement façon radio */
.checkout-method {
    position: relative;
    display: flex;
    align-items: center;
    gap: 14px;
    border: 2px solid #e5e7eb;
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 12px;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.checkout-method:last-of-type {
    margin-bottom: 0;
}

.checkout-method input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    pointer-events: none;
}

.checkout-method-radio {
    flex-shrink: 0;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 2px solid #c4c4cc;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.2s ease;
}

.checkout-method-radio::after {
    content: "";
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: var(--checkout-purple);
    transform: scale(0);
    transition: transform 0.2s ease;
}

.checkout-method:has(input:checked) {
    border-color: var(--checkout-purple);
    box-shadow: 0 0 0 1px var(--checkout-purple);
}

.checkout-method:has(input:checked) .checkout-method-radio {
    border-color: var(--checkout-purple);
}

.checkout-method:has(input:checked) .checkout-method-radio::after {
    transform: scale(1);
}

.checkout-method input:focus-visible + .checkout-method-radio {
    outline: 2px solid var(--checkout-purple);
    outline-offset: 2px;
}

.checkout-method-info {
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: 3px;
    min-width: 0;
}

.checkout-method-name {
    color: #1f2433;
    font-weight: 800;
    font-size: 1rem;
}

.checkout-method-desc {
    color: #6b7280;
    font-size: 0.82rem;
}

.checkout-method-logo {
    flex-shrink: 0;
    color: #1f2433;
    font-size: 1.55rem;
}

.checkout-method:has(input:checked) .checkout-method-logo {
    color: var(--checkout-purple);
}

/* ───────────────────────── MACH Pay — opción premium ─────────────────────────
   Morado corporativo #2B0073 + acento verde neón #00F0B5. Comparte las clases
   base .checkout-method (mismo padding / margin / alineación flexbox) y solo
   sobrescribe el estado :hover / :checked para resaltar sin romper la lista. */
.checkout-method--mach {
    align-items: center;
}

/* Ícono billetera: trazo morado de marca en reposo. */
.checkout-method--mach .mach-icon {
    color: #2b0073;
    display: inline-flex;
    align-items: center;
    transition: color 0.2s ease;
}

.checkout-method--mach .mach-icon svg {
    display: block;
}

/* Hover: anticipa el acento verde neón antes de seleccionar. */
.checkout-method--mach:hover {
    border-color: #00f0b5;
}

.checkout-method--mach:hover .mach-icon {
    color: #00f0b5;
}

/* Seleccionado: borde verde neón + fondo morado translúcido (premium dark). */
.checkout-method--mach:has(input:checked) {
    border-color: #00f0b5;
    background: rgba(43, 0, 115, 0.2);
    box-shadow: 0 0 0 1px #00f0b5, 0 8px 22px rgba(0, 240, 181, 0.18);
}

/* Radio personalizado bicolor: anillo verde neón, punto morado MACH. */
.checkout-method--mach:has(input:checked) .checkout-method-radio {
    border-color: #00f0b5;
}

.checkout-method--mach:has(input:checked) .checkout-method-radio::after {
    background: #2b0073;
    transform: scale(1);
}

/* Ícono billetera en verde neón al seleccionar. */
.checkout-method--mach:has(input:checked) .mach-icon {
    color: #00f0b5;
}

.checkout-method--mach input:focus-visible + .checkout-method-radio {
    outline-color: #00f0b5;
}

/* Note présentiel + logos à l'intérieur de la carte blanche */
.checkout-card .registro-mode-note {
    color: #5b21b6;
    background: rgba(109, 40, 217, 0.06);
    border: 1px solid rgba(109, 40, 217, 0.25);
    margin-top: 14px;
}

.checkout-card #registro-step-payment-logos {
    margin-top: 14px;
}

/* Lien retour */
.checkout-back-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    margin: 0 0 18px;
    padding: 6px;
    background: none;
    border: none;
    cursor: pointer;
    color: #c4b5fd;
    font-weight: 700;
    font-size: 0.95rem;
    text-decoration: underline;
}

.checkout-back-link:hover {
    color: #fff;
}

/* Résumé de commande */
.checkout-summary {
    padding: 18px 22px;
}

.checkout-summary-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #ececf1;
    padding-bottom: 12px;
    margin-bottom: 12px;
}

.checkout-summary-title {
    color: #1f2433;
    font-size: 1.15rem;
    font-weight: 800;
}

.checkout-summary-head i {
    color: #6b7280;
}

.checkout-summary-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    color: #5b21b6;
    font-weight: 700;
    font-size: 1rem;
}

.checkout-summary-amount {
    color: #5b21b6;
    font-weight: 800;
    text-align: right;
}

.checkout-amount-ref {
    display: block;
    margin-top: 2px;
    color: #6b7280;
    font-size: 0.78rem;
    font-weight: 600;
}

.checkout-summary .pack-pay-original {
    display: block;
    color: #9ca3af;
    text-decoration: line-through;
    font-size: 0.85rem;
}

.checkout-summary .pack-pay-sale {
    display: block;
    color: #5b21b6;
    font-size: 1.2rem;
    font-weight: 900;
}

/* Bouton de paiement principal */
.checkout-pay-btn {
    width: 100%;
    border: none;
    cursor: pointer;
    background: var(--checkout-pink);
    color: #fff;
    font-weight: 800;
    font-size: 1.05rem;
    letter-spacing: 0.02em;
    padding: 16px;
    border-radius: 12px;
    box-shadow: 0 12px 24px rgba(224, 19, 107, 0.35);
    transition: transform 0.2s ease, filter 0.2s ease;
}

.checkout-pay-btn:hover {
    transform: translateY(-2px);
    filter: brightness(1.05);
}

.checkout-pay-btn:disabled {
    opacity: 0.7;
    cursor: default;
    transform: none;
}

.checkout-hidden-trigger {
    display: none !important;
}

@media (max-width: 900px) {
    .checkout-step-title {
        font-size: 1.25rem;
        white-space: normal;
    }

    .checkout-step-badge {
        width: 50px;
        height: 50px;
    }

    .checkout-card {
        padding: 18px;
    }
}
