/* ============================================================
   ALAM SIR CLASSES — BLOG STYLESHEET
   css/blog.css
   Depends on: css/style.css (must load first)
   ============================================================ */

/* ============================================================
   LAYOUT UTILITIES
   ============================================================ */
.blog-container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 40px;
}

/* Narrow container for article body */
.blog-container--narrow {
  max-width: 760px;
}

/* ============================================================
   BADGES — category labels on cards
   Usage: <span class="blog-badge blog-badge--career">
   ============================================================ */
.blog-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 12px;
  border-radius: 50px;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

.blog-badge--career {
  background: var(--orange-light);
  color: var(--orange-dark);
  border: 1.5px solid var(--orange-border);
}

.blog-badge--exam {
  background: var(--blue-light);
  color: var(--blue-dark);
  border: 1.5px solid var(--blue-border);
}

.blog-badge--govt {
  background: var(--green-light);
  color: var(--green-dark);
  border: 1.5px solid #A8EDD0;
}

/* ============================================================
   BREADCRUMB
   ============================================================ */
.blog-breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.blog-breadcrumb a {
  color: var(--orange);
  font-weight: 600;
  transition: opacity 0.2s;
}

.blog-breadcrumb a:hover { opacity: 0.7; }

/* ============================================================
   BLOG HERO (index.html)
   ============================================================ */
.blog-hero {
  background: linear-gradient(150deg, #FFF8F0 0%, #EBF4FF 55%, #F0FFF8 100%);
  padding: 72px 40px 64px;
  border-bottom: 2px solid var(--border);
  position: relative;
  overflow: hidden;
}

.blog-hero::before {
  content: '';
  position: absolute;
  width: 480px; height: 480px;
  background: radial-gradient(circle, rgba(255,107,53,0.10) 0%, transparent 70%);
  top: -200px; right: -100px;
  border-radius: 50%;
  pointer-events: none;
}

.blog-hero__inner {
  max-width: 640px;
  position: relative;
  animation: fadeUp 0.65s ease both;
}

.blog-hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--yellow-light);
  color: #7A5800;
  font-size: 13px;
  font-weight: 700;
  padding: 6px 16px;
  border-radius: 50px;
  border: 1.5px solid #FFE680;
  margin-bottom: 20px;
}

.blog-hero__title {
  font-family: var(--font-display);
  font-size: 48px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.15;
  margin-bottom: 14px;
}

.blog-hero__desc {
  font-size: 17px;
  color: var(--text-muted);
  line-height: 1.7;
}

.blog-hero__decor {
  position: absolute;
  right: 60px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 16px;
  font-size: 52px;
  opacity: 0.18;
  pointer-events: none;
  animation: fadeUp 0.65s 0.15s ease both;
}

/* ============================================================
   FEATURED POST (index.html)
   ============================================================ */
.blog-featured-wrap {
  padding: 56px 0 0;
  background: var(--white);
}

.blog-featured {
  display: block;
  background: linear-gradient(135deg, #FFF5EE, #EBF4FF);
  border: 2px solid var(--orange-border);
  border-radius: var(--radius-xl);
  padding: 36px 40px;
  text-decoration: none;
  color: inherit;
  transition: transform 0.22s, box-shadow 0.22s;
  position: relative;
  overflow: hidden;
}

.blog-featured::before {
  content: '⭐ Featured';
  position: absolute;
  top: 20px; right: 24px;
  background: var(--yellow);
  color: var(--text);
  font-size: 12px;
  font-weight: 800;
  padding: 4px 14px;
  border-radius: 50px;
}

.blog-featured:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.blog-featured__meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.blog-featured__date {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 600;
}

.blog-featured__title {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.25;
  margin-bottom: 12px;
}

.blog-featured__excerpt {
  font-size: 16px;
  color: var(--text-muted);
  line-height: 1.7;
  max-width: 680px;
  margin-bottom: 20px;
}

.blog-featured__cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  font-size: 15px;
  color: var(--orange);
  transition: gap 0.2s;
}

.blog-featured:hover .blog-featured__cta { gap: 10px; }

/* ============================================================
   CATEGORY CARDS (index.html)
   ============================================================ */
.blog-categories-section {
  padding: 64px 40px 80px;
  background: var(--white);
}

.blog-categories__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  max-width: 1080px;
  margin: 0 auto;
}

.blog-cat-card {
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-xl);
  padding: 28px 24px 22px;
  border: 2px solid transparent;
  text-decoration: none;
  color: inherit;
  transition: transform 0.22s, box-shadow 0.22s;
  gap: 16px;
}

.blog-cat-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.blog-cat-card--career {
  background: var(--orange-light);
  border-color: var(--orange-border);
}

.blog-cat-card--exams {
  background: var(--blue-light);
  border-color: var(--blue-border);
}

.blog-cat-card--govt {
  background: var(--green-light);
  border-color: #A8EDD0;
}

.blog-cat-card__icon {
  font-size: 42px;
  line-height: 1;
}

.blog-cat-card__body {
  flex: 1;
}

.blog-cat-card__title {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 8px;
}

.blog-cat-card__desc {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 14px;
}

.blog-cat-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.blog-cat-card__tags span {
  background: rgba(255,255,255,0.6);
  border: 1.5px solid rgba(0,0,0,0.07);
  border-radius: 50px;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  color: var(--text);
}

.blog-cat-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  border-top: 1.5px solid rgba(0,0,0,0.06);
}

.blog-cat-card__count {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
}

.blog-cat-card__arrow {
  font-size: 18px;
  color: var(--text-muted);
  transition: transform 0.2s, color 0.2s;
}

.blog-cat-card:hover .blog-cat-card__arrow {
  transform: translateX(5px);
  color: var(--orange);
}

/* ============================================================
   RECENT POSTS SECTION
   ============================================================ */
.blog-recent-section {
  padding: 64px 40px 80px;
  background: var(--bg);
}

/* ============================================================
   BLOG CARDS GRID — shared across all pages
   ============================================================ */
.blog-cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.blog-cards-grid--3 {
  grid-template-columns: repeat(3, 1fr);
}

.blog-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1.5px solid var(--border);
  box-shadow: var(--shadow-sm);
  text-decoration: none;
  color: inherit;
  overflow: hidden;
  transition: transform 0.22s, box-shadow 0.22s;
}

.blog-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

/* Thumbnail / header strip */
.blog-card__thumb {
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 44px;
  flex-shrink: 0;
}

.blog-card__thumb--orange { background: linear-gradient(135deg, #FFE8D5, #FFD0B0); }
.blog-card__thumb--blue   { background: linear-gradient(135deg, #D5EEFF, #B0CEFF); }
.blog-card__thumb--green  { background: linear-gradient(135deg, #D5FFE8, #A8EDD0); }
.blog-card__thumb--yellow { background: linear-gradient(135deg, #FFFAD5, #FFE0A0); }
.blog-card__thumb--pink   { background: linear-gradient(135deg, #FFD5E8, #FFB0CC); }
.blog-card__thumb--purple { background: linear-gradient(135deg, #EDD5FF, #C8B0FF); }

.blog-card__body {
  padding: 20px 18px 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.blog-card__title {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.35;
}

.blog-card__excerpt {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.65;
  flex: 1;
}

.blog-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 12px;
  border-top: 1.5px solid var(--border);
  margin-top: auto;
}

.blog-card__date {
  font-size: 12px;
  color: var(--text-light);
  font-weight: 600;
}

.blog-card__read {
  font-size: 12px;
  font-weight: 700;
  color: var(--orange);
  transition: gap 0.2s;
}

/* ============================================================
   CATEGORY HERO (category-template.html)
   ============================================================ */
.blog-cat-hero {
  background: linear-gradient(150deg, #FFF8F0, #EBF4FF);
  padding: 56px 40px 52px;
  border-bottom: 2px solid var(--border);
}

.blog-cat-hero__inner {
  display: flex;
  align-items: center;
  gap: 24px;
  max-width: 1080px;
  margin: 0 auto;
  animation: fadeUp 0.6s ease both;
}

.blog-cat-hero__icon {
  font-size: 64px;
  flex-shrink: 0;
  line-height: 1;
}

.blog-cat-hero__title {
  font-family: var(--font-display);
  font-size: 38px;
  font-weight: 800;
  color: var(--text);
  margin: 8px 0 6px;
  line-height: 1.2;
}

.blog-cat-hero__desc {
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.7;
  max-width: 560px;
}

/* ============================================================
   FILTER BAR (category-template.html)
   ============================================================ */
.blog-filter-section {
  background: var(--white);
  padding: 24px 40px;
  border-bottom: 2px solid var(--border);
  position: sticky;
  top: 74px;  /* matches navbar height */
  z-index: 90;
}

.blog-filter-bar {
  max-width: 1080px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

/* Search input */
.blog-search {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg);
  border: 2px solid var(--border);
  border-radius: 50px;
  padding: 9px 18px;
  flex: 1;
  min-width: 180px;
  max-width: 320px;
  transition: border-color 0.2s;
}

.blog-search:focus-within {
  border-color: var(--orange);
  background: var(--white);
}

.blog-search__icon { font-size: 15px; color: var(--text-muted); flex-shrink: 0; }

.blog-search__input {
  border: none;
  background: transparent;
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--text);
  outline: none;
  width: 100%;
}

.blog-search__input::placeholder { color: var(--text-light); }

/* Tag filter buttons */
.blog-tags {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.blog-tag {
  padding: 7px 16px;
  border-radius: 50px;
  border: 2px solid var(--border);
  background: var(--bg);
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.blog-tag:hover {
  border-color: var(--orange-border);
  color: var(--orange);
  background: var(--orange-light);
}

.blog-tag--active {
  background: var(--orange);
  border-color: var(--orange);
  color: var(--white);
}

/* ============================================================
   ARTICLES LIST SECTION (category-template.html)
   ============================================================ */
.blog-list-section {
  padding: 44px 40px 64px;
  background: var(--bg);
}

.blog-results-count {
  font-size: 14px;
  color: var(--text-muted);
  font-weight: 600;
  margin-bottom: 24px;
}

/* ============================================================
   PAGINATION (category-template.html)
   ============================================================ */
.blog-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 48px;
  flex-wrap: wrap;
}

.blog-pagination__btn {
  padding: 9px 18px;
  border-radius: 50px;
  border: 2px solid var(--border);
  background: var(--white);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
}

.blog-pagination__btn:hover:not([disabled]) {
  border-color: var(--orange);
  color: var(--orange);
  background: var(--orange-light);
}

.blog-pagination__btn[disabled] {
  opacity: 0.4;
  cursor: not-allowed;
}

.blog-pagination__pages {
  display: flex;
  align-items: center;
  gap: 6px;
}

.blog-pagination__page {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 2px solid var(--border);
  background: var(--white);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.blog-pagination__page:hover {
  border-color: var(--orange);
  color: var(--orange);
}

.blog-pagination__page--active {
  background: var(--orange);
  border-color: var(--orange);
  color: var(--white);
}

/* ============================================================
   ARTICLE HERO (article-template.html)
   ============================================================ */
.article-hero {
  background: linear-gradient(150deg, #FFF8F0, #EBF4FF);
  padding: 56px 40px 48px;
  border-bottom: 2px solid var(--border);
  text-align: center;
}

.article-hero__badge {
  font-size: 54px;
  display: block;
  margin-bottom: 16px;
  animation: fadeUp 0.5s ease both;
}

.article-hero .blog-badge {
  margin-bottom: 16px;
  display: inline-flex;
}

.article-hero__title {
  font-family: var(--font-display);
  font-size: 40px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.2;
  margin: 14px 0 20px;
  animation: fadeUp 0.55s 0.05s ease both;
}

.article-hero__meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  animation: fadeUp 0.55s 0.1s ease both;
}

.article-hero__meta-item {
  font-size: 14px;
  color: var(--text-muted);
  font-weight: 600;
}

.article-hero__meta-sep {
  color: var(--border);
  font-size: 16px;
}

/* ============================================================
   ARTICLE THUMBNAIL / BANNER
   ============================================================ */
.article-thumb {
  display: block;
  width: 100%;
  border-radius: var(--radius-xl);
  margin: 32px auto;
  max-height: 380px;
  object-fit: cover;
}

.article-thumb--placeholder {
  background: linear-gradient(135deg, #FFF5EE, #EBF4FF);
  border: 2px solid var(--border);
  height: 260px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
}

.article-thumb__emoji { font-size: 72px; line-height: 1; }

.article-thumb__label {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ============================================================
   ARTICLE BODY CONTENT
   ============================================================ */
.article-body-wrap {
  padding: 0 40px 48px;
}

.article-body {
  font-size: 16.5px;
  line-height: 1.85;
  color: var(--text);
}

.article-body p {
  margin-bottom: 22px;
}

.article-body h2 {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 800;
  color: var(--text);
  margin: 36px 0 14px;
  padding-top: 8px;
}

.article-body h3 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  margin: 24px 0 10px;
}

.article-body ul,
.article-body ol {
  padding-left: 24px;
  margin-bottom: 22px;
  list-style: disc;
}

.article-body ol { list-style: decimal; }

.article-body ul li,
.article-body ol li {
  margin-bottom: 8px;
  color: var(--text-muted);
}

.article-body strong { color: var(--text); font-weight: 700; }
.article-body em     { color: var(--text); font-style: italic; }

/* Quote / tip block */
.article-quote {
  background: var(--yellow-light);
  border-left: 4px solid var(--yellow-dark);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 16px 20px;
  margin: 24px 0;
  font-size: 15px;
  color: #6B4E00;
  line-height: 1.7;
}

/* Coloured highlight box */
.article-highlight {
  border-radius: var(--radius);
  padding: 18px 22px;
  margin: 24px 0;
  font-size: 15px;
  line-height: 1.7;
}

.article-highlight--blue {
  background: var(--blue-light);
  color: var(--blue-dark);
  border: 1.5px solid var(--blue-border);
}

.article-highlight--orange {
  background: var(--orange-light);
  color: var(--orange-dark);
  border: 1.5px solid var(--orange-border);
}

.article-highlight--green {
  background: var(--green-light);
  color: var(--green-dark);
  border: 1.5px solid #A8EDD0;
}

/* Author block */
.article-author {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 40px;
  padding-top: 28px;
  border-top: 2px solid var(--border);
}

.article-author__avatar {
  width: 54px;
  height: 54px;
  background: var(--orange-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  flex-shrink: 0;
  border: 2px solid var(--orange-border);
}

.article-author__name {
  display: block;
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 3px;
}

.article-author__role {
  font-size: 13px;
  color: var(--text-muted);
}

/* ============================================================
   STUDY MATERIAL CTA (article-template.html)
   ============================================================ */
.article-resources-cta {
  padding: 0 40px 48px;
}

.article-resources-cta__inner {
  background: linear-gradient(135deg, #FFF5EE, #EBF4FF);
  border: 2px solid var(--orange-border);
  border-radius: var(--radius-xl);
  padding: 32px 36px;
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

.article-resources-cta__icon {
  font-size: 52px;
  flex-shrink: 0;
}

.article-resources-cta__body {
  flex: 1;
  min-width: 200px;
}

.article-resources-cta__body h3 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 6px;
}

.article-resources-cta__body p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 14px;
}

.article-resources-cta__pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.article-resources-cta__pills span {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: 50px;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text);
}

/* ============================================================
   RELATED ARTICLES SECTION
   ============================================================ */
.article-related-section {
  padding: 48px 40px 64px;
  background: var(--bg);
}

.article-related__heading {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 28px;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 960px) {
  .blog-categories__grid { grid-template-columns: 1fr; gap: 18px; }
  .blog-cards-grid       { grid-template-columns: repeat(2, 1fr); }
  .blog-cards-grid--3    { grid-template-columns: repeat(2, 1fr); }

  .blog-cat-hero__inner { flex-direction: column; gap: 16px; text-align: center; }
  .blog-cat-hero__icon  { font-size: 52px; }

  .blog-hero__decor { display: none; }

  .article-resources-cta__inner { flex-direction: column; gap: 20px; }
}

@media (max-width: 640px) {
  .blog-hero    { padding: 52px 20px 44px; }
  .blog-hero__title { font-size: 34px; }

  .blog-container { padding: 0 20px; }
  .blog-cat-hero  { padding: 44px 20px; }

  .blog-featured  { padding: 24px 20px; }
  .blog-featured__title { font-size: 22px; }

  .blog-categories-section { padding: 48px 20px; }
  .blog-recent-section     { padding: 48px 20px 56px; }

  .blog-cards-grid    { grid-template-columns: 1fr; }
  .blog-cards-grid--3 { grid-template-columns: 1fr; }

  .blog-filter-section { padding: 18px 20px; top: 68px; }
  .blog-filter-bar     { gap: 12px; }
  .blog-search         { max-width: 100%; }

  .blog-list-section  { padding: 32px 20px 48px; }

  .article-hero       { padding: 44px 20px 36px; }
  .article-hero__title { font-size: 28px; }
  .article-body-wrap  { padding: 0 20px 40px; }
  .article-resources-cta { padding: 0 20px 40px; }
  .article-related-section { padding: 40px 20px 56px; }
}
