/* Language controls reuse the existing ink, peach, type, and corner tokens. */
.language-picker { position: relative; flex: none; font-size: 13px; font-weight: 500; color: #e7e9ef; }
.language-picker summary { cursor: pointer; padding: 10px 7px; min-height: 44px; display: flex; align-items: center; gap: 5px; list-style: none; white-space: nowrap; }
.language-picker summary::-webkit-details-marker { display: none; }
.language-picker summary::after { content: '⌄'; font-size: 12px; }
.language-options { position: absolute; right: 0; top: 100%; display: grid; min-width: 150px; padding: 8px; background: var(--ink); color: #fff; border-radius: 14px; box-shadow: 0 10px 30px rgba(23,28,43,.18); z-index: 60; }
.language-options a { padding: 8px 12px; min-height: 40px; border-radius: 8px; }
.language-options a:hover { background: rgba(255,255,255,.08); }
.language-options a[aria-current], .language-links a[aria-current] { color: var(--peach); text-decoration: underline; text-underline-offset: 4px; }
.language-links { display: flex; flex-wrap: wrap; gap: 0 18px; margin-top: 24px; font-size: 13px; color: #c9cdd8; }
.language-links a { display: inline-flex; align-items: center; min-height: 44px; }
.language-links a:hover { color: #fff; }
/* Let translated text wrap within the original components instead of clipping. */
html:not([lang="zh-Hans"]) :is(.hero-title, .h2, .final-title, .mega, .manifesto-end) { white-space: normal; max-width: 100%; }
html:not([lang="zh-Hans"]) .btn { white-space: normal; }
html:not([lang="zh-Hans"]) .btn > span:first-child { text-align: left; }
html:not([lang="zh-Hans"]) .badge { line-height: 1.4; }
html:not([lang="zh-Hans"]) .badge-m { flex: none; }
.nav-left, .nav-right { min-width: 0; }
.nav-links a { white-space: nowrap; }
@media (max-width:640px) {
  .nav-right { gap: 2px; }
  .language-picker summary { padding-inline: 4px; font-size: 12px; }
  .legal-nav { flex-wrap: wrap; }
  .legal-nav > .language-picker { position: absolute; right: 10px; top: 8px; }
  html:not([lang="zh-Hans"]) .nav-right .btn-sm { font-size: 13px; padding-left: 10px; gap: 6px; }
}
@media (max-width:640px) {
  .nav-menu > span { display: none; }
  .nav-right > .language-picker { position: absolute; left: 44px; top: 8px; }
  .nav-right > .language-picker .language-options { left: 0; right: auto; }
}
.legal :is(h1, h2, h3) { overflow-wrap: anywhere; }
