/* estilos.css */
:root {
    --primary: #2c3e50;
    --accent: #3498db;
    --bg: #f4f7f6;
}

body { 
    font-family: 'Segoe UI', sans-serif; 
    margin: 0; 
    display: flex; 
    flex-direction: column; 
    min-height: 100vh; 
    background: var(--bg); 
}

/* Escritorio: Menú a la izquierda */
@media (min-width: 768px) {
    body { flex-direction: row; }
    nav { 
        width: 250px; 
        height: 100vh; 
        position: sticky; 
        top: 0; 
        display: flex;
        flex-direction: column;
    }
}

nav { 
    background: var(--primary); 
    color: white; 
    padding: 20px;
    box-shadow: 2px 0 5px rgba(0,0,0,0.1);
}

nav h1 { font-size: 1.3rem; margin: 0 0 20px 0; text-align: center; }

#menu-dinamico { 
    display: flex; 
    gap: 10px; 
    overflow-x: auto; 
    padding-bottom: 10px;
}

@media (min-width: 768px) {
    #menu-dinamico { flex-direction: column; overflow-x: visible; }
}

.btn-menu {
    background: rgba(255,255,255,0.1);
    border: none;
    color: white;
    padding: 12px 20px;
    border-radius: 5px;
    cursor: pointer;
    white-space: nowrap;
    transition: 0.3s;
    text-align: left;
}

.btn-menu:hover { background: var(--accent); }

main { flex-grow: 1; padding: 20px; }

.link-card {
    display: block;
    background: white;
    padding: 18px;
    margin-bottom: 12px;
    border-radius: 10px;
    text-decoration: none;
    color: var(--primary);
    font-weight: 600;
    box-shadow: 0 3px 6px rgba(0,0,0,0.05);
    transition: 0.2s;
}

.link-card:hover { border-left: 5px solid var(--accent); padding-left: 23px; }

.contenedor-imagen img {
    max-width: 90%;
    max-height: 90vh; /* Evita que la imagen desborde verticalmente */
    object-fit: contain; /* Mantiene las proporciones de la imagen */
}