/* =========================================================================
   RTL — loaded only on Arabic pages (html[dir="rtl"]).
   Logical properties (inset-inline, margin-inline, padding-inline, text-align:
   start/end) already used throughout components.css/layout.css flip
   automatically. This file holds the handful of things that need a genuine
   design decision rather than a mechanical mirror.
   ========================================================================= */

html[dir="rtl"] {
  font-family: var(--font-body-ar);
}

/* Numerals, order/serial IDs and QR codes stay LTR even inside RTL flow —
   mirroring a QR code or a serial number would make it unreadable/unscannable. */
html[dir="rtl"] .mono,
html[dir="rtl"] .keep-ltr {
  direction: ltr;
  unicode-bidi: isolate;
  display: inline-block;
}

/* The eyebrow marker rotates to read naturally in the mirrored composition */
html[dir="rtl"] .eyebrow::before { order: 2; }

/* Arabic type needs a touch more line-height and slightly larger body size
   for comfortable reading — a deliberate choice, not a bug fix. */
html[dir="rtl"] body { line-height: 1.85; }
html[dir="rtl"] p { font-size: 1.04em; }

/* Display headlines: Arabic has no small-caps/serif display face loaded, so
   headline hierarchy leans on weight + a gold underline dash instead of
   italic accents (which don't exist in the Arabic display cut). */
html[dir="rtl"] h1 em, html[dir="rtl"] h2 em { font-style: normal; color: var(--gold-600); }

/* Icons that imply direction (arrows) flip; icons that don't (checkmarks,
   QR corners, paw prints) must NOT flip. Mark direction-agnostic icons with
   .icon-static from the markup side. */
html[dir="rtl"] .icon-directional { transform: scaleX(-1); }

/* Stepper progress bars run the opposite visual direction in RTL, which is
   handled by flex row-reverse rather than mirroring each element internally */
html[dir="rtl"] .stepper { direction: rtl; }

/* Phone frame stays LTR-shaped (a physical object doesn't mirror) but its
   text content inside flips via inherited dir */
html[dir="rtl"] .phone-frame { direction: rtl; }

/* Card corner motifs swap sides intentionally to keep the "entry point" of
   the eye in the correct reading-direction corner */
html[dir="rtl"] .img-frame.with-corners::before { left: auto; right: 14px; border-right: 3px solid var(--gold-400); border-left: none; }
html[dir="rtl"] .img-frame.with-corners::after { right: auto; left: 14px; border-left: 3px solid var(--gold-400); border-right: none; }
