/* ======== CONFIGURACIÓN GLOBAL ======== */
:root {
    --color-primario: #007bff;
    --color-secundario: #f9a826; /* Amarillo del CTA */
    --color-fondo-light: #ffffff;
    --color-texto-light: #212529;
    --color-texto-gris: #555;
    --fuente-principal: 'Lato', 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

body {
    margin: 0;
    padding: 0;
    font-family: var(--fuente-principal);
    background-color: #f8f9fa;
    color: var(--color-texto-light);
    line-height: 1.7;
    font-size: 18px;
    padding-top: 80px; /* IMPORTANTE: Espacio para el menú fijo */
}

/* ======== BARRA DE NAVEGACIÓN (MENU) ======== */
.main-nav {
    background-color: rgba(15, 18, 26, 0.95);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 15px 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.nav-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo img {
    height: 40px; 
    width: auto;
    display: block;
}

.nav-links {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 30px;
}

.nav-links a {
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.95rem;
    text-transform: uppercase;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: #4CAF50;
}

.nav-btn-comprar {
    background-color: #1D6F42;
    padding: 8px 15px;
    border-radius: 4px;
}
.nav-btn-comprar:hover {
    background-color: #145230;
    color: #fff !important;
}

.hamburger {
    display: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
}

.bar {
    width: 25px;
    height: 3px;
    background-color: #fff;
    border-radius: 2px;
}

/* ======== CONTENEDOR DEL ARTÍCULO ======== */
.article-content {
    max-width: 720px;
    margin: 40px auto;
    padding: 40px;
    background-color: var(--color-fondo-light);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

h1, h2, h3, h4 {
    font-weight: 900;
    line-height: 1.3;
    color: #111;
}

h1 { font-size: 2.5rem; margin-bottom: 10px; }
h2 { font-size: 1.8rem; color: var(--color-primario); margin-top: 40px; margin-bottom: 20px; }
h3 { font-size: 1.5rem; margin-top: 30px; }

.intro { font-size: 1.2rem; color: var(--color-texto-gris); margin-bottom: 30px; }

p { margin-bottom: 20px; }
ul, ol { margin-bottom: 20px; padding-left: 30px; }
li { margin-bottom: 10px; }
hr { border: none; border-top: 1px solid #dee2e6; margin: 40px 0; }

/* ======== CÓDIGO Y TABLAS ======== */
code {
    background-color: #e9ecef;
    padding: 3px 6px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.9em;
    color: #d63384;
}

pre {
    background-color: #212529;
    color: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    overflow-x: auto;
    margin-bottom: 20px;
}

.example-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
    font-size: 0.9rem;
    background-color: #fff;
    border: 1px solid #dee2e6;
}
.example-table th, .example-table td { border: 1px solid #dee2e6; padding: 12px; text-align: left; }
.example-table thead { background-color: #f1f3f5; font-weight: bold; }

/* ======== IMÁGENES ======== */
figure { margin: 30px 0; }
figure img { max-width: 100%; height: auto; border-radius: 8px; box-shadow: 0 4px 12px rgba(0,0,0,0.1); }
figure figcaption { font-size: 0.9rem; color: var(--color-texto-gris); text-align: center; margin-top: 10px; font-style: italic; }

/* ======== CTA ======== */
.cta-box {
    background-color: #0f121a;
    color: #e9ecef;
    padding: 40px;
    border-radius: 8px;
    text-align: center;
    margin-top: 50px;
}
.cta-box h2 { color: #ffffff; margin-top: 0; }
.cta-button {
    display: inline-block;
    background-color: var(--color-secundario);
    color: #111;
    font-size: 1.2rem;
    font-weight: 900;
    text-decoration: none;
    padding: 18px 35px;
    border-radius: 8px;
    text-transform: uppercase;
    box-shadow: 0 5px 15px rgba(249, 168, 38, 0.3);
    transition: transform 0.2s;
    margin-top: 20px;
}
.cta-button:hover { transform: translateY(-3px); }
.cta-subtext { display: block; font-size: 0.9rem; margin-top: 15px; opacity: 0.8; }

/* ======== FOOTER ======== */
footer {
    text-align: center;
    padding: 40px 20px;
    font-size: 0.9rem;
    color: #888;
    background-color: #eee;
    margin-top: 40px;
}
.disclaimer { font-size: 0.8rem; font-style: italic; }

/* ======== BANNER COOKIES ======== */
.cookie-banner-container {
    position: fixed;
    bottom: -100%;
    left: 0;
    width: 100%;
    background-color: #222;
    color: #fff;
    padding: 20px;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.2);
    z-index: 9999;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 20px;
    transition: bottom 0.5s ease-in-out;
}
.cookie-banner-container.show { bottom: 0; }
.cookie-content a { color: #4CAF50; }
.cookie-btn {
    background-color: #1D6F42;
    color: white;
    border: none;
    padding: 10px 25px;
    border-radius: 5px;
    font-weight: bold;
    cursor: pointer;
}

/* ======== RESPONSIVE ======== */
@media (max-width: 768px) {
    .hamburger { display: flex; }
    .nav-links {
        display: none;
        flex-direction: column;
        width: 100%;
        position: absolute;
        top: 70px;
        left: 0;
        background-color: #0f121a;
        padding: 20px 0;
        text-align: center;
        border-top: 1px solid #333;
    }
    .nav-links.active { display: flex; }
    .nav-links li { margin: 15px 0; }
    
    .article-content { padding: 20px; margin: 20px auto; }
}