/**
 * BMHC Language Switcher — right-to-left corrections for Arabic pages.
 *
 * Salient ships an rtl.css, but it does not cover WPBakery rows or several
 * Salient components that hard-code left/right. These are loaded only when
 * the current language is Arabic.
 */

/* ---- Typography -------------------------------------------------------- */
/* System Arabic stack: no external font request, so nothing extra to load. */
html[lang="ar"] body,
html[lang="ar"] .wpb_wrapper,
html[lang="ar"] h1, html[lang="ar"] h2, html[lang="ar"] h3,
html[lang="ar"] h4, html[lang="ar"] h5, html[lang="ar"] h6 {
	font-family: "Segoe UI", "Geeza Pro", "Noto Naskh Arabic", "Traditional Arabic", Tahoma, Arial, sans-serif;
}

/* Arabic script sits lower and needs a little more room to breathe. */
html[lang="ar"] body {
	line-height: 1.85;
}
html[lang="ar"] h1, html[lang="ar"] h2, html[lang="ar"] h3 {
	line-height: 1.5;
}

/* Keep Latin-script fragments (brand names, emails, URLs) readable. */
html[lang="ar"] [lang="en"],
html[lang="ar"] .bmhc-lang--en {
	direction: ltr;
	unicode-bidi: isolate;
}

/* ---- Base direction ---------------------------------------------------- */
html[dir="rtl"] body,
html[dir="rtl"] .container-wrap,
html[dir="rtl"] .main-content {
	direction: rtl;
	text-align: right;
}

/* ---- WPBakery rows and columns ---------------------------------------- */
html[dir="rtl"] .wpb_row .wpb_column,
html[dir="rtl"] .vc_row .vc_column_container,
html[dir="rtl"] .wpb_wrapper > .wpb_column {
	float: right;
}
html[dir="rtl"] .vc_row[data-vc-full-width] {
	direction: rtl;
}
html[dir="rtl"] .wpb_text_column,
html[dir="rtl"] .wpb_text_column p,
html[dir="rtl"] .wpb_text_column li {
	text-align: right;
}
html[dir="rtl"] .wpb_text_column ul,
html[dir="rtl"] .wpb_text_column ol,
html[dir="rtl"] .main-content ul,
html[dir="rtl"] .main-content ol {
	padding-left: 0;
	padding-right: 1.4em;
}

/* Rows explicitly centred in the builder must stay centred. */
html[dir="rtl"] .text-align-center,
html[dir="rtl"] .vc_custom_heading.text-align-center,
html[dir="rtl"] [style*="text-align: center"] {
	text-align: center !important;
}

/* ---- Header / navigation ---------------------------------------------- */
html[dir="rtl"] #top .row .col.span_9 {
	float: left;
}
html[dir="rtl"] #top .row .col.span_3 {
	float: right;
}
html[dir="rtl"] #top nav > ul > li {
	float: right;
}
html[dir="rtl"] #top nav ul li ul {
	text-align: right;
}
html[dir="rtl"] #top nav ul li ul li a {
	padding-right: 20px;
	padding-left: 10px;
}
/* Dropdown carets and submenu flyouts point the other way. */
html[dir="rtl"] #top nav ul li ul ul {
	left: auto;
	right: 100%;
}

/* ---- Salient components ------------------------------------------------ */
html[dir="rtl"] .nectar-cta,
html[dir="rtl"] .iconized-icon,
html[dir="rtl"] .nectar-icon-list-item {
	text-align: right;
}
html[dir="rtl"] .nectar-icon-list-item .list-icon-holder {
	left: auto;
	right: 0;
}
html[dir="rtl"] .nectar-icon-list-item .content {
	padding-left: 0;
	padding-right: 70px;
}
html[dir="rtl"] .toggle > h3 a,
html[dir="rtl"] .tabbed > ul li a {
	text-align: right;
}
html[dir="rtl"] .toggle > h3 a i {
	left: auto;
	right: 0;
}
html[dir="rtl"] .toggle > h3 a {
	padding-left: 10px;
	padding-right: 33px;
}

/* Buttons that carry an arrow icon. */
html[dir="rtl"] .nectar-button i,
html[dir="rtl"] .vc_btn3 i {
	transform: scaleX(-1);
}

/* ---- Forms ------------------------------------------------------------- */
html[dir="rtl"] input[type="text"],
html[dir="rtl"] input[type="email"],
html[dir="rtl"] input[type="tel"],
html[dir="rtl"] input[type="search"],
html[dir="rtl"] textarea,
html[dir="rtl"] select,
html[dir="rtl"] .wpcf7 label {
	text-align: right;
	direction: rtl;
}
/* Email, phone and amount fields read better left-to-right. */
html[dir="rtl"] input[type="email"],
html[dir="rtl"] input[type="tel"],
html[dir="rtl"] input[type="number"],
html[dir="rtl"] input[type="url"] {
	direction: ltr;
	text-align: right;
}

/* ---- GiveWP donation forms -------------------------------------------- */
html[dir="rtl"] .give-form .give-donation-amount,
html[dir="rtl"] .give-form .form-row {
	direction: rtl;
	text-align: right;
}
/* Currency symbol + amount must stay LTR or the figure reads wrong. */
html[dir="rtl"] .give-form .give-currency-symbol,
html[dir="rtl"] .give-form #give-amount,
html[dir="rtl"] .give-donation-amount .give-text-input,
html[dir="rtl"] .give-final-total-amount {
	direction: ltr !important;
	unicode-bidi: embed;
}
html[dir="rtl"] .give-btn,
html[dir="rtl"] .give-submit {
	float: none;
}

/* ---- Prayer times table ------------------------------------------------ */
/* Times are numerals: keep the columns in their original order. */
html[dir="rtl"] .dpt_table,
html[dir="rtl"] .dptTimetable,
html[dir="rtl"] table.dpt {
	direction: ltr;
}
html[dir="rtl"] .dpt_table th,
html[dir="rtl"] .dpt_table td {
	text-align: center;
}

/* ---- Footer ------------------------------------------------------------ */
html[dir="rtl"] #footer-outer .col {
	float: right;
	text-align: right;
}
html[dir="rtl"] #footer-outer .widget ul {
	padding-right: 0;
}

/* ---- Leave absolutely-positioned sliders alone ------------------------- */
/* Slider Revolution positions every layer by coordinate; flipping it breaks
   the design, so the slider keeps its original direction. */
html[dir="rtl"] rs-module,
html[dir="rtl"] .rev_slider_wrapper,
html[dir="rtl"] .nectar-slider-wrap {
	direction: ltr;
}
html[dir="rtl"] rs-module [class*="rs-layer"] {
	direction: rtl;
}
