:root {
    --bg-main: #ffffff;
    --bg-secondary: #fdfdfd;
    --bg-card: rgba(255, 255, 255, 0.85);
    --text-dark: #0f172a;    
    --text-muted: #64748b;   
    --border-smooth: #f1f5f9;
    --brand-verde: #8cc63f;   
    --brand-azul: #1c4463;    
    --brand-azul-light: #2a5c84;
    --whatsapp-color: #22c55e;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, Arial, sans-serif;
    color: var(--text-dark);
    background-color: #fafbfc;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

/* --- ESCENARIO DE INICIO --- */
.hero-wrapper {
    display: flex; flex-direction: column; justify-content: space-between; min-height: 100vh;
    background: radial-gradient(circle at top right, rgba(140, 198, 63, 0.04), transparent 45%), var(--bg-main);
}

.main-header {
    text-align: center; padding: 2rem; flex-grow: 1;
    display: flex; flex-direction: column; justify-content: center; align-items: center;
}

.logo-container-hero { display: flex; align-items: center; justify-content: center; gap: 1.5rem; margin-bottom: 1.5rem; width: 100%; max-width: 600px; }
.logo-composicion { display: flex; align-items: center; height: 95px; }
.hero-bolitas-img { height: 100%; width: auto; margin-right: -5px; }
.hero-muñeco-img { height: 100%; width: auto; }
.hero-titulo-texto { font-size: 3rem; font-weight: 800; color: var(--brand-azul); letter-spacing: -1px; }
.header-subtitle { font-size: 1.2rem; color: var(--text-muted); max-width: 680px; margin: 0 auto; }

/* --- BARRA DE NAVEGACIÓN --- */
nav.nav-moderno {
    position: sticky; top: 0; background: linear-gradient(135deg, #1c4463 0%, #2a5c84 60%, #1c4463 100%);
    backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    display: flex; justify-content: space-between; align-items: center; padding: 0 2rem; z-index: 1000; width: 100%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 4px 20px rgba(0,0,0,0.03);
}

.nav-logo-fijo { display: flex; align-items: center; gap: 0.8rem; position: relative; padding: 0.6rem 0; }
.nav-assets-wrapper { display: flex; align-items: center; height: 42px; }
.nav-bolitas-base { height: 100%; width: auto; margin-right: -2px; }
.nav-character-base { height: 100%; width: auto; }
.nav-logo-text { color: #ffffff; font-weight: 700; font-size: 1.25rem; letter-spacing: -0.3px; white-space: nowrap; }

.nav-links { display: flex; }

nav a { 
    color: rgba(255, 255, 255, 0.85); padding: 1.5rem 1.2rem; text-decoration: none; 
    font-weight: 600; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.5px;
    position: relative; transition: color 0.3s ease;
}

nav a::after {
    content: ''; position: absolute; bottom: 0; left: 50%; width: 0; height: 3px;
    background-color: var(--brand-verde); transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    transform: translateX(-50%); border-radius: 2px 2px 0 0;
}

nav a:hover { color: #ffffff; }
nav a:hover::after { width: 80%; }

/* Clases de apoyo dinámico para el script */
nav .nav-links a.activo-verde::after { width: 80% !important; background-color: var(--brand-verde); }
nav .nav-links a.activo-verde { color: #ffffff; }

/* --- CONTENIDOS --- */
.container { max-width: 1140px; margin: 0 auto; padding: 1.5rem; }
.section { padding: 6rem 0; }
.section h2 { font-size: 2.1rem; font-weight: 700; margin-bottom: 2.5rem; color: var(--brand-azul); position: relative; }
.section h2::after { content: ''; display: block; width: 40px; height: 4px; background: linear-gradient(90deg, var(--brand-verde), var(--brand-azul)); border-radius: 2px; margin-top: 0.6rem; }
.subtitle { color: var(--text-muted); font-size: 1.1rem; margin-bottom: 2rem; }

.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(310px, 1fr)); gap: 2.5rem; }
.card { background: var(--bg-main); border-radius: 16px; overflow: hidden; border: 1px solid var(--border-smooth); display: flex; flex-direction: column; transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1); box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.01); }
.card:hover { transform: translateY(-6px); box-shadow: 0 20px 25px -5px rgba(28, 68, 99, 0.06); border-color: rgba(28, 68, 99, 0.1); }
.card-img { height: 200px; background-size: cover; background-position: center; }
.card-content { padding: 2rem; flex-grow: 1; }
.card h3 { font-size: 1.4rem; margin-bottom: 0.75rem; color: var(--brand-azul); font-weight: 600; }
.card p { color: var(--text-muted); font-size: 0.95rem; margin-bottom: 1.5rem; }
.card ul { list-style: none; }
.card ul li { font-size: 0.95rem; margin-bottom: 0.6rem; padding-left: 1.5rem; position: relative; color: #475569; }
.card ul li::before { content: "→"; color: var(--brand-verde); position: absolute; left: 0; font-weight: 700; }

.splitting-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: 4rem; align-items: center; }
.split-text p { font-size: 1.15rem; color: var(--text-muted); line-height: 1.9; }
.split-img { height: 380px; background-size: cover; background-position: center; border-radius: 20px; box-shadow: 0 20px 40px rgba(0,0,0,0.04); border: 1px solid var(--border-smooth); }

.online-banner { background-image: linear-gradient(135deg, rgba(28, 68, 99, 0.96), rgba(42, 92, 132, 0.94)), url('celular_farmacia.png'); background-size: cover; background-position: center; color: #ffffff; padding: 6rem 2rem; border-radius: 24px; box-shadow: 0 20px 40px rgba(28, 68, 99, 0.15); }
.online-box h2 { color: #ffffff; margin-bottom: 1rem; }
.online-box h2::after { background: var(--brand-verde); margin: 0.6rem auto 0 auto; }
.online-box p { max-width: 650px; margin: 1.5rem auto 2.5rem auto; font-size: 1.15rem; opacity: 0.9; }

.guardia-notice { background: #fefce8; border: 1px solid #fef08a; border-left: 4px solid #eab308; padding: 1.5rem; border-radius: 12px; margin-bottom: 3rem; color: #713f12; font-size: 1rem; }
.grid-grupos { display: grid; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); gap: 2rem; }
.grupo-card { background: var(--bg-main); border: 1px solid var(--border-smooth); padding: 2.5rem; border-radius: 16px; box-shadow: 0 4px 6px -1px rgba(0,0,0,0.01); }
.grupo-card h3 { color: var(--brand-azul); margin: 0.75rem 0 0.5rem 0; font-size: 1.3rem; }
.grupo-card p { color: var(--text-muted); font-size: 0.95rem; }
.badge { display: inline-block; padding: 0.35rem 0.9rem; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; border-radius: 30px; color: #ffffff; letter-spacing: 0.5px; }
.badge-azul { background-color: rgba(28, 68, 99, 0.1); color: var(--brand-azul); }
.badge-verde { background-color: rgba(140, 198, 99, 0.15); color: #5f9222; }

.grid-contacto-qr { display: grid; grid-template-columns: 1.2fr 1fr; gap: 4rem; align-items: start; }
.qr-card-box { background: var(--bg-main); border: 1px solid var(--border-smooth); padding: 3rem 2rem; border-radius: 20px; text-align: center; box-shadow: 0 10px 30px rgba(0,0,0,0.02); }
.qr-card-box h3 { color: var(--brand-azul); margin-bottom: 0.75rem; font-size: 1.3rem; }
.qr-card-box p { font-size: 0.9rem; color: var(--text-muted); margin-bottom: 1.5rem; }
.qr-wrapper { max-width: 180px; margin: 0 auto; background: #ffffff; padding: 1rem; border: 1px solid var(--border-smooth); border-radius: 12px; }
.qr-image { width: 100%; height: auto; display: block; }

.btn { display: inline-block; padding: 0.9rem 2.2rem; border-radius: 8px; text-decoration: none; font-weight: 600; font-size: 0.88rem; text-transform: uppercase; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); border: none; cursor: pointer; }
.btn-whatsapp { background: var(--whatsapp-color); color: #ffffff; box-shadow: 0 8px 20px rgba(34, 197, 94, 0.25); }
.btn-whatsapp:hover { background: #16a34a; transform: translateY(-2px); }
.btn-online { background: #ffffff; color: var(--brand-azul); box-shadow: 0 4px 12px rgba(0,0,0,0.05); }
.btn-online:hover { background: var(--brand-verde); color: var(--text-dark); transform: translateY(-2px); }
.btn-email { background: linear-gradient(135deg, var(--brand-azul), var(--brand-azul-light)); color: #ffffff; }
.btn-email:hover { transform: translateY(-2px); }
.text-center { text-align: center; }

.cta-box { padding: 3.5rem 2rem; border-radius: 20px; border: 1px solid var(--border-smooth); text-align: center; box-shadow: 0 10px 30px rgba(0,0,0,0.02); }
.cta-box h3 { margin-bottom: 0.75rem; font-size: 1.5rem; color: var(--brand-azul); }
.cta-box p { color: var(--text-muted); margin-bottom: 2rem; font-size: 1rem; }
.contact-info p { margin-bottom: 1rem; color: var(--text-muted); }
.contact-info strong { color: var(--text-dark); }

footer { background: #0f172a; text-align: center; padding: 4rem 1.5rem; color: #94a3b8; font-size: 0.88rem; margin-top: 6rem; }

/* --- REGLAS EXCLUSIVAS DE LIMPIEZA PARA CELULARES (RESPONSIVE) --- */
@media (max-width: 768px) {
    /* Centrado vertical simétrico del logo inicial arriba de todo */
    .logo-container-hero { 
        flex-direction: column; 
        gap: 0.75rem; 
        text-align: center;
    }
    .logo-composicion { 
        height: 70px; /* Achicamos un poco la escala para que no desborde */
        justify-content: center;
    }
    .hero-titulo-texto { 
        font-size: 2.2rem; 
        text-align: center;
    }
    .header-subtitle {
        font-size: 1.05rem;
        padding: 0 1rem;
    }

    /* Orden de la barra de navegación en teléfonos */
    nav.nav-moderno { 
        flex-direction: column; 
        padding: 1rem; 
        align-items: center;
    }
    .nav-logo-fijo {
        justify-content: center;
        margin-bottom: 0.75rem;
        width: 100%;
    }
    .nav-assets-wrapper {
        height: 34px; /* Proporción compacta para celulares */
    }
    .nav-logo-text {
        font-size: 1.15rem;
    }
    .nav-links { 
        flex-direction: column; 
        width: 100%; 
        text-align: center; 
    }
    nav a { 
        padding: 0.8rem; 
        display: block;
width: 100%;font-size: 0.8rem;border-bottom: 1px solid rgba(255,255,255,0.05);}nav a::after {bottom: 2px;}/* Secciones y tarjetas estiradas al 100% de forma prolija /.section {padding: 4rem 0;}.section h2 {font-size: 1.6rem;text-align: center;}.section h2::after {margin: 0.5rem auto 0 auto; / Centramos la línea decorativa de los títulos /}.subtitle {text-align: center;font-size: 0.95rem;}.splitting-grid, .grid-contacto-qr {grid-template-columns: 1fr;gap: 2.5rem;}.split-text {text-align: center;}.split-img {height: 220px;order: -1; / Muestra la foto de la góndola arriba del texto en celulares /}.btn {width: 100%; / Botones de pantalla completa para tocar fácil con el pulgar */text-align: center;}.cta-box {padding: 2.5rem 1rem;}}