.locale-bar {
  position: relative;
  z-index: 3;
  width: 100%;
}
.locale-bar__inner {
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: 10px;
  padding-block: 10px;
}
.locale-bar__inner > form {
  display: flex;
  flex: 1 1 0;
  min-width: 0;
  max-width: 280px;
}
.locale-bar__item {
  position: relative;
  flex: 1 1 0;
  min-width: 0;
  max-width: 280px;
  width: 100%;
}
.locale-bar__btn {
  width: 100%;
  justify-content: flex-start;
  gap: 8px;
  padding: calc(var(--button-border-thickness) + 7px) calc(var(--button-border-thickness) + 14px);
  font-size: var(--body3-font-size);
}
.locale-bar__glyph {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  opacity: 0.75;
}
.locale-bar__glyph svg { width: 100%; height: 100%; }
.locale-bar__glyph--cur {
  width: auto;
  min-width: 14px;
  height: auto;
  font-size: 1.05em;
  line-height: 1;
  font-weight: var(--body-bold-font-weight);
  opacity: 0.9;
}
.locale-bar__label {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.locale-bar__arrow {
  display: inline-flex;
  flex: 0 0 auto;
  margin-inline-start: auto;
  width: 10px;
  transition: transform 180ms ease;
}
.locale-bar__btn[aria-expanded="true"] .locale-bar__arrow {
  transform: rotate(180deg);
}
.locale-bar__panel {
  position: absolute;
  z-index: 50;
  top: calc(100% + 6px);
  left: 0;
  width: 100%;
  min-width: 100%;
  max-height: 280px;
  overflow: auto;
  padding: 6px;
  background: rgb(var(--color-background));
  border: 1px solid rgba(var(--color-button-secondary-border), 1);
  border-radius: var(--button-border-radius);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.12);
}
.locale-bar__list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.locale-bar__opt {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 10px;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: start;
  cursor: pointer;
  border-radius: var(--button-border-radius);
}
.locale-bar__opt:hover {
  background: rgba(var(--color-button-secondary-border), 0.1);
}
.locale-bar__opt[data-selected] {
  font-weight: var(--body-bold-font-weight);
}
.locale-bar__opt[data-selected]::after {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.55;
}
@media (--mobile) {
  .locale-bar__inner > form,
  .locale-bar__item {
    max-width: none;
  }
  .locale-bar__panel {
    width: max(100%, 220px);
  }
}

/* Google 翻译引擎：藏到屏幕外，页面上不出现第二个入口 */
.locale-bar__engine {
  position: fixed;
  left: -9999px;
  top: 0;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}
.goog-te-banner-frame,
.goog-te-balloon-frame,
.skiptranslate > iframe { display: none !important; }
body { top: 0 !important; }
.goog-text-highlight { background: none !important; box-shadow: none !important; }
.goog-tooltip, .goog-tooltip:hover { display: none !important; }
