/* ===========================================================
   Zeptrix Labs · Blog stylesheet
   Loaded after the main styles.css so it inherits brand tokens
   (--bg, --lime, --text, --font-display, --font-body, etc.)
   =========================================================== */

/* -------- Layout -------- */
.blog-shell {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* -------- Hero (listing) -------- */
.blog-hero {
  padding: 5rem 0 3rem;
  text-align: center;
  position: relative;
}

.blog-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(60% 60% at 50% 0%, rgba(212,255,58,0.06) 0%, transparent 70%);
  pointer-events: none;
  z-index: -1;
}

.blog-hero .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--lime);
  margin-bottom: 1.25rem;
}

.blog-hero .eyebrow::before,
.blog-hero .eyebrow::after {
  content: "";
  width: 22px;
  height: 1px;
  background: var(--lime);
}

.blog-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 4.2rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0 auto 1rem;
  max-width: 900px;
}

.blog-hero h1 .italic {
  font-style: italic;
  color: var(--lime);
  font-weight: 300;
}

.blog-hero p {
  max-width: 640px;
  margin: 0 auto;
  color: var(--text-soft);
  font-size: 1.05rem;
  line-height: 1.65;
}

/* -------- Breadcrumb -------- */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  padding: 1.5rem 0;
}

.breadcrumb a {
  color: var(--text-soft);
  text-decoration: none;
  transition: color 0.2s;
}

.breadcrumb a:hover { color: var(--lime); }
.breadcrumb .separator { opacity: 0.4; }
.breadcrumb .current { color: var(--lime); }

/* -------- Search bar -------- */
.blog-search {
  max-width: 580px;
  margin: 2rem auto 0;
  position: relative;
}

.blog-search input {
  width: 100%;
  background: var(--bg-elevated);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 999px;
  padding: 0.95rem 1.4rem 0.95rem 3rem;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.98rem;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.blog-search input:focus {
  border-color: rgba(212,255,58,0.5);
  box-shadow: 0 0 0 3px rgba(212,255,58,0.1);
}

.blog-search input::placeholder { color: var(--text-muted); }

.blog-search .search-icon {
  position: absolute;
  left: 1.1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}

/* -------- Categories -------- */
.blog-categories {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
  margin: 2rem 0 3rem;
}

.category-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 1rem;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 999px;
  color: var(--text-soft);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s;
}

.category-chip:hover,
.category-chip.active {
  background: var(--lime-soft);
  border-color: rgba(212,255,58,0.4);
  color: var(--lime);
}

/* -------- Featured article -------- */
.featured-article {
  background: linear-gradient(135deg, rgba(212,255,58,0.05) 0%, rgba(212,255,58,0.01) 100%);
  border: 1px solid rgba(212,255,58,0.18);
  border-radius: 24px;
  padding: 2.5rem;
  margin-bottom: 4rem;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 3rem;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.featured-article::before {
  content: "Featured";
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--lime);
  background: rgba(10,10,11,0.6);
  border: 1px solid rgba(212,255,58,0.3);
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
}

.featured-article .featured-meta {
  display: flex;
  gap: 0.8rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
}

.featured-article .featured-meta .category { color: var(--lime); }

.featured-article h2 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  line-height: 1.1;
  margin: 0 0 1rem;
}

.featured-article h2 a {
  color: var(--text);
  text-decoration: none;
  transition: color 0.2s;
}

.featured-article h2 a:hover { color: var(--lime); }

.featured-article p {
  color: var(--text-soft);
  font-size: 1.02rem;
  line-height: 1.65;
  margin: 0 0 1.5rem;
}

.featured-article .featured-image {
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: var(--bg-elevated);
}

.featured-article .featured-image svg {
  width: 100%;
  height: 100%;
  display: block;
}

@media (max-width: 768px) {
  .featured-article {
    grid-template-columns: 1fr;
    padding: 1.8rem;
    gap: 1.5rem;
  }
}

/* -------- Article grid (listing) -------- */
.article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
  gap: 2rem;
  margin-bottom: 5rem;
}

.article-card {
  background: var(--bg-elevated);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 20px;
  overflow: hidden;
  transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
  display: flex;
  flex-direction: column;
}

.article-card:hover {
  transform: translateY(-4px);
  border-color: rgba(212,255,58,0.3);
  box-shadow: 0 12px 40px -16px rgba(212,255,58,0.2);
}

.article-card .card-image {
  aspect-ratio: 16 / 10;
  background: var(--bg);
  overflow: hidden;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.article-card .card-image svg {
  width: 100%;
  height: 100%;
  display: block;
}

.article-card .card-body {
  padding: 1.6rem 1.5rem 1.8rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.article-card .card-meta {
  display: flex;
  gap: 0.7rem;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  margin-bottom: 0.9rem;
}

.article-card .card-meta .category { color: var(--lime); }

.article-card h3 {
  font-family: var(--font-display);
  font-size: 1.42rem;
  line-height: 1.18;
  margin: 0 0 0.7rem;
  letter-spacing: -0.01em;
}

.article-card h3 a {
  color: var(--text);
  text-decoration: none;
  transition: color 0.2s;
}

.article-card h3 a:hover { color: var(--lime); }

.article-card .card-excerpt {
  color: var(--text-soft);
  font-size: 0.93rem;
  line-height: 1.6;
  margin: 0 0 1.2rem;
}

.article-card .card-footer {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid rgba(255,255,255,0.06);
  font-size: 0.82rem;
  color: var(--text-muted);
}

.article-card .author-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--lime);
  color: var(--bg);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 500;
  font-style: italic;
  font-size: 0.95rem;
}

/* ===========================================================
   ARTICLE PAGE
   =========================================================== */

.article-shell {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.article-header {
  padding: 3rem 0 2.5rem;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.article-header .article-category {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--lime);
  padding: 0.35rem 0.9rem;
  border: 1px solid rgba(212,255,58,0.3);
  border-radius: 999px;
  margin-bottom: 1.5rem;
}

.article-header h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4.5vw, 3.6rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin: 0 0 1.5rem;
}

.article-header h1 .italic {
  font-style: italic;
  color: var(--lime);
  font-weight: 300;
}

.article-header .article-subtitle {
  color: var(--text-soft);
  font-size: 1.15rem;
  line-height: 1.6;
  margin: 0 0 2rem;
}

.article-meta {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  font-size: 0.88rem;
  color: var(--text-soft);
}

.article-meta .author {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.article-meta .author-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--lime);
  color: var(--bg);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 500;
  font-style: italic;
  font-size: 1.1rem;
}

.article-meta .author-name {
  font-weight: 500;
  color: var(--text);
  line-height: 1.2;
}

.article-meta .author-title {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
}

.article-meta .meta-separator { color: var(--text-muted); opacity: 0.5; }

/* -------- Hero illustration -------- */
.article-hero-image {
  width: 100%;
  max-width: 920px;
  margin: 0 auto 3rem;
  aspect-ratio: 16 / 9;
  border-radius: 24px;
  background: var(--bg-elevated);
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.06);
}

.article-hero-image svg {
  width: 100%;
  height: 100%;
  display: block;
}

/* -------- Article body -------- */
.article-layout {
  display: grid;
  grid-template-columns: 1fr 240px;
  gap: 4rem;
  margin-bottom: 5rem;
}

.article-body {
  max-width: 720px;
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--text-soft);
}

.article-body p {
  margin: 0 0 1.4rem;
}

.article-body h2 {
  font-family: var(--font-display);
  font-size: 2rem;
  line-height: 1.2;
  letter-spacing: -0.015em;
  color: var(--text);
  margin: 3rem 0 1.2rem;
}

.article-body h2:first-child { margin-top: 0; }

.article-body h3 {
  font-family: var(--font-display);
  font-size: 1.45rem;
  line-height: 1.25;
  color: var(--text);
  margin: 2.4rem 0 0.9rem;
}

.article-body h4 {
  font-family: var(--font-body);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
  margin: 2rem 0 0.7rem;
}

.article-body strong { color: var(--text); font-weight: 600; }

.article-body a {
  color: var(--lime);
  text-decoration: underline;
  text-decoration-color: rgba(212,255,58,0.3);
  text-underline-offset: 3px;
  transition: text-decoration-color 0.2s;
}

.article-body a:hover { text-decoration-color: var(--lime); }

.article-body ul,
.article-body ol {
  margin: 0 0 1.6rem;
  padding-left: 1.4rem;
}

.article-body li {
  margin-bottom: 0.55rem;
}

.article-body ul li::marker { color: var(--lime); }

.article-body blockquote {
  border-left: 3px solid var(--lime);
  padding: 0.4rem 0 0.4rem 1.4rem;
  margin: 2rem 0;
  font-family: var(--font-display);
  font-size: 1.18rem;
  font-style: italic;
  line-height: 1.55;
  color: var(--text);
}

.article-body code {
  background: rgba(212,255,58,0.08);
  color: var(--lime);
  padding: 0.15em 0.4em;
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 0.9em;
}

/* -------- Tables / comparison charts -------- */
.article-body .table-wrap {
  overflow-x: auto;
  margin: 1.8rem 0;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.08);
}

.article-body table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.article-body th {
  background: var(--bg-elevated);
  color: var(--lime);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  text-align: left;
  padding: 0.95rem 1.1rem;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.article-body td {
  padding: 0.95rem 1.1rem;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  color: var(--text-soft);
}

.article-body tr:last-child td { border-bottom: none; }
.article-body tr:nth-child(even) td { background: rgba(255,255,255,0.015); }

/* -------- Callouts -------- */
.callout {
  background: rgba(212,255,58,0.05);
  border: 1px solid rgba(212,255,58,0.2);
  border-radius: 14px;
  padding: 1.4rem 1.6rem;
  margin: 2rem 0;
  display: flex;
  gap: 1rem;
}

.callout-icon {
  font-family: var(--font-mono);
  font-weight: 700;
  color: var(--lime);
  flex-shrink: 0;
  font-size: 1.4rem;
  line-height: 1.2;
}

.callout-body {
  color: var(--text);
  font-size: 0.97rem;
  line-height: 1.6;
  margin: 0;
}

.callout-body strong { color: var(--lime); }

/* -------- TOC sidebar -------- */
.article-toc {
  position: sticky;
  top: 6rem;
  align-self: start;
  font-family: var(--font-body);
}

.article-toc .toc-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--lime);
  margin-bottom: 1rem;
}

.article-toc ul {
  list-style: none;
  padding: 0;
  margin: 0;
  border-left: 1px solid rgba(255,255,255,0.08);
}

.article-toc li {
  padding: 0;
}

.article-toc a {
  display: block;
  padding: 0.55rem 0 0.55rem 1rem;
  font-size: 0.86rem;
  color: var(--text-soft);
  text-decoration: none;
  border-left: 2px solid transparent;
  margin-left: -1px;
  line-height: 1.4;
  transition: color 0.2s, border-color 0.2s;
}

.article-toc a:hover {
  color: var(--lime);
  border-left-color: var(--lime);
}

@media (max-width: 1024px) {
  .article-layout {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .article-toc {
    position: static;
    background: var(--bg-elevated);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 14px;
    padding: 1.2rem 1.4rem;
    margin-bottom: 2rem;
  }

  .article-toc ul { border-left: none; }
  .article-toc a { padding-left: 0; border-left: none; }
}

/* -------- Social share -------- */
.share-bar {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 1.4rem 0;
  border-top: 1px solid rgba(255,255,255,0.06);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  margin: 3rem 0;
  flex-wrap: wrap;
}

.share-bar .share-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
}

.share-bar .share-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  color: var(--text-soft);
  padding: 0.5rem 0.95rem;
  border-radius: 999px;
  text-decoration: none;
  font-size: 0.82rem;
  transition: all 0.2s;
}

.share-bar .share-btn:hover {
  background: var(--lime-soft);
  border-color: rgba(212,255,58,0.4);
  color: var(--lime);
}

/* -------- FAQ section -------- */
.faq-section {
  margin: 3rem 0 2rem;
}

.faq-item {
  background: var(--bg-elevated);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 14px;
  margin-bottom: 0.8rem;
  overflow: hidden;
}

.faq-item summary {
  padding: 1.2rem 1.4rem;
  cursor: pointer;
  font-family: var(--font-body);
  font-weight: 500;
  color: var(--text);
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  transition: color 0.2s;
}

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary::after {
  content: "+";
  color: var(--lime);
  font-family: var(--font-mono);
  font-size: 1.4rem;
  transition: transform 0.2s;
}

.faq-item[open] summary::after { transform: rotate(45deg); }

.faq-item summary:hover { color: var(--lime); }

.faq-item .faq-body {
  padding: 0 1.4rem 1.4rem;
  color: var(--text-soft);
  line-height: 1.65;
  font-size: 0.97rem;
}

/* -------- Article CTA box -------- */
.article-cta {
  background: linear-gradient(135deg, rgba(212,255,58,0.12) 0%, rgba(212,255,58,0.03) 100%);
  border: 1px solid rgba(212,255,58,0.3);
  border-radius: 20px;
  padding: 2.4rem;
  margin: 3rem 0;
  text-align: center;
}

.article-cta h3 {
  font-family: var(--font-display);
  font-size: 1.8rem;
  line-height: 1.15;
  margin: 0 0 0.8rem;
  color: var(--text);
}

.article-cta h3 .italic { font-style: italic; color: var(--lime); font-weight: 300; }

.article-cta p {
  color: var(--text-soft);
  max-width: 540px;
  margin: 0 auto 1.6rem;
  line-height: 1.6;
}

.article-cta .cta-button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--lime);
  color: var(--bg);
  padding: 0.95rem 1.8rem;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  text-decoration: none;
  box-shadow: 0 8px 32px -8px rgba(212,255,58,0.4);
  transition: transform 0.2s, box-shadow 0.2s;
}

.article-cta .cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 40px -8px rgba(212,255,58,0.55);
}

/* -------- Related articles -------- */
.related-articles {
  margin: 4rem 0;
  padding-top: 3rem;
  border-top: 1px solid rgba(255,255,255,0.08);
}

.related-articles h2 {
  font-family: var(--font-display);
  font-size: 2rem;
  margin: 0 0 2rem;
  letter-spacing: -0.015em;
}

.related-articles h2 .italic { font-style: italic; color: var(--lime); font-weight: 300; }

.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

/* -------- Reading time / progress -------- */
.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: var(--lime);
  z-index: 100;
  width: 0;
  transition: width 0.1s;
  box-shadow: 0 0 8px rgba(212,255,58,0.6);
}

/* -------- Responsive tweaks -------- */
@media (max-width: 768px) {
  .article-meta { gap: 0.8rem; font-size: 0.82rem; }
  .article-meta .meta-separator { display: none; }
  .article-body { font-size: 1rem; }
  .article-body h2 { font-size: 1.65rem; margin-top: 2.4rem; }
  .article-body h3 { font-size: 1.25rem; }
}
