/* ============================================================
   Usereviews — blog styles (article + index)
   Pairs with styles.css (vars, nav, footer, buttons, modal).
   ============================================================ */

/* ===== shared article main ===== */
.blog-main { width: min(1440px, 100% - 16vw); margin: 0 auto; }

/* ===== ARTICLE HEADER ===== */
.article-meta-row {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--mono); font-size: 11px;
  color: var(--text-faint); letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-top: 56px;
}
.article-meta-row .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--text-faint); }
.article-tag {
  color: var(--text); border: 1px solid var(--border-strong);
  padding: 4px 10px; border-radius: var(--radius);
}
.article-title {
  font-family: var(--sans);
  font-size: clamp(34px, 4.5vw, 56px);
  line-height: 1.05; letter-spacing: -0.03em;
  font-weight: 500;
  margin: 24px 0 20px;
  max-width: 1000px;
  text-wrap: balance;
}
.article-deck {
  font-size: 19px; color: var(--text-dim);
  line-height: 1.5; max-width: 760px;
  margin-bottom: 40px;
}
.article-hero-image {
  margin: 0 0 64px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg-soft);
}
.article-hero-image img { display: block; width: 100%; height: auto; }

/* ===== two-column body + sticky TOC ===== */
.article-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 240px;
  gap: 72px;
  align-items: start;
  max-width: 1080px;
  margin-inline: auto;
}
.article-toc {
  position: sticky; top: 80px;
  font-family: var(--mono); font-size: 11px;
  color: var(--text-faint); letter-spacing: 0.05em;
  max-height: calc(100vh - 120px); overflow-y: auto;
}
.article-toc h6 {
  text-transform: uppercase; font-size: 10px;
  color: var(--text-faint); margin-bottom: 14px;
  font-weight: 500; letter-spacing: 0.15em;
}
.article-toc ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.article-toc a {
  color: var(--text-dim);
  transition: color 0.15s, border-color 0.15s;
  display: block; line-height: 1.45;
  padding: 4px 0 4px 12px; margin-left: -14px;
  border-left: 2px solid transparent;
}
.article-toc a:hover { color: var(--text); border-left-color: var(--text); }
.article-toc a.toc-active { color: var(--text); border-left-color: var(--text); font-weight: 500; }

/* ===== PROSE ===== */
.prose { max-width: 760px; }
.prose p {
  font-family: var(--sans);
  font-size: 16px; line-height: 1.6;
  color: var(--text-read);
  margin: 0 0 26px;
}
.prose p:empty { display: none; }
.prose p strong { font-weight: 500; }
.prose a {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--border-strong);
  text-decoration-thickness: 1px;
  transition: text-decoration-color 0.15s;
}
.prose a:hover { text-decoration-color: var(--text); }
.prose em { font-style: italic; }

.prose h2 {
  font-family: var(--sans);
  font-size: 30px; line-height: 1.15;
  letter-spacing: -0.02em; font-weight: 500;
  margin: 32px 0 20px;
  padding-top: 48px;
  border-top: 1px solid var(--border);
  text-wrap: balance;
  scroll-margin-top: 90px;
}
.prose > h2:first-child { border-top: none; padding-top: 0; margin-top: 0; }
.prose h3 {
  font-family: var(--sans);
  font-size: 21px; line-height: 1.25;
  letter-spacing: -0.01em; font-weight: 500;
  margin: 40px 0 14px;
  text-wrap: balance;
  scroll-margin-top: 90px;
}
.prose h4 {
  font-family: var(--sans);
  font-size: 17px; font-weight: 500;
  margin: 28px 0 10px;
}

.prose ul, .prose ol { margin: 0 0 26px; padding: 0; list-style: none; }
.prose ul li, .prose ol li {
  position: relative;
  padding: 0 0 8px 22px;
  font-size: 16px; line-height: 1.6;
  color: var(--text);
}
.prose ul li::before {
  content: '';
  position: absolute;
  left: 4px; top: 12px;
  width: 6px; height: 6px;
  background: var(--text-dim);
  border-radius: 1px;
}
.prose ol { counter-reset: li; }
.prose ol li::before {
  counter-increment: li;
  content: counter(li) ".";
  position: absolute; left: 0; top: 0;
  font-family: var(--mono); font-size: 13px;
  color: var(--text-faint);
}
.prose li strong { font-weight: 500; }
.prose blockquote {
  margin: 0 0 26px; padding: 4px 0 4px 22px;
  border-left: 2px solid var(--border-strong);
  color: var(--text-dim); font-size: 18px; line-height: 1.55;
}
.prose hr { border: none; border-top: 1px solid var(--border); margin: 40px 0; }

/* figures / inline images from the CMS */
.prose figure {
  margin: 32px 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg-soft);
}
.prose figure img { display: block; width: 100%; height: auto; }
.prose figure figcaption {
  font-family: var(--mono); font-size: 11px;
  color: var(--text-faint); padding: 10px 14px;
  border-top: 1px solid var(--border);
  background: var(--bg-elev);
}
.prose figure.w-richtext-align-fullwidth { margin-left: 0; margin-right: 0; }
.prose img { max-width: 100%; height: auto; border-radius: var(--radius); }

/* ===== TABLES ===== */
.prose-table {
  margin: 24px 0 36px;
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-elev);
}
.prose-table table { width: 100%; border-collapse: collapse; font-size: 14px; }
.prose-table th[border], .prose-table table[border] td { border: none; }
.prose-table thead th {
  text-align: left;
  font-family: var(--mono);
  font-size: 10px; font-weight: 500;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--text-faint);
  padding: 14px 16px;
  background: var(--bg-soft);
  border-bottom: 1px solid var(--border);
  vertical-align: bottom;
}
.prose-table tbody td {
  padding: 14px 16px; line-height: 1.5;
  color: var(--text); vertical-align: top;
  border-bottom: 1px solid var(--border);
}
.prose-table tbody tr:last-child td { border-bottom: none; }
.prose-table tbody tr:nth-child(even) td { background: var(--bg-soft); }
.prose-table tbody td:first-child { font-weight: 500; color: var(--text); }
.prose-table tbody td strong { font-weight: 500; }
.prose-table tbody td a, .prose-table thead th a { color: var(--text); text-decoration: underline; text-underline-offset: 2px; text-decoration-color: var(--border-strong); }
/* p tags inside cells (CMS output) */
.prose-table td p, .prose-table th p {
  margin: 0;
  font-size: inherit;
  line-height: 1.45;
}

.prose-table .badge {
  display: inline-block; font-family: var(--mono); font-size: 10px;
  padding: 3px 8px; border-radius: 4px; background: var(--bg-soft);
  border: 1px solid var(--border); color: var(--text-dim); white-space: nowrap;
}

/* ===== CTA ===== */
.article-cta {
  margin: 80px 0 0 max(0px, calc(50% - 540px)); max-width: 760px;
  padding: 48px; background: #0a0a0a; color: #fff;
  border-radius: var(--radius);
}
.article-cta h3 {
  font-size: 28px; line-height: 1.15; letter-spacing: -0.02em;
  font-weight: 500; margin-bottom: 12px; text-wrap: balance;
}
.article-cta p { color: #a8acb4; font-size: 16px; line-height: 1.5; margin-bottom: 24px; max-width: 520px; }
.article-cta .cta-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 20px; background: #fff; color: #0a0a0a !important;
  border-radius: var(--radius); font-size: 14px; font-weight: 500;
  transition: background 0.15s;
}
.article-cta .cta-btn:hover { background: #f1f2f5; }

/* ===== BLOG INDEX ===== */
.blog-head { padding: 72px 0 40px; border-bottom: 1px solid var(--border); margin-bottom: 48px; }
.blog-eyebrow {
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--text-faint); margin-bottom: 18px;
}
.blog-title {
  font-size: clamp(34px, 4.5vw, 52px); line-height: 1.05;
  letter-spacing: -0.03em; font-weight: 500; max-width: 760px; text-wrap: balance;
}
.blog-lede { font-size: 18px; color: var(--text-dim); max-width: 620px; margin-top: 18px; line-height: 1.55; }

.blog-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.blog-card {
  display: flex; flex-direction: column;
  background: var(--bg-elev);
  border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden;
  transition: background 0.15s, border-color 0.15s;
}
.blog-card:hover { background: var(--bg-soft); border-color: var(--border-strong); }
.blog-card-thumb {
  aspect-ratio: 16 / 9; overflow: hidden;
  background: var(--bg-soft); border-bottom: 1px solid var(--border);
}
.blog-card-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.blog-card-body { padding: 24px; display: flex; flex-direction: column; gap: 12px; flex: 1; }
.blog-card-meta {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--mono); font-size: 10px; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--text-faint);
}
.blog-card-meta .tag { color: var(--text); border: 1px solid var(--border-strong); padding: 3px 8px; border-radius: 4px; }
.blog-card-meta .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--text-faint); }
.blog-card h3 {
  font-size: 19px; line-height: 1.25; letter-spacing: -0.01em;
  font-weight: 500; color: var(--text); text-wrap: balance;
}
.blog-card p { font-size: 14px; color: var(--text-dim); line-height: 1.5; }
.blog-card .read-more {
  margin-top: auto; font-family: var(--mono); font-size: 11px;
  letter-spacing: 0.05em; color: var(--text); padding-top: 6px;
}

/* featured (first) card spans full width with side-by-side layout */
.blog-card.featured { grid-column: 1 / -1; flex-direction: row; }
.blog-card.featured .blog-card-thumb {
  aspect-ratio: auto; width: 52%; border-bottom: none; border-right: 1px solid var(--border);
}
.blog-card.featured .blog-card-body { padding: 40px; gap: 16px; justify-content: center; }
.blog-card.featured h3 { font-size: 28px; line-height: 1.15; font-weight: 500; }
.blog-card.featured p { font-size: 16px; max-width: 460px; }

/* ===== RESPONSIVE ===== */
@media (max-width: 960px) {
  .article-shell { grid-template-columns: 1fr; gap: 0; }
  .article-toc { display: none; }
  .blog-main { width: auto; padding: 0 20px; }
  .article-cta { padding: 32px 24px; }
  .article-meta-row { margin-top: 32px; }
  .blog-grid { grid-template-columns: repeat(2, 1fr); }
  .blog-card.featured { flex-direction: column; }
  .blog-card.featured .blog-card-thumb { width: 100%; border-right: none; border-bottom: 1px solid var(--border); aspect-ratio: 16/9; }
}
@media (max-width: 620px) {
  .blog-grid { grid-template-columns: 1fr; }
}

/* ===== LOAD MORE ===== */
.blog-loadmore {
  display: flex;
  justify-content: center;
  padding-top: 56px;
}
.blog-loadmore button {
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 500;
  color: var(--text-dim);
  background: transparent;
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  padding: 13px 28px;
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s, background 0.15s;
}
.blog-loadmore button:hover {
  color: var(--text);
  border-color: var(--text);
  background: rgba(0,0,0,0.03);
}
