/*
 * Unified language control
 *
 * Mirrors the mining-site globe dropdown and keeps it immediately beside the
 * engineer-support CTA across the legacy and multilingual commercial shells.
 */
.header-language-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.language-control {
  position: relative;
  z-index: 70;
  flex: 0 0 auto;
  width: 44px;
  margin: 0;
}

.language-control summary {
  display: inline-flex;
  width: 44px;
  height: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 6px;
  color: #fff;
  background: transparent;
  cursor: pointer;
  font-weight: 800;
  list-style: none;
}

.language-control summary:hover,
.language-control summary:focus-visible,
.language-control[open] summary {
  border-color: #f8b918;
  color: #f8b918;
  outline: none;
}

.language-control summary::-webkit-details-marker {
  display: none;
}

.language-globe-icon {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.language-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 80;
  display: grid;
  min-width: 150px;
  overflow: hidden;
  border: 1px solid #d7e0ed;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 18px 42px rgba(4, 28, 64, 0.18);
}

.language-menu a,
.main-nav .language-menu a,
.commercial-main-nav .language-menu a,
.nav .language-menu a {
  display: block !important;
  padding: 11px 14px !important;
  border: 0 !important;
  color: #061833 !important;
  background: #fff;
  font-weight: 800;
  line-height: 1.35;
  text-align: left;
  text-decoration: none;
  white-space: nowrap;
}

.language-menu a:hover,
.language-menu a:focus-visible,
.language-menu a[aria-current="true"] {
  color: #0648c7 !important;
  background: #eef5ff;
  outline: none;
}

.main-nav > .header-language-actions,
.commercial-main-nav > .header-language-actions,
.nav > .header-language-actions {
  margin-left: auto !important;
}

.header-language-actions > .nav-cta,
.header-language-actions > .commercial-nav-cta {
  width: auto;
  margin-left: 0 !important;
}

@media (max-width: 1180px) {
  .main-nav > .header-language-actions,
  .commercial-main-nav > .header-language-actions {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr);
    width: 100%;
    margin-top: 6px;
  }

  .header-language-actions > .nav-cta,
  .header-language-actions > .commercial-nav-cta {
    width: 100% !important;
    min-width: 0 !important;
  }
}

@media (max-width: 900px) {
  .nav > .header-language-actions {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr);
    width: auto;
  }
}

@media (max-width: 420px) {
  .header-language-actions {
    gap: 8px;
  }

  .nav > .header-language-actions > .nav-cta {
    padding-inline: 10px;
  }
}
