/* Shared language dropdown (Bootstrap 5). Load after site button/input rules if those exist. */
.lang-switch-row {
  display: flex;
  justify-content: flex-end;
  margin-top: 0.75rem;
}
.lang-switch.dropdown {
  position: relative;
  width: max-content;
  max-width: 100%;
}
.lang-switch-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  width: auto !important;
  max-width: none;
  margin: 0 !important;
  min-height: 44px;
  min-width: 44px;
  padding: 0.35rem 0.85rem 0.35rem 0.7rem;
  border: 1px solid #ced4da !important;
  border-radius: 999px;
  background: #fff !important;
  color: #343a40 !important;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  line-height: 1;
  cursor: pointer;
  overflow: visible;
  white-space: nowrap;
  text-align: left;
}
.lang-switch-btn:hover,
.lang-switch-btn.show {
  background: #f8f9fa !important;
  color: #212529 !important;
  border-color: #adb5bd !important;
}
.lang-switch-btn:focus-visible {
  outline: 2px solid #6c757d;
  outline-offset: 2px;
}
.lang-switch .lang-switch-menu {
  position: absolute;
  top: calc(100% + 0.25rem);
  right: 0;
  left: auto;
  width: max-content;
  z-index: 20;
  min-width: 12.5rem;
  max-width: calc(100vw - 1.5rem);
  padding: 0.3rem 0;
  border-radius: 0.7rem;
}
.lang-switch-menu .dropdown-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: 44px;
  padding: 0.55rem 1rem;
  font-size: 1rem;
  white-space: nowrap;
}
.lang-switch-menu .dropdown-item.active,
.lang-switch-menu .dropdown-item:active {
  background: #e9ecef;
  color: #212529;
  font-weight: 600;
}
.lang-switch-noscript {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.35rem 0.75rem;
  margin-top: 0.5rem;
  font-size: 0.95rem;
}
.lang-switch-noscript a[aria-current="true"] {
  font-weight: 600;
  color: inherit;
  text-decoration: none;
}
