/* Theme Name: Rincon Colombiano V2 */

:root {
    --bg-color: #f8f9fa;
    --header-bg: #EF6E59; 
    --text-main: #000000; 
    --text-muted: #1C3D44; 
    --brand-lime: #EF6E59;
    --neon-green: #00D633;
    --footer-card-bg: #1C3D44; 
    --footer-text-light: #BAF7D9; 
    --footer-accent: #EF6E59; 
    --search-bg: rgba(255, 255, 255, 0.4); 
    --border-color: #EF6E59;
    --font-titles: "Times New Roman", Times, serif; 
    --font-body: 'Lora', serif;         
    --card-radius: 24px; 
    --gap: 20px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body { 
    font-family: var(--font-body); 
    color: var(--text-main); 
    background-color: var(--bg-color); 
    line-height: 1.6; 
    font-size: 17px;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-titles);
    font-weight: 700; 
    line-height: 1.05; 
    margin-top: 0;
    letter-spacing: -0.5px; 
}

a, button, input, .nav-link, .btn { 
    font-family: var(--font-body); 
    text-decoration: none; 
    color: inherit; 
    transition: opacity 0.2s; 
}

ul { list-style: none; margin: 0; padding: 0; }
img { max-width: 100%; height: auto; display: block; }
html { scroll-behavior: smooth; }

/* ==========================================================================
   ESTILOS GENERALES Y UTILIDADES
   ========================================================================== */

.site-main { width: 100%; padding-bottom: 0px; }
.container-grid { max-width: 1400px; margin: 0 auto; padding: 0 20px; display: grid; gap: var(--gap); }
.section-header { max-width: 1400px; margin: 40px auto 20px; padding: 0 20px; }
.section-title { font-family: var(--font-titles); font-size: 1.8rem; font-weight: 700; letter-spacing: -0.5px; margin: 0; }
.text-white { color: #fff; }

.section-title-wrapper { display: flex; align-items: center; gap: 15px; }
.section-arrow-link { flex-shrink: 0; display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 50%; border: 1px solid currentColor; color: inherit; transition: all 0.2s ease; }
.section-arrow-link svg { width: 16px; height: 16px; }
.section-arrow-link:hover { background-color: var(--brand-lime); border-color: var(--brand-lime); color: #fff; transform: translateX(5px); }
.text-white .section-arrow-link { border-color: rgba(255,255,255,0.3); }
.text-white .section-arrow-link:hover { background-color: #fff; color: #000; border-color: #fff; }

.standard-grid { grid-template-columns: repeat(2, 1fr); }
@media (min-width: 768px) { .standard-grid { grid-template-columns: repeat(4, 1fr); } }

/* ==========================================================================
   TARJETAS DE ARTÍCULOS (GENÉRICAS)
   Se mantienen aquí por si se usan fuera de la Home.
   ========================================================================== */
.article-card { position: relative; border-radius: var(--card-radius); overflow: hidden; background: #fff; transition: transform 0.2s; }
.article-card:hover { transform: translateY(-2px); }

.article-card__media { 
    position: relative; 
    width: 100%; 
    height: auto;
    aspect-ratio: 16/9;
    display: block; 
    overflow: hidden; 
}

/* Modificadores de tamaño (usados por el grid de la home) */
.article-card.hero-span-3 .article-card__media,
.article-card.hero-span-4 .article-card__media,
.article-card--overlay .article-card__media {
    height: 100%;
    aspect-ratio: auto;
}

.article-card__img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.article-card:hover .article-card__img { transform: scale(1.03); }
.article-card__body { padding: 15px; }
.article-card__cat { font-size: 10px; font-weight: 800; text-transform: uppercase; background: #000; color: #fff; padding: 4px 12px; border-radius: 100px; display: inline-block; margin-bottom: 12px; letter-spacing: 0.5px; line-height: 1; }
.article-card__title { font-size: 1rem; font-weight: 700; line-height: 1.15; margin: 0; color: #1a1a1a; }
.article-card__meta { font-size: 0.8rem; color: #888; margin-top: 8px; }

/* Estilo Overlay (Texto sobre imagen) */
.article-card--overlay .article-card__link { display: block; height: 100%; position: relative; }
.article-card--overlay .article-card__body { position: absolute; bottom: 0; left: 0; width: 100%; z-index: 2; padding: 20px; background: transparent; }
.article-card--overlay .article-card__title { color: #fff; font-size: 1.1rem; text-shadow: 0 2px 4px rgba(0,0,0,0.5); }
.article-card__gradient { position: absolute; bottom: 0; left: 0; width: 100%; height: 80%; background: linear-gradient(to top, rgba(0,0,0,0.8), transparent); pointer-events: none; z-index: 1; }

/* ==========================================================================
   ARCHIVOS & CATEGORÍAS (Estructura Base)
   ========================================================================== */
.archive-hero {
    position: relative; width: 100%; min-height: 40vh; display: flex; align-items: center;
    background-color: var(--text-muted); color: #ffffff; padding: 60px 20px; overflow: hidden;
}
.archive-hero__overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(circle at 80% 20%, rgba(239,110,89,0.1) 0%, transparent 40%);
    pointer-events: none;
}
.archive-hero__content { max-width: 1200px; margin: 0 auto; position: relative; z-index: 2; }
.archive-hero__title { font-family: var(--font-titles); font-size: 3rem; font-weight: 800; margin-bottom: 20px; line-height: 1.05; color: #fff; }
.archive-hero__description { max-width: 800px; font-size: 1.1rem; line-height: 1.6; opacity: 0.9; font-family: var(--font-body); }

.archive-subnav-container { max-width: 1200px; margin: -40px auto 60px; padding: 0 20px; position: relative; z-index: 3; }
.archive-subnav { display: grid; grid-template-columns: repeat(2, 1fr); gap: 15px; }
@media (min-width: 768px) { .archive-subnav { grid-template-columns: repeat(4, 1fr); gap: 20px; } }
.subnav-card {
    background: #fff; padding: 20px; border-radius: 16px; box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    display: flex; align-items: center; gap: 12px; transition: transform 0.2s, box-shadow 0.2s;
    text-decoration: none; font-family: var(--font-body);
}
.subnav-card:hover { transform: translateY(-3px); box-shadow: 0 8px 20px rgba(0,0,0,0.12); }
.subnav-icon { font-size: 1.5rem; }
.subnav-text { font-weight: 700; color: var(--text-muted); font-size: 1rem; }

.portal-content { max-width: 1200px; margin: 0 auto 80px; padding: 0 20px; }
.archive-grid { display: grid; grid-template-columns: 1fr; gap: 30px; }
@media (min-width: 768px) { .archive-grid { grid-template-columns: repeat(3, 1fr); } }

/* Tarjeta de Archivo (Lista) */
.archive-post-card {
    background: #fff; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    transition: transform 0.2s; height: 100%; display: flex; flex-direction: column;
}
.archive-post-card:hover { transform: translateY(-3px); }
.archive-card-link { text-decoration: none; color: inherit; display: flex; flex-direction: column; height: 100%; }
.archive-card__media { position: relative; width: 100%; padding-top: 56.25%; overflow: hidden; background: #eee; }
.archive-card__img { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.archive-post-card:hover .archive-card__img { transform: scale(1.05); }
.archive-card__body { padding: 20px; flex-grow: 1; display: flex; flex-direction: column; }
.archive-card__title { font-size: 1.2rem; font-weight: 700; margin: 0 0 10px 0; line-height: 1.1; color: var(--text-muted); }
.archive-card__meta { font-size: 0.85rem; color: #666; margin-bottom: 15px; font-family: var(--font-body); }
.meta-sep { margin: 0 5px; }
.archive-read-more { margin-top: auto; font-weight: 700; color: var(--brand-lime); font-size: 0.9rem; }

/* SECCIÓN AUTORIDAD */
.archive-authority { background-color: #FFFBEB; padding: 80px 20px; margin-bottom: 80px; }
.authority-container { max-width: 1000px; margin: 0 auto; }
.authority-title { font-family: var(--font-titles); font-weight: 700; font-size: 2.5rem; color: var(--text-muted); margin-bottom: 30px; text-align: center; line-height: 1.05; }
.authority-columns { column-count: 1; column-gap: 40px; font-size: 1.1rem; line-height: 1.8; color: #333; font-family: var(--font-body); }
@media (min-width: 768px) { .authority-columns { column-count: 2; text-align: justify; } }

/* FAQ GENÉRICO */
.archive-faq { max-width: 800px; margin: 0 auto 100px; padding: 0 20px; }
.faq-main-title { font-family: var(--font-titles); text-align: center; font-size: 2.2rem; color: var(--text-muted); margin-bottom: 40px; font-weight: 800; }
.faq-item { border-bottom: 1px solid #ddd; margin-bottom: 10px; }
.faq-question { font-weight: 700; font-size: 1.1rem; padding: 20px 0; cursor: pointer; list-style: none; position: relative; color: var(--text-muted); font-family: var(--font-body); }
.faq-question::-webkit-details-marker { display: none; }
.faq-question::after { content: '+'; position: absolute; right: 0; font-weight: 400; font-size: 1.5rem; color: var(--brand-lime); }
details[open] .faq-question::after { content: '-'; }
.faq-answer { padding-bottom: 20px; color: #555; line-height: 1.6; font-family: var(--font-body); }

/* ==========================================================================
   TAGS (Estilos Genéricos)
   ========================================================================== */
.tag-page-container { padding: 40px 20px; background-color: #fff; }
.tag-container-width { max-width: 900px; margin: 0 auto; }
.tag-header { border-bottom: 2px solid var(--text-muted); padding-bottom: 20px; margin-bottom: 30px; }
.tag-title { font-family: var(--font-titles); font-size: 2.5rem; font-weight: 800; color: #1a1a1a; margin: 5px 0 15px; }
.tag-description { font-family: var(--font-body); font-size: 1.1rem; color: #555; line-height: 1.6; }
.tag-posts-list { display: flex; flex-direction: column; gap: 25px; }
.tag-list-card { border-bottom: 1px solid #eee; padding-bottom: 25px; }
.tag-list-card:last-child { border: none; }
.tag-card-link { display: flex; gap: 25px; text-decoration: none; align-items: flex-start; }
.tag-card-media { width: 240px; height: 160px; flex-shrink: 0; border-radius: 8px; overflow: hidden; background: #f0f0f0; }
.tag-card-img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.tag-card-link:hover .tag-card-img { transform: scale(1.05); }
.tag-card-content { flex: 1; }
.tag-card-date { font-size: 0.8rem; text-transform: uppercase; color: #999; font-weight: 700; display: block; margin-bottom: 5px; }
.tag-card-title { font-family: var(--font-titles); font-size: 1.4rem; font-weight: 700; color: var(--text-muted); line-height: 1.2; margin: 0 0 10px; }
.tag-card-link:hover .tag-card-title { color: var(--brand-lime); }
.tag-card-excerpt { font-size: 0.95rem; color: #555; line-height: 1.5; margin: 0; }
@media (max-width: 768px) { .tag-card-link { flex-direction: column; gap: 15px; } .tag-card-media { width: 100%; height: 200px; } .tag-title { font-size: 2rem; } }

/* ==========================================================================
   PAGINACIÓN GLOBAL (V7.4 - Integrada y Limpia)
   Aplica a: Categorías, Tags, Búsqueda
   ========================================================================== */
.tag-pagination {
    margin-top: 20px;  /* Pequeño respiro */
    padding-top: 0;
    border-top: none;
    display: flex;
    justify-content: center;
    width: 100%;
}

.tag-pagination .nav-links {
    display: flex;
    flex-wrap: wrap;
    gap: 6px; /* Separación mínima */
    align-items: center;
    justify-content: center;
}

/* Estilo de cada número */
.tag-pagination .page-numbers {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 32px; /* Compacto */
    height: 32px;
    padding: 0;
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 4px; 
    font-family: var(--font-body);
    font-size: 1rem; 
    font-weight: 700;
    color: #333;
    text-decoration: none;
    transition: all 0.2s ease;
    line-height: 1;
}

/* Hover */
.tag-pagination .page-numbers:not(.current):not(.dots):hover {
    background-color: #f9f9f9;
    border-color: var(--text-muted);
    color: var(--text-muted);
    transform: translateY(-1px);
}

/* Página Actual (Activa) */
.tag-pagination .page-numbers.current {
    background-color: var(--text-muted); 
    border-color: var(--text-muted);
    color: #fff;
    cursor: default;
}

/* Puntos suspensivos (...) */
.tag-pagination .page-numbers.dots {
    border: none;
    background: transparent;
    min-width: auto;
    height: auto;
    font-size: 1rem;
    color: #999;
    padding: 0 2px;
}

/* Flechas Anterior/Siguiente */
.tag-pagination .page-numbers.prev, 
.tag-pagination .page-numbers.next {
    padding: 0 10px;
    width: auto;
    background: transparent;
    border: none;
    text-transform: uppercase;
    font-size: 0.8rem;
    height: auto;
}

.tag-pagination .page-numbers.prev:hover, 
.tag-pagination .page-numbers.next:hover {
    background: transparent;
    color: var(--brand-lime); 
    border: none;
    transform: none;
    box-shadow: none;
}

/* ==========================================================================
   PLACEHOLDER DE IMÁGENES GLOBAL
   ========================================================================== */
.img-placeholder {
    width: 100%;
    height: 100%;
    background-color: #eeeeee;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: inherit;
}
/* Opcional: Logo tenue en el fondo del placeholder */
.img-placeholder::after {
    content: 'W.'; /* Reemplazar por ícono o dejar vacío */
    font-family: var(--font-titles);
    font-size: 2rem;
    color: #cccccc;
    font-weight: 800;
}