@font-face { font-family: Pretendard; src: url(fonts/PretendardVariable.woff2) format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Black Han Sans"; src: url(fonts/BlackHanSans-Regular.ttf) format("truetype"); font-display: swap; }
@font-face{font-family:"Nunito";src:url(fonts/Nunito-cyrillic-ext.woff2) format("woff2-variations");font-weight:200 1000;font-style:normal;font-display:swap;unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}
@font-face{font-family:"Nunito";src:url(fonts/Nunito-cyrillic.woff2) format("woff2-variations");font-weight:200 1000;font-style:normal;font-display:swap;unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}
@font-face{font-family:"Nunito";src:url(fonts/Nunito-latin-ext.woff2) format("woff2-variations");font-weight:200 1000;font-style:normal;font-display:swap;unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:"Nunito";src:url(fonts/Nunito-latin.woff2) format("woff2-variations");font-weight:200 1000;font-style:normal;font-display:swap;unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
/* 글꼴: 스튜디오 공통. 라틴·키릴 Nunito, 한글 본문 Pretendard, 한국어 제목 Black Han Sans, 로고는 모든 언어에서 Nunito 900 */
:root { --font: "Nunito", "Segoe UI", system-ui, sans-serif; --display: var(--font); --dw: 900; }
:root:lang(ko) { --font: "Nunito", Pretendard, "Malgun Gothic", "Apple SD Gothic Neo", "Noto Sans KR", system-ui, sans-serif; --display: "Black Han Sans", "Nunito", Pretendard, "Malgun Gothic", sans-serif; --dw: 400; }
:root:lang(ja) { --font: "Nunito", "Yu Gothic UI", "Meiryo UI", "Hiragino Sans", "Noto Sans JP", system-ui, sans-serif; }
:root:lang(zh-Hans) { --font: "Nunito", "Microsoft YaHei UI", "PingFang SC", "Noto Sans SC", system-ui, sans-serif; }
:root:lang(zh-Hant) { --font: "Nunito", "Microsoft JhengHei UI", "PingFang TC", "Noto Sans TC", system-ui, sans-serif; }
:root { --ink: #fff3e2; --muted: #c9ab93; --panel: #1d100cdb; --edge: #8a5a33; --gold: #f2c14e; --gold2: #ffdf8e; --wine: #7a1f2b; --bad: #ff5d6c; --safe-b: env(safe-area-inset-bottom); }
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; overflow: hidden; background: #0d0706; color: var(--ink); font-family: var(--font); overscroll-behavior: none; }
body { user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; word-break: keep-all; }
input { user-select: text; -webkit-user-select: text; }
[hidden] { display: none !important; }
#gl { position: fixed; inset: 0; width: 100%; height: 100%; display: block; touch-action: none; }
#vignette { position: fixed; inset: 0; pointer-events: none; background: radial-gradient(ellipse at 50% 45%, transparent 52%, #000000b8 100%); }
#redflash { position: fixed; inset: 0; pointer-events: none; background: radial-gradient(circle, #ff202000 25%, #d0001acc 100%); opacity: 0; }

button, .linkbtn { font: inherit; font-weight: 800; color: var(--ink); background: linear-gradient(#4b2c1e, #321b12); border: 1.5px solid var(--edge); border-radius: 12px; min-height: 44px; padding: 8px 16px; cursor: pointer; touch-action: manipulation; box-shadow: 0 3px 0 #140a06, inset 0 1px 0 #ffffff1c; transition: transform .08s, filter .15s; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
button:hover { filter: brightness(1.14); }
button:active { transform: translateY(2px); box-shadow: 0 1px 0 #140a06; }
button:disabled { opacity: .4; cursor: default; filter: none; }
button.primary { background: linear-gradient(var(--gold2), var(--gold) 55%, #d9992c); border-color: #ffe8ac; color: #2c1604; box-shadow: 0 3px 0 #7a4a0c, 0 0 22px #f2c14e40, inset 0 1px 0 #fff8; }
button.wine { background: linear-gradient(#9a2b3a, var(--wine)); border-color: #d97a86; }
button.ghost { background: #0000003d; box-shadow: none; }
button.big { font-family: var(--display); font-weight: var(--dw); font-size: 21px; letter-spacing: .5px; min-height: 52px; }
input { font: inherit; font-size: 16px; color: var(--ink); background: #0f0806cc; border: 1.5px solid var(--edge); border-radius: 12px; min-height: 44px; padding: 8px 12px; min-width: 0; width: 100%; outline: none; }
input:focus { border-color: var(--gold); }

.screen { display: none; position: fixed; inset: 0; pointer-events: none; }
.screen > * { pointer-events: auto; }
body[data-screen=home] #home, body[data-screen=lobby] #lobby, body[data-screen=closet] #closet, body[data-screen=game] #game { display: block; }
.panel { background: var(--panel); border: 1.5px solid var(--edge); border-radius: 20px; box-shadow: 0 18px 50px #000a, inset 0 0 0 4px #ffffff08; backdrop-filter: blur(9px); }
.row { display: flex; gap: 8px; align-items: center; }
.row > button { white-space: nowrap; }
.msg { color: var(--bad); margin: 0; min-height: 1.2em; font-size: 13px; font-weight: 700; }
.msg.soft { color: var(--muted); }
.small { font-size: 12px; color: var(--muted); line-height: 1.6; }
.small a { color: var(--gold2); }

#loading { position: fixed; inset: 0; display: none; flex-direction: column; align-items: center; justify-content: center; background: #0d0706; }
body[data-screen=loading] #loading { display: flex; }
.logo { font-family: "Nunito", system-ui, sans-serif; font-weight: 900; font-size: clamp(46px, 7.4vw, 84px); line-height: .98; color: var(--gold2); text-shadow: 0 4px 0 #7a3a0a, 0 0 34px #ffb43c66; }
.logo span { color: #fff3e2; text-shadow: 0 4px 0 var(--wine), 0 0 30px #ff506e55; }
.logo.small { font-size: 40px; }
.panel.side { position: absolute; left: max(18px, env(safe-area-inset-left)); top: 50%; transform: translateY(-50%); width: min(390px, 92vw); max-height: calc(100% - 20px); overflow: auto; padding: 22px; display: flex; flex-direction: column; gap: 11px; }
.tagline { margin: 0; color: var(--muted); }
.tagline b { color: var(--bad); }
.field { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); font-weight: 700; }
.links { display: flex; flex-wrap: wrap; gap: 4px; justify-content: center; }
.links button { min-height: 32px; padding: 3px 8px; font-size: 12px; font-weight: 600; background: none; border: 0; box-shadow: none; color: var(--muted); text-decoration: underline; }

.panel.dock { position: absolute; left: 50%; bottom: calc(10px + var(--safe-b)); transform: translateX(-50%); width: min(980px, calc(100% - 20px)); padding: 12px 16px; display: grid; grid-template-columns: 240px 1fr 230px; gap: 16px; align-items: center; }
.dock > div { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.codeBox small { color: var(--muted); font-size: 11px; }
.bigCode { font-family: "Nunito", monospace; font-weight: 900; font-size: 38px; letter-spacing: 9px; color: var(--gold2); line-height: 1; user-select: text; -webkit-user-select: text; }
#invite { min-height: 28px; font-size: 11px; padding: 3px 8px; }
.players { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.players li { display: flex; align-items: center; gap: 6px; background: #0006; border: 1.5px solid #ffffff1a; border-radius: 10px; padding: 6px 8px; font-size: 13px; font-weight: 800; white-space: nowrap; overflow: hidden; }
.players li i { width: 12px; height: 12px; border-radius: 50%; flex: none; }
.players li.me { border-color: var(--gold); }
.players li.off { opacity: .45; }
.players li.empty { color: #ffffff40; border-style: dashed; font-weight: 500; }

#closetDrag { position: absolute; inset: 0; touch-action: none; cursor: grab; }
.closetPanel { position: absolute; left: max(14px, env(safe-area-inset-left)); top: 12px; bottom: calc(12px + var(--safe-b)); width: min(430px, 48vw); padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.closetHead { display: flex; justify-content: space-between; align-items: center; }
.closetHead h2 { margin: 0; font-family: var(--display); font-weight: var(--dw); color: var(--gold2); }
.presets { display: flex; gap: 6px; flex-wrap: wrap; }
.presets button { flex: 1; min-height: 40px; padding: 4px 8px; white-space: nowrap; }
.slots { overflow: auto; display: flex; flex-direction: column; gap: 9px; flex: 1; padding-right: 4px; }
.slot h3 { margin: 0 0 4px; font-size: 12px; color: var(--muted); }
.slot div { display: flex; flex-wrap: wrap; gap: 5px; }
.slot button { min-height: 36px; padding: 4px 11px; font-size: 13px; border-radius: 9px; }
.slot button.on { background: linear-gradient(#8a5a1c, #6a3f10); border-color: var(--gold2); box-shadow: 0 0 0 1.5px var(--gold2), 0 0 16px #f2c14e55; }
.slot button.swatch { width: 40px; padding: 0; }

#topbar { position: absolute; left: 0; right: 0; top: 0; display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; padding: 8px max(10px, env(safe-area-inset-right)) 0 max(10px, env(safe-area-inset-left)); pointer-events: none; }
#topbar button { pointer-events: auto; min-height: 40px; padding: 4px 13px; }
#roundLbl { font-family: var(--display); font-weight: var(--dw); font-size: 16px; background: var(--panel); border: 1.5px solid var(--edge); border-radius: 10px; padding: 7px 12px; white-space: nowrap; }
#phaseBox { background: var(--panel); border: 1.5px solid var(--edge); border-radius: 14px; padding: 7px 18px 6px; text-align: center; max-width: 64vw; }
#phaseText { font-size: 15px; }
#phaseBox.mine { border-color: var(--gold2); box-shadow: 0 0 22px #f2c14e80; }
#timer { height: 5px; background: #ffffff1c; border-radius: 3px; margin-top: 5px; overflow: hidden; min-width: 180px; }
#timer i { display: block; height: 100%; width: 100%; background: var(--gold); transform-origin: left; }
#timer.low i { background: var(--bad); }

#plates, #cupTags { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.plate { position: absolute; transform: translate(-50%, -100%); display: flex; flex-direction: column; align-items: center; gap: 3px; white-space: nowrap; }
.plate .card { display: flex; align-items: center; gap: 7px; background: #170c08e6; border: 1.5px solid #ffffff2e; border-radius: 10px; padding: 3px 9px; font-size: 13px; font-weight: 800; }
.plate .dot { width: 10px; height: 10px; border-radius: 50%; }
.plate .stars { letter-spacing: 1px; color: #ffffff2e; }
.plate .stars b { color: var(--gold2); text-shadow: 0 0 8px #f2c14e; }
.plate .cups { font-size: 11px; color: var(--muted); }
.plate .bubble { background: var(--ink); color: #2a130a; border-radius: 12px; padding: 2px 11px; font-size: 13px; font-weight: 900; animation: pop .28s ease-out; }
.plate .bubble.pass { background: #8f827c; color: #1c100c; }
.plate .bubble:empty { display: none; }
.plate.turn .card { border-color: var(--gold2); box-shadow: 0 0 18px #f2c14ecc; }
.plate.out { opacity: .5; }
.cupTag { position: absolute; transform: translate(-50%, -100%); border-radius: 11px; padding: 1px 7px; font-size: 11px; font-weight: 900; white-space: nowrap; background: var(--gold); color: #2c1604; border: 1.5px solid #fff3; }
.cupTag.t { background: var(--bad); color: #fff; }

#banner { position: absolute; left: 50%; top: 22%; transform: translate(-50%, -50%); text-align: center; pointer-events: none; width: max-content; max-width: 94vw; opacity: 0; }
#banner.show { animation: banner var(--t, 2s) ease-out forwards; }
#banner b { display: block; font-family: var(--display); font-weight: var(--dw); font-size: clamp(30px, 6vw, 62px); color: var(--gold2); text-shadow: 0 4px 0 #5a2a06, 0 0 30px #000; }
#banner span { display: inline-block; margin-top: 4px; font-size: clamp(13px, 2vw, 18px); font-weight: 800; background: #140a06d9; border-radius: 20px; padding: 4px 14px; }
#banner span:empty { display: none; }
#banner.snap b { font-size: clamp(70px, 15vw, 170px); color: #fff; -webkit-text-stroke: 3px #7a0010; text-shadow: 0 8px 0 #b0001c, 0 0 50px #ff2040; transform: rotate(-8deg); }
@media (orientation: landscape) { #banner.snap { left: 24%; top: 30%; } #banner.snap.self, #banner.self { left: 50%; top: 11%; } #banner.snap.self b { font-size: clamp(54px, 9vw, 100px); } }
@keyframes banner { 0% { opacity: 0; transform: translate(-50%, -50%) scale(.4); } 10% { opacity: 1; transform: translate(-50%, -50%) scale(1.12); } 18% { transform: translate(-50%, -50%) scale(1); } 82% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -60%) scale(.98); } }
@keyframes pop { from { transform: scale(.3); } 70% { transform: scale(1.18); } to { transform: scale(1); } }

#mirror { position: absolute; left: max(10px, env(safe-area-inset-left)); bottom: calc(10px + var(--safe-b)); width: 214px; display: flex; flex-direction: column; gap: 5px; }
#mirrorView { height: 226px; border-radius: 16px; border: 2.5px solid var(--gold); box-shadow: 0 0 0 4px #1d100c, 0 10px 30px #000b; pointer-events: none; }
#myStatus { text-align: center; font-size: 12px; font-weight: 800; background: var(--panel); border-radius: 9px; padding: 3px 6px; white-space: nowrap; overflow: hidden; }
#emotes { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; }
#mirror.zoom { left: 50%; bottom: 44%; transform: translate(-50%, 50%); width: min(430px, 70vw); z-index: 3; }
#mirror.zoom #mirrorView { height: min(430px, 53vh); border-width: 4px; box-shadow: 0 0 0 5px #1d100c, 0 0 60px #000e; }
#mirror.zoom #emotes, #mirror.zoom #myStatus { visibility: hidden; }
#game:has(#mirror.zoom) #plates, #game:has(#mirror.zoom) #cupTags { visibility: hidden; }
.row.center { justify-content: center; }
#emotes button { min-height: 34px; padding: 0; font-size: 16px; border-radius: 9px; }
#btnPose { font-size: 11px !important; }
#poseMenu { position: absolute; left: max(10px, env(safe-area-inset-left)); bottom: calc(62px + var(--safe-b)); display: flex; flex-direction: column; gap: 4px; background: var(--panel); border: 1.5px solid var(--edge); border-radius: 12px; padding: 7px; z-index: 5; }
#poseMenu button { min-height: 34px; font-size: 13px; }
#poseMenu button.on { border-color: var(--gold2); box-shadow: 0 0 0 1.5px var(--gold2); }

#actions { position: absolute; left: 50%; bottom: calc(10px + var(--safe-b)); transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 6px; pointer-events: none; width: max-content; max-width: calc(100% - 460px); }
#actions button, #bidBox { pointer-events: auto; }
#hint { font-size: 13px; font-weight: 800; background: #140a06c7; border-radius: 20px; padding: 3px 14px; text-align: center; }
#hint:empty { display: none; }
#buttons { display: flex; gap: 8px; align-items: stretch; justify-content: center; flex-wrap: wrap; }
.token { flex-direction: column; gap: 0 !important; min-width: 92px; min-height: 66px; position: relative; padding: 6px 10px; }
.token i { display: block; width: 34px; height: 26px; }
.token.cheese i { background: linear-gradient(#ffd75a, #f0a915); clip-path: polygon(0 100%, 100% 100%, 100% 42%, 0 12%); }
.token.trap i { background: linear-gradient(90deg, #c9954f, #e3b878); border-radius: 4px; box-shadow: inset 0 0 0 3px #d7dbe3, inset 0 -9px 0 #b9382c; width: 24px; }
.token span { font-size: 12px; }
.token em { position: absolute; right: -6px; top: -7px; min-width: 22px; height: 22px; border-radius: 11px; background: var(--ink); color: #2a130a; font-style: normal; font-size: 13px; display: grid; place-items: center; }
#bidBox { display: flex; align-items: center; gap: 6px; background: var(--panel); border: 1.5px solid var(--edge); border-radius: 14px; padding: 6px; }
#bidBox > button:not(.primary) { width: 44px; padding: 0; font-size: 22px; }
#bidN { font-family: var(--display); font-weight: var(--dw); font-size: 34px; min-width: 1.6ch; text-align: center; color: var(--gold2); }
#actBid { font-size: 17px; min-width: 76px; }
#flipButtons { display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; }
#flipButtons button { border-color: var(--gold2); }

.overlay { position: fixed; inset: 0; background: #070302c9; display: flex; z-index: 20; padding: 10px; backdrop-filter: blur(3px); }
.sheet { display: none; margin: auto; width: min(430px, 100%); max-height: 100%; overflow: auto; flex-direction: column; gap: 9px; background: #241410f5; border: 1.5px solid var(--edge); border-radius: 18px; padding: 18px; }
.sheet.on { display: flex; }
.sheet h2 { margin: 0; font-family: var(--display); font-weight: var(--dw); color: var(--gold2); }
.sheet p { margin: 0; line-height: 1.55; font-size: 14px; }
.sheet ol { margin: 0; padding-left: 20px; line-height: 1.65; font-size: 14px; }
.toggle { display: flex; justify-content: space-between; align-items: center; background: #0005; border-radius: 10px; padding: 10px 12px; font-weight: 700; }
.toggle input { width: 24px; min-height: 24px; accent-color: var(--gold); }
#net { position: fixed; inset: 0; background: #070302a8; display: grid; place-items: center; z-index: 30; padding: 16px; }
#net[hidden] { display: none; }
#net > div { display: flex; flex-direction: column; gap: 10px; align-items: center; background: #241410f5; border: 2px solid var(--bad); border-radius: 16px; padding: 18px 22px; max-width: 92vw; text-align: center; font-weight: 800; }
#net p { margin: 0; }
#toast { position: fixed; left: 50%; top: 82px; transform: translateX(-50%); background: #0f0806f0; border: 1.5px solid var(--edge); border-radius: 20px; padding: 8px 16px; z-index: 31; opacity: 0; pointer-events: none; transition: opacity .2s; max-width: 92vw; width: max-content; text-align: center; font-size: 14px; font-weight: 800; }
#toast.show { opacity: 1; }

/* 폰 가로 */
@media (orientation: landscape) and (max-height: 520px) {
  .logo { font-size: 38px; }
  .logo br { display: none; }
  .panel.side { padding: 12px 14px; gap: 7px; width: min(360px, 52vw); }
  .panel.side .tagline { display: none; }
  button.big { min-height: 44px; font-size: 18px; }
  .panel.dock { grid-template-columns: 190px 1fr 180px; gap: 10px; padding: 8px 10px; }
  .bigCode { font-size: 28px; }
  .codeBox #invite, .codeBox small { display: none; }
  .dock button { min-height: 36px; padding: 4px 10px; }
  .players li { padding: 3px 6px; font-size: 12px; }
  #mirror { width: 132px; }
  #mirrorView { height: 124px; border-radius: 12px; }
  #mirror.zoom { width: 250px; }
  #myStatus { font-size: 11px; }
  #emotes button { min-height: 30px; font-size: 13px; }
  #actions { max-width: calc(100% - 300px); left: calc(50% + 66px); gap: 3px; bottom: calc(6px + var(--safe-b)); }
  #hint { font-size: 11px; padding: 1px 10px; }
  .token { min-height: 50px; min-width: 70px; padding: 3px 6px; }
  .token i { height: 18px; width: 26px; }
  .token.trap i { width: 18px; }
  #bidBox { padding: 3px; gap: 4px; }
  #bidBox button { min-height: 40px; }
  #bidN { font-size: 26px; }
  #roundLbl { font-size: 13px; padding: 5px 8px; }
  #phaseBox { padding: 4px 12px; }
  #phaseText { font-size: 13px; }
  .plate .card { font-size: 11px; padding: 1px 6px; gap: 5px; }
  .plate .cups { display: none; }
  .plate .bubble { font-size: 11px; }
}
/* 세로 화면 */
@media (orientation: portrait) {
  .panel.side { left: 50%; top: auto; bottom: calc(10px + var(--safe-b)); transform: translateX(-50%); gap: 8px; padding: 14px; max-height: 68%; }
  .panel.side .logo { font-size: 40px; text-align: center; }
  .panel.side .logo br { display: none; }
  .panel.dock { grid-template-columns: 1fr; gap: 8px; }
  .codeBox { align-items: center; }
  .players { grid-template-columns: repeat(2, 1fr); }
  .go .row { justify-content: center; }
  .closetPanel { left: 8px; right: 8px; width: auto; top: auto; height: 52%; }
  #btnMenu { order: 3; }
  #phaseText { font-size: 13px; }
  #timer { min-width: 120px; }
  #mirror { width: 104px; bottom: calc(max(166px, var(--actions-h, 0px)) + 18px + var(--safe-b)); left: 8px; }
  #mirrorView { height: 116px; border-radius: 12px; }
  #mirror.zoom { width: 270px; bottom: 46%; left: 50%; }
  #myStatus { font-size: 10px; }
  #emotes { grid-template-columns: repeat(3, 1fr); }
  #emotes button { min-height: 30px; font-size: 13px; }
  #poseMenu { bottom: calc(200px + var(--safe-b)); left: 118px; }
  #actions { max-width: calc(100% - 16px); width: 100%; }
  .plate .card { font-size: 11px; padding: 1px 6px; gap: 5px; }
  .plate .cups { display: none; }
  #banner { top: 18%; }
}
@media (prefers-reduced-motion: reduce) { #banner.show { animation-timing-function: linear; } }

/* 게임 이름, 설정·크레딧·개인정보 */
.gamename { font-family: var(--display); font-weight: var(--dw); font-size: 22px; color: var(--muted); margin-top: -6px; }
.token span { text-align: center; line-height: 1.15; max-width: 110px; }
.players li i.dot, .plate .dot { display: inline-grid; place-items: center; flex: none; font-style: normal; border-radius: 50%; }
.players li i.dot { width: 12px; height: 12px; }
body.cb .players li i.dot, body.cb .plate .dot { width: 18px; height: 18px; font-size: 12px; font-weight: 900; color: #000; }
body.cb .cupTag.t { background: #0b3f73; border-color: #fff; border-radius: 3px; }
.sheet h3 { margin: 6px 0 0; font-size: 14px; color: var(--gold2); }
.sheet .studio { color: var(--muted); }
.lic { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.lic li { display: flex; justify-content: space-between; gap: 12px; background: #0005; border-radius: 9px; padding: 7px 11px; font-size: 13px; }
.lic li span { text-align: right; color: var(--muted); }
.lic a { color: var(--gold2); }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.opt { display: flex; flex-direction: column; gap: 4px; background: #0004; border-radius: 12px; padding: 9px 11px; }
.opt small { color: var(--muted); font-size: 12px; }
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 5px; }
.seg button { min-height: 36px; padding: 3px 6px; font-size: 13px; box-shadow: none; }
.seg button[aria-pressed=true] { background: linear-gradient(#8a5a1c, #6a3f10); border-color: var(--gold2); box-shadow: 0 0 0 1.5px var(--gold2); }
select { font: inherit; font-size: 16px; color: var(--ink); background: #0f0806; border: 1.5px solid var(--edge); border-radius: 10px; min-height: 42px; padding: 6px 10px; }
/* 긴 번역이 단추 밖으로 나가지 않게 */
button { text-align: center; line-height: 1.2; }
:root:not(:lang(ko)):not(:lang(ja)):not(:lang(zh-Hans)):not(:lang(zh-Hant)) body { word-break: normal; overflow-wrap: break-word; }
@media (orientation: landscape) and (max-height: 520px) { .gamename { display: none; } .dock button.big { font-size: 15px; } .links button { min-height: 30px; } }
@media (orientation: portrait) { .gamename { text-align: center; } }
/* 검수 반영 (2026-11-25) */
#banner { z-index: 4; }
#mirror[hidden] { display: none; }
#bidBox { flex-wrap: wrap; justify-content: center; }
#bidTotal { width: 100%; text-align: center; font-size: 12px; font-weight: 800; color: var(--muted); }
.plate.target .card { pointer-events: auto; cursor: pointer; min-height: 34px; border-color: var(--gold2); animation: target 1s ease-in-out infinite alternate; }
@keyframes target { from { box-shadow: 0 0 0 0 #f2c14e55; } to { box-shadow: 0 0 0 5px #f2c14e88; } }
.plate .card { position: relative; }
.plate.target .card::after { content: ''; position: absolute; inset: -6px; }
.sheet:focus { outline: none; }
.sheet:focus-visible { outline: none; }
#banner.pick b { font-size: clamp(26px, 5vw, 50px); }
@media (orientation: portrait), (max-height: 520px) {
  .plate .cups { display: inline; font-size: 10px; }
  #flipButtons button { min-height: 40px; padding: 3px 10px; font-size: 12px; }
}
@media (orientation: landscape) and (max-height: 520px) {
  #mirror { width: 150px; }
  #mirrorView { height: 100px; }
  #emotes { grid-template-columns: repeat(3, 1fr); }
  #emotes button { min-height: 40px; font-size: 16px; }
  #btnPose { font-size: 10px !important; }
  #mirror.zoom { width: 230px; bottom: 36%; }
  #mirror.zoom #mirrorView { height: min(230px, 50vh); }
  #actions { max-width: calc(100% - 332px); left: calc(50% + 78px); }
  #bidTotal { font-size: 10px; }
  #bidBox { flex-wrap: nowrap; }
  #bidTotal { width: auto; max-width: 74px; line-height: 1.15; }
}

/* 화면 검수 반영 (2026-11-25) */
.plate .stars { color: #ffffff6b; font-size: 15px; }
#banner.low { top: 72%; }
#game:has(#banner.low.show) #plates { opacity: .25; }
#game:has(#mirror.zoom) #topbar { visibility: hidden; }
.sheet > button[data-close] { position: sticky; bottom: -10px; flex: none; box-shadow: 0 0 0 6px #241410, 0 4px 14px #000a; }
.links button { font-size: 13px; }
@media (orientation: landscape) and (max-height: 520px) {
  #banner.snap.self, #banner.self { left: 18%; top: 46%; max-width: 32vw; }
  #banner.snap.self b { font-size: 17vh; }
  #banner.self b { font-size: 11vh; }
  #banner.self span { font-size: 12px; max-width: 30vw; }
  #game:has(#mirror.zoom) #actions { left: 83%; max-width: 30vw; }
  #banner.low { top: 70%; }
  .plate .stars { font-size: 12px; }
}

/* 안내식 첫 판 */
body.tutorial #timer, body.tutorial #hint { display: none; }
#coach { pointer-events: auto; width: max-content; max-width: min(520px, 100%); display: flex; flex-direction: column; align-items: center; gap: 7px; background: #241410f5; border: 2px solid var(--gold2); border-radius: 14px; padding: 8px 16px; text-align: center; box-shadow: 0 0 24px #f2c14e66; }
#coach p { margin: 0; font-size: 16px; font-weight: 800; line-height: 1.35; text-wrap: balance; }
#coach .row:not(:has(button:not([hidden]))) { display: none; }
#tutSkip { position: absolute; right: max(10px, env(safe-area-inset-right)); bottom: calc(10px + var(--safe-b)); min-height: 36px; padding: 4px 12px; font-size: 13px; background: #170c08d9; z-index: 2; }
.tutGo, body.tutorial #flipButtons button { animation: tutgo .7s ease-in-out infinite alternate; }
@keyframes tutgo { from { box-shadow: 0 0 0 2px #ffdf8e66; translate: 0 0; } to { box-shadow: 0 0 0 5px #ffdf8e, 0 0 26px #f2c14e; translate: 0 -3px; } }
@media (orientation: landscape) and (max-height: 520px) {
  #coach { padding: 4px 10px; gap: 4px; }
  #coach p { font-size: 12px; }
  #coach button { min-height: 34px; }
  #tutSkip { bottom: calc(6px + var(--safe-b)); min-height: 32px; max-width: 82px; padding: 3px 6px; font-size: 11px; }
}
@media (min-height: 820px) and (orientation: landscape) { #coach { max-width: min(680px, 100%); padding: 12px 22px; } #coach p { font-size: 21px; } #coach button { font-size: 18px; } }
@media (orientation: portrait) { #coach p { font-size: 14px; } #tutSkip { right: 8px; bottom: calc(max(166px, var(--actions-h, 0px)) + 18px + var(--safe-b)); max-width: 46vw; } }
