/* ============================================================
   Sharp AI Hub — Prose & article layout styles
   Extends style.v2.css for content pages
   ============================================================ */

/* ---- Page wrapper ---- */
.page-wrap {
  max-width: var(--container);
  margin: 0 auto;
  padding: var(--space-7) var(--space-5) var(--space-9);
}

/* ---- Breadcrumb ---- */
.breadcrumb {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  margin-bottom: var(--space-6);
  display: flex;
  gap: 0.4rem;
  align-items: center;
  flex-wrap: wrap;
}
.breadcrumb a {
  color: var(--color-text-muted);
  text-decoration: none;
  transition: color var(--transition);
}
.breadcrumb a:hover { color: var(--color-text); }
.breadcrumb span { opacity: 0.4; }

/* ---- Article layout ---- */
.article-wrap {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: var(--space-8);
  align-items: start;
  max-width: 1100px;
  margin: 0 auto;
}
@media (max-width: 900px) {
  .article-wrap { grid-template-columns: 1fr; }
  .article-sidebar { display: none; }
}

/* ---- Article header ---- */
.article-header { margin-bottom: var(--space-7); }
.article-tag {
  display: inline-flex;
  font-size: 0.69rem; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase;
  color: var(--color-accent-light); background: rgba(124,92,252,0.1);
  padding: 4px 9px; border-radius: var(--radius-sm);
  margin-bottom: var(--space-4);
}
.article-header h1 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.6rem);
  font-weight: var(--weight-bold);
  line-height: 1.1;
  letter-spacing: -0.025em;
  color: var(--color-heading);
  margin: 0 0 var(--space-4);
  text-wrap: balance;
}
.article-meta {
  display: flex;
  gap: var(--space-4);
  align-items: center;
  flex-wrap: wrap;
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  margin-bottom: var(--space-5);
}
.article-meta .rating { color: var(--color-star); font-size: var(--text-sm); font-weight: 600; }

/* ---- Prose content ---- */
.prose {
  color: var(--color-text);
  font-size: 1.0625rem;
  line-height: 1.75;
}
.prose h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: var(--weight-bold);
  letter-spacing: -0.02em;
  color: var(--color-heading);
  margin: 2.5rem 0 1rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--color-border);
}
.prose h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: var(--weight-bold);
  color: var(--color-heading);
  margin: 2rem 0 0.75rem;
}
.prose p { margin: 0 0 1.1rem; color: var(--color-text); }
.prose a { color: var(--color-accent-light); text-decoration: underline; text-decoration-color: rgba(165,147,255,0.3); }
.prose a:hover { text-decoration-color: var(--color-accent-light); }
.prose ul, .prose ol { padding-left: 1.5rem; margin: 0 0 1.1rem; }
.prose li { margin-bottom: 0.45rem; color: var(--color-text); }
.prose strong { color: var(--color-heading); font-weight: var(--weight-bold); }

/* ---- Verdict box ---- */
.verdict-box, .cta-box {
  background: var(--color-surface);
  border: 1px solid var(--color-accent-border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  margin: var(--space-6) 0;
}
.verdict-box strong, .cta-box strong { color: var(--color-heading); }

/* ---- Tables ---- */
.prose table {
  width: 100%; border-collapse: collapse;
  margin: var(--space-5) 0;
  font-size: var(--text-sm);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.prose th {
  background: var(--color-surface);
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--color-border-strong);
  color: var(--color-accent-light);
  font-weight: 600;
}
.prose td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--color-border);
  color: var(--color-text-muted);
}
.prose tr:last-child td { border-bottom: none; }

/* ---- FAQ ---- */
.faq-item { margin: var(--space-5) 0; }
.faq-item h3 { color: var(--color-heading); margin-bottom: 0.5rem; }

/* ---- Sidebar ---- */
.article-sidebar { position: sticky; top: 84px; }
.sidebar-box {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  margin-bottom: var(--space-4);
}
.sidebar-box h4 {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: var(--weight-bold);
  color: var(--color-heading);
  margin: 0 0 var(--space-4);
}
.toc-link {
  display: block;
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  text-decoration: none;
  padding: 4px 0;
  border-left: 2px solid var(--color-border);
  padding-left: var(--space-3);
  margin-bottom: 4px;
  transition: color var(--transition), border-color var(--transition);
}
.toc-link:hover { color: var(--color-accent-light); border-color: var(--color-accent); }

/* ---- Blog index grid ---- */
.blog-header { max-width: 640px; margin-bottom: var(--space-7); }
.blog-header h1 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.75rem);
  font-weight: var(--weight-bold);
  letter-spacing: -0.025em;
  color: var(--color-heading);
  margin: 0 0 var(--space-3);
}
.blog-header p { color: var(--color-text-muted); font-size: var(--text-lg); margin: 0; }

.article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: var(--space-5);
}
@media (max-width: 520px) {
  .article-grid { grid-template-columns: 1fr; }
}

.article-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: border-color var(--transition), transform var(--transition);
  text-decoration: none;
  display: flex;
  flex-direction: column;
}
.article-card:hover { border-color: rgba(124,92,252,0.55); transform: translateY(-2px); }
.article-card-body { padding: var(--space-5); flex: 1; display: flex; flex-direction: column; gap: var(--space-3); }
.article-title {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: var(--weight-bold);
  color: var(--color-heading);
  line-height: 1.3;
  letter-spacing: -0.01em;
  margin: 0;
  flex: 1;
}
.article-excerpt { font-size: var(--text-sm); color: var(--color-text-muted); line-height: 1.55; margin: 0; }
.article-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: var(--space-3);
  border-top: 1px solid var(--color-border);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}
.article-rating { color: var(--color-star); font-weight: 600; }

/* ---- Lang bar ---- */
.lang-bar {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 0.75rem var(--space-5);
  margin-bottom: var(--space-6);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}
.lang-bar a { color: var(--color-accent-light); text-decoration: none; }

/* ---- Stat grid (about page) ---- */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-4);
  margin: var(--space-6) 0;
}
.stat {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  text-align: center;
}
.stat-number { font-family: var(--font-display); font-size: 2rem; font-weight: var(--weight-bold); color: var(--color-accent-light); }
.stat-label { font-size: var(--text-xs); color: var(--color-text-muted); margin-top: 0.25rem; }

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

/* =====================================================================
   Sharp AI Hub — prose.css ADDITIONS / OVERRIDES
   ===================================================================== */

.prose { font-size: 1.125rem; line-height: 1.8; }
.prose > * + * { margin-top: 1.35em; }
.prose h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); letter-spacing: -0.02em; line-height: 1.2; margin-top: 2.4em; scroll-margin-top: 96px; }
.prose h3 { font-size: 1.3rem; letter-spacing: -0.01em; margin-top: 1.8em; scroll-margin-top: 96px; }
.prose h2 .accent, .prose h3 .accent { color: var(--color-accent, #7C5CFC); }
.prose a { color: var(--color-accent, #7C5CFC); text-underline-offset: 3px; text-decoration-thickness: 1px; }
.prose a:hover { text-decoration-color: var(--color-accent, #7C5CFC); }

/* Blockquote */
.prose blockquote { margin: 2em 0; padding: 4px 0 4px 24px; border-left: 3px solid var(--color-accent, #7C5CFC); font-size: 1.2rem; line-height: 1.6; color: var(--color-text, #ECECF3); }
.prose blockquote p { margin: 0; }
.prose blockquote cite { display: block; margin-top: 12px; font-size: .9rem; font-style: normal; color: var(--color-text-muted, #9A9AAE); }

/* Pull quote */
.prose .pullquote { margin: 1.8em 0; font-size: clamp(1.5rem, 3vw, 2rem); line-height: 1.3; letter-spacing: -0.02em; text-align: center; text-wrap: balance; background: linear-gradient(120deg, var(--color-accent, #7C5CFC), #a78bfa); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; }

/* Code */
.prose code { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: .9em; padding: .15em .4em; border-radius: 6px; background: rgba(124,92,252,.12); color: #cbbcff; }
.prose pre { margin: 1.8em 0; padding: 18px 20px; border-radius: 12px; border: 1px solid var(--color-border, rgba(255,255,255,.08)); background: #0d0d1a; overflow-x: auto; font-size: .92rem; line-height: 1.65; }
.prose pre code { padding: 0; background: none; color: #d7d7e6; font-size: inherit; }

/* Tables */
.prose table { width: 100%; margin: 1.8em 0; border-collapse: separate; border-spacing: 0; font-size: .98rem; border: 1px solid var(--color-border, rgba(255,255,255,.08)); border-radius: 12px; overflow: hidden; }
.prose thead th { position: sticky; top: 0; z-index: 1; text-align: left; font-size: .8rem; letter-spacing: .06em; text-transform: uppercase; color: var(--color-heading, #fff); background: #1a1a2e; padding: 12px 16px; border-bottom: 1px solid var(--color-border, rgba(255,255,255,.08)); }
.prose tbody td { padding: 12px 16px; border-bottom: 1px solid rgba(255,255,255,.05); color: var(--color-text, #ECECF3); }
.prose tbody tr:last-child td { border-bottom: none; }
.prose tbody tr:nth-child(odd) { background: rgba(255,255,255,.025); }
.prose tbody tr:nth-child(even) { background: transparent; }
.prose tbody tr:hover { background: rgba(124,92,252,.07); }

/* Affiliate CTA box */
.prose .affiliate-cta { display: flex; gap: 16px; align-items: flex-start; margin: 2em 0; padding: 20px 22px; border-radius: 14px; position: relative; background: linear-gradient(180deg, rgba(124,92,252,.08), transparent 70%), var(--color-surface, #14141E); border: 1px solid var(--color-border, rgba(255,255,255,.08)); border-left: none; }
.prose .affiliate-cta::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; border-radius: 14px 0 0 14px; background: linear-gradient(180deg, var(--color-accent, #7C5CFC), #a78bfa); }
.prose .affiliate-cta__icon { flex: 0 0 auto; width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px; font-size: 1.25rem; color: #fff; background: linear-gradient(135deg, var(--color-accent, #7C5CFC), #a78bfa); }
.prose .affiliate-cta__body { flex: 1; }
.prose .affiliate-cta__body > * { margin: 0; }
.prose .affiliate-cta__body > * + * { margin-top: 8px; }
.prose .affiliate-cta__btn { display: inline-block; margin-top: 12px; padding: 9px 18px; border-radius: 10px; font-weight: 600; font-size: .95rem; text-decoration: none; color: #fff; background: linear-gradient(135deg, var(--color-accent, #7C5CFC), #6d4cf0); transition: transform .15s ease, box-shadow .15s ease; }
.prose .affiliate-cta__btn:hover { transform: translateY(-1px); box-shadow: 0 8px 20px -8px rgba(124,92,252,.7); }

/* =====================================================================
   Blog index + article legacy classes
   ===================================================================== */

/* Lang bar */
.lang-bar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  font-size: .85rem; color: var(--color-text-muted, #9A9AAE);
  margin-bottom: 2rem; padding: 10px 16px;
  border: 1px solid var(--color-border, rgba(255,255,255,.08));
  border-radius: 10px; background: rgba(255,255,255,.03);
}
.lang-bar a { color: var(--color-accent, #7C5CFC); text-decoration: none; }
.lang-bar a:hover { text-decoration: underline; }

/* Blog page heading + subtitle */
.page-wrap > h1 { font-size: clamp(1.8rem, 4vw, 2.8rem); letter-spacing: -.02em; margin-bottom: .5rem; }
.page-wrap > .subtitle { color: var(--color-text-muted, #9A9AAE); font-size: 1.1rem; margin-bottom: 2.5rem; }

/* Article grid */
.article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr));
  gap: 20px;
}

/* Article card */
.article-card {
  border: 1px solid var(--color-border, rgba(255,255,255,.08));
  border-radius: 14px;
  background: var(--color-surface, #14141E);
  transition: transform .22s cubic-bezier(.2,.7,.3,1), border-color .22s ease, box-shadow .22s ease;
  overflow: hidden;
}
.article-card:hover {
  transform: translateY(-3px);
  border-color: rgba(124,92,252,.3);
  box-shadow: 0 14px 32px -14px rgba(0,0,0,.6), 0 0 0 1px rgba(124,92,252,.12);
}
.article-card > a {
  display: flex; flex-direction: column; height: 100%;
  text-decoration: none; color: inherit; padding: 20px;
  gap: 10px;
}
.article-card > a > div:first-child { flex: 1; display: flex; flex-direction: column; gap: 8px; }

/* Article tag (category chip) */
.article-tag {
  display: inline-block; width: fit-content;
  font-size: .72rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
  color: var(--color-accent-light, #A593FF);
  background: rgba(124,92,252,.12);
  border: 1px solid rgba(124,92,252,.2);
  border-radius: 6px; padding: 3px 9px;
}

/* Article title */
.article-title {
  font-size: 1.05rem; font-weight: 700; line-height: 1.35;
  letter-spacing: -.01em;
  color: var(--color-heading, #fff);
}

/* Article excerpt */
.article-excerpt {
  font-size: .9rem; line-height: 1.6;
  color: var(--color-text-muted, #9A9AAE);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}

/* Article meta (date + read time) */
.article-meta {
  display: flex; gap: 12px; flex-wrap: wrap;
  font-size: .78rem; color: var(--color-text-muted, #9A9AAE);
  margin-top: auto; padding-top: 8px;
  border-top: 1px solid var(--color-border, rgba(255,255,255,.06));
}

/* Article rating badge */
.article-rating {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 42px; height: 28px; padding: 0 8px;
  border-radius: 8px; font-size: .85rem; font-weight: 700;
  background: rgba(124,92,252,.15); color: #a78bfa;
  align-self: flex-start; flex-shrink: 0;
}

/* ── Article page classes ─────────────────────────────────────── */

/* Verdict box */
.verdict-box {
  margin: 1.5em 0 2em;
  padding: 20px 24px;
  border-radius: 14px;
  border: 1px solid var(--color-border, rgba(255,255,255,.08));
  border-left: 4px solid var(--color-accent, #7C5CFC);
  background: linear-gradient(180deg, rgba(124,92,252,.08), transparent 60%), var(--color-surface, #14141E);
}
.verdict-box .rating { font-size: 1.6rem; font-weight: 700; color: #a78bfa; }
.verdict-box .meta { font-size: .9rem; color: var(--color-text-muted, #9A9AAE); margin-top: 6px; }

/* CTA box */
.cta-box {
  display: flex; flex-wrap: wrap; align-items: center; gap: 16px;
  margin: 2em 0; padding: 22px 24px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(124,92,252,.15), rgba(167,139,250,.08));
  border: 1px solid rgba(124,92,252,.25);
}
.cta-box a.btn, .cta-box .btn {
  display: inline-block; padding: 10px 22px; border-radius: 10px;
  font-weight: 600; font-size: .95rem; text-decoration: none;
  color: #fff; background: linear-gradient(135deg, #7C5CFC, #6d4cf0);
  transition: transform .15s ease, box-shadow .15s ease;
}
.cta-box a.btn:hover { transform: translateY(-1px); box-shadow: 0 8px 20px -8px rgba(124,92,252,.7); }

/* FAQ */
.faq-item { margin: 1.5em 0; }
.faq-item h3 { margin-bottom: .5em; }

/* Article meta line (date, author) */
.prose .meta, article .meta {
  display: flex; flex-wrap: wrap; gap: 16px;
  font-size: .85rem; color: var(--color-text-muted, #9A9AAE);
  border-bottom: 1px solid var(--color-border, rgba(255,255,255,.08));
  padding-bottom: 1.5em; margin-bottom: 1.5em;
}

/* =====================================================================
   Table wrapper + enhanced comparison tables
   ===================================================================== */
.table-wrap {
  overflow-x: auto; -webkit-overflow-scrolling: touch;
  margin: 1.8em 0; border-radius: 14px;
  border: 1px solid var(--color-border, rgba(255,255,255,.08));
  box-shadow: 0 4px 24px -8px rgba(0,0,0,.4);
}
.table-wrap table,
.prose .table-wrap table { margin: 0; border: none; border-radius: 0; box-shadow: none; }
.table-wrap table thead th { background: #1c1c2e; }
.table-wrap table td:first-child { font-weight: 600; color: var(--color-heading, #fff); }

/* Checkmark / cross colorize */
.prose td { white-space: nowrap; }
.prose td:not(:first-child) { color: var(--color-text-muted, #9A9AAE); font-size: .92rem; }

/* =====================================================================
   Article layout: prose + sidebar
   ===================================================================== */
.article-layout {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 48px;
  align-items: start;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}
@media (max-width: 900px) {
  .article-layout { grid-template-columns: 1fr; }
  .article-sidebar { display: none; }
}
.article-layout .prose { min-width: 0; }

/* Sidebar */
.article-sidebar {
  position: sticky; top: 88px;
  display: flex; flex-direction: column; gap: 20px;
  max-height: calc(100vh - 100px); overflow-y: auto;
}
.sidebar-box {
  border: 1px solid var(--color-border, rgba(255,255,255,.08));
  border-radius: 14px;
  background: var(--color-surface, #14141E);
  padding: 18px;
}
.sidebar-box__title {
  font-size: .7rem; font-weight: 700; letter-spacing: .12em;
  text-transform: uppercase; color: var(--color-text-muted, #9A9AAE);
  margin: 0 0 14px;
}
.related-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.related-item a {
  display: grid; grid-template-columns: 48px 1fr; gap: 10px;
  align-items: center; text-decoration: none; color: inherit;
}
.related-item a:hover .related-title { color: var(--color-accent, #7C5CFC); }
.related-thumb {
  width: 48px; height: 48px; border-radius: 10px;
  display: grid; place-items: center;
  font-size: 1.3rem; font-weight: 700; color: rgba(255,255,255,.7);
  flex-shrink: 0;
}
.related-title {
  font-size: .88rem; font-weight: 600; line-height: 1.35;
  color: var(--color-heading, #fff);
  transition: color .15s ease;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.related-cat {
  font-size: .7rem; color: var(--color-text-muted, #9A9AAE);
  margin-top: 2px;
}

/* =====================================================================
   Article hero image
   ===================================================================== */
.article-hero {
  width: 100%; aspect-ratio: 16/7; border-radius: 16px;
  display: flex; align-items: center; justify-content: center;
  position: relative; overflow: hidden; margin-bottom: 2rem;
}
.article-hero__icon {
  font-size: 4rem; font-weight: 900; letter-spacing: -.04em;
  color: rgba(255,255,255,.15); user-select: none; line-height: 1;
}
.article-hero__label {
  position: absolute; bottom: 16px; left: 20px;
  font-size: .72rem; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; color: rgba(255,255,255,.5);
}
.article-hero::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(120% 80% at 20% 0%, rgba(255,255,255,.1), transparent 55%);
  pointer-events: none;
}
