:root {
    --primary: #147a96; 
    --text-dark: #333;
    --text-light: #666;
    --bg-light: #f4f7f9;
    --footer-bg: #0a2d37;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-image: url("../img/fondo-pagina.png");
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    min-height: 100vh;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 5%;
    background: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.logo {
    width: 200px; 
    position: relative;
}

.logo img {
    width: 350px; 
    height: auto;
    position: absolute;
    transform: translate(-100px, -175px); 
    max-width: none;
    pointer-events: none;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 30px;
}

nav ul li a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
}

nav ul li a.active { color: var(--primary); }

.btn-nav {
    background: var(--primary);
    color: white;
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 14px;
}

.hero {
    height: 450px;
    background: linear-gradient(rgba(0,0,0,0.3), rgba(0,0,0,0.3)), url('assets/img/fondo-pagina.png');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    padding: 0 5%;
}

.hero-content {
    max-width: 500px;
    color: white;
}

.hero-content h1 {
    font-size: 36px;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero-content p {
    margin-bottom: 30px;
    font-size: 18px;
    opacity: 0.9;
}

.btn-primary {
    background: var(--primary);
    color: white;
    padding: 12px 25px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
}

.container {
    padding: 60px 5%;
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    text-align: center;
    margin-bottom: 40px;
}

.section-title h2 {
    font-size: 28px;
    color: var(--text-dark);
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s;
}

.card:hover { transform: translateY(-5px); }

.card-image {
    position: relative;
    height: 200px;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.badge {
    position: absolute;
    top: 15px;
    left: 15px;
    padding: 5px 12px;
    border-radius: 5px;
    color: white;
    font-size: 12px;
    font-weight: bold;
}

.badge-nutricion { background: #008eb3; }
.badge-ejercicio  { background: #1e81b0; }
.badge-bienestar  { background: #156580; }

.card-body { padding: 25px; }

.card-body h3 {
    margin-bottom: 15px;
    font-size: 20px;
    color: var(--text-dark);
}

.card-body p {
    color: var(--text-light);
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 20px;
}

.date { font-size: 12px; color: #aaa; }

.view-more { text-align: center; margin-top: 50px; }

.btn-secondary {
    background: var(--primary);
    color: white;
    padding: 12px 35px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: bold;
    border: none;
    cursor: pointer;
    font-size: 14px;
}

/* ---- FOOTER ---- */
.main-footer {
    background-color: var(--footer-bg);
    color: #e0e0e0;
    padding: 60px 5% 25px;
}

.footer-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto 40px;
}

.footer-section:first-child {
    position: relative;
    padding-top: 80px;
}

.footer-logo {
    height: 440px;
    filter: brightness(0) invert(1);
    display: block;
    position: absolute;

    /* --- COORDENADAS DEL LOGO (modifica estos valores) --- */
    top: -210px;      /* Sube (-) o baja (+) */
    left: -120px;      /* Mueve a la izquierda (-) o derecha (+) */
}

.footer-section p {
    font-size: 13px;
    color: #b0c4cc;
    line-height: 1.6;
}

.footer-section h3 {
    color: #fff;
    font-size: 16px;
    margin-bottom: 20px;
    position: relative;
}

.footer-section h3::after {
    content: '';
    position: absolute;
    left: 0; bottom: -6px;
    width: 35px; height: 2px;
    background: #147a96;
}

.footer-section ul { list-style: none; }
.footer-section ul li { margin-bottom: 8px; }
.footer-section ul li a {
    text-decoration: none;
    color: #b0c4cc;
    font-size: 13px;
    transition: color 0.2s;
}
.footer-section ul li a:hover { color: #fff; }

.social-icons { display: flex; gap: 14px; margin-top: 18px; }
.social-icons a {
    color: #fff;
    font-size: 18px;
    transition: color 0.2s, transform 0.2s;
}
.social-icons a:hover { color: #14b5d1; transform: translateY(-3px); }

.ods-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(20,122,150,0.2);
    border: 1px solid #147a96;
    padding: 8px 14px;
    border-radius: 5px;
    margin-top: 12px;
    font-size: 13px;
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 20px;
    text-align: center;
    font-size: 12px;
    color: #888;
}

/* ---- BOTÓN ADMIN EN NAVBAR ---- */
.btn-admin-nav {
    background: linear-gradient(135deg, #1a5276, #0d3349);
    color: white;
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 4px 12px rgba(26,82,118,0.3);
}

.btn-admin-nav:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(26,82,118,0.4);
}