/* ============================================================
   Stur Africa — Blog styles
   Requires colors_and_type.css + site.css loaded first
   ============================================================ */

/* ══════════════════════════════════════════════════════
   HERO
══════════════════════════════════════════════════════ */
.blog-hero {
  background: var(--grad-hero);
  padding: 148px 24px 72px;
  text-align: center;
}
.blog-hero-inner {
  max-width: 600px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.blog-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(44px, 7.2vw, 88.568px);
  font-weight: 600;
  line-height: 0.931;
  letter-spacing: clamp(-3px, -0.25vw, -1.5px);
  color: var(--ink);
  text-wrap: balance;
  margin: 0;
}
.blog-hero-sub {
  font-size: 17px;
  color: var(--fg-muted);
  line-height: 1.5;
  margin: 0;
}

/* Category filter pills */
.blog-cats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
  width: fit-content;
}
.blog-cat {
  height: 36px;
  padding: 0 18px;
  border-radius: var(--r-pill);
  border: 1.5px solid var(--grey-300);
  background: transparent;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-60);
  cursor: pointer;
  transition: background var(--dur-fast) var(--ease-std),
              color var(--dur-fast) var(--ease-std),
              border-color var(--dur-fast) var(--ease-std);
}
.blog-cat.active,
.blog-cat:hover {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}

/* ══════════════════════════════════════════════════════
   MAIN LAYOUT
══════════════════════════════════════════════════════ */
.blog-main {
  padding: 72px 24px 100px;
  background: var(--paper);
}
.blog-container {
  max-width: var(--content-max);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 72px;
}

/* ══════════════════════════════════════════════════════
   TAG BADGES
══════════════════════════════════════════════════════ */
.blog-tag {
  display: inline-block;
  width: fit-content;
  padding: 4px 11px;
  border-radius: var(--r-pill);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  line-height: 1;
}
.blog-tag--product { background: #ede9ff; color: var(--stur-purple); }
.blog-tag--guides  { background: #e0f7fa; color: #00838f; }
.blog-tag--vendor  { background: #fce4ec; color: #c2185b; }
.blog-tag--updates { background: #e8f5e9; color: #2e7d32; }

/* ══════════════════════════════════════════════════════
   FEATURED POST
══════════════════════════════════════════════════════ */
.blog-featured {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  border-radius: var(--r-card);
  overflow: hidden;
  background: var(--grey-50);
  text-decoration: none;
  color: inherit;
  transition: box-shadow var(--dur) var(--ease-std);
}
.blog-featured:hover { box-shadow: 0 8px 40px rgba(0,0,0,0.10); }

.featured-img-wrap {
  overflow: hidden;
  min-height: 360px;
}
.featured-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s var(--ease-std);
}
.blog-featured:hover .featured-img { transform: scale(1.04); }

.featured-body {
  padding: 48px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  justify-content: center;
}
.featured-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: var(--fg-subtle);
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 10px;
}
.featured-label::before {
  content: '';
  display: inline-block;
  width: 24px;
  height: 2px;
  background: var(--stur-purple);
  border-radius: 1px;
  flex-shrink: 0;
}
.featured-title {
  font-size: 30px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.5px;
  color: var(--ink);
  text-wrap: balance;
  margin: 0;
}
.featured-excerpt {
  font-size: 16px;
  color: var(--fg-muted);
  line-height: 1.6;
  margin: 0;
}
.featured-read {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 700;
  color: var(--stur-purple);
  margin-top: 4px;
}
.featured-read svg {
  transition: transform var(--dur-fast) var(--ease-std);
}
.blog-featured:hover .featured-read svg { transform: translateX(4px); }

/* ══════════════════════════════════════════════════════
   POST META (author · date · read time)
══════════════════════════════════════════════════════ */
.post-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--fg-muted);
  flex-wrap: wrap;
}
.author-av {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--stur-purple);
  color: var(--paper);
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
}
.author-av img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.author-name { font-weight: 600; color: var(--ink); }
.meta-sep { color: var(--grey-300); font-size: 10px; }

/* ══════════════════════════════════════════════════════
   POST GRID
══════════════════════════════════════════════════════ */
.blog-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: -40px;
}
.blog-section-head h2 {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--fg-subtle);
  margin: 0;
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}
.blog-card {
  display: flex;
  flex-direction: column;
  border-radius: var(--r-tile);
  overflow: hidden;
  background: var(--paper);
  border: 1px solid rgba(0,0,0,0.07);
  text-decoration: none;
  color: inherit;
  transition: box-shadow var(--dur) var(--ease-std),
              transform var(--dur) var(--ease-std);
}
.blog-card:hover {
  box-shadow: 0 4px 32px rgba(0,0,0,0.08);
  transform: translateY(-4px);
}
.card-img-wrap {
  aspect-ratio: 3/2;
  overflow: hidden;
}
.card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.55s var(--ease-std);
}
.blog-card:hover .card-img { transform: scale(1.05); }
.card-body {
  padding: 22px 24px 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}
.card-title {
  font-size: 17px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.2px;
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
}
.card-excerpt {
  font-size: 14px;
  color: var(--fg-muted);
  line-height: 1.55;
  flex: 1;
  margin: 0;
}

/* ══════════════════════════════════════════════════════
   LOAD MORE
══════════════════════════════════════════════════════ */
.blog-load-wrap {
  display: flex;
  justify-content: center;
}
.blog-card.hidden { display: none; }
.blog-card.visible { display: flex; }

/* ══════════════════════════════════════════════════════
   BLOG CTA BANNER
══════════════════════════════════════════════════════ */
.blog-cta {
  background: var(--ink);
  padding: 88px 24px;
  text-align: center;
}
.blog-cta-inner {
  max-width: 500px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}
.blog-cta h2 {
  font-size: 38px;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -1px;
  color: var(--paper);
  text-wrap: balance;
  margin: 0;
}
.blog-cta p {
  font-size: 16px;
  color: rgba(255,255,255,0.55);
  line-height: 1.5;
  margin: 0;
}
.blog-cta .btn-primary {
  background: var(--paper);
  color: var(--ink);
}
.blog-cta .btn-primary:hover { background: var(--grey-100); color: var(--ink); }

/* ══════════════════════════════════════════════════════
   ARTICLE HEADER
══════════════════════════════════════════════════════ */
.article-header {
  padding: 140px 24px 0;
  max-width: 760px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.article-breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--fg-muted);
}
.article-breadcrumb a { color: var(--fg-muted); }
.article-breadcrumb a:hover { color: var(--stur-purple); }
.article-breadcrumb-sep {
  font-size: 10px;
  color: var(--grey-300);
}
.article-title {
  font-size: 46px;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -1.5px;
  color: var(--ink);
  text-wrap: balance;
  margin: 0;
}
.article-sub {
  font-size: 19px;
  color: var(--fg-muted);
  line-height: 1.55;
  margin: 0;
}
.article-cover {
  display: block;
  width: 100%;
  max-width: 760px;
  margin: 40px auto 0;
  aspect-ratio: 16/8;
  object-fit: cover;
}

/* ══════════════════════════════════════════════════════
   ARTICLE BODY PROSE
══════════════════════════════════════════════════════ */
.article-prose {
  max-width: 680px;
  margin: 56px auto 0;
  padding: 0 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.article-prose p {
  font-size: 17px;
  line-height: 1.75;
  color: var(--ink-80);
  margin: 0;
}
.article-prose h2 {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.4px;
  color: var(--ink);
  margin: 16px 0 0;
}
.article-prose h3 {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.2px;
  color: var(--ink);
  margin: 12px 0 0;
}
.article-prose ul,
.article-prose ol {
  padding-left: 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 0;
}
.article-prose li {
  font-size: 17px;
  line-height: 1.7;
  color: var(--ink-80);
}
.article-prose blockquote {
  margin: 8px 0;
  padding: 20px 24px;
  border-left: 3px solid var(--stur-purple);
  background: var(--grey-50);
  border-radius: 0 var(--r-sm) var(--r-sm) 0;
}
.article-prose blockquote p {
  font-size: 19px;
  font-style: italic;
  color: var(--ink-60);
  line-height: 1.55;
}
.article-prose .article-img {
  width: 100%;
  border-radius: var(--r-ctrl);
  display: block;
}
.article-divider {
  border: none;
  border-top: 1px solid var(--ink-06);
  margin: 8px 0;
}

/* ══════════════════════════════════════════════════════
   ARTICLE FOOTER (share + tags)
══════════════════════════════════════════════════════ */
.article-footer {
  max-width: 680px;
  margin: 48px auto 80px;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.article-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.article-share {
  display: flex;
  align-items: center;
  gap: 10px;
}
.share-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--fg-muted);
}
.share-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1.5px solid var(--grey-300);
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--ink-60);
  transition: border-color var(--dur-fast) var(--ease-std),
              background var(--dur-fast) var(--ease-std),
              color var(--dur-fast) var(--ease-std);
  text-decoration: none;
}
.share-btn:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}
.share-btn svg { display: block; }

/* ══════════════════════════════════════════════════════
   RELATED POSTS
══════════════════════════════════════════════════════ */
.related-posts {
  padding: 80px 24px;
  background: var(--grey-50);
}
.related-inner {
  max-width: var(--content-max);
  margin: 0 auto;
}
.related-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 36px;
}
.related-head h2 {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.3px;
  margin: 0;
}
.related-head a {
  font-size: 14px;
  font-weight: 600;
  color: var(--stur-purple);
}
.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

/* ══════════════════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════════════════ */
@media (max-width: 1060px) {
  .blog-grid { grid-template-columns: repeat(2, 1fr); }
  .related-grid { grid-template-columns: repeat(2, 1fr); }
  .related-grid .blog-card:last-child { display: none; }
}

@media (max-width: 860px) {
  .blog-featured {
    grid-template-columns: 1fr;
    border-radius: var(--r-tile);
  }
  .featured-img-wrap { min-height: 260px; max-height: 320px; }
  .featured-body { padding: 28px 28px 32px; gap: 14px; }
  .featured-title { font-size: 24px; }
  .featured-excerpt { font-size: 15px; }

  .article-title { font-size: 34px; }
  .article-sub { font-size: 17px; }
}

@media (max-width: 640px) {
  .blog-hero { padding: 120px 20px 56px; }
  .blog-hero h1 { font-size: 61px; line-height: 57px; letter-spacing: -1.5px; }
  .blog-hero-sub { font-size: 15px; }
  .blog-cats { gap: 6px; }
  .blog-cat { height: 32px; padding: 0 14px; font-size: 12px; }

  .blog-main { padding: 48px 16px 72px; }
  .blog-container { gap: 48px; }
  .blog-grid { grid-template-columns: 1fr; }
  .related-grid { grid-template-columns: 1fr; }
  .related-grid .blog-card:last-child { display: flex; }

  .blog-cta { padding: 64px 24px; }
  .blog-cta h2 { font-size: 28px; }

  .article-header { padding: 120px 20px 0; }
  .article-cover { aspect-ratio: 4/3; margin: 28px auto 0; }
  .article-title { font-size: 28px; letter-spacing: -0.75px; }
  .article-prose p,
  .article-prose li { font-size: 16px; }
  .article-prose h2 { font-size: 22px; }
  .article-prose blockquote p { font-size: 17px; }
  .article-footer { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 400px) {
  .blog-hero h1 { font-size: 48px; line-height: 46px; letter-spacing: -1.5px; }
  .article-title { font-size: 24px; }
}
