/* Language-specific native fonts; never squeeze glyphs to fit. */
:root:lang(ko){--font:-apple-system,BlinkMacSystemFont,"Helvetica Neue",Helvetica,"Segoe UI",Arial,Roboto,"Malgun Gothic","Apple SD Gothic Neo","Noto Sans KR",sans-serif}
:root:lang(ja){--font:-apple-system,BlinkMacSystemFont,"Helvetica Neue",Helvetica,"Segoe UI",Arial,Roboto,"Yu Gothic","Hiragino Kaku Gothic ProN","Meiryo","Noto Sans JP",sans-serif}
:lang(ko) :is(h1,h2,h3,p,.fine,.notice,.hint){word-break:keep-all;overflow-wrap:break-word}
:root:lang(ko) .hdr-slogan{font-size:12px}
:root:lang(ko) .hdr-title{word-break:keep-all;overflow-wrap:normal;text-wrap:balance}
:lang(ja) :is(p,.fine,.notice,.hint){line-break:strict;overflow-wrap:break-word}
.language-list{display:grid;gap:8px;padding:4px 0 12px}
.language-list button{width:100%;min-height:48px;display:flex;align-items:center;justify-content:space-between;gap:16px;border:1px solid var(--hairline);background:#fff;color:var(--ink);border-radius:10px;padding:12px 16px;font:inherit;text-align:start}
.language-list button[aria-pressed=true]{color:var(--blue-ink);border-color:var(--blue-line);background:var(--blue-soft)}
.language-list button:focus-visible{outline:2px solid var(--blue);outline-offset:2px}
.language-list button:lang(ko){font-family:"Malgun Gothic","Apple SD Gothic Neo",sans-serif}
.language-list button:lang(ja){font-family:"Yu Gothic","Meiryo",sans-serif}
/* Translated strategy labels share a row with an action; wrap within their own column. */
:root:not([data-lang="zh"]) .strat{min-width:0;flex-wrap:wrap;white-space:normal;row-gap:4px}
/* Keep translated actions equal-height without clipping longer words or model uses. */
:root:not([data-lang="zh"]) .cp-token .btn{height:auto;min-height:48px;padding-block:10px;white-space:normal;line-height:1.4}
:root:not([data-lang="zh"]) .cp-token .btn>span{white-space:normal;overflow-wrap:anywhere}
:root:not([data-lang="zh"]) .res-model .res-title>span{white-space:normal;overflow:visible;text-overflow:initial;overflow-wrap:anywhere}
/* Category names remain readable; narrow screens can scroll the full tab row. */
:root:not([data-lang="zh"]) :is(.me-rec,.seg-wrap) .seg{overflow-x:auto;scrollbar-width:thin}
:root:not([data-lang="zh"]) :is(.me-rec,.seg-wrap) .seg button{flex:1 0 auto}
:root:not([data-lang="zh"]) .ai-sec{flex-wrap:wrap;row-gap:8px}
:root:not([data-lang="zh"]) .ai-sec .lnk{flex-shrink:0;white-space:normal;max-width:100%;text-align:start}
:root:not([data-lang="zh"]) .kv .icon-btn.mini{width:44px;height:44px;margin:0;padding:0}
:root:not([data-lang="zh"]) .kv .icon-btn.mini::after{inset:0}
@container (max-width:360px){
  :root:not([data-lang="zh"]) .ai-title{flex-wrap:wrap}
  :root:not([data-lang="zh"]) .ai-title .lt-copy{flex-basis:calc(100% - 60px)}
  :root:not([data-lang="zh"]) .ai-title .lt-side{margin-left:56px}
}
