/* BEAN TALK — DeskKit 위에 얹는 앱 배치 CSS.
   규칙: radius 5(var(--radius)) · 최소 14px · 중첩 배경/테두리 금지 · 같은 행 같은 높이 ·
   카드/그리드 분할 · 모바일(≤760px) 완전 반응형(100dvh + safe-area). */

:root {
  /* 포인트 색은 deskkit/tokens/colors.css(샘플 토큰)와 설정(app-settings.js accents)이 정한다. */
  /* 창·옆칸 뒤를 가리는 바탕. ★ 여태 어디에도 정의돼 있지 않아 창 여덟 개가 모두 뒤가 비친 채로 떴다
     (2026-09-25 윈도우 세션이 찾음). DeskKit 기본 창 바탕(.dk-scrim)과 같은 값. */
  --scrim: rgba(0, 0, 0, 0.28);   /* 샘플 '접속 중인 회원' 창 바탕 */
  /* 화면 아래 안전 영역(홈 막대 자리) — 화면 아래 끝에 닿는 줄(내 줄·글 쓰는 줄·설정 아래 줄)이 이만큼 늘어나고,
     글·단추는 늘어난 높이의 가운데에 선다(2026-09-30 사용자 규칙 — 맨 아래 막대는 화면 끝까지, 여백 없이).
     탭 막대가 있는 좁은 화면에서는 탭 막대 혼자 가진다 — 그 위 본문(.bt-body > section)은 0 으로 되돌린다.
     맥·윈도우·보통 브라우저에서는 0 이라 넓은 화면 모양은 그대로다. */
  --bt-sab: env(safe-area-inset-bottom);
  /* 보이는 높이의 1/100 — 평소엔 1dvh. 아이폰 · 아이패드에서 글자판이 뜨면 app-touch.js(keyboardFit)가 글자판 위 높이로 바꾼다.
     화면 · 뜨는 창의 높이는 dvh 를 바로 쓰지 말고 이것으로 잡는다(글자판이 떠도 위가 잘리지 않게). */
  --bt-vh: 1dvh;
  /* 맨 아래 한 줄(옆칸 내 줄 · 글 쓰는 줄)의 설계 높이 — 둘이 같아야 격자가 맞는다. 손가락 화면은 65px(아래 pointer:coarse). */
  --bt-row-h: 56px;
}

html, body { height: 100%; overflow: hidden; }
/* ★ 글자색 변수는 --text 다. 여기 --text-1(어디에도 없는 이름)을 적어 두어 글자색이 통째로 빠져 있었다(2026-09-28). */
body { margin: 0; background: var(--bg); color: var(--text); overflow: hidden; }

.bt-screen { height: calc(var(--bt-vh) * 100); display: flex; flex-direction: column; overflow-x: hidden;
  padding-top: env(safe-area-inset-top); padding-bottom: env(safe-area-inset-bottom); }
/* ★ 본 화면은 아래 안전 영역을 바깥에서 비우지 않는다 — 비우면 화면 맨 아래에 빈 띠가 깔린다(아이패드에서 옆칸·글 쓰는 줄 밑 20px).
     화면 끝에 닿는 줄이 저마다 --bt-sab 만큼 늘어나 끝까지 칠한다(좁은 화면은 탭 막대, 넓은 화면은 내 줄·글 쓰는 줄·설정 아래 줄·대시보드). */
#screen-main { padding-bottom: 0; }
[hidden] { display: none !important; }

/* ── 로그인 ── */
#screen-login { align-items: center; justify-content: center; overflow-y: auto; }

/* ★ 좁은 화면에서는 가운데 맞춤이 아니라 위에서 시작한다.
     세로로 가운데 맞추면 위쪽에 350px 가까운 빈 자리가 생기고, 자판이 올라오면
     그 빈 자리 때문에 글칸이 화면 밖으로 밀린다. */
@media (max-width: 600px) {
  /* ★ padding-top 을 다시 쓰면 .bt-screen 이 비켜 둔 안전 영역이 통째로 지워진다 —
     로고가 노치·다이내믹 아일랜드 밑으로 들어가 잘려 보였다. 더해서 쓴다. */
  #screen-login { justify-content: flex-start; padding-top: calc(env(safe-area-inset-top) + 8px); }
  .bt-login { gap: 12px; padding: 8px 0 24px; }
  .bt-login__head { padding-bottom: 0; }
  .bt-login__logo { width: 44px; height: 44px; }
  .bt-login__head h1 { margin: 6px 0 0; }
}
.bt-login { display: flex; flex-direction: column; gap: 16px; width: 400px; max-width: calc(100vw - 32px); padding: 24px 0; }
.bt-login__head { display: flex; flex-direction: column; gap: 4px; align-items: center; padding-bottom: 8px; }
.bt-login__logo { width: 64px; height: 64px; object-fit: contain; display: block; }
.bt-login__head h1 { margin: 12px 0 0; font-size: var(--text-2xl); font-weight: 700; }
.bt-login__head p { margin: 0; font-size: var(--text-sm); color: var(--text-3); text-align: center; }
.bt-login__form { display: flex; flex-direction: column; gap: 14px; }
/* 로그인하는 동안의 상태 줄 — 단추 글은 '로그인' 그대로 둔다 */
#login-busy { text-align: center; }

/* ── 사용법 — 설명 글은 늘 깔지 않고 '사용법' 을 눌렀을 때만 보인다(2026-09-28 사용자 규칙) ──
   설명이 든 칸(카드·창·화면)에 data-help-scope 를 달고, 설명 글에 .bt-help 를 단다. 단추(.bt-helpbtn)가 data-help="on" 을 켜고 끈다.
   ★ 숨긴 설명은 자리도 0 이다(내용이 곧 자리). 상태·경고 글은 .bt-help 를 달지 않는다 — 늘 보인다. */
[data-help-scope]:not([data-help="on"]) .bt-help { display: none !important; }
.bt-helpbtn[aria-expanded="true"] { background: var(--accent-muted); color: var(--accent); }
/* 기다리는 동안의 상태 줄 — '…' 로 끝나는 단추 글 대신 여기 적는다 */
.bt-busyline { margin: 0; font-size: var(--text-sm); color: var(--text-3); line-height: 1.5; }
/* 끝을 모르는 일을 기다리는 진행 막대 — 막대 전체에 스펙트럼(빨강 → 주황 → 노랑 → 초록 → 청록 → 파랑 → 보라 → 빨강)이 흘러간다.
   ★ 사용자 직접 요청(2026-10-07)이라 그라데이션 금지의 예외는 이 막대 하나뿐. 바깥 요청 없음(CSS 만). 두 바퀴를 깔고 한 바퀴만큼 밀어 이음매가 없다.
   쓰는 법: <div class="bt-spectrum" role="progressbar" aria-busy="true"></div> — 보일 때만 움직인다(숨기면 애니메이션도 멈춘다). */
.bt-spectrum { height: 6px; border-radius: 3px; overflow: hidden; background-color: var(--border);
  background-image: linear-gradient(90deg, hsl(0 78% 58%), hsl(30 85% 55%), hsl(55 85% 52%), hsl(125 60% 46%), hsl(180 70% 46%), hsl(220 78% 60%), hsl(275 70% 60%), hsl(330 75% 58%), hsl(360 78% 58%),
    hsl(30 85% 55%), hsl(55 85% 52%), hsl(125 60% 46%), hsl(180 70% 46%), hsl(220 78% 60%), hsl(275 70% 60%), hsl(330 75% 58%), hsl(360 78% 58%));
  background-size: 200% 100%; background-repeat: repeat-x; animation: bt-spectrum-flow 1.8s linear infinite, bt-spectrum-wave 3.6s ease-in-out infinite; }
.bt-spectrum[hidden] { display: none; animation: none; }
@keyframes bt-spectrum-flow { from { background-position: 0 0; } to { background-position: 100% 0; } }
@keyframes bt-spectrum-wave { 0%, 100% { filter: brightness(1); } 50% { filter: brightness(1.12); } }
@media (prefers-reduced-motion: reduce) { .bt-spectrum { animation: none; } }
.bt-spectrum--wait { margin-top: 8px; }
.bt-abt__spec { width: min(320px, 100%); margin-top: 10px; }

/* ── 서버 고르기 ── */
.bt-srv { display: flex; gap: 6px; align-items: stretch; }
.bt-srv__pick { flex: 1 1 auto; min-width: 0; }
.bt-srv__pick select, .bt-srv__pick input { width: 100%; min-width: 0; }
/* ★ 고르는칸은 제 그림표를 스스로 들고 있어 테두리가 두 겹으로 보인다.
     감싼 칸이 테두리를 맡고, 안쪽은 민얼굴로 둔다. */
.bt-srv__pick select {
  appearance: none; -webkit-appearance: none;
  border: 0; outline: none; color: inherit;
  font: inherit; height: 100%; cursor: pointer; padding-right: 18px;
  /* 네이티브 화살표를 지웠으니 우리가 그린다 — 그림 파일 없이 선 두 개로 */
  background-color: transparent;
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%),
                    linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: calc(100% - 6px) 55%, calc(100% - 1px) 55%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}
.bt-srv--add { margin-top: 6px; }
.bt-srv .dk-btn { flex: 0 0 auto; border-color: var(--border); }

/* ── 계정 만들기 · 찾기 ──
   ★ 아이폰 심사에서 "가입할 길이 안 보인다" 로 걸렸다(2026-09-18). 로그인 화면에서
     바로 계정을 만들 수 있게 단추를 둔다. 누르면 그 서버의 가입 화면이 열린다. */
/* 로그인 아래 세 갈래 — 회원가입 · SNS 간편가입 · 아이디·비밀번호 찾기.
   ★ 폭이 모자라면 줄을 바꾼다(글자를 줄이거나 자르지 않는다). 둘째 줄로 내려간 단추는 그 줄을 다 쓴다.
   ★ [hidden] 을 못박는다 — .dk-btn 의 display 가 hidden 속성을 덮는다(서버에 SNS 가 없을 때 숨김). */
.bt-login__join { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.bt-login__join .dk-btn { flex: 1 1 auto; min-width: 0; }
.bt-login__join .dk-btn[hidden] { display: none; }

/* ── SNS 간편가입 창 ──
   고른 서버의 SNS 관리 모듈에 켜 둔 것만 한 줄에 하나씩 단추로 그린다. 글자 단추만 — 상표 그림은 넣지 않는다. */
.bt-sns-pick { width: 380px; max-width: calc(100vw - 32px); }
.bt-sns-pick__text { margin: 0 0 14px; color: var(--text-2); line-height: 1.6; word-break: keep-all; }
.bt-sns-pick__list { display: flex; flex-direction: column; gap: 8px; }
.bt-login__sns-btn { width: 100%; }

/* 브라우저에서 로그인을 마칠 때까지 기다리는 창 */
.bt-sns-wait { width: 380px; max-width: calc(100vw - 32px); }
.bt-sns-wait__text { margin: 0; color: var(--text-2); line-height: 1.6; word-break: keep-all; }

/* ── 자동 로그인 · 비밀번호 저장 ── */
.bt-login__opts { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }
/* ★ 이 두 가지를 켜면 이 컴퓨터를 쓰는 다른 사람도 그대로 들어온다 — 그 말을 화면에 남긴다. */
.bt-login__warn { margin: -6px 0 0; font-size: var(--text-sm); color: var(--warning); line-height: 1.5; }
.bt-login__warn[hidden] { display: none; }
/* ── 계정 만들기가 남은 회원(서버 code account_setup) — 한 줄 + [계정 정보 넣기] [다시 로그인] + 결과 줄 ── */
.bt-login__setup { display: flex; flex-direction: column; gap: 8px; }
.bt-login__setup-line { margin: 0; font-size: var(--text-sm); font-weight: 600; color: var(--text); line-height: 1.5; word-break: keep-all; }
.bt-login__setup-row { display: flex; gap: 8px; flex-wrap: wrap; }
.bt-login__setup-row .dk-btn { flex: 1 1 auto; }
.bt-login__setup-row .dk-btn[hidden] { display: none; }

/* ── 본 화면 뼈대 ── */
.bt-main { flex: 1; display: flex; min-height: 0; position: relative; overflow-x: hidden; }
/* position:relative 는 내 정보 차림표를 이 안에 앉히려고 둔다.
   ★ 모바일 규칙(position:fixed)보다 반드시 앞에 있어야 한다 — 뒤에 두면 덮어써서
     좁은 화면에서도 사이드바가 260px 자리를 먹고 본문이 밀려난다. */
.bt-side { display: flex; flex-direction: column; width: 260px; min-width: 260px; position: relative;
  background: var(--surface); border-right: 1px solid var(--border); min-height: 0; }
.bt-body { flex: 1; display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.bt-body > section { flex: 1; display: flex; flex-direction: column; min-height: 0; }
.bt-lobby { align-items: center; justify-content: center; }

/* ── 사이드바 ── */
.bt-side__top { display: flex; align-items: center; gap: 8px; padding: 10px 10px 6px; }
.bt-side__brand { display: inline-flex; align-items: center; gap: 8px; margin-right: auto; min-width: 0; }
.bt-side__logo { height: 26px; width: auto; display: block; }
.bt-side__name { font-size: var(--text-lg); font-weight: 700; letter-spacing: -.01em; }
.bt-side__search { display: flex; gap: 6px; padding: 4px 10px 8px; align-items: center; }
/* 검색칸과 [+] 단추는 같은 줄 — 높이를 --control-h 하나로 맞춘다. */
.bt-side__search .dk-inputwrap, .bt-side__search .dk-btn { height: var(--control-h); }
.bt-side__search .dk-inputwrap { flex: 1; min-width: 0; }
.bt-side__search .dk-btn { flex: none; }
.bt-side__tabs { margin: 0 10px 8px; }
/* ★ 목록은 안쪽 여백·줄 사이 틈이 없다 — 고른 줄 배경이 사이드바 양옆에 딱 붙는다. 줄 사이·목록 위에 선은 긋지 않는다. */
.bt-side__list { flex: 1; padding: 0; display: flex; flex-direction: column; gap: 0; }
.bt-side__me { display: flex; align-items: center; gap: 8px; padding: 10px; border-top: 1px solid var(--border); }
.bt-side__nick { flex: 1; min-width: 0; font-size: var(--text-sm); font-weight: 600;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 방 이름 줄 — 자물쇠를 글자와 같은 줄 가운데에 놓는다(예전엔 글줄에 섞여 삐뚤었다). */
.bt-roomname { display: flex; align-items: center; gap: 5px; min-width: 0; }
.bt-roomname__t { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 내가 만든 방 — 목록에서 한눈에 */
.bt-room-own { flex: none; padding: 0 5px; border-radius: var(--radius);
  background: var(--accent-muted); color: var(--accent);
  font-size: var(--text-sm); font-weight: 600; line-height: 17px; }
/* 비밀번호 방 — 글자 뱃지 대신 자물쇠 그림 */
.bt-room-lock { flex: none; display: inline-flex; align-items: center; color: var(--text-3); }
.bt-room-lock .bt-ico { width: 13px; height: 13px; }
.bt-scrim { display: none; }

/* ── 방 머리 ── */
.bt-room__head { display: flex; align-items: center; gap: 6px; padding: 8px 12px;
  border-bottom: 1px solid var(--border); background: var(--surface); }
.bt-room__title { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.bt-room__name { font-size: var(--text-md); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-room__sub { font-size: var(--text-sm); color: var(--text-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-room__spacer { flex: 1; }
.bt-only-mobile { display: none; }
.bt-callbtn-on { background: var(--accent-muted); color: var(--accent); }


/* ── 메시지 ── */
/* ★ 방 안은 넘쳐 그려지지 않는다. 통화 칸이 커지면 대화·참여자 칸이 줄어야지,
   글칸 위로 삐져나와 겹치면 안 된다(참여자 머리글이 글칸에 겹쳐 보였다). */
.bt-room__wrap { flex: 1; display: flex; min-height: 0; overflow: hidden; }
.bt-people { overflow: hidden; }
/* 통화 칸은 스스로 줄어들 수 있어야 한다(자식 높이에 붙들리지 않게). */
.bt-call { min-height: 0; }
/* 글 쓰는 줄은 절대 밀려나지 않는다. */
.bt-input { flex: none; }
.bt-msgs { flex: 1; padding: 16px; display: flex; flex-direction: column; gap: 14px; }
.bt-msg { display: flex; gap: 10px; max-width: 100%; }
.bt-msg__body { display: flex; flex-direction: column; gap: 3px; min-width: 0; max-width: min(560px, 78%); }
.bt-msg__meta { font-size: var(--text-sm); }
.bt-msg__meta b { font-weight: 600; }
.bt-msg__time { color: var(--text-3); font-weight: 400; margin-left: 6px; }
.bt-msg__time:first-child { margin-left: 0; }

/* ── 말풍선 ──────────────────────────────────────────────────────────
   누가 한 말인지 한눈에 보이게. 내 말은 오른쪽에 붙이고 강조색으로 칠한다.
   ★ 글줄에 word-break:break-word 를 쓰면 flex 안에서 폭이 한 글자로 무너진다.
     줄바꿈은 overflow-wrap 으로만 다루고, 상자는 fit-content 로 글에 맞춘다. */
.bt-bubble { width: fit-content; max-width: 100%; padding: 8px 12px;
  border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border); }
.bt-msg__text { margin: 0; font-size: var(--text-md); line-height: 1.55;
  white-space: pre-wrap; word-break: keep-all; overflow-wrap: break-word; }

/* 지운 말 — 자리를 남기는 설정일 때만 보인다. 흐린 글씨 한 줄로 둔다. */
.bt-msg.is-gone .bt-bubble { background: transparent; border-style: dashed; }
.bt-msg__gone { color: var(--text-3); font-style: italic; }
.bt-msg.is-mine.is-gone .bt-bubble { background: transparent; border-color: var(--border); }
.bt-msg.is-mine.is-gone .bt-bubble .bt-msg__gone { color: var(--text-3); }

.bt-msg.is-mine { flex-direction: row-reverse; }
.bt-msg.is-mine .bt-msg__body { align-items: flex-end; margin-left: auto; }
.bt-msg.is-mine .bt-msg__meta { text-align: right; }

/* 그림·영상도 카드다 — 미리보기가 위, 이름·크기가 아래.
   말풍선이 곧 카드 테두리라 안쪽 살은 빼고 모서리만 물린다. */
.bt-bubble:has(> .bt-thumb) { padding: 0; overflow: hidden; width: fit-content; max-width: min(560px, 100%); }

/* 파일·소리는 말풍선을 카드로 쓴다. 안에 또 테두리를 두지 않는다. */
.bt-bubble:has(> .bt-filecard),
.bt-bubble:has(> .bt-msg__audio) { padding: 10px 12px; }
.bt-msg__img { max-width: min(560px, 100%); max-height: 360px; border-radius: var(--radius);
  border: 1px solid var(--border); cursor: pointer; display: block; }
/* ── 붙임 파일 ────────────────────────────────────────────────────────
   말풍선이 곧 카드다. 안에 테두리를 또 두르지 않는다.
   확장자를 네모 한 칸에 글자로 보인다(아이콘은 안 쓴다). */
.bt-filecard { display: flex; align-items: center; gap: 10px;
  min-width: 0; max-width: min(320px, 100%); color: inherit; text-decoration: none; }
.bt-filecard__ext { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center;
  min-width: 40px; height: 40px; padding: 0 6px; border-radius: var(--radius);
  background: var(--bg); border: 1px solid var(--border);
  font-size: 12px; font-weight: 700; letter-spacing: .02em; color: var(--text-2); text-transform: uppercase; }
/* 이름·크기 줄 — 파일 카드와 미리보기 카드가 함께 쓴다.
   ★ 이름은 자르지 않고 접는다. 가로가 좁으면 여러 줄이 된다.
     word-break:break-word 는 flex 안에서 폭을 한 글자로 무너뜨리므로 쓰지 않는다. */
.bt-cardmeta { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.bt-cardmeta__name { font-size: var(--text-sm); font-weight: 600; line-height: 1.35;
  white-space: normal; word-break: keep-all; overflow-wrap: anywhere; }
.bt-cardmeta__size { font-size: var(--text-sm); color: var(--text-3); }
.bt-filecard:hover .bt-cardmeta__name { text-decoration: underline; }
.bt-daybreak { align-self: center; }

/* ── 참여자 패널 ── */
.bt-people { width: var(--people-w, 220px); min-width: var(--people-w, 220px);
  border-left: 1px solid var(--border); position: relative;
  background: var(--surface); display: flex; flex-direction: column; min-height: 0; }
/* 대화와 참여자 사이 경계 — 잡고 끌면 너비가 바뀐다(경계선 위 6px 만 잡힌다). */
.bt-people__grip { position: absolute; left: -3px; top: 0; bottom: 0; width: 6px; z-index: 5;
  cursor: col-resize; background: transparent; }
.bt-people__grip:hover, body[data-resizing] .bt-people__grip { background: var(--accent); }
body[data-resizing] { cursor: col-resize; user-select: none; }
.bt-people__head { display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 8px 8px 6px 12px; font-size: var(--text-sm); font-weight: 600; color: var(--text-3);
  border-bottom: 1px solid var(--border); }
.bt-people > .dk-scroll { flex: 1; padding: 0 6px 6px; display: flex; flex-direction: column; gap: 2px; }
.bt-person { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: var(--radius); }
/* 이름과 방장 표를 한 덩어리로 — 이름만 줄어들고 표는 이름에 붙어 있게 */
.bt-person__name { flex: 1; min-width: 0; display: flex; align-items: center; gap: 6px; }
.bt-person__nick { min-width: 0; font-size: var(--text-sm); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-owner { flex: none; padding: 0 5px; border: 1px solid var(--border); border-radius: var(--radius);
  font-size: var(--text-sm); line-height: 17px; color: var(--text-3); }
.bt-person__state { display: flex; gap: 4px; color: var(--text-3); font-size: 14px; }
.bt-person--off { opacity: .45; }

/* ── 입력바 ── */
/* 화면 끝에 닿으면(아이패드) 안전 영역만큼 늘어나고 글칸·단추는 그 가운데에 선다 — 위아래에 반씩. */
.bt-input { display: flex; gap: 8px; align-items: center; padding: calc(10px + var(--bt-sab) / 2) 12px;
  border-top: 1px solid var(--border); background: var(--surface); }
.bt-input__box { flex: 1; }
/* 메시지 칸 — 시프트+엔터로 줄을 늘리면 칸이 따라 자란다.
   ★ 감싸개는 높이가 못박혀 있어 그대로 두면 글칸이 잘린다. 여기서만 풀어 준다. */
.bt-input__box { height: auto; min-height: var(--control-h); align-items: center; padding: 6px 10px; }
.bt-input__box > textarea {
  border: 0; outline: none; background: transparent; padding: 0; margin: 0;
  font: inherit; font-size: var(--text-sm); color: var(--text);
  width: 100%; min-width: 0; resize: none; overflow-y: hidden;
  line-height: 1.5; max-height: 132px;
}
.bt-input__box > textarea::placeholder { color: var(--text-3); }

/* ── 설정 ──────────────────────────────────────────────────────────────────────────────
   ★ 다른 빈 앱 설정 창과 한 꼴이다(2026-09-28 사용자 지시 — 겉모습은 빈뮤즈, 구성은 빈픽).
     · 위쪽 밑줄 탭(DeskKit .dk-tabs — 글자만, 고른 탭은 강조색 + 2px 밑줄). '사용법' 은 아래 줄 왼쪽 끝(다른 빈 앱의 [사용법 … 닫기 저장] 줄 자리 — 2026-09-28).
     · 탭마다 한 줄에 한 설정 — 이름은 왼쪽 한 칸(흐린 글씨), 값은 오른쪽. 이름 칸 폭은 그 탭에서 가장 긴 이름만큼
       (격자 max-content — 말을 바꾸거나 줄이 숨고 드러나도 저절로 다시 잰다). 줄 사이는 1px 선 하나, 묶음 제목은 굵게.
     · 카드·상자 없음 — 바탕은 창 바탕(--bg) 한 겹.
     · 좁은 화면(≤760)에서는 탭 줄이 고르는 칸 하나가 되고, 이름은 값 위로 올라간다.
   ★ 줄(.bt-set__row)·묶음(.bt-set__grp)은 display:contents — 이름·값 칸이 탭 격자(.bt-set__rows)의 두 칸에 곧바로 앉는다.
     그래서 이름 칸 폭이 탭 안의 모든 줄에 하나로 걸리고, 숨긴 줄(hidden·아이폰 숨김·'사용법' 뒤 설명)은 자리도 0 이다. */
#view-settings { --set-pad: 6px; --set-ctrl: 280px; --set-slider: 200px; background: var(--bg); }
.bt-settings { flex: 1 1 auto; min-height: 0; padding: 8px 20px calc(28px + var(--bt-sab)); }
.bt-spane { max-width: 760px; }

/* 탭 줄 — 바닥 선 한 줄 위에 글자 탭. 고른 탭의 2px 밑줄이 그 선 위에 겹쳐 앉는다(선은 ::after, 탭이 그 위에 그려진다). */
.bt-stabs { position: relative; flex: none; display: flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 16px 0 8px; }
/* 11-13 선은 바탕(height 1px)이 아니라 테두리로 — 바탕 칸은 소수 배율(1.25 · 1.5)에서 자리에 따라 기기 화소 두 줄이 된다, 테두리는 늘 한 줄. */
.bt-stabs::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 0; border-top: 1px solid var(--border); pointer-events: none; }
.bt-stabs .bt-stabs__tabs { flex: 1 1 auto; min-width: 0; align-self: stretch; align-items: stretch; gap: 0; border-bottom: 0; }
.bt-stabs .dk-tabs__tab { position: relative; z-index: 1; flex: none; height: auto; margin-bottom: 0; white-space: nowrap; }
/* 고르는 칸(app-listbox 단추)은 탭 줄이 안 들어갈 때만 — .bt-lb 의 inline-flex 보다 무겁게 못박는다 */
.bt-stabs .bt-stabs__pick { display: none; }
/* 탭 이름이 한 줄에 다 안 들어가면(긴 말·좁은 창) 탭 줄 대신 고르는 칸 하나 — 글자를 줄이거나 자르지 않는다(setTabs.fit). */
.bt-stabs[data-compact] { padding: 8px 20px; }
.bt-stabs[data-compact] .bt-stabs__tabs { display: none; }
.bt-stabs[data-compact] .bt-lb.bt-stabs__pick { display: inline-flex; flex: 0 1 var(--set-ctrl); min-width: 0; }

/* 아래 줄 — 왼쪽 끝 '사용법'(그 탭에 설명이 있을 때만), 오른쪽 끝 '닫기'(11-12 리디자인 — 머리줄 '뒤로' 를 옮김).
   빈톡 설정은 고르는 즉시 걸려 저장 단추가 없다(대표님 11-12). 닫기가 늘 있으니 줄도 늘 있다. */
.bt-sfoot { flex: none; display: flex; align-items: center; gap: 8px; padding: calc(8px + var(--bt-sab) / 2) 20px; border-top: 1px solid var(--border); background: var(--bg); }
.bt-sfoot > .bt-helpbtn { flex: none; }
/* 탭 한 판 = 격자 두 칸(이름 | 값). 이름 칸은 가장 긴 이름만큼(210~320px — 다른 빈 앱 설정과 같은 최소 폭, 넘으면 이름이 줄을 바꾼다). */
.bt-set__rows { position: relative; display: grid; grid-template-columns: max-content minmax(0, 1fr); }
/* ★ 줄 사이 선 — 줄마다 위에 선을 긋고, 판 맨 위 1px 만 바탕색으로 덮는다. 맨 위 줄들이 숨어도(hidden·아이폰 숨김)
     첫 보이는 줄 위에는 선이 안 남는다(탭 줄 선과 두 겹이 되지 않는다). 숨은 줄은 자리가 없으니 선도 없다. */
.bt-set__rows::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 1px; z-index: 2;
  background: var(--bg); pointer-events: none; }
.bt-set__row, .bt-set__grp { display: contents; }
.bt-set__row > * { grid-column: 2; }
.bt-set__row > .bt-set__label { grid-column: 1; }
.bt-set__row:not(.bt-set__row--sub) > .bt-set__label,
.bt-set__row:not(.bt-set__row--sub) > .bt-set__label + * { border-top: 1px solid var(--border); }
/* 이름 — 흐린 글씨. 값 첫 줄(컨트롤 한 줄)의 세로 가운데에 맞춘다 — 값이 여러 줄(설명·상태 글)이어도 이름은 첫 줄 옆에 남는다. */
.bt-set__label { min-width: 210px; max-width: 320px;
  padding: calc(var(--set-pad) + (var(--control-h) - 20px) / 2) 24px var(--set-pad) 0;
  font-size: var(--text-sm); line-height: 20px; color: var(--text-3); word-break: keep-all; overflow-wrap: anywhere; }
/* 값 — 컨트롤·체크·단추를 한 줄에, 넘치면 다음 줄로. 한 줄 안은 한 크기(14px). */
.bt-set__value { min-width: 0; padding: var(--set-pad) 0; display: flex; flex-wrap: wrap; align-items: center; align-content: flex-start;
  gap: 8px 12px; font-size: var(--text-sm); color: var(--text); }
/* 글만 있는 값(서버 주소·아이디·판) — 이름과 같은 자리·같은 줄 높이. 칸 높이는 컨트롤 줄과 같다. */
.bt-set__value--text { display: block; min-height: calc(var(--control-h) + var(--set-pad) * 2 + 1px);
  padding-top: calc(var(--set-pad) + (var(--control-h) - 20px) / 2); line-height: 20px; overflow-wrap: anywhere; }
/* 묶음 제목 — 굵게, 글 색. 위 묶음과는 선 하나와 넉넉한 틈으로 가른다. */
.bt-set__head { grid-column: 1 / -1; margin: 0; padding: 22px 0 8px; border-top: 1px solid var(--border);
  font-size: var(--text-sm); font-weight: 700; line-height: 20px; color: var(--text); }
.bt-set__rows > .bt-set__head:first-child { padding-top: 10px; }
/* 보조 줄(시험 단추·미리보기·미터·상태 글) — 바로 위 줄에 붙는다. 선도 이름도 없다. */
.bt-set__row--sub > .bt-set__label { display: none; }
.bt-set__row--sub > .bt-set__value { padding-top: 0; }
.bt-set__row--sub > .bt-hevc-install { justify-self: start; margin: 0 0 var(--set-pad); }
/* 설명·상태 글은 늘 컨트롤 아래 제 줄에.
   ★ 내용이 곧 자리 — 빈 상태 글은 제 줄을 차지하지 않는다. 글만 담는 보조 줄은 글이 비면 줄째 없다
     (#v-outchanhelp · #v-chanhelp · #mic-state · #dev-note 가 '' 일 때 빈 줄이 남았다 — 2026-09-28). */
.bt-set__value > .dk-fieldrow__help { flex: 1 1 100%; line-height: 1.5; word-break: keep-all; overflow-wrap: anywhere; }
.dk-fieldrow__help.bt-set__value { display: block; line-height: 1.5; color: var(--text-3); word-break: keep-all; overflow-wrap: anywhere; }
.dk-fieldrow__help.bt-set__value.bt-warn { color: var(--danger); }
.bt-set__value > .dk-fieldrow__help:empty,
.bt-set__row--sub > .dk-fieldrow__help.bt-set__value:empty { display: none; }
/* 컨트롤 폭 — 고르는 칸·글칸은 한 폭, 밀대(와 게이트 막대)는 한 폭 + 값. 칸이 좁으면 줄어든다(긴 이름은 말줄임 + 말풍선). */
.bt-set__value > .bt-lb, .bt-set__value > input[type="text"] { flex: 0 1 var(--set-ctrl); min-width: 0; }
.bt-set__value > .dk-btn, .bt-set__value > .bt-lb, .bt-set__value > input[type="text"] { height: var(--control-h); }
/* 체크상자도 컨트롤 한 줄 높이를 차지해야 이름과 세로 가운데가 맞는다(단추·고르는 칸과 같은 자리). */
.bt-set__value > .dk-check { min-height: var(--control-h); }
.bt-set__value > .bt-range { flex: 0 1 var(--set-slider); min-width: 120px; max-width: none; height: var(--control-h); }
.bt-set__value > .bt-mono { white-space: nowrap; }
/* 글칸(마이크 음소거 단축키) — 고르는 칸과 같은 테두리·높이 */
.bt-set__value > input[type="text"] { padding: 0 10px; border: 1px solid var(--border); border-radius: var(--radius);
  background: transparent; color: var(--text); font: inherit; font-size: var(--text-sm); }
.bt-set__value > input[type="text"]:focus { border-color: var(--accent); outline: 3px solid var(--focus-ring); outline-offset: 0; }
.bt-set__value > input[type="text"]::placeholder { color: var(--text-3); }
/* 포인트 컬러 — 한 줄에 열 개씩 두 줄(칸은 값 칸 안에 따로 — 줄 선은 값 칸 폭을 그대로 쓴다) */
.bt-accents { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; max-width: 360px; min-height: var(--control-h); }
.bt-set__value > .bt-diag { flex: 1 1 100%; min-width: 0; }
.bt-set__value > .bt-meter { flex: 0 1 var(--set-ctrl); }
/* 새 판 알림 띠 — 일반 탭 맨 위(새 판이 있을 때만) */
.bt-spane > .bt-update { margin: 8px 0 12px; }
.bt-spane > .bt-update__status { margin: -4px 0 12px; }
/* 정보 — 앱 그림 */
.bt-about__logo { display: block; width: 64px; height: 64px; object-fit: contain; margin: 16px 0 12px; }
.bt-about__desc { margin: 12px 0 0; color: var(--text-3); font-size: var(--text-sm); line-height: 1.6; word-break: keep-all; }
/* 손가락으로 쓰는 화면 — 탭도 44px */
@media (pointer: coarse) { .bt-stabs { min-height: 44px; } }
/* 좁은 화면 — 탭 줄은 고르는 칸 하나, 이름은 값 위로(한 칸 격자). 선은 이름 위에(이름이 없으면 값 위에). */
@media (max-width: 760px) {
  .bt-settings { padding: 4px 16px 24px; }
  .bt-stabs { padding: 8px 16px; }
  .bt-sfoot { padding: 8px 16px; }
  /* (다른 방에서 통화 중일 때 떠 있는 '통화 중' 막대는 이제 탭 막대 위에 서고, 본문이 그 자리를 비워 둔다 — 아래 '탭 막대' 묶음.
     예전처럼 이 줄에만 여백을 더하지 않는다.) */
  .bt-stabs .bt-stabs__tabs { display: none; }
  .bt-stabs .bt-lb.bt-stabs__pick { display: inline-flex; flex: 1 1 auto; min-width: 0; }
  .bt-set__rows { grid-template-columns: minmax(0, 1fr); }
  .bt-set__row > * { grid-column: 1; }
  .bt-set__label { min-width: 0; max-width: none; padding: 12px 0 2px; }
  .bt-set__label:empty { display: none; }
  .bt-set__row:not(.bt-set__row--sub) > .bt-set__label + * { border-top: 0; }
  .bt-set__row:not(.bt-set__row--sub) > .bt-set__label:empty + * { border-top: 1px solid var(--border); padding-top: 12px; }
  .bt-set__value { padding: 4px 0 12px; }
  .bt-set__value--text { min-height: 0; padding-top: 2px; }
  .bt-set__row--sub > .bt-set__value { padding-top: 0; margin-top: -4px; }
  .bt-set__value > .bt-lb, .bt-set__value > input[type="text"] { flex: 1 1 200px; }
  .bt-set__value > .bt-range, .bt-set__value > .bt-gate__track { flex: 1 1 150px; }
  .bt-set__value > .bt-meter { flex: 1 1 100%; }
}
.bt-mono { font-family: var(--font-mono); font-size: var(--text-sm); }
/* 진단 기록 — 길어지면 스스로 넘긴다(창 가로너비는 절대 안 밀리게). */
.bt-diag { display: block; max-height: 180px; overflow: auto; margin: 0;
           font-family: var(--font-code); font-size: var(--text-sm); line-height: 1.6;
           color: var(--text-2); white-space: pre-wrap; word-break: break-all;
           border: 1px solid var(--border); border-radius: var(--radius); padding: 8px 10px; }
/* 고정폭 칸이라도 안내 글이 떠 있는 동안은 보통 글꼴로 쓴다.
   ★ 고정폭 글꼴은 빈칸 너비가 보통 글꼴의 두 배(8px vs 4px)여서, 한글 안내 글이
     '빈톡  서버가  설치된  도메인' 처럼 띄어쓰기가 벌어져 보인다.
     주소를 치는 순간 다시 고정폭으로 돌아가 도메인이 또렷하게 읽힌다. */
.dk-inputwrap--mono > input:placeholder-shown { font-family: var(--font-sans); }
.bt-accent-dot { width: 26px; height: 26px; border-radius: var(--radius); border: 1px solid var(--border);
  cursor: pointer; padding: 0; }
/* 고른 색 — 그림자 고리 대신 바깥 선(그림자 금지 규칙) */
.bt-accent-dot[data-on="true"] { outline: 2px solid var(--accent); outline-offset: 2px; }
.bt-accent-dot:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }

/* ── 오버레이/다이얼로그 ── */
.bt-overlay { position: fixed; inset: 0; background: var(--scrim); display: grid; place-items: center; z-index: 60;
  padding: 16px; }
/* ★ 대화상자는 창보다 길어지면 안에서 굴러야 한다. 넓은 화면에는 최대 높이가 없어서, 칸이 많은
     가입 창(휴대폰 인증·이름·약관)이 낮은 창에서 위아래로 잘려 가입 단추에 손이 안 닿았다.
     머리·단추 줄은 그대로 두고 본문만 굴린다. */
.bt-overlay > .dk-dialog { max-height: calc(var(--bt-vh) * 100 - 32px); min-height: 0; }
.bt-overlay > .dk-dialog > .dk-dialog__body { flex: 1 1 auto; min-height: 0; overflow-y: auto; }
.bt-dlg__form { display: flex; flex-direction: column; gap: 12px; }
.bt-dlg__desc { margin: 0; font-size: var(--text-sm); color: var(--text-3); }

/* ── 토스트 ── */
.bt-toasts { position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom));
  display: flex; flex-direction: column; gap: 8px; z-index: 80; }

/* ── 모바일 (≤760px) — 사이드바는 오버레이, 참여자 패널은 겹판 ── */
@media (max-width: 760px) {
  .bt-only-mobile { display: inline-flex; }
  /* ★ 로고 줄은 아예 두지 않는다 — 로고는 머리줄 안으로 들어갔고, 안전 영역은
     .bt-screen 이 이미 비켜 준다. 여기서 또 비켜 주면 위가 두 번 비어 보인다. */
  .bt-topbar.bt-only-mobile { display: none; }
  /* 그림 단추라 자리를 적게 먹는다 — 이름 자리를 넓게 준다. */
  .bt-room__title { min-width: 130px; }
  /* ★ 아래 안전 영역은 옆칸이 아니라 맨 아래 내 줄이 가진다 — 옆칸에 여백으로 주면 내 줄 밑에 빈 띠(34px)가 남았다.
       내 줄이 화면 끝까지 늘어나고 이름·마이크·상태는 그 가운데에 선다(.bt-side__mebar · --bt-sab). */
  .bt-side { position: fixed; top: 0; bottom: 0; left: 0; z-index: 50; width: min(300px, 84vw);
    transform: translateX(-104%); transition: transform .16s ease;
    padding-top: env(safe-area-inset-top); padding-bottom: 0; }
  .bt-side[data-open="true"] { transform: translateX(0); }
  .bt-scrim { display: block; position: fixed; inset: 0; background: var(--scrim); z-index: 45;
    opacity: 0; pointer-events: none; transition: opacity .16s ease; }
  .bt-side[data-open="true"] ~ .bt-scrim, .bt-scrim[data-open="true"] { opacity: 1; pointer-events: auto; }
  .bt-people__grip { display: none; }
  .bt-people { position: fixed; top: 0; bottom: 0; right: 0; z-index: 50;
    width: min(280px, 80vw); min-width: 0;
    padding-top: env(safe-area-inset-top); }
  /* 참여자 판은 화면 아래 끝까지 칠하고, 목록은 끝까지 굴러 내려가도 마지막 줄이 홈 막대 위에 선다.
     ★ 판 자체에 여백을 주지 않는다 — 목록 밑에 빈 띠가 남는다. 굴림칸 안쪽 끝에만 둔다(env 를 바로 쓴다 — 방 화면 안이라 --bt-sab 는 0). */
  .bt-people > .dk-scroll { padding-bottom: calc(6px + env(safe-area-inset-bottom)); }
  .bt-msgs { padding: 12px; }
  .bt-callgrid { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); max-height: calc(var(--bt-vh) * 38); }
  /* (설정 화면의 좁은 화면 규칙은 위 '설정' 묶음에 모아 두었다 — 탭 줄은 고르는 칸, 이름은 값 위로.) */
  /* iOS 확대 방지 — 모바일 입력은 16px */
  .bt-input input, #screen-login input { font-size: 16px; }
  /* 방 머리 — 그림 단추라 좁아도 들어간다. 이름 자리만 지켜 준다. */
  .bt-room__head { gap: 6px; padding: 6px 10px; }
  .bt-room__title { min-width: 72px; }
}

.bt-login__hint { color: var(--text-3); }

/* ── 툴팁 자리 ──
   DeskKit 기본 말풍선은 버튼 '위'로 뜬다. 화면 맨 위 줄(방 머리·사이드바 상단)에서는
   그 자리가 창 밖이라 잘리므로 아래로 뒤집는다. 위에 겹칠 것이 없게 z-index 도 올린다. */
.bt-room__head { position: relative; z-index: 30; overflow: visible; }
/* ★ 말풍선은 CSS(::after)로 띄우지 않는다 — 창 모서리에서 잘리는 걸 막을 수가 없다.
   화면 안으로 눌러 앉히는 하나짜리 말풍선(.bt-tip)을 자바스크립트가 띄운다. */
.dk-tip:hover::after { content: none !important; }
.bt-tip { position: fixed; z-index: 200; max-width: min(320px, 90vw);
  padding: 5px 8px; border-radius: var(--radius);
  background: var(--text); color: var(--bg);
  font-size: var(--text-sm); line-height: 1.35; pointer-events: none; }

/* ── 대시보드 ── */
.bt-dash { flex: 1; padding: 16px 16px calc(16px + var(--bt-sab)); display: flex; flex-direction: column; gap: 12px; }
.bt-dash__stats { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }

/* ★ 좁은 화면에서는 숫자 카드 넷이 한 줄씩 차지해 화면을 다 먹었다. 정작 보러 온
   채팅방 목록이 화면 밖으로 밀린다. 두 칸씩 묶고 카드 안 여백도 줄인다. */
@media (max-width: 600px) {
  .bt-dash__stats { grid-template-columns: 1fr 1fr; gap: 8px; }
  .bt-stat .dk-card__body { padding: 10px 12px; gap: 2px; }
  .bt-stat__value { font-size: var(--text-lg); }
  .bt-stat__hint { display: none; }   /* 좁으면 덧붙이는 설명은 접는다 */
}
.bt-stat .dk-card__body { display: flex; flex-direction: column; gap: 4px; }
.bt-stat__label { font-size: var(--text-sm); color: var(--text-3); }
.bt-stat__value { font-size: var(--text-2xl); font-weight: 700; line-height: 1.1; }
.bt-stat__hint { font-size: var(--text-sm); color: var(--text-3); }
/* 최근 채팅방 — 줄이 카드 테두리에 딱 붙는다(안쪽 여백·틈 없음, 네모 줄, 사이는 옅은 선). 끝 줄 배경은 카드 모서리 안에서 잘린다. */
.bt-dash__recentcard { overflow: hidden; }
.bt-dash__recent { display: flex; flex-direction: column; gap: 0; padding: 0; }
.bt-dash__recent > .dk-listrow { border-radius: 0; padding: 0 14px; }

/* ── 읽음 뱃지 ── */
.bt-read { display: inline-flex; align-items: center; margin-left: 7px; padding: 0;
  border: 0; background: none; font-size: var(--text-sm); color: var(--text-3);
  cursor: pointer; vertical-align: middle; }
.bt-read:hover { color: var(--accent); }
/* 다 읽었으면 '읽음' 한 마디(그림 글자 ✓ 대신 — 2026-09-28). 시각 옆이라 상자를 두르지 않는다. 같은 줄은 한 크기. */
.bt-read--all { color: var(--success); font-size: 13px; line-height: 1; }
.bt-read--all:hover { color: var(--success); }

/* ── 읽은 사람 말풍선 ── */
.bt-readers { position: fixed; z-index: 95; width: 260px; max-height: 300px;
  display: flex; flex-direction: column; background: var(--surface);
  border: 1px solid var(--border); border-radius: var(--radius); }
.bt-readers__head { display: flex; flex-direction: column; gap: 6px; padding: 10px 10px 8px;
  border-bottom: 1px solid var(--border); font-size: var(--text-sm); font-weight: 600; }
.bt-readers__list { flex: 1; overflow-y: auto; padding: 6px; display: flex; flex-direction: column; gap: 2px; }
.bt-reader { display: flex; align-items: center; gap: 8px; padding: 5px 6px; border-radius: var(--radius); }
.bt-reader__nick { flex: 1; min-width: 0; font-size: var(--text-sm);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-reader--un { opacity: .6; }
.bt-reader__state { font-size: var(--text-sm); color: var(--text-3); }
.bt-reader__state--ok { color: var(--success); font-weight: 600; }
.bt-reader__empty { padding: 14px 8px; text-align: center; font-size: var(--text-sm); color: var(--text-3); }
.bt-readers__more { padding: 7px 10px; border-top: 1px solid var(--border);
  font-size: var(--text-sm); color: var(--text-3); }

/* ── 내 정보 줄 · 상태 ── */
.bt-side__me { display: flex; align-items: center; gap: 8px; width: 100%; padding: 10px;
  border: 0; border-top: 1px solid var(--border); background: transparent; color: inherit;
  cursor: pointer; text-align: left; font: inherit; }
.bt-side__me:hover { background: var(--surface-hover); }
.bt-status { display: inline-flex; align-items: center; gap: 5px; font-size: var(--text-sm); color: var(--text-3); }
.bt-status__dot { width: 8px; height: 8px; border-radius: var(--radius-full); background: var(--success); flex: none; }
.bt-status__dot[data-status="away"] { background: var(--warning); }
.bt-status__dot[data-status="busy"] { background: var(--danger); }

/* 내 정보 메뉴 — 사이드바 아래에서 위로
   ★ 줄은 차림표 테두리에 딱 붙는다 — 안쪽 여백·줄 사이 틈 없이 네모 줄, 사이는 옅은 선(2026-09-28 사용자 규칙).
     끝 줄 배경이 둥근 모서리 밖으로 삐져나오지 않게 안에서 자른다. */
/* ★ 자리는 내 줄 바로 위 — 내 줄이 안전 영역만큼 늘어나므로 함께 올린다. 56px 로 박아 두어 아이폰에서 차림표가 내 줄을 34px 덮었다(--bt-row-h). */
.bt-memenu { position: absolute; left: 8px; right: 8px; bottom: calc(var(--bt-row-h) + var(--bt-sab)); z-index: 70;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 0; display: flex; flex-direction: column; gap: 0; overflow: hidden; }
.bt-memenu__head { padding: 8px 12px 6px; font-size: var(--text-sm); color: var(--text-3); font-weight: 600; }
.bt-memenu__item { display: flex; align-items: center; gap: 8px; width: 100%; height: var(--control-h);
  padding: 0 12px; border: 0; border-radius: 0; background: transparent; color: inherit;
  font: inherit; font-size: var(--text-sm); cursor: pointer; text-align: left; }
.bt-memenu__item:hover { background: var(--surface-hover); }
.bt-memenu__item--danger { color: var(--danger); }
.bt-memenu__item .dk-badge { margin-left: auto; }
.bt-memenu__sep { height: 0; border-top: 1px solid var(--border); margin: 0; flex: none; }

/* 접속 중인 회원 목록 — 테두리 상자 안에 줄이 딱 붙는다(안쪽 여백·틈 없음). 짧으면 짧은 만큼만. */
.bt-online__list { max-height: 320px; overflow-y: auto; display: flex; flex-direction: column; gap: 0; }

/* 참여자 패널 막 — 모바일에서만 */
#people-scrim { display: none; }
@media (max-width: 760px) {
  #people-scrim { display: block; position: fixed; inset: 0; background: var(--scrim); z-index: 45;
    opacity: 0; pointer-events: none; transition: opacity .16s ease; }
  #people-scrim[data-open] { opacity: 1; pointer-events: auto; }
}

/* ── 미리보기 카드 ──────────────────────────────────────────────────
   그림이든 영상이든 미리보기를 원본 비율 그대로 보인다(잘라내지 않는다).
   카드 너비는 미리보기가 정하고, 이름 줄은 그 너비 안에서 접힌다.
   ★ 이름 줄에 width:0 + min-width:100% 를 쓰는 까닭 — 이렇게 두어야 긴 파일
     이름이 카드 너비를 밀어내지 못한다(제 몫의 폭을 주장하지 않는다). */
/* ★ 카드 너비는 말풍선이 정하고, 그림은 그 안을 꽉 채운다.
   예전에는 단추가 fit-content 라 그림 너비가 소수점으로 떨어질 때 오른쪽에 1픽셀 띠가
   남아 초록 말풍선이 테두리처럼 비쳤다(실제로 그랬다 — 붙여넣은 그림 오른쪽 줄). */
.bt-thumb { position: relative; display: block; padding: 0; border: 0; background: transparent;
  cursor: pointer; text-align: left; width: 100%; min-width: 0; max-width: 100%; overflow: hidden; }
.bt-thumb .bt-msg__img { display: block; position: absolute; inset: 0; width: 100%; max-width: none; height: 100%; max-height: none;
  object-fit: cover; border: 0; border-radius: 0; }
/* ★ 미리보기 칸은 카드 폭을 꽉 채우고, 높이만 원본 비율(--ar)을 따라 120~320px 사이로 잡는다.
   그림은 칸을 cover 로 채운다 — 작은 그림도 옆에 빈자리가 남지 않고, 너무 길거나 넓은 그림은 잘린다. */
.bt-thumb__frame { overflow: hidden; display: block; position: relative; width: 100%;
  aspect-ratio: var(--ar, 4 / 3); min-height: 120px; max-height: 320px; background: var(--sel, var(--bg)); }

/* 붙여넣기 확인 창의 미리보기 — 여러 장이면 나란히. */
.bt-ask__thumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.bt-ask__thumb { display: flex; flex-direction: column; gap: 4px; max-width: 220px; }
.bt-ask__thumb img { display: block; width: 100%; max-height: 200px; object-fit: contain;
  border-radius: var(--radius); background: var(--bg); }
.bt-ask__thumb span { font-size: var(--text-sm); color: var(--text-3);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-thumb--video .bt-msg__img { background: var(--stage-bg); }
/* 재생 표는 '영상 칸' 한가운데 — 영상 크기에 딱 맞춘 칸이라야 가운데로 온다. */
.bt-thumb__frame { position: relative; display: block; line-height: 0; }
.bt-thumb__play { position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; }
.bt-thumb__play svg { width: 46px; height: 46px; display: block; }
.bt-thumb .bt-cardmeta { box-sizing: border-box; width: 0; min-width: 100%; padding: 8px 10px; }

.bt-msg__audio { display: block; width: min(320px, 100%); height: 34px; }
.bt-bubble:has(> .bt-msg__audio) .bt-cardmeta { margin-top: 8px; }

/* ── 크게 보기 ── */
.bt-lightbox { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center;
  padding: 24px 16px; background: var(--lightbox-scrim); }
/* 그림·영상만 또렷하고 나머지는 살짝 어둡게. 단추는 바로 아래 줄에. */
.bt-lightbox__box { margin: 0; display: flex; flex-direction: column; gap: 8px;
  align-items: center; max-width: 100%; max-height: 100%; }
.bt-lightbox__body { display: grid; place-items: center; min-height: 0; }
.bt-lightbox__media { max-width: min(1600px, 92vw); max-height: 78dvh; border-radius: var(--radius);
  background: var(--stage-bg); display: block; }
.bt-lightbox__bar { display: flex; align-items: center; gap: 6px; padding: 4px 6px 4px 12px;
  border-radius: var(--radius); background: var(--stage-scrim); }
.bt-lightbox__name { font-size: var(--text-sm); color: var(--on-fill); opacity: .85;
  max-width: min(60vw, 460px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-lightbox__act { display: inline-flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; padding: 0; border: 0; border-radius: var(--radius);
  background: transparent; color: var(--on-fill); cursor: pointer; text-decoration: none; }
.bt-lightbox__act:hover { background: var(--stage-hover); color: var(--on-fill); text-decoration: none; }

/* ── 우클릭 메뉴 ── */
.bt-ctx { position: fixed; z-index: 90; width: 180px; padding: 0;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  display: flex; flex-direction: column; gap: 0; overflow: hidden; }
.bt-ctx .bt-memenu__item:disabled { color: var(--dim2); cursor: default; }

/* ── 통화 중 막대(다른 방을 보고 있을 때) ── */
.bt-callbar { position: fixed; left: 50%; transform: translateX(-50%);
  bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 85;
  display: flex; align-items: center; gap: 10px; padding: 8px 12px;
  background: var(--surface); border: 1px solid var(--accent); border-radius: var(--radius);
  font-size: var(--text-sm); max-width: calc(100vw - 24px); }
.bt-callbar__dot { width: 8px; height: 8px; border-radius: var(--radius-full); background: var(--success); flex: none; }
.bt-callbar__text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-callbar__icons { display: inline-flex; gap: 4px; margin-left: 4px; vertical-align: middle; }
.bt-callbar .dk-btn { height: 26px; }
/* 방 목록의 통화 표시 */
.bt-oncall { display: inline-flex; align-items: center; gap: 4px; color: var(--success); font-weight: 600; }

/* ── 채팅방 탭 — 한 칸짜리 세그먼트 ── */
.bt-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 3px;
  border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg); }
.bt-tab { display: inline-flex; align-items: center; justify-content: center; gap: 5px;
  height: 28px; padding: 0 8px; border: 0; border-radius: var(--radius); background: transparent;
  color: var(--text-3); font: inherit; font-size: var(--text-sm); font-weight: 600;
  cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bt-tab:hover { color: var(--text); }
/* 고른 탭 — 안쪽 1px 선(그림자 대신 안으로 들인 윤곽선. 칸 크기는 그대로) */
.bt-tab[data-selected="true"] { background: var(--surface); color: var(--accent);
  outline: 1px solid var(--accent); outline-offset: -1px; }

/* 프로필 그림 아바타 */
.dk-avatar.bt-face { padding: 0; overflow: hidden; }
.dk-avatar.bt-face img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* 장치 시험 */
.bt-meter { height: 10px; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; display: block; }
/* ★ 막대는 폭(width)이 아니라 가로 배율(transform: scaleX)로 움직인다 — 폭을 바꾸면 초당 수십 번 배치를 다시 잡는다.
     값은 meterSet() 으로만 넣는다(같은 값이면 건드리지 않는다). 짧은 이음(50ms)은 합성 단계에서만 돈다. */
.bt-meter__fill { display: block; height: 100%; width: 100%; background: var(--accent);
  transform: scaleX(0); transform-origin: left center; transition: transform .05s linear; }
/* ★ 미리보기 생김새도 실제로 잡히는 그림을 따른다(세로·회전을 골랐으면 세로로 보인다). */
.bt-camprev { width: auto; height: 135px; max-width: 100%; aspect-ratio: var(--cam-ar, 16/9); background: var(--stage-bg);
  border: 1px solid var(--border); border-radius: var(--radius); display: block; object-fit: cover; }

/* ── 통화 화면 ──
   중첩 금지 규칙대로: 통화 영역은 '카드 안의 카드' 없이 한 겹으로 둔다.
   바탕은 --surface 한 겹, 칸끼리는 헤어라인 하나로만 가른다. */
.bt-call { position: relative; display: flex; flex-direction: column; gap: 8px;
  padding: 10px 12px 12px; background: var(--surface); border-bottom: 1px solid var(--border); }
/* 통화 칸과 대화 칸 사이 경계 — 잡고 위아래로 끌면 높이가 바뀐다. */
.bt-call__grip { position: absolute; left: 0; right: 0; bottom: -3px; height: 6px; z-index: 5;
  cursor: row-resize; background: transparent; }
.bt-call__grip:hover, body[data-vresizing] .bt-call__grip { background: var(--accent); }
body[data-vresizing] { cursor: row-resize; user-select: none; }
/* 통화 줄('~에서 통화 중 · 접기 · 통화 끊기')은 절대 줄어들지 않는다. */
.bt-call__top { flex: none; }
.bt-call__top { display: flex; align-items: center; gap: 8px; font-size: var(--text-sm); color: var(--text-3); }
.bt-call__where { display: inline-flex; align-items: center; gap: 6px; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-call__where b { color: var(--text); }
.bt-call__spacer { flex: 1; }

/* 메인 — 테두리 없이 검은 무대만(그림이 곧 경계) */
/* ★ 무대 생김새는 들어온 영상이 정한다. 보내는 사람이 세로(9:16)면 세로로 보여야 한다.
   못 알아냈을 때만 16:9 로 둔다. 높이는 --stage-h 로 눌러 화면 밖으로 넘치지 않게. */
.bt-call__stage { position: relative; width: 100%; max-height: var(--stage-h, calc(var(--bt-vh) * 46));
  aspect-ratio: var(--stage-ar, 16/9);
  background: var(--stage-bg); border-radius: var(--radius); overflow: hidden; }
/* 세로 영상은 폭을 그림에 맞춰 줄여 좌우 검은 띠를 없앤다. */
.bt-call__stage--tall { width: auto; height: var(--stage-h, calc(var(--bt-vh) * 46)); margin: 0 auto; }
.bt-call__stage video { width: 100%; height: 100%; object-fit: contain; display: block; background: var(--stage-bg); }

/* 전체 화면 — 웹뷰의 Fullscreen API 는 막혀 있어(맥 WKWebView·윈도우 WebView2 둘 다)
   우리가 직접 창을 덮는다. 자리를 재서 그림을 얹는 네이티브 층도 이 자리를 그대로 따라온다. */
/* ★ 갈래 이름을 겹쳐 무게를 올린다. 아래 좁은 화면 규칙(.bt-call__stage{max-height:34dvh})이
   뒤에 있어 그냥 두면 전체 화면인데도 화면 위 3분의 1만 덮었다(아이폰 실측 2026-09-22). */
/* 안드로이드 작은 창 — 눌 수 없을 만큼 작으니 칸 위 단추는 감춘다 */
.bt-pip .bt-call__acts { display: none !important; }
.bt-pip .bt-call__stage.bt-call__stage--full { width: var(--bt-pip-w, 100%); height: var(--bt-pip-h, 100%); right: auto; bottom: auto; }
.bt-call__stage.bt-call__stage--full { position: fixed; inset: 0; z-index: 9000; width: 100%; height: 100%;
  max-height: none; aspect-ratio: auto; margin: 0; border-radius: 0; background: var(--stage-bg); }
/* 전체 화면일 때 단추는 위쪽 안전 영역 아래로 — 아이폰은 그냥 두면 다이내믹 아일랜드에 가려
   나가는 단추를 누를 수가 없다. */
.bt-call__stage--full .bt-call__acts { top: calc(8px + env(safe-area-inset-top)); right: calc(8px + env(safe-area-inset-right)); }
.bt-call__stage--full .bt-call__name { bottom: calc(8px + env(safe-area-inset-bottom)); left: calc(10px + env(safe-area-inset-left)); }

/* 진짜 전체 모드 — 화면을 꽉 채운다. 가로 그림을 세로로 들고 있으면 그림을 돌려서 보여 준다
   (웹뷰는 화면 방향을 잠글 수 없다 — 기기를 돌리는 대신 그림을 돌린다). */
/* 꽉 채우기는 잘리더라도 빈 띠 없이 채운다 — 띠 없이 보고 싶어서 누르는 단추다.
   잘리는 것이 싫으면 한 단계 앞(전체 화면)이 그림을 다 보여 준다. */
.bt-call__stage--cover video { object-fit: cover; }
.bt-call__stage--cover.is-rot { width: 100dvh; height: 100dvw; inset: auto;
  left: 50%; top: 50%; transform: translate(-50%, -50%) rotate(90deg); transform-origin: center; }
.bt-call__stage--cover.is-rot .bt-call__acts { top: calc(8px + env(safe-area-inset-left)); }
/* 이름표 — 글자 그림자 대신 반투명 검은 바탕 한 겹(그림자 금지 규칙, 칸 아래 이름표와 같은 꼴) */
.bt-call__name { position: absolute; left: 10px; bottom: 8px; color: var(--on-fill); font-size: var(--text-sm);
  font-weight: 600; padding: 2px 6px; border-radius: var(--radius); background: var(--stage-scrim);
  max-width: calc(100% - 20px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 화면 위 단추들(보내는 화질 · 꽉 채우기 · 전체 화면) — 늘 보이게 둔다. */
.bt-call__acts { position: absolute; right: 8px; top: 8px; z-index: 3; display: flex; gap: 6px; }
.bt-call__act { display: inline-flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; padding: 0; border: 0; border-radius: var(--radius);
  background: var(--stage-scrim); color: var(--on-fill); cursor: pointer; }
.bt-call__act:hover { background: var(--stage-scrim-strong); color: var(--on-fill); }
.bt-call__act:focus-visible { outline: 2px solid var(--on-fill); outline-offset: -2px; }

/* 갤러리 — 썸네일 줄(가로 스크롤) */
.bt-call__strip { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 2px; }
.bt-call--folded .bt-call__strip { flex-wrap: wrap; overflow-x: visible; }
/* ★ 폭은 16:9 로 나누어떨어지는 값으로 — 150px 이면 높이가 84.375px 라
   테두리가 반 픽셀에 걸려 흐릿하게 그려진다(160 → 90 은 딱 떨어진다). */
.bt-tile { position: relative; flex: none; width: var(--tile-w, 160px); height: 90px; padding: 0;
  border: 0; border-radius: var(--radius); overflow: hidden; background: var(--stage-bg); cursor: pointer;
  display: grid; place-items: center;
  outline: 1px solid var(--border); outline-offset: -1px; }
/* ★ 테두리는 안으로 들인 윤곽선(outline-offset 음수)으로 — 그림자 금지 규칙(2026-09-28). 칸 크기가 안 바뀌어
     고른 칸·말하는 칸으로 굵기가 바뀌어도 옆 칸이 흔들리지 않는다. 둥근 모서리도 따라간다. */
/* ★ 칸 높이는 고정, 폭은 그림 생김새를 따른다(세로 영상은 좁고 길게).
   cover 로 잘라 내면 세로 영상이 가운데만 남아 무엇인지 알 수 없다. */
.bt-tile video { width: 100%; height: 100%; object-fit: cover; display: block;
  border-radius: inherit; }
.bt-tile--tall video { object-fit: contain; }
.bt-tile--on { outline: 2px solid var(--accent); outline-offset: -2px; }
/* 영상 칸 — 이름은 아래 띠(.bt-tile__txt), 상태 글은 숨긴다. 목소리 칸은 app-look.css 가 첫 글자 옆 두 줄로 바꾼다. */
.bt-tile__txt { position: absolute; left: 0; right: 0; bottom: 0; display: flex; color: var(--on-fill);
  padding: 2px 6px 3px; background: var(--stage-scrim); text-align: left; min-width: 0; }
.bt-tile__name { min-width: 0; color: var(--on-fill); font-size: var(--text-sm);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-tile__st { display: none; }
/* ★ 왼쪽에 세로 미터(4px + 폭 6px)가 있는 칸은 이름을 그 오른쪽에서 시작한다 — 안 그러면 이름 첫 글자가 미터에 덮인다(2026-09-26). */
.bt-tile:has(> .bt-vmeter) .bt-tile__txt { padding-left: 14px; }

@media (max-width: 760px) {
  .bt-call__stage { max-height: calc(var(--bt-vh) * 34); }
  .bt-tile { width: var(--tile-w, 112px); height: 63px; }   /* 16:9 로 딱 떨어지는 값 */
}

/* 업데이트 알림 — 설정 일반 탭 맨 위의 띠(줄 전체가 단추). 새 판이 있을 때만 보인다. */
.bt-update { display: flex; align-items: center; gap: 8px; width: 100%; height: 40px; padding: 0 14px;
  border: 0; border-radius: var(--radius); background: var(--accent); color: var(--on-accent);
  font: inherit; font-size: var(--text-sm); font-weight: 700; cursor: pointer; text-align: left; }
.bt-update:hover { filter: brightness(1.06); }

/* 내려받기 진행 — 알림 오른쪽 끝의 동그라미.
   호(arc) 길이로 나타낸다. 그러데이션은 쓰지 않는다. */
/* ★ 링 안에 숫자가 들어가야 얼마나 받았는지 읽힌다 — 그래서 32px 로 키웠다.
   링만 돌리면(rotate) 안의 글자까지 누워 버리므로, 도는 것은 차오르는 획만. */
.bt-ring { flex: 0 0 auto; margin-left: auto; width: 32px; height: 32px; }
.bt-ring circle { fill: none; stroke-width: 2.5; transform: rotate(-90deg); transform-origin: 50% 50%; }
.bt-ring__track { stroke: var(--stage-track); }
.bt-ring__bar { stroke: var(--on-accent); stroke-linecap: round;
  stroke-dasharray: 81.68;                   /* 2 x 파이 x 13 */
  stroke-dashoffset: 81.68;                  /* 0% 에서 시작 */
  transition: stroke-dashoffset .15s linear; }
.bt-ring__num { fill: var(--on-accent); font-size: 12px; font-weight: 700;
  text-anchor: middle; dominant-baseline: central; }

/* 통화 칸 왼쪽의 세로 볼륨미터 — 분절 방식(그러데이션 없음).
   칸은 위에서 아래로 놓이고, 소리는 아래에서부터 차오른다. */
.bt-tile { position: relative; }
/*   ★ 이름을 bt-vmeter 로 둔다 — bt-meter 는 마이크 테스트 게이트 미터가 이미 쓴다.
       같은 이름을 쓰면 그쪽 규칙(높이 10px·테두리·display:block)이 겹쳐 묻힌다. */
.bt-vmeter { position: absolute; left: 4px; top: 6px; bottom: 6px; width: 6px;
  display: flex; flex-direction: column; gap: 2px; pointer-events: none; z-index: 2; }
.bt-vmeter > i { flex: 1 1 0; border-radius: 1px; background: var(--stage-cell); }
.bt-vmeter > i.is-on { background: var(--meter-ok); }
.bt-vmeter > i.is-warm.is-on { background: var(--meter-warm); }
.bt-vmeter > i.is-hot.is-on { background: var(--meter-hot); }
.bt-vmeter > i.is-peak { background: var(--stage-peak); }

/* 목소리 손질 */
/* 슬라이더 — 트랙 4px · 손잡이 14px 로 통일 */
/* 볼륨 페이더 — 홈에 잠긴 자리까지 액센트로 차고, 손잡이는 각진 페이더 캡.
   색 경계는 전부 딱 끊어 둔다(번지는 그라데이션 아님). --v 는 자바스크립트가 채운다. */
.bt-range { flex: 1; min-width: 150px; max-width: 300px; height: 26px;
  -webkit-appearance: none; appearance: none; background: transparent; cursor: pointer; }
.bt-range::-webkit-slider-runnable-track { height: 6px; border-radius: 3px;
  background: linear-gradient(to right, var(--accent) 0 var(--v, 0%), var(--border) var(--v, 0%) 100%); }
/* 손잡이 테두리는 그림자 대신 진짜 1px 선(그림자 금지). 크기가 그대로이게 border-box 로 잰다. */
.bt-range::-webkit-slider-thumb { -webkit-appearance: none; box-sizing: border-box; width: 12px; height: 24px; margin-top: -9px;
  border-radius: 3px; background: var(--text);
  border: 1px solid color-mix(in oklch, var(--text) 70%, var(--knob)); }
.bt-range:hover::-webkit-slider-thumb { background: var(--text-2); }
/* 초점 — 페이더 전체에 윤곽선(그림자 고리 대신), 손잡이 선은 강조색으로 */
.bt-range:focus { outline: none; }
.bt-range:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; border-radius: var(--radius); }
.bt-range:focus-visible::-webkit-slider-thumb { border-color: var(--accent); }
.bt-range::-moz-range-track { height: 6px; border-radius: 3px; background: var(--border); }
.bt-range::-moz-range-progress { height: 6px; border-radius: 3px; background: var(--accent); }
.bt-range::-moz-range-thumb { width: 12px; height: 24px; border-radius: 3px;
  background: var(--text); border: 0; }
/* 게이트 — 막대 위에 손잡이를 얹은 페이더. 손잡이를 끌면 작용점이 바뀐다. */
/* ★ 막대 칸은 컨트롤 한 줄 높이(30px)에 막대를 가운데 — 옆 밀대와 같은 폭·같은 세로 가운데(2026-09-28 설정 통일). */
.bt-gate { position: relative; }
.bt-gate__track { position: relative; flex: 0 1 var(--set-slider, 200px); min-width: 120px; padding: 10px 0;
                  cursor: pointer; touch-action: none; }
.bt-gate__track:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: var(--radius); }
.bt-gate .bt-meter { width: 100%; }
.bt-meter__fill--open { background: var(--success); }
.bt-gate__mark { position: absolute; top: 6px; width: 2px; height: 18px;
                 margin-left: -1px; background: var(--danger); pointer-events: none; }
/* 손잡이는 옆 페이더(.bt-range)와 같은 모양이어야 한 화면에서 따로 놀지 않는다. */
.bt-gate__grip { position: absolute; top: 3px; width: 12px; height: 24px; margin-left: -6px;
                 border-radius: 3px; background: var(--text); pointer-events: none;
                 border: 1px solid color-mix(in oklch, var(--text) 70%, var(--knob)); }
.bt-gate__track:hover .bt-gate__grip { background: var(--text-2); }

/* 참여자·통화막대에서 지금 무엇을 켰는지 — 작은 그림(음성·음소거·영상·화면) */
.bt-pstate { display: inline-flex; align-items: center; justify-content: center;
  width: 20px; height: 20px; padding: 0; border-radius: var(--radius);
  background: var(--accent-muted); color: var(--accent); }
.bt-ico--sm { width: 14px; height: 14px; }
/* 입력줄 단추는 둘 다 테두리를 갖는다(보내기만 채운 단추, 파일은 선 단추). */
.bt-input .dk-btn--ghost { border-color: var(--border-strong) !important; }

/* 되묻기 — 줄바꿈 살리고 너무 넓어지지 않게 */
.bt-ask { width: min(420px, 92vw); }
.bt-ask__text { margin: 0; font-size: var(--text-md); line-height: 1.6; white-space: pre-line; }

/* 단추 그림 — 파일도 폰트도 아니고 그려 넣는다(바깥 의존 없음, 색은 글자색을 따라간다) */
.bt-ico { width: 18px; height: 18px; flex: none; display: block; }

/* ── 방 목록 — 고정 묶음·끌어서 차례 바꾸기 ──
   ★ 줄은 네모로 목록 폭을 다 쓴다(고른 줄 배경이 사이드바 양옆에 딱 붙는다). 줄 사이에 선은 긋지 않는다. */
.bt-roomgroup { display: flex; flex-direction: column; gap: 0; }
/* 고정 묶음은 아래와 헤어라인 하나로만 가른다(상자 겹치기 금지). */
.bt-roomgroup--pinned { border-bottom: 1px solid var(--border); }
.bt-roomgroup__head { padding: 6px 12px 4px; font-size: var(--text-sm); color: var(--text-3); }
.bt-room { position: relative; cursor: pointer; }
.bt-room.dk-listrow { border-radius: 0; padding: 0 12px; }
.bt-room.is-dragging { opacity: .45; }
/* 압정 — 평소엔 숨었다가 마우스를 얹거나 고정돼 있으면 보인다. */
.bt-pin { position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  display: none; align-items: center; justify-content: center; width: 24px; height: 24px;
  padding: 0; border: 0; border-radius: var(--radius); background: var(--surface);
  color: var(--text-3); cursor: pointer; }
.bt-pin[data-on="true"] { display: inline-flex; }
.bt-pin:hover { background: var(--surface-hover); color: var(--text); }
.bt-pin[data-on="true"] { color: var(--accent); background: transparent; }
/* 압정이 보일 때는 오른쪽 글(시각·통화 중)을 가리지 않게 자리를 비켜 준다. */
.bt-room:has(.bt-pin[data-on="true"]) .dk-listrow__right { padding-right: 26px; }
/* ★ 얹으면 보이기는 얹을 수 있는 화면(마우스)에서만 건다. 손가락 화면에서 걸면 줄을 톡 누를 때 압정이 '새로 나타난 단추' 가 되어,
     아이폰 웹뷰가 그 톡을 얹기로만 치고 click 을 안 낸다 — 방이 한 번에 안 들어가지고 두 번 눌러야 했다(2026-10-03 시뮬레이터 실측).
     손가락 화면에서 고정은 줄을 꾹 눌러 여는 차림표에 있고, 고정된 줄의 압정은 늘 보여 눌러서 풀 수 있다. */
@media (hover: hover) {
  .bt-room:hover .bt-pin { display: inline-flex; }
  .bt-room:hover .dk-listrow__right { padding-right: 26px; }
}
/* 꾹 눌러 0.5초를 채운 줄(app-touch.js) — 떼면 차림표가 열린다는 표시. 진동이 없는 기기(아이패드)에서도 보이게. */
.bt-held { opacity: .6; }
/* 꾹 누르는 동안의 반응(app-touch.js · JUCE 앱 HoldCue 와 같은 약속): 줄이 어두워지고 고리가 0.41초에 차고, 문턱에서 0.2초 튀고, 꽉 찬 채 뗄 때까지 남는다. */
.bt-holding { filter: brightness(.92); transition: filter 410ms linear; }
#bt-hold-cue { display: none; position: fixed; z-index: 2147483000; width: 88px; height: 88px; margin: -44px 0 0 -44px; pointer-events: none; }
#bt-hold-cue.on, #bt-hold-cue.out { display: block; }
#bt-hold-cue.out { opacity: 0; transition: opacity 110ms linear; }
#bt-hold-cue svg { display: block; width: 100%; height: 100%; overflow: visible; filter: drop-shadow(0 0 2px rgba(0, 0, 0, .55)); }
#bt-hold-cue circle { fill: none; stroke: #fff; transform-origin: center; transform: rotate(-90deg); }
#bt-hold-cue .t { stroke-width: 3; opacity: .3; }
#bt-hold-cue .a { stroke-width: 3.5; stroke-linecap: round; stroke-dasharray: 226.2; stroke-dashoffset: 226.2; }
#bt-hold-cue.on .a { animation: bt-cue-fill 410ms linear forwards; }
#bt-hold-cue.ready .a, #bt-hold-cue.out .a { animation: none; stroke-dashoffset: 0; }
#bt-hold-cue.ready svg { animation: bt-cue-pop 200ms ease-out; }
@keyframes bt-cue-fill { to { stroke-dashoffset: 0; } }
@keyframes bt-cue-pop { 50% { transform: scale(1.22); } }
@media (prefers-reduced-motion: reduce) {
  .bt-holding, #bt-hold-cue.out { transition: none; }
  #bt-hold-cue.on .a, #bt-hold-cue.ready svg { animation: none; }
  #bt-hold-cue.on:not(.ready) svg { display: none; }
  #bt-hold-cue.on.ready .a { stroke-dashoffset: 0; }
  #bt-hold-cue.out { display: none; }
}

/* ── 방 안으로 파일 끌어다 놓기 ── */
#view-room { position: relative; }
.bt-drop { position: absolute; inset: 0; z-index: 40; display: none;
  align-items: center; justify-content: center; text-align: center;
  background: color-mix(in oklch, var(--surface) 88%, transparent);
  border: 2px dashed var(--accent); border-radius: var(--radius); }
.bt-drop[data-on="true"] { display: flex; }
.bt-drop__t { font-size: var(--text-lg); font-weight: 700; color: var(--accent); }
.bt-drop__s { font-size: var(--text-sm); color: var(--text-3); margin-top: 4px; }

/* ── 내 줄(사이드바 맨 아래) — 이름 · 마이크 · 상태 ── */
/* ★ 왼쪽 '나' 칸과 오른쪽 메시지 입력 칸은 높이가 같아야 격자가 맞는다(사용자 지적 2026-09-23).
   입력 칸의 실제 높이 = 글칸 35px(글줄 21 + 안쪽 6·6 + 테두리 2) + 위아래 10px + 테두리 1px = 56px(실측).
   --control-h(30px)보다 글칸이 커서 토큰으로 셈하면 5px 어긋났다. 두 칸 모두 글칸 실제 높이로 셈한다. */
/* ★ 화면 끝에 닿는 줄이면(아이폰 옆칸·아이패드) 둘 다 안전 영역만큼 함께 늘어난다 — 내용은 가운데(align-items:center · 위아래 여백 반씩). */
.bt-input__box { min-height: 35px; }
.bt-side__mebar, .bt-input { min-height: calc(var(--bt-row-h) + var(--bt-sab)); box-sizing: border-box; }
.bt-side__mebar { display: flex; align-items: center; gap: 4px; padding: 6px 8px;
  border-top: 1px solid var(--border); }
.bt-side__mebar .bt-side__me { flex: 1; min-width: 0; width: auto; border-top: 0; padding: 4px 4px; }
.bt-micbtn { display: inline-flex; align-items: center; justify-content: center; flex: none;
  width: 28px; height: 28px; padding: 0; border: 0; border-radius: var(--radius);
  background: transparent; color: var(--text-3); cursor: pointer; }
.bt-micbtn:hover { background: var(--surface-hover); color: var(--text); }
.bt-micbtn[data-off="true"] { color: var(--danger); }
.bt-side__mebar .bt-status { flex: none; border: 0; background: transparent; cursor: pointer;
  padding: 0 4px; font: inherit; font-size: var(--text-sm); color: var(--text-3); }

/* ── 말하는 사람 — 그림 테두리가 밝아진다 ── */
.bt-pstate--sound { border: 0; cursor: pointer; }
/* 말하는 중 — 그림자 대신 안으로 들인 윤곽선(칸 크기는 그대로, 행 밖으로 안 나간다) */
.bt-pstate.is-talking { outline: 2px solid var(--accent); outline-offset: -2px; }
/* 말하는 중 — 고른 칸과 같은 굵기로, 겹쳐도 어긋나 보이지 않게 */
.bt-tile.is-talking { outline: 2px solid var(--accent); outline-offset: -2px; }

/* 참여자 우클릭 차림표(방장 전용) — 줄이 테두리에 딱 붙는다(안쪽 여백·틈 없음, 네모 줄, 사이는 옅은 선) */
.bt-pmenu { position: fixed; z-index: 120; min-width: 190px; padding: 0; overflow: hidden;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.bt-pmenu__head { padding: 8px 12px; font-size: var(--text-sm); color: var(--text-3);
  border-bottom: 1px solid var(--border); margin: 0; }
.bt-pmenu__item { display: block; width: 100%; padding: 8px 12px; border: 0; border-radius: 0;
  background: transparent; color: var(--text); font: inherit; font-size: var(--text-sm);
  text-align: left; cursor: pointer; }
.bt-pmenu__item:hover { background: var(--surface-hover); }
.bt-pmenu__item.is-danger { color: var(--danger); }
.bt-person--can-manage { cursor: context-menu; }

/* 참여자 상태 불 — 온라인·자리 비움·방해 금지 */
.bt-pdot { flex: none; width: 8px; height: 8px; border-radius: var(--radius-full);
  background: var(--success); margin-left: -4px; }
.bt-pdot[data-status="away"] { background: var(--warning); }
.bt-pdot[data-status="busy"] { background: var(--danger); }
.bt-pdot[data-status="offline"] { background: var(--border-strong); }

/* 좁은 화면 로고 줄.

   ★ 예전에는 로고만 담은 줄을 머리줄 위에 따로 두었다. 노치 자리까지 합쳐 100px 가까이를
     로고 하나에 쓰면서, 정작 대화가 보일 자리가 그만큼 줄었다(휴대폰에서는 세로가 가장
     귀한 자리다). 이제 안전 영역만 비켜 주고 줄 자체는 아주 얇게 둔다 — 로고는 머리줄
     안으로 들어간다. */
.bt-topbar { display: none; }
.bt-topbar__logo { display: none; }

/* 머리줄 안에 서는 작은 로고 — 좁은 화면에서만 보인다.
   ★ 여기서 함께 정해야 한다. 미디어 쿼리를 위에 두면 아래의 기본 규칙에 덮인다. */
.bt-head__logo { height: 22px; width: auto; display: none; flex: 0 0 auto; }
@media (max-width: 760px) { .bt-head__logo { display: block; } }

/* 로비·방 머리의 이름 자리는 넉넉히 — 짧게 잘려 보이지 않게.
   ★ 기준 폭을 120px 로 둔다. 제 글 폭(auto)을 기준으로 두면 긴 방 이름 하나에 단추 묶음이 다음 줄로 밀려난다 —
     이름은 남는 자리를 채우고 넘치면 말줄임, 단추 묶음은 120px 도 안 남을 때만 내려간다. */
.bt-room__title { flex: 1 1 120px; }
.bt-room__name { font-size: var(--text-md); }
.bt-room__spacer { flex: 0 0 8px; }

/* 잡음 제거 마법사 */
.bt-wiz { width: min(420px, 92vw); }
.bt-wiz__step { margin: 0 0 4px; font-size: var(--text-sm); color: var(--text-3); }
.bt-wiz__say { margin: 0 0 14px; font-size: var(--text-lg); font-weight: 700; line-height: 1.45; }
.bt-wiz__meterwrap { display: flex; align-items: center; gap: 12px; }
.bt-wiz__meter { flex: 1; }
.bt-wiz__count { min-width: 34px; text-align: right; font-size: var(--text-lg); font-weight: 700; }
.bt-wiz__result { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 4px; font-size: var(--text-sm); }
.bt-wiz__row { display: flex; justify-content: space-between; gap: 12px; }
.bt-wiz__row span:last-child { color: var(--text-3); font-family: var(--font-mono); }

/* 보내는 화질 알림창 */
/* ★ 전체 화면(z-index 9000) 위에 떠야 한다. 95 로 두면 화질 창이 전체 화면 뒤에 깔려
   단추를 눌러도 아무 일이 없는 것처럼 보였다(아이폰 실측 2026-09-22). */
/* ★ 뜨는 창은 화면보다 커지면 안에서 굴러야 한다 — 낮은 창(가로로 누운 휴대폰)에서 아래 줄이 잘렸다(2026-09-28). */
.bt-qualitypop { position: fixed; z-index: 9100; min-width: 232px; padding: 10px 12px;
  max-width: calc(100vw - 16px); max-height: calc(var(--bt-vh) * 100 - 16px); overflow-y: auto;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.bt-qualitypop__head { font-size: var(--text-sm); color: var(--text-3); margin-bottom: 6px; }
.bt-qualitypop__body { font-size: var(--text-sm); }
.bt-qualitypop__pick { display: flex; flex-direction: column; gap: 6px;
  padding-bottom: 8px; margin-bottom: 8px; border-bottom: 1px solid var(--border); }
.bt-qualitypop__row { display: flex; align-items: center; justify-content: space-between; gap: 10px;
  font-size: var(--text-sm); color: var(--text-3); }
.dk-select--sm { height: 28px; padding: 0 6px; font-size: var(--text-sm); }
.bt-qrow { display: flex; justify-content: space-between; gap: 14px; font-family: var(--font-code); }
.bt-qrow + .bt-qrow { margin-top: 4px; padding-top: 4px; border-top: 1px solid var(--border); }
.bt-qnote { margin-top: 6px; padding-top: 6px; border-top: 1px solid var(--border);
  font-size: var(--text-sm); color: var(--text-3); }

/* 목소리만인 통화 — 검은 화면 대신 큰 마이크 그림 */
.bt-call__idle { position: absolute; inset: 0; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 10px; color: var(--stage-ink); }
.bt-call__idleico { display: grid; place-items: center; width: 96px; height: 96px;
  border-radius: var(--radius-full); background: var(--stage-hover); }
.bt-call__idleico .bt-ico { width: 44px; height: 44px; }
.bt-call__idle.is-talking .bt-call__idleico { outline: 3px solid var(--accent); outline-offset: 0; }
.bt-call__idlename { font-size: var(--text-lg); font-weight: 700; }
.bt-call__idlesub { font-size: var(--text-sm); opacity: .7; }

/* 내 목소리 듣기 — 켜져 있으면 눈에 띄게 */
#btn-mic-hear[data-on="true"] { border-color: var(--accent) !important; color: var(--accent) !important; }

/* 입력·출력 채널 목록 — 겉모양은 app-look.css('채널 목록'). 여기는 배치 규칙만.
   채널 목록이 비면(고를 장치가 없거나 아직 못 받음) 이름표 줄째 자리를 없앤다 — 내용이 곧 자리 */
.bt-set__row--chans:has(> .bt-chanlist:empty) { display: none; }
.bt-hevc-install { margin-top: 6px; height: var(--control-h); }

/* 접속 중인 회원 — 줄을 또렷하게, 상태는 오른쪽에 나란히.
   ★ 줄은 딱 붙는다(안쪽 여백·줄 사이 틈 없음, 네모 줄). 줄 사이·바깥에 선은 긋지 않는다. 높이는 내용만큼 — 최대 320px 에서 굴린다. */
.bt-online { display: flex; flex-direction: column; gap: 0; padding: 0; }
.bt-online .bt-reader { padding: 8px 12px; gap: 10px; border-radius: 0; flex: none; }
.bt-online .bt-reader:hover { background: var(--surface-hover); }
.bt-online .dk-avatar { flex: 0 0 auto; }
.bt-online .bt-reader__nick { font-weight: 600; }
/* 상태는 폭을 고정해 여러 줄이 세로로 딱 맞게 선다. */
.bt-online .bt-status { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px;
  min-width: 72px; justify-content: flex-end; font-size: var(--text-sm); color: var(--text-2); }
.bt-online .bt-reader__state { color: var(--text-3); font-weight: 400; }

/* 차단 목록 — 참여자 칸 머리에서 연다. */
.bt-people__head { display: flex; align-items: center; gap: 6px; }
.bt-people__head > span:first-child { flex: 1; min-width: 0; }
/* ★ 차단 목록은 사람이 많아도 화면을 넘지 않는다 — 머리는 그대로, 줄들만 안에서 굴린다(2026-09-28). */
.bt-banlist { min-width: 240px; max-width: calc(100vw - 16px); max-height: min(360px, calc(var(--bt-vh) * 100 - 16px));
  display: flex; flex-direction: column; }
.bt-banlist__body { flex: 1 1 auto; min-height: 0; overflow-y: auto; }
.bt-banlist__row { display: flex; align-items: center; gap: 8px; padding: 6px 12px; }
.bt-banlist__nick { flex: 1; min-width: 0; font-size: var(--text-sm);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-banlist__empty { padding: 10px 12px; font-size: var(--text-sm); color: var(--text-3); }
/* 대화창에서 이름을 우클릭할 수 있다는 표 — 방장에게만 붙는다. */
.bt-msg__meta b.bt-person--can-manage,
.bt-avatar.bt-person--can-manage { cursor: context-menu; }

/* ── 사람별 소리 크기 팝업 — 한 격자: [이름표] [막대] [값] [음소거] ──
   ★ 2026-10-07 사용자 "배치 이상하지 않아?" — 줄마다 따로 격자(단추 칸이 auto)라 '음소거' · '음소거 해제' 폭이 달라지면
     막대 끝 · 값 자리 · 단추 폭이 줄마다 어긋났다. 이제 몸통이 격자이고 줄은 display:contents — 두 줄이 같은 칸을 쓴다.
     · 이름표 칸: 두 줄 중 긴 이름(너무 길면 150px 에서 줄바꿈) · 막대 칸: 남는 폭 전부(두 줄 같은 폭 · 같은 x)
     · 값 칸: 고정 48px, 오른쪽 맞춤(고정폭 글꼴 '+36 dB' 여섯 자) — 끌어도 막대 폭이 안 흔들린다
     · 단추 칸: 두 말을 겹쳐 둔 단추라 늘 긴 말 폭(.bt-gainpop__mute) — 두 줄 · 두 상태 모두 같은 폭
     · 뜻풀이(.bt-gainpop__hint): 그 줄 아래 막대 칸부터 배지(.bt-chips) — 두 줄 같은 꼴
   ★ 폭은 화면을 넘지 않는다. 머리는 그대로, 몸통만 안에서 굴린다. */
.bt-gainpop { position: fixed; z-index: 95; width: max-content; min-width: min(380px, calc(100vw - 16px));
  max-width: min(560px, calc(100vw - 16px)); max-height: calc(var(--bt-vh) * 100 - 16px);
  display: flex; flex-direction: column; padding: 0;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.bt-gainpop__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex: none;
  padding: 6px 8px 6px 12px; border-bottom: 1px solid var(--border); font-size: var(--text-sm); color: var(--text-3); }
.bt-gainpop__head b { min-width: 0; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-gainpop__body { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding: 12px;
  display: grid; grid-template-columns: fit-content(150px) minmax(120px, 1fr) 48px max-content;
  column-gap: 10px; row-gap: 6px; align-items: center; }
.bt-gainpop__row { display: contents; }
.bt-gainpop__body > .bt-gainpop__row:not([hidden]) ~ .bt-gainpop__row > :not(.bt-gainpop__hint) { margin-top: 8px; }
.bt-gainpop__row .bt-range { width: 100%; min-width: 0; max-width: none; }
.bt-gainpop__lbl { font-size: 12px; line-height: 16px; color: var(--text-2); overflow-wrap: anywhere; }
.bt-gainpop__num { font-size: 12px; line-height: 16px; text-align: right; white-space: nowrap; }
/* 단추 — 두 말을 한 칸에 겹친다(안 보이는 말도 폭은 잡는다). 켜짐(음소거 중)은 앱의 눌린 단추와 같은 꼴: 잉크 바탕 · 흰 글자 */
.bt-gainpop__mute { display: inline-grid; justify-items: center; align-items: center; width: 100%; font-size: 12px; }
.bt-gainpop__mute > span { grid-area: 1 / 1; white-space: nowrap; }
.bt-gainpop__mute > .bt-gainpop__on, .bt-gainpop__mute[aria-pressed="true"] > .bt-gainpop__off { visibility: hidden; }
.bt-gainpop__mute[aria-pressed="true"] > .bt-gainpop__on { visibility: visible; }
.bt-gainpop__hint { grid-column: 2 / -1; font-size: 12px; color: var(--text-3); line-height: 16px; }
.bt-gainpop__hint:empty { display: none; }
/* 좁으면 이름표가 제 줄을 다 쓰고 그 아래에 막대 · 값 · 음소거 — 막대가 한 뼘도 안 남던 것 */
@media (max-width: 480px) {
  .bt-gainpop { width: calc(100vw - 16px); min-width: 0; }
  .bt-gainpop__body { grid-template-columns: minmax(0, 1fr) 48px max-content; }
  .bt-gainpop__lbl { grid-column: 1 / -1; }
  .bt-gainpop__hint { grid-column: 1 / -1; }
  .bt-gainpop__body > .bt-gainpop__row:not([hidden]) ~ .bt-gainpop__row > :not(.bt-gainpop__hint):not(.bt-gainpop__lbl) { margin-top: 0; }
}

/* ── 아이폰·아이패드에서 쓸 수 없는 설정은 감춘다 ─────────────────────────
   네이티브가 window.beanSetOS('ios') 로 알려 주면 <html data-os="ios"> 가 된다.
   브라우저 문자열로 가늠하지 않는다 — 아이패드는 자기를 맥이라고 적기도 한다. */
html[data-os="ios"] [data-os-hide~="ios"] { display: none !important; }
/* 안드로이드도 같다(2026-10-30) — 트레이 · 오버레이 · 창 · 스스로 업데이트(플레이 정책: 앱이 스스로 내려받아 갈아 끼우면 안 된다)가 없다. */
html[data-os="android"] [data-os-hide~="ios"] { display: none !important; }

/* ══ 손가락으로 쓰는 화면 ════════════════════════════════════════════════
   애플 휴먼 인터페이스 가이드라인 — iOS·iPadOS 의 조작은 44pt 가 기본, 28pt 가 바닥이다.
   마우스로 쓰는 맥·윈도우는 지금 크기(30px)가 알맞으므로 건드리지 않는다.
   기기 종류가 아니라 '가리키는 방식' 으로 가른다 — 터치 노트북도 있다. */
@media (pointer: coarse) {
  :root {
    --control-h-sm: 36px;
    --control-h: 44px;
    --control-h-lg: 50px;
  }
  .dk-iconbtn { min-width: 44px; min-height: 44px; }
  .dk-check__box { width: 22px; height: 22px; }
  .bt-tab { min-height: 44px; }
  /* 목록 줄도 손가락이 닿을 만큼 */
  .bt-roomitem, .bt-memenu__item { min-height: 44px; }
  /* 참여자 줄의 마이크 그림(누르면 소리 크기 창) — 그림은 15px 그대로, 누르는 자리만 보이지 않는 테두리로 45px */
  /* 단추 자체를 44px 로(안쪽 여백 14.5 · 같은 만큼 바깥 여백을 빼 줄 배치는 그대로). 오른쪽으로 나간 몫은 줄의 오른쪽 여백(15px) 안이다 */
  #people-list .bt-pstate--sound { padding: 14.5px; }
  #people-list .bt-person__state:has(.bt-pstate--sound) { margin: -14.5px -14.5px -14.5px -10.5px; }
  #people-list .bt-person { padding-right: 15px; }
  /* 꾹 눌러 여는 차림표(참여자 관리 · 내 글)의 줄도 */
  .bt-pmenu__item { display: flex; align-items: center; min-height: 44px; }
  /* 손가락 화면에는 '얹기' 가 없다 — 꾹 눌러 연 차림표가 손가락 밑에 뜨면 그 줄이 얹힌 빛으로 남아 고른 것처럼 보였다.
     차림표 줄은 누르는 동안에만 빛을 준다. */
  .bt-memenu__item:hover, .bt-pmenu__item:hover { background: transparent; }
  .bt-memenu__item:active, .bt-pmenu__item:active { background: var(--surface-hover); }
  /* 꾹 눌러 차림표를 여는 줄(app-touch.js) — 그 줄에서만 글자 고르기 · 미리보기 풍선이 먼저 뜨지 않게.
     방 목록 줄 · 차림표가 달린 내 글 · 방장이 관리할 수 있는 이름과 참여자 줄. 마우스 화면은 그대로 둔다(글자를 끌어 고른다). */
  .bt-room, .bt-msg--menu, .bt-person--can-manage {
    -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; }
  /* ★ 내 줄과 글 쓰는 줄은 높이가 같아야 격자가 맞는다('내 줄' 묶음 · --bt-row-h) — 손가락 화면은 단추가 44px 이라
       글 쓰는 줄이 65px(윗선 1 + 10 + 44 + 10)이 된다. 내 줄도 같이 키운다(아이패드에서 9px 어긋나 보였다). */
  :root { --bt-row-h: 65px; }
}

/* ══ 좁은 화면의 뜨는 창 ═════════════════════════════════════════════════
   가운데 떠 있는 작은 창은 손가락으로 가장자리를 잡기 어렵다.
   아래에서 올라오는 시트로 바꾸고, 아래 안전 영역을 비운다. */
@media (max-width: 600px) {
  .dk-scrim { place-items: end center; }
  /* ★ 빈톡 창 바탕(.bt-overlay)도 아래에 붙인다. 좁으면 창이 아래 테두리 없는 시트 꼴로 바뀌는데
       바탕이 가운데 정렬이라 시트가 화면 중간에 떠서 아래가 잘린 것처럼 보였다(2026-09-25). */
  .bt-overlay { place-items: end center; padding: 0; }
  .bt-overlay > .dk-dialog { max-height: calc(var(--bt-vh) * 92); max-width: 100%; }
  .dk-dialog {
    width: 100%;
    max-height: calc(var(--bt-vh) * 92);
    border-radius: var(--radius) var(--radius) 0 0;
    border-bottom: none;
    padding-bottom: env(safe-area-inset-bottom);
  }
  /* ★ 시트 맨 아래 단추 줄도 맨 아래 막대다(2026-09-30 규칙) — 줄이 화면 끝까지 늘어나고 단추는 그 가운데.
       창에 여백으로 주면 단추 밑에 빈 띠(34px)가 남았다. 단추 줄이 끝에 있는 창은 그 여백을 단추 줄 위아래에 반씩 나눈다.
       셈: 아이폰(34) 단추 위아래 29px · 홈 막대 없는 기종(0) 12px 그대로. */
  .dk-dialog:has(> .dk-dialog__foot:last-child) { padding-bottom: 0; }
  .dk-dialog > .dk-dialog__foot:last-child { padding-top: calc(12px + env(safe-area-inset-bottom) / 2);
    padding-bottom: calc(12px + env(safe-area-inset-bottom) / 2); }
  .dk-dialog__body { overflow-y: auto; }
  /* 단추 줄은 가로로 꽉 — 좁은 데서 오른쪽 끝에 몰아 두면 누르기 어렵다 */
  .dk-dialog__foot { justify-content: stretch; }
  .dk-dialog__foot .dk-btn { flex: 1; }
}

/* ══ 아이패드 세로처럼 중간 폭 ══════════════════════════════════════════
   옆칸을 늘 띄워 두기엔 좁고, 감추기엔 넓다. 옆칸을 좁혀 함께 보여 준다. */
@media (min-width: 761px) and (max-width: 1023px) {
  .bt-side { width: 232px; }
  .bt-people { width: 200px; }
}

/* ── 2026-09-22 재설계 1차 (Fluxer 배치) ──────────────────────────────── */
/* 그림자 금지(빈 디자인 원칙) — DeskKit 의 떠 있는 상자는 테두리만으로 가른다. */
/* (그림자 — 2026-10-07 샘플부터 떠 있는 것(차림표 · 창 · 알림)에만 쓴다. 값은 colors.css --shadow-menu · --shadow-dialog · --shadow-toast) */

/* 사이드바 통화 패널 — 통화 중이면 어느 방을 보든 여기 늘 보인다. */
/* ★ 통화 패널은 바로 아래 내 줄(.bt-side__mebar)과 같은 치수다 — 여백 6px 8px · 속 36px · 합 48px.
   방 이름과 통화 길을 한 줄에(두 줄로 쌓아 높이가 달랐다 — 2026-09-22 사용자 지적), 글자는 최소 14px. */
.bt-voice { border-top: 1px solid var(--border); padding: 6px 8px; min-height: 48px; box-sizing: border-box;
  display: flex; align-items: center; background: var(--surface-2, var(--surface)); }
.bt-voice__head { display: flex; align-items: center; gap: 8px; min-width: 0; flex: 1; height: 36px; padding: 0 4px; }
.bt-voice__dot { width: 8px; height: 8px; border-radius: var(--radius-full); background: var(--success); flex: none; }
.bt-voice__title { display: flex; flex-direction: row; align-items: baseline; gap: 6px; min-width: 0; flex: 1; line-height: 1.25; }
.bt-voice__title b { font-size: var(--text-sm); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-voice__state { font-size: var(--text-sm); color: var(--text-3); white-space: nowrap; }
.bt-voice__state::before { content: "· "; }
.bt-voice #voice-goto { height: 28px; flex: none; }
/* 넓은 화면에서는 사이드바 패널이 알리므로 떠다니는 통화 막대는 감춘다. */
@media (min-width: 761px) { .bt-callbar { display: none !important; } }
/* 좁은 화면에서는 사이드바가 겹판이라 패널을 사이드바 안에 둔 채로 두고 막대가 알린다. */

/* 좁은 화면 아래 탭 막대 */
.bt-tabbar { display: none; }
@media (max-width: 760px) {
  /* 탭 막대 치수 — 윗선 1px + 설계 높이 44px + 아래 안전 영역. 막대 위에 뜨는 것(통화 중 막대·알림)이 이 값으로 비켜 선다. */
  :root { --bt-tabbar-h: calc(45px + env(safe-area-inset-bottom)); --bt-callbar-h: 44px; }
  /* ★ 아래 안전 영역은 탭 막대 혼자 가진다. 바깥 .bt-screen 도 같은 값을 물고 있어
     둘이 겹쳐 막대 밑에 빈 띠가 남았다(아이폰 실측 2026-09-22). 본 화면은 이제 넓은 화면에서도 바깥 여백이 0 이다(맨 위 #screen-main).
     ★ 탭 막대 위 본문(글 쓰는 줄·설정 아래 줄·대시보드)도 안전 영역을 비키지 않는다 — 둘이 겹쳐
     입력줄과 막대 사이에 빈 띠가 생겼다(아이폰 실측 2026-09-23). --bt-sab 를 0 으로 되돌린다. */
  .bt-body > section { --bt-sab: 0px; }
  .bt-tabbar { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; order: 99;
    border-top: 1px solid var(--border); background: var(--surface); padding-bottom: 0; flex: none; }
  /* ★ 맨 아래 막대는 화면 아래 끝까지, 그림은 늘어난 막대 전체 높이의 가운데(2026-09-30 사용자 규칙 — 모든 앱:
       "어플들 저런식으로 최하단에 여백 생기던데 여백 안 생기게 못하나").
       · 막대 높이 = 설계 높이 44px + 아래 안전 영역. 바탕·윗선·누르는 자리·누른 표시가 모두 화면 끝까지 간다.
         막대에 여백으로 주면 단추 밑에 아무것도 없는 흰 띠가 남았다(아이폰 실측 2026-09-22) — 단추가 그 자리까지 내려온다.
       · 예전에는 단추에 안전 영역만큼 padding-bottom 을 주어 그림을 위쪽 44px 에 올려 두었다(홈 막대 띠를 피하려고).
         그러면 그림 밑으로 34px 가 비어 '최하단 여백' 으로 보였다. 이제 여백 없이 전체 높이의 가운데에 둔다.
       · 셈(그림 22px): 아이폰(안전 영역 34) 단추 78px → 그림 위아래 28px, 화면 끝에서 28px(홈 막대보다 위).
         안전 영역 0(홈 버튼 기종·웹) 단추 44px → 위아래 11px. 어느 쪽이든 화면 끝에서 8px 이상 떨어진다. */
  .bt-tabbar__btn { display: inline-flex; align-items: center; justify-content: center;
    height: calc(44px + env(safe-area-inset-bottom)); padding: 0;
    border: 0; background: transparent; color: var(--text-2); cursor: pointer; border-radius: 0; }
  .bt-tabbar__btn .bt-ico { width: 22px; height: 22px; }
  .bt-tabbar__btn:active { background: var(--accent-muted); color: var(--accent); }
  /* 탭 막대가 아래에 서므로 본문 아래 여백은 두지 않는다(막대 자체가 자리를 차지한다). */
  .bt-body { flex-direction: column; }
  .bt-body > section { flex: 1; min-height: 0; }
  /* 방 머리의 그림 단추 4개는 패널·탭 막대가 대신하므로 사람·통화 단추만 남긴다. */

  /* ── 탭 막대 위에 뜨는 것 ──
     ★ '통화 중' 막대와 알림은 화면 끝에서 16px + 안전 영역에 서 있어 탭 막대(가운데 참여자 단추)를 덮었다.
       탭 막대 위 12px 에 세운다. 알림은 본 화면(탭 막대가 있는 화면)에서만 올린다 — 로그인 화면에는 탭 막대가 없다. */
  .bt-callbar { bottom: calc(var(--bt-tabbar-h) + 12px); height: var(--bt-callbar-h);
    /* 옆칸·참여자 판·창(시트)이 뜨면 그 아래로 들어간다 — 막대가 시트 단추를 덮었다(바탕 막 45 보다 낮게). */
    z-index: 40; }
  /* 11-14 빠르기: ':has(#… :not([hidden]))' 대신 data 표시(app-core.js 숨김 거울) — 웹킷은 그런 :has 가 있으면 hidden 을 바꿀 때마다 문서를 다시 따졌다. :not(#bt-none) 은 예전 규칙과 세기를 맞추는 것(뜻 없음). */
  body[data-bt-sm]:not(#bt-none) .bt-toasts { bottom: calc(var(--bt-tabbar-h) + 12px); }
  body[data-bt-sm][data-bt-cb]:not(#bt-none):not(#bt-none2) .bt-toasts {
    bottom: calc(var(--bt-tabbar-h) + 12px + var(--bt-callbar-h) + 8px); }
  /* 통화 중 막대가 떠 있으면 그 자리만큼 본문 아래를 비운다(위아래 12px 씩) — 막대가 글 쓰는 줄·설정 '사용법' 줄을
     덮지 않게(내용이 곧 자리). 예전에는 설정 아래 줄에만 여백을 더했다. */
  body[data-bt-cb]:not(#bt-none) .bt-body > section { padding-bottom: calc(var(--bt-callbar-h) + 24px); }
}
/* 설정의 상태 글 — 문제가 있을 때만 경고색 */
.bt-warn { color: var(--danger); }

/* ── 회원가입 — 칸은 서버의 회원 설정에서 받아 그린다(app-signup.js) ── */
.bt-su-body { display: flex; flex-direction: column; gap: var(--sp-2); }
.bt-su-phone { display: flex; gap: var(--sp-2); align-items: center; }
.bt-su-phone[hidden] { display: none; }
.bt-su-phone .dk-select { flex: none; width: auto; }
.bt-su-phone .dk-btn { flex: none; }
.bt-su-grow { flex: 1 1 auto; min-width: 0; }
#su-fields { display: flex; flex-direction: column; gap: var(--sp-3); margin-top: var(--sp-3); }   /* 서버 줄과 첫 칸 사이도 칸 사이와 같게 */
#su-agree { display: flex; flex-direction: column; gap: var(--sp-3); margin-top: var(--sp-3); }
#su-agree[hidden] { display: none; }
#su-sms-state[hidden] { display: none; }
.bt-su-agree { display: flex; flex-direction: column; gap: var(--sp-2); }
/* 약관 본문 — 길어도 가입 창이 끝없이 늘지 않게 칸 안에서 굴린다. */
.bt-su-terms {
  max-height: 120px; overflow-y: auto; white-space: pre-wrap;
  font-size: var(--text-sm); color: var(--text-3);
  border: var(--border-w) solid var(--border); border-radius: var(--radius);
  padding: var(--sp-2) var(--sp-3);
}
.bt-su-ok { color: var(--success); }
/* 좁은 화면 — 나라·번호·단추가 한 줄에 안 들어가면 단추를 아래로 내린다. */
@media (max-width: 420px) {
  .bt-su-phone { flex-wrap: wrap; }
  .bt-su-phone .dk-btn { flex: 1 1 100%; }
}

/* ── 고르는 칸(app-listbox.js) — 앱의 모든 드롭다운이 한 모양 ──────────────────────────────
   ★ 운영체제 차림표 대신 우리 목록을 띄운다 — 언어 16개·장치·채널 64개도 열 줄까지만 보이고 나머지는
     목록 안에서 굴러간다(2026-09-28 사용자 규칙). 맥·윈도우·아이폰이 모두 같은 모양이다.
   ★ 단추는 select 가 달던 차림새(dk-select: 테두리·높이·꺾쇠 · bt-set__value: 폭)를 그대로 물려받는다.
     글자는 어디서나 한 크기(--text-sm). 긴 이름은 말줄임 + 말풍선(title). */
.bt-lb { position: relative; display: inline-flex; align-items: center; min-width: 0;
  padding: 0 28px 0 10px; background: transparent; color: var(--text);
  font: inherit; text-align: left; cursor: pointer; }
.bt-lb.bt-lb { font-size: var(--text-sm); }
.bt-lb.dk-select--sm { padding: 0 26px 0 8px; }
.bt-lb__text { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-lb:disabled { color: var(--dim2); cursor: default; }
/* 초점 — 마우스로 눌렀을 때는 조용히, 키보드로 왔을 때만 윤곽선. 열려 있는 동안은 강조색 테두리. */
.bt-lb:focus { outline: none; }
.bt-lb.dk-select:focus-within { border-color: var(--border); outline: none; }
.bt-lb.dk-select[aria-expanded="true"] { border-color: var(--accent); }
.bt-lb.dk-select:focus-visible { border-color: var(--accent); outline: 3px solid var(--focus-ring); outline-offset: 0; }
/* 로그인 서버 고르기 — 테두리는 감싼 칸(dk-inputwrap)이 맡는다. 꺾쇠만 직접 그린다. */
.bt-lb--bare { width: 100%; height: 100%; border: 0; padding: 0 18px 0 0; }
.bt-lb--bare::after { content: ""; position: absolute; right: 2px; width: 7px; height: 7px; pointer-events: none;
  border-right: 1.5px solid var(--text-3); border-bottom: 1.5px solid var(--text-3); transform: rotate(45deg) translateY(-2px); }
/* 목록 — 줄은 테두리에 딱 붙는다(안쪽 여백·줄 사이 틈 없음). 높이는 JS 가 '줄 높이 × 최대 열 줄' 로 자른다. */
.bt-lb__pop { position: fixed; z-index: 9500; overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain;
  padding: 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.bt-lb__opt { display: flex; align-items: center; height: var(--control-h); padding: 0 12px;
  font-size: var(--text-sm); color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  cursor: pointer; user-select: none; -webkit-user-select: none; }
.bt-lb__opt.is-active { background: var(--surface-hover); }
.bt-lb__opt[aria-selected="true"] { color: var(--accent); font-weight: 600; }
.bt-lb__opt[aria-disabled] { color: var(--dim2); cursor: default; }
.bt-lb__pop::-webkit-scrollbar { width: 10px; }
.bt-lb__pop::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: var(--radius); border: 2px solid transparent; background-clip: content-box; }
.bt-lb__pop::-webkit-scrollbar-track { background: transparent; }

/* ══ 모바일 전수 점검(2026-10-03) ═══════════════════════════════════════════
   아이폰 · 아이패드 화면을 320pt 폭까지 훑어 고친 것들. 까닭은 줄마다 적는다. */

/* 뜨는 창 바탕은 격자다 — 칸 폭을 내용에 맡기면(auto) 긴 이름 한 줄이 창을 화면보다 넓게 민다
   ('접속 중인 회원' 창이 320pt 화면에서 370px — 오른쪽 상태 글과 닫기 단추가 잘렸다). 칸을 화면 폭에 묶는다. */
.bt-overlay { grid-template-columns: minmax(0, 1fr); }
.bt-overlay > .dk-dialog { min-width: 0; }
.bt-online .bt-reader { min-width: 0; }
.bt-online .bt-reader__nick { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* 목록 줄의 오른쪽 묶음(통화 표시 · 안 읽은 수 · 시각)은 줄어들지 않는다 — 줄어들면 '통화' 표시가 두 줄로 꺾여 세로로 섰다.
   긴 방 이름 쪽이 말줄임으로 자리를 내준다. */
.dk-listrow__right { flex: none; }
.dk-listrow__title { min-width: 0; }
.dk-listrow .dk-badge { white-space: nowrap; flex: none; }

/* 글 머리줄(이름 · 시각 · 읽음) — 이름이 길어도 시각은 한 덩어리로 넘어간다('3:03' / 'AM' 으로 쪼개지던 것). */
.bt-msg__time, .bt-read { white-space: nowrap; }
.bt-msg__meta b { overflow-wrap: anywhere; }

/* 빈 방 — 글이 하나도 없을 때의 한 줄 */
.bt-msgs__empty { margin: auto; padding: 24px 16px; text-align: center; font-size: var(--text-sm); color: var(--text-3); }
/* 빈 자리 안내 글은 낱말 단위로 꺾고 줄 길이를 고르게 — 마지막 줄에 '요.' 한 글자만 남던 것 */
.bt-msgs__empty, .bt-reader__empty, .dk-empty__desc { word-break: keep-all; text-wrap: balance; }
/* 빈 목록의 다음 걸음 단추 */
.bt-empty__act { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 12px; }

/* 옆 서랍의 통화 줄 — 방 이름이 먼저다. 연결 길 글('· 통화 서버')이 자리를 다 먹어 방 이름이 '내가 …' 두 글자로 줄던 것(영어 · 좁은 서랍).
   방 이름은 제 폭을 지키고(너무 길면 그것만 말줄임) 연결 길 글이 먼저 줄어든다. */
.bt-voice__title b { flex: 0 0 auto; max-width: 100%; }
.bt-voice__state { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }

@media (max-width: 600px) {
  /* 통화 칸 위 줄('○○ 방에서 통화 중') — 좁으면 두 줄까지 흘린다(320pt 에서 '통화 중' 끝이 잘렸다). */
  .bt-call__where { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; white-space: normal; word-break: keep-all; }
  /* 머리줄 아래 글(안 읽은 메시지 수 · 접속 수)은 좁으면 두 줄까지 흘린다 — 한 줄에 가둬 '안 읽은 메시지가 …' 로 잘렸다. */
  .bt-room__sub { white-space: normal; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden;
    word-break: keep-all; }   /* 낱말 가운데서 꺾지 않는다('참' / '여 18명') */
}
@media (max-width: 420px) {
  /* 로그인의 서버 주소 — 고르는 칸과 단추 둘을 한 줄에 두면 320pt 에서 주소가 'http://…' 로만 보였다.
     고르는 칸이 한 줄을 다 쓰고 단추는 그 아래 줄에 나란히. (서버 추가 줄은 입력 + 저장 그대로 한 줄) */
  .bt-srv:not(.bt-srv--add) { flex-wrap: wrap; }
  .bt-srv:not(.bt-srv--add) .bt-srv__pick { flex: 1 1 100%; }
  .bt-srv:not(.bt-srv--add) .dk-btn { flex: 1 1 0; }
}

@media (pointer: coarse) {
  /* ★ 글 쓰는 칸은 16px — 아이폰 웹뷰는 16px 보다 작은 칸에 초점이 가면 화면을 확대한다. 가입 창이 확대돼 좌우가 잘리고
       (제목 '회원가입' 의 앞 글자 · '인증 번호 받기' 단추), 글자판을 내려도 확대된 채 남았다(2026-10-03 시뮬레이터).
       예전 규칙은 로그인 칸에만 걸려 있었다 — 가입 · 방 만들기 · 비밀번호 · 검색 · 대화 글칸(textarea)은 빠져 있었다. */
  input:not([type="range"]):not([type="checkbox"]):not([type="radio"]), textarea, select,
  .bt-input__box > textarea { font-size: 16px; }
  /* 누르는 자리는 44px 이상(모든 앱 규칙) — 작은 단추(닫기 · 차단 목록 · 차단 해제 · 통화 줄의 축소 · 종료)도 손가락 화면에서는 44. */
  :root { --control-h-sm: 44px; }
  /* 목록 줄 — 방 목록 40 · 대시보드 최근 방 38 이던 것 */
  .dk-listrow { height: auto; min-height: 44px; }
  /* 내 줄 — 이름 칸 36 · 마이크 단추 28 · 상태 21 이던 것. 줄 높이(--bt-row-h 65px) 안에서 키운다. */
  .bt-side__mebar .bt-side__me { min-height: 44px; }
  .bt-micbtn { width: 44px; height: 44px; }
  .bt-side__mebar .bt-status { min-height: 44px; padding: 0 6px; }
  /* 포인트 컬러 점 — 보이는 네모는 26 그대로, 누르는 자리만 44(보이지 않는 테두리 9px 씩). 점 사이를 18 로 벌려 누르는 자리가 안 겹친다. */
  .bt-accents { gap: 18px; max-width: none; padding: 9px 0; }
  .bt-accent-dot { position: relative; }
  .bt-accent-dot::after { content: ''; position: absolute; inset: -9px; }
  /* 통화 칸의 작은 단추(꽉 채움 · 전체 화면 32) — 누르는 자리 44 */
  .bt-call__acts { gap: 12px; }
  .bt-call__act { position: relative; }
  .bt-call__act::after { content: ''; position: absolute; inset: -6px; }
  /* 다른 화면을 볼 때의 '통화 중' 막대 — 복귀 · 종료 단추가 26 이었다. 막대를 60 으로 키우고 단추는 44, 글은 두 줄까지. */
  :root { --bt-callbar-h: 60px; }
  .bt-callbar .dk-btn { height: 44px; }
  .bt-callbar { width: calc(100vw - 24px); }   /* 글이 두 줄로 흐르면 내용 폭에 맞추는 막대가 글 칸을 한 낱말 폭으로 줄인다 — 화면 폭을 쓴다 */
  .bt-callbar__text { flex: 1 1 auto; white-space: normal; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; word-break: keep-all; }
  /* 옆 서랍의 통화 줄 '방으로' 단추(28) */
  .bt-voice #voice-goto { height: 44px; }
  /* 설정 갈래 탭 — 'UI' 처럼 짧은 이름도 44 폭 */
  .dk-tabs__tab { min-width: 44px; }
  /* 값 막대는 탭으로 고른 뒤 다시 누르고 끌어야 바뀐다(app-touch.js touchSlider) — 고르지 않은 막대는 손가락을 받지 않아,
     그 위에서 시작한 끌기가 화면 굴리기가 된다(굴리다 스쳐 값이 바뀌던 것). 고른 막대에는 테두리. */
  input[type="range"]:not(.bt-armed), .bt-gate__track:not(.bt-armed) { pointer-events: none; }
  input[type="range"].bt-armed, .bt-gate__track.bt-armed { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: var(--radius); }
}

/* ══ 글자판이 올라오면 화면이 줄어든다(아이폰 · 아이패드 — app-touch.js keyboardFit) ══════════════
   웹뷰는 글자판이 떠도 화면 크기를 그대로 두고 쪽 전체를 위로 민다. 그래서 대화에서는 방 머리줄이 사라지고 글이 상태 막대(시계) 밑으로
   들어갔고, 아래에서 올라오는 창(가입)은 제목 줄이 화면 위로 잘렸다(2026-10-03 시뮬레이터). 글자판이 떠 있는 동안(html.bt-kb):
   · 화면과 창은 글자판 위에 보이는 높이(--bt-vh) 안에 선다.
   · body 를 그 높이의 틀로 삼는다 — transform 을 주면 떠 있는 것(창 · 옆 서랍 · 알림 · 통화 막대)이 화면이 아니라 body 를 기준으로 선다.
   · 글자판이 홈 막대 자리를 덮으니 아래 안전 영역과 탭 막대는 거둔다(글 쓰는 줄이 글자판에 바로 붙는다). */
html.bt-kb { --bt-sab: 0px; --bt-tabbar-h: 0px; }
html.bt-kb body { height: calc(var(--bt-vh) * 100); transform: translateZ(0); }
html.bt-kb .bt-tabbar { display: none; }
html.bt-kb-soft { --bt-sab: 0px; --bt-tabbar-h: 0px; }
html.bt-kb-soft .bt-tabbar { display: none; }
html.bt-kb-soft .bt-screen { padding-bottom: 0; }
html.bt-kb .bt-screen { padding-bottom: 0; }
html.bt-kb .dk-dialog { padding-bottom: 0; }
html.bt-kb .dk-dialog > .dk-dialog__foot:last-child { padding-top: 12px; padding-bottom: 12px; }
/* 로그인 화면은 제 안에서 굴린다 — 위 안전 영역을 여백(padding)으로 두면 굴릴 때 글이 상태 막대 밑으로 들어간다. 테두리로 둔다(테두리 밖으로는 안 구른다). */
#screen-login { padding-top: 0; border-top: env(safe-area-inset-top) solid transparent; }
