.topbar-actions,
.header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 16px;
}

.topbar-actions {
  margin-left: auto;
}

.lang-switcher {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border: 1px solid rgba(22, 33, 38, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(10px);
}

.lang-switcher button {
  min-width: 44px;
  min-height: 36px;
  padding: 0 12px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: inherit;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
}

.lang-switcher button[aria-pressed="true"] {
  background: #2f6b57;
  color: #ffffff;
}

.lang-switcher button:focus-visible {
  outline: 2px solid #2f6b57;
  outline-offset: 2px;
}

@media (max-width: 760px) {
  .topbar-actions {
    flex: 1 1 auto;
    gap: 12px;
    justify-content: flex-end;
  }

  .lang-switcher {
    margin-left: auto;
  }

  .topbar-actions .navbar-links {
    order: 2;
    flex-basis: 100%;
  }

  .topbar-actions .lang-switcher {
    order: 1;
    margin-left: auto;
  }

  .navbar-toggle {
    order: 3;
    margin-left: 12px;
  }
}

@media (max-width: 640px) {
  .header-actions {
    width: 100%;
    justify-content: space-between;
  }

  .header-actions .header-nav {
    order: 2;
    width: 100%;
  }

  .header-actions .lang-switcher {
    order: 1;
    margin-left: auto;
  }
}
