.lang-open {
  position: absolute;
  top: 48px;
  right: 40px;
  z-index: 1000;
}

/* Show only the active button */
.lang-open .lang-btn {
  display: none;
}

/* Active button is always visible */
.lang-open .lang-btn.active {
  display: inline-flex;
}

/* Dropdown menu */
.lang-open:hover .lang-btn {
  display: inline-flex;
}

/* To make the buttons drop down */
.lang-open {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.lang-btn {
  position: relative;
  width: 32px;
  height: 22px;
  /* Flag button height */
  padding: 0;
  /* Small buttons */
  border: 1px solid #ccc;
  border-radius: 4px;
  overflow: hidden;
  /* Crops the image at the edges */
  background: #eee;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.lang-btn img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* White language code on top of the flag, top center */
.lang-btn .flag-code {
  position: absolute;
  top: 3px;
  /* Distance from the top edge of the button */
  left: 50%;
  transform: translateX(-50%);
  font-size: 11px;
  line-height: 1;
  color: #ffffff;
  font-weight: 700;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
  pointer-events: none;
  user-select: none;
  text-shadow:
    -0.5px -0.5px 0 black,
    0.5px -0.5px 0 black,
    -0.5px 0.5px 0 black,
    0.5px 0.5px 0 black;
}

.lang-btn.active {
  box-shadow: 0 0 0 2px rgba(0, 120, 215, 0.18);
}

.lang-btn:focus {
  outline: 2px solid #4d90fe;
  outline-offset: 2px;
}