/* Language controls and locale-specific wrapping, using existing Project V tokens. */
.header__inner { gap: 20px; }
.header__inner > .brand { order: 0; flex-shrink: 0; }
.header__inner > .nav { order: 1; margin-left: auto; gap: 20px; }
.header__inner > .language-switch { order: 2; flex-shrink: 0; }
.header__inner > .nav-toggle { order: 3; flex-shrink: 0; }
.language-switch { display: flex; align-items: center; gap: 2px; border: 1px solid var(--line-strong); border-radius: 999px; padding: 2px; background: var(--surface); }
.language-switch a { display: inline-flex; justify-content: center; align-items: center; min-width: 44px; min-height: 44px; padding: 6px 7px; border-radius: 999px; font-family: var(--font-kr); font-size: .72rem; line-height: 1.2; color: var(--fg-2); white-space: nowrap; }
.language-switch a[aria-current="page"] { background: var(--pv-deep); color: var(--fg); }
.language-switch a:hover { color: var(--fg); background: var(--surface-2); }
.language-switch a[aria-current="page"]:hover { background: var(--pv-main); }
html:lang(ja) { --font-kr: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif; --font-display: "Inter Tight", "Noto Sans JP", "Yu Gothic", Meiryo, sans-serif; --font-serif: "Noto Serif JP", "Yu Mincho", "Hiragino Mincho ProN", serif; }
html:lang(ja) body { word-break: normal; line-break: strict; }
html:lang(en) body { word-break: normal; overflow-wrap: break-word; }
html:lang(en) .character-hero__title { font-size: clamp(2.25rem, 4vw, 4rem); letter-spacing: -.045em; }
html:lang(ja) .character-hero__title { font-size: clamp(2.3rem, 4vw, 4.6rem); letter-spacing: -.045em; }
html:lang(en) .character-hero__lead { max-width: 48ch; }
html:lang(en) .eyebrow, html:lang(ja) .eyebrow { letter-spacing: .1em; }
.work__top, .work__name { flex-wrap: wrap; min-width: 0; }
.work__name .h3, .work__name .en { min-width: 0; }
html:lang(en) .character-profile__facts > div, html:lang(ja) .character-profile__facts > div { grid-template-columns: minmax(80px, .33fr) minmax(0, 1fr); }
html:lang(en) .character-profile__facts dt, html:lang(ja) .character-profile__facts dt { overflow-wrap: break-word; }
.character-hero__foot > div, .character-profile__facts dd, .planned-channel { min-width: 0; }
html:lang(en) .tag, html:lang(en) .status, html:lang(ja) .tag, html:lang(ja) .status { letter-spacing: .04em; }
@media (max-width: 1100px) {
  .header__inner { gap: 12px; }
  .header__inner > .language-switch { margin-left: auto; }
  .header__inner > .nav { position: fixed; inset: 72px 0 auto 0; margin-left: 0; flex-direction: column; align-items: stretch; gap: 0; padding: 12px var(--gutter) 24px; background: var(--bg-2); border-bottom: 1px solid var(--line); box-shadow: 0 30px 60px -20px rgba(0,0,0,.8); transform: translateY(-8px); opacity: 0; pointer-events: none; transition: opacity 250ms, transform 300ms var(--ease-out); }
  html.has-js .header__inner > .nav:not(.is-open) { visibility: hidden; }
  .header__inner > .nav.is-open { visibility: visible; opacity: 1; transform: none; pointer-events: auto; }
  .nav a { padding: 14px 0; min-height: 44px; font-size: 1rem; border-bottom: 1px solid var(--line); }
  .nav a::after { display: none; }
  .nav .btn { margin-top: 16px; min-height: 44px; justify-content: center; }
  .nav-toggle { display: inline-flex; }
  html:not(.has-js) .header__inner { height: auto; min-height: 72px; flex-wrap: wrap; padding-block: 10px; }
  html:not(.has-js) .header__inner > .nav { order: 4; position: static; transform: none; opacity: 1; pointer-events: auto; visibility: visible; width: 100%; box-shadow: none; padding: 0; }
  html:not(.has-js) .header__inner > .nav-toggle { display: none; }
}
@media (max-width: 820px) {
  .header__inner > .nav { inset-block-start: 64px; }
  html:lang(en) .character-hero__title { font-size: clamp(2.25rem, 7.8vw, 4.5rem); }
  html:lang(ja) .character-hero__title { font-size: clamp(2.3rem, 8.4vw, 4.7rem); }
}
@media (max-width: 480px) {
  .header__inner { gap: 8px; }
  .language-switch a { padding-inline: 5px; }
  html:lang(en) .character-hero__title { font-size: clamp(2.25rem, 9vw, 2.9rem); }
  html:lang(ja) .character-hero__title { font-size: clamp(2.3rem, 9vw, 2.9rem); }
  html:lang(en) .character-profile__facts > div, html:lang(ja) .character-profile__facts > div { grid-template-columns: 1fr; gap: 4px; }
  .gallery-dialog__bottom { padding-inline: 12px; gap: 8px; }
  .gallery-dialog__move { padding-inline: 12px; }
  .gallery-dialog__close { padding-inline: 12px; }
}
