/* =========================================================
   SHAHD ACADEMY — Components v2
   ========================================================= */

/* ---------- HERO (home) ---------- */
.hero {
  padding: 120px 0 50px;
  min-height: 90svh;
  display: flex;
  align-items: center;
  background: radial-gradient(
    120% 90% at 85% 10%,
    var(--sage-tint),
    transparent 60%
  );
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 40px;
  align-items: center;
  width: 100%;
}
.hero-copy {
  max-width: 640px;
}
.hero .eyebrow {
  margin: 0 0 22px;
}
.hero h1 {
  margin: 0 0 24px;
}
.hero-cta {
  display: flex;
  gap: 12px;
  margin: 30px 0;
  flex-wrap: wrap;
}
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.chips li {
  font-size: 0.74rem;
  letter-spacing: 0.02em;
  border: 1px solid var(--line);
  border-radius: 100px;
  padding: 7px 14px;
  color: var(--ink-2);
  background: var(--paper-2);
}
.hero-figure {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-photo {
  position: relative;
  width: 100%;
  max-width: 460px;
  aspect-ratio: 3/4;
  border-radius: 240px 240px 14px 14px;
  overflow: hidden;
  box-shadow: 0 34px 60px rgba(43, 33, 28, 0.2);
  border: 1px solid var(--line-soft);
}
.hero-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 -60px 80px -40px rgba(43, 33, 28, 0.22);
  pointer-events: none;
}
.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 12%;
}
/* faint brand motif on sage sections + page heroes */
.section.sage,
.page-hero {
  position: relative;
}
.section.sage::before,
.page-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url(/assets/brand/pattern.png) center/520px;
  opacity: 0.3;
  mix-blend-mode: multiply;
  pointer-events: none;
}
.section.sage > *,
.page-hero > * {
  position: relative;
  z-index: 1;
}

/* ---------- credibility strip ---------- */
.strip {
  border-block: 1px solid var(--line);
  background: var(--paper-2);
  overflow: hidden;
}
.marquee {
  padding: 16px 0;
  white-space: nowrap;
  overflow: hidden;
}
.marquee-track {
  display: inline-flex;
  align-items: center;
  gap: 26px;
  animation: scroll 42s linear infinite;
  will-change: transform;
}
.marquee-track span {
  font-family: var(--serif);
  font-weight: 300;
  font-style: italic;
  font-size: clamp(1rem, 1.7vw, 1.3rem);
  color: var(--ink-2);
}
[dir="rtl"] .marquee-track span {
  font-style: normal;
  font-weight: 500;
}
.marquee-track i {
  color: var(--brand);
  font-style: normal;
}
@keyframes scroll {
  to {
    transform: translateX(-50%);
  }
}
@media (prefers-reduced-motion: reduce) {
  .marquee-track {
    animation: none;
  }
}

/* ---------- stat band ---------- */
.stat-band {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(20px, 4vw, 50px);
}
.stat {
  text-align: center;
}
.stat b {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  color: var(--brand);
  display: block;
  line-height: 1;
}
.stat span {
  font-size: 0.82rem;
  color: var(--ink-2);
  letter-spacing: 0.02em;
  margin-top: 8px;
  display: block;
}
@media (max-width: 720px) {
  .stat-band {
    grid-template-columns: 1fr 1fr;
    gap: 34px;
  }
}

/* ---------- about ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(36px, 6vw, 84px);
  align-items: center;
}
.about-media {
  position: relative;
}
.about-media img {
  width: 100%;
  aspect-ratio: 4/5;
  max-height: 600px;
  object-fit: cover;
  object-position: center 15%;
  border-radius: 6px;
}
.about-media .frame {
  position: absolute;
  inset: 14px -14px -14px 14px;
  border: 1px solid var(--brand);
  border-radius: 6px;
  z-index: -1;
}
[dir="rtl"] .about-media .frame {
  inset: 14px 14px -14px -14px;
}
.cred-list {
  list-style: none;
  margin: 30px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
}
.cred-list li {
  padding: 18px 0;
  border-top: 1px solid var(--line);
}
.cred-list b {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ink);
}
.cred-list span {
  display: block;
  font-size: 0.8rem;
  color: var(--smoke);
  margin-top: 2px;
}
@media (max-width: 820px) {
  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .cred-list {
    grid-template-columns: 1fr;
  }
}

/* ---------- services ---------- */
.svc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border-top: 1px solid var(--line);
}
/* flex column + margin-top:auto on .tags pins the pill row and the link to the
   bottom of every card, so all three line up however long the copy runs */
.svc {
  padding: 38px 30px 32px;
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
  transition: background 0.4s var(--ease);
  display: flex;
  flex-direction: column;
}
[dir="rtl"] .svc {
  border-right: none;
  border-left: 1px solid var(--line);
}
.svc:first-child {
  border-left: 1px solid var(--line);
}
[dir="rtl"] .svc:first-child {
  border-left: none;
  border-right: 1px solid var(--line);
}
.svc:hover {
  background: var(--sage-tint);
}
.svc-n {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.6rem;
  color: var(--brand);
  display: block;
  margin-bottom: 16px;
}
[dir="rtl"] .svc-n {
  font-style: normal;
}
.svc h3 {
  font-size: 1.4rem;
  margin: 0 0 12px;
  color: var(--ink);
}
.svc p {
  color: var(--ink-2);
  font-size: 0.94rem;
  margin: 0 0 20px;
}
.tags {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  padding: 0;
  margin: 0 0 22px;
}
.tags li {
  font-size: 0.71rem;
  border: 1px solid var(--line);
  border-radius: 100px;
  padding: 5px 11px;
  color: var(--ink-2);
}
.svc .tags {
  margin-top: auto;
}
/* reserve two lines for the heading so the body copy starts level across columns */
@media (min-width: 901px) {
  .svc h3 {
    min-height: calc(2 * 1.62em);
  }
  [dir="rtl"] .svc h3 {
    min-height: calc(2 * 1.8em);
  }
}
.svc-link {
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--brand);
  display: inline-flex;
  gap: 0.5em;
  align-items: center;
  align-self: flex-start;
}
.svc-link span {
  transition: transform 0.35s var(--ease);
}
.svc-link:hover span {
  transform: translateX(5px);
}
[dir="rtl"] .svc-link:hover span {
  transform: translateX(-5px);
}
@media (max-width: 900px) {
  .svc-grid {
    grid-template-columns: 1fr;
  }
  .svc,
  [dir="rtl"] .svc {
    border-left: 1px solid var(--line);
    border-right: 1px solid var(--line);
  }
}

/* ---------- carousel ---------- */
.carousel {
  position: relative;
  max-width: 820px;
  margin-inline: auto;
  border-radius: 8px;
  overflow: hidden;
  background: #000;
  direction: ltr;
}
.car-track {
  display: flex;
  transition: transform 0.7s var(--ease);
}
.car-slide {
  position: relative;
  min-width: 100%;
  margin: 0;
  aspect-ratio: 3/2;
}
.car-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.car-slide figcaption {
  position: absolute;
  left: 0;
  bottom: 0;
  padding: 22px 26px;
  color: #fff;
  font-size: 0.9rem;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.6), transparent);
  width: 100%;
}
[dir="rtl"] .car-slide figcaption {
  direction: rtl;
  text-align: right;
}
.car-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  border: none;
  color: var(--ink);
  font-size: 1.6rem;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: 0.3s var(--ease);
  z-index: 3;
}
.car-arrow:hover {
  background: #fff;
  transform: translateY(-50%) scale(1.08);
}
.car-arrow.prev {
  left: 18px;
}
.car-arrow.next {
  right: 18px;
}
.car-dots {
  position: absolute;
  bottom: 18px;
  right: 24px;
  display: flex;
  gap: 8px;
  z-index: 3;
}
.car-dots button {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.45);
  cursor: pointer;
  padding: 0;
  transition: 0.3s;
}
.car-dots button.on {
  background: #fff;
  width: 22px;
  border-radius: 5px;
}

/* ---------- reels (Bunny) ---------- */
.reel-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  max-width: 1000px;
  margin: 0 auto;
}
.reel {
  position: relative;
  aspect-ratio: 16/9;
  margin: 0;
  border-radius: 10px;
  overflow: hidden;
  background: #000;
  border: 1px solid var(--line);
}
.reel iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.reel-note {
  max-width: 1000px;
  margin: 16px auto 0;
  text-align: center;
  font-size: 0.82rem;
  color: var(--smoke);
}
@media (max-width: 760px) {
  .reel-grid {
    grid-template-columns: 1fr;
  }
}

/* ---------- gallery (uniform tiles) ---------- */
.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.gallery figure {
  margin: 0;
  aspect-ratio: 4/5;
  border-radius: 8px;
  overflow: hidden;
  position: relative;
  background: var(--sage-tint);
}
.gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 22%;
  display: block;
  transition: transform 0.6s var(--ease);
}
.gallery figure:hover img {
  transform: scale(1.05);
}
.gallery figcaption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 18px 18px 15px;
  color: #fff;
  font-size: 0.82rem;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.7), transparent);
  opacity: 0;
  transition: opacity 0.35s var(--ease);
}
.gallery figure:hover figcaption {
  opacity: 1;
}
@media (max-width: 820px) {
  .gallery {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 480px) {
  .gallery {
    grid-template-columns: 1fr;
  }
  .gallery figure {
    aspect-ratio: 3/2;
  }
}

/* ---------- certificates ---------- */
.cert-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.cert {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  transition: 0.4s var(--ease);
  display: flex;
  flex-direction: column;
}
.cert:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 50px rgba(43, 33, 28, 0.12);
}
.cert-img {
  aspect-ratio: 1.4/1;
  overflow: hidden;
  background: var(--sage-tint);
  border-bottom: 1px solid var(--line-soft);
}
.cert-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 10px;
}
.cert-body {
  padding: 20px 22px 22px;
}
.cert-body h3 {
  font-size: 1.12rem;
  margin: 0 0 5px;
  color: var(--ink);
}
.cert-body .issuer {
  font-size: 0.82rem;
  color: var(--brand);
  font-weight: 600;
  margin: 0 0 10px;
}
.cert-body p {
  font-size: 0.86rem;
  color: var(--ink-2);
  margin: 0;
  line-height: 1.55;
}
@media (max-width: 900px) {
  .cert-grid {
    grid-template-columns: 1fr 1fr;
  }
}
@media (max-width: 600px) {
  .cert-grid {
    grid-template-columns: 1fr;
  }
}

/* ---------- testimonials ---------- */
.tst-carousel {
  position: relative;
  overflow: hidden;
}
.tst-track {
  display: flex;
  gap: 22px;
  transition: transform 0.6s var(--ease);
  will-change: transform;
}
.tst-dots {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-top: 26px;
}
.tst-dots button {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: var(--line);
  cursor: pointer;
  padding: 0;
  transition: 0.3s;
}
.tst-dots button.on {
  background: var(--brand);
  width: 22px;
  border-radius: 5px;
}
.tst {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 30px 32px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  position: relative;
}
.tst::before {
  content: "\201C";
  position: absolute;
  top: 14px;
  inset-inline-end: 26px;
  font-family: var(--serif);
  font-size: 4rem;
  line-height: 1;
  color: var(--sage);
  opacity: 0.8;
}
.tst-quote {
  font-family: var(--serif);
  font-weight: 300;
  font-size: 1.16rem;
  line-height: 1.5;
  color: var(--ink);
  margin: 0;
  position: relative;
  z-index: 1;
}
[dir="rtl"] .tst-quote {
  font-weight: 400;
}
.tst-who {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: auto;
}
.tst-av {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--brand);
  color: var(--paper);
  display: grid;
  place-items: center;
  font-family: var(--serif);
  font-size: 1.2rem;
  flex: none;
}
.tst-name,
.tst-from {
  display: block;
}
.tst-name {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ink);
}
.tst-from {
  font-size: 0.8rem;
  color: var(--smoke);
}
@media (max-width: 760px) {
  .tst-grid {
    grid-template-columns: 1fr;
  }
}

/* ---------- contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(36px, 6vw, 80px);
  align-items: start;
}
.contact-list {
  list-style: none;
  padding: 0;
  margin: 30px 0 0;
}
.contact-list li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 20px;
  padding: 18px 0;
  border-top: 1px solid rgba(246, 242, 236, 0.18);
}
.contact-list li:last-child {
  border-bottom: 1px solid rgba(246, 242, 236, 0.18);
}
.contact-list a {
  font-family: var(--serif);
  font-weight: 300;
  font-size: 1.35rem;
}
.contact-list a:hover {
  color: var(--sage);
}
.contact-list span {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #a89f96;
}
[dir="rtl"] .contact-list span {
  letter-spacing: 0;
}
.contact-cards {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.cta-card {
  border: 1px solid rgba(246, 242, 236, 0.22);
  border-radius: 8px;
  padding: 24px 26px;
  transition: 0.4s var(--ease);
  display: block;
}
.cta-card:hover {
  background: var(--paper);
  color: var(--ink);
  transform: translateX(6px);
}
[dir="rtl"] .cta-card:hover {
  transform: translateX(-6px);
}
.cta-card h3 {
  font-size: 1.25rem;
  margin: 0 0 5px;
  color: inherit;
}
.cta-card p {
  margin: 0 0 14px;
  font-size: 0.88rem;
  color: #d9d2ca;
}
.cta-card:hover p {
  color: var(--ink-2);
}
.cta-go {
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--sage);
}
.cta-card:hover .cta-go {
  color: var(--brand);
}
[dir="rtl"] .cta-go {
  letter-spacing: 0;
}
.elsewhere {
  margin-top: 34px;
}
.elsewhere-label {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #a89f96;
  margin-bottom: 13px;
}
[dir="rtl"] .elsewhere-label {
  letter-spacing: 0;
}
/* QR block */
.qr-card {
  display: flex;
  gap: 20px;
  align-items: center;
  margin-top: 30px;
  padding: 20px;
  background: rgba(246, 242, 236, 0.06);
  border: 1px solid rgba(246, 242, 236, 0.16);
  border-radius: 12px;
}
.qr-card img {
  width: 120px;
  height: 120px;
  border-radius: 8px;
  background: #fff;
  padding: 8px;
  flex: none;
}
.qr-card .qr-t {
  font-family: var(--serif);
  font-size: 1.1rem;
  color: var(--paper);
  margin: 0 0 4px;
}
.qr-card .qr-d {
  font-size: 0.84rem;
  color: #d9d2ca;
  margin: 0;
}
@media (max-width: 760px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

/* ---------- faq ---------- */
.faq-list {
  border-top: 1px solid var(--line);
  max-width: 940px;
}
.faq-item {
  border-bottom: 1px solid var(--line);
}
.faq-item summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 26px 4px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.1rem, 2.2vw, 1.45rem);
  color: var(--ink);
}
.faq-item summary::-webkit-details-marker {
  display: none;
}
.faq-item summary::after {
  content: "+";
  font-family: var(--sans);
  font-size: 1.5rem;
  color: var(--brand);
  flex: none;
  transition: transform 0.35s var(--ease);
}
.faq-item[open] summary::after {
  transform: rotate(45deg);
}
.faq-a {
  overflow: hidden;
  padding: 0 4px;
}
.faq-a p {
  margin: 0 0 26px;
  max-width: 70ch;
  color: var(--ink-2);
  font-size: 1rem;
  line-height: 1.65;
}
.faq-item[open] .faq-a {
  animation: faqOpen 0.4s var(--ease);
}
@keyframes faqOpen {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

/* ---------- stage/topics ---------- */
.stage-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 30px;
  margin-bottom: 34px;
  flex-wrap: wrap;
}
.stage-side {
  display: flex;
  align-items: center;
  gap: 26px;
  flex-wrap: wrap;
}
.topics {
  list-style: none;
  display: flex;
  gap: 20px;
  padding: 0;
  margin: 0;
  flex-wrap: wrap;
}
.topics li {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.02rem;
  color: var(--ink-2);
  position: relative;
  padding-left: 16px;
}
[dir="rtl"] .topics li {
  font-style: normal;
  padding-left: 0;
  padding-right: 16px;
}
.topics li::before {
  content: "—";
  position: absolute;
  left: 0;
  color: var(--brand);
}
[dir="rtl"] .topics li::before {
  left: auto;
  right: 0;
}

/* two-column media rows (about/speaking) */
.media-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(30px, 5vw, 70px);
  align-items: center;
  margin-top: clamp(40px, 6vw, 80px);
}
.media-row.flip .media-row-img {
  order: 2;
}
.media-row-img img {
  width: 100%;
  border-radius: 8px;
  aspect-ratio: 4/3;
  object-fit: cover;
}
.media-row h3 {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  margin: 0 0 14px;
  color: var(--ink);
}
@media (max-width: 820px) {
  .media-row {
    grid-template-columns: 1fr;
    gap: 26px;
  }
  .media-row.flip .media-row-img {
    order: 0;
  }
}

/* cta band */
.cta-band {
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}
.cta-band h2 {
  margin: 0 0 18px;
}
.cta-band .btn {
  margin-top: 8px;
}

/* show testimonials matching the active site language */

/* ---------- mobile hero (stack + aligned photo, consistent EN/AR) ---------- */
@media (max-width: 820px) {
  .hero {
    min-height: auto;
    padding: 100px 0 34px;
    display: block;
  }
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 26px;
  }
  .hero-copy {
    max-width: none;
  }
  .hero .display {
    font-size: clamp(3.2rem, 13vw, 4rem);
    line-height: 1.02;
  }
  .hero .lede {
    max-width: none;
  }
  .hero-figure {
    margin-top: 6px;
  }
  .hero-photo {
    max-width: 360px;
  }
}
html[lang="ar"] .hero .display {
  font-size: clamp(3rem, 12vw, 3.7rem);
  line-height: 1.16;
}
@media (min-width: 821px) {
  html[lang="ar"] .hero .display {
    font-size: clamp(2.9rem, 7vw, 5.4rem);
  }
}

/* carousel cards: equal height.
   align-self:stretch rather than height:100% — the track has no definite height,
   so the percentage had nothing to resolve against and cards kept their own. */
.tst-track {
  align-items: stretch;
}
.tst-carousel .tst {
  margin: 0;
  align-self: stretch;
}
/* .tst-who already carries margin-top:auto, so the author block sits on the
   baseline of every card once the cards themselves are equal height */

/* =========================================================
   BLOG — index cards, article layout, figures
   ========================================================= */
.wrap-narrow {
  max-width: 760px;
  margin-inline: auto;
}
.wrap-wide {
  max-width: 1080px;
  margin-inline: auto;
}

/* --- index --- */
.post-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 34px;
}
.post-list-2 {
  grid-template-columns: repeat(2, 1fr);
}
.post-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  transition:
    transform 0.4s var(--ease),
    box-shadow 0.4s var(--ease);
}
.post-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 54px rgba(43, 33, 28, 0.1);
}
.post-card::after {
  display: none;
}
.post-card-art {
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--sage-tint);
}
.post-card-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.post-card-copy {
  padding: 26px 28px 30px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}
.post-card-copy h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.42rem;
  line-height: 1.16;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin: 0;
}
.post-card-desc {
  font-size: 0.92rem;
  color: var(--ink-2);
  margin: 0;
}
.post-card .tags {
  margin: 0;
}
.post-card .svc-link {
  margin-top: auto;
  padding-top: 6px;
}
.post-meta {
  font-family: var(--sans);
  font-size: 0.76rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--smoke);
  margin: 0;
}
.post-meta .num {
  font-family: var(--serif);
  font-style: italic;
  text-transform: none;
  color: var(--brand);
  margin-inline-end: 6px;
}
.post-meta a {
  color: var(--brand);
  font-weight: 600;
}

/* --- article --- */
.post-head {
  padding: 60px 0 26px;
}
.post-head h1 {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(2.1rem, 4.6vw, 3.3rem);
  line-height: 1.06;
  letter-spacing: -0.02em;
  margin: 14px 0 0;
  text-wrap: balance;
}
.post-standfirst {
  font-size: clamp(1.02rem, 1.5vw, 1.2rem);
  line-height: 1.55;
  color: var(--ink-2);
  margin: 18px 0 0;
  max-width: 60ch;
}
.post-hero {
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 16/9;
  background: var(--sage-tint);
  margin-bottom: 52px;
}
.post-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.post-body {
  font-size: 1.06rem;
  line-height: 1.75;
  color: var(--ink-2);
}
.post-body > * + * {
  margin-top: 1.15em;
}
.post-body h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.62rem;
  line-height: 1.2;
  letter-spacing: -0.012em;
  color: var(--ink);
  margin-top: 2.1em;
  text-wrap: balance;
}
.post-body h3 {
  font-size: 1.16rem;
  color: var(--ink);
  margin-top: 1.7em;
}
.post-body strong {
  color: var(--ink);
  font-weight: 600;
}
.post-body a {
  color: var(--brand);
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.post-body ul,
.post-body ol {
  padding-inline-start: 1.3em;
  display: flex;
  flex-direction: column;
  gap: 0.55em;
}
.post-body li {
  padding-inline-start: 0.2em;
}
.post-body li::marker {
  color: var(--brand);
}
.post-body blockquote {
  margin: 1.6em 0;
  padding: 4px 0 4px 22px;
  border-inline-start: 3px solid var(--brand);
  font-family: var(--serif);
  font-size: 1.2rem;
  line-height: 1.5;
  color: var(--ink);
}
[dir="rtl"] .post-body blockquote {
  padding: 4px 22px 4px 0;
}
.post-body code {
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 0.88em;
  background: var(--sage-tint);
  padding: 0.12em 0.38em;
  border-radius: 4px;
  color: var(--ink);
}
.post-rule {
  border: none;
  border-top: 1px solid var(--line);
  margin: 2.4em 0;
}

/* --- figures --- */
.post-fig {
  margin: 2.2em 0;
  padding: 0;
}
.post-fig-art {
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 26px 22px;
  overflow-x: auto;
}
.post-fig svg {
  width: 100%;
  height: auto;
  min-width: 520px;
  display: block;
}
.post-fig .fig-n {
  font-family: var(--serif);
  font-style: italic;
  font-size: 15px;
}
.post-fig .fig-t {
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 600;
}

.post-fig .fig-m {
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 14px;
}
.post-fig .fig-s {
  font-family: var(--sans);
  font-size: 12.5px;
}
/* colour ONLY when the element sets no fill of its own — a CSS fill beats the
   presentation attribute, which was silently blanking every coloured label */
.post-fig .fig-n:not([fill]) {
  fill: var(--brand);
}
.post-fig .fig-t:not([fill]) {
  fill: var(--ink);
}
.post-fig .fig-m:not([fill]) {
  fill: var(--ink);
}
.post-fig .fig-s:not([fill]) {
  fill: var(--smoke);
}
.post-fig .fig-on:not([fill]) {
  fill: var(--paper);
}
.post-fig figcaption {
  font-size: 0.85rem;
  color: var(--smoke);
  margin-top: 12px;
  text-align: center;
  font-family: var(--sans);
}

/* --- footer of an article --- */
.post-cta {
  margin: 56px 0 0;
  padding: 34px 36px;
  background: var(--sage-tint);
  border: 1px solid var(--line);
  border-radius: 16px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.post-cta-h {
  font-family: var(--serif);
  font-size: 1.3rem;
  color: var(--ink);
  margin: 0;
  max-width: 34ch;
}
.post-byline {
  margin: 34px 0 0;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  font-size: 0.88rem;
  color: var(--smoke);
}
.post-byline a {
  color: var(--brand);
  font-weight: 600;
}

@media (max-width: 860px) {
  .post-list,
  .post-list-2 {
    grid-template-columns: 1fr;
    gap: 26px;
  }
  .post-head {
    padding: 40px 0 20px;
  }
  .post-hero {
    margin-bottom: 36px;
    border-radius: 12px;
  }
  .post-cta {
    padding: 26px 24px;
  }
}
