/* ═══════════════════════════════════════════════════════════
   NavvyNest Blog Templates
   Three distinct blog post layouts:
   1. The Compass — Featured Story (hero-forward, editorial)
   2. The Nest — Resource Guide (structured, two-column with TOC)
   3. The Lantern — Quick Insight (warm, intimate, short-form)
   ═══════════════════════════════════════════════════════════ */

/* ─────────────────────────────────────────────────────────
   Shared Blog Post Styles
   ───────────────────────────────────────────────────────── */

.blog-post-full {
  max-width: 720px;
  margin: 0 auto;
}

.blog-body {
  color: var(--color-text-primary, #1f1f1f);
  line-height: 1.8;
  font-size: var(--font-size-base, 1rem);
}

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

.blog-body h2 {
  font-size: 1.75rem;
  font-weight: 600;
  color: var(--color-navy, #203b8a);
  margin: 2.5rem 0 1rem;
  line-height: 1.3;
}

.blog-body h3 {
  font-size: 1.375rem;
  font-weight: 600;
  color: var(--color-navy, #203b8a);
  margin: 2rem 0 0.75rem;
  line-height: 1.3;
}

.blog-body ul,
.blog-body ol {
  margin: 1rem 0 1.5rem 1.5rem;
  line-height: 1.8;
}

.blog-body ul {
  list-style: none;
  padding-left: 0;
}

.blog-body ul li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.5rem;
}

.blog-body ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.65rem;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--color-orange, #fe8a51);
}

.blog-body ol {
  list-style: none;
  counter-reset: blog-counter;
  padding-left: 0;
}

.blog-body ol li {
  counter-increment: blog-counter;
  position: relative;
  padding-left: 2.75rem;
  margin-bottom: 1rem;
}

.blog-body ol li::before {
  content: counter(blog-counter);
  position: absolute;
  left: 0;
  top: 0;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-orange, #fe8a51);
  color: #fff;
  font-size: 0.8125rem;
  font-weight: 700;
  border-radius: 50%;
}

.blog-body strong {
  font-weight: 600;
  color: var(--color-navy, #203b8a);
}

.blog-body a {
  color: var(--color-navy, #203b8a);
  text-decoration: underline;
  text-decoration-color: var(--color-orange, #fe8a51);
  text-underline-offset: 3px;
  transition: color 200ms ease;
}

.blog-body a:hover {
  color: var(--color-orange, #fe8a51);
}

.blog-body img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-lg, 24px);
  margin: 2rem 0;
  box-shadow: var(--shadow-md, 0 8px 24px rgba(20, 27, 60, 0.06));
}

.blog-body blockquote {
  margin: 2rem 0;
  padding: 1rem 0 1rem 1.5rem;
  border-left: 4px solid var(--color-orange, #fe8a51);
  font-style: italic;
  font-size: 1.125rem;
  color: var(--color-text-secondary, #5b6275);
  line-height: 1.7;
}

/* Share buttons (shared) */
.blog-share {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 2.5rem 0 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--color-border, #e5e5f0);
}

.blog-share-label {
  font-size: 0.875rem;
  color: var(--color-text-muted, #8891a8);
  font-weight: 500;
}

.blog-share-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1.5px solid var(--color-border, #e5e5f0);
  background: #fff;
  cursor: pointer;
  font-size: 1rem;
  transition: all 200ms ease;
  text-decoration: none;
}

.blog-share-btn:hover {
  border-color: var(--color-navy, #203b8a);
  background: var(--color-navy, #203b8a);
  color: #fff;
  transform: translateY(-2px);
}

/* Back to blog link (shared) */
.blog-back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9375rem;
  color: var(--color-text-secondary, #5b6275);
  text-decoration: none;
  transition: color 200ms ease;
}

.blog-back-link:hover {
  color: var(--color-orange, #fe8a51);
}

/* ─────────────────────────────────────────────────────────
   Template 1: The Compass — Featured Story
   Hero-forward editorial layout for narratives
   ───────────────────────────────────────────────────────── */

.blog-template-compass {
  max-width: none;
}

/* Hero section */
.compass-hero {
  position: relative;
  width: 100%;
  min-height: 480px;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  border-radius: 0 0 var(--radius-2xl, 40px) var(--radius-2xl, 40px);
  margin-bottom: 0;
}

.compass-hero-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.compass-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(32, 59, 138, 0.3) 0%,
    rgba(32, 59, 138, 0.7) 60%,
    rgba(24, 42, 107, 0.9) 100%
  );
}

.compass-hero-content {
  position: relative;
  z-index: 2;
  max-width: 800px;
  padding: 0 var(--spacing-2xl, 3rem) var(--spacing-3xl, 4rem);
  margin: 0 auto;
  width: 100%;
}

.compass-hero-eyebrow {
  display: inline-block;
  font-size: 0.8125rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-orange-light, #ffab7d);
  margin-bottom: 1rem;
}

.compass-hero-title {
  font-size: clamp(2rem, 5vw, 3.25rem);
  font-weight: 700;
  color: #fff;
  line-height: 1.15;
  margin: 0 0 1rem 0;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.2);
}

.compass-hero-subtitle {
  font-size: 1.25rem;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.6;
  margin: 0;
  max-width: 600px;
}

/* No hero fallback */
.compass-hero.no-image {
  min-height: 320px;
  background: linear-gradient(135deg, var(--color-navy, #203b8a), var(--color-navy-dark, #182a6b));
}

/* Byline */
.compass-byline {
  max-width: 720px;
  margin: 0 auto;
  padding: var(--spacing-2xl, 3rem) var(--spacing-md, 1rem) var(--spacing-xl, 2rem);
  display: flex;
  align-items: center;
  gap: 16px;
}

.compass-author-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--color-navy, #203b8a), var(--color-navy-light, #4b6bb7));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 600;
  font-size: 1.125rem;
  flex-shrink: 0;
}

.compass-byline-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.compass-author-name {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--color-text-primary, #1f1f1f);
}

.compass-article-date {
  font-size: 0.8125rem;
  color: var(--color-text-muted, #8891a8);
}

.compass-divider {
  max-width: 720px;
  margin: 0 auto;
  height: 3px;
  width: 60px;
  background: var(--color-orange, #fe8a51);
  border-radius: 9999px;
  margin-bottom: var(--spacing-2xl, 3rem);
}

/* Body */
.compass-body {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 var(--spacing-md, 1rem) var(--spacing-3xl, 4rem);
}

/* Pull quote */
.compass-body blockquote {
  margin: 3rem 0;
  padding: 1.5rem 0 1.5rem 2rem;
  border-left: 5px solid var(--color-orange, #fe8a51);
  font-size: 1.375rem;
  font-style: italic;
  color: var(--color-navy, #203b8a);
  line-height: 1.6;
  font-weight: 500;
}

/* Related stories */
.compass-related {
  max-width: 900px;
  margin: 0 auto;
  padding: var(--spacing-3xl, 4rem) var(--spacing-md, 1rem);
}

.compass-related-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--color-navy, #203b8a);
  margin-bottom: var(--spacing-xl, 2rem);
  text-align: center;
}

.compass-related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: var(--spacing-xl, 2rem);
}

.compass-related-card {
  display: block;
  background: var(--color-card, #fff);
  border-radius: var(--radius-lg, 24px);
  overflow: hidden;
  box-shadow: var(--shadow-sm, 0 4px 12px rgba(20, 27, 60, 0.04));
  text-decoration: none;
  transition: all 300ms ease;
}

.compass-related-card:hover {
  box-shadow: var(--shadow-lg, 0 35px 80px rgba(20, 27, 60, 0.12));
  transform: translateY(-4px);
}

.compass-related-card-image {
  width: 100%;
  height: 160px;
  object-fit: cover;
  background: var(--color-background-muted, #e5e5f0);
}

.compass-related-card-body {
  padding: var(--spacing-lg, 1.5rem);
}

.compass-related-card-category {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-orange, #fe8a51);
  margin-bottom: 0.5rem;
}

.compass-related-card-title {
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--color-navy, #203b8a);
  line-height: 1.4;
  margin: 0;
}

/* ─────────────────────────────────────────────────────────
   Template 2: The Nest — Resource Guide
   Structured, scannable, two-column with sticky TOC
   ───────────────────────────────────────────────────────── */

.blog-template-nest {
  max-width: none;
}

/* Header */
.nest-header {
  background: var(--color-navy, #203b8a);
  padding: var(--spacing-4xl, 6rem) var(--spacing-md, 1rem) var(--spacing-3xl, 4rem);
  text-align: center;
  position: relative;
  overflow: hidden;
  border-radius: 0 0 var(--radius-2xl, 40px) var(--radius-2xl, 40px);
}

/* Decorative orange arc — echoes the "nest" shape */
.nest-header::after {
  content: '';
  position: absolute;
  bottom: -60px;
  left: 50%;
  transform: translateX(-50%);
  width: 200px;
  height: 100px;
  border: 4px solid var(--color-orange, #fe8a51);
  border-top: none;
  border-radius: 0 0 100px 100px;
  opacity: 0.6;
}

.nest-header-eyebrow {
  display: inline-block;
  font-size: 0.8125rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-orange-light, #ffab7d);
  margin-bottom: 1rem;
}

.nest-header-title {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 700;
  color: #fff;
  line-height: 1.2;
  margin: 0 auto 1rem;
  max-width: 700px;
}

.nest-header-subtitle {
  font-size: 1.125rem;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.6;
  max-width: 600px;
  margin: 0 auto;
}

.nest-byline {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 1.5rem;
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.7);
}

.nest-byline .nest-byline-divider {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--color-orange, #fe8a51);
}

/* Two-column layout */
.nest-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: var(--spacing-3xl, 4rem);
  max-width: 1100px;
  margin: 0 auto;
  padding: var(--spacing-3xl, 4rem) var(--spacing-md, 1rem);
  align-items: start;
}

/* Sticky TOC */
.nest-toc {
  position: sticky;
  top: 2rem;
  padding: 1.5rem;
  background: var(--color-background, #f4f6ff);
  border-radius: var(--radius-md, 20px);
  border: 1px solid var(--color-border, #e5e5f0);
}

.nest-toc-title {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted, #8891a8);
  margin: 0 0 1rem 0;
}

.nest-toc ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.nest-toc li {
  margin-bottom: 0.5rem;
}

.nest-toc a {
  display: block;
  font-size: 0.875rem;
  color: var(--color-text-secondary, #5b6275);
  text-decoration: none;
  padding: 6px 10px;
  border-radius: 8px;
  transition: all 200ms ease;
  line-height: 1.4;
}

.nest-toc a:hover {
  background: var(--color-navy, #203b8a);
  color: #fff;
}

/* Article body */
.nest-body {
  max-width: 720px;
}

.nest-body h2 {
  position: relative;
  padding-left: 1.5rem;
}

.nest-body h2::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.55rem;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-orange, #fe8a51);
}

/* Callout boxes */
.nest-callout {
  margin: 2rem 0;
  padding: 1.25rem 1.5rem;
  background: rgba(32, 59, 138, 0.06);
  border: 1px solid rgba(32, 59, 138, 0.15);
  border-radius: var(--radius-md, 20px);
}

.nest-callout-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--color-navy, #203b8a);
  margin-bottom: 0.5rem;
}

.nest-callout-label-icon {
  font-size: 1rem;
}

.nest-callout p {
  margin: 0;
  font-size: 0.9375rem;
  color: var(--color-text-secondary, #5b6275);
  line-height: 1.7;
}

/* Feedback bar */
.nest-feedback {
  max-width: 720px;
  margin: 0 auto;
  padding: var(--spacing-xl, 2rem) var(--spacing-md, 1rem) var(--spacing-3xl, 4rem);
  text-align: center;
}

.nest-feedback-question {
  font-size: 1.0625rem;
  font-weight: 500;
  color: var(--color-navy, #203b8a);
  margin-bottom: 1rem;
}

.nest-feedback-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
}

.nest-feedback-btn {
  padding: 10px 24px;
  font-size: 0.9375rem;
  font-weight: 500;
  border: 2px solid var(--color-border, #e5e5f0);
  border-radius: 9999px;
  background: #fff;
  color: var(--color-text-secondary, #5b6275);
  cursor: pointer;
  transition: all 200ms ease;
}

.nest-feedback-btn:hover {
  border-color: var(--color-navy, #203b8a);
  color: var(--color-navy, #203b8a);
}

.nest-feedback-btn.yes:hover {
  background: var(--color-green, #80c95e);
  border-color: var(--color-green, #80c95e);
  color: #fff;
}

.nest-feedback-btn.no:hover {
  background: var(--color-orange, #fe8a51);
  border-color: var(--color-orange, #fe8a51);
  color: #fff;
}

/* Print styles */
@media print {
  .nest-toc,
  .nest-feedback,
  .blog-share,
  .site-header,
  .site-footer {
    display: none !important;
  }
  .nest-layout {
    grid-template-columns: 1fr;
    display: block;
  }
  .nest-header {
    background: #fff !important;
    color: #000 !important;
    border-radius: 0;
  }
  .nest-header-title,
  .nest-header-subtitle {
    color: #000 !important;
  }
  .nest-header::after {
    display: none;
  }
  body {
    background: #fff !important;
  }
}

/* ─────────────────────────────────────────────────────────
   Template 3: The Lantern — Quick Insight
   Warm, intimate, short-form layout
   ───────────────────────────────────────────────────────── */

.blog-template-lantern {
  max-width: none;
}

/* Warm gradient header with lantern glow */
.lantern-header {
  position: relative;
  background: linear-gradient(160deg, var(--color-navy, #203b8a) 0%, var(--color-navy-light, #4b6bb7) 100%);
  padding: var(--spacing-4xl, 6rem) var(--spacing-md, 1rem) var(--spacing-3xl, 4rem);
  text-align: center;
  overflow: hidden;
  border-radius: 0 0 var(--radius-2xl, 40px) var(--radius-2xl, 40px);
}

/* Soft orange glow — like a lantern's light */
.lantern-header::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(254, 138, 81, 0.25) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.lantern-header-eyebrow {
  position: relative;
  z-index: 2;
  display: inline-block;
  font-size: 0.8125rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-orange-light, #ffab7d);
  margin-bottom: 1rem;
}

.lantern-header-title {
  position: relative;
  z-index: 2;
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  color: #fff;
  line-height: 1.25;
  margin: 0 auto 0.75rem;
  max-width: 560px;
}

.lantern-header-subtitle {
  position: relative;
  z-index: 2;
  font-size: 1.0625rem;
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.6;
  max-width: 500px;
  margin: 0 auto;
}

/* Narrow reading column */
.lantern-body {
  max-width: 600px;
  margin: 0 auto;
  padding: var(--spacing-3xl, 4rem) var(--spacing-md, 1rem) var(--spacing-2xl, 3rem);
  font-size: 1.125rem;
  line-height: 1.85;
  color: var(--color-text-primary, #1f1f1f);
}

.lantern-body p {
  margin-bottom: 1.75rem;
}

/* Drop cap on first paragraph */
.lantern-body > p:first-child::first-letter {
  float: left;
  font-size: 3.5rem;
  font-weight: 700;
  color: var(--color-orange, #fe8a51);
  line-height: 0.8;
  margin: 0.25rem 0.5rem 0 0;
  font-family: var(--font-family, 'Space Grotesk', sans-serif);
}

/* Insight cards — navy cards with white text */
.lantern-insight {
  margin: 2.5rem 0;
  padding: 1.5rem 1.75rem;
  background: var(--color-navy, #203b8a);
  border-radius: var(--radius-md, 20px);
  color: #fff;
  position: relative;
}

.lantern-insight::before {
  content: '💡';
  position: absolute;
  top: -12px;
  left: 1.5rem;
  font-size: 1.25rem;
  background: var(--color-orange, #fe8a51);
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
}

.lantern-insight p {
  margin: 0;
  font-size: 1rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.95);
}

/* Single image with orange border */
.lantern-image {
  max-width: 100%;
  border-radius: var(--radius-lg, 24px);
  border: 3px solid var(--color-orange, #fe8a51);
  margin: 2rem 0;
  display: block;
}

/* Minimal footer */
.lantern-footer {
  max-width: 600px;
  margin: 0 auto;
  padding: var(--spacing-xl, 2rem) var(--spacing-md, 1rem) var(--spacing-3xl, 4rem);
  text-align: center;
  border-top: 1px solid var(--color-border, #e5e5f0);
}

.lantern-footer-byline {
  font-size: 0.875rem;
  color: var(--color-text-muted, #8891a8);
  margin-bottom: 1.5rem;
}

.lantern-footer-byline strong {
  color: var(--color-text-secondary, #5b6275);
  font-weight: 600;
}

.lantern-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: var(--color-orange, #fe8a51);
  color: #fff;
  font-weight: 600;
  font-size: 0.9375rem;
  border-radius: 9999px;
  text-decoration: none;
  transition: all 200ms ease;
  box-shadow: 0 8px 24px rgba(254, 138, 81, 0.3);
}

.lantern-cta:hover {
  background: var(--color-orange-light, #ffab7d);
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(254, 138, 81, 0.4);
}

/* ─────────────────────────────────────────────────────────
   Responsive
   ───────────────────────────────────────────────────────── */

@media (max-width: 900px) {
  .nest-layout {
    grid-template-columns: 1fr;
    gap: var(--spacing-xl, 2rem);
  }

  .nest-toc {
    position: static;
    order: 2;
  }

  .nest-body {
    order: 1;
  }
}

@media (max-width: 640px) {
  .compass-hero {
    min-height: 360px;
  }

  .compass-hero-content {
    padding: 0 var(--spacing-lg, 1.5rem) var(--spacing-2xl, 3rem);
  }

  .compass-hero-title {
    font-size: 1.75rem;
  }

  .compass-hero-subtitle {
    font-size: 1rem;
  }

  .nest-header {
    padding: var(--spacing-3xl, 4rem) var(--spacing-lg, 1.5rem) var(--spacing-2xl, 3rem);
  }

  .lantern-header {
    padding: var(--spacing-3xl, 4rem) var(--spacing-lg, 1.5rem) var(--spacing-2xl, 3rem);
  }

  .lantern-body {
    font-size: 1rem;
    padding: var(--spacing-2xl, 3rem) var(--spacing-lg, 1.5rem) var(--spacing-xl, 2rem);
  }

  .lantern-body > p:first-child::first-letter {
    font-size: 2.75rem;
  }

  .compass-related-grid {
    grid-template-columns: 1fr;
  }

  .blog-body ol li {
    padding-left: 2.25rem;
  }

  .blog-body ol li::before {
    width: 24px;
    height: 24px;
    font-size: 0.75rem;
  }
}

/* ═══════════════════════════════════════════════════════════
   Blog Listing — Search + Topic Sidebar Layout
   ═══════════════════════════════════════════════════════════ */

.blog-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: var(--spacing-2xl, 3rem);
  align-items: start;
}

.blog-sidebar {
  position: sticky;
  top: 90px;
  display: flex;
  flex-direction: column;
  gap: var(--spacing-xl, 2rem);
}

.blog-sidebar-card {
  background: var(--color-card, #fff);
  border-radius: var(--radius-lg, 24px);
  box-shadow: var(--shadow-md, 0 8px 24px rgba(20,27,60,0.06));
  padding: var(--spacing-xl, 2rem);
}

.blog-sidebar-title {
  font-size: var(--font-size-sm, 0.875rem);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-navy, #203b8a);
  margin: 0 0 var(--spacing-md, 1rem);
}

/* Search box in sidebar */
.blog-search {
  position: relative;
}

.blog-search-input {
  width: 100%;
  padding: 12px 14px 12px 40px;
  border: 1.5px solid var(--color-border, #e5e5f0);
  border-radius: var(--radius-sm, 12px);
  font-size: var(--font-size-base, 1rem);
  font-family: inherit;
  color: var(--color-text-primary, #1f1f1f);
  background: var(--color-card, #fff);
  transition: border-color var(--transition-fast, 150ms ease);
  box-sizing: border-box;
}

.blog-search-input:focus {
  outline: none;
  border-color: var(--color-navy, #203b8a);
}

.blog-search-input::placeholder {
  color: var(--color-text-muted, #8891a8);
}

.blog-search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-text-muted, #8891a8);
  font-size: 1rem;
  pointer-events: none;
}

/* Topic list */
.blog-topics-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.blog-topic-item {
  margin: 0;
}

.blog-topic-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 10px 14px;
  border: 0;
  background: transparent;
  border-radius: var(--radius-sm, 12px);
  font-size: var(--font-size-sm, 0.875rem);
  font-family: inherit;
  color: var(--color-text-secondary, #5b6275);
  text-align: left;
  cursor: pointer;
  transition: all var(--transition-fast, 150ms ease);
}

.blog-topic-btn:hover {
  background: var(--color-background-muted, #e5e5f0);
  color: var(--color-navy, #203b8a);
}

.blog-topic-btn.active {
  background: var(--color-navy, #203b8a);
  color: #fff;
  font-weight: 600;
}

.blog-topic-btn.active .blog-topic-count {
  color: rgba(255,255,255,0.8);
}

.blog-topic-count {
  font-size: var(--font-size-xs, 0.75rem);
  color: var(--color-text-muted, #8891a8);
  background: var(--color-background-muted, #e5e5f0);
  padding: 2px 8px;
  border-radius: 9999px;
  min-width: 24px;
  text-align: center;
}

.blog-topic-btn:hover .blog-topic-count {
  background: rgba(255,255,255,0.5);
}

/* Recent posts in sidebar */
.blog-recent-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md, 1rem);
}

.blog-recent-item {
  margin: 0;
}

.blog-recent-link {
  display: block;
  text-decoration: none;
  color: var(--color-text-primary, #1f1f1f);
  font-size: var(--font-size-sm, 0.875rem);
  font-weight: 500;
  line-height: 1.4;
  transition: color var(--transition-fast, 150ms ease);
}

.blog-recent-link:hover {
  color: var(--color-orange, #fe8a51);
}

.blog-recent-date {
  display: block;
  font-size: var(--font-size-xs, 0.75rem);
  color: var(--color-text-muted, #8891a8);
  margin-top: 2px;
}

/* Main content area */
.blog-main {
  min-width: 0;
}

.blog-results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--spacing-md, 1rem);
  margin-bottom: var(--spacing-xl, 2rem);
}

.blog-results-title {
  font-size: var(--font-size-xl, 1.25rem);
  font-weight: 600;
  color: var(--color-navy, #203b8a);
  margin: 0;
}

.blog-results-count {
  font-size: var(--font-size-sm, 0.875rem);
  color: var(--color-text-muted, #8891a8);
}

.blog-clear-filters {
  font-size: var(--font-size-sm, 0.875rem);
  color: var(--color-orange, #fe8a51);
  background: none;
  border: 0;
  cursor: pointer;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: var(--radius-sm, 12px);
  transition: background var(--transition-fast, 150ms ease);
}

.blog-clear-filters:hover {
  background: rgba(254, 138, 81, 0.1);
}

.blog-posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--spacing-2xl, 2rem);
}

.blog-card {
  background: var(--color-card, #fff);
  border-radius: var(--radius-lg, 24px);
  box-shadow: var(--shadow-md, 0 8px 24px rgba(20,27,60,0.06));
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform var(--transition-base, 250ms ease), box-shadow var(--transition-base, 250ms ease);
}

.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg, 0 35px 80px rgba(20,27,60,0.12));
}

.blog-card-image {
  height: 180px;
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
}

.blog-card-body {
  padding: var(--spacing-xl, 2rem);
  display: flex;
  flex-direction: column;
  flex: 1;
}

.blog-card-category {
  font-size: var(--font-size-xs, 0.75rem);
  color: var(--color-orange, #fe8a51);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: var(--spacing-sm, 0.75rem);
}

.blog-card-title {
  font-size: var(--font-size-xl, 1.25rem);
  margin: 0 0 var(--spacing-sm, 0.75rem);
  color: var(--color-navy, #203b8a);
  line-height: 1.3;
}

.blog-card-title a {
  color: inherit;
  text-decoration: none;
}

.blog-card-title a:hover {
  color: var(--color-orange, #fe8a51);
}

.blog-card-subtitle {
  color: var(--color-text-secondary, #5b6275);
  font-size: var(--font-size-sm, 0.875rem);
  margin: 0 0 var(--spacing-md, 1rem);
}

.blog-card-excerpt {
  color: var(--color-text-secondary, #5b6275);
  font-size: var(--font-size-sm, 0.875rem);
  line-height: 1.6;
  margin: 0 0 var(--spacing-lg, 1.5rem);
}

.blog-card-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: var(--font-size-xs, 0.75rem);
  color: var(--color-text-muted, #8891a8);
  margin-top: auto;
}

.blog-empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: var(--spacing-4xl, 6rem) var(--spacing-xl, 2rem);
  color: var(--color-text-secondary, #5b6275);
}

.blog-empty-state h3 {
  font-size: var(--font-size-2xl, 1.5rem);
  color: var(--color-navy, #203b8a);
  margin: 0 0 var(--spacing-sm, 0.75rem);
}

.blog-empty-state p {
  margin: 0 0 var(--spacing-lg, 1.5rem);
}

/* Mobile sidebar toggle */
.blog-sidebar-toggle {
  display: none;
  width: 100%;
  padding: 14px 18px;
  background: var(--color-navy, #203b8a);
  color: #fff;
  border: 0;
  border-radius: var(--radius-sm, 12px);
  font-size: var(--font-size-base, 1rem);
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  margin-bottom: var(--spacing-lg, 1.5rem);
  align-items: center;
  justify-content: center;
  gap: 8px;
}

/* ── Responsive ── */

@media (max-width: 900px) {
  .blog-layout {
    grid-template-columns: 1fr;
  }

  .blog-sidebar {
    position: static;
  }

  .blog-sidebar.collapsed {
    display: none;
  }

  .blog-sidebar-toggle {
    display: flex;
  }
}

@media (max-width: 640px) {
  .blog-posts-grid {
    grid-template-columns: 1fr;
  }
}
