/* ── Blog Page Hero ─────────────────────────────────────── */
.blog-page-hero {
  position: relative;
  background: var(--cream);
  background-color:var(--sdg-6);
  padding: 9rem 5vw 5rem;
  width: 100%;
  overflow: hidden;
  border-bottom-left-radius: 40px;
  border-bottom-right-radius: 40px;
  margin-bottom: 0;

  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

/* Content */
.blog-hero-content {
  position: relative;
  z-index: 3;
  max-width: 760px;
  width: 100%;
}

.blog-hero-content .hero-badge {
  display: inline-block;
  background: rgba(30, 127, 110, 0.1);
  color: var(--teal-mid);
  padding: 0.4rem 1.2rem;
  border-radius: 30px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
  border: 1px solid rgba(30, 127, 110, 0.2);
}

.blog-hero-content h1 {
  font-size: clamp(3rem, 6vw, 5rem);
  color: var(--charcoal);
  margin-bottom: 1rem;
  line-height: 1.1;
}

.blog-hero-content p {
  color: var(--slate-light);
  font-size: 1.05rem;
  line-height: 1.8;
  max-width: 650px;
  margin: 0 auto;
}

/* Decorative Shapes Behind */
.blog-hero-deco {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

/* Shapes */
.deco-leaf {
  position: absolute;
  border-radius: 50% 0 50% 0;
  filter: blur(1px);
}

.deco-leaf-1 {
  width: 140px;
  height: 140px;
  background: rgba(30, 127, 110, 0.12);
  top: 20%;
  left: 32%;
  transform: rotate(-20deg);
}

.deco-leaf-2 {
  width: 100px;
  height: 100px;
  background: rgba(217, 122, 92, 0.12);
  bottom: 20%;
  right: 32%;
  transform: rotate(30deg);
}

.deco-ring-hero {
  position: absolute;
  width: 220px;
  height: 220px;
  border: 2px solid rgba(15, 76, 92, 0.12);
  border-radius: 50%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.deco-dot-h1 {
  position: absolute;
  width: 16px;
  height: 16px;
  background: var(--teal-deep);
  border-radius: 50%;
  top: 28%;
  left: 58%;
}

.deco-dot-h2 {
  position: absolute;
  width: 10px;
  height: 10px;
  background: var(--terracotta);
  border-radius: 50%;
  bottom: 30%;
  left: 40%;
}

/* Mobile */
@media (max-width: 900px) {
  .blog-page-hero {
    padding: 8rem 5vw 4rem;
  }

  .blog-hero-content h1 {
    font-size: 3rem;
  }

  .deco-ring-hero {
    width: 170px;
    height: 170px;
  }
}

/* ── Toolbar (search + count) ────────────────────────────── */
.blog-toolbar {
  background: var(--white);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  padding: 1rem 0;
  position: sticky;
  top: 7rem;
  z-index: 100;
}

.toolbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.search-wrap {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--cream);
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 30px;
  padding: 0.45rem 1rem;
  flex: 1;
  max-width: 400px;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.search-wrap:focus-within {
  border-color: var(--teal-mid);
  box-shadow: 0 0 0 3px rgba(30, 127, 110, 0.1);
}

.search-icon { color: var(--slate-light); display: flex; }

.search-wrap input {
  border: none;
  background: transparent;
  outline: none;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  color: var(--slate);
  width: 100%;
}

.search-wrap input::placeholder { color: rgba(74, 91, 110, 0.55); }

.post-count {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--slate-light);
  white-space: nowrap;
  flex-shrink: 0;
}

/* ── Section header row (used in accomplishments) ───────── */
.section-header-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.section-header-tools {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  flex-shrink: 0;
}

.section-header-tools .search-wrap {
  max-width: 260px;
}

/* ── Filter Pills ────────────────────────────────────────── */
.filter-section {
  background: var(--white);
  padding: 0.75rem 0 1rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.filter-bar-scroll {
  overflow-x: auto;
  padding-bottom: 4px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.filter-bar-scroll::-webkit-scrollbar { display: none; }

.filter-bar {
  display: flex;
  gap: 0.5rem;
  flex-wrap: nowrap;
  white-space: nowrap;
  min-width: max-content;
}

.filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.42rem 1rem;
  border-radius: 30px;
  border: 1.5px solid rgba(15, 76, 92, 0.2);
  background: transparent;
  color: var(--slate);
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
  flex-shrink: 0;
}

.filter-btn:hover {
  border-color: var(--teal-mid);
  color: var(--teal-deep);
  background: rgba(30, 127, 110, 0.05);
}

.filter-btn.active {
  background: var(--teal-deep);
  border-color: var(--teal-deep);
  color: var(--white);
  box-shadow: 0 2px 10px rgba(15, 76, 92, 0.25);
}

/* ── Blog Grid ────────────────────────────────────────────  */
.blog-section {
  padding: 3rem 0 5rem;
  background: var(--cream);
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 1.75rem;
  margin-top: 1.5rem;
}

/* ── Blog Card ─────────────────────────────────────────── */
.b-card {
  background: var(--white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  position: relative;
}

.b-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.b-card-img {
  height: 190px;
  overflow: hidden;
  background: var(--cream);
  position: relative;
}

.b-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.b-card:hover .b-card-img img {
  transform: scale(1.05);
}

.b-card-body {
  padding: 1.35rem 1.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.b-tag {
  display: inline-block;
  background: rgba(244, 228, 193, 0.7);
  color: var(--teal-deep);
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.22rem 0.7rem;
  border-radius: 20px;
  margin-bottom: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  align-self: flex-start;
}

.b-card-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.05rem;
  color: var(--charcoal);
  line-height: 1.45;
  margin-bottom: 0.65rem;
}

.b-excerpt {
  font-size: 0.87rem;
  color: var(--slate-light);
  line-height: 1.65;
  flex: 1;
  margin-bottom: 1.2rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.b-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  padding-top: 0.85rem;
}

.b-date {
  font-size: 0.78rem;
  color: var(--slate-light);
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.b-read-time {
  font-size: 0.78rem;
  color: var(--slate-light);
}

.b-read-more {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--teal-deep);
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  transition: gap 0.2s;
}

.b-card:hover .b-read-more { gap: 0.55rem; }

/* ── Skeleton loading ──────────────────────────────────── */
.b-skeleton {
  background: var(--white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.skeleton-img {
  height: 190px;
  background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

.skeleton-body { padding: 1.35rem 1.5rem; }

.skeleton-line {
  height: 12px;
  border-radius: 6px;
  background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  margin-bottom: 0.75rem;
}

.skeleton-line.short { width: 45%; }
.skeleton-line.medium { width: 70%; }
.skeleton-line.long { width: 90%; }

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ── Empty / Error States ─────────────────────────────── */
.blog-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 5rem 2rem;
  color: var(--slate-light);
}

.blog-empty h3 {
  font-size: 1.5rem;
  margin-bottom: 0.75rem;
  color: var(--charcoal);
}

.blog-empty p { font-size: 1rem; }

/* ── Pagination ─────────────────────────────────────────── */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  margin-top: 3rem;
  flex-wrap: wrap;
}

.page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  height: 38px;
  padding: 0 0.6rem;
  border-radius: 10px;
  border: 1.5px solid rgba(15, 76, 92, 0.18);
  background: var(--white);
  color: var(--slate);
  font-family: 'Inter', sans-serif;
  font-size: 0.87rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: var(--shadow-sm);
}

.page-btn:hover:not(:disabled) {
  border-color: var(--teal-mid);
  color: var(--teal-deep);
  background: rgba(30, 127, 110, 0.04);
}

.page-btn.active {
  background: var(--teal-deep);
  border-color: var(--teal-deep);
  color: var(--white);
  box-shadow: 0 3px 12px rgba(15, 76, 92, 0.25);
}

.page-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.page-ellipsis {
  padding: 0 0.3rem;
  color: var(--slate-light);
  font-size: 0.9rem;
  letter-spacing: 0.1em;
}

/* ── Post Page ──────────────────────────────────────────── */
.post-main {
  padding: 8rem 0 5rem;
  min-height: 60vh;
}

.post-container {
  max-width: 780px;
  margin: 0 auto;
}

.post-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--teal-deep);
  background: rgba(15, 76, 92, 0.06);
  padding: 0.55rem 1.1rem;
  border-radius: 30px;
  margin-bottom: 2.5rem;
  transition: all 0.2s;
  text-decoration: none;
}

.post-back-btn:hover {
  background: rgba(15, 76, 92, 0.12);
  gap: 0.75rem;
}

.post-cats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.2rem;
}

.post-cat-tag {
  display: inline-block;
  background: rgba(244, 228, 193, 0.8);
  color: var(--teal-deep);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
}

.post-title {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  color: var(--charcoal);
  line-height: 1.25;
  margin-bottom: 1.2rem;
}

.post-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  flex-wrap: wrap;
}

.post-meta-main {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.author-img {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--cream);
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.post-meta-text {
  display: flex;
  flex-direction: column;
}

.author-name {
  font-weight: 700;
  color: var(--teal-deep);
  font-size: 0.95rem;
}

.post-dates {
  font-size: 0.8rem;
  color: var(--slate-light);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.post-meta-dot {
  width: 3px;
  height: 3px;
  background: var(--slate-light);
  border-radius: 50%;
  opacity: 0.5;
}

.post-metrics {
  display: flex;
  gap: 1rem;
  color: var(--slate-light);
  font-size: 0.8rem;
  font-weight: 500;
}

.post-metrics span {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.post-hero-img {
  width: 100%;
  height: 380px;
  object-fit: cover;
  border-radius: var(--radius-md);
  margin-bottom: 2.5rem;
  box-shadow: var(--shadow-md);
}

.post-excerpt {
  font-size: 1.2rem;
  color: var(--slate);
  line-height: 1.8;
  font-style: italic;
  border-left: 4px solid var(--teal-mid);
  padding-left: 1.25rem;
  margin-bottom: 2rem;
}

.post-body {
  font-size: 1.1rem;
  color: var(--charcoal);
  line-height: 1.8;
  font-family: 'Inter', sans-serif;
}

/* Rich Content Node Styles */
.rich-p { margin-bottom: 1.5rem; }
.rich-p.center { text-align: center; }
.rich-p.right { text-align: right; }

.rich-h2, .rich-h3, .rich-h4 {
  color: var(--teal-deep);
  font-family: 'Playfair Display', serif;
  margin: 2.5rem 0 1.2rem;
  line-height: 1.3;
}

.rich-h2 { font-size: 1.8rem; font-weight: 800; border-bottom: 2px solid var(--gold); display: inline-block; padding-bottom: 5px; margin-bottom: 1.5rem; }
.rich-h3 { font-size: 1.5rem; font-weight: 700; }

.rich-img {
  margin: 2.5rem 0;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.rich-img img {
  width: 100%;
  display: block;
}

.rich-img figcaption {
  padding: 0.75rem 1rem;
  background: #f9f9f9;
  font-size: 0.85rem;
  color: var(--slate-light);
  font-style: italic;
  text-align: center;
}

.rich-video {
  margin: 2.5rem 0;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  position: relative;
  padding-bottom: 56.25%; /* 16:9 */
  height: 0;
}

.rich-video iframe, .rich-video video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.rich-ul, .rich-ol {
  margin: 1.5rem 0;
  padding-left: 1.5rem;
}

.rich-ul li, .rich-ol li {
  margin-bottom: 0.75rem;
}

.post-body a {
  color: var(--teal-mid);
  text-decoration: underline;
  text-decoration-color: var(--gold);
  text-underline-offset: 4px;
  font-weight: 600;
}

.post-body a:hover {
  color: var(--teal-deep);
  text-decoration-color: var(--teal-mid);
}

.post-body strong {
  color: var(--teal-deep);
  font-weight: 700;
}

.post-external-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 2rem;
  padding: 0.8rem 2rem;
  background: var(--teal-deep);
  color: var(--white);
  border-radius: var(--radius-btn);
  font-weight: 700;
  font-size: 0.9rem;
  transition: background 0.2s, transform 0.2s;
  text-decoration: none;
}

.post-external-btn:hover {
  background: var(--teal-mid);
  transform: translateY(-2px);
}

/* Post Skeleton */
.post-skeleton { max-width: 780px; margin: 0 auto; padding: 2rem 0; }
.post-skeleton .sk-title { height: 42px; margin-bottom: 1rem; border-radius: 8px; }
.post-skeleton .sk-meta { height: 14px; width: 50%; margin-bottom: 2rem; border-radius: 6px; }
.post-skeleton .sk-img { height: 380px; border-radius: var(--radius-md); margin-bottom: 2rem; }
.post-skeleton .sk-body { height: 14px; border-radius: 6px; margin-bottom: 0.8rem; }
.post-skeleton .sk-body.w80 { width: 80%; }
.post-skeleton .sk-body.w70 { width: 70%; }

.post-skeleton .sk-title,
.post-skeleton .sk-meta,
.post-skeleton .sk-img,
.post-skeleton .sk-body {
  background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

/* ── Related Posts ────────────────────────────────────── */
.related-section {
  padding: 4rem 0 5rem;
  background: var(--cream);
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 1.5rem;
}

@media (max-width: 800px) {
  .related-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 540px) {
  .related-grid { grid-template-columns: 1fr; }
}

/* ── Responsive Blog Grid ───────────────────────────── */
@media (max-width: 900px) {
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

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

  .blog-toolbar {
    top: 5rem;
  }

  .toolbar-inner {
    flex-direction: column;
    align-items: stretch;
  }

  .search-wrap {
    max-width: 100%;
  }

  .post-hero-img { height: 230px; }

  .post-main { padding: 6.5rem 0 4rem; }
}

.post-share-bar {
  display: flex;
  gap: 1rem;
  padding: 2rem 0;
  margin-top: 3rem;
  border-top: 1px solid rgba(0,0,0,0.06);
}

.share-icon {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #f5f5f5;
  color: var(--charcoal);
  text-decoration: none;
  font-weight: 700;
  transition: all 0.2s;
  font-size: 1rem;
}

.share-icon:hover {
  background: var(--teal-deep);
  color: var(--white);
  transform: translateY(-3px);
}

/* Rich File Card */
.rich-file-card {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 1.25rem;
  background: #fcfcfc;
  border: 1px solid #eee;
  border-radius: 8px;
  margin: 2rem 0;
  transition: border-color 0.2s;
}

.rich-file-card:hover {
  border-color: var(--teal-mid);
}

.file-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f0f0f0;
  border-radius: 6px;
  color: var(--teal-deep);
}

.file-info {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.file-name {
  font-weight: 600;
  color: var(--charcoal);
  font-size: 0.95rem;
  margin-bottom: 2px;
}

.file-meta {
  font-size: 0.8rem;
  color: var(--slate-light);
}

.file-download {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--slate-light);
  border-radius: 50%;
  transition: background 0.2s, color 0.2s;
}

.file-download:hover {
  background: var(--teal-deep);
  color: var(--white);
}
