/* ============================================================
   HOME v2.1 — Espaço do Povo
   Uma manchete grande sobre preto é o único gesto forte; o resto é
   branco, tipografia e ritmo. Ciano só como chip, régua e botão.
   ============================================================ */

.home { --pad: 16px; }
.home .container { max-width: var(--container-max, 1200px); margin: 0 auto; padding: 0 var(--pad); }

/* ---------- utilidades ---------- */
.kicker {
    display: inline-block; font-family: var(--font-display); font-weight: 700; font-size: 0.75rem;
    color: var(--brand-ink); margin-bottom: 4px;
}
.meta { font-size: 0.8rem; color: var(--muted); margin: 0; }
.chip {
    display: inline-block; padding: 4px 10px; border-radius: 4px; font-family: var(--font-display);
    font-weight: 700; font-size: 0.75rem; text-decoration: none; line-height: 1.3;
}
.chip--brand { background: var(--brand); color: var(--ink); }
.chip--brand:hover { background: #fff; color: var(--ink); }
.sec-head {
    display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px;
    margin: 0 0 20px; padding-bottom: 12px; border-bottom: 3px solid var(--ink);
}
.sec-title { font-family: var(--font-display); font-weight: 700; font-size: 1.5rem; line-height: 1.1; margin: 0; letter-spacing: -0.01em; }
.sec-sub { margin: 6px 0 0; color: var(--muted); font-size: 0.95rem; max-width: 60ch; }
.sec-more {
    display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
    font-family: var(--font-display); font-weight: 700; font-size: 0.85rem; color: var(--brand-ink); text-decoration: none;
}
.sec-more:hover { color: var(--ink); }
.sec-more .ico { width: 1.1em; height: 1.1em; }
.card-img { display: block; width: 100%; height: 100%; object-fit: cover; }
.card-img--placeholder { object-fit: contain; background: var(--ink); }

/* ---------- 1. MANCHETE ---------- */
.manchete { background: var(--ink); color: var(--paper); padding: 24px 0 32px; }
.manchete-grid { display: grid; gap: 24px; }
.manchete-lead-media {
    display: block; aspect-ratio: 16 / 9; overflow: hidden; border-radius: 8px; background: #151515;
}
.manchete-lead-media img { width: 100%; height: 100%; object-fit: cover; object-position: center top; display: block; }
.manchete-lead-body { padding-top: 16px; }
.manchete-lead-title {
    font-family: var(--font-display); font-weight: 700; letter-spacing: -0.02em; line-height: 1.05;
    font-size: clamp(1.75rem, 4.5vw, 3rem); margin: 12px 0 10px; text-wrap: balance;
}
.manchete-lead-title a { color: var(--paper); text-decoration: none; }
.manchete-lead-title a:hover { color: var(--brand); }
.manchete-lead-excerpt { font-size: 1.05rem; line-height: 1.5; color: rgba(250,250,250,0.78); margin: 0 0 10px; max-width: 62ch; }
.manchete .meta { color: rgba(250,250,250,0.6); }

.manchete-rail { display: flex; flex-direction: column; gap: 14px; }
.rail-item {
    display: grid; grid-template-columns: 112px 1fr; gap: 12px; align-items: start;
    padding-top: 14px; border-top: 1px solid rgba(255,255,255,0.12);
}
.rail-item:first-child { border-top: 0; padding-top: 0; }
.rail-media { display: block; aspect-ratio: 16 / 9; border-radius: 6px; overflow: hidden; background: #151515; }
.rail-item .kicker { color: var(--brand); }
.rail-title { font-family: var(--font-display); font-weight: 700; font-size: 1rem; line-height: 1.25; margin: 0; }
.rail-title a { color: var(--paper); text-decoration: none; }
.rail-title a:hover { color: var(--brand); }

@media (min-width: 768px) and (max-width: 1023px) {
    .manchete-rail { display: grid; grid-template-columns: 1fr 1fr; }
}
@media (min-width: 1024px) {
    .manchete { padding: 32px 0 40px; }
    .manchete-grid { grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: 32px; }
    .manchete-rail { gap: 0; justify-content: space-between; align-self: stretch; }
    /* cada item ocupa 1/4 da altura da manchete: sem sobra embaixo */
    .rail-item { flex: 1 1 0; grid-template-columns: 148px 1fr; align-items: center; padding: 12px 0; border-top: 1px solid rgba(255,255,255,0.12); }
    .rail-item:first-child { padding-top: 0; border-top: 0; }
    .rail-item:last-child { padding-bottom: 0; }
}

/* ---------- 2. VOZES ---------- */
.vozes { padding: 40px 0 8px; }
.vozes-track {
    display: grid; grid-auto-flow: column; grid-auto-columns: minmax(260px, 1fr); gap: 20px;
    overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; scrollbar-width: thin;
}
.voz { display: grid; grid-template-columns: 56px 1fr; gap: 12px; scroll-snap-align: start; align-items: center; min-height: 72px; }
.voz-avatar {
    width: 56px; height: 56px; border-radius: 50%; overflow: hidden; display: block; background: var(--paper-2);
    border: 2px solid var(--brand);
}
.voz-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.voz-avatar-fallback { display: grid; place-items: center; width: 100%; height: 100%; font-family: var(--font-display); font-weight: 700; font-size: 1.3rem; color: var(--ink); }
.voz-name { display: block; font-family: var(--font-display); font-weight: 700; font-size: 0.9rem; }
.voz-title {
    font-family: var(--font-body); font-weight: 500; font-size: 0.95rem; line-height: 1.35; margin: 2px 0 0;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; /* no máximo 2 linhas: cards iguais */
}
.voz-title a { color: var(--ink); text-decoration: none; }
.voz-title a:hover { color: var(--brand-ink); text-decoration: underline; text-underline-offset: 3px; }
@media (min-width: 1024px) {
    .vozes-track { grid-auto-flow: row; grid-template-columns: repeat(3, 1fr); overflow: visible; row-gap: 24px; }
}

/* ---------- 3. EDITORIAS ---------- */
.editorias { padding: 40px 0 8px; }
.editorias-grid { display: grid; gap: 32px; }
.editoria-name { font-family: var(--font-display); font-weight: 700; font-size: 1.1rem; margin: 0 0 12px; padding-bottom: 8px; border-bottom: 2px solid var(--brand); }
.editoria-name a { color: var(--ink); text-decoration: none; }
.editoria-media { display: block; aspect-ratio: 16 / 9; overflow: hidden; border-radius: 6px; background: var(--paper-2); margin-bottom: 10px; }
.editoria-lead-title { font-family: var(--font-display); font-weight: 700; font-size: 1.1rem; line-height: 1.25; margin: 0 0 12px; }
.editoria-lead-title a { color: var(--ink); text-decoration: none; }
.editoria-lead-title a:hover { color: var(--brand-ink); }
.editoria-list { list-style: none; margin: 0; padding: 0; }
.editoria-list li { padding: 9px 0; border-top: 1px solid var(--line); font-size: 0.95rem; line-height: 1.35; }
.editoria-list a { color: var(--ink); text-decoration: none; }
.editoria-list a:hover { color: var(--brand-ink); text-decoration: underline; text-underline-offset: 3px; }
.editoria-more { display: inline-flex; align-items: center; gap: 6px; margin-top: 10px; font-family: var(--font-display); font-weight: 700; font-size: 0.85rem; color: var(--brand-ink); text-decoration: none; }
.editoria-more:hover { color: var(--ink); }
@media (min-width: 640px) { .editorias-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .editorias-grid { grid-template-columns: repeat(3, 1fr); } }

/* ---------- 4. ÚLTIMAS + LATERAL ---------- */
.ultimas { padding: 40px 0 16px; background: var(--paper-2); margin-top: 32px; }
.ultimas-grid { display: grid; gap: 40px; }
.posts-grid { display: grid; gap: 24px; }
.post-card { display: grid; grid-template-columns: 120px 1fr; gap: 12px; align-items: start; }
.post-card-media { display: block; aspect-ratio: 16 / 9; overflow: hidden; border-radius: 6px; background: #ddd; }
.post-card-title { font-family: var(--font-display); font-weight: 700; font-size: 1rem; line-height: 1.25; margin: 0 0 6px; }
.post-card-title a { color: var(--ink); text-decoration: none; }
.post-card-title a:hover { color: var(--brand-ink); }
.post-card-excerpt { display: none; font-size: 0.9rem; line-height: 1.45; color: var(--muted); margin: 0 0 6px; }
.load-more-wrap { text-align: center; margin-top: 28px; }
@media (min-width: 640px) {
    .posts-grid { grid-template-columns: repeat(2, 1fr); }
    .post-card { grid-template-columns: 1fr; gap: 10px; }
    .post-card-excerpt { display: block; }
}
@media (min-width: 1024px) {
    .ultimas-grid { grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); }
    .posts-grid { grid-template-columns: repeat(3, 1fr); }
}
.ultimas-side { display: grid; gap: 24px; align-content: start; }
.side-title { font-family: var(--font-display); font-weight: 700; font-size: 1.1rem; margin: 0 0 12px; }
.mais-lidas, .side-newsletter, .side-pauta { background: var(--paper); border-radius: 8px; padding: 20px; border: 1px solid var(--line); }
.mais-lidas-list { list-style: none; margin: 0; padding: 0; counter-reset: lidas; }
.mais-lidas-list li {
    counter-increment: lidas; display: grid; grid-template-columns: 32px 1fr; column-gap: 8px; padding: 10px 0; border-top: 1px solid var(--line);
}
.mais-lidas-list li:first-child { border-top: 0; padding-top: 0; }
.mais-lidas-list li::before {
    content: counter(lidas); grid-row: 1 / 3; font-family: var(--font-display); font-weight: 700; font-size: 1.6rem; line-height: 1; color: var(--brand-ink);
}
.mais-lidas-list .kicker { grid-column: 2; margin: 0; }
.mais-lidas-list a { grid-column: 2; color: var(--ink); text-decoration: none; font-weight: 500; font-size: 0.95rem; line-height: 1.3; }
.mais-lidas-list a:hover { color: var(--brand-ink); }
.side-newsletter { background: var(--brand); border-color: var(--brand); color: var(--ink); }
.side-newsletter p { margin: 0 0 12px; font-size: 0.95rem; }
.side-newsletter input {
    width: 100%; padding: 12px 14px; border: 2px solid var(--ink); border-radius: 8px; font: inherit; margin-bottom: 8px; background: #fff; color: var(--ink);
}
.side-newsletter .btn { width: 100%; background: var(--ink); color: var(--paper); border-color: var(--ink); }
.side-newsletter .btn:hover { background: #222; }
.side-pauta p { margin: 0 0 12px; font-size: 0.95rem; color: var(--muted); }

/* ---------- 5. VÍDEOS ---------- */
.videos { background: var(--ink); color: var(--paper); padding: 40px 0 48px; }
.videos .sec-head { border-bottom-color: rgba(255,255,255,0.2); }
.videos .sec-title, .manchete h2, .manchete h3 { color: var(--paper); }
.videos .sec-more { color: var(--brand); }
.videos-grid { display: grid; gap: 20px; }
.video-card { display: block; text-decoration: none; color: var(--paper); }
.video-media { position: relative; display: block; aspect-ratio: 16 / 9; border-radius: 6px; overflow: hidden; background: #151515; }
.video-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.video-play {
    position: absolute; inset: 0; margin: auto; width: 56px; height: 56px; border-radius: 50%;
    background: var(--brand); color: var(--ink); display: grid; place-items: center; transition: transform 0.15s;
}
.video-play .ico { fill: currentColor; stroke: none; }
.video-card:hover .video-play { transform: scale(1.08); }
.video-title { display: block; margin-top: 10px; font-family: var(--font-display); font-weight: 700; font-size: 0.95rem; line-height: 1.3; }
@media (min-width: 640px) { .videos-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .videos-grid { grid-template-columns: repeat(3, 1fr); } }

/* ---------- 6. EDIÇÕES ---------- */
.edicoes { padding: 40px 0 56px; }
.edicoes-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.edicao-card { display: block; text-decoration: none; color: var(--ink); }
.edicao-cover { display: block; aspect-ratio: 3 / 4; overflow: hidden; border-radius: 4px; background: var(--paper-2); border: 1px solid var(--line); }
.edicao-cover img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; }
.edicao-cover-fallback { display: grid; place-items: center; height: 100%; font-family: var(--font-display); font-weight: 700; color: var(--muted); }
.edicao-num { display: block; margin-top: 8px; font-family: var(--font-display); font-weight: 700; font-size: 0.9rem; }
.edicao-date { display: block; font-size: 0.8rem; color: var(--muted); }
.edicao-card:hover .edicao-cover { border-color: var(--brand-ink); }
@media (min-width: 768px) { .edicoes-grid { grid-template-columns: repeat(6, 1fr); } }

/* ---------- 2b. REDE ESPAÇO DO POVO ---------- */
.rede { padding: 40px 0 8px; }
.rede-track {
    display: grid; grid-auto-flow: column; grid-auto-columns: minmax(180px, 220px); gap: 16px;
    overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; scrollbar-width: thin;
}
.rede-card {
    position: relative; display: flex; flex-direction: column; align-items: center; justify-content: flex-end;
    aspect-ratio: 3 / 4; border-radius: 12px; overflow: hidden; background: var(--ink); color: var(--paper);
    text-decoration: none; padding: 16px 12px 18px; scroll-snap-align: start; isolation: isolate;
}
.rede-cover { position: absolute; inset: 0; z-index: -1; }
.rede-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rede-cover::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0.25) 50%, rgba(0,0,0,0) 100%); }
.rede-avatar {
    width: 64px; height: 64px; border-radius: 50%; overflow: hidden; border: 3px solid var(--paper);
    background: var(--brand); margin-bottom: 10px; display: grid; place-items: center; box-shadow: 0 2px 8px rgba(0,0,0,0.4);
}
.rede-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rede-avatar-fallback { font-family: var(--font-display); font-weight: 700; font-size: 1.5rem; color: var(--ink); }
.rede-name { font-family: var(--font-display); font-weight: 700; font-size: 1rem; text-align: center; line-height: 1.2; text-shadow: 0 1px 3px rgba(0,0,0,0.6); }
.rede-area { font-size: 0.8rem; color: rgba(250,250,250,0.85); margin-top: 2px; text-align: center; }
a.rede-card:hover .rede-avatar { border-color: var(--brand); }
a.rede-card:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; }
@media (min-width: 1200px) {
    .rede-track { grid-auto-flow: row; grid-template-columns: repeat(5, 1fr); grid-auto-columns: unset; overflow: visible; }
}
