/* ─────────────────────────────────────────────────────────────
   꿈끼발표회 진행 콘솔 — 학급포털과 같은 디자인 언어
   종이색 바탕 · 흰 카드 · 얇은 연회색 선 · 짙은 초록 하나
   ───────────────────────────────────────────────────────────── */
:root {
  color-scheme: light;
  --paper: #f6f7f5;
  --white: #fff;
  --ink: #172522;
  --muted: #596762;
  --faint: #8a9690;
  --line: #e0e6e1;
  --field-line: #ccd6d0;
  --hover-line: #91b5a6;
  --brand: #206756;
  --brand-hover: #174f42;
  --dark: #143f38;
  --soft: #e9f3ee;
  --accent-line: #cce1d6;
  --red: #b4372b;
  --red-soft: #f9edeb;
  --red-line: #e8bfbb;
  --amber: #8a5a12;
  --amber-soft: #fbf4e4;
  --amber-line: #eedcb3;
  --radius: 17px;
  --r-md: 13px;
  --r-sm: 9px;
  /* 예전 이름 (스크립트에서 쓰는 곳 대비) */
  --text: var(--ink);
  --accent: var(--brand);
  --live: var(--red);
  --ok: var(--brand);
  --warn: var(--amber);
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--paper); color: var(--ink); font: 14.5px/1.55 "Pretendard Variable", "Pretendard", "Noto Sans KR", "Malgun Gothic", "Apple SD Gothic Neo", system-ui, sans-serif; overflow: hidden; -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; }
button { color: inherit; cursor: pointer; }
button:disabled { cursor: default; opacity: .5; }
button:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; }
a { color: var(--brand); text-decoration: none; }
kbd { background: var(--white); border: 1px solid var(--field-line); border-bottom-width: 2px; border-radius: 6px; padding: 0 6px; font-size: 11px; font-family: inherit; color: var(--muted); font-weight: 700; }
.mini { font-size: 12px; color: var(--muted); font-weight: 500; }
.spacer { flex: 1; }
[hidden] { display: none !important; }
* { scrollbar-width: thin; scrollbar-color: #cfd8d3 transparent; }

/* ───────── 상단 바 ───────── */
.top { height: 64px; display: flex; align-items: center; gap: 8px; padding: 0 20px; background: var(--white); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 17px; letter-spacing: -.04em; white-space: nowrap; margin-right: 10px; }
.brand span:not(.brandMark) { color: var(--muted); font-weight: 650; }
.pill { display: inline-flex; align-items: center; height: 28px; padding: 0 11px; border-radius: 100px; font-size: 12.5px; font-weight: 750; white-space: nowrap; background: var(--paper); color: var(--muted); border: 1px solid var(--line); }
.pill.ok { background: var(--soft); color: var(--brand); border-color: var(--accent-line); }
.pill.warn { background: var(--amber-soft); color: var(--amber); border-color: var(--amber-line); }
.pill.bad { background: var(--red-soft); color: var(--red); border-color: var(--red-line); }
.tbtn { display: inline-flex; align-items: center; gap: 5px; min-height: 38px; padding: 6px 12px; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--white); color: var(--ink); font-weight: 700; font-size: 13.5px; white-space: nowrap; }
.tbtn:hover { background: var(--soft); border-color: var(--hover-line); }
.tbtn.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.tbtn.primary:hover { background: var(--brand-hover); }
.tbtn .mini { margin-left: 2px; }
.clock { font-variant-numeric: tabular-nums; font-size: 18px; font-weight: 800; letter-spacing: -.02em; padding: 0 8px; }

/* ───────── 레이아웃 ───────── */
.grid { height: calc(100vh - 64px); display: grid; grid-template-columns: 250px minmax(0, 1fr) 300px; gap: 16px; padding: 16px 20px; }
.panel { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
.panelHead { display: flex; gap: 6px; align-items: baseline; padding: 16px 18px 8px; font-weight: 800; font-size: 15px; letter-spacing: -.03em; }

/* ───────── 진행 순서 (학급포털 메뉴와 같은 모양) ───────── */
.list { display: flex; flex-direction: column; min-height: 0; }
.runList { overflow-y: auto; padding: 0 10px 12px; flex: 1; }
.runItem { display: grid; grid-template-columns: 26px minmax(0, 1fr) auto; gap: 8px; align-items: center; min-height: 48px; padding: 7px 10px; border-radius: 10px; cursor: pointer; border: 1px solid transparent; }
.runItem:hover { background: var(--paper); }
.runItem .no { font-weight: 800; font-size: 13px; color: var(--faint); text-align: center; font-variant-numeric: tabular-nums; }
.runItem .t { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: -.02em; }
.runItem .s { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.runItem .ic { display: flex; gap: 3px; align-items: center; max-width: 90px; flex-wrap: wrap; justify-content: flex-end; overflow: hidden; font-size: 11px; }
.runItem.info .t { color: var(--muted); font-weight: 600; }
.runItem.done { opacity: .45; }
.runItem.cur { background: var(--soft); }
.runItem.cur .t, .runItem.cur .no { color: var(--brand); }
.runItem.nxt { border: 1px dashed var(--accent-line); }
.partHead { font-size: 12px; font-weight: 750; color: var(--brand); padding: 14px 10px 4px; }
.dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; background: #b9c5bf; }
.dot.yt, .dot.file, .dot.web, .dot.camera { background: #b9c5bf; }
.dot.missing { background: transparent; border: 1.5px solid var(--amber); }
.dotN { font-size: 11px; font-weight: 750; height: 20px; line-height: 18px; padding: 0 7px; border-radius: 100px; background: var(--paper); border: 1px solid var(--line); color: var(--muted); white-space: nowrap; }
.dotN.miss { background: var(--amber-soft); border-color: var(--amber-line); color: var(--amber); }

/* ───────── 가운데 ───────── */
.center { display: flex; flex-direction: column; gap: 16px; min-height: 0; overflow-y: auto; }
.monitorRow { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.monitor { position: relative; width: 100%; max-width: calc(44vh * 16 / 9); aspect-ratio: 16 / 9; background: #0d1412; border-radius: var(--r-md); overflow: hidden; border: 1px solid var(--line); }
.monitor.live { box-shadow: 0 0 0 3px var(--red-soft), 0 0 0 4px var(--red-line); }
.monitor > img, .monitor > video, .monitor > iframe { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; border: 0; display: none; background: #000; }
.monitor > iframe { pointer-events: none; }
.monitor .on { display: block !important; }
#monCam.mirror { transform: scaleX(-1); }
#monBlack { position: absolute; inset: 0; background: #000; display: none; place-items: center; color: #3b4440; font-weight: 800; letter-spacing: .3em; font-size: 18px; }
#monBlack.on { display: grid !important; }
#monOverlay { position: absolute; inset: 0; display: none; place-items: center; text-align: center; padding: 20px; }
#monOverlay.on { display: grid; }
#monOverlay .ovBox { background: var(--white); color: var(--ink); border-radius: var(--r-md); padding: 12px 18px; font-weight: 750; font-size: 15px; }
#monOverlay .mini { color: var(--muted); }
.monTag { position: absolute; left: 10px; top: 10px; background: var(--white); color: var(--ink); font-size: 11.5px; font-weight: 750; height: 22px; line-height: 22px; padding: 0 9px; border-radius: 100px; }
.monAudio { position: absolute; left: 10px; right: 10px; bottom: 10px; display: none; background: var(--white); color: var(--ink); font-size: 13px; font-weight: 700; padding: 7px 12px; border-radius: var(--r-sm); }
.monAudio.on { display: block; }
.monTools { display: flex; align-items: center; gap: 10px; }

/* ───────── 재생 바 ───────── */
.transport { padding: 16px 18px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px 14px; align-items: center; }
.tpInfo { min-width: 0; }
.tpTitle { font-weight: 800; font-size: 16px; letter-spacing: -.03em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tpSub { font-size: 12.5px; color: var(--muted); }
.tpBar { grid-column: 1 / -1; position: relative; height: 6px; background: var(--paper); border: 1px solid var(--line); border-radius: 100px; cursor: pointer; }
.tpFill { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: var(--brand); border-radius: 100px; }
.tpEnd { position: absolute; top: -5px; bottom: -5px; width: 2px; background: var(--amber); display: none; border-radius: 2px; }
.tpTime { font-variant-numeric: tabular-nums; font-weight: 800; grid-row: 1; grid-column: 2; }
.tpBtns { grid-column: 1 / -1; display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.sbtn { display: inline-flex; align-items: center; justify-content: center; gap: 5px; min-height: 36px; padding: 6px 12px; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--white); color: var(--ink); font-weight: 700; font-size: 13.5px; white-space: nowrap; text-decoration: none; }
.sbtn:hover:not(:disabled) { background: var(--soft); border-color: var(--hover-line); }
.sbtn.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.sbtn.primary:hover:not(:disabled) { background: var(--brand-hover); }
.sbtn.danger { color: var(--red); border-color: var(--red-line); background: var(--white); }
.sbtn.danger:hover:not(:disabled) { background: var(--red-soft); border-color: var(--red-line); }
.vol { display: flex; align-items: center; gap: 6px; margin-left: auto; color: var(--muted); }
.vol input { width: 120px; accent-color: var(--brand); }
#tpCrop.active, #tpFit.active { background: var(--soft); border-color: var(--accent-line); color: var(--brand); }
.deckBar { grid-column: 1 / -1; display: flex; align-items: center; gap: 8px; border-top: 1px solid var(--line); padding-top: 12px; }
.deckBar #deckInfo { font-weight: 800; font-variant-numeric: tabular-nums; min-width: 60px; text-align: center; }
.deckStrip { display: flex; gap: 6px; overflow-x: auto; flex: 1; padding-bottom: 2px; }
.deckStrip img { height: 40px; border-radius: 6px; border: 2px solid transparent; cursor: pointer; }
.deckStrip img.on { border-color: var(--brand); }

/* ───────── 현재 순서 ───────── */
.current { padding: 20px 22px; }
.curHead { display: flex; gap: 14px; align-items: center; }
.curNo { flex: none; min-width: 48px; height: 48px; display: grid; place-items: center; border-radius: 12px; background: var(--brand); color: #fff; font-size: 22px; font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: -.03em; }
.curTitle { font-size: 24px; font-weight: 800; line-height: 1.25; letter-spacing: -.045em; }
.curMeta { color: var(--muted); font-size: 13.5px; margin-top: 2px; }
.curNotes { display: flex; flex-wrap: wrap; gap: 6px; margin: 14px 0 2px; }
.note { display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: 100px; background: var(--paper); border: 1px solid var(--line); color: var(--muted); font-size: 12.5px; font-weight: 650; }
.note.warn { background: var(--amber-soft); border-color: var(--amber-line); color: var(--amber); }
.note.gear { background: var(--paper); }
.cues { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; margin-top: 16px; }
.cue { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-md); padding: 14px; display: flex; flex-direction: column; gap: 9px; transition: border-color .15s; }
.cue:hover { border-color: var(--hover-line); }
.cue.playing { border-color: var(--red); box-shadow: 0 0 0 1px var(--red); }
.cue.dragover { outline: 2px dashed var(--brand); outline-offset: -4px; }
.cueTop { display: flex; gap: 7px; align-items: center; }
.cueKey { min-width: 22px; height: 22px; line-height: 20px; text-align: center; border-radius: 6px; background: var(--paper); border: 1px solid var(--line); font-size: 11.5px; font-weight: 800; color: var(--muted); font-variant-numeric: tabular-nums; }
.cueLabel { flex: 1; min-width: 0; font-weight: 800; letter-spacing: -.03em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cueSub { font-size: 12.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cueSub.miss { color: var(--amber); font-weight: 650; }
.modeChip { height: 22px; padding: 0 9px; border-radius: 100px; background: var(--soft); border: 0; color: var(--brand); font-size: 11.5px; font-weight: 750; white-space: nowrap; }
.modeChip:hover { background: var(--accent-line); }
.modeChip.audio-black { background: var(--paper); color: var(--muted); }
.cueGo { min-height: 42px; border: 0; border-radius: var(--r-sm); background: var(--brand); color: #fff; font-weight: 800; font-size: 15px; letter-spacing: -.02em; }
.cueGo:hover { background: var(--brand-hover); }
.cue.playing .cueGo { background: var(--red); }
.cueRow { display: flex; gap: 5px; flex-wrap: wrap; }
.cueRow .sbtn { min-height: 30px; padding: 3px 9px; font-size: 12px; }
.emptyCues { color: var(--muted); padding: 14px 2px 4px; }
.curFoot { display: flex; gap: 10px; margin-top: 16px; flex-wrap: wrap; align-items: center; }

/* 선생님 요청사항 */
.reqBox { position: relative; margin-top: 16px; padding: 14px 16px 14px 18px; border-radius: var(--r-md); background: var(--amber-soft); border: 1px solid var(--amber-line); cursor: pointer; }
.reqBox::before { content: ''; position: absolute; left: 0; top: 12px; bottom: 12px; width: 3px; border-radius: 0 3px 3px 0; background: #d49a2a; }
.reqBox:hover { border-color: #ddc28a; }
.reqBox.empty { background: var(--paper); border: 1px dashed var(--field-line); }
.reqBox.empty::before { display: none; }
.reqHead { display: flex; gap: 8px; align-items: baseline; font-size: 13px; font-weight: 750; color: var(--amber); }
.reqBox.empty .reqHead { color: var(--muted); }
.reqText { margin-top: 4px; font-size: 17px; font-weight: 700; line-height: 1.55; color: var(--ink); letter-spacing: -.02em; }
.reqBox.empty .reqText { font-size: 13.5px; font-weight: 500; color: var(--muted); }
.memoText { margin-top: 8px; padding-top: 8px; border-top: 1px dashed var(--amber-line); font-size: 13.5px; color: var(--muted); }

/* 방송반 장비 세팅 */
.gearRow { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 12px; }
.gearLab { font-size: 13px; font-weight: 750; color: var(--muted); margin-right: 2px; }
.gearLab b { color: var(--ink); } .gearLab b.ok { color: var(--brand); }
.gchip { display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: 100px; background: var(--white); border: 1px solid var(--line); color: var(--ink); font-size: 12.5px; font-weight: 650; cursor: default; }
.gchip[data-gi] { cursor: pointer; }
.gchip[data-gi]:hover { border-color: var(--hover-line); }
.gchip.done { background: var(--soft); border-color: var(--accent-line); color: var(--brand); }
.gchip.add { background: transparent; border-style: dashed; border-color: var(--field-line); color: var(--muted); cursor: pointer; }
.gchip.add:hover { color: var(--brand); border-color: var(--brand); }

/* 버튼이 많을 때 */
.cueBar { display: flex; gap: 10px; align-items: center; margin-top: 16px; flex-wrap: wrap; }
.cueBar kbd { margin-left: 4px; background: rgba(255, 255, 255, .2); border-color: rgba(255, 255, 255, .4); color: #fff; }
.nextBadge { height: 20px; line-height: 20px; padding: 0 7px; border-radius: 100px; background: var(--soft); color: var(--brand); font-size: 11px; font-weight: 800; }
.cues.many { grid-template-columns: repeat(auto-fill, minmax(176px, 1fr)); gap: 8px; }
.cues.many .cue { padding: 10px; gap: 6px; }
.cues.many .cueGo { min-height: 34px; font-size: 13.5px; }
.cues.many .cueSub { font-size: 11.5px; }
.cues.many .cueRow .sbtn { min-height: 26px; padding: 2px 7px; font-size: 11px; }

/* 미리보기 썸네일 */
.thumb { position: relative; display: grid; place-items: center; aspect-ratio: 16 / 9; background: #0d1412; border-radius: var(--r-sm); overflow: hidden; cursor: pointer; color: #9fb0a8; font-size: 12px; text-decoration: none; }
.thumb img { width: 100%; height: 100%; object-fit: contain; display: block; }
.thumb .dur { position: absolute; right: 6px; bottom: 6px; height: 20px; line-height: 20px; padding: 0 7px; border-radius: 100px; background: rgba(0, 0, 0, .7); color: #fff; font-size: 11px; font-weight: 750; font-variant-numeric: tabular-nums; }
.thumb .play { position: absolute; inset: 0; display: grid; place-items: center; font-size: 24px; color: #fff; opacity: 0; transition: opacity .15s; background: rgba(0, 0, 0, .25); }
.thumb:hover .play { opacity: 1; }
.thumb.audio { background: var(--soft); color: var(--brand); }
.thumb.audio .big { font-size: 28px; }
.thumb.audio .dur { background: var(--white); color: var(--brand); }
.thumb.loading { background: var(--paper); color: var(--muted); }

/* ───────── 오른쪽 ───────── */
.side { display: flex; flex-direction: column; gap: 16px; min-height: 0; overflow-y: auto; }
.nav { display: grid; grid-template-columns: 1fr 2fr; gap: 8px; }
.navbtn { min-height: 60px; border-radius: 14px; border: 1px solid var(--line); background: var(--white); color: var(--ink); font-weight: 800; font-size: 15px; letter-spacing: -.03em; }
.navbtn:hover { background: var(--soft); border-color: var(--hover-line); }
.navbtn.next { background: var(--brand); border-color: var(--brand); color: #fff; font-size: 18px; }
.navbtn.next:hover { background: var(--brand-hover); }
.nextCard { padding: 16px 18px; }
.nextCard .lab { font-size: 13px; font-weight: 750; color: var(--brand); }
.nextCard img { width: 100%; aspect-ratio: 16 / 9; object-fit: contain; background: #0d1412; border-radius: 10px; margin: 10px 0; display: block; }
.nextCard .noimg { width: 100%; aspect-ratio: 16 / 9; background: var(--paper); border: 1px dashed var(--field-line); border-radius: 10px; margin: 10px 0; display: grid; place-items: center; color: var(--muted); font-size: 12.5px; }
.nextCard .t { font-weight: 800; font-size: 16px; letter-spacing: -.035em; }
.nextCard ul { margin: 6px 0 0; padding-left: 16px; font-size: 13px; color: var(--muted); }
.nextReq { margin-top: 10px; padding: 8px 11px; border-radius: var(--r-sm); background: var(--amber-soft); border: 1px solid var(--amber-line); color: var(--ink); font-size: 13px; font-weight: 600; }
.nextGear { margin-top: 6px; font-size: 12.5px; color: var(--muted); }
.nextCard .gearRow { margin-top: 10px; }
.globals { padding: 10px; display: grid; gap: 6px; }
.gbtn { min-height: 44px; border-radius: 10px; border: 0; background: transparent; color: var(--muted); font-weight: 700; text-align: left; padding: 9px 12px; }
.gbtn:hover { background: var(--paper); color: var(--ink); }
.gbtn.active { background: var(--amber-soft); color: var(--amber); }
.timer { padding: 14px 18px; }
.timer b { font-size: 26px; font-weight: 800; letter-spacing: -.03em; font-variant-numeric: tabular-nums; margin: 0 8px; }
.timer b.over { color: var(--red); }
.keys { padding: 0 18px 14px; font-size: 12.5px; color: var(--muted); display: grid; gap: 5px; }
.keys .panelHead { padding-left: 0; }

/* 방송반 · 담임 보내기 */
.tbtn.share { }
.crewMsg { padding: 0 16px 16px; display: grid; gap: 8px; }
.crewMsg .panelHead { padding-left: 0; }
.crewMsg textarea, .crewMsg select { width: 100%; }
.presets { display: flex; flex-wrap: wrap; gap: 4px; }
.presets button { height: 26px; padding: 0 10px; border-radius: 100px; border: 1px solid var(--line); background: var(--white); font-size: 12px; }
.sentList { display: grid; gap: 4px; max-height: 150px; overflow-y: auto; }
.sent { display: flex; justify-content: space-between; gap: 8px; padding: 7px 10px; border-radius: var(--r-sm); background: var(--paper); font-size: 13px; }
.sent .ak { white-space: nowrap; font-weight: 750; color: var(--muted); }
.sent .ak.ok { color: var(--brand); }

/* ───────── 입력 ───────── */
select, input[type=text], input[type=number], textarea { min-height: 40px; min-width: 0; border: 1px solid var(--field-line); border-radius: var(--r-sm); background: var(--white); color: var(--ink); padding: 8px 11px; line-height: 1.45; }
textarea { resize: vertical; }
select { flex: 1; }
input::placeholder, textarea::placeholder { color: var(--muted); opacity: .9; }
.row { display: flex; gap: 8px; align-items: center; }
.chk { display: flex; gap: 7px; align-items: center; font-size: 13.5px; font-weight: 650; }
.chk input { width: 17px; height: 17px; margin: 0; accent-color: var(--brand); }

/* ───────── 대화상자 ───────── */
.dlg { background: var(--white); color: var(--ink); border: 1px solid var(--line); border-radius: 20px; padding: 0; width: min(860px, 94vw); max-height: 90vh; box-shadow: 0 24px 60px #162e2433; }
.dlg.wide { width: min(1100px, 96vw); }
.dlg::backdrop { background: rgba(20, 40, 34, .35); }
.dlgHead { display: flex; justify-content: space-between; align-items: center; padding: 18px 22px; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: var(--white); z-index: 2; }
.dlgHead b { font-size: 17px; letter-spacing: -.04em; }
.x { width: 36px; height: 36px; border: 0; border-radius: 9px; background: none; color: var(--muted); font-size: 17px; }
.x:hover { background: var(--paper); color: var(--ink); }
.dlgFoot { display: flex; gap: 8px; align-items: center; padding: 14px 22px; border-top: 1px solid var(--line); position: sticky; bottom: 0; background: var(--white); }
.camGrid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding: 16px 22px; }
.camOpt { background: var(--paper); border-radius: var(--r-md); padding: 14px 16px; }
.camOpt h3 { margin: 0 0 8px; font-size: 15px; letter-spacing: -.03em; }
.camOpt p { margin: 4px 0; }
.qrRow { display: flex; gap: 12px; align-items: flex-start; }
.qr { background: #fff; padding: 8px; border-radius: 10px; border: 1px solid var(--line); line-height: 0; flex: none; }
.qr img, .qr svg { width: 140px; height: 140px; }
.qr.big img, .qr.big svg { width: 200px; height: 200px; }
.shareBody { display: flex; gap: 18px; padding: 20px 22px; align-items: flex-start; }
.camPreview { position: relative; margin: 0 22px; aspect-ratio: 16 / 9; max-height: 34vh; background: #0d1412; border-radius: var(--r-md); overflow: hidden; display: grid; place-items: center; }
.camPreview video { width: 100%; height: 100%; object-fit: contain; position: absolute; inset: 0; }
.camPreview video.mirror { transform: scaleX(-1); }
#camPrevEmpty { color: #9fb0a8; }
.checkBody { padding: 8px 22px 22px; overflow: auto; }
.checkSum { display: flex; gap: 6px; flex-wrap: wrap; margin: 10px 0 14px; }
.checkTable { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.checkTable th, .checkTable td { border-bottom: 1px solid var(--line); padding: 10px 8px; text-align: left; vertical-align: middle; }
.checkTable th { position: sticky; top: 0; background: var(--white); color: var(--muted); font-size: 12.5px; font-weight: 700; }
.checkTable tr:hover td { background: var(--paper); }
.st { font-weight: 750; white-space: nowrap; }
.st.ok { color: var(--brand); } .st.miss { color: var(--amber); } .st.na { color: var(--faint); }
.editBody { padding: 16px 22px; overflow: auto; display: grid; gap: 12px; }
.editText, .editCue { background: var(--paper); border-radius: var(--r-md); padding: 14px; display: grid; gap: 10px 12px; }
.editText { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.editCue { grid-template-columns: repeat(6, minmax(0, 1fr)); align-items: end; border: 1px solid var(--line); background: var(--white); }
.editText label, .editCue label { display: grid; gap: 5px; font-size: 12.5px; font-weight: 700; color: var(--muted); }
.editText .span2, .editCue .span2 { grid-column: span 2; } .editText .span3 { grid-column: 1 / -1; }
.editCue .span3 { grid-column: span 3; } .editCue .span4 { grid-column: span 4; } .editCue .span6 { grid-column: 1 / -1; }
.editAdd { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.help { padding: 10px 26px 22px; line-height: 1.8; }
.help li { margin-bottom: 4px; }
.help h4 { margin: 18px 0 2px; color: var(--brand); letter-spacing: -.03em; }
.askDlg { width: min(460px, 92vw); }
.askBody { padding: 20px 22px 8px; font-size: 15px; }
.askBody p { margin: 0 0 12px; }
.askInput { width: 100%; }
.previewDlg { width: min(880px, 94vw); }
.pvBody { padding: 16px 22px; }
.pvBody video, .pvBody img { width: 100%; max-height: 60vh; background: #0d1412; border-radius: var(--r-md); display: block; object-fit: contain; }
.pvBody audio { width: 100%; margin-top: 8px; }
.pvAudio { padding: 22px; text-align: center; border-radius: var(--r-md); background: var(--soft); color: var(--brand); font-size: 19px; font-weight: 800; }

/* ───────── 알림 (학급포털 토스트와 같은 모양) ───────── */
#toasts { position: fixed; right: 24px; bottom: 24px; display: grid; gap: 8px; z-index: 100; width: min(380px, 90vw); }
.toast { padding: 12px 18px; border-radius: 12px; background: var(--dark); color: #fff; box-shadow: 0 8px 30px #122d2550; animation: tin .2s ease; }
.toast.err { background: #7d2a22; }
.toast.warn { background: #6b4a12; }
.toast a { color: #cfeee2; }
@keyframes tin { from { transform: translateY(8px); opacity: 0; } }

@media (max-width: 1500px) { .brand span:not(.brandMark) { display: none; } .top { gap: 6px; padding: 0 14px; } .tbtn .mini { display: none; } .tbtn.share .mini { display: inline; } .clock { font-size: 16px; } .grid { gap: 12px; padding: 12px 14px; } }
@media (max-width: 1180px) { .grid { grid-template-columns: 214px minmax(0, 1fr) 260px; } }
.brandMark { display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 9px; background: var(--brand); color: #fff !important; font-size: 15px; font-weight: 800; }

/* 설정 */
.brand b { font-weight: 800; }
.setBody { padding: 6px 22px 22px; display: grid; gap: 4px; overflow: auto; }
.setSec { padding: 16px 0; border-top: 1px solid var(--line); }
.setSec:first-child { border-top: 0; }
.setSec h3 { margin: 0 0 10px; font-size: 16px; letter-spacing: -.04em; }
.setSec p { margin: 6px 0; }
.setSec label.grow { flex: 1; display: grid; gap: 5px; font-size: 12.5px; font-weight: 700; color: var(--muted); }
.setSec .row { align-items: flex-end; flex-wrap: wrap; }
.setSteps { margin: 0; padding-left: 20px; display: grid; gap: 10px; line-height: 1.9; }
.linkRow { display: grid; grid-template-columns: 110px 1fr auto; gap: 8px; align-items: center; margin-top: 6px; font-weight: 700; font-size: 13.5px; }
.impSum { margin-top: 14px; padding: 10px 14px; border-radius: var(--r-sm); background: var(--soft); color: var(--brand); font-size: 13.5px; }
.impWarn { margin-top: 8px; padding: 10px 14px; border-radius: var(--r-sm); background: var(--amber-soft); color: var(--amber); font-size: 13px; line-height: 1.6; }
.impTable { margin-top: 10px; max-height: 42vh; overflow: auto; border: 1px solid var(--line); border-radius: var(--r-sm); }
.impTable .note { margin: 2px 2px 2px 0; }

/* 로그인 확인 */
.gate { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; background: var(--paper); padding: 20px; }
.gate[hidden] { display: none; }
.gateBox { background: var(--white); border: 1px solid var(--line); border-radius: 20px; padding: 26px 28px; max-width: 520px; width: 100%; }
.gateBox h2 { margin: 0 0 10px; font-size: 22px; letter-spacing: -.045em; }
#userName { margin-left: 4px; white-space: nowrap; }
@media (max-width: 1500px) { #userName { display: none; } }
