/* ============================================================
   RTL (Right-to-Left) Layout Overrides for k712
   Applies to: Arabic (ar), Hebrew (he), Persian/Farsi (fa),
               Urdu (ur), Pashto (ps), Sindhi (sd), Yiddish (yi)
   Activated by: <html dir="rtl">
   ============================================================ */

/* ── Base Direction ─────────────────────────────────────────── */
html[dir="rtl"] {
  direction: rtl;
  text-align: right;
}

html[dir="rtl"] body {
  direction: rtl;
  text-align: right;
}

/* ── Images (no mirroring) ─────────────────────────────────── */
/* Images keep their original orientation in RTL layout */

/* ── Float Swap ────────────────────────────────────────────── */
html[dir="rtl"] .fl {
  float: right !important;
}

html[dir="rtl"] .fr {
  float: left !important;
}

/* ── Bootstrap Grid & Column Reversal ───────────────────────── */
html[dir="rtl"] .row {
  direction: rtl;
}

html[dir="rtl"] .float-start {
  float: right !important;
}

html[dir="rtl"] .float-end {
  float: left !important;
}

html[dir="rtl"] .text-start {
  text-align: right !important;
}

html[dir="rtl"] .text-end {
  text-align: left !important;
}

html[dir="rtl"] .ms-auto {
  margin-right: auto !important;
  margin-left: 0 !important;
}

html[dir="rtl"] .me-auto {
  margin-left: auto !important;
  margin-right: 0 !important;
}

html[dir="rtl"] .ms-0 { margin-right: 0 !important; margin-left: 0 !important; }
html[dir="rtl"] .me-0 { margin-left: 0 !important; margin-right: 0 !important; }
html[dir="rtl"] .ms-1 { margin-right: 0.25rem !important; margin-left: 0 !important; }
html[dir="rtl"] .me-1 { margin-left: 0.25rem !important; margin-right: 0 !important; }
html[dir="rtl"] .ms-2 { margin-right: 0.5rem !important; margin-left: 0 !important; }
html[dir="rtl"] .me-2 { margin-left: 0.5rem !important; margin-right: 0 !important; }
html[dir="rtl"] .ms-3 { margin-right: 1rem !important; margin-left: 0 !important; }
html[dir="rtl"] .me-3 { margin-left: 1rem !important; margin-right: 0 !important; }
html[dir="rtl"] .ms-4 { margin-right: 1.5rem !important; margin-left: 0 !important; }
html[dir="rtl"] .me-4 { margin-left: 1.5rem !important; margin-right: 0 !important; }

html[dir="rtl"] .ps-0 { padding-right: 0 !important; padding-left: 0 !important; }
html[dir="rtl"] .pe-0 { padding-left: 0 !important; padding-right: 0 !important; }
html[dir="rtl"] .ps-1 { padding-right: 0.25rem !important; padding-left: 0 !important; }
html[dir="rtl"] .pe-1 { padding-left: 0.25rem !important; padding-right: 0 !important; }
html[dir="rtl"] .ps-2 { padding-right: 0.5rem !important; padding-left: 0 !important; }
html[dir="rtl"] .pe-2 { padding-left: 0.5rem !important; padding-right: 0 !important; }
html[dir="rtl"] .ps-3 { padding-right: 1rem !important; padding-left: 0 !important; }
html[dir="rtl"] .pe-3 { padding-left: 1rem !important; padding-right: 0 !important; }

/* ── Dropdown Menus ─────────────────────────────────────────── */
html[dir="rtl"] .dropdown-menu {
  text-align: right;
  left: auto !important;
  right: 0;
}

html[dir="rtl"] .dropdown-menu-end {
  right: auto !important;
  left: 0 !important;
}

html[dir="rtl"] .dropdown-item {
  text-align: right;
}

/* ── Header / Navigation ───────────────────────────────────── */
html[dir="rtl"] .main-header-content {
  direction: rtl;
}

html[dir="rtl"] .main-header-logo {
  direction: rtl;
}

html[dir="rtl"] .main-header-right {
  direction: rtl;
}

html[dir="rtl"] .main-menu-wrapper ul.main-menu-list {
  direction: rtl;
}

html[dir="rtl"] .main-menu-wrapper ul.main-menu-list > li {
  direction: rtl;
}

html[dir="rtl"] .main-menu-wrapper ul.main-menu-list > li > a span {
  /* no translateX flip needed, direction handles it */
}

/* ── Mobile Menu ────────────────────────────────────────────── */
html[dir="rtl"] .mobile-nav-wrapper {
  direction: rtl;
}

html[dir="rtl"] .mobile-nav-content {
  right: auto !important;
  left: 0 !important;
  direction: rtl;
  text-align: right;
}

html[dir="rtl"] .mobile-nav-overlay {
  /* overlay stays full-screen */
}

html[dir="rtl"] .mobile-nav-close {
  direction: rtl;
}

html[dir="rtl"] .mobile-nav-container {
  direction: rtl;
  text-align: right;
}

/* ── Language Switcher ──────────────────────────────────────── */
html[dir="rtl"] .head_lang .language-dropdown {
  right: auto !important;
  left: 0;
}

html[dir="rtl"] .head_lang .language-item {
  direction: rtl;
}

/* ── Home: About Section ────────────────────────────────────── */
html[dir="rtl"] .about {
  direction: rtl;
}

html[dir="rtl"] .ab_txt {
  text-align: right;
}

html[dir="rtl"] .ab_more {
  flex-direction: row-reverse;
}

html[dir="rtl"] .ab_more i {
  margin-right: 0;
  margin-left: 10px;
}

html[dir="rtl"] .ab_right {
  direction: rtl;
}

/* ── Home: Product Section ──────────────────────────────────── */
html[dir="rtl"] .product {
  direction: rtl;
}

html[dir="rtl"] .sl {
  direction: rtl;
}

html[dir="rtl"] .sl .gallery-thumbs {
  float: right !important;
}

html[dir="rtl"] .sl .gallery-top {
  float: left !important;
}

html[dir="rtl"] .sl_list {
  direction: rtl;
}

html[dir="rtl"] .sl_list .swiper-slide {
  direction: rtl;
  text-align: right;
}

html[dir="rtl"] .sl_list .swiper-slide p {
  text-align: right;
}

/* ── Home: Case Section ─────────────────────────────────────── */
html[dir="rtl"] .case {
  direction: rtl;
}

html[dir="rtl"] .case .swiper-slide {
  direction: rtl;
}

html[dir="rtl"] .case .swiper-slide .msg {
  direction: rtl;
  text-align: right;
}

/* ── Home: News Section ─────────────────────────────────────── */
html[dir="rtl"] .news {
  direction: rtl;
}

html[dir="rtl"] .news-list {
  direction: rtl;
}

html[dir="rtl"] .news-list .swiper-slide {
  direction: rtl;
  text-align: right;
}

html[dir="rtl"] .news-list .swiper-slide p {
  text-align: right;
}

/* ── Home: Certificate Section ──────────────────────────────── */
html[dir="rtl"] .certificate-section {
  direction: rtl;
}

html[dir="rtl"] .certificate-item {
  direction: rtl;
}

/* ── Home: Video Section ────────────────────────────────────── */
html[dir="rtl"] .video-section {
  direction: rtl;
}

/* ── Swiper RTL Support ─────────────────────────────────────── */
html[dir="rtl"] .swiper {
  direction: rtl;
}

html[dir="rtl"] .swiper-wrapper {
  direction: rtl;
}

html[dir="rtl"] .swiper-button-next {
  right: auto !important;
  left: 10px !important;
}

html[dir="rtl"] .swiper-button-prev {
  left: auto !important;
  right: 10px !important;
}

/* ── Footer ─────────────────────────────────────────────────── */
html[dir="rtl"] .footer {
  direction: rtl;
  text-align: right;
}

html[dir="rtl"] .footerr {
  direction: rtl;
}

html[dir="rtl"] .footerr .wal {
  direction: rtl;
}

html[dir="rtl"] .footerr .foot_item {
  direction: rtl;
  text-align: right;
}

html[dir="rtl"] .footerr .foot_item ul {
  padding-right: 0;
  padding-left: 0;
  list-style-position: inside;
}

html[dir="rtl"] .ft-contact {
  direction: rtl;
  text-align: right;
}

html[dir="rtl"] .copyright {
  direction: rtl;
  text-align: center;
}

html[dir="rtl"] .links {
  direction: rtl;
}

html[dir="rtl"] .foot_bot {
  direction: rtl;
  text-align: center;
}

html[dir="rtl"] .foot_bot .wal {
  direction: rtl;
}

/* ── Footer QR Codes ────────────────────────────────────────── */
html[dir="rtl"] .footer-qrcode {
  direction: rtl;
}

/* ── Social Links ───────────────────────────────────────────── */
html[dir="rtl"] .social-links-grid {
  direction: rtl;
}

/* ── Floating Contact Buttons (Suspension) ──────────────────── */
html[dir="rtl"] #suspension {
  right: auto !important;
  left: 8px !important;
}

html[dir="rtl"] #suspension li {
  direction: rtl;
}

html[dir="rtl"] #suspension li a {
  right: auto !important;
  left: 0;
}

html[dir="rtl"] #suspension li .txt {
  direction: rtl;
}

html[dir="rtl"] #suspension li.ewm .ewm-box {
  right: auto !important;
  left: -5px !important;
}

html[dir="rtl"] #suspension li.ewm .ewm-box:after {
  right: auto !important;
  left: -5px !important;
}

/* ── Forms ──────────────────────────────────────────────────── */
html[dir="rtl"] input,
html[dir="rtl"] textarea,
html[dir="rtl"] select {
  direction: rtl;
  text-align: right;
}

html[dir="rtl"] .contact-box .message {
  direction: rtl;
}

/* ── Inner Pages: About ─────────────────────────────────────── */
html[dir="rtl"] .about-box {
  direction: rtl;
}

html[dir="rtl"] .about-fl {
  direction: rtl;
}

html[dir="rtl"] .about-fr {
  direction: rtl;
}

html[dir="rtl"] .desc-wrapper {
  direction: rtl;
  text-align: right;
}

/* ── Inner Pages: Product / Article ─────────────────────────── */
html[dir="rtl"] .ncontainer {
  direction: rtl;
}

html[dir="rtl"] .pro_bodyb {
  direction: rtl;
}

html[dir="rtl"] .innerright {
  direction: rtl;
  text-align: right;
}

html[dir="rtl"] .innerleft {
  direction: rtl;
  text-align: right;
}

html[dir="rtl"] .pro_ll {
  direction: rtl;
}

html[dir="rtl"] .pro_r {
  direction: rtl;
}

html[dir="rtl"] .pro_re {
  direction: rtl;
}

html[dir="rtl"] .pro_con {
  direction: rtl;
  text-align: right;
}

/* ── Inner Pages: Article List ──────────────────────────────── */
html[dir="rtl"] .news-twoo {
  direction: rtl;
}

html[dir="rtl"] .news-twoo ul li {
  direction: rtl;
  text-align: right;
}

html[dir="rtl"] .newsin-c {
  direction: rtl;
  text-align: right;
}

/* ── Breadcrumb ─────────────────────────────────────────────── */
html[dir="rtl"] .breadcrumb {
  direction: rtl;
}

html[dir="rtl"] .breadcrumb-item + .breadcrumb-item::before {
  transform: scaleX(-1);
  display: inline-block;
}

html[dir="rtl"] .navpost {
  direction: rtl;
}

html[dir="rtl"] .inposition {
  direction: rtl;
}

/* ── FAQ ────────────────────────────────────────────────────── */
html[dir="rtl"] .faq_item {
  direction: rtl;
  text-align: right;
}

/* ── Product List ───────────────────────────────────────────── */
html[dir="rtl"] .product-list {
  direction: rtl;
}

html[dir="rtl"] .product-list .swiper-container {
  direction: rtl;
}

html[dir="rtl"] .product_navv {
  direction: rtl;
}

html[dir="rtl"] .product_navv ul li {
  direction: rtl;
  text-align: right;
}

/* ── Product Gallery ────────────────────────────────────────── */
html[dir="rtl"] .xql {
  float: right !important;
}

html[dir="rtl"] .xqr {
  float: left !important;
}

html[dir="rtl"] .innerrightxq {
  direction: rtl;
  text-align: right;
}

/* ── Lists ──────────────────────────────────────────────────── */
html[dir="rtl"] ul,
html[dir="rtl"] ol {
  padding-right: 40px;
  padding-left: 0;
}

html[dir="rtl"] .footerr .foot_item ul {
  padding-right: 0;
  padding-left: 0;
}

/* ── Table ──────────────────────────────────────────────────── */
html[dir="rtl"] table {
  direction: rtl;
}

html[dir="rtl"] th,
html[dir="rtl"] td {
  text-align: right;
}

/* ── Flexbox & Grid Direction ───────────────────────────────── */
html[dir="rtl"] .d-flex {
  direction: rtl;
}

html[dir="rtl"] .justify-content-start {
  justify-content: flex-end !important;
}

html[dir="rtl"] .justify-content-end {
  justify-content: flex-start !important;
}

/* ── Border Radius Flips ────────────────────────────────────── */
html[dir="rtl"] .border-start {
  border-right: var(--bs-border-width) var(--bs-border-style) var(--bs-border-color) !important;
  border-left: 0 !important;
}

html[dir="rtl"] .border-end {
  border-left: var(--bs-border-width) var(--bs-border-style) var(--bs-border-color) !important;
  border-right: 0 !important;
}

html[dir="rtl"] .rounded-start {
  border-radius: 0 var(--bs-border-radius) var(--bs-border-radius) 0 !important;
}

html[dir="rtl"] .rounded-end {
  border-radius: var(--bs-border-radius) 0 0 var(--bs-border-radius) !important;
}

/* ── QR Modal ───────────────────────────────────────────────── */
html[dir="rtl"] .fqr-overlay712 {
  direction: rtl;
}

html[dir="rtl"] .fqr-modal-box712 {
  direction: rtl;
}

html[dir="rtl"] .fqr-close712 {
  right: auto !important;
  left: 10px !important;
}

/* ── Misc Utility ───────────────────────────────────────────── */
html[dir="rtl"] .container {
  direction: rtl;
}

html[dir="rtl"] .container-fluid {
  direction: rtl;
}

html[dir="rtl"] .w1200 {
  direction: rtl;
}

/* ── Icon Font Arrows ───────────────────────────────────────── */
html[dir="rtl"] .iconfont {
  direction: rtl;
}

/* ── Print ──────────────────────────────────────────────────── */
@media print {
  html[dir="rtl"] {
    direction: rtl;
  }
}
