/* ========================================
    RESET Y VARIABLES
======================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --color-primary: #1E40AF;
    --color-primary-light: #3B82F6;
    --color-primary-bg: #EFF6FF;
    --color-cta: #10B981;
    --color-cta-hover: #059669;
    --color-text: #1F2937;
    --color-text-secondary: #6B7280;
    --color-border: #E5E7EB;
    --color-error: #EF4444;
    --color-bg: #F9FAFB;
    --color-white: #FFFFFF;
    --color-stars: #FBBF24;
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --border-radius: 8px;
    --border-radius-lg: 12px;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --transition: all 0.2s ease-in-out;
    
    --color-strength-weak: #EF4444;
    --color-strength-fair: #F59E0B;
    --color-strength-good: #10B981;
    --color-strength-strong: #059669;
}

body {
    font-family: var(--font-family);
    background-color: var(--color-bg);
    color: var(--color-text);
    line-height: 1.6;
}

/* ========================================
    HEADER
======================================== */
.header {
    background-color: var(--color-white);
    padding: 16px 24px;
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-container {
    max-width: 1000px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 40px;
    width: auto;
}

.header-phone {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--color-primary);
    font-weight: 600;
    text-decoration: none;
    font-size: 14px;
}

.header-phone:hover {
    color: var(--color-primary-light);
}

/* ========================================
    CONTENEDOR PRINCIPAL
======================================== */
.main-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 32px 20px 100px;
}

/* ========================================
    TÍTULO PRINCIPAL
======================================== */
.page-title {
    text-align: center;
    margin-bottom: 32px;
}

.page-title h1 {
    font-size: 28px;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 8px;
}

.page-title p {
    font-size: 16px;
    color: var(--color-text-secondary);
}

/* ========================================
    SECCIONES / CARDS
======================================== */
.section-card {
    background-color: var(--color-white);
    border-radius: var(--border-radius-lg);
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--color-border);
}

.section-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ========================================
    PLAN SELECCIONADO
======================================== */
.plan-selected-box {
    background-color: var(--color-primary-bg);
    border: 2px solid var(--color-primary);
    border-radius: var(--border-radius);
    padding: 16px 20px;
    margin-bottom: 16px;
}

.plan-selected-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    flex-wrap: wrap;
    gap: 8px;
}

.plan-selected-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--color-primary);
}

.plan-selected-price {
    font-size: 20px;
    font-weight: 700;
    color: var(--color-cta);
}

.plan-selected-features {
    font-size: 14px;
    color: var(--color-text-secondary);
}

.plan-selected-features span {
    margin-right: 12px;
}

.periodo-selector {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.periodo-selector label {
    font-size: 14px;
    font-weight: 500;
    color: var(--color-text);
}

.periodo-selector select {
    flex: 1;
    max-width: 280px;
    padding: 10px 16px;
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    font-size: 14px;
    font-family: var(--font-family);
    background-color: var(--color-white);
    cursor: pointer;
    transition: var(--transition);
}

.periodo-selector select:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

.link-otros-planes {
    font-size: 14px;
    color: var(--color-primary);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.link-otros-planes:hover {
    text-decoration: underline;
}

/* ========================================
    FORMULARIO - FILAS
======================================== */
.form-rows {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-row {
    width: 100%;
}

.form-row.two-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

@media (max-width: 600px) {
    .form-row.two-columns {
        grid-template-columns: 1fr;
    }
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 14px;
    font-weight: 500;
    color: var(--color-text);
}

.form-group label .required {
    color: var(--color-error);
}

.form-group input {
    padding: 12px 16px;
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    font-size: 14px;
    font-family: var(--font-family);
    transition: var(--transition);
    width: 100%;
}

.form-group input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

.form-group input::placeholder {
    color: var(--color-text-secondary);
}

.form-group input.error {
    border-color: var(--color-error);
}

.form-group .error-message {
    font-size: 12px;
    color: var(--color-error);
    display: none;
}

.form-group .error-message.show {
    display: block;
}

/* ========================================
    PASSWORD INPUT CON TOGGLE
======================================== */
.password-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.password-input-wrapper input {
    width: 100%;
    padding-right: 48px;
}

.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-text-secondary);
    transition: var(--transition);
}

.password-toggle:hover {
    color: var(--color-primary);
}

.password-toggle:focus {
    outline: none;
}

.password-toggle .icon-eye {
    width: 20px;
    height: 20px;
}

/* ========================================
    INDICADOR DE FORTALEZA DE PASSWORD
======================================== */
.password-strength {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 4px;
    opacity: 0;
    height: 0;
    overflow: hidden;
    transition: opacity 0.3s ease, height 0.3s ease, margin 0.3s ease;
}

.password-strength.visible {
    opacity: 1;
    height: 20px;
    margin-top: 8px;
}

.password-strength-bar {
    flex: 1;
    height: 4px;
    background-color: var(--color-border);
    border-radius: 2px;
    overflow: hidden;
}

.password-strength-fill {
    height: 100%;
    width: 0;
    border-radius: 2px;
    transition: width 0.3s ease, background-color 0.3s ease;
}

.password-strength-fill.debil {
    background-color: var(--color-strength-weak);
}

.password-strength-fill.regular {
    background-color: var(--color-strength-fair);
}

.password-strength-fill.buena {
    background-color: var(--color-strength-good);
}

.password-strength-fill.fuerte {
    background-color: var(--color-strength-strong);
}

.password-strength-text {
    font-size: 12px;
    font-weight: 500;
    min-width: 50px;
    text-align: right;
}

.password-strength-text.debil {
    color: var(--color-strength-weak);
}

.password-strength-text.regular {
    color: var(--color-strength-fair);
}

.password-strength-text.buena {
    color: var(--color-strength-good);
}

.password-strength-text.fuerte {
    color: var(--color-strength-strong);
}

/* ========================================
    MÉTODO DE PAGO
======================================== */
.payment-methods {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

@media (max-width: 500px) {
    .payment-methods {
        grid-template-columns: 1fr;
    }
}

.payment-method-card {
    border: 2px solid var(--color-border);
    border-radius: var(--border-radius-lg);
    padding: 20px;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
}

.payment-method-card:hover {
    border-color: var(--color-primary-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.payment-method-card.selected {
    border-color: var(--color-primary);
    background-color: var(--color-primary-bg);
}

.payment-method-card .icon {
    font-size: 32px;
    margin-bottom: 8px;
}

.payment-method-card .title {
    font-size: 16px;
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: 4px;
}

.payment-method-card .description {
    font-size: 13px;
    color: var(--color-text-secondary);
    margin-bottom: 8px;
}

.payment-method-card .payment-options {
    font-size: 12px;
    color: var(--color-primary);
    font-weight: 500;
    margin-top: 8px;
    margin-bottom: 12px;
    padding: 4px 12px;
    background-color: var(--color-primary-bg);
    border-radius: 20px;
    display: inline-block;
}

.payment-method-card.selected .payment-options {
    background-color: var(--color-white);
}

.payment-method-card .radio-indicator {
    width: 20px;
    height: 20px;
    border: 2px solid var(--color-border);
    border-radius: 50%;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.payment-method-card.selected .radio-indicator {
    border-color: var(--color-primary);
}

.payment-method-card.selected .radio-indicator::after {
    content: '';
    width: 10px;
    height: 10px;
    background-color: var(--color-primary);
    border-radius: 50%;
}

/* ========================================
    BOTÓN CTA
======================================== */
.cta-container {
    text-align: center;
    margin-top: 24px;
}

.btn-cta {
    background-color: var(--color-cta);
    color: var(--color-white);
    border: none;
    padding: 16px 48px;
    font-size: 16px;
    font-weight: 600;
    font-family: var(--font-family);
    border-radius: var(--border-radius-lg);
    cursor: pointer;
    transition: var(--transition);
    box-shadow: var(--shadow-md);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-cta:hover {
    background-color: var(--color-cta-hover);
    transform: scale(1.02);
    box-shadow: var(--shadow-lg);
}

.btn-cta:disabled {
    background-color: var(--color-text-secondary);
    cursor: not-allowed;
    transform: none;
}

.secure-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 12px;
    font-size: 13px;
    color: var(--color-text-secondary);
}

/* ========================================
    BENEFICIOS INLINE
======================================== */
.benefits-inline {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 24px;
    padding: 20px 0;
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
    margin: 24px 0;
}

.benefit-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: var(--color-text);
}

.benefit-item .check {
    color: var(--color-cta);
    font-weight: bold;
}

/* ========================================
    TESTIMONIOS
======================================== */
.testimonials-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 600px) {
    .testimonials-grid {
        grid-template-columns: 1fr;
    }
}

.testimonial-card {
    background-color: var(--color-white);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius-lg);
    padding: 20px;
}

.testimonial-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.testimonial-photo {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--color-primary-bg);
}

.testimonial-info {
    flex: 1;
}

.testimonial-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--color-text);
}

.testimonial-business {
    font-size: 13px;
    color: var(--color-text-secondary);
}

.testimonial-stars {
    color: var(--color-stars);
    font-size: 14px;
    letter-spacing: 2px;
}

.testimonial-text {
    font-size: 14px;
    color: var(--color-text);
    font-style: italic;
    line-height: 1.6;
}

/* ========================================
    SELLOS DE CONFIANZA
======================================== */
.trust-badges {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    text-align: center;
}

@media (max-width: 600px) {
    .trust-badges {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

.trust-badge {
    padding: 20px;
}

.trust-badge img {
    height: 48px;
    margin-bottom: 12px;
    opacity: 0.9;
}

.trust-badge .badge-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: 4px;
}

.trust-badge .badge-description {
    font-size: 12px;
    color: var(--color-text-secondary);
}

/* ========================================
    SECCIÓN WHATSAPP
======================================== */
.whatsapp-section {
    background-color: var(--color-primary-bg);
    border-radius: var(--border-radius-lg);
    padding: 24px;
    text-align: center;
}

.whatsapp-section h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: 12px;
}

.btn-whatsapp {
    background-color: #25D366;
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 600;
    font-family: var(--font-family);
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.btn-whatsapp:hover {
    background-color: #128C7E;
    transform: scale(1.02);
}

.whatsapp-section .hours {
    font-size: 13px;
    color: var(--color-text-secondary);
    margin-top: 12px;
}

/* ========================================
    FOOTER
======================================== */
.footer {
    background-color: var(--color-white);
    border-top: 1px solid var(--color-border);
    padding: 20px;
    text-align: center;
}

.footer-content {
    max-width: 900px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.footer-logo img {
    height: 28px;
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-links a {
    font-size: 13px;
    color: var(--color-text-secondary);
    text-decoration: none;
}

.footer-links a:hover {
    color: var(--color-primary);
}

.footer-copyright {
    font-size: 13px;
    color: var(--color-text-secondary);
}

@media (max-width: 600px) {
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
}

/* ========================================
    BOTÓN FLOTANTE WHATSAPP
======================================== */
.whatsapp-float {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 60px;
    height: 60px;
    background-color: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    cursor: pointer;
    transition: var(--transition);
    z-index: 1000;
    text-decoration: none;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 12px 24px rgba(37, 211, 102, 0.4);
}

.whatsapp-float svg {
    width: 32px;
    height: 32px;
    fill: white;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.4); }
    70% { box-shadow: 0 0 0 15px rgba(37, 211, 102, 0); }
    100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

.whatsapp-float {
    animation: pulse 2s infinite;
}

/* ========================================
    MOBILE CTA FIJO
======================================== */
@media (max-width: 768px) {
    .mobile-cta-fixed {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        background-color: var(--color-white);
        padding: 16px 20px;
        box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.1);
        z-index: 999;
    }

    .mobile-cta-fixed .btn-cta {
        width: 100%;
        justify-content: center;
    }

    .main-container {
        padding-bottom: 120px;
    }

    .whatsapp-float {
        bottom: 90px;
    }

    .cta-container.desktop-only {
        display: none;
    }
}

@media (min-width: 769px) {
    .mobile-cta-fixed {
        display: none;
    }
}

/* ========================================
    MODAL DE PROCESAMIENTO
======================================== */
.processing-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.processing-modal.visible {
    opacity: 1;
    visibility: visible;
}

.processing-modal-content {
    background: var(--color-white);
    padding: 48px 40px;
    border-radius: 20px;
    text-align: center;
    max-width: 400px;
    width: 90%;
    margin: 20px;
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.processing-modal.visible .processing-modal-content {
    transform: scale(1);
}

.processing-spinner {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.spinner-ring {
    width: 64px;
    height: 64px;
    border: 4px solid var(--color-primary-bg);
    border-top-color: var(--color-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.error-icon {
    width: 64px;
    height: 64px;
    background-color: var(--color-error);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: white;
    font-weight: bold;
    animation: shake 0.5s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-8px); }
    40%, 80% { transform: translateX(8px); }
}

.processing-success {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
}

.success-checkmark svg {
    width: 80px;
    height: 80px;
}

.checkmark-circle {
    stroke: var(--color-cta);
    stroke-width: 2;
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    animation: stroke 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.checkmark-check {
    stroke: var(--color-cta);
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    animation: stroke 0.3s cubic-bezier(0.65, 0, 0.45, 1) 0.6s forwards;
}

@keyframes stroke {
    100% {
        stroke-dashoffset: 0;
    }
}

.processing-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--color-text);
    margin-bottom: 8px;
}

.processing-step {
    font-size: 15px;
    color: var(--color-text-secondary);
    margin-bottom: 24px;
    min-height: 24px;
}

.processing-steps-indicator {
    display: flex;
    justify-content: center;
    gap: 12px;
}

.step-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: var(--color-border);
    transition: all 0.3s ease;
}

.step-dot.active {
    background-color: var(--color-primary);
    transform: scale(1.2);
    animation: pulse-dot 1s ease infinite;
}

.step-dot.completed {
    background-color: var(--color-cta);
}

@keyframes pulse-dot {
    0%, 100% { transform: scale(1.2); }
    50% { transform: scale(1); }
}

/* ========================================
    UTILITIES
======================================== */
.text-center { text-align: center; }
.mb-0 { margin-bottom: 0; }