/* ==========================================================================
   Brandema — brandema.index (/news)
   Carregado só nas páginas de /news. Usa os tokens de tokens.css.
   1. Cabeçalho compacto (sem hero grande e sem faixa de logos)
   2. Marca brandema.index
   3. Filtro de categorias
   4. Cards da listagem
   5. Página da matéria
   6. Barra lateral
   ========================================================================== */

/* Logo brandema.index no header das páginas do /news
   (mais larga que a padrão por causa do ".index") */
.site-logo--index {
  width: clamp(170px, 36vw, 260px);
}

/* ---------------------------------------------------------------------------
   1. Cabeçalho compacto
   --------------------------------------------------------------------------- */
.news-head {
  padding-top: calc(var(--header-h) + clamp(1.5rem, 4vw, 3rem));
  padding-bottom: clamp(1.5rem, 3vw, 2.5rem);
  border-bottom: var(--border);
}

.news-head__inner {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.news-head__title {
  font-size: var(--fs-h2);
  letter-spacing: -0.03em;
}

.news-head .lead {
  max-width: 62ch;
}

/* ---------------------------------------------------------------------------
   2. Marca brandema.index (texto; trocar por imagem quando o selo estiver pronto)
   --------------------------------------------------------------------------- */
.index-mark {
  font-weight: var(--fw-bold);
  letter-spacing: -0.03em;
}

.index-mark__dot {
  color: var(--color-accent-text);
}

/* ---------------------------------------------------------------------------
   3. Filtro de categorias
   --------------------------------------------------------------------------- */
.news-filter {
  margin-bottom: var(--space-7);
}

.news-filter .pill {
  cursor: pointer;
  background: none;
  font: inherit;
  font-size: var(--fs-small);
}

.news-filter .pill[aria-pressed="true"] {
  color: var(--color-bg);
  background: var(--color-text);
  border-color: var(--color-text);
}

.news-empty {
  padding: var(--space-7) var(--space-5);
  text-align: center;
  color: var(--color-text-muted);
  border: 1px dashed var(--color-line-strong);
  border-radius: var(--radius);
}

/* ---------------------------------------------------------------------------
   4. Cards da listagem
   --------------------------------------------------------------------------- */
.news-grid {
  list-style: none;
  padding: 0;
  display: grid;
  gap: var(--space-7) var(--space-6);
}

@media (min-width: 768px) {
  .news-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 1100px) {
  .news-grid { grid-template-columns: repeat(3, 1fr); }
}

.news-grid > li[hidden] {
  display: none;
}

.news-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  height: 100%;
}

.news-card__media {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--color-surface);
}

.news-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--dur) var(--ease);
}

.news-card:hover .news-card__media img {
  transform: scale(1.04);
}

.news-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2) var(--space-4);
  font-family: var(--font-mono);
  font-size: var(--fs-small);
  color: var(--color-text-faint);
}

.news-tag {
  position: relative;
  z-index: 2; /* fica acima do link que cobre o card */
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  font-weight: var(--fw-medium);
  letter-spacing: var(--ls-caps);
  text-transform: uppercase;
  color: var(--color-accent-text);
}

.news-meta__tags {
  display: inline-flex;
  flex-wrap: wrap;
  gap: var(--space-1) var(--space-3);
}

.news-tag:hover {
  text-decoration: underline;
}

.news-card__title {
  font-size: var(--fs-h5);
  line-height: var(--lh-heading);
}

/* O link do título cobre o card inteiro */
.news-card__title a::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
}

.news-card__title a:hover {
  color: var(--color-accent-text);
}

.news-card__excerpt {
  color: var(--color-text-muted);
  font-size: var(--fs-small);
}

/* ---------------------------------------------------------------------------
   5. Página da matéria
   --------------------------------------------------------------------------- */
.post-layout {
  display: grid;
  gap: var(--space-8);
}

/* A seção da matéria é seguida pela seção do CTA: sem isto, os dois paddings
   somam 240px de vazio entre "Compartilhar" e o CTA no desktop. */
.section:has(> .post-layout) {
  padding-bottom: 0;
}

@media (min-width: 1024px) {
  .post-layout {
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: var(--space-8) clamp(3rem, 6vw, 6rem);
    align-items: start;
  }
}

/* Título da matéria: mesmo estilo do .page-hero__title (caixa alta + itálico,
   com "-" e "//" via .deco-dash/.deco-slash), num tamanho entre h3 e h2
   para caber títulos longos. 28px no celular → 48px no desktop. */
.post-head__title {
  font-size: clamp(1.75rem, 1.2rem + 2.2vw, 3rem);
  font-style: italic;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  line-height: 1.1;
  max-width: 28ch;
  overflow-wrap: break-word;
}

/* Subtítulo: segunda parte do título, menor e sem caixa alta */
.post-head__subtitle {
  display: block;
  margin-top: 0.5em;
  font-size: clamp(1.125rem, 0.95rem + 0.9vw, 1.75rem); /* 18 → 28 */
  font-style: normal;
  font-weight: var(--fw-semibold);
  text-transform: none;
  letter-spacing: -0.01em;
  line-height: 1.3;
  color: var(--color-text-muted);
}

/* No desktop, o cabeçalho da matéria usa as mesmas colunas da matéria:
   a barra de informações (e o botão de compartilhar) termina na borda da capa. */
@media (min-width: 1024px) {
  .news-head--post .news-head__inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: var(--space-4) clamp(3rem, 6vw, 6rem);
  }

  .news-head--post .news-head__inner > * {
    grid-column: 1;
  }
}

/* Capa mais perto da linha do cabeçalho (antes: 60px no desktop) */
.news-head--post + .section {
  padding-top: clamp(1.25rem, 2.5vw, 2rem); /* 20 → 32px */
}

/* Selo no cabeçalho da listagem ("Humanos e máquinas opinam lado a lado.") */
.news-head__badge {
  margin: 0;
  line-height: 1;
}

/* ---- Seletor de versão da matéria (Humano / IA) ----
   Montado pelo news.js dentro de [data-versoes]. Mesmo visual do .human-badge. */
.versoes {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-2);
}

.versoes:empty {
  display: none; /* sem JavaScript: só o texto humano aparece */
}

.versoes__pergunta {
  margin: 0;
  font-size: var(--fs-small);
  color: var(--color-text-muted);
}

.versoes__tabs {
  display: inline-flex;
  gap: 4px;
  padding: 3px;
  border: 1.5px solid var(--brand-black);
  border-radius: var(--radius-pill);
}

.versoes__tab {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  min-height: 36px;
  padding: 0.4rem 0.9rem;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  font-weight: var(--fw-medium);
  letter-spacing: var(--ls-caps);
  text-transform: uppercase;
  color: var(--color-text);
  background: transparent;
  border: 0;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition:
    color var(--dur-fast) ease,
    background-color var(--dur-fast) ease;
}

.versoes__tab svg {
  flex: none;
  width: 16px;
  height: 16px;
}

.versoes__tab[aria-selected="false"]:hover {
  background: var(--color-surface);
}

.versoes__tab--humana[aria-selected="true"] {
  color: var(--brand-black);
  background: var(--brand-lime);
}

.versoes__tab--ia[aria-selected="true"] {
  color: #fff;
  background: var(--brand-magenta);
}

/* Pulso discreto no botão da IA, uma vez, na primeira visita */
.versoes__tab--pulso {
  animation: versao-pulso 1.6s var(--ease-out) 0.8s 1;
}

@keyframes versao-pulso {
  0%   { box-shadow: 0 0 0 0 rgba(198, 25, 96, 0.45); }
  100% { box-shadow: 0 0 0 10px rgba(198, 25, 96, 0); }
}

/* Autor na barra de informações: troca conforme a versão (news.js) */
.news-meta__autor [hidden] {
  display: none;
}

/* Troca suave do texto */
.post-version--enter {
  animation: versao-entra 0.35s var(--ease-out);
}

@keyframes versao-entra {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .versoes__tab,
  .versoes__tab--pulso,
  .post-version--enter {
    animation: none;
    transition: none;
  }
}

/* Celular: barra de informações em 2 linhas, com o botão de compartilhar à direita
   Linha 1: categoria · Linha 2: data + autor */
@media (max-width: 639px) {
  .news-head--post .news-meta {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: var(--space-1) var(--space-3);
    white-space: nowrap; /* "Por Mateus Costa" não quebra (cabe até em 320px) */
  }

  .news-head--post .news-meta .news-meta__tags {
    grid-column: 1 / 3;
    grid-row: 1;
    justify-self: start;
  }

  .news-head--post .news-meta time {
    grid-column: 1;
    grid-row: 2;
  }

  .news-head--post .news-meta time + span {
    grid-column: 2;
    grid-row: 2;
  }

  .news-head--post .share-menu {
    grid-column: 3;
    grid-row: 1 / 3;
    margin-left: 0;
  }
}

/* Botão de compartilhar (fim da barra de informações) */
.share-menu {
  position: relative;
  margin-left: auto;
}

html:not(.js) .share-menu {
  display: none; /* sem JavaScript, ficam os botões do fim da matéria */
}

.share-menu__toggle {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  color: var(--color-text);
  background: var(--color-bg);
  border: 1.5px solid var(--color-text);
  border-radius: var(--radius-round);
  cursor: pointer;
  transition:
    color var(--dur-fast) ease,
    background-color var(--dur-fast) ease;
}

.share-menu__toggle svg {
  width: 20px;
  height: 20px;
}

.share-menu__toggle:hover,
.share-menu__toggle[aria-expanded="true"] {
  color: var(--color-bg);
  background: var(--color-text);
}

.share-menu__panel {
  position: absolute;
  top: calc(100% + var(--space-2));
  right: 0;
  z-index: 20;
  min-width: 220px;
  padding: var(--space-3);
  background: var(--color-bg);
  border: 1px solid var(--color-line-strong);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
}

.share-menu__panel[hidden] {
  display: none;
}

.share-menu__title {
  padding: var(--space-1) var(--space-3) var(--space-2);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  font-weight: var(--fw-medium);
  letter-spacing: var(--ls-caps);
  text-transform: uppercase;
  color: var(--color-text-faint);
}

.share-menu__list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.share-menu__item {
  display: block;
  width: 100%;
  padding: var(--space-2) var(--space-3);
  font: inherit;
  font-family: var(--font-body);
  font-size: var(--fs-small);
  text-align: left;
  color: var(--color-text);
  background: none;
  border: 0;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

.share-menu__item:hover {
  background: var(--color-surface);
}

.post-cover {
  margin: 0 0 var(--space-7);
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--color-surface);
}

.post-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Capa dentro do texto (depois de ~1/3), como nos portais de notícia */
.prose .post-cover {
  margin-block: var(--space-7);
}

.prose .post-cover + * {
  margin-top: 0; /* o espaço abaixo da capa já vem da margem dela */
}

/* Posição da capa: no celular/tablet fica no topo, antes do texto;
   no desktop fica dentro do texto (depois de ~1/3). É a mesma imagem,
   então o navegador baixa uma vez só. */
@media (max-width: 1023px) {
  .prose .post-cover { display: none; }
}
@media (min-width: 1024px) {
  .post-cover--topo { display: none; }
}

/* Texto da matéria: ocupa a largura toda da coluna, igual à capa */
.prose {
  font-size: 1.0625rem;
}

/* a imagem lateral (float) não vaza para fora do texto.
   Não use display no .prose: ele anula o [hidden] que esconde a versão da IA. */
.prose::after {
  content: "";
  display: table;
  clear: both;
}

/* garantia: bloco de versão escondido continua escondido, mesmo se alguma regra mudar o display */
.post-version[hidden] {
  display: none !important;
}

.prose .lead {
  max-width: none; /* o .lead do site é limitado a 60ch */
}

.prose > * + * {
  margin-top: var(--space-5);
}

.prose h2 {
  margin-top: var(--space-7);
  font-size: var(--fs-h4);
}

.prose h3 {
  margin-top: var(--space-6);
  font-size: var(--fs-h5);
}

.prose a {
  color: var(--color-accent-text);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.prose ul,
.prose ol {
  padding-left: 1.25em;
}

.prose li + li {
  margin-top: var(--space-2);
}

.prose blockquote {
  margin-inline: 0;
  padding-left: var(--space-5);
  border-left: 3px solid var(--color-accent-2);
  font-style: italic;
  color: var(--color-text-muted);
}

.prose figure {
  margin-inline: 0;
}

.prose figure img {
  border-radius: var(--radius);
}

.prose figcaption {
  margin-top: var(--space-2);
  font-size: var(--fs-small);
  color: var(--color-text-faint);
}

/* Imagem lateral: .post-figure--esquerda ou .post-figure--direita.
   A partir de 640px fica de um lado e o texto corre do outro; no celular ocupa a largura toda.
   Com <a data-lightbox> em volta da imagem, o clique abre o lightbox (seção 9 do news.js).
   Também serve para a capa dentro do texto: <figure class="post-cover post-figure--direita">. */
.prose .post-figure--esquerda,
.prose .post-figure--direita {
  margin-bottom: var(--space-5);
}

@media (min-width: 640px) {
  .prose .post-figure--esquerda,
  .prose .post-figure--direita {
    width: 45%;
    margin-block: var(--space-2) var(--space-4);
  }
  .prose .post-figure--esquerda {
    float: left;
    margin-inline: 0 var(--space-6);
  }
  .prose .post-figure--direita {
    float: right;
    margin-inline: var(--space-6) 0;
  }
  .prose .post-figure--esquerda + *,
  .prose .post-figure--direita + * { margin-top: 0; }
  /* lista ao lado da imagem: não deixa os marcadores encostarem nela */
  .prose ul, .prose ol { overflow: hidden; }
  /* capa, títulos, caixas e outra imagem lateral começam abaixo da imagem lateral anterior */
  .prose .post-cover, .prose .post-figure--esquerda, .prose .post-figure--direita,
  .prose h2, .prose h3, .prose aside { clear: both; }
}

.post-figure__zoom {
  position: relative;
  display: block;
  border-radius: var(--radius);
  cursor: zoom-in;
}

.post-figure__zoom::after {
  content: "Ampliar";
  position: absolute;
  right: var(--space-2);
  bottom: var(--space-2);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-pill);
  background: var(--brand-black);
  color: #fff;
  font-size: var(--fs-small);
  opacity: 0.85;
  transition: opacity 0.2s;
}

.post-figure__zoom:hover::after,
.post-figure__zoom:focus-visible::after { opacity: 1; }

/* Lightbox */
.lightbox {
  width: 100vw;
  max-width: none;
  height: 100vh;
  max-height: none;
  margin: 0;
  padding: var(--space-6) var(--space-4);
  border: 0;
  background: transparent;
}

.lightbox::backdrop { background: rgb(0 0 0 / 0.85); }

.lightbox[open] {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
}

.lightbox__img {
  max-width: min(100%, 1600px);
  max-height: calc(100vh - 7rem);
  width: auto;
  height: auto;
  border-radius: var(--radius);
  background: #fff;
}

.lightbox__caption {
  color: #fff;
  font-size: var(--fs-small);
}

.lightbox__close {
  position: absolute;
  top: var(--space-3);
  right: var(--space-3);
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: var(--radius-round);
  background: #fff;
  color: var(--brand-black);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}

.lightbox__close:focus-visible { outline: 3px solid var(--brand-lime); outline-offset: 3px; }

/* "A visão da Brandema": bloco de opinião do Mateus */
.post-take {
  padding: var(--space-6);
  background: var(--color-surface);
  border-left: 4px solid var(--brand-lime);
  border-radius: 0 var(--radius) var(--radius) 0;
}

.post-take > * + * {
  margin-top: var(--space-4);
}

/* Box de destaque (opcional): título curto + lista numerada.
   Uso em _modelos/COMO-PUBLICAR.md. */
.post-highlight {
  margin-block: var(--space-7);
  margin-right: 12px; /* espaço para a sombra deslocada não encostar na borda */
  padding: var(--space-6);
  background: var(--color-surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow-offset-magenta);
}

.prose .post-highlight + * {
  margin-top: var(--space-7);
}

.post-highlight__title {
  margin: 0 0 var(--space-5);
  font-size: var(--fs-h5);
  font-style: italic;
  text-transform: uppercase;
  letter-spacing: -0.01em;
}

.prose .post-highlight__title {
  margin-top: 0;
  font-size: var(--fs-h5);
}

.prose .post-highlight ol {
  list-style: none;
  padding: 0;
  margin: 0;
  counter-reset: destaque;
}

.post-highlight li {
  counter-increment: destaque;
  display: grid;
  grid-template-columns: 2.25rem minmax(0, 1fr);
  gap: var(--space-3);
  align-items: baseline;
}

.prose .post-highlight li + li {
  margin-top: var(--space-4);
  padding-top: var(--space-4);
  border-top: var(--border);
}

.post-highlight li::before {
  content: counter(destaque, decimal-leading-zero);
  content: counter(destaque, decimal-leading-zero) / ""; /* o <ol> já anuncia a posição */
  font-family: var(--font-mono);
  font-size: var(--fs-h5);
  font-weight: var(--fw-medium);
  line-height: 1;
  color: var(--color-accent-text);
}

/* ---- Votação "Qual versão você preferiu?" (montada pelo news.js) ---- */
.voto-mount[hidden] {
  display: none;
}

.voto {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  margin-top: var(--space-8);
  padding: var(--space-6);
  background: var(--color-surface);
  border: 1.5px solid var(--brand-black);
  border-radius: var(--radius-lg);
}

.voto__titulo {
  margin: 0;
  font-size: var(--fs-h4);
  font-style: italic;
  text-transform: uppercase;
  letter-spacing: -0.01em;
}

.voto__aviso,
.voto__total,
.voto__escolha {
  margin: 0;
  font-family: var(--font-mono);
  font-size: var(--fs-small);
  color: var(--color-text-muted);
}

.voto__aviso[hidden] {
  display: none;
}

.voto__botoes {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}

.voto__btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  min-height: 44px;
  padding: 0.5rem 1.25rem;
  font-family: var(--font-mono);
  font-size: var(--fs-small);
  font-weight: var(--fw-medium);
  letter-spacing: var(--ls-caps);
  text-transform: uppercase;
  border: 1.5px solid var(--brand-black);
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition:
    transform var(--dur-fast) ease,
    opacity var(--dur-fast) ease;
}

.voto__btn svg {
  flex: none;
  width: 18px;
  height: 18px;
}

.voto__btn--humana {
  color: var(--brand-black);
  background: var(--brand-lime);
}

.voto__btn--ia {
  color: #fff;
  background: var(--brand-magenta);
}

.voto__btn[aria-disabled="false"]:hover {
  transform: translateY(-2px);
}

/* Antes de ler as duas versões e depois de votar */
.voto__btn[aria-disabled="true"],
.voto__btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* A versão escolhida fica em destaque depois do voto */
.voto__btn.is-votado {
  opacity: 1;
  box-shadow: 4px 4px 0 0 var(--brand-black);
}

.voto__resultado {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.voto__resultado:empty {
  display: none;
}

.voto__obrigado,
.voto__aguardando {
  margin: 0;
  font-weight: var(--fw-semibold);
}

.voto__barras {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.voto__linha {
  display: grid;
  grid-template-columns: 6.5rem minmax(0, 1fr) 3rem;
  align-items: center;
  gap: var(--space-3);
}

.voto__rotulo {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-mono);
  font-size: var(--fs-small);
  font-weight: var(--fw-medium);
  text-transform: uppercase;
  letter-spacing: var(--ls-caps);
}

.voto__rotulo svg {
  width: 16px;
  height: 16px;
}

.voto__trilho {
  height: 14px;
  overflow: hidden;
  background: var(--color-bg);
  border: 1.5px solid var(--brand-black);
  border-radius: var(--radius-pill);
}

.voto__barra {
  display: block;
  height: 100%;
  border-radius: var(--radius-pill);
  transition: width 0.6s var(--ease-out);
}

.voto__linha--humana .voto__barra { background: var(--brand-lime); }
.voto__linha--ia .voto__barra { background: var(--brand-magenta); }

.voto__pct {
  font-family: var(--font-mono);
  font-weight: var(--fw-semibold);
  text-align: right;
}

@media (prefers-reduced-motion: reduce) {
  .voto__btn,
  .voto__barra {
    transition: none;
  }
}

/* Fonte e compartilhar */
.post-footer {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
  margin-top: var(--space-7);
  padding-top: var(--space-5);
  border-top: var(--border);
}

/* Assinatura no fim da matéria (escondida enquanto a versão da IA está ativa) */
.post-byline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3) var(--space-5);
}

.post-byline[hidden] {
  display: none;
}

.post-byline__author {
  font-size: var(--fs-h5);
}

.post-byline__author strong {
  font-weight: var(--fw-semibold);
}

.human-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: 0.4rem 0.9rem;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  font-weight: var(--fw-medium);
  letter-spacing: var(--ls-caps);
  text-transform: uppercase;
  color: var(--brand-black);
  background: var(--brand-lime);
  border: 1.5px solid var(--brand-black);
  border-radius: var(--radius-pill);
}

.human-badge svg {
  flex: none;
  width: 16px;
  height: 16px;
}

.post-source {
  font-size: var(--fs-small);
  color: var(--color-text-muted);
}

.post-source a {
  color: var(--color-text);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.share {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
}

.share__label {
  margin-right: var(--space-2);
  font-family: var(--font-mono);
  font-size: var(--fs-small);
  color: var(--color-text-faint);
}

.share .pill {
  cursor: pointer;
  background: none;
  font: inherit;
  font-size: var(--fs-small);
}

/* ---------------------------------------------------------------------------
   6. Barra lateral
   --------------------------------------------------------------------------- */
.post-aside {
  display: flex;
  flex-direction: column;
  gap: var(--space-7);
}

@media (min-width: 1024px) {
  .post-aside {
    position: sticky;
    top: calc(var(--header-h) + var(--space-5));
    /* Com 4 matérias + 7 categorias a lateral passa de ~890px: em telas baixas
       ela ganha rolagem própria em vez de esconder o fim até acabar o texto. */
    max-height: calc(100vh - var(--header-h) - var(--space-5) * 2);
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    /* folga para o anel de foco não ser cortado pelo overflow */
    padding: 4px;
    margin: -4px;
  }
}

.post-aside__title {
  margin-bottom: var(--space-4);
  font-family: var(--font-mono);
  font-size: var(--fs-small);
  font-weight: var(--fw-medium);
  letter-spacing: var(--ls-caps);
  text-transform: uppercase;
  color: var(--color-text-faint);
}

.aside-list {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  border-top: var(--border);
}

.aside-list li {
  border-bottom: var(--border);
}

.aside-list a {
  display: flex;
  justify-content: space-between;
  gap: var(--space-3);
  padding-block: var(--space-3);
  transition: color var(--dur-fast) ease;
}

.aside-list a:hover {
  color: var(--color-accent-text);
}

.aside-list small {
  display: block;
  margin-top: var(--space-1);
  font-family: var(--font-mono);
  color: var(--color-text-faint);
}
