/* ═══════════════════════════════════════════════════════════════
   Hyperfix Labs — Blog Styles
   Reusable layout for /gainlock/blog/ index + article pages
   Depends on /styles/shared.css
   ═══════════════════════════════════════════════════════════════ */

:root {
  --volt: #4ADE80;
  --volt-soft: rgba(74, 222, 128, 0.1);
  --obsidian: #0B0F12;
  --mono: 'JetBrains Mono', monospace;
}

/* ─── Article shell ─── */
.article-shell {
  max-width: 740px;
  margin: 0 auto;
  padding: 7rem clamp(1.25rem, 4vw, 2rem) 4rem;
}

.breadcrumb {
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--text-3);
  text-transform: uppercase;
  margin-bottom: 2rem;
  display: flex;
  gap: 0.5rem;
  align-items: center;
  flex-wrap: wrap;
}
.breadcrumb a {
  color: var(--text-3);
  text-decoration: none;
  transition: color 0.2s var(--ease);
}
.breadcrumb a:hover { color: var(--text); }
.breadcrumb-sep { color: var(--border-hover); }

.article-meta {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: wrap;
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--text-3);
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}
.article-meta .dot {
  width: 4px; height: 4px;
  background: var(--border-hover);
  border-radius: 50%;
}
.article-meta .tag {
  padding: 0.3rem 0.7rem;
  background: var(--volt-soft);
  color: #166534;
  border-radius: 999px;
  font-size: 0.65rem;
  letter-spacing: 0.16em;
}

article h1 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2rem, 5vw, 3.2rem);
  line-height: 1.05;
  letter-spacing: -0.035em;
  color: var(--text);
  margin-bottom: 1.5rem;
}

.article-lede {
  font-size: clamp(1.05rem, 1.8vw, 1.2rem);
  line-height: 1.65;
  color: var(--text-2);
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}

article h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.5rem, 3vw, 1.9rem);
  letter-spacing: -0.02em;
  color: var(--text);
  margin-top: 3.25rem;
  margin-bottom: 1rem;
  line-height: 1.2;
}

article h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--text);
  margin-top: 2rem;
  margin-bottom: 0.6rem;
  line-height: 1.3;
}

article p {
  font-size: 1.02rem;
  line-height: 1.75;
  color: var(--text);
  margin-bottom: 1.15rem;
}

article ul, article ol {
  margin: 0 0 1.5rem 1.4rem;
  padding: 0;
}
article li {
  font-size: 1.02rem;
  line-height: 1.7;
  color: var(--text);
  margin-bottom: 0.55rem;
}
article ul li::marker { color: var(--text-3); }
article ol li::marker { color: var(--text-3); font-family: var(--mono); font-weight: 700; }

article strong { font-weight: 700; color: var(--text); }

article a {
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: var(--volt);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
  transition: all 0.2s var(--ease);
}
article a:hover {
  background: var(--volt-soft);
  text-decoration-thickness: 3px;
}

article hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 3rem 0;
}

/* ─── Pull-quote / callout ─── */
.callout {
  margin: 2rem 0;
  padding: 1.5rem 1.75rem;
  background: var(--bg-card);
  border-left: 3px solid var(--volt);
  border-radius: 0 12px 12px 0;
}
.callout p { margin: 0; color: var(--text-2); font-size: 1rem; }
.callout .callout-label {
  font-family: var(--mono);
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.2em;
  color: var(--text-3);
  text-transform: uppercase;
  display: block;
  margin-bottom: 0.5rem;
}

/* ─── Comparison entry card ─── */
.app-entry {
  margin: 2rem 0;
  padding: 1.75rem 1.75rem 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  transition: border-color 0.2s var(--ease), transform 0.2s var(--ease);
}
.app-entry:hover {
  border-color: var(--border-hover);
}
.app-entry-head {
  display: flex;
  align-items: baseline;
  gap: 0.85rem;
  flex-wrap: wrap;
  margin-bottom: 0.85rem;
}
.app-entry-rank {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  color: var(--text-3);
}
.app-entry h3 {
  margin: 0;
  font-size: 1.35rem;
  line-height: 1.2;
}
.app-entry-platform {
  font-family: var(--mono);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--text-3);
  text-transform: uppercase;
  padding: 0.25rem 0.55rem;
  border: 1px solid var(--border);
  border-radius: 4px;
}
.app-entry p { font-size: 0.97rem; line-height: 1.65; margin-bottom: 0.85rem; }
.app-entry-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 0.75rem 1.5rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px dashed var(--border);
}
.app-entry-meta dt {
  font-family: var(--mono);
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  color: var(--text-3);
  text-transform: uppercase;
  margin-bottom: 0.2rem;
}
.app-entry-meta dd {
  font-size: 0.92rem;
  color: var(--text);
  font-weight: 500;
}
.app-entry.featured {
  border-color: var(--volt);
  background: linear-gradient(180deg, rgba(74,222,128,0.04), var(--bg-card));
}
.app-entry.featured .app-entry-rank {
  color: #166534;
}

/* ─── Inline CTA card ─── */
.cta-card {
  margin: 3.5rem 0 0;
  padding: 2.25rem;
  background: var(--obsidian);
  color: #F1F5F9;
  border-radius: 16px;
  text-align: center;
}
.cta-card .cta-label {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.22em;
  color: var(--volt);
  text-transform: uppercase;
  display: block;
  margin-bottom: 0.85rem;
}
.cta-card h3 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.6rem;
  color: #F1F5F9;
  margin: 0 0 0.75rem;
  letter-spacing: -0.02em;
}
.cta-card p {
  color: #A1A8B0;
  font-size: 0.98rem;
  line-height: 1.6;
  margin: 0 0 1.5rem;
  max-width: 460px;
  margin-left: auto;
  margin-right: auto;
}
.cta-card a.btn-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.5rem;
  background: var(--volt);
  color: var(--obsidian);
  font-family: var(--mono);
  font-weight: 800;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 8px;
  transition: transform 0.2s var(--ease);
}
.cta-card a.btn-cta:hover { transform: translateY(-2px); background: var(--volt); text-decoration: none; }

/* ─── Article footer / share ─── */
.article-foot {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--text-3);
  text-transform: uppercase;
}

/* ─── TOC ─── */
.toc {
  margin: 2rem 0 2.5rem;
  padding: 1.25rem 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
}
.toc-title {
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.2em;
  color: var(--text-3);
  text-transform: uppercase;
  margin-bottom: 0.85rem;
}
.toc ol {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: toc;
}
.toc ol li {
  counter-increment: toc;
  font-size: 0.93rem;
  margin-bottom: 0.45rem;
  padding-left: 2rem;
  position: relative;
}
.toc ol li::before {
  content: counter(toc, decimal-leading-zero);
  position: absolute;
  left: 0;
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-3);
  top: 3px;
}
.toc a {
  color: var(--text-2);
  text-decoration: none;
  transition: color 0.2s var(--ease);
}
.toc a:hover { color: var(--text); }

/* ─── Blog index ─── */
.blog-index-shell {
  max-width: 920px;
  margin: 0 auto;
  padding: 7rem clamp(1.25rem, 4vw, 2rem) 4rem;
}
.blog-index-hero {
  margin-bottom: 3.5rem;
}
.blog-index-hero .eyebrow {
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.22em;
  color: var(--text-3);
  text-transform: uppercase;
  margin-bottom: 1rem;
  display: block;
}
.blog-index-hero h1 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.4rem, 5.5vw, 3.6rem);
  letter-spacing: -0.04em;
  line-height: 1;
  margin-bottom: 1.25rem;
}
.blog-index-hero p {
  font-size: 1.1rem;
  line-height: 1.6;
  color: var(--text-2);
  max-width: 580px;
}

.post-card {
  display: block;
  padding: 2rem 0;
  border-top: 1px solid var(--border);
  text-decoration: none;
  color: var(--text);
  transition: padding 0.2s var(--ease);
}
.post-card:last-of-type { border-bottom: 1px solid var(--border); }
.post-card:hover { padding-left: 0.5rem; }
.post-card:hover h2 { color: var(--text); }
.post-card-meta {
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--text-3);
  text-transform: uppercase;
  margin-bottom: 0.65rem;
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
}
.post-card h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.4rem, 2.8vw, 1.9rem);
  letter-spacing: -0.025em;
  line-height: 1.15;
  margin-bottom: 0.6rem;
  color: var(--text);
  transition: color 0.2s var(--ease);
}
.post-card p {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-2);
  max-width: 640px;
}

/* ─── Footer min spacing for blog pages ─── */
.article-shell + footer,
.blog-index-shell + footer { margin-top: 2rem; }

/* ─── Responsive ─── */
@media (max-width: 640px) {
  .article-shell { padding-top: 6rem; }
  .blog-index-shell { padding-top: 6rem; }
  .app-entry { padding: 1.5rem 1.25rem; }
  .cta-card { padding: 1.75rem 1.5rem; }
  .toc { padding: 1.1rem 1.25rem; }
}
