/*
  Wizard HR Blog — blog.css
  Blog-specific styles using Wizard HR brand tokens.
  Used on blog index + article pages.
*/

/* --------------------------------------------------
   Design Tokens (Wizard HR brand)
-------------------------------------------------- */
:root {
  --brand-blue: #1a1952;
  --accent-yellow: #d8b664;
  --bg-light-gray: #f9f9f9;
  --bg-light-blue: #eef0f8;
  --text-dark: #1a1952;
  --text-gray: #444;
  --text-body: #333;

  /* Surfaces */
  --surface-0: #ffffff;
  --surface-1: #fbfbfb;

  /* Borders */
  --border: rgba(0,0,0,0.08);
  --border-default: rgba(0,0,0,0.12);
  --border-muted: rgba(0,0,0,0.06);

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.06);

  /* Layout */
  --header-h: 60px;
  --site-header-offset: 64px;
  --details-bar-h: 58px;
}

/* --------------------------------------------------
   Base
-------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'Nunito', sans-serif;
  color: var(--text-body);
  background: var(--bg-light-blue);
}

/* --------------------------------------------------
   Container / Section
-------------------------------------------------- */
.container {
  width: min(1180px, 92vw);
  margin-inline: auto;
}

.section {
  padding: 56px 0;
}

/* --------------------------------------------------
   Blog Intro (index page)
-------------------------------------------------- */
.blog-intro-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  column-gap: 24px;
  align-items: start;
}

.blog-intro-text h2 {
  margin-top: 0;
  margin-bottom: 0;
  color: var(--brand-blue);
}

.page-subtitle {
  color: var(--text-gray);
  line-height: 1.6;
}

.page--blog-index .container {
  max-width: 1100px;
}

.page--blog-index .section--intro .container {
  max-width: 1100px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  column-gap: 24px;
  align-items: start;
}

.page--blog-index .section--posts {
  padding-top: 0;
}

@media (max-width: 900px) {
  .blog-intro-grid {
    grid-template-columns: 1fr;
    row-gap: 14px;
  }
  .page--blog-index .section--intro .container {
    grid-template-columns: 1fr;
    row-gap: 14px;
  }
  .page--blog-index .posts-toolbar {
    justify-self: start;
    max-width: none;
    justify-content: flex-start;
    padding-top: 0;
  }
}

@media (max-width: 560px) {
  .page--blog-index .section--intro {
    padding-bottom: 16px;
  }
  .page--blog-index .section--posts {
    padding-top: 0;
  }
  .page--blog-index .posts-grid--2 {
    gap: 14px;
  }
}

/* --------------------------------------------------
   Posts Grid
-------------------------------------------------- */
.posts-grid--2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.page--blog-index .posts-grid--2 {
  gap: 20px;
}

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

/* --------------------------------------------------
   Posts Toolbar
-------------------------------------------------- */
.posts-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
  max-width: 520px;
  padding-top: 6px;
}

.page--blog-index .posts-toolbar {
  justify-self: end;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  max-width: 520px;
  justify-content: flex-end;
  padding-top: 6px;
  align-items: center;
}

@media (max-width: 900px) {
  .posts-toolbar {
    justify-content: flex-start;
    max-width: none;
    padding-top: 0;
  }
}

@media (max-width: 560px) {
  .page--blog-index .posts-toolbar {
    max-width: none;
    justify-content: flex-start;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 6px;
    gap: 10px;
    scrollbar-width: none;
  }
  .page--blog-index .posts-toolbar::-webkit-scrollbar {
    display: none;
  }
  .page--blog-index .label-pill {
    flex: 0 0 auto;
    font-size: 0.88rem;
    padding: 8px 11px;
  }
  #postsToolbar.posts-toolbar {
    display: flex !important;
    justify-content: flex-end;
    overflow: visible !important;
    padding-bottom: 0 !important;
  }
  #postsToolbar .label-pill {
    display: none !important;
  }
}

/* --------------------------------------------------
   Filters Trigger + Drawer
-------------------------------------------------- */
.filters-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  line-height: 1;
  font-weight: 600;
  font-family: 'Nunito', sans-serif;
  background: #fff;
  border: 1px solid rgba(26,25,82,.12);
  box-shadow: 0 1px 0 rgba(26,25,82,.06);
  cursor: pointer;
  border-radius: 999px;
  position: relative;
  color: var(--brand-blue);
}

.filters-trigger:active {
  transform: translateY(1px);
}

.filters-trigger:focus-visible {
  outline: 2px solid var(--accent-yellow);
  outline-offset: 2px;
}

.filters-trigger::after {
  content: "\25BE";
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-52%);
  font-size: .85em;
  opacity: .55;
  pointer-events: none;
}

@media (max-width: 560px) {
  .filters-trigger {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    border: 1px solid rgba(26,25,82,.12);
    background: transparent;
  }
}

.filters-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.35);
  z-index: 80;
  backdrop-filter: blur(2px);
}

.filters-drawer {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 90;
  background: #fff;
  border-top-left-radius: 16px;
  border-top-right-radius: 16px;
  transform: translateY(100%);
  transition: transform 280ms ease;
  display: flex;
  flex-direction: column;
  max-height: min(82vh, 720px);
  overflow: hidden;
}

.filters-drawer.is-open {
  transform: translateY(0);
}

.filters-drawer__handle {
  width: 36px;
  height: 4px;
  border-radius: 2px;
  background: rgba(26,25,82,.12);
  margin: 8px auto 4px;
}

.filters-drawer__header {
  padding: 12px 16px;
  border-bottom: 1px solid rgba(26,25,82,.08);
  position: sticky;
  top: 0;
  z-index: 2;
  background: #fff;
}

.filters-drawer__title {
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--brand-blue);
}

.filters-drawer__close {
  appearance: none;
  padding: 6px 10px;
  border-radius: 10px;
  border: 1px solid rgba(26,25,82,.12);
  background: #fff;
  cursor: pointer;
  font-family: 'Nunito', sans-serif;
}

.filters-drawer__close:focus-visible {
  outline: 2px solid var(--accent-yellow);
  outline-offset: 2px;
}

.filters-drawer__search {
  margin-top: 10px;
}

.filters-drawer__search-input {
  width: 100%;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid rgba(26,25,82,.12);
  background: #fff;
  font: inherit;
  font-family: 'Nunito', sans-serif;
}

.filters-drawer__search-input:focus {
  outline: none;
  border-color: var(--accent-yellow);
  box-shadow: 0 0 0 4px rgba(216,182,100,.18);
}

.filters-drawer__list {
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 10px;
  padding-bottom: 18px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

@media (min-width: 420px) {
  .filters-drawer__list {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 560px) {
  .filters-drawer__list {
    grid-template-columns: 1fr 1fr 1fr;
  }
}

.filters-drawer__item {
  padding: 12px 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-radius: 12px;
  border: 1px solid rgba(26,25,82,.10);
  background: #fff;
  font-weight: 600;
  font-family: 'Nunito', sans-serif;
  color: var(--brand-blue);
  transition: transform 160ms ease, border-color 160ms ease, background-color 160ms ease;
}

.filters-drawer__item:hover {
  background: rgba(26,25,82,.03);
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(26,25,82,.08);
  border-color: rgba(26,25,82,.16);
}

.filters-drawer__item.is-active {
  border-color: var(--accent-yellow);
  background: #fff;
  font-weight: 600;
}

.filters-drawer__item > span:first-child {
  font-weight: 650;
  letter-spacing: -0.01em;
  line-height: 1.15;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.filters-drawer__item-count {
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  height: 22px;
  min-width: 28px;
  padding: 0 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid rgba(26,25,82,.10);
}

.filters-drawer__item.is-active .filters-drawer__item-count {
  border-color: rgba(216,182,100,.55);
}

/* Prevent body scroll when drawer is open */
body.no-scroll {
  overflow: hidden;
}

/* --------------------------------------------------
   Post Cards
-------------------------------------------------- */
.post-card {
  height: 100%;
  border: 1px solid rgba(26,25,82,.08);
  border-radius: 16px;
  background: #fff;
  overflow: hidden;
}

.post-card__link {
  display: block;
  height: 100%;
  text-decoration: none;
  color: inherit;
}

.post-card__inner {
  padding: 18px;
  display: grid;
  gap: 12px;
}

.post-card__body {
  display: grid;
  grid-template-columns: 176px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.post-card__media {
  display: grid;
  place-items: center;
  overflow: hidden;
}

.post-card__media img,
.post-card__img {
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: contain !important;
  object-position: center center !important;
  display: block;
}

.post-card__title {
  margin: 0 0 8px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 1.3rem;
  color: var(--brand-blue);
}

.post-card__title-mark {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--accent-yellow);
  flex: 0 0 auto;
}

.post-card__title-text {
  color: var(--brand-blue);
}

.post-card__excerpt {
  margin: 0 0 12px;
  opacity: 0.9;
  white-space: pre-line;
  color: var(--text-gray);
}

.post-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 0.95em;
  opacity: 0.85;
}

.post-card__author {
  font-weight: 600;
  color: var(--brand-blue);
}

.post-card__img--fallback {
  object-fit: contain;
  padding: 20px;
  max-width: 70%;
  max-height: 70%;
  margin: auto;
  opacity: 0.75;
}

/* Blog index specific post cards */
.page--blog-index .post-card {
  background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(255,255,255,.94));
  border: 1px solid rgba(26,25,82,.10);
  border-radius: 18px;
  box-shadow:
    0 1px 0 rgba(255,255,255,.7) inset,
    0 10px 28px rgba(26,25,82,.08);
  overflow: hidden;
  transition: transform 180ms ease, box-shadow 220ms ease, border-color 220ms ease;
}

.page--blog-index .post-card:hover {
  transform: translateY(-3px);
  border-color: rgba(26,25,82,.16);
  box-shadow:
    0 1px 0 rgba(255,255,255,.75) inset,
    0 18px 44px rgba(26,25,82,.12);
}

.page--blog-index .post-card__link:focus-visible {
  outline: 2px solid var(--accent-yellow);
  outline-offset: 4px;
  border-radius: 18px;
}

.page--blog-index .post-card__inner {
  padding: 16px;
  display: grid;
  gap: 12px;
}

.page--blog-index .post-card__body {
  display: grid;
  grid-template-columns: 152px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.page--blog-index .post-card__media {
  width: 152px;
  aspect-ratio: 4 / 3;
  border-radius: 14px;
  overflow: hidden;
  background: radial-gradient(120% 120% at 30% 20%, rgba(26,25,82,.10), rgba(26,25,82,.03));
  border: 1px solid rgba(26,25,82,.08);
  box-shadow: 0 8px 18px rgba(26,25,82,.10);
}

.page--blog-index .post-card__media img,
.page--blog-index .post-card__img {
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: contain !important;
  object-position: center center !important;
  display: block;
  background: transparent;
}

.page--blog-index .post-card__img.is-cover {
  object-fit: cover !important;
}

.page--blog-index .post-card:hover .post-card__media img,
.page--blog-index .post-card:hover .post-card__img {
  transform: scale(1.03);
  filter: saturate(1.03) contrast(1.02);
}

.page--blog-index .post-card__media .post-card__img--fallback {
  width: clamp(72px, 26vw, 120px) !important;
  height: auto !important;
  max-width: 70% !important;
  max-height: 70% !important;
  object-fit: contain !important;
  padding: 0 !important;
  opacity: 0.78;
  filter: saturate(0.95);
  transform: none !important;
}

.page--blog-index .post-card__title {
  margin: 0 0 6px;
  font-size: 1.12rem;
  line-height: 1.18;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.page--blog-index .post-card__title,
.page--blog-index .post-card__title a {
  color: var(--brand-blue);
}

.page--blog-index .post-card:hover .post-card__title {
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
  text-decoration-color: rgba(26,25,82,.28);
}

.page--blog-index .post-card__excerpt {
  margin: 0 0 10px;
  font-size: 0.98rem;
  line-height: 1.5;
  color: rgba(26,25,82,.78);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

.page--blog-index .post-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  font-size: 0.84rem;
  color: rgba(26,25,82,.62);
}

.page--blog-index .post-card__author {
  font-weight: 650;
  color: rgba(26,25,82,.78);
}

.page--blog-index .post-card__meta > * {
  background: rgba(26,25,82,.03);
  border: 1px solid rgba(26,25,82,.06);
  padding: 4px 8px;
  border-radius: 999px;
}

/* Post card mobile */
@media (max-width: 560px) {
  .post-card__body {
    grid-template-columns: 1fr;
  }
  .post-card__img--fallback {
    max-width: 55%;
    max-height: 55%;
    padding: 16px;
  }

  .page--blog-index .post-card {
    border-radius: 16px;
    box-shadow:
      0 1px 0 rgba(255,255,255,.65) inset,
      0 10px 24px rgba(26,25,82,.10);
  }
  .page--blog-index .post-card__inner {
    padding: 14px;
    gap: 10px;
  }
  .page--blog-index .post-card__body {
    display: grid;
    grid-template-columns: 108px minmax(0, 1fr);
    gap: 12px;
    align-items: start;
  }
  .page--blog-index .post-card__media {
    width: 108px;
    aspect-ratio: 1 / 1;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(26,25,82,.08);
    background: rgba(26,25,82,.03);
    border: 1px solid rgba(26,25,82,.06);
  }
  .page--blog-index .post-card__media img,
  .page--blog-index .post-card__img,
  .page--blog-index .post-card__img.is-cover {
    width: 100% !important;
    height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    object-fit: contain !important;
    object-position: center center !important;
    display: block;
    background: transparent;
    transform: none !important;
    filter: none !important;
  }
  .page--blog-index .post-card__title {
    font-size: 1.02rem;
    line-height: 1.22;
    margin: 0 0 6px;
    letter-spacing: -0.01em;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
  }
  .page--blog-index .post-card__title-mark {
    display: none;
  }
  .page--blog-index .post-card__excerpt {
    font-size: 0.95rem;
    line-height: 1.48;
    margin: 0 0 10px;
    -webkit-line-clamp: 2;
  }
  .page--blog-index .post-card__meta {
    font-size: 0.82rem;
    gap: 8px;
  }
  .page--blog-index .post-card__meta > * {
    padding: 3px 8px;
    border-radius: 999px;
    background: rgba(26,25,82,.03);
    border: 1px solid rgba(26,25,82,.06);
  }
}

/* --------------------------------------------------
   Label Pills
-------------------------------------------------- */
.label-pill {
  border: 1px solid rgba(26,25,82,.12);
  background: #fff;
  color: var(--brand-blue);
  border-radius: 999px;
  padding: 7px 11px;
  font: inherit;
  font-family: 'Nunito', sans-serif;
  cursor: pointer;
  line-height: 1;
  font-size: 0.9rem;
}

.label-pill.is-active {
  font-weight: 600;
  border-color: var(--accent-yellow);
}

.page--blog-index .label-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(26,25,82,.12);
  background: #fff;
  font-weight: 600;
}

#postLabels .label-pill {
  border: none;
  background: transparent;
  padding: 0;
  margin: 0;
  display: inline;
  opacity: 0.85;
}

/* --------------------------------------------------
   Article Page Layout
-------------------------------------------------- */
.page--blog-article .container {
  max-width: 1100px;
}

.article-header {
  margin-top: 18px;
  margin-bottom: 20px;
  max-width: 860px;
}

.article-header--split {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 20px;
  align-items: start;
}

.article-header__left #postTitle {
  font-size: clamp(16px, 1.3vw, 20px);
  line-height: 1.25;
  margin: 0;
  position: relative;
  padding-left: 14px;
  color: var(--brand-blue);
}

.article-header__left #postTitle::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.46em;
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--accent-yellow);
}

#postTitle {
  font-size: clamp(8px, 1.2vw, 16px);
  line-height: 1.15;
  margin: 0 0 12px;
  position: relative;
  padding-left: 18px;
  color: var(--brand-blue);
}

#postTitle::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.46em;
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--accent-yellow);
}

.page--blog-article #postTitle {
  font-size: clamp(26px, 2.6vw, 40px);
  line-height: 1.1;
  margin: 0 0 14px;
}

/* Article Content */
.article-content {
  max-width: none;
  background: rgba(255,255,255,.96);
  border: 1px solid rgba(26,25,82,.10);
  border-radius: 18px;
  box-shadow:
    0 1px 0 rgba(255,255,255,.65) inset,
    0 14px 40px rgba(26,25,82,.10);
  padding: clamp(18px, 2.4vw, 26px);
}

#postContent.article-content {
  background: rgba(255,255,255,.96);
  border: 1px solid rgba(26,25,82,.10);
  border-radius: 18px;
  box-shadow:
    0 1px 0 rgba(255,255,255,.65) inset,
    0 14px 40px rgba(26,25,82,.10);
  padding: clamp(18px, 2.4vw, 26px);
}

#postContent p {
  font-size: 1.02rem;
  line-height: 1.68;
  color: rgba(26,25,82,.86);
}

.page--blog-article #postContent.article-content {
  grid-column: 1;
}

#postContent + .article-back-link {
  grid-column: 1;
}

/* Article Sidebar */
.article-side {
  max-width: 420px;
  background: rgba(255,255,255,.92);
  border: 1px solid rgba(26,25,82,.10);
  border-radius: 16px;
  box-shadow:
    0 1px 0 rgba(255,255,255,.65) inset,
    0 12px 30px rgba(26,25,82,.08);
  padding: 14px;
}

.article-side--drawer {
  max-width: none;
}

.article-side__line {
  display: block;
  margin: 0 0 10px;
  font-size: 0.92rem;
  color: rgba(26,25,82,.70);
}

#postAuthor {
  font-weight: 750;
  color: rgba(26,25,82,.84);
}

#postDate {
  color: rgba(26,25,82,.62);
}

/* Back link */
.article-back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid rgba(26,25,82,.12);
  border-radius: 999px;
  text-decoration: none;
  color: var(--brand-blue);
  opacity: 0.9;
  margin-bottom: 14px;
  font-family: 'Nunito', sans-serif;
}

.article-back-link:hover {
  opacity: 1;
}

.article-side .article-back-link {
  margin-top: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid rgba(26,25,82,.12);
  border-radius: 999px;
  background: rgba(255,255,255,.78);
  text-decoration: none;
  color: var(--brand-blue);
  transition: transform 160ms ease, border-color 160ms ease, background-color 160ms ease;
}

.article-side .article-back-link:hover {
  transform: translateY(-1px);
  border-color: rgba(26,25,82,.18);
  background: rgba(26,25,82,.06);
}

.article-side__sticky-back.article-back-link {
  flex: 1;
  justify-content: center;
  padding: 10px 14px;
  border-radius: 999px;
}

/* Recommendations */
.article-side__recs {
  margin-top: 0;
  padding-top: 12px;
  border-top: 1px solid rgba(26,25,82,.10);
}

.article-side__recs-title {
  font-size: 0.9rem;
  font-weight: 850;
  letter-spacing: -0.01em;
  color: var(--brand-blue);
  margin-bottom: 10px;
}

.article-side__recs-list {
  display: grid;
  gap: 10px;
}

/* --------------------------------------------------
   Details Drawer (mobile article sidebar)
-------------------------------------------------- */
.details-drawer {
  position: relative;
}

.details-drawer__bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(26,25,82,.10);
  border-radius: 16px;
  box-shadow: 0 12px 28px rgba(26,25,82,0.10);
  backdrop-filter: blur(10px);
  position: fixed !important;
  top: var(--site-header-offset, 64px) !important;
  left: 0;
  right: 0;
  z-index: 2000 !important;
}

.details-drawer__toggle {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 1px solid rgba(26,25,82,.12);
  background: rgba(255,255,255,0.9);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  top: 6px;
}

.details-drawer__chev {
  width: 22px;
  height: 22px;
  transition: transform 180ms ease;
  color: var(--brand-blue);
  display: block;
}

.details-drawer.is-open .details-drawer__chev {
  transform: rotate(180deg);
}

.details-drawer__panel {
  margin-top: 0;
  padding: 0;
  display: none;
  position: fixed !important;
  left: 0;
  right: 0;
  top: calc(var(--header-h) + var(--details-bar-h, 58px)) !important;
  z-index: 1500 !important;
  max-height: calc(100vh - (var(--header-h) + var(--details-bar-h, 58px)) - 12px) !important;
  overflow: auto !important;
  width: 100vw;
  background: transparent;
  border: 0;
  box-shadow: none;
  border-radius: 0;
}

.details-drawer.is-open .details-drawer__panel {
  display: block;
  margin-top: 6px;
}

.article-side__panel {
  border-radius: 16px;
  border: 1px solid rgba(26,25,82,0.10);
  background: rgba(255,255,255,0.96);
  box-shadow: 0 12px 28px rgba(26,25,82,0.10);
  padding: 12px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (min-width: 520px) {
  .article-side__panel {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }
}

/* --------------------------------------------------
   Recommendation Cards
-------------------------------------------------- */
.page--blog-article .reco-card {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 10px;
  border-radius: 14px;
  border: 1px solid rgba(26,25,82,.10);
  background: rgba(255,255,255,.78);
  text-decoration: none;
  color: inherit;
  transition: transform 160ms ease, border-color 160ms ease, background-color 160ms ease;
}

.page--blog-article .reco-card:hover {
  transform: translateY(-1px);
  border-color: rgba(26,25,82,.16);
  background: rgba(255,255,255,.90);
}

.page--blog-article .reco-card__media {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  overflow: hidden;
  background: rgba(26,25,82,.03);
  border: 1px solid rgba(26,25,82,.06);
  display: grid;
  place-items: center;
}

.page--blog-article .reco-card__img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.page--blog-article .reco-card__title {
  font-size: 0.92rem;
  font-weight: 750;
  line-height: 1.2;
  color: var(--brand-blue);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.page--blog-article .reco-card__meta {
  margin-top: 4px;
  font-size: 0.82rem;
  color: rgba(26,25,82,.60);
}

/* --------------------------------------------------
   Lightbox (article page images)
-------------------------------------------------- */
.blog-lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(0,0,0,.78);
}

.blog-lightbox.is-open {
  display: flex;
}

.blog-lightbox__frame {
  position: relative;
  max-width: min(1100px, 96vw);
  max-height: 92vh;
}

.blog-lightbox__img {
  display: block;
  max-width: 100%;
  max-height: 92vh;
  width: auto;
  height: auto;
  border-radius: 14px;
  box-shadow: 0 18px 55px rgba(0,0,0,.45);
  background: #111;
}

.blog-lightbox__close {
  position: absolute;
  top: -10px;
  right: -10px;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.28);
  background: rgba(10,10,10,.65);
  color: #fff;
  cursor: pointer;
  display: grid;
  place-items: center;
  line-height: 1;
}

.blog-lightbox__close:focus {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

@media (max-width: 600px) {
  .blog-lightbox { padding: 10px; }
  .blog-lightbox__close { top: -6px; right: -6px; }
}

/* --------------------------------------------------
   Blog Footer (simple light footer for blog)
-------------------------------------------------- */
.blog-footer {
  background: #1a1952;
  color: white;
  padding: 20px;
  text-align: center;
  font-size: 14px;
  font-family: 'Nunito', sans-serif;
}

.blog-footer a {
  color: var(--accent-yellow);
  text-decoration: none;
}

.blog-footer a:hover {
  text-decoration: underline;
}

/* --------------------------------------------------
   Article Responsive
-------------------------------------------------- */
@media (max-width: 560px) {
  .article-header {
    margin-top: 10px;
  }
  #postTitle {
    font-size: clamp(22px, 2.4vw, 30px);
    line-height: 1.2;
    margin: 0 0 10px;
  }
  #postContent.article-content {
    padding: 16px;
    border-radius: 16px;
  }
  #postContent p {
    font-size: 1rem;
  }
}

@media (max-width: 900px) {
  .article-header--split {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .page--blog-article .article-header--split {
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
    min-height: 0 !important;
  }
  .article-header__right {
    position: static !important;
    padding-left: 0 !important;
  }
  .article-header__right::before {
    display: none !important;
  }
  .details-drawer {
    position: sticky;
    top: var(--site-header-offset, 64px);
    z-index: 50;
  }
  .article-side__sticky {
    display: flex;
    align-items: center;
    gap: 10px;
  }
  .article-side__panel {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  #postRecs {
    display: block;
  }
  .article-side__recs {
    margin-top: 0;
  }
  .page--blog-article .article-layout {
    grid-template-columns: 1fr;
  }
  .page--blog-article .article-aside {
    position: static;
  }
  .page--blog-article .article-back-link--bottom {
    display: inline-flex;
    width: 100%;
    justify-content: center;
    margin-top: 14px;
    margin-bottom: 6px;
  }
}

@media (min-width: 901px) {
  .article-header__right {
    margin-top: 6px;
  }
  .page--blog-article #postContent.article-content {
    margin-top: 5px;
  }
  /* Hide mobile-only details drawer bar on desktop */
  .details-drawer__bar {
    display: none;
  }
}

/* Visually hidden utility */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
