/* --- CSS Variables: Minimalismo Moderno --- */
:root {
    /* Colores */
    --bg-white: #ffffff;
    --bg-light: #ffffff;
    --bg-card: #ffffff;
    --text-dark: var(--primary);
    --text-muted: #333333;

    /* Marca */
    --primary: #071939;
    --primary-hover: #38A57A;
    --secondary: #e5e5ea;

    /* Tipografía */
    --font-heading: 'Inter', sans-serif;
    --font-body: 'Inter', sans-serif;

    /* Spacing & Borders */
    --radius-lg: 0px;
    --radius-sm: 0px;
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* --- Base Reset --- */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font-body);
    background-color: var(--bg-white);
    color: var(--text-dark);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    font-size: 15px;
}
a { text-decoration: none; color: inherit; transition: var(--transition); }
ul { list-style: none; }
img { max-width: 100%; height: auto; display: block; }

.header-container {
    width: 100%;
    max-width: 1280px;
    padding: 0 5%;
    margin: 0 auto;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 5%;
}

/* --- Typography --- */
h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 400;
    line-height: 1.1;
    color: var(--text-dark);
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

h1 { font-size: clamp(2.2rem, 4.5vw, 3.8rem); margin-bottom: 24px; font-weight: 800; }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.5rem); margin-bottom: 20px; font-weight: 700; }
h3 { font-size: 1.25rem; margin-bottom: 12px; font-weight: 700; }
h4 { font-size: 0.95rem; margin-bottom: 8px; font-weight: 600; }
p { font-size: 0.95rem; }

/* --- Buttons --- */
.btn {
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    border-radius: 0;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: var(--transition);
    border: 1px solid transparent;
    font-family: var(--font-body);
}

.btn-primary {
    background-color: var(--primary-hover);
    color: #ffffff;
}

.btn-primary:hover {
    background-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.btn-secondary {
    background-color: transparent;
    border-color: var(--primary-hover);
    color: var(--primary-hover);
}

.btn-secondary:hover {
    background-color: var(--primary-hover);
    color: #ffffff;
}

.btn-outline {
    background-color: transparent;
    border-color: var(--primary-hover);
    color: var(--primary-hover);
}

.btn-outline:hover {
    background-color: var(--primary-hover);
    color: #ffffff;
}

/* Banner specific buttons (dark bg) */
.hero .btn-primary, .page-header .btn-primary { background-color: var(--primary-hover); color: #ffffff; }
.hero .btn-primary:hover, .page-header .btn-primary:hover { background-color: var(--primary); }
.hero .btn-secondary, .page-header .btn-secondary { border-color: #ffffff; color: #ffffff; }
.hero .btn-secondary:hover, .page-header .btn-secondary:hover { background-color: #ffffff; color: var(--primary); }

.btn-large { padding: 16px 32px; font-size: 0.95rem; }
.btn-full { width: 100%; }

/* --- Navbar --- */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: transparent;
    z-index: 1000;
    padding: 30px 0;
    transition: var(--transition);
    border-bottom: 1px solid transparent;
}
.header.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 15px 0;
    box-shadow: 0 4px 20px rgba(0,0,0,0.03);
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.nav-container { display: flex; justify-content: space-between; align-items: center; }
.logo { display: flex; align-items: center; }
.header-logo { max-height: 70px; width: auto; }

/* Menu agrupado a la derecha */
.nav-right {
    display: flex;
    align-items: center;
    gap: 40px;
    margin-left: auto;
}

.nav-menu { display: flex; gap: 30px; align-items: center; }
.nav-menu a { font-weight: 600; color: #ffffff; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.05em; }
.nav-menu a:hover, .nav-menu a.active { opacity: 0.8; }
.header.scrolled .nav-menu a:hover, .header.scrolled .nav-menu a.active { color: var(--primary); opacity: 1; }
.nav-cta { padding: 12px 24px; font-size: 0.8rem; }

@media (min-width: 769px) {
    .header:not(.scrolled) .nav-cta {
        background-color: #ffffff;
        color: var(--primary);
    }
    .header:not(.scrolled) .nav-cta:hover {
        background-color: #f0f0f0;
    }
    .header.scrolled .nav-cta {
        background-color: var(--primary);
        color: #ffffff;
    }
    .header.scrolled .nav-cta:hover {
        background-color: var(--primary-hover);
    }
}

/* --- Dropdown --- */
.dropdown { position: relative; display: inline-block; padding: 10px 0; }
.dropdown-content {
    display: none;
    position: absolute;
    background-color: #ffffff; /* FONDO BLANCO ARREGLADO */
    min-width: 240px;
    border: 1px solid var(--secondary);
    border-radius: var(--radius-sm);
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    z-index: 10;
    top: 100%;
    left: -20px;
    overflow: hidden;
}
.dropdown-content a {
    color: var(--primary);
    padding: 16px 24px;
    text-decoration: none;
    display: block;
    font-size: 0.9rem;
    font-weight: 500;
    border-bottom: 1px solid var(--secondary);
}
.dropdown-content a:last-child { border-bottom: none; }
.dropdown-content a:hover { background-color: #f5f5f7; color: var(--primary); }
.dropdown:hover .dropdown-content { display: block; }

/* --- Page Header --- */
.page-header {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 120px 0;
    background-color: #f5f5f7;
    text-align: center;
}
.page-header h1 { font-size: 2.2rem; margin-bottom: 24px; color: #ffffff !important; }
.page-header p { font-size: 0.95rem; color: #ffffff !important; max-width: 700px; margin: 0 auto; }
.page-header-actions { margin-top: 50px; display: flex; gap: 20px; justify-content: center; }

/* --- Hero Section --- */
.hero { min-height: 100vh; display: flex; align-items: center; padding: 120px 0; background-color: #f5f5f7; }
.hero-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 120px; align-items: center; }
.hero-text h1 { font-size: 2.2rem; margin-bottom: 30px; letter-spacing: -0.02em; line-height: 1.05; color: #ffffff !important; }
.hero-text p { font-size: 0.95rem; color: #ffffff !important; margin-bottom: 50px; max-width: 550px; }
.hero-actions { display: flex; gap: 20px; margin-bottom: 40px; }
.hero-image img { border-radius: var(--radius-lg); width: 100%; height: 100%; object-fit: cover; }

/* --- Sections --- */
.section { padding: 160px 0; }
.section-header { max-width: 800px; margin-bottom: 80px; }
.section-header h2 { font-size: 2.2rem; margin-bottom: 24px; }
.section-header p { font-size: 0.95rem; color: var(--text-muted); }

/* --- Cards Grid Layout --- */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 60px;
    align-items: stretch; /* Fija alturas iguales */
}

.card {
    background: var(--bg-card);
    padding: 60px 50px;
    border-radius: var(--radius-lg);
    transition: var(--transition);
    border: 1px solid transparent;
    display: flex;
    flex-direction: column;
    height: 100%;
}
.card > span {
    margin-top: auto; /* Empuja el "Saber más" al fondo */
}
.hover-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.04);
    background: var(--bg-white);
    border: 1px solid var(--secondary);
}
.card h3 { font-size: 0.95rem; margin-bottom: 20px; }
.card p { color: var(--text-muted); font-size: 0.95rem; }

/* --- Plan Block Layout --- */
.plan-block {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: var(--primary);
    color: #ffffff;
    padding: 40px;
    border-radius: 0;
    margin-bottom: 40px;
    border: 1px solid var(--secondary);
}
.plan-block > div:last-child {
    margin-top: auto; /* Empuja el botón CTA al fondo */
}

.plan-header { text-align: center; margin-bottom: 30px; padding-bottom: 20px; border-bottom: 1px solid var(--secondary); }
.plan-header h3 { font-size: 1.1rem; margin-bottom: 15px; }
.plan-price { font-size: 0.95rem; font-family: var(--font-body); font-weight: 600; color: var(--text-muted); margin-bottom: 10px; }
.plan-desc { font-size: 1.05rem; color: var(--text-dark); margin-top: 20px; line-height: 1.6; }

.plan-details { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 30px; flex-grow: 1; }
.plan-item { margin-bottom: 15px; }
.plan-item:last-child { margin-bottom: 0; }
.plan-item h4 { font-size: 0.85rem;  letter-spacing: 1px; color: var(--text-dark); margin-bottom: 8px;}
.plan-item p { font-size: 0.95rem; color: var(--text-dark); line-height: 1.5; }

/* --- 50/50 Layouts --- */
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 120px; align-items: center; }
.profile-img { width: 100%; height: auto; border-radius: var(--radius-lg); object-fit: cover; }
.about-intro { font-size: 0.95rem; margin-bottom: 20px; }

/* --- Footer Minimalista --- */
.footer { padding: 100px 0 40px; background: var(--primary); color: #ffffff; border-top: none; }
.footer-content { display: grid; grid-template-columns: 1fr 1fr; gap: 100px; margin-bottom: 80px; }
.footer-brand p { color: #aaaaaa; font-size: 0.95rem; margin-top: 20px; max-width: 350px; }
.footer-logo { max-height: 40px; filter: invert(1); }

.footer-col h4 { font-size: 1rem; margin-bottom: 24px; text-transform: uppercase; letter-spacing: 1px; color: #ffffff; }
.footer-col a { display: block; color: #aaaaaa; margin-bottom: 16px; font-size: 1rem; }
.footer-col a:hover { color: #ffffff; }

.footer-bottom {
    padding-top: 40px;
    border-top: 1px solid #333333;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: #aaaaaa;
}
.footer-legal a { color: #aaaaaa; margin-left: 30px; }
.footer-legal a:hover { color: #ffffff; }

/* Minimalist Form Footer */
.minimal-form { max-width: 100%; }
.minimal-form .form-group { margin-bottom: 20px; }
.minimal-form input[type="text"], .minimal-form input[type="email"], .minimal-form textarea {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid #444444;
    padding: 10px 0;
    font-size: 0.85rem;
    color: #ffffff;
    font-family: var(--font-body);
    transition: var(--transition);
    border-radius: 0;
}
.minimal-form input[type="text"]:focus, .minimal-form input[type="email"]:focus, .minimal-form textarea:focus {
    outline: none;
    border-bottom-color: #ffffff;
    box-shadow: none;
}
.minimal-form .btn {
    padding: 12px 0;
    width: 100%;
    background: transparent;
    color: #ffffff;
    border: 1px solid #ffffff;
    margin-top: 10px;
}
.minimal-form .btn:hover {
    background: #ffffff;
    color: #1a1a1a;
}

/* --- SVG Icons --- */
.icon-svg { max-width: 32px; max-height: 32px; margin-bottom: 20px; display: block; stroke-width: 1.5; color: var(--text-dark); }
.card img, .card svg { max-width: 32px; max-height: 32px; margin-bottom: 20px; }

/* --- Mobile Responsiveness --- */
.mobile-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 20px;
    cursor: pointer;
    z-index: 1001;
}
.mobile-toggle span {
    display: block;
    height: 2px;
    width: 100%;
    background-color: #ffffff; /* Default is white for dark banners */
    transition: var(--transition);
}

@media (max-width: 768px) {

    /* Mobile Typography Adjustments */
    h1 { font-size: 2.2rem; }
    h2 { font-size: 1.8rem; }
    h3 { font-size: 1.3rem; }

    /* 100vh Mobile Banners */
    .page-header {
        min-height: 100vh;
        display: flex;
        flex-direction: column;
        justify-content: center;
        padding: 40px 20px;
    }

    /* Smaller buttons on mobile */
    .btn {
        padding: 12px 24px;
        font-size: 0.85rem;
    }

    /* Disable hover for dropdown on mobile */
    .dropdown:hover .dropdown-content { display: none; }
    .mobile-toggle { display: flex; }

    .nav-right {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 40px;
        transform: translateY(-100%);
        transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
        z-index: 999;
    }

    .nav-right.mobile-active { transform: translateY(0); }
    .nav-right.mobile-active + .mobile-toggle span { background-color: var(--text-dark) !important; }

    .nav-menu { flex-direction: column; text-align: center; gap: 30px; }
    .nav-menu a { font-size: 1.2rem; color: var(--text-dark) !important; }
    .nav-cta {
        background: transparent !important;
        border: none !important;
        color: var(--text-dark) !important;
        padding: 0 !important;
        font-size: 1.2rem !important;
        box-shadow: none !important;
        text-transform: uppercase;
        font-weight: 600;
    }

    .dropdown-content { position: static; box-shadow: none; border: none; background: transparent; padding-top: 10px; }
    .dropdown.open .dropdown-content { display: flex; flex-direction: column; position: static; box-shadow: none; border: none; background: transparent; padding-top: 10px; padding-bottom: 15px; }

    .hero, .page-header { padding: 120px 20px 60px; min-height: 100vh; display: flex; flex-direction: column; justify-content: center; }
    .hero-grid, .about-grid { grid-template-columns: 1fr; gap: 60px; }
    .cards-grid, .cards-grid-2 { grid-template-columns: 1fr !important; gap: 30px !important; }
    .plan-details { grid-template-columns: 1fr !important; gap: 15px; }
    .plan-block, .card { padding: 30px; transform: none !important; margin: 0 !important; }
    .footer-content { grid-template-columns: 1fr !important; gap: 40px !important; }

    h1 { font-size: 2.2rem !important; }
    h2 { font-size: 1.8rem !important; }

    .section { padding: 80px 0; }
}
.header.scrolled .nav-menu a {
    color: var(--text-dark);
}
.header.scrolled .mobile-toggle span {
    background-color: var(--text-dark);
}

/* Mobile dropdown fix */
.dropdown.open .dropdown-content { display: flex; flex-direction: column; position: static; box-shadow: none; border: none; background: transparent; padding-top: 10px; padding-bottom: 15px; }

/* --- MOBILE OPTIMIZATIONS (ADDED) --- */
html, body {
    overflow-x: hidden;
}

@media (max-width: 768px) {
    h1 {
        font-size: 2rem !important;
    }
    h2 {
        font-size: 1.8rem !important;
    }
    .hero-text h1 {
        font-size: 2.2rem !important;
    }
    .section, .hero, .page-header {
        padding-left: 15px !important;
        padding-right: 15px !important;
    }
    /* Reducir gaps en grids de servicios y metodologia en movil */
    div[style*="gap: 30px"] {
        gap: 15px !important;
    }
    .cta-gratis h2 {
        font-size: 2rem !important;
    }
    .cta-gratis p {
        font-size: 1rem !important;
    }
    /* Ajustes generales a grids en contenedor móvil */
    .cards-grid {
        gap: 15px !important;
    }
}


/* --- NEW PLAN STYLES --- */
.plan-block.premium {
    border: 2px solid var(--primary);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    position: relative;
    
    z-index: 10;
}
.plan-block.premium:hover {
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.12);
}
.plan-block .ribbon {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary);
    color: #ffffff;
    font-size: 0.8rem;
    font-weight: 700;
    padding: 6px 16px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    z-index: 2;
    white-space: nowrap;
}

/* Pair grids for side-by-side plan comparison */
.plan-pair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 60px;
    align-items: stretch;
}
@media (max-width: 900px) {
    .plan-pair { grid-template-columns: 1fr; gap: 40px; }
    .plan-block.premium { transform: scale(1); }
    
}

/* Add-ons & Maintenance Lists */
.addons-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 40px;
}
.addon-card {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 24px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
}
.addon-header h4 {
    font-size: 1.1rem;
    color: var(--text-dark);
    margin-bottom: 8px;
}
.addon-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 15px;
}
.addon-desc {
    font-size: 0.9rem;
    color: var(--text-muted);
}
.addon-desc ul {
    margin-top: 10px;
    list-style: none;
    padding: 0;
}
.addon-desc ul li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 8px;
    line-height: 1.4;
}
.addon-desc ul li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--primary);
    font-weight: bold;
}


/* UNIFIED PLAN PAIR CSS */
.plan-pair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px !important; 
    margin-bottom: 50px;
    align-items: stretch;
    background: transparent;
    border: none;
    box-shadow: none;
}
/* Ficha Cuadrada 1: Pago Único */
.plan-pair > .plan-block:first-child {
    background: var(--primary);
    border: 2px solid var(--primary);
    border-radius: 0px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    padding: 40px;
}
/* Ficha Cuadrada 2: Suscripción (Premium) */
.plan-pair > .plan-block {
    background: var(--primary);
    color: #ffffff;
    border: 2px solid var(--primary);
    border-radius: 0px;
    box-shadow: 0 15px 40px rgba(7, 25, 57, 0.2);
    padding: 40px;
    
}
/* Ajustes de color para texto interno Premium */
.plan-pair > .plan-block h3,
.plan-pair > .plan-block h4,
.plan-pair > .plan-block .plan-price {
    color: #ffffff !important;
}
.plan-pair > .plan-block p {
    color: rgba(255, 255, 255, 0.8) !important;
}
.plan-pair > .plan-block .plan-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}
.plan-pair > .plan-block .plan-price span {
    color: rgba(255, 255, 255, 0.8) !important;
}
.plan-pair > .plan-block .btn {
    background: var(--primary-hover);
    color: #ffffff;
    border: 1px solid var(--primary-hover);
}
.plan-pair > .plan-block .btn:hover {
    background: #ffffff;
    color: var(--primary);
    border-color: #ffffff;
}
@media (max-width: 900px) {
    .plan-pair {
        grid-template-columns: 1fr;
        gap: 30px !important;
    }
    .plan-pair > .plan-block {
        transform: scale(1);
    }
}

/* Global overrides to make all grid plans blue with white text */
.cards-grid > .plan-block {
    background: var(--primary) !important;
    color: #ffffff !important;
}
.cards-grid > .plan-block h3, 
.cards-grid > .plan-block h4,
.cards-grid > .plan-block .plan-price {
    color: #ffffff !important;
}
.cards-grid > .plan-block p,
.cards-grid > .plan-block .plan-price span {
    color: rgba(255, 255, 255, 0.8) !important;
}
.cards-grid > .plan-block .plan-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}
.cards-grid > .plan-block .btn {
    background: var(--primary-hover) !important;
    color: #ffffff !important;
    border: 1px solid var(--primary-hover) !important;
}
.cards-grid > .plan-block .btn:hover {
    background: #ffffff !important;
    color: var(--primary) !important;
    border-color: #ffffff !important;
}

@media (max-width: 768px) {
    .section h2, .section-header h2 {
        font-size: 1.35rem !important;
        overflow-wrap: break-word;
        word-wrap: break-word;
        hyphens: auto;
        line-height: 1.3;
        padding: 0 10px;
    }
}

/* Ocultar parcialmente el badge de reCAPTCHA y que se despliegue al interactuar */
.grecaptcha-badge {
    visibility: visible !important;
    right: -240px !important; /* Oculto casi por completo (solo asoma el borde) */
    bottom: 90px !important; /* Por encima del botón de WhatsApp */
    opacity: 0.15 !important; /* Aún más transparente */
    transition: all 0.4s ease !important;
    z-index: 99998 !important;
}

.grecaptcha-badge:hover, .grecaptcha-badge:active {
    right: -10px !important;
    opacity: 1 !important;
}

/* Evitar zoom automático en iOS al hacer clic en los inputs */
@media screen and (max-width: 768px) {
    .minimal-form input[type="text"], 
    .minimal-form input[type="email"], 
    .minimal-form select,
    .minimal-form textarea {
        font-size: 16px !important;
    }
}
