.lang-switcher--enhanced {
  position: relative;
  isolation: isolate;
}

.nav-links .lang-switcher--enhanced::after {
  content: none !important;
}

.nav-links .lang-switcher--enhanced select {
  display: none !important;
}

.lang-switcher__button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 40px;
  max-width: min(180px, calc(100vw - 32px));
  padding: 8px 12px 8px 14px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(37, 18, 16, 0.92), rgba(20, 9, 9, 0.98));
  box-shadow:
    0 18px 40px rgba(0, 0, 0, 0.32),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  color: #f8fafc;
  cursor: pointer;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.01em;
  transition:
    transform 0.18s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    background 0.18s ease;
}

.lang-switcher__button:hover,
.lang-switcher__button:focus-visible,
.lang-switcher--open .lang-switcher__button {
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow:
    0 22px 44px rgba(0, 0, 0, 0.36),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  outline: none;
  transform: translateY(-1px);
}

.lang-switcher__current {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lang-switcher__chevron {
  flex: none;
  width: 10px;
  height: 10px;
  border-right: 1.5px solid rgba(255, 255, 255, 0.72);
  border-bottom: 1.5px solid rgba(255, 255, 255, 0.72);
  transform: rotate(45deg) translateY(-1px);
  transition: transform 0.18s ease;
}

.lang-switcher--open .lang-switcher__chevron {
  transform: rotate(-135deg) translateY(-1px);
}

.lang-switcher__menu {
  position: absolute;
  inset-block-start: calc(100% + 10px);
  inset-inline-end: 0;
  z-index: 30;
  display: grid;
  gap: 4px;
  min-width: 248px;
  max-width: min(280px, calc(100vw - 24px));
  max-height: min(70vh, 560px);
  overflow-y: auto;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(39, 12, 9, 0.98), rgba(24, 6, 6, 0.98));
  box-shadow:
    0 30px 70px rgba(0, 0, 0, 0.48),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.lang-switcher__menu[hidden] {
  display: none;
}

.nav-links .lang-switcher__menu .lang-switcher__option {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  color: #f8fafc;
  text-decoration: none;
  transition:
    background 0.16s ease,
    color 0.16s ease,
    transform 0.16s ease;
}

.nav-links .lang-switcher__menu .lang-switcher__option:hover,
.nav-links .lang-switcher__menu .lang-switcher__option:focus-visible {
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  outline: none;
  text-decoration: none;
  transform: translateX(2px);
}

.nav-links .lang-switcher__menu .lang-switcher__option.is-active {
  background: rgba(255, 255, 255, 0.04);
}

.lang-switcher__option-name {
  min-width: 0;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.lang-switcher__option-check {
  opacity: 0;
  color: #f97316;
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
}

.lang-switcher__option.is-active .lang-switcher__option-check {
  opacity: 1;
}

@media (max-width: 768px) {
  .lang-switcher__button {
    max-width: min(144px, calc(100vw - 24px));
    min-height: 38px;
    padding-inline: 12px;
    font-size: 13px;
  }

  .lang-switcher__menu {
    min-width: min(240px, calc(100vw - 24px));
    max-width: min(260px, calc(100vw - 24px));
  }
}
