/* ============================================================
   KOVINTA — Arabic (RTL) layer
   Loaded after style.css on the Arabic page only. It swaps the
   typeface family and mirrors the handful of physical properties
   the base sheet still uses.

   Type: Cairo (600-900 variable) for display — a heavy geometric
   Kufi that carries the same weight as Archivo does in English —
   and Tajawal for running text. Both are standard choices in the
   Gulf and Egyptian corporate market.
   ============================================================ */

@font-face { font-family: 'CairoAr'; font-style: normal; font-weight: 600 900; font-display: swap; src: url(../fonts/Cairo-arabic-600900.woff2) format('woff2'); unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0898-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC; }
@font-face { font-family: 'CairoAr'; font-style: normal; font-weight: 600 900; font-display: swap; src: url(../fonts/Cairo-latin-600900.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2212, U+FEFF, U+FFFD; }

@font-face { font-family: 'TajawalAr'; font-style: normal; font-weight: 400; font-display: swap; src: url(../fonts/Tajawal-arabic-400.woff2) format('woff2'); unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0898-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC; }
@font-face { font-family: 'TajawalAr'; font-style: normal; font-weight: 500; font-display: swap; src: url(../fonts/Tajawal-arabic-500.woff2) format('woff2'); unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0898-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC; }
@font-face { font-family: 'TajawalAr'; font-style: normal; font-weight: 700; font-display: swap; src: url(../fonts/Tajawal-arabic-700.woff2) format('woff2'); unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0898-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC; }
@font-face { font-family: 'TajawalAr'; font-style: normal; font-weight: 400; font-display: swap; src: url(../fonts/Tajawal-latin-400.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2212, U+FEFF, U+FFFD; }
@font-face { font-family: 'TajawalAr'; font-style: normal; font-weight: 500; font-display: swap; src: url(../fonts/Tajawal-latin-500.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2212, U+FEFF, U+FFFD; }
@font-face { font-family: 'TajawalAr'; font-style: normal; font-weight: 700; font-display: swap; src: url(../fonts/Tajawal-latin-700.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2212, U+FEFF, U+FFFD; }

/* ---------- Family swap ---------- */
[dir="rtl"] {
  --display: 'CairoAr', 'TajawalAr', sans-serif;
  --body: 'TajawalAr', sans-serif;
  --mono: 'TajawalAr', 'PlexMono', monospace;
}
[dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] h3, [dir="rtl"] h4 {
  font-weight: 800;
  letter-spacing: 0;            /* Arabic must never be letter-spaced */
  line-height: 1.45;            /* Cairo's ascenders and descenders need room */
}
[dir="rtl"] .hero h1 { font-weight: 900; line-height: 1.35; letter-spacing: 0; }
[dir="rtl"] .h-sect { font-weight: 800; }
[dir="rtl"] body { line-height: 1.9; }
[dir="rtl"] .btn { font-weight: 700; }

/* Uppercase and tracking are meaningless in Arabic */
[dir="rtl"] .eyebrow,
[dir="rtl"] .divisions,
[dir="rtl"] .hero-tag,
[dir="rtl"] .spec-grid span,
[dir="rtl"] .creds-row,
[dir="rtl"] .nav-list a,
[dir="rtl"] .f-title,
[dir="rtl"] .step-tab,
[dir="rtl"] .field > label,
[dir="rtl"] .chip,
[dir="rtl"] .eq-class,
[dir="rtl"] .term .lbl,
[dir="rtl"] .routes-card h3,
[dir="rtl"] .route-table th,
[dir="rtl"] .route-table .ctry,
[dir="rtl"] .map-legend,
[dir="rtl"] .map-note,
[dir="rtl"] .contact-list .lbl,
[dir="rtl"] .registry .lbl,
[dir="rtl"] .gal-cap,
[dir="rtl"] .insp-num,
[dir="rtl"] .eq-models,
[dir="rtl"] .pr-port,
[dir="rtl"] .pr-days,
[dir="rtl"] .unit-spec dt,
[dir="rtl"] .unit-sub,
[dir="rtl"] .unit-badge,
[dir="rtl"] .proto-ports .lbl,
[dir="rtl"] .map-chart-title,
[dir="rtl"] .flag-direct,
[dir="rtl"] .flag-ts {
  text-transform: none;
  letter-spacing: 0;
}
[dir="rtl"] .eyebrow { font-size: 0.82rem; }
[dir="rtl"] .field > label { font-size: 0.8rem; }
[dir="rtl"] .step-tab { font-size: 0.82rem; }

/* Figures stay in Western digits and always read left-to-right.
   (.term .big is NOT here: it mixes Arabic words with a numeric range, and the
   bidi algorithm already keeps "7–14" intact inside RTL text.) */
[dir="rtl"] .spec-grid b,
[dir="rtl"] .cp-days,
[dir="rtl"] .unit-spec dd:not(.ok),
[dir="rtl"] .route-table .days,
[dir="rtl"] .registry .val,
[dir="rtl"] .creds-row .k,
[dir="rtl"] .eq-class,
[dir="rtl"] .eq-models,
[dir="rtl"] .insp-num {
  direction: ltr;
  unicode-bidi: isolate;
  font-family: var(--mono);
}
/* Forcing LTR keeps Western figures in order, but the value must still sit
   under its own label on the right-hand edge. */
[dir="rtl"] .unit-spec dd,
[dir="rtl"] .eq-models { text-align: right; }
/* The feature-panel model lines are Arabic-led, so they belong in the RTL
   flow; the equipment-card lines above are pure Latin and keep the isolation. */
[dir="rtl"] .eq-feature .eq-models { direction: rtl; text-align: right; }
[dir="rtl"] .spec-grid b, [dir="rtl"] .term .big { font-family: 'CairoAr', sans-serif; font-weight: 800; }
/* The Latin display line-height (1.05) beheads Arabic ascenders and clips the
   descenders of the big figures — Arabic needs the taller box. */
[dir="rtl"] .term .big { line-height: 1.5; }
[dir="rtl"] .spec-grid b { line-height: 1.4; }

/* ---------- Mirror the physical properties the base sheet still uses ---------- */

[dir="rtl"] .eyebrow::before { margin-left: 0; }
[dir="rtl"] .brand { margin-right: 0; margin-left: auto; }

[dir="rtl"] .spec-grid > div { border-right: none; border-left: 1px solid var(--line); padding-left: clamp(0.5rem, 1.6vw, 1.25rem); padding-right: 0; }
[dir="rtl"] .spec-grid > div:first-child { padding-right: 0; }
[dir="rtl"] .spec-grid > div:last-child { border-left: none; }
@media (max-width: 720px) {
  [dir="rtl"] .spec-grid > div:nth-child(2n) { border-left: none; }
  [dir="rtl"] .spec-grid > div:nth-child(3) { padding-right: 0; }
}

[dir="rtl"] .eq-class { left: auto; right: 0.75rem; }
[dir="rtl"] .gal-cap { text-align: right; }
[dir="rtl"] .route-table th:last-child,
[dir="rtl"] .route-table td:last-child { text-align: left; }
[dir="rtl"] .route-table th { text-align: right; }
[dir="rtl"] .route-table .rgroup-head th,
[dir="rtl"] .route-table .rgroup-note td { text-align: right; }

[dir="rtl"] .note { border-left: none; border-right: 2px solid var(--royal); border-radius: var(--r) 0 0 var(--r); }
[dir="rtl"] .send-error { border-left: 1px solid #f0c2bc; border-right: 3px solid #c0392b; }

[dir="rtl"] .field select {
  background-position: left 0.85rem center;
  padding-left: 2.4rem;
  padding-right: 0.9rem;
}
[dir="rtl"] .switch input:checked + .track::after { transform: translateX(-22px); }
[dir="rtl"] .switch .track::after { left: auto; right: 3px; }

[dir="rtl"] .lightbox-close { right: auto; left: clamp(0.7rem, 2vw, 1.4rem); }
[dir="rtl"] .skip-link:focus, [dir="rtl"] .skip-link:focus-visible { left: auto; right: 0.65rem; }
[dir="rtl"] .wa-float { right: auto; left: clamp(0.85rem, 2.5vw, 1.5rem); }
@media (max-width: 1024px) { [dir="rtl"] .wa-float { left: 0; right: 0; } }

/* Latin-authored inline SVG icons should mirror with the text */
[dir="rtl"] #toStep2 svg,
[dir="rtl"] #backStep1 svg,
[dir="rtl"] .eq-cta a svg { transform: scaleX(-1); }
[dir="rtl"] .eq-cta a:hover svg { transform: scaleX(-1) translateX(4px); }
[dir="rtl"] .eq-card::before { transform-origin: right; }
[dir="rtl"] .eq-feature::before { transform-origin: right; }
[dir="rtl"] .eq-tag { letter-spacing: 0; text-transform: none; }
[dir="rtl"] #terms { background-position: left -4rem top 14%, 0 0, 0 0; }

/* The language switcher pill is styled in the base sheet; its label here is
   Latin ("English"), which needs no RTL override. */

/* A postal address and an e-mail are Latin strings: force LTR so the house
   number and postcode do not jump to the wrong end under bidi reordering. */
[dir="rtl"] .contact-list .val,
[dir="rtl"] .f-list li.latin,
[dir="rtl"] .contact-list a[href^="mailto"],
[dir="rtl"] .f-list a[href^="mailto"] {
  direction: ltr;
  unicode-bidi: isolate;
  text-align: right;
  justify-content: flex-end;
}
[dir="rtl"] .field input::placeholder { text-align: right; }

/* The map is a Latin-authored graphic: keep its internal direction LTR */
[dir="rtl"] .map-panel svg { direction: ltr; }
[dir="rtl"] .map-label { font-family: 'TajawalAr', sans-serif; font-weight: 700; }
[dir="rtl"] .map-label-sm { font-family: 'TajawalAr', sans-serif; }

/* New 2026 components: mirror the physical edges */
[dir="rtl"] .unit-badge { left: auto; right: 0.7rem; }
[dir="rtl"] .proto-code, [dir="rtl"] .cp-head { letter-spacing: 0; }
