@import url('https://fonts.googleapis.com/css2?family=Lato:wght@400;700&display=swap');
:root {
     --color-primario: #28a745;
     --color-secundario: #218838;
     --color-texto-oscuro: #2c3e50;
     --color-texto-claro: #a1a1a1;
     --color-fondo-caja: white;
     --color-fondo-pagina: rgba(181,181,181,0.66);
}

body {
     background-color: var(--color-fondo-pagina);
     font-family: 'Lato', sans-serif;
     line-height: 1.6;
     padding-top: 80px; 
}

header {
     height: 80px; 
     background-color: #ffffff;
     border-radius:  8px;
     box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
     padding: 0 40px;
     display: flex;
     justify-content: space-between;
     align-items: center;
     position: fixed;
     top: 0;
     width: 90%;
     max-width: 1200px;
     left: 50%;
     transform: translateX(-50%);
     box-sizing: border-box;
     z-index: 1000;
}

/* Ajuste del main para que parte quede debajo del header */
main {
     width: 90%;
     max-width: 1200px;
     margin: 20px auto; 
     padding: 20px;
     background-color: var(--color-fondo-caja);
     border-radius: 8px;
     box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Resto de estilos (sin cambios funcionales) */
footer {
     text-align: center;
     padding: 30px;
     margin-top: 40px;
     background-color: var(--color-fondo-caja);
     color: var(--color-texto-claro);
     border-top: 1px solid #eee;
}


nav {
     display: flex;
     gap: 20px;
}

nav a {
     text-decoration: none;
     color: var(--color-texto-claro);
     font-weight: 600;
}
nav a:hover {
     color: var(--color-secundario);
}
nav a.active {
     color: var(--color-texto-oscuro);
}
header h1 {
     font-size: 1.5em;
     color: var(--color-texto-oscuro);
     margin: 0;
}

.logo-container {
     display: flex;
     align-items: center;
     text-decoration: none;
}

.logo {
     height: 60px;
     width: auto;
     margin-right: 15px;
}

.imagen-header {
     width: 100%;
     height: auto;
     border-radius: 8px;
     margin-bottom: 20px;
}

.card {
     background-color: var(--color-fondo-caja);
     border-radius: 8px;
     padding: 25px;
     margin-bottom: 30px;
     box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
     transition: box-shadow 0.3s ease;
}
.card:hover {
     box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}
.card h2 {
     color: var(--color-texto-oscuro);
     margin-bottom: 10px;
}

.card-title-link {
     text-decoration: none;
     color: var(--color-texto-oscuro);
}

.read-more-link {
     text-decoration: none;
     color: var(--color-primario);
     font-weight: 700;
}
.read-more-link:hover {
     color: var(--color-secundario);
}
.footer-nav {
     margin-top: 10px;
}

.footer-nav a {
    color: var(--color-texto-claro);
    text-decoration: none;
    padding: 0 5px;
}
.footer-nav span {
    color: var(--color-texto-claro);
} /* <--- ¡ESTA LLAVE FALTABA! */

.hamburger-btn {
     width: 40px;
     height: 30px;
     background: transparent;
     border: none;
     cursor: pointer;
     display: flex;
     flex-direction: column;
     justify-content: space-around;
     padding: 0;
     z-index: 1010;

}
.hamburger-btn .bar {
     display: block;
     width: 100%;
     height: 4px;
     background-color: var(--color-texto-oscuro);
     border-radius: 2px;
     transition: all 0.3s ease-in-out;
}
.hamburger-btn.open .bar:nth-child(1) {
     transform: translateY(13px) rotate(45deg);
}
.hamburger-btn.open .bar:nth-child(2) {
     opacity: 0;
}
.hamburger-btn.open .bar:nth-child(3) {
     transform: translateY(-13px) rotate(-45deg);

}
.overlay {
     position: fixed;
     top: 0;
     left: 0;
     width: 100vw;
     height: 100vh;
     background-color: rgba(0, 0, 0, 0.5);
     z-index: 1001;
     opacity: 0;
     visibility: hidden;
     transition: opacity 0.3s ease, visibility 0.3s ease;
}

.overlay.open{
     opacity: 1;
     visibility: visible;
}
.sidebar {
     position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: 280px; 
    background-color: var(--color-fondo-caja); 
    z-index: 1002; 
    box-shadow: -4px 0 10px rgba(0, 0, 0, 0.1);
    transform: translateX(100%);
    transition: transform 0.3s ease-in-out;
    padding: 25px;
    box-sizing: border-box;

}
.sidebar.open {

     transform: translateX(0);
 }
 
 .sidebar h2 {
     color: var(--color-texto-oscuro);
     margin-top: 20px;
     margin-bottom: 20px;
 }
 
 .sidebar-nav {
     display: flex;
     flex-direction: column;
 }
 
 .sidebar-nav a {
     text-decoration: none;
     color: var(--color-texto-claro);
     font-weight: 600;
     font-size: 1.1em;
     padding: 15px 10px;
     border-radius: 6px;
     transition: background-color 0.2s ease, color 0.2s ease;
 }
 
 .sidebar-nav a:hover {
     background-color: #f4f4f4; 
     color: var(--color-secundario); 
 }
 
@media (max-width: 700px) {
    header {
         flex-direction: column;
         gap: 15px;
         position: static;
    }
    
    
    .nav {
         flex-direction: column;
         align-items: center;
    } 
    h1, h2, h3 {
         font-weight: 700;
         color: var(--color-texto-oscuro);
    }
    main {
         margin-top: 20px; 
    }
    body {
     padding-top: 0;
 }
}