/* ═══════════════════════════════════════════════════════
   NATIVA CONSULTING — public-blog.css  (mobile-first)
   Page Hero · Blog · Buscador · Pagina estática · Comentarios
   MAX 300 líneas — SIN GPU triggers mobile
═══════════════════════════════════════════════════════ */

/* ── PAGE HERO (blog / buscador / pagina) ───────────── */
.page-hero {
    background: var(--primary);
    padding: 5rem 0 3rem;
    text-align: center;
    margin-top: calc(-1 * var(--nav-h));
    padding-top: calc(var(--nav-h) + 3rem);
}
.page-hero-title { color: #fff; margin-bottom: .5rem; }
.page-hero-sub   { color: rgba(255,255,255,.78); font-size: 1.0625rem; max-width: 540px; margin: 0 auto; }

/* ── BLOG FILTERS ───────────────────────────────────── */
.blog-filters {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    margin-bottom: 2rem;
}
.blog-filter-tag {
    display: inline-block;
    padding: .4rem .9rem;
    border-radius: var(--radius-sm);
    font-size: .875rem;
    font-weight: 500;
    color: var(--text-muted);
    background: var(--white);
    border: 1px solid var(--border);
    transition: background var(--transition), color var(--transition), border-color var(--transition);
}
.blog-filter-tag:hover, .blog-filter-tag.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

/* ── BLOG CARD extras (cat, meta) ───────────────────── */
.blog-cat {
    font-size: .75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: var(--accent);
    display: block;
    margin-bottom: .35rem;
}
.blog-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: .8125rem;
    color: var(--text-muted);
    margin-top: auto;
    padding-top: .75rem;
    border-top: 1px solid var(--border);
}

/* ── PAGINATION ─────────────────────────────────────── */
.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    justify-content: center;
    margin-top: 2.5rem;
}
.pagination a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    font-size: .875rem;
    font-weight: 500;
    color: var(--text);
    background: var(--white);
    border: 1px solid var(--border);
    transition: background var(--transition), color var(--transition);
}
.pagination a:hover, .pagination a.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

/* ── ARTICLE HEADER ─────────────────────────────────── */
.article-header {
    background: var(--primary);
    padding: 5rem 0 2.5rem;
    margin-top: calc(-1 * var(--nav-h));
    padding-top: calc(var(--nav-h) + 3rem);
}
.article-header-inner { max-width: 720px; }
.article-cat {
    display: inline-block;
    font-size: .75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: rgba(255,255,255,.7);
    margin-bottom: .75rem;
    border: 1px solid rgba(255,255,255,.3);
    padding: .2rem .6rem;
    border-radius: 4px;
}
.article-cat:hover { color: #fff; border-color: rgba(255,255,255,.7); }
.article-title { color: #fff; margin-bottom: .75rem; }
.article-meta  { color: rgba(255,255,255,.6); font-size: .9375rem; }

/* ── ARTICLE LAYOUT (content + sidebar) ─────────────── */
.article-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2.5rem;
    padding-top: 2.5rem;
    padding-bottom: 3rem;
}
@media (min-width: 1024px) {
    .article-layout { grid-template-columns: minmax(0, 1fr) 300px; align-items: start; }
}

/* ── PROSE (Quill output) ───────────────────────────── */
.prose { line-height: 1.75; color: var(--text); }
.prose h2 { font-size: clamp(1.2rem, 3vw, 1.6rem); margin: 2rem 0 .75rem; }
.prose h3 { font-size: clamp(1rem, 2.5vw, 1.3rem); margin: 1.5rem 0 .5rem; }
.prose p  { margin-bottom: 1.125rem; }
.prose ul, .prose ol { padding-left: 1.5rem; margin-bottom: 1.125rem; }
.prose li { margin-bottom: .4rem; }
.prose img { border-radius: var(--radius-md); max-width: 100%; margin: 1.25rem 0; }
.prose blockquote {
    border-left: 3px solid var(--accent);
    padding: .5rem 1rem;
    margin: 1.25rem 0;
    color: var(--text-muted);
    font-style: italic;
}
.prose pre {
    background: var(--bg-alt);
    border-radius: var(--radius-sm);
    padding: 1rem;
    overflow-x: auto;
    font-size: .875rem;
}
.prose a { color: var(--accent); text-decoration: underline; }
.prose strong { font-weight: 700; }
.prose .ql-align-center  { text-align: center; }
.prose .ql-align-right   { text-align: right; }
.prose .ql-align-justify { text-align: justify; }
.prose .ql-size-small    { font-size: .75em; }
.prose .ql-size-large    { font-size: 1.5em; }
.prose .ql-size-huge     { font-size: 2.5em; }

/* ── COMMENTS ───────────────────────────────────────── */
.article-comments {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}
.article-comments > h3 { margin-bottom: 1.5rem; }
.comentarios-list { display: flex; flex-direction: column; gap: 1.25rem; margin-bottom: 2rem; }
.comentario {
    background: var(--bg-alt);
    border-radius: var(--radius-md);
    padding: 1.25rem;
}
.comentario-autor { font-weight: 700; font-size: .9375rem; margin-bottom: .2rem; }
.comentario-fecha { font-size: .8125rem; color: var(--text-muted); margin-bottom: .75rem; }
.comentario-texto { color: var(--text); line-height: 1.65; }
.comment-form { margin-top: 1.5rem; display: flex; flex-direction: column; gap: 1rem; }

/* ── SIDEBAR ────────────────────────────────────────── */
.article-sidebar { display: flex; flex-direction: column; gap: 1.25rem; }
.aside-card {
    background: var(--white);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    box-shadow: var(--shadow-sm);
}
.aside-card h4 {
    font-size: .875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: var(--text-muted);
    margin-bottom: .875rem;
}
.aside-search {
    width: 100%;
    padding: .625rem .875rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: .9375rem;
    background: var(--bg);
    color: var(--text);
}
.aside-search:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(0,120,191,.15); }
.aside-cats { display: flex; flex-direction: column; gap: .4rem; }
.aside-cats li a {
    font-size: .9375rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: .4rem;
    padding: .3rem 0;
    transition: color var(--transition);
}
.aside-cats li a::before { content: '›'; color: var(--accent); }
.aside-cats li a:hover { color: var(--primary); }
.aside-related {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .625rem 0;
    border-bottom: 1px solid var(--border);
    transition: opacity var(--transition);
}
.aside-related:last-child { border-bottom: none; }
.aside-related:hover { opacity: .8; }
.aside-related img { width: 56px; height: 44px; object-fit: cover; border-radius: 4px; flex-shrink: 0; }
.aside-related span { font-size: .875rem; font-weight: 500; color: var(--text); line-height: 1.4; }

/* ── BUSCADOR ───────────────────────────────────────── */
.search-box { margin-bottom: 2rem; }
.search-input-wrap {
    display: flex;
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    overflow: hidden;
    background: var(--white);
    transition: border-color var(--transition);
}
.search-input-wrap:focus-within { border-color: var(--accent); }
.search-input-wrap input {
    flex: 1;
    border: none;
    padding: .875rem 1rem;
    font-size: 1rem;
    background: transparent;
    color: var(--text);
    min-width: 0;
}
.search-input-wrap input:focus { outline: none; }
.search-input-wrap button {
    padding: .875rem 1.5rem;
    background: var(--primary);
    color: #fff;
    font-size: .9375rem;
    font-weight: 600;
    white-space: nowrap;
    transition: background var(--transition);
    min-height: 44px;
}
.search-input-wrap button:hover { background: var(--primary-dark); }
.search-result {
    padding: 1.25rem 0;
    border-bottom: 1px solid var(--border);
}
.search-result-type {
    font-size: .75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--accent);
    margin-bottom: .35rem;
}
.search-result-title a {
    font-size: 1.0625rem;
    font-weight: 600;
    color: var(--text);
    transition: color var(--transition);
}
.search-result-title a:hover { color: var(--primary); }
.search-result-excerpt { font-size: .9375rem; color: var(--text-muted); margin-top: .4rem; }

/* ── PÁGINA ESTÁTICA ────────────────────────────────── */
.pagina-wrap { padding-bottom: 4rem; }
.pagina-content {
    max-width: 760px;
    margin: 0 auto;
    padding: 2.5rem 1rem 0;
}
@media (min-width: 768px) { .pagina-content { padding: 3rem 1.5rem 0; } }

/* ── CAMPAÑA (contenido HTML/CSS propio, auto-escopeado — ver CampanaScoper) ── */
.campana-wrap { padding-top: var(--nav-h); }
.campana-vencida-aviso {
    background: var(--bg-alt);
    border-bottom: 1px solid var(--border);
    color: var(--text-muted);
    font-size: .85rem;
    text-align: center;
    padding: .75rem 0;
}
