* { box-sizing: border-box; }
body { margin: 0; font-family: -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif; background: #f4f6fb; color: #17233b; }
.hidden { display: none !important; }
.topbar { display: flex; justify-content: space-between; align-items: center; padding: 12px 20px; background: #0f2044; color: #fff; }
.brand { font-size: 20px; font-weight: 700; }
.brand span { color: #6ea8ff; font-weight: 600; }
.badge { font-size: 12px; padding: 4px 10px; border-radius: 999px; background: #445; }
.badge.live { background: #146c43; }
.badge.demo { background: #8a6d00; }
.foot { text-align: center; color: #7a8699; font-size: 12px; padding: 14px; }
.lobby { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; max-width: 980px; margin: 22px auto; padding: 0 16px; }
@media (max-width: 760px) { .lobby { grid-template-columns: 1fr; } }
.card { background: #fff; border-radius: 12px; padding: 18px; box-shadow: 0 1px 4px rgba(15,32,68,.08); }
.card h2 { margin-top: 0; font-size: 17px; }
label { display: block; font-size: 13px; color: #44506a; margin: 10px 0; }
input, select { width: 100%; padding: 9px 10px; margin-top: 4px; border: 1px solid #ccd4e4; border-radius: 8px; font-size: 14px; }
button { border: 1px solid #ccd4e4; background: #fff; border-radius: 8px; padding: 8px 14px; cursor: pointer; font-size: 14px; }
button.primary { background: #1a56db; border-color: #1a56db; color: #fff; }
button.danger { background: #c81e1e; border-color: #c81e1e; color: #fff; }
button.off { opacity: .45; }
button.small, a.btn.small { font-size: 12px; padding: 5px 10px; }
a.btn { border: 1px solid #ccd4e4; border-radius: 8px; text-decoration: none; color: #17233b; background: #fff; }
.hint { color: #7a8699; font-size: 12px; }
.muted { color: #7a8699; font-size: 13px; margin-left: 8px; }
.class-list { margin-top: 12px; display: grid; gap: 8px; }
.class-item { display: flex; justify-content: space-between; align-items: center; border: 1px solid #e2e7f2; border-radius: 10px; padding: 10px 12px; }
.class-item .t { font-weight: 600; }
.class-item .m { font-size: 12px; color: #7a8699; }
.room { max-width: 1280px; margin: 14px auto; padding: 0 14px; }
.room-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.room-head-right { display: flex; gap: 8px; align-items: center; }
.clock { font-variant-numeric: tabular-nums; font-weight: 700; }
.room-body { display: grid; grid-template-columns: 1fr 300px; gap: 12px; }
@media (max-width: 900px) { .room-body { grid-template-columns: 1fr; } }
.stage { position: relative; background: #0b1220; border-radius: 12px; aspect-ratio: 16/9; overflow: hidden; }
.stage video { width: 100%; height: 100%; object-fit: contain; background: #000; }
.stage-ph { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #8fa3c8; font-size: 15px; }
.toolbar { display: flex; gap: 8px; flex-wrap: wrap; margin: 10px 0; }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; }
.tile { position: relative; background: #0b1220; border-radius: 10px; aspect-ratio: 4/3; overflow: hidden; }
.tile video { width: 100%; height: 100%; object-fit: cover; }
.tile .nm { position: absolute; left: 6px; bottom: 6px; color: #fff; font-size: 12px; background: rgba(0,0,0,.55); padding: 2px 7px; border-radius: 999px; }
.tile .avatar { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #8fa3c8; font-size: 26px; }
.side { background: #fff; border-radius: 12px; padding: 12px; box-shadow: 0 1px 4px rgba(15,32,68,.08); display: flex; flex-direction: column; min-height: 420px; }
.side-tabs { display: flex; gap: 6px; margin-bottom: 10px; }
.tab.active { background: #1a56db; color: #fff; border-color: #1a56db; }
.people { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.people li { display: flex; justify-content: space-between; border-bottom: 1px solid #eef1f7; padding: 6px 2px; font-size: 14px; }
.role { font-size: 11px; color: #fff; background: #64748b; border-radius: 999px; padding: 1px 7px; margin-left: 6px; }
.role.teacher { background: #1a56db; }
.role.ta { background: #7c3aed; }
.chatbox { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; min-height: 300px; }
.msg { font-size: 14px; }
.msg .who { font-weight: 600; font-size: 12px; color: #44506a; }
.chat-send { display: flex; gap: 6px; margin-top: 10px; }
.chat-send input { flex: 1; margin-top: 0; }
.ware-add { display: grid; gap: 6px; margin-top: 10px; }
.ware-add input { margin-top: 0; }
#wareList a { display: block; padding: 7px 2px; border-bottom: 1px solid #eef1f7; color: #1a56db; text-decoration: none; font-size: 14px; }
.board-wrap { margin-top: 12px; background: #fff; border-radius: 12px; padding: 12px; box-shadow: 0 1px 4px rgba(15,32,68,.08); }
.board-head { display: flex; gap: 8px; align-items: center; margin-bottom: 8px; }
.board-head input[type=color] { width: 44px; padding: 2px; }
#board { width: 100%; border: 1px solid #ccd4e4; border-radius: 8px; touch-action: none; background: #fff; }
