/*
Right-to-left overrides, loaded only when the current language is written right to left (Arabic).
Flexbox and grid mirror themselves; what is listed here is every rule in style.css that names a
physical side, so the page reads from the right without touching the left-to-right stylesheet.
*/

/* Global helpers */
.skip-link { left: auto; right: 12px; }

/* Masthead */
form.search { padding: 0 12px 0 4px; }
.brand__logo { margin-right: 0; }

/* Cards and lists */
.bcard__facts dd,
.tcard__facts dd { text-align: left; }
.tcard__rank { left: auto; right: 18px; }
.hero__facts strong { margin-right: 0; margin-left: 5px; }
.filtermore__count { margin-left: 0; margin-right: 6px; }
.byline__read { margin-left: 0; margin-right: auto; }

/* Review page */
.toc a { border-left: 0; border-right: 2px solid var(--line); }
.toc a:hover { border-left-color: transparent; border-right-color: var(--blue); }
.evlist li { padding-left: 0; padding-right: 20px; }
.evlist li::before { left: auto; right: 0; }
.evlist--plain li,
.evlist li.ev-src { padding-right: 0; }
.sl__col ul,
.panel ul,
.policy ul,
.policy ol,
.prose ul,
.prose ol,
.table ul { padding-left: 0; padding-right: 20px; }
.prose blockquote { padding: 4px 22px 4px 0; border-left: 0; border-right: 3px solid var(--blue); }

/* Tables */
.table th,
.table td { text-align: right; }
.table .num { text-align: left; }

/* Numbers, codes and addresses stay left to right inside right-to-left text */
.ring__val,
.tcard__rank,
.weight__pct,
.region__count,
.acard__num,
.ncard__date,
.filterbar__range output,
.bar__row span:last-child,
.hero__facts strong,
.company dd,
.mono { direction: ltr; unicode-bidi: isolate; }
.bar__row span:last-child,
.region__count { text-align: left; }

/* Arabic reads better with a touch more line height at small sizes */
body { line-height: 1.7; }
.note,
.tile__sub,
.bcard__date,
.tcard__facts,
.bcard__facts { line-height: 1.6; }

/* Language codes stay left to right, whatever the page direction. */
.langs__links { direction: ltr; unicode-bidi: isolate; }
.langs__select { background-position: left 8px center; padding: 4px 8px 4px 24px; }
.masthead__slim-links { justify-content: flex-start; }
