/* Resenhas de artigos (/noticias/, /news/).
   Complementa instrument.css — hero, cards, callouts e tabelas vêm de lá. */

.post-meta {
  color: rgba(255,255,255,0.55); font-size: 0.82rem;
  margin: -0.2rem 0 0.9rem; letter-spacing: 0.01em;
}
.post-tags { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 1.2rem; }
.post-tag {
  background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.14);
  color: rgba(255,255,255,0.75); border-radius: 999px;
  padding: 0.15rem 0.7rem; font-size: 0.74rem; font-weight: 600;
}

/* Ficha do artigo resenhado — o que o leitor precisa para achar o original */
.post-source {
  background: #fff; border: 1px solid var(--border); border-left: 3px solid var(--orange);
  border-radius: 12px; padding: 1.1rem 1.3rem; margin-bottom: 1.5rem;
}
.post-source .ps-label {
  font-size: 0.7rem; font-weight: 800; letter-spacing: 0.09em;
  text-transform: uppercase; color: var(--orange); margin-bottom: 0.45rem;
}
.post-source .ps-title {
  font-size: 0.92rem; font-weight: 700; color: var(--navy);
  line-height: 1.5; margin-bottom: 0.4rem;
}
.post-source .ps-meta {
  font-size: 0.8rem; color: var(--muted); line-height: 1.6; margin-bottom: 0.4rem;
}
.post-source .ps-links {
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 0.9rem;
  margin: 0.6rem 0 0; font-size: 0.82rem;
}
.post-source .ps-links a { color: var(--accent); text-decoration: none; font-weight: 600; }
.post-source .ps-links a:hover { text-decoration: underline; }
.post-source .ps-doi {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.74rem; color: var(--muted);
  background: var(--light); border-radius: 5px; padding: 0.12rem 0.45rem;
}

/* Nota PEDro. A origem anda sempre colada no número, de propósito. */
.post-source .ps-pedro {
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem 0.6rem;
  margin: 0.7rem 0 0; padding-top: 0.7rem; border-top: 1px solid var(--border);
}
.pedro-badge {
  background: var(--navy); color: #fff; border-radius: 6px;
  padding: 0.18rem 0.55rem; font-size: 0.78rem; font-weight: 800;
  text-decoration: none; white-space: nowrap;
}
.pedro-badge:hover { background: var(--accent); color: #fff; }
.pedro-origin {
  font-size: 0.74rem; font-weight: 700; color: #92400e;
  background: #FFFBEB; border: 1px solid #FDE68A; border-radius: 999px;
  padding: 0.1rem 0.55rem;
}
.pedro-origin.is-official { color: #15803d; background: #dcfce7; border-color: #bbf7d0; }
.pedro-src { font-size: 0.78rem; color: var(--accent); text-decoration: none; font-weight: 600; }
.pedro-src:hover { text-decoration: underline; }

.pedro-detail { margin-top: 0.6rem; }
.pedro-detail summary {
  cursor: pointer; font-size: 0.78rem; font-weight: 600; color: var(--muted);
  list-style: none; display: inline-flex; align-items: center; gap: 0.3rem;
}
.pedro-detail summary::-webkit-details-marker { display: none; }
.pedro-detail summary::before { content: '▸'; font-size: 0.7rem; }
.pedro-detail[open] summary::before { content: '▾'; }
.pedro-detail summary:hover { color: var(--navy); }
.pedro-detail .inst-table { font-size: 0.79rem; }
.pedro-detail tr.not-scored td { color: var(--muted); background: #fafafa; }
.pedro-nc { font-size: 0.68rem; color: var(--muted); font-style: italic; }
.pedro-mark { text-align: center; font-weight: 800; color: #15803d; }
.pedro-note {
  font-size: 0.78rem; color: var(--muted); line-height: 1.65;
  margin: 0.5rem 0 0; padding-left: 0.6rem; border-left: 2px solid var(--border);
}

/* Corpo da resenha */
.post-body h2 {
  font-size: 1.05rem; font-weight: 700; color: var(--navy);
  margin: 1.9rem 0 0.7rem; padding-bottom: 0.4rem; border-bottom: 1px solid var(--border);
}
.post-body h2:first-child { margin-top: 0; }
.post-body h3 { font-size: 0.94rem; font-weight: 700; color: #1e293b; margin: 1.3rem 0 0.5rem; }
.post-body p, .post-body li { font-size: 0.92rem; color: #374151; line-height: 1.8; }
.post-body p { margin-bottom: 0.9rem; }
.post-body ul, .post-body ol { margin-bottom: 1rem; padding-left: 1.3rem; }
.post-body li { margin-bottom: 0.35rem; }
.post-body a { color: var(--accent); text-decoration: none; }
.post-body a:hover { text-decoration: underline; }
.post-body strong { color: #1e293b; font-weight: 700; }
.post-body code {
  font-size: 0.85em; background: var(--light); color: var(--navy);
  border-radius: 5px; padding: 0.1rem 0.35rem;
}
.post-body blockquote {
  border-left: 3px solid var(--border); margin: 1.1rem 0; padding: 0.2rem 0 0.2rem 1.1rem;
  color: var(--muted); font-style: italic; font-size: 0.9rem; line-height: 1.75;
}
.post-body hr { border: none; border-top: 1px solid var(--border); margin: 2rem 0; }

/* Termo do glossário no meio do texto: visível sem gritar */
.post-body a.g-term {
  color: inherit; text-decoration: none;
  border-bottom: 1px dashed var(--accent);
  cursor: help;
}
.post-body a.g-term:hover { color: var(--accent); border-bottom-style: solid; text-decoration: none; }

/* Camada técnica: quem só quer a leitura clínica pode pular a caixa inteira */
.post-tec {
  background: #F8FAFC; border: 1px solid #E2E8F0; border-radius: 10px;
  padding: 0.95rem 1.2rem; margin: 1.3rem 0;
}
.post-tec .tec-label {
  font-size: 0.68rem; font-weight: 800; letter-spacing: 0.09em;
  text-transform: uppercase; color: var(--muted); margin-bottom: 0.5rem;
}
.post-tec p, .post-tec li { font-size: 0.85rem; color: #475569; line-height: 1.7; }
.post-tec p:last-child { margin-bottom: 0; }
.post-tec .inst-table { font-size: 0.8rem; }

/* Barra lateral da resenha: acompanha a rolagem, leva ao glossário */
.post-layout { display: flex; gap: 1.6rem; align-items: flex-start; }
.post-main { flex: 1 1 auto; min-width: 0; }
.post-rail { flex: 0 0 150px; position: sticky; top: 90px; }
.rail-link {
  display: block; background: #fff; border: 1px solid var(--border);
  border-left: 3px solid var(--orange); border-radius: 10px;
  padding: 0.7rem 0.9rem; text-decoration: none;
  color: var(--navy); font-size: 0.86rem; font-weight: 700;
  transition: border-color 0.15s, background 0.15s;
}
.rail-link:hover { background: #EFF6FF; border-color: var(--navy); border-left-color: var(--orange); color: var(--navy); }

/* Abaixo de 992px a barra vira um link no topo do texto */
@media (max-width: 991px) {
  .post-layout { display: block; }
  .post-rail { position: static; margin-bottom: 1rem; }
  .rail-link { display: inline-block; padding: 0.5rem 0.9rem; font-size: 0.82rem; }
}

/* Glossário */
.g-entry { padding: 0.9rem 0; border-bottom: 1px solid #f1f5f9; scroll-margin-top: 90px; }
.g-entry:last-child { border-bottom: none; padding-bottom: 0; }
.g-entry h3 { font-size: 0.92rem; font-weight: 700; color: var(--navy); margin: 0 0 0.35rem; }
.g-entry p { font-size: 0.88rem; color: #374151; line-height: 1.75; margin: 0; }
.g-entry .g-link { margin-top: 0.4rem; }
.g-entry .g-link a { font-size: 0.82rem; color: var(--accent); text-decoration: none; font-weight: 600; }
.g-entry .g-link a:hover { text-decoration: underline; }
.g-entry:target { background: #EFF6FF; box-shadow: 0 0 0 0.6rem #EFF6FF; border-radius: 3px; }
.g-entry:target h3 { color: var(--accent); }

/* Índice */
.post-list { display: flex; flex-direction: column; gap: 1rem; }
.post-item {
  display: block; background: #fff; border: 1px solid var(--border);
  border-radius: 12px; padding: 1.2rem 1.4rem; text-decoration: none;
  transition: border-color 0.15s, transform 0.15s;
}
.post-item:hover { border-color: var(--navy); transform: translateY(-2px); }
.post-item time {
  font-size: 0.74rem; font-weight: 700; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--orange);
}
.post-item h2 {
  font-size: 1.05rem; font-weight: 700; color: var(--navy);
  line-height: 1.45; margin: 0.4rem 0 0.5rem;
}
.post-item p { font-size: 0.87rem; color: #475569; line-height: 1.7; margin-bottom: 0.7rem; }
.post-more { font-size: 0.82rem; font-weight: 700; color: var(--accent); }
.post-empty { color: var(--muted); font-size: 0.9rem; }

@media (max-width: 767px) {
  .post-source { padding: 0.95rem 1rem; }
  .post-item { padding: 1rem 1.1rem; }
}

/* Selo de tipo no índice. Só a resenha leva: marcar os dois vira ruído. */
.post-kind {
  display: inline-block; margin-left: 0.6rem;
  background: var(--border); color: var(--navy);
  border-radius: 999px; padding: 0.08rem 0.5rem;
  font-size: 0.68rem; font-weight: 800; letter-spacing: 0.04em;
  text-transform: uppercase; vertical-align: 0.1em;
}
