/* Locale-only additions; original Solaria rules remain unchanged. */
.locale-switcher { position: relative; display: inline-flex; align-items: center; height: 44px; flex: 0 0 44px; width: 44px; overflow: visible; z-index: 101; color: #fff; }
.locale-toggle { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border: 0; padding: 0; background: transparent; color: inherit; font-size: 20px; cursor: pointer; }
.locale-options { position: fixed; min-width: 170px; max-width: calc(100vw - 32px); padding: 8px; background: var(--bg-dark-1, #0f2647); color: #fff; box-shadow: 0 4px 12px #0003; border-radius: 4px; }
.locale-options[hidden] { display: none !important; }
.locale-switcher .locale-options a { display: flex !important; align-items: center; min-height: 44px; padding: 8px 12px !important; font-size: 14px !important; line-height: 1.4; white-space: nowrap; color: #fff !important; text-decoration: none; }
.locale-options a:hover, .locale-options a:focus-visible { background: #ffffff1a; }
/* Keep flags and language names in the same columns in every locale. */
.locale-switcher .locale-options a { direction: ltr; flex-direction: row; justify-content: flex-start; text-align: left; }
.locale-switcher .locale-options [data-locale="ar"] span { direction: rtl; unicode-bidi: isolate; }
.locale-switcher a[aria-current="page"] { text-decoration: underline !important; text-underline-offset: 4px; }
.locale-switcher :is(a,button):focus-visible { outline: 2px solid var(--primary-color); outline-offset: 2px; }
header .menu_side_area { display: flex; align-items: center; gap: 8px; }
header:is(.header-light,.scroll-light) .locale-switcher { color: var(--bg-dark-1); }
.product-page-header > .container > .locale-switcher { margin-inline-start: auto; }
@media (min-width: 994px) {
  html[lang="ar-MA"] #mainmenu > li { float: right; margin-inline-start: 0; margin-inline-end: 30px; }
  html[lang="ar-MA"] #mainmenu > li:last-child { margin-inline-end: 0; }
}
html[lang="ar-MA"] { direction: rtl; }
html[lang="ar-MA"] body { text-align: start; }
html[lang="ar-MA"] :is(h1,h2,h3,h4,h5,h6,p,a,button,label,legend,summary) { overflow-wrap: anywhere; letter-spacing: 0; }
html[lang="ar-MA"] :is(.brand-logo-text,.locale-ltr,bdi,[data-capacity]) { direction: ltr; unicode-bidi: isolate; }
html[lang="ar-MA"] .brand-logo-text { display: inline-flex; }
html[lang="ar-MA"] :is(th,caption) { text-align: start; }
html[lang="ar-MA"] td { text-align: start; }
html[lang="ar-MA"] .table-responsive { direction: rtl; max-width: 100%; overflow-x: auto; }
html[lang="ar-MA"] :is(.site-mainmenu,.widget ul,.ul-check) { padding-inline-start: 0; }
html[lang="ar-MA"] .site-mainmenu > li > ul { inset-inline-start: 0; inset-inline-end: auto; text-align: start; }
html[lang="ar-MA"] :is(#catalogue-filters fieldset,.product-information-panel,dialog) { text-align: start; }
html[lang="ar-MA"] .catalogue-checkbox { direction: rtl; }
html[lang="ar-MA"] #catalogue-filters input[type="checkbox"] { margin-inline: 0 8px; }
html[lang="ar-MA"] :is(.site-supplier-footer,.site-policy-page) { text-align: start; }
html[lang="ar-MA"] .site-supplier-footer .text-center { text-align: center !important; }
html[lang="ar-MA"] .product-title { overflow-wrap: anywhere; }
html[lang="ar-MA"] #content .d-flex.align-items-center.fw-bold.text-dark:has(> i.me-2) { gap: 8px; }
html[lang="ar-MA"] #content .d-flex.align-items-center.fw-bold.text-dark > i.me-2 { margin: 0 !important; }
html[lang="ar-MA"] .topbar-widget :is(a:not([dir="ltr"]),.site-location-text) { display: inline-flex; align-items: center; gap: 10px; }
html[lang="ar-MA"] .topbar-widget :is(a:not([dir="ltr"]),.site-location-text) > i { margin: 0; }
html[lang="ar-MA"] :is(.fa-arrow-right,.fa-arrow-left,.icofont-arrow-right,.icofont-arrow-left,.icofont-long-arrow-right,.icofont-long-arrow-left) { transform: rotate(180deg); }
.locale-legal-review { padding-block: 8px; border-inline-start: 3px solid var(--primary-color); padding-inline-start: 12px; }
html[lang="ar-MA"] img[src$="up-right-arrow.webp"] { transform: scaleX(-1); }
html[lang="ar-MA"] [data-image-step] i { transform: rotate(180deg); }
html[lang="ar-MA"] .blog-read ol.ol-style-1 { margin-left: 0; margin-right: 50px; }
html[lang="ar-MA"] .blog-read ol.ol-style-1 > li::before { left: auto; right: -50px; margin-left: 0; margin-right: 0; }
@media (max-width: 993px) {
  .locale-switcher .locale-options a { width: auto !important; }
  html[lang="ar-MA"] .site-mainmenu > li > ul { padding-inline: 16px 0; }
}
/* The unchanged logo and two 44px controls need a second row at 320px. */
@media (max-width: 359px) {
  header .de-flex:has(.locale-switcher) { flex-wrap: wrap; }
  header .de-flex-col:has(> .menu_side_area > .locale-switcher) { margin-inline-start: auto; }
  header:has(.locale-switcher) .header-col-mid #mainmenu { top: 120px; }
}

/* Local flag icons avoid platform-dependent emoji rendering. */
.locale-switcher .locale-options a { gap: 8px; }
.locale-switcher .locale-flag { display: block; width: 24px; height: 18px; flex: 0 0 24px; object-fit: contain; }

/* Keep the marquee plugin's physical track LTR; isolate Arabic text inside it. */
html[lang="ar-MA"] .de-marquee-list-2 { direction: ltr; min-width: 0; width: 100%; }
html[lang="ar-MA"] .de-marquee-list-2 .js-marquee > span { direction: rtl; unicode-bidi: isolate; }
html[lang="ar-MA"] .ul-check li { padding-left: 0; padding-right: 30px; }
html[lang="ar-MA"] .ul-check li::before { left: auto; right: 0; margin-right: 0; margin-left: 12px; }

/* Shared footer rhythm and interaction affordances, scoped to supplier footers. */
footer.section-dark {
  --footer-control-size: 44px;
  --footer-heading-height: 36px;
  --footer-section-gap: 24px;
}
footer.section-dark .logo-footer-text {
  min-height: var(--footer-heading-height);
  font-size: 26px;
  line-height: 1.2;
  margin-bottom: 16px;
  max-width: 100%;
}
footer.section-dark .logo-footer-text .brand-logo-mark {
  width: 36px;
  height: 36px;
  object-fit: contain;
}
footer.section-dark .logo-footer-text + .spacer-20 { display: none; }
body footer.section-dark .widget .home-footer-title {
  display: flex;
  align-items: center;
  min-height: var(--footer-heading-height);
  font-size: 18px;
  line-height: 1.4;
  margin-bottom: 16px;
}
footer.section-dark > .container > .row { row-gap: var(--footer-section-gap); }
footer.section-dark .widget { margin-bottom: var(--footer-section-gap); }
footer.section-dark :is(a,button) {
  display: inline-flex;
  align-items: center;
  min-height: var(--footer-control-size);
  max-width: 100%;
  overflow-wrap: anywhere;
}
/* Footer links keep their template color; brand yellow on hover/keyboard focus. */
footer.section-dark :is(a,button[data-cookie-settings]) { text-decoration: none !important; }
footer.section-dark :is(a,button[data-cookie-settings]):is(:hover,:focus-visible) { color: var(--primary-color) !important; }
footer.section-dark :is(.menu-simple,.product-page-footer-links) a { min-height: var(--footer-control-size); }
footer.section-dark :is(a,button):hover { color: var(--primary-color); }
footer.section-dark :is(a,button):focus-visible {
  outline: 2px solid var(--primary-color);
  outline-offset: 3px;
}
footer.section-dark [href^="tel:"] { direction: ltr; unicode-bidi: isolate; white-space: nowrap; }
footer.section-dark .menu-simple {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 4px 16px;
  padding-inline: 0;
  margin-block: 16px 0;
}
footer.section-dark .menu-simple li { margin: 0; }
footer.section-dark .subfooter .de-flex { gap: 16px; flex-wrap: wrap; }
/* Restore the existing contact content on small screens, not a new section. */
body.homepage-finalized section.bg-color:has(.home-contact-title) .row.sm-hide { display: flex; }
body.homepage-finalized section.bg-color:has(.home-contact-title) .d-flex {
  gap: 12px;
  align-items: flex-start;
}
body.homepage-finalized section.bg-color:has(.home-contact-title) .d-flex > i {
  font-size: 36px;
  line-height: 1.2;
  flex: 0 0 36px;
  text-align: center;
}
body.homepage-finalized section.bg-color:has(.home-contact-title) .d-flex > .ms-3 { margin-inline: 0 !important; }
body.homepage-finalized section.bg-color:has(.home-contact-title) .d-flex > div { min-width: 0; flex: 1; overflow-wrap: anywhere; }
body.homepage-finalized section.bg-color .home-contact-title { font-size: 20px; line-height: 1.4; }
@media (max-width: 575px) {
  body.homepage-finalized section.bg-color:has(.home-contact-title) p:has(> a[href^="tel:"]) { display: flex; flex-wrap: wrap; align-items: center; column-gap: 4px; }
  body.homepage-finalized section.bg-color:has(.home-contact-title) p:has(> a[href^="tel:"]) > br { flex-basis: 100%; height: 0; }
  body.homepage-finalized section.bg-color:has(.home-contact-title) a[href^="tel:"] { white-space: nowrap; }
}
body.homepage-finalized section.bg-color:has(.home-contact-title) a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  text-decoration: underline;
  text-underline-offset: 3px;
}
body.homepage-finalized section.bg-color:has(.home-contact-title) a:focus-visible {
  outline: 2px solid var(--bg-dark-1);
  outline-offset: 3px;
}

/* Arabic UX review: all additions are locale-scoped; content and EN/FR stay intact. */
html[lang="ar-MA"] #home-hero .text-start { text-align: start !important; }
/* Preserve the original font stack/sizes, with a supported Arabic weight and leading. */
html[lang="ar-MA"] #home-hero .hero-copy h1 {
  font-weight: 600;
  line-height: 1.4 !important;
}
/* Retain the muted template treatment while making Arabic headings readable. */
html[lang="ar-MA"] body.homepage-finalized #content h2 > .op-3 { opacity: .55; }
/* Reading rhythm only inside product and article information, never product values. */
html[lang="ar-MA"] :is(.product-information-panel,.blog-read) :is(p,li) {
  font-size: 17px;
  line-height: 1.9;
}
html[lang="ar-MA"] :is(.product-information-panel,.blog-read) > p {
  max-inline-size: 75ch;
  margin-inline-end: auto;
}
html[lang="ar-MA"] .product-information-panel h2 { font-size: 28px; line-height: 1.5; }
html[lang="ar-MA"] .product-information-panel h3 { font-size: 22px; line-height: 1.6; }
html[lang="ar-MA"] .product-information-panel :is(ul,ol):not(.list-unstyled):not(.ul-check) {
  padding-inline-start: 1.5rem;
  padding-inline-end: 0;
}
html[lang="ar-MA"] .product-information-panel li { margin-block-end: 8px; }
/* Numeric controls retain their intentional LTR presentation inside the RTL page. */
html[lang="ar-MA"] #product-detail #product-quantity {
  direction: ltr;
  unicode-bidi: isolate;
  text-align: center;
}
html[lang="ar-MA"] #product-detail .table-responsive[tabindex]:focus-visible {
  outline: 2px solid var(--bg-dark-1);
  outline-offset: -2px;
}
/* The inherited second line had both left and right offsets on desktop RTL. */
@media (min-width: 994px) {
  html[lang="ar-MA"] #btn-extra[role="button"] span { right: auto; }
}

html[lang="ar-MA"] #product-specifications bdi.arabic-spec-value { direction: rtl; }

/* Align Arabic specification tables while preserving the direction of model codes and values. */

html[lang="ar-MA"] #product-specifications table {
  width: 100%;
  table-layout: fixed;
}
html[lang="ar-MA"] #product-specifications table :is(th, td) {
  text-align: right;
  vertical-align: top;
  padding: .65rem .75rem;
  overflow-wrap: anywhere;
}
html[lang="ar-MA"] #product-specifications table thead th:first-child {
  width: clamp(7.5rem, 36%, 24rem);
}
html[lang="ar-MA"] #product-specifications table:has(thead th:nth-child(3)) {
  width: max-content;
  min-width: 100%;
  table-layout: auto;
}
html[lang="ar-MA"] #product-specifications table:has(thead th:nth-child(3)) :is(th, td) {
  box-sizing: border-box;
  width: 13rem;
  min-width: 13rem;
  max-width: 13rem;
}

/* Anchor LTR identifiers and quantities beside their RTL field labels. */
html[lang="ar-MA"] #product-detail :is(#selected-model,#selected-capacity,#selected-rated-power) {
  text-align: right;
}
