.haldugroep-lang-switcher {
  position: relative;
  box-sizing: border-box;
  flex: 0 0 auto;
  width: auto;
  height: auto;
  align-self: stretch;
  display: flex;
  align-items: stretch;
  overflow: visible;
  z-index: 40;
}

.haldugroep-lang-switcher__toggle {
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: auto;
  height: auto;
  align-self: stretch;
  min-height: 0;
  min-width: 0;
  padding: 0 8px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  background-color: #ffffff;
  color: #111827;
  cursor: pointer;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
}

.haldugroep-lang-switcher__toggle:hover,
.haldugroep-lang-switcher__toggle:focus {
  background-color: #f9fafb;
  outline: none;
}

.haldugroep-lang-switcher__toggle:focus-visible {
  box-shadow: 0 0 0 2px #ffffff, 0 0 0 4px #f97316;
}

.haldugroep-lang-switcher__flag {
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 1.35rem;
  height: 1rem;
  overflow: visible;
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", "Twemoji Mozilla", sans-serif;
  font-size: 1.05rem;
  line-height: 1;
  text-align: center;
}

.haldugroep-lang-switcher__current {
  box-sizing: border-box;
  flex: 0 0 auto;
  min-width: 0;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.2;
  text-align: center;
  color: #374151;
  font-variant-numeric: tabular-nums;
}

/* ── Modal ── */
.haldugroep-lang-modal {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  box-sizing: border-box;
}

.haldugroep-lang-modal[hidden] {
  display: none !important;
}

.haldugroep-lang-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(17, 24, 39, 0.55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  cursor: pointer;
}

.haldugroep-lang-modal__dialog {
  position: relative;
  z-index: 1;
  box-sizing: border-box;
  width: min(100%, 460px);
  max-height: min(90vh, 720px);
  overflow: auto;
  margin: 0;
  padding: 28px 28px 24px;
  border-radius: 12px;
  background: #ffffff;
  color: #111827;
  box-shadow: 0 24px 60px rgba(17, 24, 39, 0.28);
  font-family: "Open Sans", sans-serif;
}

.haldugroep-lang-modal__close {
  position: absolute;
  top: 14px;
  right: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: none;
  border-radius: 999px;
  background: #111827;
  color: #ffffff;
  cursor: pointer;
  font-size: 1.35rem;
  line-height: 1;
}

.haldugroep-lang-modal__close:hover,
.haldugroep-lang-modal__close:focus {
  background: #374151;
  outline: none;
}

.haldugroep-lang-modal__close:focus-visible {
  box-shadow: 0 0 0 2px #ffffff, 0 0 0 4px #f97316;
}

.haldugroep-lang-modal__section + .haldugroep-lang-modal__section {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid #e5e7eb;
}

.haldugroep-lang-modal__heading {
  margin: 0 0 12px;
  padding-right: 36px;
  font-family: "Open Sans", sans-serif;
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.3;
  color: #111827;
}

.haldugroep-lang-modal__current {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
}

.haldugroep-lang-modal__flag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 1.35rem;
  width: 1.35rem;
  height: 1.35rem;
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", "Twemoji Mozilla", sans-serif;
  font-size: 1.2rem;
  line-height: 1;
}

.haldugroep-lang-modal__current-name {
  font-size: 1rem;
  font-weight: 700;
  color: #389feb;
  line-height: 1.3;
}

.haldugroep-lang-modal__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 20px;
}

.haldugroep-lang-modal__option {
  margin: 0;
  padding: 0;
  min-width: 0;
  border-bottom: 1px solid #e5e7eb;
}

.haldugroep-lang-modal__link {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 12px 4px;
  border-radius: 0;
  color: #111827;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.25;
  box-sizing: border-box;
}

.haldugroep-lang-modal__link:hover,
.haldugroep-lang-modal__link:focus {
  background-color: transparent;
  color: #389feb;
  text-decoration: none;
  outline: none;
}

.haldugroep-lang-modal__link.is-current {
  background-color: transparent;
  color: #c2410c;
  cursor: default;
}

.haldugroep-lang-modal__name {
  flex: 1 1 auto;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.haldugroep-lang-modal-open {
  overflow: hidden;
}

@media (max-width: 1024px) {
  .haldugroep-lang-switcher__toggle {
    padding: 0 7px;
  }
}

@media (max-width: 480px) {
  .haldugroep-lang-modal__dialog {
    padding: 24px 16px 20px;
  }

  .haldugroep-lang-modal__list {
    gap: 0 12px;
  }

  .haldugroep-lang-modal__link {
    padding: 10px 2px;
    font-size: 0.9rem;
  }
}
