.classroom-page { padding-block: 38px 70px; }
.classroom-intro, .section-heading, .room-heading, .student-room-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.classroom-intro { margin-bottom: 22px; }
.classroom-intro h1 { font-size: clamp(2rem, 4vw, 3.1rem); letter-spacing: -.035em; margin-bottom: 10px; }
.eyebrow { color: var(--teal); font-size: .84rem; font-weight: 700; letter-spacing: .06em; }
.classroom-layout { display: grid; grid-template-columns: minmax(225px, 285px) minmax(0, 1fr); align-items: start; gap: 24px; }
.classroom-layout > *, .student-room-heading > div { min-width: 0; }
.classroom-layout aside { position: sticky; top: 16px; }
.classroom-page select, .classroom-page input, .classroom-page textarea { width: 100%; padding: 10px 12px; }
.classroom-page form label { display: block; margin-block: 14px 6px; font-weight: 600; }
.wide { width: 100%; margin-block: 16px; min-height: 44px; }
.small { font-size: .85rem; }
.join-shortcut { border: 1px solid var(--line); border-radius: 9px; padding: 10px 16px; font-weight: 650; text-decoration: none; background: white; }
.room-list { display: grid; gap: 10px; margin-top: 18px; max-height: 430px; overflow-y: auto; }
.room-list button { display: block; width: 100%; text-align: left; padding: 12px; }
.room-list button[aria-pressed=true] { background: var(--wash); border-color: var(--teal); }
.room-list small { display: block; margin-top: 4px; font-weight: 400; }
.empty-classroom { padding-block: 56px; text-align: center; background: linear-gradient(135deg, #f0faf9, #fffdf4); }
.empty-classroom p { max-width: 430px; margin: 14px auto; }
.empty-mark { display: inline-grid; place-items: center; width: 70px; height: 70px; border-radius: 20px; background: #d0efea; color: var(--teal); font-size: 2.7rem; margin-bottom: 24px; }
.room-heading { align-items: stretch; }
.room-heading > div:first-child { flex: 1 1 230px; overflow-wrap: anywhere; }
.code-panel { display: grid; gap: 7px; text-align: center; background: #ecf7f4; border-radius: 12px; padding: 16px 22px; flex: 0 1 280px; }
.code-panel > span { font-size: .8rem; color: var(--muted); }
.code-panel strong { font: 750 clamp(1.8rem, 4vw, 2.35rem)/1.4 ui-monospace, Consolas, monospace; letter-spacing: .13em; color: #005d66; }
.code-panel button { justify-self: center; }
.section-heading { margin-bottom: 14px; }
.section-heading h2 { margin: 0; }
.step-controls { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.step-controls select { flex: 1 1 200px; width: auto; }
.connection-state { font-size: .8rem; color: #12684d; border-radius: 99px; padding: 5px 10px; background: #eaf5ef; flex: none; }
.connection-state.offline { color: #875013; background: #fff1d8; }
.danger-button { color: #a33e30; border-color: #d9ada5; }
.members { display: grid; gap: 10px; }
.member-row { display: grid; grid-template-columns: minmax(100px, 1fr) minmax(130px, 1fr) auto auto; align-items: end; gap: 10px; padding-block: 12px; border-bottom: 1px solid var(--line); }
.member-row label { font-size: .78rem; color: var(--muted); }
.member-row strong { align-self: center; overflow-wrap: anywhere; }
.member-row button { min-height: 44px; }
.submission-card { border-top: 1px solid var(--line); padding-block: 16px; overflow-wrap: anywhere; }
.submission-card p { white-space: pre-wrap; }
.submission-card .result-meta { color: var(--muted); font-size: .82rem; }
.student-page { background: #f4f9f8; }
.classroom-return-nav { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-left: auto; }
.classroom-return-nav a { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 7px 12px; border: 1px solid var(--line); border-radius: 8px; background: white; font-size: .9rem; font-weight: 600; text-decoration: none; }
.classroom-return-nav a:hover { background: var(--wash); }
.student-width { max-width: 860px; }
.join-card { max-width: 480px; margin: 16px auto; padding: clamp(24px, 5vw, 42px); }
.join-card h1 { font-size: 2.25rem; }
.join-card #join-code { font-size: 1.65rem; letter-spacing: .12em; font-weight: 700; margin-top: 7px; }
.join-card input { margin-top: 7px; }
.student-notice { min-height: 26px; text-align: center; color: var(--muted); font-size: .9rem; }
.student-notice.error, #submission-notice.error { color: #a33819; }
.student-room-heading h1 { font-size: clamp(1.5rem, 4vw, 2rem); overflow-wrap: anywhere; }
.student-room-heading p:last-child { margin-bottom: 0; }
.pending-panel { border-color: #e9c574; background: #fffbef; }
.closed-message { background: var(--wash); padding: 12px 15px; border-radius: 8px; }
.student-footer { justify-content: space-between; }
.student-footer p { flex: 1 1 220px; margin: 0; }
.classroom-page fieldset { border: 1px solid var(--line); border-radius: 9px; padding: 12px; margin: 12px 0; }
.classroom-page fieldset button { margin: 4px; min-width: 44px; min-height: 44px; }
#teacher-activity, #student-activity { overflow-wrap: anywhere; }
#teacher-activity .step, #student-activity .step { margin-bottom: 0; }
@media (max-width: 900px) { .classroom-layout { grid-template-columns: 1fr; } .classroom-layout aside { position: static; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; } .room-list { max-height: 240px; } }
@media (max-width: 560px) { .classroom-page { padding-top: 26px; } .classroom-layout aside { display: block; } .room-heading .code-panel { flex: 1 1 100%; } .member-row { grid-template-columns: 1fr 1fr; } .member-row strong { grid-column: 1 / -1; } .member-row label { grid-column: 1 / -1; } .step-controls button { width: 100%; } .student-room-heading { gap: 10px; } .join-card { margin-top: 0; } .classroom-page .site-nav { gap: 8px; } }

.device-check-entry { display: inline-flex; align-items: center; min-height: 44px; }
