/* =========================================================
   STATECRAFT EDITORIAL — blog components
   Loaded AFTER the main site's css/styles.css, which supplies the
   tokens (colours, fonts), header, footer, buttons, eyebrows, the
   page-intro band and the blog cards. This file only adds what the
   archive and article pages need on top, in the same visual language.
   ========================================================= */

/* ---------- Intro band (archive + category + search) ---------- */
.editorial-intro { padding: 190px 0 100px; }
.editorial-intro--compact { padding: 170px 0 80px; }
.editorial-intro .eyebrow a:hover { color: var(--cream); }
.editorial-intro .hero-actions { margin-top: 36px; }

/* ---------- Archive ---------- */
.editorial-archive { background: var(--paper); padding: 72px 0 110px; }

.filters {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 48px;
}

.search-form { display: flex; }
.search-form input {
  width: 15rem;
  padding: 11px 14px;
  font-family: var(--sans);
  font-size: 14px;
  color: var(--text-dark);
  background: #fff;
  border: 1px solid var(--line-ink);
  border-radius: 0;
  outline: none;
  transition: border-color .2s ease, width .25s ease;
}
.search-form input:focus { border-color: var(--brass); width: 18rem; }
.search-form button {
  padding: 0 16px;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: #fff;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: background .25s ease, border-color .25s ease;
}
.search-form button:hover { background: var(--brass); border-color: var(--brass); }

/* Cards: .blog-card comes from styles.css. Additions: */
/* The newest article leads the archive as a wide card. */
.blog-card--feature { grid-column: 1 / -1; flex-direction: row; }
.blog-card--feature .blog-card-media { flex: 1 1 55%; aspect-ratio: auto; min-height: 380px; }
.blog-card--feature .blog-card-body { flex: 1 1 45%; padding: 44px 44px 36px; justify-content: center; }
.blog-card--feature h3 { font-size: clamp(30px, 3vw, 42px); line-height: 1.1; }
.blog-card--feature p { font-size: 16px; -webkit-line-clamp: 5; }
.blog-card--feature .blog-tag { background: var(--brass); color: #fff; }

mark { background: rgba(240,78,26,0.16); color: inherit; padding: 0 .15em; }

.empty {
  text-align: center;
  padding: 80px 24px;
  border: 1px solid var(--line-ink);
  background: var(--cream);
}
.empty h3 { font-size: 30px; margin-bottom: 10px; }
.empty p { color: var(--text-mute); margin: 0; }
.text-link {
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--brass-dim);
}
.text-link:hover { color: var(--ink); }

.pager { display: flex; align-items: center; justify-content: center; gap: 10px; margin-top: 64px; flex-wrap: wrap; }
.pager a, .pager span {
  min-width: 44px; height: 44px;
  display: grid; place-items: center;
  font-family: var(--sans); font-size: 14px; font-weight: 500;
  border: 1px solid var(--line-ink);
  color: var(--ink);
  background: #fff;
  transition: background .25s ease, color .25s ease, border-color .25s ease;
}
.pager a:hover { border-color: var(--ink); }
.pager .is-current { background: var(--ink); border-color: var(--ink); color: var(--cream); }
.pager .is-disabled { opacity: .4; }
.pager .pager-step { padding: 0 18px; font-size: 11px; font-weight: 600; letter-spacing: 2.5px; text-transform: uppercase; }

/* ---------- Single article (matches statecraft.com.ng/blog/…) ---------- */
/* Banner: solid navy band, date eyebrow, large serif headline. */
.post-hero { background: var(--ink); padding: 150px 0 0; position: relative; overflow: hidden; }
.post-hero .container { position: relative; z-index: 2; padding-bottom: 90px; }
.post-hero .eyebrow { margin-bottom: 36px; }
.post-hero h1 { color: var(--cream); font-size: clamp(38px, 5vw, 76px); max-width: 20ch; margin: 0; }
.post-hero .lead { color: rgba(248, 244, 235, 0.94); max-width: 65ch; margin: 28px 0 0; }

/* Featured image: full container width, below the banner. */
.post-figure { margin: 80px auto 30px; }
.post-figure img { width: 100%; max-height: 620px; object-fit: cover; }
.post-figure-credit { font-family: var(--serif); font-style: italic; font-size: 15px; color: var(--text-mute); margin: 10px 0 0; }

/* Body: centred reading column.
   Measured from the live statecraft.com.ng articles at 1366px wide:
   18.5px text on a 33.3px line (1.8), 22px between paragraphs, 41px / 27px
   serif headings with 46/18 and 38/14 spacing, a 17.5px lead line, 794px
   column, lists without markers, quotes with an orange rule. */
.post-body { padding-top: 30px; padding-bottom: 110px; }
.post-body--no-figure { padding-top: 80px; }
.post-body .prose {
  max-width: 794px; margin: 0 auto;
  font-family: var(--sans); font-size: 18.5px; line-height: 1.8; color: var(--text-dark);
  overflow-wrap: break-word; word-break: break-word;
}
.post-body .prose > * { max-width: 100%; margin: 0; }
.post-body .prose > p:first-child::first-letter { float: none; font: inherit; color: inherit; padding: 0; }
.post-body .prose p,
.post-body .prose ul,
.post-body .prose ol { font-family: inherit; font-size: 18.5px; line-height: 1.8; color: inherit; letter-spacing: .002em; }
.post-body .prose p { margin: 0 0 1.2em; }
/* "# Lead line" — the short opening line the live posts start with. */
.post-body .prose h1 {
  font-family: inherit; font-size: 17.5px; font-weight: 500; line-height: 1.6;
  letter-spacing: .002em; color: inherit; margin: 0 0 24px; max-width: none;
}
.post-body .prose h2 {
  font-family: var(--serif); font-size: clamp(30px, 3vw, 44px); font-weight: 500;
  line-height: 1.02; letter-spacing: -0.01em; color: var(--text-dark); margin: 46px 0 18px;
}
.post-body .prose h3 {
  font-family: var(--serif); font-size: clamp(22px, 2vw, 30px); font-weight: 500;
  line-height: 1.05; letter-spacing: -0.01em; color: var(--text-dark); margin: 38px 0 14px;
}
.post-body .prose > :first-child { margin-top: 0; }
.post-body .prose strong, .post-body .prose b { font-weight: 700; color: inherit; }
.post-body .prose em, .post-body .prose i { color: inherit; }
.post-body .prose ul, .post-body .prose ol { list-style: none; margin: 0; padding-left: 22px; }
.post-body .prose li { margin: 0 0 8px; }
.post-body .prose li::marker { content: none; }
.post-body .prose img { max-width: 100%; height: auto; margin: 30px 0; border: 0; }
.post-body .prose p > img:only-child { display: block; margin: 30px 0; }
.post-body .prose blockquote {
  margin: 34px 0; padding: 6px 0 6px 26px; border-left: 2px solid var(--brass);
  font-family: inherit; font-style: italic; font-size: 17px; line-height: 1.7; color: inherit;
}
.post-body .prose blockquote p { font-size: inherit; line-height: inherit; margin: 0; }
.post-body .prose blockquote p + p { margin-top: .8em; }
.post-body .prose hr { margin: 46px 0; }
.post-body .prose .callout { margin: 34px 0; }

/* Related articles (same category) under each post. */
.post-related { padding: 90px 0 110px; }
.post-related .home-blog-head h2 em { color: var(--brass); }

/* Share row */
.share-bar {
  max-width: 800px;
  margin: 46px auto 0;
  padding-top: 26px;
  border-top: 1px solid rgba(10, 22, 40, 0.12);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 11px 20px;
  border: 0;
  background: var(--ink);
  color: #f6f1e7;
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  cursor: pointer;
  transition: background .25s ease;
}
.share-btn:hover { background: #16294a; }
.share-alt {
  padding: 10px 16px;
  border: 1px solid rgba(10, 22, 40, 0.16);
  color: #4a5568;
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  text-decoration: none;
  transition: color .25s ease, border-color .25s ease;
}
.share-alt:hover { color: var(--brass-dim); border-color: var(--brass-dim); }

.post-back {
  max-width: 800px;
  margin: 60px auto 40px;
  font-family: var(--sans);
  font-size: 13px;
  letter-spacing: 1px;
}
.post-back a:hover { color: var(--brass-dim); }

.avatar {
  width: 42px; height: 42px; flex: none;
  display: grid; place-items: center;
  background: var(--brass);
  color: #fff;
  font-family: var(--serif);
  font-size: 20px;
}

.prose { max-width: 720px; font-size: 18px; line-height: 1.8; color: var(--text-dark); }
.prose > * + * { margin-top: 1.2em; }
.prose p { font-size: inherit; line-height: inherit; margin: 0; }
.prose > p:first-child::first-letter {
  float: left;
  font-family: var(--serif);
  font-size: 4.4em;
  line-height: .82;
  padding: .06em .1em 0 0;
  color: var(--brass);
}
.prose h2 { font-size: clamp(30px, 3vw, 40px); margin: 2em 0 0; line-height: 1.12; }
.prose h3 { font-size: clamp(24px, 2.2vw, 29px); margin: 1.7em 0 0; }
.prose h4 { font-family: var(--sans); font-weight: 600; font-size: 13px; letter-spacing: 2.5px; text-transform: uppercase; color: var(--brass-dim); margin: 1.8em 0 0; }
.prose em, .prose i { color: inherit; }
.prose a { color: var(--brass-dim); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.prose a:hover { color: var(--ink); }
.prose strong { color: var(--ink); font-weight: 600; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin: .5em 0; }
.prose li::marker { color: var(--brass); }
.prose blockquote {
  margin: 2em 0;
  padding: .1em 0 .1em 28px;
  border-left: 2px solid var(--brass);
  font-family: var(--serif);
  font-style: italic;
  font-size: 26px;
  line-height: 1.4;
  color: var(--ink);
}
.prose blockquote p:last-child { margin-bottom: 0; }
.prose hr { border: 0; height: 1px; background: var(--line-ink); margin: 2.6em 0; }
.prose img { border: 1px solid var(--line-ink); }
.prose code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .86em; background: var(--paper); padding: .12em .4em; }
.prose pre { background: var(--ink); color: var(--cream); padding: 20px 24px; overflow-x: auto; font-size: 14px; line-height: 1.6; }
.prose pre code { background: none; padding: 0; color: inherit; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line-ink); background: #fff; }
.prose table { width: 100%; border-collapse: collapse; font-size: 15px; }
.prose th, .prose td { padding: 12px 16px; border-bottom: 1px solid var(--line-ink); text-align: left; }
.prose th { background: var(--paper); font-family: var(--sans); font-size: 10px; font-weight: 600; letter-spacing: 2.5px; text-transform: uppercase; color: var(--brass-dim); }
.prose tr:last-child td { border-bottom: 0; }
.callout { margin: 2em 0; padding: 22px 26px; background: var(--paper); border-left: 3px solid var(--brass); }
.callout-label { display: block; font-family: var(--sans); font-size: 10px; font-weight: 600; letter-spacing: 3px; text-transform: uppercase; color: var(--brass-dim); margin-bottom: 8px; }
.callout p:last-child { margin-bottom: 0; }
.callout--warning { border-left-color: var(--ink); }
.callout--warning .callout-label { color: var(--ink); }

.badge {
  display: inline-block;
  font-family: var(--sans);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  padding: 6px 10px;
  background: rgba(240,78,26,0.12);
  color: var(--brass-dim);
}

.progress { position: fixed; top: 0; left: 0; height: 3px; background: var(--brass); width: 0; z-index: 150; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .blog-card--feature { flex-direction: column; }
  .blog-card--feature .blog-card-media { aspect-ratio: 16 / 10; min-height: 0; }
  .blog-card--feature .blog-card-body { padding: 26px 26px 24px; }
}
@media (max-width: 720px) {
  .editorial-intro, .editorial-intro--compact { padding: 140px 0 64px; }
  .post-hero { padding: 120px 0 0; }
  .post-hero .container { padding-bottom: 60px; }
  .post-figure { margin: 60px auto 30px; }
  .post-body { padding-top: 20px; padding-bottom: 80px; }
  .post-body--no-figure { padding-top: 56px; }
  .post-body .prose { font-size: 17px; line-height: 1.75; }
  .post-body .prose p, .post-body .prose ul, .post-body .prose ol { font-size: 17px; line-height: 1.75; }
  .post-body .prose h1 { font-size: 16.5px; line-height: 1.6; }
  .post-body .prose h2 { margin: 34px 0 14px; font-size: 26px; }
  .post-body .prose h3 { font-size: 22px; margin: 30px 0 12px; }
  .post-body .prose ul, .post-body .prose ol { padding-left: 18px; }
  .post-body .prose blockquote { margin: 26px 0; padding-left: 18px; font-size: 16.5px; }
  .post-related { padding: 64px 0 80px; }
  .editorial-archive { padding: 48px 0 80px; }
  .search-form { width: 100%; }
  .search-form input, .search-form input:focus { width: 100%; }
  .prose { font-size: 17px; }
  .prose blockquote { font-size: 22px; }
}
