/* Blog do CrewBot. Usa as variáveis e o cabeçalho de site.css; páginas geradas por scripts/gerar-blog.mjs. */

.blog-hero {
  position: relative;
  padding: 72px 0 28px;
}

.blog-hero::before {
  content: "";
  position: absolute;
  inset: -80px 0 auto;
  height: 420px;
  background:
    radial-gradient(520px 260px at 22% 30%, rgba(111, 125, 255, 0.2), transparent 70%),
    radial-gradient(420px 220px at 78% 10%, rgba(47, 227, 207, 0.12), transparent 70%);
  pointer-events: none;
  z-index: -1;
}

.blog-hero h1 {
  margin: 14px 0 0;
  font-size: clamp(40px, 6vw, 72px);
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.045em;
}

.blog-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 30px 0 0;
  padding: 0;
  list-style: none;
}

.blog-tabs a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 15px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  color: var(--muted);
  font-size: 14.5px;
  font-weight: 600;
  text-decoration: none;
  transition:
    color 0.2s,
    border-color 0.2s,
    background 0.2s;
}

.blog-tabs a:hover {
  color: var(--text);
}

.blog-tabs a[aria-current="page"] {
  color: var(--ink);
  background: var(--text);
  border-color: var(--text);
}

.blog-tabs small {
  font-size: 12px;
  opacity: 0.65;
}

/* ---------- Cartões ---------- */
.post-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin: 34px 0 0;
  padding: 0;
  list-style: none;
}

.post-grid > li {
  min-width: 0;
}

.post-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(244, 246, 251, 0.02);
  overflow: hidden;
  text-decoration: none;
  transition:
    transform 0.25s ease,
    border-color 0.25s ease,
    background 0.25s ease;
}

.post-card:hover {
  transform: translateY(-4px);
  border-color: var(--line-strong);
  background: rgba(244, 246, 251, 0.04);
}

.post-card img {
  width: 100%;
  height: auto;
  aspect-ratio: 1200 / 630;
  object-fit: cover;
  border-bottom: 1px solid var(--line);
  background: var(--ink-2);
}

.post-card-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
  padding: 20px 22px 22px;
}

.post-card h2,
.post-card h3 {
  margin: 0;
  max-width: none;
  font-size: 20px;
  line-height: 1.22;
  font-weight: 750;
  letter-spacing: -0.02em;
}

.post-card p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.5;
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  color: var(--dim);
  font-size: 13px;
  font-weight: 550;
}

.post-cat {
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.02em;
  color: var(--aqua);
  border: 1px solid rgba(47, 227, 207, 0.32);
  background: rgba(47, 227, 207, 0.07);
}

.post-cat.cat-comparativos {
  color: var(--violet);
  border-color: rgba(154, 140, 255, 0.36);
  background: rgba(154, 140, 255, 0.08);
}

.post-card .post-meta {
  margin-top: auto;
  padding-top: 6px;
}

/* Destaque: o post mais recente, maior. */
.post-feature {
  grid-column: 1 / -1;
}

.post-feature .post-card {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  align-items: center;
}

.post-feature .post-card img {
  height: auto;
  border-bottom: 0;
}

.post-feature .post-card-body {
  justify-content: center;
  padding: 34px;
}

.post-feature .post-card h2 {
  font-size: clamp(22px, 2.3vw, 30px);
  letter-spacing: -0.035em;
}

.post-feature .post-card p {
  font-size: 16.5px;
}

.post-feature .post-meta {
  margin-top: 8px;
}

.blog-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin: 72px 0 0;
}

.blog-section-head h2 {
  margin: 0;
  font-size: clamp(26px, 3vw, 36px);
  letter-spacing: -0.035em;
}

.blog-section-head a {
  color: var(--aqua);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}

.blog-empty {
  color: var(--muted);
}

/* ---------- Post ---------- */
.article {
  max-width: 820px;
  margin: 0 auto;
  padding: 56px 0 10px;
}

.crumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 22px;
  color: var(--dim);
  font-size: 14px;
}

.crumbs a {
  color: var(--muted);
  text-decoration: none;
}

.crumbs a:hover {
  color: var(--text);
}

.article h1 {
  margin: 14px 0 0;
  font-size: clamp(34px, 4.8vw, 54px);
  line-height: 1.05;
  font-weight: 800;
  letter-spacing: -0.04em;
}

.article .lead-text {
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 19.5px;
  line-height: 1.5;
}

.article .post-meta {
  margin-top: 22px;
}

.article-cover {
  margin: 34px 0 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.article-cover img {
  width: 100%;
  height: auto;
}

.prose {
  font-size: 17.5px;
  line-height: 1.72;
  color: rgba(244, 246, 251, 0.86);
}

.prose h2 {
  margin: 52px 0 0;
  max-width: none;
  font-size: clamp(26px, 3vw, 32px);
  line-height: 1.15;
  font-weight: 780;
  letter-spacing: -0.03em;
  color: var(--text);
  scroll-margin-top: 90px;
}

.prose h3 {
  margin: 32px 0 0;
  font-size: 20px;
  line-height: 1.3;
  font-weight: 720;
  letter-spacing: -0.015em;
  color: var(--text);
}

.prose p,
.prose ul,
.prose ol,
.prose blockquote,
.prose table {
  margin: 16px 0 0;
}

.prose ul,
.prose ol {
  padding-left: 22px;
}

.prose li {
  margin: 6px 0;
}

.prose li::marker {
  color: var(--aqua);
}

.prose strong {
  color: var(--text);
  font-weight: 650;
}

.prose a {
  color: var(--aqua);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.prose code {
  padding: 2px 6px;
  border-radius: 6px;
  background: rgba(244, 246, 251, 0.07);
  font: 0.88em ui-monospace, "SF Mono", Menlo, monospace;
}

.prose blockquote {
  padding: 16px 20px;
  border-left: 3px solid var(--violet);
  border-radius: 0 14px 14px 0;
  background: rgba(154, 140, 255, 0.06);
  color: var(--muted);
}

.prose blockquote p:first-child {
  margin-top: 0;
}

.prose hr {
  margin: 44px 0;
  border: 0;
  border-top: 1px solid var(--line);
}

.table-scroll {
  margin: 20px 0 0;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 16px;
}

.prose table {
  width: 100%;
  margin: 0;
  border-collapse: collapse;
  font-size: 15px;
  line-height: 1.5;
}

.prose th,
.prose td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.prose th {
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: rgba(244, 246, 251, 0.035);
}

.prose tr:last-child td {
  border-bottom: 0;
}

.prose td:first-child {
  color: var(--text);
  font-weight: 600;
  white-space: nowrap;
}

.prose .win {
  display: inline-block;
  margin-right: 6px;
  padding: 1px 8px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--aqua);
  background: rgba(47, 227, 207, 0.1);
  border: 1px solid rgba(47, 227, 207, 0.3);
}

/* Resposta curta e cartões "Escolha X se". */
.answer {
  margin: 28px 0 0;
  padding: 22px 24px;
  border-radius: var(--radius);
  border: 1px solid rgba(47, 227, 207, 0.25);
  background: linear-gradient(180deg, rgba(47, 227, 207, 0.06), rgba(47, 227, 207, 0.015));
}

.answer > :first-child {
  margin-top: 0;
}

.answer b.label {
  display: block;
  margin-bottom: 6px;
  color: var(--aqua);
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.choose {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 22px 0 0;
}

.choose > div {
  min-width: 0;
  padding: 22px 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(244, 246, 251, 0.02);
}

.choose > div.us {
  border-color: rgba(154, 140, 255, 0.35);
  background: linear-gradient(180deg, rgba(154, 140, 255, 0.08), rgba(154, 140, 255, 0.015));
}

.choose h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  font-size: 18px;
}

.choose h3 img {
  width: 30px;
  height: 30px;
  border-radius: 8px;
}

.choose ul {
  margin: 12px 0 0;
  padding-left: 20px;
  font-size: 15.5px;
}

.vs-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 22px;
  margin: 26px 0 0;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(244, 246, 251, 0.02);
}

.vs-strip figure {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: 14.5px;
  font-weight: 650;
}

.vs-strip img {
  width: 64px;
  height: 64px;
  border-radius: 16px;
}

.vs-strip span {
  color: var(--dim);
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
}

.sources {
  margin: 56px 0 0;
  padding: 24px 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(244, 246, 251, 0.02);
}

.sources h2 {
  margin: 0;
  font-size: 20px;
  letter-spacing: -0.02em;
}

.sources p {
  margin: 8px 0 0;
  color: var(--dim);
  font-size: 14px;
}

.sources ol {
  margin: 14px 0 0;
  padding-left: 22px;
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.6;
}

.sources li {
  margin: 4px 0;
  overflow-wrap: anywhere;
}

.sources a {
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: rgba(244, 246, 251, 0.3);
  text-underline-offset: 3px;
}

.post-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin: 40px 0 0;
  padding: 28px 30px;
  border-radius: var(--radius);
  border: 1px solid rgba(154, 140, 255, 0.3);
  background:
    radial-gradient(360px 160px at 90% 0%, rgba(47, 227, 207, 0.14), transparent 70%),
    linear-gradient(180deg, rgba(154, 140, 255, 0.1), rgba(154, 140, 255, 0.02));
}

.post-cta img {
  flex: none;
  width: 72px;
  height: 72px;
}

.post-cta div {
  flex: 1;
}

.post-cta h2 {
  margin: 0;
  font-size: 22px;
  letter-spacing: -0.025em;
}

.post-cta p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 15.5px;
}

.related {
  margin: 20px 0 0;
}

@media (max-width: 960px) {
  .post-grid {
    grid-template-columns: 1fr 1fr;
  }

  .post-feature .post-card {
    grid-template-columns: 1fr;
  }

  .post-feature .post-card img {
    border-bottom: 1px solid var(--line);
  }
}

@media (max-width: 640px) {
  .post-grid,
  .choose {
    grid-template-columns: 1fr;
  }

  .post-feature .post-card-body {
    padding: 22px;
  }

  .post-cta {
    flex-direction: column;
    align-items: flex-start;
  }

  .prose td:first-child {
    white-space: normal;
  }

  .vs-strip {
    gap: 14px;
  }
}
