/* ==========================================================================
   RTL & Persian typography for Casper — minimal, consolidated
   ========================================================================== */

/* --------------------- 1) Fonts --------------------- */
@font-face {
  font-family: "Lyon Arabic Display";
  src: url("/assets/fonts/LyonArabicDisplay.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Adobe Arabic";
  src: url("/assets/fonts/AdobeArabic-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  size-adjust: 140%;
}

/* --------------------- 2) Base RTL --------------------- */
html[dir="rtl"] { direction: rtl; }
html[dir="rtl"] body {
  text-align: right;
  unicode-bidi: plaintext;
  line-height: 1.9;
  color: var(--majera-text);
}


/* Common blocks align right in RTL */
html[dir="rtl"] .site-header,
html[dir="rtl"] .site-footer,
html[dir="rtl"] .post-card,
html[dir="rtl"] .gh-content,
html[dir="rtl"] .nav { text-align: right; }

/* Lists: swap padding sides */
html[dir="rtl"] ul,
html[dir="rtl"] ol { padding-right: 1.25rem; padding-left: 0; }

/* Keep code/LTR snippets readable */
html[dir="rtl"] pre,
html[dir="rtl"] code,
html[dir="rtl"] kbd,
html[dir="rtl"] samp,
html[dir="rtl"] .ltr {
  direction: ltr !important;
  text-align: left !important;
}

/* Images in posts: keep a neat block flow */
html[dir="rtl"] .gh-content img {
  display: block;
  margin: 1rem 0 1rem auto;
}

/* --------------------- 3) Typography mapping via body classes --------------------- */
/* BODY: Adobe (default) */
html[dir="rtl"] body.has-adobe-body,
html[dir="rtl"] body.has-adobe-body .gh-content,
html[dir="rtl"] body.has-adobe-body .gh-content p,
html[dir="rtl"] body.has-adobe-body .gh-content li,
html[dir="rtl"] body.has-adobe-body .post-card-excerpt {
  font-family: "Adobe Arabic", "Lyon Arabic Display", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif !important;
}

/* BODY: Lyon (if selected) */
html[dir="rtl"] body.has-lyon-body,
html[dir="rtl"] body.has-lyon-body .gh-content,
html[dir="rtl"] body.has-lyon-body .gh-content p,
html[dir="rtl"] body.has-lyon-body .gh-content li,
html[dir="rtl"] body.has-lyon-body .post-card-excerpt {
  font-family: "Lyon Arabic Display", "Adobe Arabic", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif !important;
}

/* TITLES: Lyon (default) */
html[dir="rtl"] body.has-lyon-title h1,
html[dir="rtl"] body.has-lyon-title h2,
html[dir="rtl"] body.has-lyon-title h3,
html[dir="rtl"] body.has-lyon-title .site-title,
html[dir="rtl"] body.has-lyon-title .gh-head-logo,
html[dir="rtl"] body.has-lyon-title .post-card-title,
html[dir="rtl"] body.has-lyon-title .gh-article-title {
  font-family: "Lyon Arabic Display", "Adobe Arabic", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif !important;
  font-weight: 500;
  line-height: 1.35;
}

/* TITLES: Adobe (if selected) */
html[dir="rtl"] body.has-adobe-title h1,
html[dir="rtl"] body.has-adobe-title h2,
html[dir="rtl"] body.has-adobe-title h3,
html[dir="rtl"] body.has-adobe-title .site-title,
html[dir="rtl"] body.has-adobe-title .gh-head-logo,
html[dir="rtl"] body.has-adobe-title .post-card-title,
html[dir="rtl"] body.has-adobe-title .gh-article-title {
  font-family: "Adobe Arabic", "Lyon Arabic Display", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif !important;
  font-weight: 700;
  line-height: 1.35;
}

/* Headings: slightly stronger Majera heading color */
html[dir="rtl"] h1,
html[dir="rtl"] h2,
html[dir="rtl"] h3,
html[dir="rtl"] .gh-article-title,
html[dir="rtl"] .post-card-title,
html[dir="rtl"] .naghz-card-title {
  color: var(--majera-heading);
}

/* ---------------------------------------------------------
   Footnotes (Majera Style)
   Lightweight, RTL-native, no JS required
--------------------------------------------------------- */
/* Persian numerals for ordered lists (footnotes) */
@counter-style majera-persian {
  system: numeric;
  symbols: '۰' '۱' '۲' '۳' '۴' '۵' '۶' '۷' '۸' '۹';
  suffix: ' ';
}

html[dir="rtl"] .footnotes {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--majera-border);

  /* EXACT match to main body text */
  font-size: var(--content-font-size);
  line-height: 1.9;

  color: var(--majera-text); /* same as body text */
}

html[dir="rtl"] .footnotes ol {
  padding: 0;
  margin: 0;
  list-style-position: inside;
  list-style: majera-persian; /* custom Persian numbering */
}

html[dir="rtl"] .footnotes li {
  margin: 0.75rem 0;
  line-height: 1.9; /* match body */
}

/* Superscript reference styling */
html[dir="rtl"] sup a {
  color: var(--majera-accent);
  text-decoration: none;
  font-weight: 600;
}

html[dir="rtl"] sup a:hover {
  color: var(--majera-accent-soft);
}

/* Backlink arrow */
html[dir="rtl"] .footnote-back {
  text-decoration: none;
  font-size: 0.85em; /* slightly smaller, so the arrow doesn't feel huge */
  margin-right: 0.3rem;
  color: var(--majera-accent);
}

html[dir="rtl"] .footnote-back:hover {
  color: var(--majera-accent-soft);
}


/* --------------------- 4) Reading size (posts/pages) --------------------- */
@media (min-width: 768px) {
  .post-template .gh-content,
  .page-template .gh-content {
    font-size: 0.95em;
    line-height: 1.9;
  }
}

/* --------------------- Scroll to top button --------------------- */

/* Base (desktop-first): closer to the center */
.scroll-to-top {
  position: fixed;
  bottom: 6rem;
  right: auto;          
  width: 5rem;
  height: 5rem;
  border-radius: 999px;
  border: 1px solid var(--majera-border);
  background-color: var(--majera-card-bg);
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.10);
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity .2s, transform .2s, box-shadow .2s, background-color .2s;
  z-index: 50;
}

/* Mobile: move it to bottom-left */
@media (max-width: 768px) {
  .scroll-to-top {
    right: auto;
    left: 2rem;        /* thumb-friendly */
    bottom: 2rem;
  }
}

/* Desktop and larger: align with reading column */
@media (min-width: 768px) {
  .scroll-to-top {
    right: auto;
    /* 
      Put it just to the right of a centered 720px column:
      (100vw - min(100vw, 720px)) / 2 = side margin
    */
    left: calc((100vw - min(100vw, 720px)) / 2 + 0.5rem);
    bottom: 2rem;
  }
}

.scroll-to-top-icon {
  width: 2.5rem;
  height: 2.5rem;
  display: block;
}

/* Only enable layout on post templates */
.post-template .scroll-to-top {
  display: inline-flex;
}

/* Visible state controlled via JS */
.post-template .scroll-to-top.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.post-template .scroll-to-top:hover {
  background-color: var(--majera-warm-soft); /* #C8BCA0 */
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.14);
}

.post-template .scroll-to-top:active {
  transform: translateY(1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.10);
}


/* --------------------- 5) Meta/bylines polish --------------------- */
html[dir="rtl"] .post-card-meta,
html[dir="rtl"] .post-card-meta *,
html[dir="rtl"] .gh-article-meta,
html[dir="rtl"] .gh-article-meta * {
  font-style: normal !important;
}

/* Paywall CTA (kept, but aligned with Majera cards) */
html[dir="rtl"] .paywall-cta {
  border: 1px solid var(--majera-border);
  background: var(--majera-card-bg);
  padding: 1.25rem;
  border-radius: 14px;
  text-align: center;
  margin: 1.25rem 0;
}

/* (titles/desc/alt blocks stay as you have them — unchanged) */

html[dir="rtl"] .paywall-cta__btn {
  display: inline-block;
  padding: .65rem 1.1rem;
  border-radius: 10px;
  border: 2px solid var(--ghost-accent-color);
  background: transparent;
  color: var(--ghost-accent-color);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: .01em;
  transition:
    background-color .2s ease,
    color .2s ease,
    border-color .2s ease,
    box-shadow .2s ease;
}

html[dir="rtl"] .paywall-cta__btn:hover {
  background: var(--ghost-accent-color);
  color: #fff;
  box-shadow: 0 0 0 3px rgba(58, 75, 116, 0.25); /* deep blue glow instead of pink */
}

html[dir="rtl"] .paywall-cta__link,
html[dir="rtl"] .paywall-cta__special {
  color: var(--ghost-accent-color);
  text-decoration: underline;
}
.dark-mode .paywall-cta {
  background: #0f0f10;
  border-color: #2a2a2a;
}
.dark-mode .paywall-cta__btn:hover {
  box-shadow: 0 0 0 3px rgba(255, 26, 117, 0.25);
}

/* Content font-size token */
:root[dir="rtl"] { --content-font-size: 1.7rem; }
/* Apply token */
html[dir="rtl"] .paywall-cta__desc,
html[dir="rtl"] .paywall-cta__alt { font-size: var(--content-font-size) !important; line-height: 1.9; }
html[dir="rtl"] .home-template .post-card .post-card-excerpt { font-size: var(--content-font-size) !important; line-height: 1.9; }
@media (min-width: 0px) {
  html[dir="rtl"] .post-template .gh-content p,
  html[dir="rtl"] .page-template .gh-content p,
  html[dir="rtl"] .post-template .gh-content li,
  html[dir="rtl"] .page-template .gh-content li,
  html[dir="rtl"] .post-template .gh-content blockquote p,
  html[dir="rtl"] .page-template .gh-content blockquote p {
    font-size: var(--content-font-size) !important;
    line-height: 1.9;
  }
}

/* Stack subscribe + login vertically */
html[dir="rtl"] .paywall-cta__actions {
  display: flex;
  flex-direction: column !important;
  align-items: center;
  gap: 0.6rem;
  margin-top: 0.9rem;
}

/* Byline font family alignment */
html[dir="rtl"] body.has-adobe-body .article-byline,
html[dir="rtl"] body.has-adobe-body .article-byline *,
html[dir="rtl"] body.has-adobe-body .article-byline a {
  font-family: "Adobe Arabic","Lyon Arabic Display",system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif !important;
  font-weight: 400;
}
html[dir="rtl"] body.has-lyon-body .article-byline,
html[dir="rtl"] body.has-lyon-body .article-byline *,
html[dir="rtl"] body.has-lyon-body .article-byline a {
  font-family: "Lyon Arabic Display","Adobe Arabic",system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif !important;
  font-weight: 400;
}
html[dir="rtl"] .article-byline .author-name,
html[dir="rtl"] .article-byline .author-name a { font-weight: 600 !important; }

/* --------------------- 6) Global canvas --------------------- */

:root[dir="rtl"] {
  /* Majera brand tokens — v2 (no blue, logo-based, subtle warm background) */

  /* Surfaces */
  --majera-bg:           #FFFF;  /* simple white */
  --majera-card-bg:      #F3F4F5;  /* inner surfaces: cards, content blocks */

  /* Text */
  --majera-text:         #212121;  /* primary body text */
  --majera-text-muted:   #6D6A65;  /* timestamps, metadata */
  --majera-heading:      #212121;  /* headings (hierarchy via size/weight) */

  /* Lines & borders */
  --majera-border:       #DCDCDC;  /* matches logo's grey rules */

  /* Warm brand scale (selective use) */
  --majera-warm-soft:    #C8BCA0;  /* soft brand warm for backgrounds, tags, hovers */
  --majera-warm-strong:  #BBA77F;  /* primary accent for CTAs, key highlights */

  /* Accent mapping */
  --majera-accent:       #3A4750;  /* main accent color */
  --majera-accent-soft:  var(--majera-warm-soft);    /* softer accent */

  /* Backwards-compatible aliases used elsewhere in the theme */
  --bg-sepia:       var(--majera-bg);
  --color-bg:       var(--majera-bg);
  --color-bg-alt:   var(--majera-bg);
  --color-bg-inset: var(--majera-bg);
}

/* Force visible hamburger icon in Majera RTL (overrides Casper's has-cover white) */
html[dir="rtl"] .gh-burger::before,
html[dir="rtl"] .gh-burger::after {
  background-color: var(--majera-text) !important;  /* dark text color */
}

html[dir="rtl"],
html[dir="rtl"] body,
html[dir="rtl"] .viewport,
html[dir="rtl"] .site-content,
html[dir="rtl"] .outer,
html[dir="rtl"] .inner,
html[dir="rtl"] .site-main,
html[dir="rtl"] .gh-canvas,
html[dir="rtl"] .article,
html[dir="rtl"] .post-card,
html[dir="rtl"] .post-card-content,
html[dir="rtl"] .read-more,
html[dir="rtl"] .kg-card,
html[dir="rtl"] .kg-bookmark-card,
html[dir="rtl"] .kg-gallery-card,
html[dir="rtl"] .kg-callout-card,
html[dir="rtl"] .kg-toggle-card,
html[dir="rtl"] .kg-product-card,
html[dir="rtl"] .site-footer,
html[dir="rtl"] .gh-head,
html[dir="rtl"] .site-header-content {
  background-color: var(--bg-sepia) !important;
}
html[dir="rtl"] .gh-canvas,
html[dir="rtl"] .post-card,
html[dir="rtl"] .read-more,
html[dir="rtl"] .kg-card {
  border-color: rgba(0,0,0,0.04) !important;
}

/* Footer stays dark */
html[dir="rtl"] .site-footer,
html[dir="rtl"] .site-footer .outer,
html[dir="rtl"] .site-footer .inner { background-color: #0b0b0b !important; }
html[dir="rtl"] .site-footer { 
  border-top: 1px solid rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.85) !important;
}
html[dir="rtl"] .site-footer a { color: rgba(255,255,255,0.9) !important; }
html[dir="rtl"] .site-footer a:hover { color: #fff !important; }
html[dir="rtl"] .site-footer.outer { padding-top: 0 !important; padding-bottom: 0 !important; }
html[dir="rtl"] .site-footer .inner {
  padding-top: 6px !important; padding-bottom: 6px !important;
  display: flex; align-items: center; gap: 10px; min-height: 0;
}
html[dir="rtl"] .site-footer .copyright,
html[dir="rtl"] .site-footer .site-footer-nav { margin: 0 !important; }
html[dir="rtl"] .site-footer,
html[dir="rtl"] .site-footer * { font-size: 1.6rem; line-height: 2.0; }
html[dir="rtl"] .site-footer-nav .nav { display: flex; gap: 8px; flex-wrap: wrap; }
html[dir="rtl"] .site-footer-nav .nav li { margin: 0 !important; }

/* Ensure nav/header/footer use Adobe Arabic */
html[dir="rtl"] body.has-adobe-body .site-nav,
html[dir="rtl"] body.has-adobe-body .gh-head,
html[dir="rtl"] body.has-adobe-body .gh-head-menu,
html[dir="rtl"] body.has-adobe-body .nav,
html[dir="rtl"] body.has-adobe-body .nav a,
html[dir="rtl"] body.has-adobe-body .site-footer,
html[dir="rtl"] body.has-adobe-body .gh-head-actions,
html[dir="rtl"] body.has-adobe-body .gh-head-link,
html[dir="rtl"] body.has-adobe-body .gh-head-button {
  font-family: "Adobe Arabic", system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif !important;
  font-weight: 400;
}
html[dir="rtl"] { 
  --font-serif: "Adobe Arabic", system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --font-sans-serif: "Adobe Arabic", system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}

/* In RTL, keep header text dark, regardless of has-cover */
html[dir="rtl"] .gh-head {
  color: var(--majera-text) !important;
}

/* In RTL, keep Subscribe button as accent pill */
html[dir="rtl"] .gh-head-button {
  background: var(--ghost-accent-color);
  color: #fff;
}

/* --------------------- 7) Minimal Home (index) – Two-card layout --------------------- */
.home-template .gh-head,
.home-template .gh-foot { display: none; }

.home-template .site-main {
  min-height: 88vh;
  display: grid;
  place-items: center;
  background: var(--majera-bg);
}

.home-template .home-hero {
  text-align: center;
  padding: 6vh 6vw;
}

/* Add breathing room between logo+tagline image and the cards/buttons */
.home-template .home-logo {
  margin-bottom: 3rem;   /* tweak 2–4rem to taste */
}

.home-template .home-logo img {
  max-width: 380px;
  width: 100%;
  height: auto;
  display: inline-block;
}

.home-template .home-title {
  font-family: "Lyon Arabic Display", serif;
  font-size: clamp(32px, 5vw, 52px);
  margin: 0 0 8px;
  color: var(--majera-heading);
}

.home-template .home-tagline {
  font-family: "Adobe Arabic", "Noto Naskh Arabic", serif;
  font-size: clamp(18px, 2.2vw, 26px);
  line-height: 1.45;
  margin: 10px 0 28px;
  color: var(--majera-text);
}

.home-template .home-grid {
  --gap: 28px;
  margin: 0 auto 22px;
  max-width: 1040px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--gap);
  position: relative;
}

@media (min-width: 860px) {
  .home-template .home-grid::before {
    content: "";
    position: absolute;
    top: 6%;
    bottom: 6%;
    left: 50%;
    width: 1px;
    transform: translateX(-50%);
    background: rgba(0,0,0,.10);
    pointer-events: none;
  }
}

@media (max-width: 859.98px) {
  .home-template .home-grid { grid-template-columns: 1fr; gap: 22px; }
}

.home-template .home-card {
  display: block;
  text-align: right;
  background: var(--majera-card-bg);
  border: 1px solid rgba(0,0,0,.10);
  border-radius: 12px;
  padding: clamp(14px, 3vw, 24px);
  color: var(--majera-text);
  text-decoration: none;
  transition: transform .12s ease-out, box-shadow .12s ease-out, border-color .12s ease-out;
  min-height: 160px;
}

.home-template .home-card:hover,
.home-template .home-card:focus {
  transform: translateY(-2px);
  border-color: rgba(0,0,0,.18);
  box-shadow: 0 6px 18px rgba(0,0,0,.08);
  text-decoration: none;
  outline: 1px solid rgba(34,34,34,.18);
  outline-offset: 2px;
}

.home-template .home-card-title {
  font-family: "Lyon Arabic Display", serif;
  font-size: clamp(22px, 3vw, 34px);
  line-height: 1.2;
  margin: 2px 0 8px;
  color: var(--majera-heading);
}

.home-template .home-card:hover .home-card-title,
.home-template .home-card:focus .home-card-title { text-decoration: underline; }

.home-template .home-card-sub {
  font-family: "Adobe Arabic", "Noto Naskh Arabic", serif;
  font-size: clamp(15px, 1.8vw, 17px);
  line-height: 1.45;
  margin: 0;
  color: var(--majera-text-muted);
}

.home-template .home-card--naghz .home-card-brand {
  display: flex;
  justify-content: flex-start;
  margin-bottom: 10px;
}

.home-template .home-card--naghz .home-card-brand img {
  max-height: 56px;
  height: auto;
  width: auto;
  object-fit: contain;
  opacity: .92;
  display: inline-block;
}

.home-template .home-actions {
  margin-top: 16px;
  display: inline-flex;
  gap: 12px;
  align-items: center;
  justify-content: center;
}

.home-template .btn {
  font-family: "Adobe Arabic", "Noto Naskh Arabic", serif;
  font-size: 15px;
  padding: 10px 18px;
  border-radius: 999px;
  text-decoration: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 104px;
  transition: background-color .12s ease-out, color .12s ease-out, border-color .12s ease-out, transform .06s ease-out;
  outline: none;
}

.home-template .btn:focus {
  outline: 1px solid rgba(34,34,34,.28);
  outline-offset: 2px;
}

.home-template .btn-secondary {
  background: transparent;
  color: var(--majera-text);
  border: 1px solid rgba(0,0,0,.22);
}

.home-template .btn-secondary:hover,
.home-template .btn-secondary:focus {
  background: rgba(34,34,34,.06);
  border-color: rgba(0,0,0,.28);
}

.home-template .btn-primary {
  background: var(--ghost-accent-color, #ff9d19);
  color: #fff;
  border: 1px solid var(--ghost-accent-color, #ff9d19);
}

.home-template .btn-primary:hover,
.home-template .btn-primary:focus {
  filter: brightness(0.94);
}

@media (prefers-reduced-motion: no-preference) {
  .home-template .home-logo, 
  .home-template .home-tagline,
  .home-template .home-grid,
  .home-template .home-actions { 
    opacity: 0; 
    transform: translateY(6px);
    animation: homeFade .28s ease-out forwards;
  }

  .home-template .home-logo { animation-delay: .02s; }
  .home-template .home-tagline { animation-delay: .12s; }
  .home-template .home-grid { animation-delay: .20s; }
  .home-template .home-actions { animation-delay: .28s; }

  @keyframes homeFade {
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
}

/* --------------------- 8) Podcasts Hub --------------------- */
.podcasts-hub {
  background: #faf5ee;
  margin: 0 auto;
  max-width: 900px;
  text-align: center;
  padding-top: clamp(24px, 5vw, 48px);
  padding-bottom: clamp(32px, 6vw, 64px);
}
.podcasts-hub .podcasts-hero { margin-bottom: clamp(20px, 4vw, 36px); }
.podcasts-hub .podcasts-title { font-family: "Lyon Arabic Display", serif; font-size: clamp(28px, 4.2vw, 44px); margin: 0 0 8px; color: #222; }
.podcasts-hub .podcasts-intro { font-family: "Adobe Arabic", "Noto Naskh Arabic", serif; font-size: clamp(16px, 2vw, 18px); line-height: 1.75; color: rgba(34,34,34,.9); margin: 0 auto; max-width: 700px; }
.podcasts-hub .show-block { padding-block: clamp(24px, 3.5vw, 36px); }
.podcasts-hub .show-layout {
  display: flex; flex-direction: row-reverse;
  align-items: flex-start; gap: clamp(16px, 3vw, 36px); justify-content: center;
}
.podcasts-hub .show-image { max-width: 160px; height: auto; border-radius: 8px; box-shadow: 0 3px 8px rgba(0,0,0,.08); transition: transform .15s ease-out; }
.podcasts-hub .show-image:hover { transform: translateY(-2px); }
.podcasts-hub .show-text { text-align: right; max-width: 600px; }
.podcasts-hub .show-title { font-family: "Lyon Arabic Display", serif; font-size: clamp(24px, 3.6vw, 38px); margin: 0 0 10px; color: #222; text-decoration: none; }
.podcasts-hub .show-link { text-decoration: none; color: inherit; }
.podcasts-hub .show-link:hover .show-title,
.podcasts-hub .show-link:focus .show-title { text-decoration: underline; }
.podcasts-hub .show-description { font-family: "Adobe Arabic", "Noto Naskh Arabic", serif; font-size: clamp(16px, 2.1vw, 19px); line-height: 1.85; margin: 0; color: rgba(34,34,34,.9); }
.podcasts-hub .show-divider { border: 0; height: 1px; background: rgba(0,0,0,.10); margin: clamp(8px, 2.4vw, 20px) auto; width: 90%; }
@media (max-width: 720px) {
  .podcasts-hub .show-layout { flex-direction: column; align-items: center; text-align: center; }
  .podcasts-hub .show-text { text-align: center; }
  .podcasts-hub .show-image { max-width: 220px; margin-bottom: 12px; }
}

/* --------------------- 9) Naghzonik — Home (minimal grid) --------------------- */
html[dir="rtl"] .naghz-header {
  display: flex; flex-direction: column; align-items: center; text-align: center; margin-bottom: 3rem;
}
html[dir="rtl"] .naghz-logo-wrap { margin-bottom: 1.5rem; }
html[dir="rtl"] .naghz-logo { width: clamp(180px, 25vw, 300px); height: auto; display: block; }

/* Grid container */
/* Base: mobile = 1 column (unchanged) */
html[dir="rtl"] .naghz-home .naghz-grid {
  display: grid;
  grid-template-columns: 1fr; /* mobile */
  gap: 2rem;
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: 1rem;
}

/* All non-mobile (tablets & up): always 3 columns */
@media (min-width: 768px) {
  html[dir="rtl"] .naghz-home .naghz-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Card layout (minimal; no hover effects) */
html[dir="rtl"] .naghz-card { display: flex; flex-direction: column; gap: 0.8rem; }
html[dir="rtl"] .naghz-card-media {
  position: relative; width: 100%; aspect-ratio: 1 / 1; overflow: hidden; border-radius: 12px;
}
html[dir="rtl"] .naghz-card-img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block;
}
html[dir="rtl"] .naghz-card-content { display: grid; gap: 0.4rem; }

/* Title */
html[dir="rtl"] body.has-lyon-title .naghz-card-title {
  font-family: "Lyon Arabic Display", serif;
  font-weight: 400;
  font-size: clamp(2.0rem, 1.7rem + 1.4vw, 3.2rem);
  line-height: 1.35;
  margin: 0 0 0.5rem;
}
html[dir="rtl"] .naghz-card-title a { color: inherit; text-decoration: none; }
html[dir="rtl"] .naghz-card-title a:hover,
html[dir="rtl"] .naghz-card-title a:focus { text-decoration: underline; }

/* Excerpt */
html[dir="rtl"] body.has-adobe-body .naghz-card-deck {
  font-family: "Adobe Arabic", system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  font-size: var(--content-font-size);
  line-height: 1.8;
  color: rgba(0,0,0,0.75);
  margin: 0 0 0.4rem;
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden;
}

/* Meta (author + date) */
html[dir="rtl"] body.has-adobe-body .naghz-card-meta {
  font-family: "Adobe Arabic", system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  font-size: var(--content-font-size);
  line-height: 1.6;
  color: rgba(0,0,0,0.55);
  display: inline-flex; align-items: baseline; gap: 0.5rem;
}
html[dir="rtl"] .naghz-card-dot { opacity: 0.5; }

/* Inline links under header (optional) */
.naghz-inline-links a { text-decoration: none; border-bottom: 1px solid transparent; }
.naghz-inline-links a:hover { border-bottom-color: currentColor; }
.naghz-inline-links .sep { opacity: .5; margin-inline: .4rem; }

/* Naghzonik cards – align with Majera card system */
html[dir="rtl"] .naghz-home .post-card,
html[dir="rtl"] .naghz-archive .post-card {
  background: var(--majera-card-bg);
  border: 1px solid var(--majera-border);
  border-radius: 14px;
  transition:
    box-shadow .15s ease,
    border-color .15s ease,
    transform .03s ease;
}

/* Hover: gentle emphasis */
html[dir="rtl"] .naghz-home .post-card:hover,
html[dir="rtl"] .naghz-archive .post-card:hover {
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.08);
  border-color: var(--majera-accent-soft);
}

/* Title color in cards (optional, keeps it consistent with headings) */
html[dir="rtl"] .naghz-home .post-card-title,
html[dir="rtl"] .naghz-archive .post-card-title {
  color: var(--majera-heading);
}

/* Title hover: slight tilt toward accent */
html[dir="rtl"] .naghz-home .post-card:hover .post-card-title,
html[dir="rtl"] .naghz-archive .post-card:hover .post-card-title {
  color: var(--majera-accent);
}


/* --------------------- 10) Naghzonik — Archive --------------------- */
.naghz-archive .gh-content { background: #faf5ee; max-width: 900px; margin-inline: auto; text-align: center; }
.naghz-arch-head { text-align: center; margin-bottom: clamp(20px, 4vw, 36px); }
.naghz-arch-header-inner { display: flex; flex-direction: column; align-items: center; justify-content: center; }
.naghz-arch-head .nagz-logo-link { display: inline-block; text-decoration: none; }
.naghz-arch-head .nagz-logo {
  max-height: 52px; width: auto; height: auto; display: block; margin: 0 auto 8px; opacity: .95; transition: opacity .15s ease;
}
.naghz-arch-head .nagz-logo:hover { opacity: 1; }
.naghz-arch-intro { font-family: "Adobe Arabic","Noto Naskh Arabic",serif; font-size: clamp(15px, 1.9vw, 17px); color: rgba(34,34,34,.9); margin: 0; }
.naghz-arch-links { margin-top: 4px; font-family: "Adobe Arabic","Noto Naskh Arabic",serif; font-size: 15px; opacity: .85; }
.naghz-arch-links .sep { opacity: .5; margin-inline: .4rem; }
.naghz-arch-links a { text-decoration: none; border-bottom: 1px solid transparent; }
.naghz-arch-links a:hover { border-bottom-color: currentColor; }

/* Rich list */
.nagz-archive__list { list-style: none; padding: 0; margin: clamp(10px, 3vw, 18px) auto 0; max-width: 860px; text-align: right; }
.nagz-archive__list .arch-item { padding: 14px 0 18px; border-bottom: 1px solid rgba(0,0,0,.06); }
.arch-title { margin: 0 0 6px; font-family: "Lyon Arabic Display", serif; font-size: clamp(18px, 2.2vw, 22px); }
.arch-title a { text-decoration: none; color: #222; border-bottom: 1px solid transparent; }
.arch-title a:hover { border-bottom-color: currentColor; }
.arch-meta { font-size: 14px; opacity: .8; display: inline-flex; align-items: baseline; gap: .4ch; margin-bottom: 6px; }
.arch-meta .arch-dot { opacity: .5; }
.archive-authors { white-space: nowrap; }
.arch-excerpt { margin: 6px 0 0; font-family: "Adobe Arabic","Noto Naskh Arabic",serif; font-size: clamp(15px, 1.9vw, 17px); line-height: 1.8; color: rgba(34,34,34,.9); }

/* --------------------- 11) Misc --------------------- */
/* Hide Ghost search icon on mobile; keep it on desktop */
@media (max-width: 767.98px){
  #gh-head .gh-head-brand .gh-search,
  #gh-head .gh-head-actions .gh-search,
  [data-ghost-search]{ display: none !important; }
}

/* === Naghzonik grid: mobile spacing / dividers === */
@media (max-width: 768px) {
  html[dir="rtl"] .naghz-home .naghz-grid {
    gap: 3rem; /* larger vertical gap between cards */
  }

  html[dir="rtl"] .naghz-home .naghz-card {
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08); /* subtle divider */
  }

  /* Remove divider from the last card */
  html[dir="rtl"] .naghz-home .naghz-card:last-child {
    border-bottom: none;
  }
}

/* === Naghzonik single posts — centered header & smaller logo === */

/* Center the whole header block on Naghzonik posts */
html[dir="rtl"] .post-template.tag-hash-naghzonik .article-header {
  text-align: center;
}

/* Logo wrap: centered, with breathing room */
html[dir="rtl"] .naghz-logo-wrap.post-logo {
  display: flex;
  justify-content: center;
  margin-bottom: 2.25rem; /* a bit more space above the title */
}

/* Logo image: smaller than homepage */
html[dir="rtl"] .naghz-logo.post-logo-img {
  width: clamp(100px, 20vw, 160px); /* keep this smaller range */
  height: auto;
  opacity: 0.9;
  transition: opacity .2s ease;
}

/* Hover brighten if the logo is linked */
html[dir="rtl"] .naghz-logo-wrap.post-logo a:hover .naghz-logo.post-logo-img {
  opacity: 1;
}

/* Ensure title + excerpt are truly centered on this tag */
html[dir="rtl"] .post-template.tag-hash-naghzonik .article-header .article-title,
html[dir="rtl"] .post-template.tag-hash-naghzonik .article-header .article-excerpt {
  text-align: center;
  margin-inline: auto;               /* defeat any left/right widths */
  max-width: 64rem;                  /* optional: keep lines nicely wide */
}

/* Make the hero image a touch narrower and centered (only for this tag) */
html[dir="rtl"] .post-template.tag-hash-naghzonik .article-image {
  max-width: 920px;                  /* adjust to taste: 840–980px */
  margin-inline: auto;
  margin-bottom: 1.75rem;            /* breathing room before content */
}
html[dir="rtl"] .post-template.tag-hash-naghzonik .article-image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 12px;               /* optional polish */
}

/* === Podcast episode transcripts (tag: podcast) === */
html[dir="rtl"] .post-template.tag-podcast .gh-content .script-body {
  font-family: "Adobe Arabic","Noto Naskh Arabic",serif;
  font-size: var(--content-font-size);   /* matches Naghzonik body */
  line-height: 1.9;
  color: rgba(0,0,0,0.92);
}

/* Paragraphs, lists, blockquotes inside transcript */
html[dir="rtl"] .post-template.tag-podcast .gh-content .script-body p,
html[dir="rtl"] .post-template.tag-podcast .gh-content .script-body li,
html[dir="rtl"] .post-template.tag-podcast .gh-content .script-body blockquote p {
  font-size: var(--content-font-size);
  line-height: 1.9;
  margin-bottom: 1.3rem;
}

/* Headings inside transcript (consistent with Naghzonik) */
html[dir="rtl"] .post-template.tag-podcast .gh-content .script-body h2 {
  font-family: "Lyon Arabic Display", serif;
  font-size: clamp(1.6rem, 1rem + 0.9vw, 2.2rem);
  line-height: 1.4;
  margin: 2rem 0 1rem;
}
html[dir="rtl"] .post-template.tag-podcast .gh-content .script-body h3 {
  font-family: "Lyon Arabic Display", serif;
  font-size: clamp(1.4rem, 0.9rem + 0.7vw, 1.9rem);
  line-height: 1.4;
  margin: 1.5rem 0 0.8rem;
}

/* Optional: smaller code or time stamps */
html[dir="rtl"] .post-template.tag-podcast .gh-content .script-body pre,
html[dir="rtl"] .post-template.tag-podcast .gh-content .script-body code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-size: 0.9em;
  direction: ltr;
  text-align: left;
}

/* Hide visible "podcast" tag label on episode posts */
html[dir="rtl"] .post-template.tag-podcast .article-header .post-card-primary-tag,
html[dir="rtl"] .post-template.tag-podcast .article-header .article-tag {
  display: none !important;
}

/* === Podcast episode featured image — smaller, centered === */
html[dir="rtl"] .post-template.tag-podcast .article-header .article-image {
  max-width: 300px;        /* badge-like size; try 300–420px to taste */
  margin: 0 auto 1rem;     /* center above the title */
}

html[dir="rtl"] .post-template.tag-podcast .article-header .article-image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 12px;      /* subtle polish */
  box-shadow: 0 2px 10px rgba(0,0,0,.06);
}

/* Optional: give the title a bit of breathing room below the art */
html[dir="rtl"] .post-template.tag-podcast .article-header .article-title {
  margin-top: .25rem;
}

/* === Reorder podcast episode header — image on top === */
html[dir="rtl"] .post-template.tag-podcast .article-header {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Move featured image above title */
html[dir="rtl"] .post-template.tag-podcast .article-header .article-image {
  order: -1;                 /* appear first visually */
  max-width: 340px;
  margin: 0 auto 1rem;
}

/* Keep title and byline centered */
html[dir="rtl"] .post-template.tag-podcast .article-header .article-title {
  text-align: center;
  width: 100%;
}

/* Keep image styling polished */
html[dir="rtl"] .post-template.tag-podcast .article-header .article-image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,.06);
}

/* Locked cards in Naghzonik: dim + blur the image and add a subtle overlay */
html[dir="rtl"] .naghz-home .naghz-card.is-locked .naghz-card-media { position: relative; }
html[dir="rtl"] .naghz-home .naghz-card.is-locked .naghz-card-img {
  filter: blur(2px) brightness(0.6);
  transform: scale(1.02);              /* avoids edge blur artifacts */
  transition: filter .2s ease, transform .2s ease;
  will-change: filter, transform;
}
html[dir="rtl"] .naghz-home .naghz-card.is-locked .naghz-card-media::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,.22), rgba(0,0,0,.28));
  pointer-events: none;
}

/* Center the lock badge over the image (reuse your existing element) */
html[dir="rtl"] .naghz-home .naghz-card .post-card-access {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  z-index: 2; color: #fff; gap: .6rem;
  font-weight: 700; text-shadow: 0 1px 2px rgba(0,0,0,.35);
}

/* Optional: soften on hover/focus (desktop) */
@media (hover:hover) {
  html[dir="rtl"] .naghz-home .naghz-card.is-locked:hover .naghz-card-img,
  html[dir="rtl"] .naghz-home .naghz-card.is-locked:focus-within .naghz-card-img {
    filter: blur(1.5px) brightness(0.65);
    transform: scale(1.015);
  }
}

/* Hide Ghost's built-in upgrade CTA when we use our custom paywall card */
html[dir="rtl"] .gh-post-upgrade-cta,
html[dir="rtl"] .gh-post-upgrade-cta-content {
  display: none !important;
}

/* Podcasts hub: put artwork on the LEFT, text on the RIGHT (within the same column width) */
.podcasts-hub .show-layout {
  flex-direction: row;            /* was row-reverse */
  justify-content: flex-start;    /* keep content inside the column */
  width: 100%;
}

.podcasts-hub .show-image {
  flex: 0 0 160px;                /* fixed art column */
  max-width: 160px;
}

.podcasts-hub .show-text {
  flex: 1 1 auto;                 /* text takes remaining space */
  text-align: right;              /* keep title/desc right-aligned */
}

/* (unchanged) mobile stacks them */
@media (max-width: 720px) {
  .podcasts-hub .show-layout { flex-direction: column; align-items: center; text-align: center; }
  .podcasts-hub .show-text { text-align: center; }
}


/* ------ for responsive video inserts ------ */
.responsive-video {
  position: relative;
  width: 100%;
  padding-top: 56.25%; /* 16:9 default */
}
.responsive-video iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* === Mobile heading size adjustments === */
@media (max-width: 720px) {
  html[dir="rtl"] h2 {
    font-size: 1.55em !important; /* slightly larger on mobile */
    line-height: 1.4 !important;
  }

  html[dir="rtl"] h3 {
    font-size: 1.35em !important;
    line-height: 1.4 !important;
  }
}

/* Center the Majera audio player inside the content column */
.gh-content .audio-dock,
.script-body .audio-dock {
    display: block;
    width: 100%;
    max-width: 640px;      /* or 700–720px if you prefer */
    margin: 2rem auto 1.5rem auto;  /* top / left-right / bottom */
}


