/* =========================================================
   Right-to-left overrides (Arabic).
   The core stylesheet uses CSS logical properties throughout,
   so direction is largely handled by dir="rtl" alone. This file
   only swaps the type stack and fixes the few physical values.
   ========================================================= */

:root {
  --display: "IBM Plex Sans Arabic", system-ui, sans-serif;
  --body:    "IBM Plex Sans Arabic", system-ui, sans-serif;
}

body { line-height: 1.85; }

h1, h2, h3, h4 { line-height: 1.28; letter-spacing: 0; font-weight: 600; }

/* Latin-derived tracking looks wrong on Arabic – reset it */
.eyebrow, .tag, .crumbs, thead th, .footer h4, .sd-legend dt, .langs a {
  letter-spacing: 0;
  font-family: var(--body);
}

/* Numerals and measurements stay LTR inside RTL text */
.num, .sd-readout, .sd-legend dd, td.date, .stats dt, .amounts strong {
  direction: ltr;
  unicode-bidi: isolate;
  font-family: "IBM Plex Mono", ui-monospace, monospace;
}

.sd-bar b, .sd-hazard::after { direction: ltr; unicode-bidi: isolate; }

/* Hazard kerbing stripes should lean with the reading direction */
.sd-road::before, .sd-road::after {
  background: repeating-linear-gradient(45deg,
    var(--signal) 0 11px, var(--asphalt) 11px 22px);
}
