/* ============================================
   article.css — dark editorial article pages
   Loaded after style.css. Inherits dark tokens.
   ============================================ */

/* ---------- Layout: sidebar + article ---------- */
.article-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 32px;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 28px 80px;
}

.article-sidebar {
  padding-top: 60px;
  border-right: 0.5px solid var(--border-subtle);
  padding-right: 16px;
}

.sidebar-sticky {
  position: sticky;
  top: 80px;
}

.toc-heading {
  font-size: 10.5px;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.toc {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.toc a {
  font-size: 12.5px;
  color: #7dd3fc;
  padding: 6px 0 6px 12px;
  border-left: 1.5px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
  cursor: pointer;
  text-decoration: none;
}

.toc a:hover {
  color: #bae6fd;
}

.toc a.active {
  color: var(--accent);
  border-left-color: var(--accent);
}

.toc a.sub {
  padding-left: 24px;
  font-size: 11.5px;
  color: #5fb8e6;
}

.toc a.sub.active {
  color: var(--accent);
  border-left-color: var(--accent);
}

.sidebar-cta {
  background: var(--accent-soft-2);
  border: 0.5px solid var(--accent-border);
  border-radius: var(--radius-md);
  padding: 14px;
  margin-top: 24px;
}

.sidebar-cta-label {
  font-size: 10px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.sidebar-cta-text {
  font-size: 12px;
  color: var(--text-soft);
  line-height: 1.55;
  margin-bottom: 10px;
}

.sidebar-cta-link {
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
}

.sidebar-cta-link:hover {
  text-decoration: underline;
}

/* ---------- Article ---------- */
.article {
  padding: 50px 0 0;
  max-width: 720px;
}

/* Breadcrumbs */
.breadcrumbs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 22px;
  font-size: 11.5px;
}

.breadcrumbs a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s ease;
}

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

.breadcrumb-sep {
  color: var(--text-dim);
}

.breadcrumb-current {
  color: var(--text-soft);
}

/* Article header */
.article-eyebrow {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.article-title {
  font-size: clamp(30px, 4vw, 42px);
  line-height: 1.1;
  color: var(--text);
  letter-spacing: -0.025em;
  margin-bottom: 18px;
  font-weight: 700;
}

.article-title .accent {
  color: var(--accent);
}

.article-lede {
  font-size: clamp(16px, 1.8vw, 18px);
  line-height: 1.55;
  color: var(--text-soft);
  margin-bottom: 24px;
}

.article-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  padding: 14px 0;
  border-top: 0.5px solid var(--border-subtle);
  border-bottom: 0.5px solid var(--border-subtle);
  margin-bottom: 36px;
  font-size: 12px;
  color: var(--text-soft);
}

.author {
  display: flex;
  align-items: center;
  gap: 8px;
}

.author-avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--bg-elevated-2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  letter-spacing: -0.02em;
  font-weight: 600;
  color: var(--accent);
}

.meta-sep {
  color: var(--text-dim);
}

/* Quick answer callout */
.quick-answer {
  background: linear-gradient(180deg, var(--accent-soft), var(--accent-soft-2));
  border: 0.5px solid var(--accent-border);
  border-radius: var(--radius-lg);
  padding: 20px 22px;
  margin-bottom: 36px;
}

.quick-answer-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 10.5px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 10px;
}

.quick-answer-label::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.15);
}

.quick-answer p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--text);
  margin: 0;
}

.quick-answer p + p {
  margin-top: 10px;
}

/* Article body typography */
.article-body {
  font-size: 16px;
  line-height: 1.75;
  color: #d4cfc1;
}

.article-body p {
  margin-bottom: 1.2em;
}

.article-body p strong,
.article-body p b {
  color: var(--text);
  font-weight: 600;
}

.article-body h2 {
  font-size: 24px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.015em;
  line-height: 1.2;
  margin-top: 2.2em;
  margin-bottom: 0.6em;
  scroll-margin-top: 80px;
}

.article-body h3 {
  font-size: 18px;
  font-weight: 600;
  color: var(--text);
  margin-top: 1.6em;
  margin-bottom: 0.4em;
  scroll-margin-top: 80px;
}

.article-body a {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px dashed var(--accent-border);
  transition: border-color 0.15s ease;
}

.article-body a:hover {
  border-bottom-color: var(--accent);
}

.article-body ul,
.article-body ol {
  margin: 0 0 1.4em 0;
  padding-left: 1.4em;
}

.article-body li {
  margin-bottom: 0.5em;
  line-height: 1.65;
}

.article-body li::marker {
  color: var(--accent);
}

/* Product card inside article */
.product-card {
  background: var(--bg-elevated);
  border: 0.5px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin: 24px 0 28px;
}

.product-header {
  padding: 12px 22px;
  border-bottom: 0.5px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.02);
}

.product-header.is-top {
  background: var(--accent-soft);
  border-bottom-color: var(--accent-border);
}

.product-rank {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.is-top .product-rank {
  color: var(--accent);
}

.product-score {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  font-feature-settings: 'tnum';
}

.product-score-max {
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 500;
}

.product-body {
  padding: 22px;
}

.product-name {
  font-size: 20px !important;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 4px !important;
  letter-spacing: -0.005em;
  scroll-margin-top: 80px;
}

.product-subtitle {
  font-size: 13.5px;
  color: var(--text-soft);
  margin: 0 0 16px !important;
}

.product-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 16px;
}

.product-badges .badge {
  display: inline-flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-soft);
  padding: 3px 9px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 500;
  border: 0.5px solid var(--border);
}

.product-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
  gap: 6px;
  margin-bottom: 16px;
}

.product-stats .stat {
  background: rgba(255, 255, 255, 0.02);
  border: 0.5px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 8px 10px;
}

.product-stats .stat-label {
  font-size: 9.5px;
  font-weight: 600;
  color: #7dd3fc;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 2px;
}

.product-stats .stat-value {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.product-review {
  font-size: 14.5px;
  line-height: 1.65;
  color: #d4cfc1;
  margin: 0 0 14px !important;
}

.pros-cons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 18px;
}

.pros-cons div {
  background: rgba(255, 255, 255, 0.02);
  padding: 11px 13px;
  border-radius: var(--radius-sm);
}

.pros-cons .pros {
  border-left: 2px solid #1d9e75;
}

.pros-cons .cons {
  border-left: 2px solid #d85a30;
}

.pros-cons-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.pros .pros-cons-label {
  color: #5dcaa5;
}

.cons .pros-cons-label {
  color: #f0997b;
}

.pros-cons-text {
  font-size: 12.5px;
  color: var(--text-soft);
  line-height: 1.5;
}

.product-card .buy-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: var(--accent);
  color: var(--accent-text-on) !important;
  padding: 12px;
  border-radius: var(--radius-md);
  font-size: 13.5px;
  font-weight: 600;
  text-decoration: none;
  border: none !important;
  transition: filter 0.15s ease, transform 0.15s ease;
}

.product-card .buy-btn:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
  border-bottom: none !important;
}

/* Decision table */
.decision-table {
  background: var(--bg-elevated);
  border: 0.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 6px 0;
  margin: 20px 0;
}

.decision-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  border-bottom: 0.5px solid var(--border-subtle);
  font-size: 14px;
}

.decision-row:last-child {
  border-bottom: none;
}

.decision-if {
  color: var(--text);
}

.decision-arrow {
  color: var(--text-muted);
  font-size: 12px;
}

.decision-pick {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px dashed var(--accent-border) !important;
}

.decision-pick:hover {
  border-bottom-color: var(--accent) !important;
}

/* Inline matcher CTA */
.inline-cta {
  background: linear-gradient(135deg, var(--accent-soft), var(--accent-soft-2));
  border: 0.5px solid var(--accent-border);
  border-radius: var(--radius-lg);
  padding: 26px 24px;
  text-align: center;
  margin: 32px 0;
}

.inline-cta-label {
  font-size: 10.5px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.inline-cta h3 {
  font-size: 19px !important;
  font-weight: 600 !important;
  color: var(--text) !important;
  margin: 0 0 6px !important;
  letter-spacing: -0.01em;
  scroll-margin-top: 0 !important;
}

.inline-cta p {
  font-size: 13.5px !important;
  color: var(--text-soft);
  margin: 0 0 16px !important;
  line-height: 1.55;
}

.inline-cta .btn-cta {
  display: inline-block;
  background: var(--accent);
  color: var(--accent-text-on) !important;
  padding: 10px 22px;
  border-radius: var(--radius-md);
  font-size: 13.5px;
  font-weight: 600;
  text-decoration: none;
  border-bottom: none !important;
}

.inline-cta .btn-cta:hover {
  filter: brightness(1.08);
}

/* FAQ */
.faq-item {
  background: var(--bg-elevated);
  border: 0.5px solid var(--border);
  border-radius: var(--radius-md);
  margin-bottom: 8px;
  overflow: hidden;
  transition: border-color 0.15s ease;
}

.faq-item:hover {
  border-color: var(--border-strong);
}

.faq-item[open] {
  border-color: var(--accent-border);
}

.faq-item summary {
  padding: 14px 18px 14px 18px;
  font-size: 14.5px;
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
  list-style: none;
  position: relative;
  padding-right: 50px;
  transition: background 0.15s ease;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 22px;
  height: 22px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-soft);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 400;
  transition: all 0.2s ease;
}

.faq-item[open] summary::after {
  content: "−";
  background: var(--accent-soft);
  color: var(--accent);
}

.faq-item summary:hover {
  background: rgba(255, 255, 255, 0.02);
}

.faq-item p {
  padding: 0 18px 18px;
  font-size: 14px;
  line-height: 1.65;
  color: var(--text-soft);
  margin: 0 !important;
}

/* Final CTA */
.final-cta {
  background: var(--bg-elevated);
  border: 0.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 36px 28px;
  margin: 40px 0 32px;
  text-align: center;
}

.final-cta h2 {
  font-size: 22px !important;
  color: var(--text) !important;
  margin: 0 0 8px !important;
  scroll-margin-top: 0 !important;
}

.final-cta p {
  font-size: 14px;
  color: var(--text-soft);
  margin: 0 0 20px !important;
  line-height: 1.55;
  max-width: 460px;
  margin-left: auto !important;
  margin-right: auto !important;
}

.final-cta .btn {
  display: inline-block;
  background: var(--accent);
  color: var(--accent-text-on) !important;
  padding: 12px 26px;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  border: none !important;
}

/* Related articles */
.related-articles {
  margin-top: 50px;
  padding-top: 32px;
  border-top: 0.5px solid var(--border);
}

.related-articles h2 {
  font-size: 18px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 16px;
  letter-spacing: -0.01em;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.related-card {
  background: var(--bg-elevated);
  border: 0.5px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px;
  text-decoration: none !important;
  border-bottom: 0.5px solid var(--border) !important;
  transition: transform 0.2s ease, border-color 0.2s ease;
  display: block;
}

.related-card:hover {
  transform: translateY(-2px);
  border-color: var(--border-strong) !important;
}

.related-tag {
  font-size: 9.5px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.related-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
  margin-bottom: 10px;
}

.related-meta {
  font-size: 11px;
  color: var(--text-muted);
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .article-layout {
    grid-template-columns: 1fr;
    gap: 0;
    padding: 0 22px 60px;
  }
  .article-sidebar {
    display: none;
  }
  .article {
    padding-top: 30px;
    max-width: 100%;
  }
  .pros-cons {
    grid-template-columns: 1fr;
  }
  .product-stats {
    grid-template-columns: repeat(2, 1fr);
  }
  .decision-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }
  .decision-arrow {
    display: none;
  }
}

/* ============================================
   Product image placeholder
   Replace .product-image-placeholder block with
   <img class="product-image" src="..."> when real
   images are available.
   ============================================ */

.product-image-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.06) 0%, rgba(125, 211, 252, 0.06) 100%);
  border-bottom: 0.5px solid var(--border-subtle);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.product-image-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--text-muted);
  width: 100%;
  height: 100%;
  padding: 20px;
  text-align: center;
}

.product-image-placeholder svg {
  width: 56px;
  height: 56px;
  opacity: 0.45;
  color: var(--accent);
}

.product-image-placeholder-label {
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
  opacity: 0.7;
}

.product-image-caption {
  position: absolute;
  bottom: 6px;
  right: 10px;
  font-size: 10px;
  color: var(--text-muted);
  opacity: 0.5;
  letter-spacing: 0.02em;
}

@media (max-width: 700px) {
  .product-image-placeholder svg {
    width: 44px;
    height: 44px;
  }
  .product-image-placeholder-label {
    font-size: 9.5px;
  }
}

/* ============================================
   Author byline credentials
   Appears after the lede, before article body.
   ============================================ */

.author-byline {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  margin: 0 0 32px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.06) 0%, rgba(125, 211, 252, 0.04) 100%);
  border: 0.5px solid var(--accent-border);
  border-radius: var(--radius-md);
}

.author-avatar {
  flex-shrink: 0;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent) 0%, #d97706 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  color: #0d1117;
  letter-spacing: -0.02em;
}

.author-info {
  flex: 1;
  min-width: 0;
}

.author-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.005em;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.author-grammy-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: rgba(245, 158, 11, 0.15);
  color: var(--accent);
  padding: 2px 7px;
  border-radius: 4px;
  border: 0.5px solid var(--accent-border);
}

.author-credentials {
  font-size: 11.5px;
  color: var(--text-muted);
  margin-top: 2px;
  line-height: 1.4;
}

.author-credentials a {
  color: var(--text-muted);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.author-credentials a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

@media (max-width: 600px) {
  .author-byline {
    padding: 12px 14px;
    gap: 12px;
  }
  .author-avatar {
    width: 36px;
    height: 36px;
    font-size: 12px;
  }
  .author-name {
    font-size: 12.5px;
  }
  .author-credentials {
    font-size: 11px;
  }
}

/* ============================================
   Engineer note callout — for pages where Horace
   has direct professional experience with the gear
   ============================================ */

.engineer-note {
  position: relative;
  margin: 32px 0;
  padding: 22px 26px 22px 30px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.08) 0%, rgba(245, 158, 11, 0.02) 100%);
  border: 0.5px solid var(--accent-border);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius-md);
}

.engineer-note-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}

.engineer-note-label::before {
  content: "";
  display: inline-block;
  width: 14px;
  height: 14px;
  background: var(--accent);
  -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M3 18v-6a9 9 0 0 1 18 0v6'/><path d='M21 19a2 2 0 0 1-2 2h-1a2 2 0 0 1-2-2v-3a2 2 0 0 1 2-2h3zM3 19a2 2 0 0 0 2 2h1a2 2 0 0 0 2-2v-3a2 2 0 0 0-2-2H3z'/></svg>") no-repeat center / contain;
  mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M3 18v-6a9 9 0 0 1 18 0v6'/><path d='M21 19a2 2 0 0 1-2 2h-1a2 2 0 0 1-2-2v-3a2 2 0 0 1 2-2h3zM3 19a2 2 0 0 0 2 2h1a2 2 0 0 0 2-2v-3a2 2 0 0 0-2-2H3z'/></svg>") no-repeat center / contain;
}

.engineer-note-body {
  font-size: 14.5px;
  line-height: 1.65;
  color: var(--text-soft);
  font-style: italic;
}

.engineer-note-body p {
  margin: 0 0 12px;
}

.engineer-note-body p:last-child {
  margin-bottom: 0;
}

.engineer-note-body strong {
  color: var(--text);
  font-style: normal;
}

@media (max-width: 600px) {
  .engineer-note {
    padding: 18px 20px 18px 24px;
    margin: 24px 0;
  }
  .engineer-note-body {
    font-size: 13.5px;
  }
}

/* ============================================
   Book figure styling
   ============================================ */

.book-figure {
  margin: 36px 0;
}

.book-figure img {
  width: 100%;
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius-md);
  border: 0.5px solid var(--accent-border);
  background: rgba(255, 255, 255, 0.02);
}

.book-figure figcaption {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 12px;
  line-height: 1.5;
  text-align: center;
  padding: 0 8px;
}

.book-figure figcaption strong {
  color: var(--accent);
  font-weight: 600;
}

@media (max-width: 600px) {
  .book-figure {
    margin: 28px 0;
  }
  .book-figure figcaption {
    font-size: 12px;
    margin-top: 10px;
  }
}
