/* ==========================================================================
   rtl.css — Right-to-Left overrides for Arabic mode
   Applied when body has class "rtl"
   ========================================================================== */

/* ── Base direction ── */
body.rtl {
  direction: rtl;
}

/* ── Navbar: logo on right, nav in center, actions on left ── */
/* direction:rtl on a flex container reverses the main axis automatically */
body.rtl .navbar {
  direction: rtl;
}

body.rtl .navbar__logo {
  order: 1;
}

body.rtl .navbar__nav {
  order: 2;
  flex: 1;
  justify-content: center;
}

/* Override LTR margin-left:auto; use margin-right:auto to push to far left in RTL */
body.rtl .navbar__actions {
  order: 3;
  margin-left: 0;
  margin-right: auto;
}

body.rtl .navbar__mobile-menu {
  direction: rtl;
  text-align: right;
}

body.rtl .navbar__mobile-menu a {
  text-align: right;
}

/* ── Filter bar — label on right, buttons scrolling left ── */
body.rtl .filter-bar {
  direction: rtl;
  /* direction:rtl on a flex container makes it start from the right automatically */
}

body.rtl .filter-bar__buttons {
  direction: rtl;
}

/* ── Map overlays ── */
body.rtl .loading-overlay {
  right: auto;
  left: 16px;
}

/* ── Legend: move to bottom-right corner ── */
body.rtl .leaflet-bottom.leaflet-left {
  left: auto;
  right: 10px;
}

/* ── Popups ── */
body.rtl .station-popup,
body.rtl .poi-popup {
  direction: rtl;
  text-align: right;
}

body.rtl .station-popup__lines {
  flex-direction: row-reverse;
}

/* ── About / Contact / Hero sections ── */
body.rtl .page-hero,
body.rtl .page-section,
body.rtl .contact-card {
  direction: rtl;
  text-align: right;
}

body.rtl .contact-email-row {
  flex-direction: row-reverse;
}

/* ── Footer ── */
body.rtl footer {
  direction: rtl;
}

body.rtl .footer-links {
  flex-direction: row-reverse;
}

/* ── Error toast ── */
body.rtl .error-toast {
  direction: rtl;
  text-align: right;
}

/* ── Line badge direction ── */
body.rtl .line-badge {
  flex-direction: row-reverse;
}

/* ── About page stats ── */
body.rtl .stats-banner {
  direction: rtl;
}

body.rtl .stats-banner__inner {
  flex-direction: row-reverse;
}

body.rtl .lines-showcase__inner {
  flex-direction: row-reverse;
}

body.rtl .line-card {
  flex-direction: row-reverse;
}

body.rtl .about-section {
  direction: rtl;
}
