/* 구조: shadcn dashboard-01 값(머리 48px, 지표 카드 안쪽 24px와 사이 16px, 라벨 14px, 값 30px 600). owner-design V9
   학생 칸 그리드: Obserview(한 화면 최대 16명) 대신 30명 이상을 한 화면에 둔다. 칸 최소 폭 200px은 자체 값(1440px 화면에서 6열, 30명이 5줄).
   경고 칸: 테두리 2px 경보색 #B3362B와 경보색 글자(K-SMART 요구 "적색으로 표시"). 바탕은 칠하지 않는다(H1 무채색 7개 + 경보색 1개). */
.hd { display: flex; align-items: center; gap: 12px; height: 48px; padding: 0 16px; border-bottom: 1px solid var(--line); }
.hd #exam { min-height: 36px; width: 180px; padding: 4px 8px; }
.hd select { min-height: 36px; padding: 4px 8px; }
.chk { display: flex; gap: 8px; align-items: center; margin: 0; font-size: 14px; color: var(--ink); white-space: nowrap; }
.grow { flex: 1; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.layout { display: grid; grid-template-columns: 1fr; gap: 16px; padding: 16px; }
.layout.with-detail { grid-template-columns: minmax(0, 1fr) 480px; }
main > * + * { margin-top: 16px; }
.cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.m .ml { font-size: 14px; color: var(--ink2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.m .mv { font-size: 30px; font-weight: 600; line-height: 36px; white-space: nowrap; }
.m .of { color: var(--ink3); }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.tile { min-width: 0; border: 1px solid var(--line); border-radius: 8px; padding: 12px; background: var(--bg); cursor: pointer; transition: border-color 150ms var(--ease), background 150ms var(--ease); }
.tile:hover { background: var(--bg2); }
.tile:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.tile.sel { border-color: var(--ink); }
.tile .t1 { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
.tile .nm { font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.tile .sid { font-size: 14px; color: var(--ink2); white-space: nowrap; flex-shrink: 0; }
.tile .rk { font-size: 16px; white-space: nowrap; flex-shrink: 0; }
.tile .st { font-size: 14px; margin: 4px 0 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile canvas { display: block; width: 100%; height: 32px; }
.tile .t3 { display: flex; justify-content: space-between; gap: 8px; margin-top: 8px; font-size: 14px; color: var(--ink2); white-space: nowrap; }
.tile .t3 .pres { overflow: hidden; text-overflow: ellipsis; }
.tile.hot { border: 2px solid var(--alert); padding: 11px; }
.tile.hot .nm, .tile.hot .st { color: var(--alert); font-weight: 700; }
.tile.gone .nm, .tile.gone .st, .tile.done .nm, .tile.done .st { color: var(--ink3); }
.tile.gone { border-style: dashed; }
#empty { margin: 0; }

.toasts { position: fixed; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); right: 16px; z-index: 50; display: flex; flex-direction: column-reverse; gap: 8px; width: 360px; max-width: calc(100vw - 32px); }
.toast { display: grid; grid-template-columns: 1fr auto; gap: 0 12px; text-align: left; min-height: 0; padding: 12px 16px; border: 2px solid var(--alert); border-radius: 8px; background: var(--bg); color: var(--ink); white-space: normal; box-shadow: 0 4px 12px rgba(23, 23, 23, 0.12); }
.toast b { grid-column: 1; color: var(--alert); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.toast span { grid-column: 1; font-size: 14px; }
.toast .tm { grid-column: 2; grid-row: 1; color: var(--ink2); }

.rf { padding-left: 24px; margin: 0; font-size: 14px; }
.rf li + li { margin-top: 8px; }
.detail { border: 1px solid var(--line); border-radius: 8px; padding: 24px; align-self: start; position: sticky; top: 16px; max-height: calc(100vh - 32px); overflow: auto; }
.detail > * + * { margin-top: 12px; }
.d-state { font-size: 16px; font-weight: 700; margin: 0; }
.acts button { flex: 1; }
.peek { display: block; width: 100%; border-radius: 8px; background: var(--soft); aspect-ratio: 4 / 3; object-fit: cover; transform: scaleX(-1); }
.msg { border-top: 1px solid var(--line); padding-top: 12px; }
.msg .row { flex-wrap: nowrap; }
.msg input { flex: 1; min-width: 0; }
.presets { display: flex; flex-direction: column; gap: 8px; margin-bottom: 8px; }
.presets button { text-align: left; white-space: normal; font-size: 14px; min-height: 36px; }
#d-sent { margin: 8px 0 0; }
.detail canvas { width: 100%; height: 160px; border-bottom: 1px solid var(--line); }
.detail video { width: 100%; border-radius: 8px; background: var(--soft); }
.timeline { list-style: none; padding: 0; margin: 0; font-size: 14px; }
.timeline li { display: grid; grid-template-columns: 72px 1fr auto; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--line); align-items: start; }
.timeline .t { color: var(--ink2); }
.timeline .alert { color: var(--alert); }
.timeline button { min-height: 32px; padding: 2px 8px; font-size: 14px; }
@media (max-width: 1100px) { .layout.with-detail { grid-template-columns: 1fr; } .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .hd { flex-wrap: wrap; height: auto; padding: 8px 16px; } .hd #exam { width: 140px; } .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .cards { gap: 12px; } .m { padding: 16px; } }
