/* ── BLOG STYLES ── */

/* Reading progress bar */
#reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, #0066cc, #00d4ff);
  z-index: 9999;
  width: 0%;
  transition: width 0.1s linear;
}

/* ── Article Body Typography ── */
.article-body {
  font-size: 16px;
  line-height: 1.9;
  letter-spacing: 0.02em;
  color: #1a2040;
  max-width: 720px;
}

@media (max-width: 768px) {
  .article-body {
    font-size: 15px;
  }
}

.article-body h2 {
  font-size: 24px;
  font-weight: 700;
  margin-top: 3rem;
  margin-bottom: 1.2rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #e8f0fb;
  color: #0a0e27;
  scroll-margin-top: 100px;
}

.article-body h3 {
  font-size: 20px;
  font-weight: 600;
  margin-top: 2rem;
  margin-bottom: 0.8rem;
  color: #0a0e27;
}

.article-body p {
  margin-bottom: 1.5rem;
}

.article-body a {
  color: #0066cc;
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.15s;
}

.article-body a:hover {
  color: #004499;
}

.article-body blockquote {
  border-left: 4px solid #0066cc;
  padding: 1rem 1.5rem;
  background: #f8fafc;
  margin: 2rem 0;
  font-style: normal;
  border-radius: 0 8px 8px 0;
}

.article-body figure {
  margin: 2rem 0;
}

.article-body figure img {
  border-radius: 12px;
  width: 100%;
  height: auto;
}

.article-body figure figcaption {
  font-size: 13px;
  color: #6b7280;
  text-align: center;
  margin-top: 0.5rem;
}

.article-body ul, .article-body ol {
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
}

.article-body li {
  margin-bottom: 0.5rem;
}

/* ── Sticky TOC ── */
.toc-sidebar {
  position: sticky;
  top: 100px;
}

.toc-link {
  display: block;
  padding: 6px 12px;
  font-size: 13px;
  color: #6b7280;
  border-left: 2px solid transparent;
  transition: all 0.2s ease;
  line-height: 1.5;
}

.toc-link:hover {
  color: #0066cc;
  background: rgba(0, 102, 204, 0.04);
}

.toc-link.active {
  color: #0066cc;
  border-left-color: #0066cc;
  font-weight: 600;
  background: rgba(0, 102, 204, 0.04);
}

/* ── Blog Cards ── */
.blog-card {
  background: white;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
  border: 1px solid #f0f0f3;
  transition: all 0.3s cubic-bezier(.4, 0, .2, 1);
}

.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px -8px rgba(0, 102, 204, 0.15);
  border-color: rgba(0, 102, 204, 0.15);
}

.blog-card-image {
  aspect-ratio: 16 / 9;
  object-fit: cover;
  width: 100%;
}

/* ── Category Badge ── */
.category-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 12px;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 600;
}

.category-badge--articles {
  background: #e8f0fb;
  color: #0066cc;
}

.category-badge--media {
  background: #fef3c7;
  color: #92400e;
}

/* ── Tag Badge ── */
.tag-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 500;
  background: #f3f4f6;
  color: #4b5563;
  transition: background 0.15s;
}

.tag-badge:hover {
  background: #e8f0fb;
  color: #0066cc;
}

/* ── Share Buttons ── */
.share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1px solid #e5e7eb;
  color: #6b7280;
  transition: all 0.2s ease;
}

.share-btn:hover {
  border-color: #0066cc;
  color: #0066cc;
  background: rgba(0, 102, 204, 0.04);
}

.share-btn--copied {
  border-color: #10b981 !important;
  color: #10b981 !important;
  background: rgba(16, 185, 129, 0.04) !important;
}

/* ── Category Tabs ── */
.category-tab {
  padding: 8px 20px;
  border-radius: 9999px;
  font-size: 14px;
  font-weight: 600;
  color: #6b7280;
  border: 1.5px solid #e5e7eb;
  transition: all 0.2s ease;
  cursor: pointer;
}

.category-tab:hover {
  border-color: #0066cc;
  color: #0066cc;
}

.category-tab.active {
  background: #0066cc;
  border-color: #0066cc;
  color: white;
}

/* ── Breadcrumb ── */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #9ca3af;
  flex-wrap: wrap;
}

.breadcrumb a {
  color: #6b7280;
  transition: color 0.15s;
}

.breadcrumb a:hover {
  color: #0066cc;
}

.breadcrumb-sep {
  color: #d1d5db;
}

/* ── Inline CTA ── */
.inline-cta {
  background: linear-gradient(135deg, #f0f7ff 0%, #fafcff 100%);
  border: 1px solid #e8f0fb;
  border-radius: 16px;
  padding: 2rem;
  margin: 2.5rem 0;
}

/* ── Sidebar CTA ── */
.sidebar-cta {
  background: linear-gradient(135deg, #0066cc 0%, #004499 100%);
  border-radius: 16px;
  padding: 1.5rem;
  color: white;
}

/* ── Author Card ── */
.author-card {
  background: #f8fafc;
  border-radius: 16px;
  padding: 1.5rem 2rem;
  border: 1px solid #f0f0f3;
}

/* ── Mobile TOC Toggle ── */
.mobile-toc-toggle {
  display: none;
}

@media (max-width: 1023px) {
  .mobile-toc-toggle {
    display: block;
  }
}
