/* DijitalGöz — i18n: dil seçici + Arapça RTL düzeni */

/* ---- Dil seçici (yüzen pill) ---- */
#dgLangSwitch{
  position:fixed; left:14px; bottom:14px; z-index:99999;
  display:flex; gap:2px; padding:3px;
  background:rgba(10,18,16,.82); border:1px solid rgba(126,240,210,.28);
  border-radius:999px; backdrop-filter:blur(8px);
  box-shadow:0 6px 22px rgba(0,0,0,.42);
  font-family:'IBM Plex Mono','Manrope',system-ui,sans-serif;
}
#dgLangSwitch .dg-lang-btn{
  appearance:none; border:0; cursor:pointer;
  min-width:34px; height:26px; padding:0 9px;
  border-radius:999px; background:transparent;
  color:rgba(224,240,234,.72); font-size:12px; font-weight:600;
  letter-spacing:.04em; line-height:1; transition:background .15s,color .15s;
}
#dgLangSwitch .dg-lang-btn:hover{ color:#eef7f3; background:rgba(126,240,210,.12); }
#dgLangSwitch .dg-lang-btn.active{
  background:linear-gradient(90deg,#3fbf9f,#7ff0d2); color:#06231b;
}
html[dir="rtl"] #dgLangSwitch{ left:auto; right:14px; }

/* nav içine gömülü (yüzen değil) varyant — landing/panel üst menüsü */
#dgLangSwitch.dg-inline{
  position:static; left:auto; right:auto; bottom:auto;
  box-shadow:none; backdrop-filter:none;
  background:rgba(255,255,255,.05); border-color:rgba(255,255,255,.14);
}
.nav-lang{ display:inline-flex; align-items:center; margin:0 6px; }

/* Harita uygulaması (index.html) başlığındaki dil seçici — sabit, görünür */
#dgLangSlot.dg-app-lang{ position:fixed; top:12px; left:50%; transform:translateX(-50%); z-index:100000; }
html[dir="rtl"] #dgLangSlot.dg-app-lang{ left:50%; right:auto; }
@media (max-width:768px){ #dgLangSlot.dg-app-lang{ top:auto; bottom:14px; } }
.dg-app-lang #dgLangSwitch.dg-inline{
  background:rgba(10,18,16,.86); border-color:rgba(126,240,210,.3);
  box-shadow:0 6px 22px rgba(0,0,0,.45); backdrop-filter:blur(8px);
}

/* ---- Arapça RTL ---- */
html[dir="rtl"] body{ direction:rtl; }

/* arama/giriş alanları ve sayısal kutular LTR kalsın (lat/lon, sayılar) */
html[dir="rtl"] input,
html[dir="rtl"] textarea,
html[dir="rtl"] select{ text-align:right; }
html[dir="rtl"] input[type="number"],
html[dir="rtl"] input[type="search"],
html[dir="rtl"] input[inputmode="decimal"],
html[dir="rtl"] input[inputmode="numeric"]{ direction:rtl; }

/* metin blokları sağa yaslı okunur */
html[dir="rtl"] p,
html[dir="rtl"] li,
html[dir="rtl"] .intel-scroll,
html[dir="rtl"] .ai-area-body,
html[dir="rtl"] .legend,
html[dir="rtl"] .hits{ text-align:right; }

/* harita ve pusula yönü değişmesin (coğrafya mutlak) */
html[dir="rtl"] #googleMap,
html[dir="rtl"] #basemap,
html[dir="rtl"] .maplibregl-map,
html[dir="rtl"] .gm-style,
html[dir="rtl"] #compass,
html[dir="rtl"] .compass-face,
html[dir="rtl"] svg{ direction:ltr; }

/* listelerde madde işareti/padding sağa geçsin */
html[dir="rtl"] ul{ padding-right:1.1em; padding-left:0; }

/* Harita uygulaması: dil seçici sağ panelin en üstünde */
#dgLangSlot.dg-panel-lang{ display:flex; justify-content:flex-end; margin:0 0 10px; }
html[dir="rtl"] #dgLangSlot.dg-panel-lang{ justify-content:flex-start; }
.dg-panel-lang #dgLangSwitch.dg-inline{
  background:rgba(10,18,16,.86); border-color:rgba(126,240,210,.3);
}
