/* =========================================================
   LANGUAGE SWITCHER
   ========================================================= */
.lang-switch {
  position: relative;
  display: inline-block;
}
.lang-switch-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 9px 12px;
  border: 1px solid var(--line, #e3e8e7);
  border-radius: 11px;
  background: #fff;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-2, #3d4d4c);
  cursor: pointer;
  transition: .15s;
}
.lang-switch-toggle:hover {
  border-color: #c9d6d4;
  box-shadow: var(--shadow-sm);
}
.lang-switch-toggle .current-flag {
  font-size: 16px;
  line-height: 1;
}
.lang-switch-toggle .chev {
  width: 10px;
  height: 10px;
  opacity: .6;
  transition: transform .2s;
}
.lang-switch.open .lang-switch-toggle .chev {
  transform: rotate(180deg);
}

.lang-switch-menu {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 160px;
  background: #fff;
  border: 1px solid var(--line, #e3e8e7);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(16,32,30,.12);
  padding: 6px;
  z-index: 60;
  animation: langFade .15s ease;
}
.lang-switch.open .lang-switch-menu {
  display: block;
}
@keyframes langFade {
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: none; }
}

.lang-switch-menu a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--ink-2, #3d4d4c);
  text-decoration: none;
  transition: .15s;
}
.lang-switch-menu a:hover {
  background: #f4f8f7;
  color: var(--ink, #0e1a1a);
}
.lang-switch-menu a.active {
  background: var(--accent-soft, #e6f2f0);
  color: var(--accent, #0d7a6b);
  font-weight: 700;
}
.lang-switch-menu a .flag {
  font-size: 18px;
  line-height: 1;
}

/* =========================================================
   RTL SUPPORT (Arabic)
   ========================================================= */
html[dir="rtl"] body {
  direction: rtl;
}
html[dir="rtl"] .header-inner,
html[dir="rtl"] .nav,
html[dir="rtl"] .footer-main,
html[dir="rtl"] .footer-bottom,
html[dir="rtl"] .toolbar,
html[dir="rtl"] .modal-top,
html[dir="rtl"] .modal-actions,
html[dir="rtl"] .side-card {
  direction: rtl;
}
html[dir="rtl"] .header-right {
  margin-left: 0;
  margin-right: auto;
}
html[dir="rtl"] .logo,
html[dir="rtl"] .nav a {
  text-align: right;
}
html[dir="rtl"] .nav a {
  padding-right: 12px;
}
html[dir="rtl"] .searchbar .field svg {
  order: 1;
}
html[dir="rtl"] .searchbar input {
  text-align: right;
}
html[dir="rtl"] .filters {
  direction: rtl;
  text-align: right;
}
html[dir="rtl"] .card-body,
html[dir="rtl"] .modal-body {
  text-align: right;
}
html[dir="rtl"] .price-line,
html[dir="rtl"] .meta {
  direction: rtl;
}
html[dir="rtl"] .toolbar-right {
  margin-left: 0;
  margin-right: auto;
}
html[dir="rtl"] .fav {
  right: auto;
  left: 10px;
}
html[dir="rtl"] .badges {
  left: auto;
  right: 12px;
}