/* 
Theme Name: Hello Elementor Child
Theme URI: https://github.com/elementor/hello-theme-child/
Description: Hello Elementor Child is a child theme of Hello Elementor, created by Elementor team
Author: Elementor Team
Author URI: https://elementor.com/
Template: hello-elementor
Version: 2.0.0
Text Domain: hello-elementor-child
License: GNU General Public License v3 or later.
License URI: https://www.gnu.org/licenses/gpl-3.0.html
Tags: flexible-header, custom-colors, custom-menu, custom-logo, editor-style, featured-images, rtl-language-support, threaded-comments, translation-ready
*/

/* --- VARIABLES Y BASE --- */
:root {
    --brand-p: #310135; 
    --brand-p-dark: #1a011f; 
    --brand-s: #db0082;
    --green: #C4F955; 
    --white: #ffffff; 
    --text-main: #1e293b;
    --text-muted: #94a3b8;
    --radius-xl: 35px; 
    --radius-md: 22px;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset básico para asegurar que Hello Elementor no interfiera */
* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Plus Jakarta Sans', sans-serif; -webkit-tap-highlight-color: transparent; }
body { background: #F8F9FC; color: var(--text-main); overflow-x: hidden; line-height: 1.5; }
.wrapper { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* --- ANIMACIONES --- */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}
.reveal { animation: fadeInUp 0.8s ease-out forwards; opacity: 0; }
.delay-1 { animation-delay: 0.2s; }
.delay-2 { animation-delay: 0.4s; }

/* --- NAVEGACIÓN --- */
nav {
    position: fixed; top: 0; width: 100%; z-index: 1000;
    background: rgba(26, 1, 31, 0.95); backdrop-filter: blur(15px);
    padding: 12px 0; border-bottom: 1px solid rgba(255,255,255,0.08);
}
.nav-inner { display: flex; justify-content: space-between; align-items: center; }

/* FIX PARA LOGO GIGANTE EN WORDPRESS */
.logo-img { 
    height: clamp(40px, 8vw, 55px) !important; 
    width: auto !important; 
    max-width: 250px !important; /* Límite de seguridad */
    transition: var(--transition); 
}

.social-tag {
    background: linear-gradient(45deg, #f09433, #bc1888);
    color: white; padding: 10px 20px; border-radius: 50px;
    font-size: 0.85rem; font-weight: 700; text-decoration: none;
    display: flex; align-items: center; gap: 8px;
}

/* --- HERO --- */
.hero {
    background: radial-gradient(circle at 80% 20%, #4a0250, var(--brand-p-dark));
    min-height: 100vh; padding: 140px 0 80px;
    display: flex; align-items: center; position: relative;
}
.hero-grid { display: flex; flex-direction: column; align-items: center; gap: 50px; text-align: center; }
@media (min-width: 1024px) { 
    .hero-grid { flex-direction: row; text-align: left; gap: 80px; } 
    .hero-col-text { flex: 1.2; } 
    .hero-col-calc { flex: 0.8; } 
}

.hero-text h1 { font-size: clamp(2.5rem, 7vw, 4.2rem); color: white; font-weight: 800; letter-spacing: -2px; margin-bottom: 25px; line-height: 1.1; }
.hero-text h1 span { color: var(--brand-s); }
.hero-text p { color: rgba(255,255,255,0.7); font-size: clamp(1.1rem, 2.5vw, 1.3rem); margin-bottom: 40px; max-width: 650px; margin-left: auto; margin-right: auto; }

/* --- CALCULADORA --- */
.hero-col-calc { width: 100%; max-width: 480px; }
.glass-calc {
    background: rgba(255, 255, 255, 0.05); backdrop-filter: blur(40px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    padding: clamp(25px, 5vw, 40px); border-radius: var(--radius-xl);
    box-shadow: 0 40px 100px rgba(0,0,0,0.4);
}
.rate-header { display: flex; align-items: center; gap: 15px; margin-bottom: 30px; }
.rate-dash { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; flex-grow: 1; }
.rate-item { background: rgba(0,0,0,0.25); padding: 14px; border-radius: 18px; text-align: center; border: 1px solid rgba(255,255,255,0.05); }
.rate-item small { display: block; font-size: 0.65rem; color: var(--brand-s); font-weight: 800; text-transform: uppercase; margin-bottom: 4px; }
.rate-item strong { color: white; font-size: 1.3rem; font-weight: 800; }

.btn-refresh {
    background: var(--brand-s); color: white; border: none;
    width: 55px; height: 55px; border-radius: 18px;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; transition: var(--transition); font-size: 1.5rem;
    box-shadow: 0 10px 20px rgba(219, 0, 130, 0.2);
}
.btn-refresh.loading i { animation: spin 1s linear infinite; }
@keyframes spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }

.input-box { background: rgba(0,0,0,0.3); padding: 25px; border-radius: var(--radius-md); border: 1px solid rgba(255,255,255,0.05); text-align: left; }
.input-box label { display: block; font-size: 0.75rem; color: rgba(255,255,255,0.5); font-weight: 700; text-transform: uppercase; margin-bottom: 10px; }
.input-box input { background: transparent; border: none; width: 100%; color: white; font-size: clamp(1.8rem, 4vw, 2.4rem); font-weight: 800; outline: none; }

.swap-circle { width: 60px; height: 60px; background: var(--brand-s); color: white; border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: -30px auto; position: relative; z-index: 10; cursor: pointer; border: 6px solid #28022d; transition: var(--transition); box-shadow: 0 10px 20px rgba(0,0,0,0.2); }
.swap-circle:hover { transform: rotate(180deg); }

.res-display { background: rgba(196, 249, 85, 0.05); padding: 30px; border-radius: var(--radius-md); margin-top: 20px; border: 1px solid rgba(196, 249, 85, 0.1); text-align: right; }
.res-display label { display:block; font-size:0.75rem; color:rgba(255,255,255,0.4); font-weight:700; text-transform:uppercase; margin-bottom:8px; }
.res-val { display: block; font-size: clamp(2.2rem, 5vw, 3rem); font-weight: 800; color: var(--green); line-height: 1; }

/* --- MARQUEE --- */
.marquee { background: var(--brand-s); padding: 18px 0; transform: rotate(-1.5deg); margin-top: -35px; position: relative; z-index: 20; border-top: 0px solid white; border-bottom: 0px solid white; }
.marquee-inner { display: flex; gap: 50px; animation: scroll 30s linear infinite; font-weight: 800; color: white; text-transform: uppercase; white-space: nowrap; font-size: 1.1rem; }
@keyframes scroll { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }

/* --- SECCIONES Y TARJETAS --- */
.section-wrap { padding: clamp(80px, 10vw, 120px) 0; }
.section-title { text-align: center; margin-bottom: 60px; }
.section-title h2 { font-size: clamp(2.2rem, 5vw, 3rem); font-weight: 800; color: var(--brand-p); letter-spacing: -1px; }

.grid-layout { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 30px; }
.card-premium { 
    background: white; padding: 60px 35px; border-radius: 40px; text-align: center; 
    box-shadow: 0 15px 40px rgba(0,0,0,0.03); border: 1px solid #f1f1f1; 
    transition: var(--transition); 
}
.card-premium:hover { transform: translateY(-12px); box-shadow: 0 30px 60px rgba(49, 1, 53, 0.1); border-color: var(--brand-s); }
.card-premium i { font-size: 3.5rem; color: var(--brand-s); margin-bottom: 25px; display: block; }
.card-premium h3 { font-size: 1.6rem; font-weight: 800; margin-bottom: 15px; }

/* --- ASESORES --- */
.card-asesor { padding: 30px 20px; border-radius: 35px; }
.card-asesor i { font-size: 2.2rem; }
.card-asesor h4 { font-size: 1.4rem; margin-bottom: 15px; }
.btn-wa-asesor { display: inline-flex; align-items: center; gap: 8px; background: var(--green); color: var(--brand-p); padding: 10px 50px; border-radius: 18px; font-weight: 800; text-decoration: none; transition: var(--transition); font-size: 0.95rem; }
.btn-wa-asesor:hover { transform: translateY(-3px); box-shadow: 0 10px 20px rgba(196, 249, 85, 0.4); }

/* --- FOOTER --- */
footer { 
    background: var(--brand-p-dark); 
    padding: 80px 0 40px !important; /* !important para evitar conflictos */
    text-align: center; 
    color: white; 
}
.footer-logo { 
    height: 60px !important; 
    width: auto !important; 
    margin: 0 auto 30px; 
    filter: brightness(0) invert(1);
    max-width: 200px !important; /* Límite de seguridad */
}
.legal-links { display: flex; justify-content: center; flex-wrap: wrap; gap: 15px; margin-bottom: 30px; }
.btn-legal { 
    background: rgba(255, 255, 255, 0.05); color: var(--white); 
    padding: 10px 22px; border-radius: 12px; font-size: 0.85rem; 
    text-decoration: none; font-weight: 600; border: 1px solid rgba(255,255,255,0.1);
    transition: 0.3s; cursor: pointer;
}
.btn-legal:hover { background: var(--brand-s); border-color: var(--brand-s); transform: translateY(-3px); }
.copy-text { opacity: 0.3; font-size: 0.8rem; }

/* --- COOKIES Y MODALES --- */
#cookie-banner {
    position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%);
    width: 90%; max-width: 800px; background: rgba(26, 1, 31, 0.98); 
    color: white; padding: 20px 30px; border-radius: 25px;
    display: none; justify-content: space-between; align-items: center; gap: 20px;
    z-index: 99999; border: 1px solid var(--brand-s); box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}
.btn-accept-cookie { background: var(--green); color: var(--brand-p); padding: 10px 25px; border-radius: 12px; font-weight: 800; border: none; cursor: pointer; transition: 0.3s; }

.modal-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(26, 1, 31, 0.95); z-index: 8000;
    display: none; align-items: center; justify-content: center; padding: 20px;
}
.modal-content {
    background: white; width: 100%; max-width: 750px; max-height: 85vh;
    border-radius: 35px; padding: clamp(30px, 6vw, 60px); overflow-y: auto; position: relative;
    color: var(--text-main); text-align: left;
}
.close-modal { position: absolute; top: 25px; right: 25px; font-size: 32px; color: var(--brand-p); cursor: pointer; }
.modal-content h3 { font-size: 1.8rem; font-weight: 800; color: var(--brand-p); margin-bottom: 25px; border-bottom: 3px solid var(--brand-s); padding-bottom: 12px; }
.modal-content h4 { font-size: 1.1rem; font-weight: 700; color: var(--brand-p); margin: 25px 0 10px; text-transform: uppercase; }
.modal-content p { font-size: 1rem; color: #475569; line-height: 1.8; margin-bottom: 15px; }

/* =========================================
   CORRECCIÓN FINAL MÓVIL (HEADER Y COOKIES)
   ========================================= */

@media (max-width: 900px) { /* Aumenté el rango para cubrir tablets verticales */
    
    /* 1. HEADER "BLINDADO" */
    nav {
        width: 100% !important;
        max-width: 100vw !important; /* Prohibido ser más ancho que la pantalla */
        overflow-x: hidden !important; /* Cortar cualquier sobrante */
        padding: 10px 0 !important;
        position: fixed !important;
        left: 0 !important;
        top: 0 !important;
    }

    .nav-inner {
        width: 100% !important;
        padding: 0 15px !important; /* Espacio seguro a los lados */
        display: flex !important;
        flex-direction: row !important; /* Siempre en fila */
        justify-content: space-between !important;
        align-items: center !important;
        box-sizing: border-box !important;
    }

    /* Logo más pequeño */
    .logo-img {
        height: 30px !important; /* Un poco más pequeño para dar espacio */
        width: auto !important;
    }

    /* Botón Instagram compacto */
    .social-tag {
        font-size: 0.6rem !important;
        padding: 6px 10px !important;
        white-space: nowrap !important; /* Evita que el texto baje de línea */
        max-width: 160px !important; /* Límite de ancho para el botón */
        text-overflow: ellipsis !important;
    }

    /* 2. COOKIE BANNER (Ajustado a la pantalla) */
    #cookie-banner {
        width: calc(100% - 30px) !important; /* 100% menos los márgenes */
        left: 15px !important;
        bottom: 15px !important;
        right: auto !important;
        transform: none !important;
        
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
        
        padding: 15px !important;
        margin: 0 !important;
        box-sizing: border-box !important;
        border-radius: 20px !important;
    }

    #cookie-banner p {
        font-size: 0.75rem !important;
        margin-bottom: 10px !important;
        width: 100% !important;
    }

    .btn-accept-cookie {
        width: 100% !important; /* Botón ancho completo */
        padding: 10px !important;
    }

    /* 3. HERO (Para que no se esconda detrás del header) */
    .hero {
        padding-top: 100px !important;
        overflow-x: hidden !important;
    }
}

/* --- BLOQUEO DE SELECCIÓN DE TEXTO --- */
body {
    -webkit-user-select: none; /* Chrome/Safari */
    -moz-user-select: none;    /* Firefox */
    -ms-user-select: none;     /* IE/Edge */
    user-select: none;         /* Estándar */
}

/* Permitir seleccionar solo en los inputs (para que puedan escribir el monto) */
input, textarea {
    -webkit-user-select: text !important;
    -moz-user-select: text !important;
    -ms-user-select: text !important;
    user-select: text !important;
}

/* --- FIX DE URGENCIA PARA MÓVIL --- */

/* 1. Controlar la Marquesina para que no ensanche la pantalla */
.marquee {
    width: 100vw !important;     /* Ancho exacto de la pantalla */
    max-width: 100% !important; 
    overflow: hidden !important; /* CORTAR lo que se salga */
    left: 0 !important;
    box-sizing: border-box !important;
}

/* 2. Forzar al navegador a respetar el ancho del móvil */
html, body {
    overflow-x: hidden !important; /* Prohibido el scroll lateral */
    width: 100% !important;
    position: relative;
}

/* 3. Ajuste específico para que la cinta no se vea gigante */
@media (max-width: 768px) {
    .marquee-inner {
        font-size: 0.8rem !important; /* Texto más pequeño en móvil */
    }
    .marquee {
        padding: 10px 0 !important; /* Cinta más delgada */
        margin-top: -20px !important; /* Ajustar posición */
    }
}

/* --- ESTILO DE LA DIRECCIÓN EN EL FOOTER --- */
.footer-address {
    color: rgba(255, 255, 255, 0.7); 
    font-size: 0.9rem;
    margin: 0 auto 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-weight: 500;
}

.footer-address i {
    color: var(--brand-s); /* Icono en color fucsia de tu marca */
    font-size: 1.2rem;
}

/* Ajuste para móviles */
@media (max-width: 768px) {
    .footer-address {
        font-size: 0.8rem;
        padding: 0 15px;
    }
}