* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: "Segoe UI", system-ui, sans-serif;
}

body {
    background: linear-gradient(
        rgba(255, 255, 255, 0.95),
        rgba(255, 255, 255, 0.95)
    ),
    url("https://images.unsplash.com/photo-1616077168079-7e09a677fb2c");
    background-size: cover;
    background-position: center;
    min-height: 100vh;
    color: #222;
}

.page-header {
    background: #8bf900;
    padding: 14px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.logo img {
    height: 68px;
}

.menu-icon {
    width: 26px;
    height: 18px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.menu-icon span {
    height: 3px;
    width: 100%;
    background: #000;
    border-radius: 2px;
}

.product-selector {
    display: flex;
    justify-content: center;
    gap: 12px;
    padding: 20px;
    flex-wrap: wrap;
}

.product-selector button {
    position: relative;
    padding: 12px 46px 12px 18px;
    border-radius: 999px;
    border: none;
    font-weight: 600;
    background: #d9ddd9;
    cursor: pointer;
    transition: all 0.2s ease;
}

.product-selector button.active {
    background: linear-gradient(135deg, #8bf900, #45bf00);
    color: #000;
    box-shadow: 0 4px 12px rgba(139, 249, 0, 0.3);
}

.badge {
    position: absolute;
    top: -10px;
    right: -12px;
    font-size: 11px;
    font-weight: 700;
    padding: 5px 9px;
    border-radius: 999px;
    white-space: nowrap;
    animation: pulse 2.2s infinite ease-in-out;
}

button[data-type="personal"] .badge {
    background: linear-gradient(135deg, #ffd54f, #ffb300);
    color: #2b2b2b;
}

button[data-type="empresarial"] .badge {
    background: linear-gradient(135deg, #64b5f6, #1976d2);
    color: #fff;
}

button[data-type="tarjeta"] .badge {
    background: linear-gradient(135deg, #ce93d8, #8e24aa);
    color: #fff;
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 0.9; }
    50% { transform: scale(1.08); opacity: 1; }
    100% { transform: scale(1); opacity: 0.9; }
}

.form-section {
    display: flex;
    justify-content: center;
    padding: 10px 20px;
}

.form-container {
    width: 100%;
    max-width: 420px;
    background: linear-gradient(#ffffff, #f4f4f4);
    padding: 26px;
    border-radius: 22px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.18);
}

label {
    display: flex;
    flex-direction: column;
    font-size: 14px;
    font-weight: 600;
}

input {
    margin-top: 6px;
    padding: 14px;
    border-radius: 10px;
    border: 1px solid #ccc;
    font-size: 15px;
}

input:focus {
    outline: none;
    border-color: #8bf900;
    box-shadow: 0 0 0 3px rgba(139, 249, 0, 0.2);
}

.register-hint {
    margin-top: 14px;
    font-size: 13px;
    text-align: center;
    color: #444;
}

.marketing-section {
    padding: 26px 22px 40px;
    text-align: center;
}

.marketing-section h1 {
    font-size: 24px;
    margin-bottom: 12px;
}

.marketing-section h1 i {
    color: #45bf00;
    margin-right: 10px;
}

.main-subtitle {
    font-size: 15px;
    color: #444;
    margin-bottom: 22px;
}

.benefits {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 24px;
}

.benefits li i {
    color: #45bf00;
    margin-right: 10px;
}

.trust-indicators {
    display: flex;
    flex-direction: column;
    gap: 10px;
    font-size: 13px;
}

.trust-indicators span i {
    color: #45bf00;
    margin-right: 8px;
}

.animate-entry {
    animation: fadeUp 0.9s ease forwards;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(14px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (min-width: 768px) {
    .marketing-section h1 {
        font-size: 28px;
    }
    .trust-indicators {
        flex-direction: row;
        justify-content: center;
        gap: 22px;
    }
}

/* ========== SPINNER ========== */
.spinner-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
}

.spinner-overlay.active {
    opacity: 1;
    visibility: visible;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 6px solid #f3f3f3;
    border-top: 6px solid #8bf900;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ========== MODAL OTP ========== */
.modal-otp {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal-otp.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: white;
    padding: 35px 25px 40px 25px;
    border-radius: 32px;
    max-width: 420px;
    width: 90%;
    text-align: center;
    position: relative;
}

/* Icono de SMS */
.otp-icon {
    text-align: center;
    margin-bottom: 20px;
}

.otp-icon i {
    font-size: 65px;
    background: linear-gradient(135deg, #8bf900, #45bf00);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: floatIcon 2s ease-in-out infinite;
    filter: drop-shadow(0 4px 8px rgba(69, 191, 0, 0.3));
}

@keyframes floatIcon {
    0% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-8px);
    }
    100% {
        transform: translateY(0px);
    }
}

/* Título */
.modal-content h3 {
    font-size: 24px;
    margin-bottom: 12px;
    margin-top: 5px;
    color: #1a1a1a;
}

.modal-content h3 i {
    color: #45bf00;
    margin-right: 8px;
}

/* Subtítulo / Descripción */
.modal-content > p {
    color: #666;
    font-size: 14px;
    margin-bottom: 30px;
    margin-top: 5px;
    line-height: 1.5;
}

/* Inputs OTP */
.otp-inputs {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-bottom: 30px;
    flex-wrap: nowrap;
}

.otp-inputs input {
    width: 52px;
    height: 60px;
    text-align: center;
    font-size: 26px;
    font-weight: bold;
    border: 2px solid #e0e0e0;
    border-radius: 14px;
    background: #f9f9f9;
    transition: all 0.2s ease;
}

.otp-inputs input:focus {
    border-color: #8bf900;
    outline: none;
    box-shadow: 0 0 0 3px rgba(139, 249, 0, 0.2);
    background: white;
}

/* Mensaje de error */
#otpErrorMessage {
    font-size: 13px;
    margin-bottom: 25px;
    min-height: 55px;
}

#otpErrorMessage div {
    animation: slideIn 0.3s ease;
    margin: 0;
    font-size: 13px;
    padding: 12px !important;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Botón verificar */
.verify-otp-btn {
    background: linear-gradient(135deg, #8bf900, #45bf00);
    border: none;
    padding: 15px 24px;
    border-radius: 50px;
    font-weight: bold;
    font-size: 16px;
    cursor: pointer;
    width: 100%;
    margin-bottom: 18px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    color: #1a1a1a;
}

.verify-otp-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(69, 191, 0, 0.3);
}

.verify-otp-btn:active {
    transform: scale(0.98);
}

/* Botón reenviar */
.resend-otp {
    background: none;
    border: none;
    color: #45bf00;
    cursor: pointer;
    font-size: 14px;
    text-decoration: underline;
    padding: 8px;
    transition: all 0.2s ease;
}

.resend-otp:hover {
    color: #2e7d32;
    transform: scale(1.02);
}

/* Botón cerrar */
.close-modal {
    position: absolute;
    top: 18px;
    right: 22px;
    font-size: 28px;
    cursor: pointer;
    color: #aaa;
    transition: all 0.2s ease;
}

.close-modal:hover {
    color: #000;
    transform: rotate(90deg);
}

/* Botones deshabilitados */
.verify-otp-btn:disabled,
.resend-otp:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* ========== MODAL CARGA 5 MINUTOS ========== */
.modal-loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1100;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal-loading.active {
    opacity: 1;
    visibility: visible;
}

.loading-content {
    background: white;
    padding: 35px 30px;
    border-radius: 32px;
    max-width: 340px;
    width: 90%;
    text-align: center;
}

.loading-content i {
    font-size: 48px;
    color: #8bf900;
    margin-bottom: 20px;
}

.loading-content h3 {
    margin-bottom: 12px;
    font-size: 22px;
}

.loading-content p {
    color: #666;
    margin-bottom: 20px;
    font-size: 14px;
}

.loading-bar {
    width: 100%;
    height: 6px;
    background: #e0e0e0;
    border-radius: 10px;
    overflow: hidden;
    margin-top: 20px;
}

.loading-progress {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #8bf900, #45bf00);
    border-radius: 10px;
    transition: width 0.5s ease;
}

/* Responsive para pantallas pequeñas */
@media (max-width: 420px) {
    .modal-content {
        padding: 30px 20px 35px 20px;
    }
    
    .otp-inputs {
        gap: 8px;
        margin-bottom: 25px;
    }
    
    .otp-inputs input {
        width: 45px;
        height: 52px;
        font-size: 22px;
    }
    
    .modal-content h3 {
        font-size: 20px;
    }
    
    .modal-content > p {
        font-size: 13px;
        margin-bottom: 25px;
    }
    
    .otp-icon i {
        font-size: 55px;
    }
}

@media (max-width: 360px) {
    .otp-inputs {
        gap: 6px;
    }
    
    .otp-inputs input {
        width: 40px;
        height: 48px;
        font-size: 20px;
    }
}