/* ========================================================================
   BD Language Switcher – RTL Direction Support for Breakdance
   Loaded only on RTL pages (Arabic, Hebrew, etc.)
   ======================================================================== */

/* ── Core direction ── */
html[dir="rtl"],
html[dir="rtl"] body {
  direction: rtl;
  text-align: right;
}

/* ── Breakdance layout containers ── */
html[dir="rtl"] .breakdance .section-container,
html[dir="rtl"] .breakdance [class*="bde-"] {
  direction: rtl;
}

/* ── Text elements ── */
html[dir="rtl"] .breakdance p,
html[dir="rtl"] .breakdance h1,
html[dir="rtl"] .breakdance h2,
html[dir="rtl"] .breakdance h3,
html[dir="rtl"] .breakdance h4,
html[dir="rtl"] .breakdance h5,
html[dir="rtl"] .breakdance h6,
html[dir="rtl"] .breakdance li,
html[dir="rtl"] .breakdance blockquote,
html[dir="rtl"] .breakdance figcaption {
  direction: rtl;
  text-align: right;
}

/* ── Headings and rich text ── */
html[dir="rtl"] .breakdance .bde-text,
html[dir="rtl"] .breakdance .bde-heading {
  direction: rtl;
  text-align: right;
}

/* ── Form inputs ── */
html[dir="rtl"] .breakdance input,
html[dir="rtl"] .breakdance textarea,
html[dir="rtl"] .breakdance select {
  direction: rtl;
  text-align: right;
}

/* ── Lists ── */
html[dir="rtl"] .breakdance ul,
html[dir="rtl"] .breakdance ol {
  padding-right: 1.2rem;
  padding-left: 0;
}

/* ── Tables ── */
html[dir="rtl"] .breakdance table {
  direction: rtl;
}

html[dir="rtl"] .breakdance th,
html[dir="rtl"] .breakdance td {
  text-align: right;
}

/* ── Flex row reversal for Breakdance columns ── */
html[dir="rtl"] .breakdance .bde-columns {
  direction: rtl;
}

/* ── Navigation ── */
html[dir="rtl"] .breakdance nav,
html[dir="rtl"] .breakdance .bde-nav-menu,
html[dir="rtl"] .breakdance .bde-header-builder {
  direction: rtl;
}

/* ── WooCommerce in Breakdance ── */
html[dir="rtl"] .breakdance .bde-woocommerce,
html[dir="rtl"] .breakdance .woocommerce {
  direction: rtl;
  text-align: right;
}

/* ── Cards and content blocks ── */
html[dir="rtl"] .breakdance [class*="card"],
html[dir="rtl"] .breakdance [class*="content"],
html[dir="rtl"] .breakdance [class*="inner"] {
  direction: rtl;
  text-align: right;
}
