/*
 * Arabic homepage typography — approved 5 September 2026.
 * Modern governmental direction: Noto Kufi Arabic for hierarchy,
 * IBM Plex Sans Arabic for reading text. Scoped to the Arabic homepage only.
 */
@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Sans+Arabic:wght@400;500;600&family=Noto+Kufi+Arabic:wght@400;500;600;700&display=swap');

html[dir='rtl'] body.home {
  font-family: 'IBM Plex Sans Arabic', Arial, sans-serif !important;
  font-synthesis: none;
}

/* Calm, legible reading text and service elements. */
html[dir='rtl'] body.home :is(
  p,
  li,
  small,
  em,
  label,
  input,
  textarea,
  select,
  button,
  .cerax-home-section-heading > span,
  .cerax-home-section-heading > a,
  .eosp-photo-summary,
  .cerax-briefing-cards em,
  .cerax-briefing-region-body p,
  .cerax-briefing-region-body small,
  .cerax-home-hero-copy p,
  .eosp-principle-card__content p
) {
  font-family: 'IBM Plex Sans Arabic', Arial, sans-serif !important;
  letter-spacing: 0 !important;
}

/* Kufi hierarchy: confident, measured and suitable for public institutional use. */
html[dir='rtl'] body.home :is(
  h1,
  h2,
  h3,
  h4,
  h5,
  h6,
  .cerax-briefing-cards b,
  .cerax-briefing-feature b,
  .cerax-region-card b,
  .cerax-region-card strong,
  .cerax-advisory-card b,
  .cerax-advisory-card strong,
  .cerax-diplomacy-paths h3,
  .cerax-dialogue-programme h3,
  .cerax-dialogue-format h3,
  .eosp-photo-caption h3,
  .eosp-principle-card__content h3,
  .eosp-cover__title
) {
  font-family: 'Noto Kufi Arabic', Arial, sans-serif !important;
  font-weight: 600 !important;
  letter-spacing: 0 !important;
  text-wrap: pretty;
}

/* Keep large display headings imposing without becoming dense on Arabic lines. */
html[dir='rtl'] body.home :is(
  .cerax-hero h1,
  .cerax-hero h2,
  .cerax-home-hero h1,
  .cerax-home-hero h2,
  .cerax-room-intro h1,
  .cerax-room-intro h2,
  .cerax-briefing-feature h3,
  .cerax-featured-publication h3
) {
  font-weight: 600 !important;
  line-height: 1.38 !important;
}

/* Editorial cards retain hierarchy, with a little additional breathing room. */
html[dir='rtl'] body.home :is(
  .eosp-photo-caption h3,
  .cerax-briefing-cards b,
  .cerax-region-card b,
  .eosp-principle-card__content h3
) {
  line-height: 1.55 !important;
}

html[dir='rtl'] body.home :is(
  .cerax-home-section-heading > span,
  .cerax-home-section-heading > a,
  .cerax-home-hero-copy > span,
  .cerax-briefing-feature > span,
  .cerax-room-intro > span,
  .cerax-advisory-card small,
  .cerax-diplomacy-paths small
) {
  font-family: 'IBM Plex Sans Arabic', Arial, sans-serif !important;
  font-weight: 600 !important;
  letter-spacing: .035em !important;
}

@media (max-width: 780px) {
  html[dir='rtl'] body.home :is(
    .cerax-hero h1,
    .cerax-hero h2,
    .cerax-home-hero h1,
    .cerax-home-hero h2,
    .cerax-room-intro h1,
    .cerax-room-intro h2
  ) {
    line-height: 1.45 !important;
  }
}
