/*--------------------------------------------------------------
# Archivo: template-hub.css
# Estilos para las páginas de clúster temático (Pilar).
--------------------------------------------------------------*/

/* --- Cabecera de la Página Hub (Hero) --- */
.hub-hero {
    position: relative;
    padding: calc(var(--spacing) * 3) 0;
    background-size: cover;
    background-position: center;
    color: white;
    text-align: center;
    min-height: 30vh;
    display: flex;
    align-items: center;
    justify-content: center;
}
.hub-hero .hero-overlay { /* Selector más específico */
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-color: rgba(17, 24, 39, 0.75);
}
.hub-hero .hero-content { /* Selector más específico */
    position: relative;
    z-index: 2;
}
.hub-hero .page-title {
    font-family: var(--font-family-serif);
    font-size: 3rem;
}
.hub-hero .page-content {
    max-width: 65ch;
    margin: 1rem auto 0 auto;
    font-size: 1.125rem;
    color: #D1D5DB;
}
.hub-hero .page-content p {
    margin: 0;
}

/* --- Introducción al Contenido del Hub --- */
.hub-container {
    padding-top: calc(var(--spacing) * 2.5);
    padding-bottom: calc(var(--spacing) * 2.5);
}
.hub-intro {
    text-align: center;
    margin-bottom: calc(var(--spacing) * 2.5);
}
.hub-intro .section-title {
    margin-bottom: 0.5rem;
}
.hub-post-count {
    display: inline-block;
    background-color: var(--color-primary);
    color: white;
    padding: 0.25rem 1rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 500;
}

/* --- Artículo Destacado --- */
.featured-post-section {
    margin-bottom: calc(var(--spacing) * 3);
}
.featured-post-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: calc(var(--spacing) * 2);
    align-items: center;
    text-decoration: none;
    background-color: var(--color-subtle-bg);
    border: 1px solid var(--color-border);
    border-radius: 12px;
    overflow: hidden;
}
.featured-post-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.featured-post-content {
    padding: var(--spacing);
}
.featured-tag {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--color-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.75rem;
}
.featured-post-title {
    font-size: 2rem;
    font-family: var(--font-family-serif);
    color: var(--color-text);
    margin: 0 0 0.75rem 0;
    line-height: 1.2;
}
.featured-post-excerpt {
    color: #6B7280;
    margin-bottom: 1rem;
}
.featured-post-excerpt p { margin: 0; }
.featured-post-card .read-more {
    font-weight: 600;
    color: var(--color-primary);
}

/* --- Grid de Artículos Restantes --- */
.section-title-minor {
    text-align: center;
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    border-top: 1px solid var(--color-border);
    padding-top: calc(var(--spacing) * 2);
}
.hub-posts-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing);
}
.hub-post-item {
    display: block;
    padding: var(--spacing);
    border: 1px solid var(--color-border);
    border-radius: 8px;
    text-decoration: none;
    transition: border-color 0.2s ease-in-out, background-color 0.2s ease-in-out;
}
.hub-post-item:hover {
    border-color: var(--color-primary);
    background-color: var(--color-background);
}
.hub-post-title {
    margin: 0;
    font-size: 1.125rem;
    color: var(--color-text);
}
.hub-post-item:hover .hub-post-title {
    color: var(--color-primary);
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .featured-post-card {
        grid-template-columns: 1fr; /* Apila imagen y contenido */
    }
    .featured-post-thumbnail {
        aspect-ratio: 16/9;
    }
    .hub-posts-grid {
        grid-template-columns: 1fr;
    }
}