/* =============================================================================
   Blog V2 — مس کاوان نماد
   Hero (dark) → Main list + sidebar (light radial-gradient) → infinite scroll
   ============================================================================= */

/* ── WP sticky header: override Ollie parent theme's z:100 with !important ──
   Ollie sets: body:not(.wp-admin) header:has(> .is-position-sticky) { z-index:100 }
   That rule has specificity 0-2-2, ours 0-2-0 loses without !important.
   Must be > sidebar (z:300) so nav overlay (inside stacking ctx) shows on top. */
.site-header.wp-block-template-part {
  z-index: 1000 !important;
}
.site-header .is-position-sticky {
  z-index: 1000 !important;
}

/* ── Shared vars (scoped to .msk-blg wrapper) ── */
.msk-blg {
  --dark:    #0B383C;
  --light:   #FBF6F5;
  --copper:  #BA6D51;
  --teal:    #0488AA;
  --white:   #FFFFFF;
  --text:    #0B383C;
  --muted:   rgba(11,56,60,0.58);
  --cu10:    rgba(186,109,81,0.10);
  --tl10:    rgba(4,136,170,0.10);
  --noise: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)'/%3E%3C/svg%3E");
  direction: rtl;
  /* clip vs hidden: clip does NOT create BFC so the hero's margin-block-start: -138px
     is not clipped — hero can extend above .msk-blg to go behind the sticky header */
  overflow-x: clip;
}

/* ── Container ── */
.msk-blg .msk-con {
  width: 100%;
  max-width: 1360px;
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 5vw, 5rem);
  position: relative;
  z-index: 1;
}

/* ══════════════════════════════════════════════════════════════
   1. HERO — dark, overlaps nav, featured posts grid
   ══════════════════════════════════════════════════════════════ */
.msk-blg-hero {
  background: var(--dark);
  margin-block-start: -138px;
  padding-block-start: calc(138px + clamp(4rem, 8vw, 7rem));
  padding-block-end: clamp(4rem, 8vw, 7rem);
  position: relative;
  overflow: hidden;
}

/* Noise on dark hero */
.msk-blg-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: var(--noise);
  mix-blend-mode: soft-light;
  opacity: 0.42;
  pointer-events: none;
  z-index: 0;
}

/* Subtle copper radial accent (top-right) */
.msk-blg-hero::after {
  content: '';
  position: absolute;
  inset-block-start: -20%;
  inset-inline-end: -10%;
  width: clamp(300px, 50vw, 700px);
  aspect-ratio: 1;
  background: radial-gradient(circle, rgba(186,109,81,0.18) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

/* Hero header text */
.msk-blg-hero__header {
  margin-block-end: clamp(2.5rem, 5vw, 4rem);
}

.msk-blg-hero__eyebrow {
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  color: var(--copper);
  text-transform: uppercase;
  margin-block-end: 1rem;
}

.msk-blg-hero__title {
  font-family: var(--wp--preset--font-family--sahel-fd, 'Tahoma', sans-serif);
  font-size: clamp(1.8rem, 4vw, 3.5rem);
  font-weight: 900;
  color: var(--white);
  margin: 0;
  line-height: 1.25;
}
.msk-blg-hero__title span { color: var(--copper); }

/* ── Featured posts grid ── */
.msk-feat-grid {
  display: grid;
  grid-template-columns: 1.55fr 1fr 1fr;
  grid-template-rows: auto auto;
  gap: 1rem;
}

/* Card 1 (large, spans 2 rows) */
.msk-feat-card:first-child {
  grid-row: 1 / 3;
}

/* ── Featured card — full-bleed image + glass body ── */
.msk-feat-card {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.08);
  display: block;
  aspect-ratio: 16/10;
  text-decoration: none;
  color: inherit;
  transition: transform 0.35s cubic-bezier(.16,.84,.44,1),
              border-color 0.35s;
}
.msk-feat-card:first-child { aspect-ratio: unset; }
.msk-feat-card:hover {
  transform: translateY(-5px);
  border-color: rgba(186,109,81,0.35);
}

/* Card noise */
.msk-feat-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: var(--noise);
  mix-blend-mode: soft-light;
  opacity: 0.45;
  pointer-events: none;
  z-index: 3;
  border-radius: 20px;
}

/* Image fills entire card */
.msk-feat-card__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}
.msk-feat-card__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.55s cubic-bezier(.16,.84,.44,1);
}
.msk-feat-card:hover .msk-feat-card__img img { transform: scale(1.05); }

/* Dark gradient over image — brand green #0B383C */
.msk-feat-card__img::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(11,56,60,0.85) 0%,
    rgba(11,56,60,0.22) 55%,
    transparent 100%
  );
  z-index: 1;
}

/* No-image: dark green gradient + hide SVG */
.msk-feat-card__img-ph {
  width: 100%;
  height: 100%;
  background: linear-gradient(140deg, #0B383C 0%, #041414 60%, #062824 100%);
  display: block;
}
.msk-feat-card__img-ph svg { display: none; }

/* Body — glass overlay at bottom */
.msk-feat-card__body {
  position: absolute;
  inset-block-end: 0;
  inset-inline: 0;
  padding: clamp(0.9rem, 1.8vw, 1.3rem);
  z-index: 2;
  background: rgba(11,56,60,0.58);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid rgba(255,255,255,0.10);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.msk-feat-card__meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-block-end: 0.6rem;
  flex-wrap: wrap;
}
.msk-feat-card__cat {
  font-size: 0.66rem;
  letter-spacing: 0.1em;
  background: rgba(186,109,81,0.25);
  color: var(--copper);
  padding: 3px 10px;
  border-radius: 100px;
}
.msk-feat-card__date {
  font-size: 0.68rem;
  color: rgba(255,255,255,0.42);
}

.msk-feat-card__title {
  font-family: var(--wp--preset--font-family--sahel-fd, 'Tahoma', sans-serif);
  font-size: clamp(0.9rem, 1.5vw, 1.1rem);
  font-weight: 700;
  color: var(--white);
  margin: 0;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.msk-feat-card:first-child .msk-feat-card__title {
  font-size: clamp(1.1rem, 2vw, 1.5rem);
  -webkit-line-clamp: 3;
}

/* ══════════════════════════════════════════════════════════════
   2. MAIN CONTENT — light bg radial-gradient + two columns
   ══════════════════════════════════════════════════════════════ */
.msk-blg-main {
  padding-block: clamp(4rem, 8vw, 7rem);
  position: relative;
  background:
    radial-gradient(55.31% 74.17% at 3.02% 8.26%, rgba(185,109,81,0.25) 0%, rgba(13,67,72,0) 100%),
    #FBF6F5;
  overflow-x: clip; /* clip X only — overflow:hidden breaks position:sticky on children */
}

/* Noise on light section */
.msk-blg-main::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: var(--noise);
  mix-blend-mode: multiply;
  opacity: 0.065;
  pointer-events: none;
  z-index: 0;
}

/* Two-column grid */
.msk-blg-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 2.5rem;
}

/* Posts column: start at top, sized to content */
.msk-blg-list {
  align-self: start;
}

/* ── Post list (70%) ── */
.msk-blg-list {}

.msk-blg-list__title {
  font-family: var(--wp--preset--font-family--sahel-fd, 'Tahoma', sans-serif);
  font-size: clamp(1.2rem, 2.5vw, 1.6rem);
  font-weight: 900;
  color: var(--text);
  margin: 0 0 clamp(1.5rem, 3vw, 2.5rem);
  display: flex;
  align-items: center;
  gap: 12px;
}
.msk-blg-list__title::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(to left, var(--copper), transparent);
  opacity: 0.35;
}

/* ── Post card (list) ── */
.msk-post-row {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 1.5rem;
  margin-block-end: 1.5rem;
  background: var(--white);
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid rgba(11,56,60,0.07);
  position: relative;
  transition: transform 0.3s cubic-bezier(.16,.84,.44,1),
              box-shadow 0.3s,
              border-color 0.3s;
}

/* Card noise */
.msk-post-row::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: var(--noise);
  mix-blend-mode: multiply;
  opacity: 0.06;
  pointer-events: none;
  z-index: 0;
  border-radius: 20px;
}

.msk-post-row:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(11,56,60,0.10);
  border-color: rgba(186,109,81,0.25);
}

/* Row image */
.msk-post-row__img {
  overflow: hidden;
  position: relative;
  min-height: 180px;
}
.msk-post-row__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s cubic-bezier(.16,.84,.44,1);
}
.msk-post-row:hover .msk-post-row__img img { transform: scale(1.06); }

/* Image placeholder */
.msk-post-row__img-ph {
  width: 100%;
  height: 100%;
  min-height: 180px;
  background: linear-gradient(135deg, var(--tl10) 0%, var(--cu10) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}
.msk-post-row__img-ph svg {
  width: 44px; height: 44px;
  opacity: 0.25;
  color: var(--dark);
}

/* Row body */
.msk-post-row__body {
  padding: clamp(1.1rem, 2vw, 1.5rem) clamp(1.1rem, 2vw, 1.5rem) clamp(1.1rem, 2vw, 1.5rem) 32px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  z-index: 1;
}

.msk-post-row__meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-block-end: 0.65rem;
  flex-wrap: wrap;
}
.msk-post-row__cat {
  font-size: 0.66rem;
  letter-spacing: 0.1em;
  background: var(--tl10);
  color: var(--teal);
  padding: 3px 10px;
  border-radius: 100px;
}
.msk-post-row__date {
  font-size: 0.68rem;
  color: var(--muted);
}
.msk-post-row__read-time {
  font-size: 0.67rem;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 4px;
  margin-inline-start: auto;
}
.msk-post-row__read-time svg { width: 12px; height: 12px; flex-shrink: 0; }

.msk-post-row__title {
  font-family: var(--wp--preset--font-family--sahel-fd, 'Tahoma', sans-serif);
  font-size: clamp(0.95rem, 1.5vw, 1.15rem);
  font-weight: 700;
  color: var(--text);
  margin: 0 0 0.65rem;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-decoration: none;
}
a.msk-post-row__title:hover { color: var(--copper); }

.msk-post-row__excerpt {
  font-size: 0.83rem;
  color: var(--muted);
  line-height: 1.9;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-block-end: 1rem;
  flex: 1;
}

.msk-post-row__footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.msk-post-row__more {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.82rem;
  font-family: var(--wp--preset--font-family--sahel-fd, 'Tahoma', sans-serif);
  font-weight: 700;
  color: var(--copper);
  text-decoration: none;
  border: 1px solid rgba(186,109,81,0.30);
  border-radius: 100px;
  padding: 7px 18px;
  transition: background 0.25s, color 0.25s, border-color 0.25s, gap 0.2s;
}
.msk-post-row__more:hover {
  background: var(--copper);
  color: #fff;
  border-color: var(--copper);
  gap: 10px;
}
.msk-post-row__more svg { width: 14px; height: 14px; transform: scaleX(-1); }

/* ── Infinite scroll sentinel + loader ── */
.msk-scroll-sentinel {
  height: 1px;
  margin-block-start: 1rem;
}

.msk-scroll-loader {
  display: none;
  justify-content: center;
  padding-block: 2rem;
}
.msk-scroll-loader.active { display: flex; }

.msk-spinner {
  width: 36px; height: 36px;
  border-radius: 50%;
  border: 3px solid rgba(186,109,81,0.2);
  border-block-start-color: var(--copper);
  animation: msk-spin 0.7s linear infinite;
}
@keyframes msk-spin { to { transform: rotate(360deg); } }

/* Load-more button (page 4+) */
.msk-load-more-wrap {
  display: none;
  justify-content: center;
  padding-block: 2.5rem;
}
.msk-load-more-wrap.visible { display: flex; }

.msk-load-more {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--dark);
  color: #fff;
  font-family: var(--wp--preset--font-family--sahel-fd, 'Tahoma', sans-serif);
  font-size: 0.95rem;
  font-weight: 700;
  padding: 14px 36px;
  border-radius: 100px;
  border: none;
  cursor: pointer;
  transition: background 0.3s, transform 0.25s, box-shadow 0.3s;
}
.msk-load-more:hover {
  background: #0d4448;
  transform: scale(1.04);
  box-shadow: 0 8px 28px rgba(11,56,60,0.22);
}
.msk-load-more svg { width: 16px; height: 16px; }
.msk-load-more.loading { opacity: 0.7; pointer-events: none; }

/* No more posts message */
.msk-no-more {
  display: none;
  text-align: center;
  padding-block: 2rem;
  color: var(--muted);
  font-size: 0.85rem;
}
.msk-no-more.visible { display: block; }

/* ── Sidebar (30%) — desktop sticky ── */
.msk-blg-sidebar {
  position: sticky;
  top: 165px;
  align-self: start; /* must be shorter than grid row so sticky has room to scroll */
}

.msk-blog-widget {
  background: var(--white);
  border-radius: 20px;
  padding: 1.5rem;
  margin-block-end: 1.25rem;
  border: 1px solid rgba(11,56,60,0.07);
  position: relative;
  overflow: hidden;
}

.msk-blog-widget::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: var(--noise);
  mix-blend-mode: multiply;
  opacity: 0.055;
  pointer-events: none;
  border-radius: 20px;
}

.msk-blog-widget__title {
  font-family: var(--wp--preset--font-family--sahel-fd, 'Tahoma', sans-serif);
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 1.1rem;
  padding-block-end: 0.75rem;
  border-block-end: 1px solid rgba(11,56,60,0.08);
  position: relative;
  z-index: 1;
}
.msk-blog-widget__title::after {
  content: '';
  position: absolute;
  inset-block-end: -1px;
  inset-inline-start: 0;
  width: 40px;
  height: 2px;
  background: var(--copper);
}

/* Widget content z-index */
.msk-blog-widget > *:not(.msk-blog-widget__title) { position: relative; z-index: 1; }

/* Category list in widget */
.msk-blog-widget ul {
  list-style: none;
  margin: 0; padding: 0;
}
.msk-blog-widget ul li {
  border-block-end: 1px solid rgba(11,56,60,0.06);
  padding-block: 0.6rem;
}
.msk-blog-widget ul li:last-child { border: none; }
.msk-blog-widget ul li a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--text);
  text-decoration: none;
  font-size: 0.87rem;
  transition: color 0.2s;
  gap: 8px;
  /* ensure tappable on mobile */
  touch-action: manipulation;
  -webkit-tap-highlight-color: rgba(186,109,81,0.15);
  min-height: 44px; /* minimum touch target */
}
.msk-blog-widget ul li a:hover { color: var(--copper); }
.msk-blog-widget ul li.current-cat > a {
  color: var(--copper);
  font-weight: 700;
}
.msk-blog-widget ul li.current-cat > a span {
  background: var(--cu20);
  color: var(--copper);
}
.msk-blog-widget ul li a span {
  font-size: 0.72rem;
  color: var(--muted);
  background: var(--tl10);
  border-radius: 100px;
  padding: 1px 8px;
  flex-shrink: 0;
}

/* Tag cloud in widget */
.tagcloud {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.tagcloud a {
  font-size: 0.75rem !important;
  color: var(--text);
  background: rgba(11,56,60,0.06);
  padding: 4px 12px;
  border-radius: 100px;
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
  touch-action: manipulation;
  -webkit-tap-highlight-color: rgba(186,109,81,0.15);
}
.tagcloud a:hover {
  background: var(--dark);
  color: #fff;
}

/* Recent posts in widget */
.msk-blog-widget .recent-post-item {
  display: flex;
  gap: 10px;
  padding-block: 0.6rem;
  border-block-end: 1px solid rgba(11,56,60,0.06);
}
.msk-blog-widget .recent-post-item:last-child { border: none; }
.msk-blog-widget .recent-post-item img {
  width: 56px; height: 56px;
  object-fit: cover;
  border-radius: 10px;
  flex-shrink: 0;
}
.msk-blog-widget .recent-post-item__text { flex: 1; min-width: 0; }
.msk-blog-widget .recent-post-item__title {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.5;
  margin-block-end: 3px;
}
.msk-blog-widget .recent-post-item__title:hover { color: var(--copper); }
.msk-blog-widget .recent-post-item__date {
  font-size: 0.68rem;
  color: var(--muted);
}

/* ══════════════════════════════════════════════════════════════
   RESPONSIVE
   ══════════════════════════════════════════════════════════════ */

/* ── Tablet: 2-col featured, single-col list ── */
@media (max-width: 1023px) {
  .msk-feat-grid {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto auto;
  }
  .msk-feat-card:first-child { grid-column: 1 / -1; grid-row: auto; }
  .msk-feat-card:first-child .msk-feat-card__img { aspect-ratio: 16/7; }

  /* List goes full-width; sidebar becomes bottom sheet */
  .msk-blg-layout {
    grid-template-columns: 1fr;
    padding-block-end: 68px; /* room for fixed bottom sheet tab */
  }

  /* ── Sidebar → sticky bottom sheet ── */
  .msk-blg-sidebar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 300;
    background: var(--dark);
    border-radius: 22px 22px 0 0;
    /* collapsed: only the 62px toggle handle is visible */
    transform: translateY(calc(100% - 62px));
    transition: transform 0.4s cubic-bezier(0.32, 0, 0.15, 1);
    box-shadow: 0 -8px 40px rgba(0,0,0,0.35);
  }
  .msk-blg-sidebar.is-open {
    transform: translateY(0);
    transition-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
  }

  /* Sidebar content (scrollable inner area, hidden when collapsed) */
  .msk-sidebar-content {
    max-height: 65vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    padding: 0 1.25rem 1.5rem;
    padding-block-end: max(1.5rem, env(safe-area-inset-bottom, 1.5rem));
  }

  /* Widget light-on-dark overrides */
  .msk-blg-sidebar .msk-blog-widget {
    background: rgba(255,255,255,0.06);
    border-color: rgba(255,255,255,0.09);
    margin-block-end: 1rem;
  }
  .msk-blg-sidebar .msk-blog-widget::before { mix-blend-mode: soft-light; opacity: 0.3; }
  .msk-blg-sidebar .msk-blog-widget__title { color: rgba(255,255,255,0.9); border-block-end-color: rgba(255,255,255,0.1); }
  .msk-blg-sidebar .msk-blog-widget ul li { border-block-end-color: rgba(255,255,255,0.07); }
  .msk-blg-sidebar .msk-blog-widget ul li a { color: rgba(255,255,255,0.78); }
  .msk-blg-sidebar .msk-blog-widget ul li a span { background: rgba(255,255,255,0.1); color: rgba(255,255,255,0.5); }
  .msk-blg-sidebar .tagcloud a { background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.7); }
  .msk-blg-sidebar .tagcloud a:hover { background: var(--copper); color: #fff; }
  .msk-blg-sidebar .recent-post-item__title { color: rgba(255,255,255,0.82); }
  .msk-blg-sidebar .recent-post-item__date { color: rgba(255,255,255,0.4); }
  .msk-blg-sidebar .recent-post-item { border-block-end-color: rgba(255,255,255,0.07); }
}

/* ── Sidebar toggle button (shows in bottom-sheet handle) ── */
.msk-sidebar-toggle {
  display: none; /* hidden on desktop */
}
@media (max-width: 1023px) {
  .msk-sidebar-toggle {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    height: 62px; /* exact collapsed tab height — matches translateY offset */
    padding: 10px 1.5rem 0;
    background: transparent;
    border: none;
    cursor: pointer;
    gap: 6px;
    -webkit-tap-highlight-color: transparent;
    flex-shrink: 0;
  }
  .msk-sidebar-toggle__drag {
    width: 38px; height: 4px;
    background: rgba(255,255,255,0.28);
    border-radius: 2px;
    transition: background 0.2s;
  }
  .msk-sidebar-toggle:hover .msk-sidebar-toggle__drag { background: rgba(255,255,255,0.55); }
  .msk-sidebar-toggle__label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.88rem;
    font-family: var(--wp--preset--font-family--sahel-fd, 'Tahoma', sans-serif);
    font-weight: 700;
    color: rgba(255,255,255,0.75);
    transition: color 0.2s;
  }
  .msk-sidebar-toggle:hover .msk-sidebar-toggle__label { color: #fff; }
  .msk-sidebar-toggle__label svg { width: 16px; height: 16px; flex-shrink: 0; }
  .msk-sidebar-toggle__chevron {
    width: 16px; height: 16px;
    transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
    color: rgba(255,255,255,0.5);
  }
  .msk-blg-sidebar.is-open .msk-sidebar-toggle__chevron {
    transform: rotate(180deg);
  }
}

/* ── Backdrop ── */
.msk-sidebar-backdrop {
  display: none;
}
@media (max-width: 1023px) {
  .msk-sidebar-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 290;
    background: rgba(0,0,0,0.45);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.35s;
  }
  .msk-sidebar-backdrop.is-open {
    opacity: 1;
    pointer-events: auto;
  }
}

/* ── Mobile: magazine-style featured posts ── */
@media (max-width: 767px) {
  .msk-feat-grid {
    grid-template-columns: 1fr 1fr;
    gap: 0.65rem;
  }

  /* Card 1: full-width hero */
  .msk-feat-card:nth-child(1) {
    grid-column: 1 / -1;
  }
  .msk-feat-card:nth-child(1) .msk-feat-card__img { aspect-ratio: 16/8; }
  .msk-feat-card:nth-child(1) .msk-feat-card__title {
    font-size: clamp(1.05rem, 4vw, 1.3rem);
    -webkit-line-clamp: 3;
  }

  /* Cards 2+3: half-width with image (natural in 2-col grid) */
  .msk-feat-card:nth-child(2) .msk-feat-card__img,
  .msk-feat-card:nth-child(3) .msk-feat-card__img { aspect-ratio: 4/3; }
  .msk-feat-card:nth-child(2) .msk-feat-card__title,
  .msk-feat-card:nth-child(3) .msk-feat-card__title { font-size: 0.85rem; }

  /* Cards 4+5: editorial text rows (no image) — magazine ticker style */
  .msk-feat-card:nth-child(4),
  .msk-feat-card:nth-child(5) {
    grid-column: 1 / -1;
    flex-direction: row;
    align-items: center;
    background: rgba(255,255,255,0.03);
    border: none;
    border-radius: 0;
    border-block-start: 1px solid rgba(255,255,255,0.08);
    padding: 0;
    min-height: 56px;
    transform: none !important; /* disable lift on hover for row items */
  }
  .msk-feat-card:nth-child(4) { border-radius: 0; }
  .msk-feat-card:nth-child(5) {
    border-radius: 0 0 16px 16px;
  }
  /* hide image */
  .msk-feat-card:nth-child(4) .msk-feat-card__img,
  .msk-feat-card:nth-child(5) .msk-feat-card__img { display: none; }

  /* body becomes horizontal row */
  .msk-feat-card:nth-child(4) .msk-feat-card__body,
  .msk-feat-card:nth-child(5) .msk-feat-card__body {
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 0.75rem;
    padding: 0.8rem 1rem;
  }
  /* keep only category badge in meta */
  .msk-feat-card:nth-child(4) .msk-feat-card__meta,
  .msk-feat-card:nth-child(5) .msk-feat-card__meta { flex-shrink: 0; margin: 0; }
  .msk-feat-card:nth-child(4) .msk-feat-card__date,
  .msk-feat-card:nth-child(5) .msk-feat-card__date { display: none; }
  /* title inline */
  .msk-feat-card:nth-child(4) .msk-feat-card__title,
  .msk-feat-card:nth-child(5) .msk-feat-card__title {
    font-size: 0.9rem;
    -webkit-line-clamp: 2;
    margin: 0;
    flex: 1;
    text-align: start;
  }

  /* Post list cards: stacked single-col */
  .msk-post-row {
    grid-template-columns: 1fr;
  }
  .msk-post-row__img { min-height: 200px; }
  .msk-post-row__body {
    padding: 1rem 1rem 1rem 32px;
  }
}

@media (max-width: 479px) {
  /* Cards 2+3 still half-width on very small screens */
  .msk-feat-card:nth-child(2) .msk-feat-card__title,
  .msk-feat-card:nth-child(3) .msk-feat-card__title { font-size: 0.78rem; }
}

/* ── Reduced motion ── */
@media (prefers-reduced-motion: reduce) {
  .msk-feat-card, .msk-post-row { transition: none; }
  .msk-feat-card__img img, .msk-post-row__img img { transition: none; }
}

/* ── Post row entrance (GSAP sets this) ── */
.msk-post-row.msk-hidden {
  opacity: 0;
  transform: translateY(40px);
}
