/* ═══════════════════════════════════════════
   Language Switcher — PROFISTRA
   Shared by index.html, how-we-earn.html,
   and all legal/sub pages.
═══════════════════════════════════════════ */

.lang-sw {
  position: relative;
  display: inline-block;
  flex-shrink: 0;
}

/* ── Toggle button ── */
.lang-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 8px;
  padding: 6px 10px;
  color: #8a9bbf;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: background .18s, border-color .18s, color .18s;
  white-space: nowrap;
  letter-spacing: .04em;
  font-family: 'Syne', sans-serif;
}
.lang-btn:hover {
  background: rgba(255,255,255,.09);
  border-color: rgba(255,255,255,.18);
  color: #e8f0ff;
}
.lang-btn.open {
  background: rgba(6,182,212,.08);
  border-color: rgba(6,182,212,.4);
  color: #e8f0ff;
}
.lang-flag { font-size: 15px; line-height: 1; }
.lang-code { font-weight: 700; }
.lang-chevron {
  font-size: 9px;
  opacity: .7;
  transition: transform .2s;
  margin-left: 1px;
}
.lang-btn.open .lang-chevron { transform: rotate(180deg); }

/* ── Dropdown panel ── */
.lang-drop {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 158px;
  background: #080f1e;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 12px;
  padding: 5px;
  box-shadow: 0 16px 48px rgba(0,0,0,.6), 0 2px 8px rgba(0,0,0,.4);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px) scale(.97);
  transition: opacity .18s, transform .18s, visibility .18s;
  z-index: 9999;
}
.lang-drop.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

/* ── Option rows ── */
.lang-drop button {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px 12px;
  background: none;
  border: none;
  border-radius: 8px;
  color: #8a9bbf;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background .13s, color .13s;
  text-align: left;
  font-family: inherit;
}
.lang-drop button:hover {
  background: rgba(255,255,255,.06);
  color: #e8f0ff;
}
.lang-drop button.active {
  color: #06b6d4;
  background: rgba(6,182,212,.09);
}
.lang-opt-flag { font-size: 16px; line-height: 1; }
.lang-opt-name { flex: 1; }
.lang-check {
  font-size: 11px;
  color: #06b6d4;
  opacity: 0;
  transition: opacity .15s;
}
.lang-drop button.active .lang-check { opacity: 1; }

/* ── lnav placement (legal/sub pages) ── */
.lnav-inner .lang-sw {
  margin-left: 4px;
}

/* ── Mobile: hide text label, show only flag+code ── */
@media (max-width: 640px) {
  .lang-drop {
    right: 0;
    left: auto;
  }
}
