/* =========================================================
   NewsHub Pro — Front-end Portal Stylesheet
   Inspirado no layout do Entorno Agora (entornoagora.com.br)
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Source+Sans+3:wght@400;600;700&family=Merriweather:wght@700;900&display=swap');

/* ── Variáveis ────────────────────────────────────────────── */
.nhp-portal {
    --nhp-red:       #c0392b;
    --nhp-red-dk:    #96281b;
    --nhp-red-lt:    #fdecea;
    --nhp-dark:      #1a1a1a;
    --nhp-text:      #333333;
    --nhp-muted:     #6b7280;
    --nhp-border:    #e5e7eb;
    --nhp-bg:        #f9f9f9;
    --nhp-white:     #ffffff;
    --nhp-radius:    6px;
    --nhp-shadow:    0 2px 8px rgba(0,0,0,.08);
    --nhp-shadow-hv: 0 6px 18px rgba(0,0,0,.13);
    --nhp-font-body: 'Source Sans 3', 'Helvetica Neue', Arial, sans-serif;
    --nhp-font-title:'Merriweather', Georgia, serif;

    /* Cores por categoria */
    --nhp-c-brasil:               #1565c0;
    --nhp-c-mundo:                #00695c;
    --nhp-c-politica:             #6a1b9a;
    --nhp-c-aguas-lindas-de-goias:#e65100;
    --nhp-c-games:                #2e7d32;
    --nhp-c-esportes:             #0277bd;
    --nhp-c-repercutiu:           #ad1457;
    --nhp-c-saude:                #00838f;
    --nhp-c-destaques:            #c0392b;
    --nhp-c-ultimas-noticias:     #37474f;

    font-family: var(--nhp-font-body);
    color: var(--nhp-text);
    box-sizing: border-box;
}
.nhp-portal *, .nhp-portal *::before, .nhp-portal *::after { box-sizing: inherit; }

/* ── Cabeçalho de seção ───────────────────────────────────── */
.nhp-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-left: 4px solid var(--nhp-red);
    padding-left: 12px;
    margin-bottom: 20px;
}
.nhp-section-title {
    font-family: var(--nhp-font-title);
    font-size: 20px;
    font-weight: 900;
    margin: 0;
    color: var(--nhp-dark);
    text-transform: uppercase;
    letter-spacing: .02em;
}
.nhp-section-title a { color: inherit; text-decoration: none; }
.nhp-section-title a:hover { color: var(--nhp-red); }
.nhp-ver-mais {
    font-size: 13px;
    font-weight: 700;
    color: var(--nhp-red);
    text-decoration: none;
    letter-spacing: .03em;
    white-space: nowrap;
}
.nhp-ver-mais:hover { color: var(--nhp-red-dk); }
.nhp-ver-mais span { font-size: 16px; }

/* ── Badges de categoria ──────────────────────────────────── */
.nhp-badge {
    display: inline-block;
    padding: 2px 9px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .06em;
    text-decoration: none;
    background: var(--nhp-red);
    color: #fff;
    margin-bottom: 7px;
    transition: opacity .15s;
}
.nhp-badge:hover { opacity: .85; color: #fff; }

/* Badge por categoria */
.nhp-badge--brasil               { background: var(--nhp-c-brasil); }
.nhp-badge--mundo                { background: var(--nhp-c-mundo); }
.nhp-badge--politica             { background: var(--nhp-c-politica); }
.nhp-badge--aguas-lindas-de-goias{ background: var(--nhp-c-aguas-lindas-de-goias); }
.nhp-badge--games                { background: var(--nhp-c-games); }
.nhp-badge--esportes             { background: var(--nhp-c-esportes); }
.nhp-badge--repercutiu           { background: var(--nhp-c-repercutiu); }
.nhp-badge--saude                { background: var(--nhp-c-saude); }
.nhp-badge--destaques            { background: var(--nhp-c-destaques); }
.nhp-badge--ultimas-noticias     { background: var(--nhp-c-ultimas-noticias); }

/* ── Card base ────────────────────────────────────────────── */
.nhp-card {
    background: var(--nhp-white);
    border-radius: var(--nhp-radius);
    overflow: hidden;
    box-shadow: var(--nhp-shadow);
    transition: box-shadow .2s, transform .2s;
    display: flex;
    flex-direction: column;
}
.nhp-card:hover {
    box-shadow: var(--nhp-shadow-hv);
    transform: translateY(-3px);
}
.nhp-card__img-link {
    display: block;
    overflow: hidden;
    position: relative;
    aspect-ratio: 16/9;
    background: #eee;
}
.nhp-card__img-link img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .35s ease;
}
.nhp-card:hover .nhp-card__img-link img { transform: scale(1.04); }
.nhp-card__no-img {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #e0e0e0 0%, #c8c8c8 100%);
}
.nhp-card__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,.72) 0%, transparent 55%);
    pointer-events: none;
}
.nhp-card__body {
    padding: 14px 16px 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
}
.nhp-card__body--over {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px 18px;
    background: transparent;
}
.nhp-card__title {
    font-family: var(--nhp-font-title);
    font-size: 15px;
    font-weight: 700;
    line-height: 1.35;
    margin: 0 0 8px;
    flex: 1;
}
.nhp-card__title a {
    color: var(--nhp-dark);
    text-decoration: none;
    transition: color .15s;
}
.nhp-card__title a:hover { color: var(--nhp-red); }
.nhp-card__body--over .nhp-card__title,
.nhp-card__body--over .nhp-card__title a { color: #fff; font-size: 18px; }
.nhp-card__body--over .nhp-card__date { color: rgba(255,255,255,.75); }
.nhp-card__title--sm { font-size: 14px; }
.nhp-card__excerpt {
    font-size: 13px;
    color: var(--nhp-muted);
    line-height: 1.55;
    margin: 0 0 10px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.nhp-card__meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
    padding-top: 8px;
    border-top: 1px solid var(--nhp-border);
}
.nhp-card__date {
    font-size: 12px;
    color: var(--nhp-muted);
}
.nhp-card__link {
    font-size: 12px;
    font-weight: 700;
    color: var(--nhp-red);
    text-decoration: none;
    white-space: nowrap;
}
.nhp-card__link:hover { color: var(--nhp-red-dk); }

/* ── Grid layout ──────────────────────────────────────────── */
.nhp-grid {
    display: grid;
    gap: 22px;
}
.nhp-cols-2 { grid-template-columns: repeat(2, 1fr); }
.nhp-cols-3 { grid-template-columns: repeat(3, 1fr); }
.nhp-cols-4 { grid-template-columns: repeat(4, 1fr); }

/* ── Featured layout ──────────────────────────────────────── */
.nhp-featured-wrap {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 22px;
    align-items: start;
}
.nhp-card--main {
    position: relative;
}
.nhp-card--main .nhp-card__img-link {
    aspect-ratio: 16/9;
    height: 100%;
    min-height: 320px;
}
.nhp-featured-side {
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.nhp-card--side {
    flex-direction: row;
    align-items: stretch;
}
.nhp-card__img-link--side {
    width: 120px;
    min-width: 120px;
    aspect-ratio: 1/1;
    flex-shrink: 0;
}
.nhp-card--side .nhp-card__body {
    padding: 10px 12px;
}
.nhp-card--side .nhp-card__title { font-size: 13px; }
.nhp-card--side .nhp-card__meta { border-top: none; padding-top: 4px; }

/* ── List layout ──────────────────────────────────────────── */
.nhp-list { display: flex; flex-direction: column; gap: 0; }
.nhp-list-item {
    display: flex;
    gap: 18px;
    padding: 16px 0;
    border-bottom: 1px solid var(--nhp-border);
    align-items: flex-start;
}
.nhp-list-item:last-child { border-bottom: none; }
.nhp-list-item__img {
    width: 140px;
    min-width: 140px;
    aspect-ratio: 16/9;
    overflow: hidden;
    border-radius: var(--nhp-radius);
    background: #eee;
    flex-shrink: 0;
}
.nhp-list-item__img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .3s;
}
.nhp-list-item:hover .nhp-list-item__img img { transform: scale(1.05); }
.nhp-list-item__body { flex: 1; }
.nhp-list-item__body .nhp-card__title { font-size: 16px; }
.nhp-sep { color: var(--nhp-border); margin: 0 4px; }
.nhp-source { font-size: 12px; color: var(--nhp-muted); }
.nhp-source a { color: var(--nhp-muted); text-decoration: underline dotted; }

/* ── Botão ver mais ───────────────────────────────────────── */
.nhp-ver-mais-wrap {
    text-align: center;
    margin-top: 28px;
}
.nhp-btn-mais {
    display: inline-block;
    padding: 10px 32px;
    background: var(--nhp-red);
    color: #fff;
    font-family: var(--nhp-font-body);
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .06em;
    text-decoration: none;
    border-radius: 4px;
    transition: background .15s, transform .15s;
}
.nhp-btn-mais:hover {
    background: var(--nhp-red-dk);
    color: #fff;
    transform: translateY(-1px);
}

/* ── Empty state ──────────────────────────────────────────── */
.nhp-empty {
    text-align: center;
    color: var(--nhp-muted);
    padding: 32px;
    font-style: italic;
}

/* ── Responsivo ───────────────────────────────────────────── */
@media (max-width: 1024px) {
    .nhp-cols-4 { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
    .nhp-featured-wrap {
        grid-template-columns: 1fr;
    }
    .nhp-card--main .nhp-card__img-link { min-height: 220px; }
    .nhp-cols-3, .nhp-cols-4 { grid-template-columns: repeat(2, 1fr); }
    .nhp-list-item__img { width: 110px; min-width: 110px; }
}

@media (max-width: 480px) {
    .nhp-cols-2, .nhp-cols-3, .nhp-cols-4 { grid-template-columns: 1fr; }
    .nhp-list-item { flex-direction: column; }
    .nhp-list-item__img { width: 100%; aspect-ratio: 16/9; }
    .nhp-card--side { flex-direction: column; }
    .nhp-card__img-link--side { width: 100%; aspect-ratio: 16/9; }
    .nhp-section-title { font-size: 17px; }
}
