.language-switcher {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.lang-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border: 1px solid #ccc;
  border-radius: 6px;
  background: transparent;
  color: #072032;
  cursor: pointer;
  font: inherit;
  font-weight: 600;
  line-height: 1;
}

.lang-btn:hover {
  background: rgba(0, 0, 0, 0.05);
}

.flag-icon {
  display: inline-block;
  width: 20px;
  height: 15px;
  flex-shrink: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border-radius: 2px;
}

.flag-icon-gb {
  background-image: url("../imgs/flags/gb.png");
}

.flag-icon-fr {
  background-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAzIDIiPjxwYXRoIGZpbGw9IiMwMDAwOTQiIGQ9Ik0wIDBoMXYySDB6Ii8+PHBhdGggZmlsbD0iI2ZmZiIgZD0iTTEgMGgxdjJIMXoiLz48cGF0aCBmaWxsPSIjZWYxNDM5IiBkPSJNMiAwaDF2MkgyeiIvPjwvc3ZnPg==");
}

.lang-select {
  position: relative;
}

.lang-menu {
  position: absolute;
  top: calc(100% + 6px);
  inset-inline-end: 0;
  z-index: 80;
  min-width: 112px;
  margin: 0;
  padding: 6px;
  list-style: none;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  box-shadow: 0 12px 30px rgba(7, 32, 50, 0.14);
}

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

.lang-option {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 8px 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #072032;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  text-align: start;
}

.lang-option:hover,
.lang-option.is-current {
  background: rgba(7, 32, 50, 0.06);
}

.flag-icon-sa {
  background-image: url("../imgs/flags/sa.svg");
}

@media only screen and (max-width: 991px) {
  .header-drawer .language-switcher {
    flex-direction: column;
    align-items: stretch;
  }

  .header-drawer .lang-select,
  .header-drawer .lang-menu {
    width: 100%;
  }

  .header-drawer .lang-menu {
    position: static;
    margin-top: 8px;
    box-shadow: none;
  }

  .header-drawer .flag-icon-sa + .lang-text::after {
    content: "العربية";
    font-size: 16px;
    font-weight: 600;
    line-height: 1.2;
  }
}
