/* 개별 화면 HUD(11/2 3단계, docs/dev/29-hud.md): 아래에서 올라오는 창·창 안 탭·알약 칩·어두운 상자·카드 안 작은 칸을 같은 판 계열로.
   css/hud-play.css 뒤에 불러 덮는다. 게임 속 물건을 흉내 낸 화면(와글 폰·개표 방송)은 그대로 둔다. */

/* ── 올라오는 창: 크림 판(금 징). 아래 변은 화면 끝이라 테두리 없이 ── */
.sheet-card { border: solid transparent; border-width: 16px 16px 0; border-image: url(../assets/hud/dock.webp) 40 fill / 16px 16px 0;   /* 자르는 선은 네 변 모두 40(아래를 0으로 자르면 양옆 띠에 아래 모서리 장식이 늘어나 번진다), 그리는 두께만 아래 0 */
  border-radius: 0; background: none;
  padding: 8px 6px calc(18px + env(safe-area-inset-bottom)); overflow-x: hidden; }
/* 자동 진행 바(js/auto.js autoBar)는 창 안쪽 여백만큼 음수 여백으로 가장자리까지 붙는다. 옛 여백(-20px·넓은 화면 -28px)이 위 6px·18px보다 커서
   자동 진행 중에만 창이 옆으로 14~22px 밀렸다(11/5 사장님 제보). 여백을 위 padding에 맞춘다. 판 테두리라 둥근 모서리도 없앤다 */
.auto-bar { margin: 14px -6px calc(-18px - env(safe-area-inset-bottom)); bottom: calc(-18px - env(safe-area-inset-bottom)); padding-left: 12px; border-radius: 0; }
/* PC: 창이 화면 아래에서 띄워져 있으니(index.html .sheet 4vh) 아래 변도 판 테두리로 마감한다. 휴대폰은 화면 끝에 붙어 아래 테두리 없이(11/5 사장님 "PC에선 밑이 뚝 잘려 보인다") */
@media (min-width: 760px) { .sheet:not(.arena) .sheet-card { border-bottom-width: 16px; border-image-width: 16px; } }

/* ── 창 안 탭: 밑줄 대신 판 위 꼬리표, 고른 탭은 어두운 판 ── */
.pane-tabs { gap: 4px; border-bottom: 2px solid #D9A62E; padding: 0 2px; }
.pane-tab { border: 1.5px solid transparent; border-bottom: 0; border-radius: 6px 6px 0 0; margin-bottom: 0; padding: 7px 11px 6px; color: #7A6A58; }
.pane-tab.on { background: #2A211E; color: #FFE58A; border-color: #2A211E; box-shadow: inset 0 2px 0 rgba(242, 199, 68, .55); }
@media (hover: hover) { .pane-tab:not(.on):hover { background: rgba(217, 166, 46, .14); color: #2A211E; } }

/* ── 알약 칩: 크림 칩 판, 고르면 어두운 알약 판 ── */
.pill { border: solid transparent; border-width: 7px 13px; border-image: url(../assets/hud/chip-cream.webp) 22 48 fill / 7px 13px; border-radius: 0; background: none; padding: 1px 0; color: #2A211E; }
.pill.sel { border-image-source: url(../assets/hud/pill-dark.webp); background: none; color: #FFF6DE; }
.pill.sel small { color: #E8C873; opacity: 1; }

/* ── 어두운 상자(상점 '내 기금'): 어두운 판 ── */
.cos-fundbar { border: 12px solid transparent; border-image: url(../assets/hud/panel-dark.webp) 44 fill / 12px; border-radius: 0; background: none; padding: 2px 4px; }
.cos-fundbar b { color: #FFE58A; }

/* ── 카드 안 작은 칸(선거 일정·정국 기상도·도전 목록): 판 위에 놓인 종이 칸 ── */
.el, .wd, .chal-list li { border-radius: 6px; background: #FFF9EC; box-shadow: inset 0 0 0 1.5px #E2C98C, 0 2px 0 rgba(176, 120, 32, .22); }
.chal-list li { border: 0; }
.chal-list li.got { background: #FFF3CC; box-shadow: inset 0 0 0 2px #D9A62E, 0 2px 0 rgba(176, 120, 32, .3); }
.el .turns { background: #2A211E; color: #FFE58A; }

/* ── 고르는 칸(출마 선언문의 성별·지역 등 .opt, 의견 종류 .fbw-k): 크림 칩 판, 고르면 금테 + 물 ── */
.opt, .fbw-k { border: 8px solid transparent; border-image: url(../assets/hud/choice.webp) 30 fill / 8px; border-radius: 0; background: none; box-shadow: none; }
.opt.sel, .fbw-k.on { border-color: transparent; background: none; outline: 3px solid #D9A62E; outline-offset: -3px; box-shadow: inset 0 0 0 999px rgba(242, 199, 68, .2); }
/* ── 글 쓰는 칸: 종이 + 금테 ── */
#nm, .fbw textarea, .wg-input { border-radius: 6px !important; background: #FFFCF4 !important; border: 2px solid #D9A62E !important; box-shadow: inset 0 2px 3px rgba(0, 0, 0, .08) !important; }
#nm:focus, .fbw textarea:focus { border-color: #2A211E !important; }

/* ── 결과 화면 안 덩어리(.end-blk: 도전·숨은 재능·결말 도감·새 기록 …): 활동 카드와 같은 크림 판, 강조할 덩어리는 금빛 물 ── */
.end-blk { border: 10px solid transparent; border-image: url(../assets/hud/choice.webp) 30 fill / 10px; border-radius: 0; background: none; padding: 6px 8px 8px; }
.end-blk.chal-new, .end-blk.end-hint { box-shadow: inset 0 0 0 999px rgba(242, 199, 68, .14); }
.rec-list li { border-radius: 6px; background: #FFF9EC; border: 0; box-shadow: inset 0 0 0 1.5px #E2C98C, 0 2px 0 rgba(176, 120, 32, .22); }
