:root {
  color-scheme: light;
  --navy: #0f172a;
  --muted: #64748b;
  --blue: #2563eb;
  --indigo: #4f46e5;
  --line: #e2e8f0;
  --surface: #ffffff;
  --background: #f8fafc;
  --green: #15803d;
  --green-bg: #dcfce7;
  --amber: #a16207;
  --amber-bg: #fef3c7;
  --red: #b91c1c;
  --red-bg: #fee2e2;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  color: var(--navy);
  background: var(--background);
}

button {
  font: inherit;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.classroom-app {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-height: 100vh;
  min-height: 100svh;
  padding: clamp(22px, 3.2vw, 48px);
  overflow: hidden;
}

.app-header {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-logo {
  width: 48px;
  height: 48px;
}

.brand-name {
  font-size: 28px;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.9px;
}

.brand-tagline {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.settings-icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid #e8edf4;
  border-radius: 50%;
  color: #475569;
  background: #f1f5f9;
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.settings-icon:hover {
  border-color: #c7d2fe;
  background: #eef2ff;
  transform: translateY(-1px);
}

.settings-icon:focus-visible,
.icon-button:focus-visible,
.primary-button:focus-visible,
.secondary-button:focus-visible,
.danger-button:focus-visible,
.join-link:focus-visible {
  outline: 3px solid rgba(79, 70, 229, 0.3);
  outline-offset: 3px;
}

.settings-icon svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.display-layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(270px, 330px) minmax(0, 1fr);
  align-items: center;
  gap: clamp(40px, 7vw, 120px);
  width: min(100%, 1280px);
  margin: 0 auto;
  padding: clamp(36px, 6vh, 76px) 0;
}

.mode-column {
  display: grid;
  gap: 16px;
}

.mode-card {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) 24px;
  align-items: center;
  gap: 14px;
  width: 100%;
  min-height: 100px;
  padding: 20px;
  border: 1.5px solid var(--line);
  border-radius: 17px;
  color: var(--navy);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.035);
  text-align: left;
}

.mode-card.is-selected {
  border-color: var(--blue);
  background: #eff6ff;
  box-shadow: 0 10px 28px rgba(37, 99, 235, 0.09);
}

.offline-card {
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.offline-card:hover {
  border-color: #cbd5e1;
  background: #ffffff;
  transform: translateY(-1px);
}

.offline-card:active {
  transform: translateY(0);
}

.mode-icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 13px;
  color: #94a3b8;
  background: #f1f5f9;
}

.is-selected .mode-icon {
  color: var(--blue);
  background: #dbeafe;
}

.mode-icon svg {
  width: 25px;
  height: 25px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.mode-copy strong,
.mode-copy > span {
  display: block;
}

.mode-copy strong {
  margin-bottom: 5px;
  font-size: 17px;
  letter-spacing: -0.25px;
}

.mode-copy > span {
  color: var(--muted);
  font-size: 13px;
}

.radio-indicator {
  display: grid;
  place-items: center;
  width: 23px;
  height: 23px;
  border: 2px solid #cbd5e1;
  border-radius: 50%;
  background: #ffffff;
}

.radio-indicator.is-checked {
  border-color: var(--blue);
}

.radio-indicator.is-checked::after {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--blue);
  content: "";
}

.smartboard-backdrop {
  position: absolute;
  z-index: -1;
  top: 15%;
  right: 1%;
  bottom: 12%;
  left: 29%;
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.7);
  border-radius: 34px;
  background: linear-gradient(135deg, #eef2ff, #f8fafc 52%, #e0e7ff);
  filter: blur(9px);
  opacity: 0.72;
  pointer-events: none;
  transform: scale(1.025);
}

.backdrop-bar {
  position: absolute;
  top: 9%;
  right: 7%;
  left: 7%;
  height: 7%;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.24);
}

.backdrop-grid {
  position: absolute;
  top: 24%;
  right: 8%;
  left: 8%;
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 4%;
  height: 44%;
}

.backdrop-grid span {
  border-radius: 20px;
  background: rgba(147, 197, 253, 0.3);
}

.backdrop-grid span:nth-child(2) {
  background: rgba(196, 181, 253, 0.32);
}

.backdrop-grid span:nth-child(3) {
  background: rgba(165, 180, 252, 0.28);
}

.backdrop-panel {
  position: absolute;
  right: 12%;
  bottom: 8%;
  left: 12%;
  height: 14%;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.58);
}

.join-stage {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 0;
}

.qr-surface {
  position: relative;
  display: grid;
  place-items: center;
  width: clamp(250px, 25vw, 340px);
  aspect-ratio: 1;
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.13);
}

.qr-corner {
  position: absolute;
  width: 38px;
  height: 38px;
  border-color: var(--indigo);
  border-style: solid;
  border-width: 0;
}

.top-left {
  top: -3px;
  left: -3px;
  border-top-width: 4px;
  border-left-width: 4px;
  border-top-left-radius: 13px;
}

.top-right {
  top: -3px;
  right: -3px;
  border-top-width: 4px;
  border-right-width: 4px;
  border-top-right-radius: 13px;
}

.bottom-left {
  bottom: -3px;
  left: -3px;
  border-bottom-width: 4px;
  border-left-width: 4px;
  border-bottom-left-radius: 13px;
}

.bottom-right {
  right: -3px;
  bottom: -3px;
  border-right-width: 4px;
  border-bottom-width: 4px;
  border-bottom-right-radius: 13px;
}

.session-qr {
  width: calc(100% - 34px);
  height: calc(100% - 34px);
  object-fit: contain;
  image-rendering: pixelated;
}

.session-empty {
  max-width: 235px;
  padding: 20px;
  text-align: center;
}

.session-icon {
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  margin: 0 auto 18px;
  border-radius: 18px;
  color: var(--blue);
  background: #eff6ff;
}

.session-icon svg {
  width: 31px;
  height: 31px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.session-empty strong {
  display: block;
  font-size: 18px;
  letter-spacing: -0.3px;
}

.session-empty p {
  margin: 9px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.scan-copy {
  width: min(100%, 620px);
  margin-top: clamp(28px, 4vh, 42px);
  text-align: center;
}

.scan-title-row {
  display: grid;
  grid-template-columns: minmax(30px, 1fr) auto minmax(30px, 1fr);
  align-items: center;
  gap: 18px;
}

.scan-title-row h1 {
  margin: 0;
  font-size: clamp(25px, 2.8vw, 38px);
  line-height: 1.2;
  letter-spacing: -1px;
  white-space: nowrap;
}

.scan-line {
  height: 1px;
  background: #cbd5e1;
}

.scan-copy > p {
  margin: 11px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.join-link {
  display: inline-block;
  margin-top: 10px;
  color: var(--indigo);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

.join-link:hover {
  text-decoration: underline;
}

.join-links {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  margin-top: 10px;
}

.join-links .join-link {
  margin-top: 0;
}

.scan-device-link {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
}

.scan-device-link:hover {
  color: var(--indigo);
  text-decoration: underline;
}

.app-footer {
  position: relative;
  z-index: 2;
  min-height: 40px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 15px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
}

.status-pill::before {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  content: "";
}

.is-checking {
  color: var(--amber);
  background: var(--amber-bg);
}

.is-online {
  color: var(--green);
  background: var(--green-bg);
}

.is-offline {
  color: var(--red);
  background: var(--red-bg);
}

.offline-toast {
  position: fixed;
  z-index: 5;
  right: 20px;
  bottom: 24px;
  left: 20px;
  width: fit-content;
  max-width: calc(100% - 40px);
  margin: 0 auto;
  padding: 13px 18px;
  border: 1px solid #c7d2fe;
  border-radius: 13px;
  color: #3730a3;
  background: #eef2ff;
  box-shadow: 0 14px 38px rgba(15, 23, 42, 0.14);
  font-size: 13px;
  font-weight: 600;
  text-align: center;
}

.offline-toast[hidden] {
  display: none;
}

.settings-drawer {
  position: fixed;
  inset: 0 0 0 auto;
  width: min(430px, 100%);
  max-width: 100%;
  height: 100dvh;
  max-height: none;
  margin: 0;
  padding: 28px;
  overflow-y: auto;
  border: 0;
  border-left: 1px solid #e2e8f0;
  color: var(--navy);
  background: #ffffff;
  box-shadow: -24px 0 70px rgba(15, 23, 42, 0.18);
}

.settings-drawer::backdrop {
  background: rgba(15, 23, 42, 0.38);
  backdrop-filter: blur(3px);
}

.drawer-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--line);
}

.eyebrow {
  color: var(--indigo);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1.1px;
  text-transform: uppercase;
}

.drawer-header h2 {
  margin: 5px 0 0;
  font-size: 23px;
  letter-spacing: -0.6px;
}

.icon-button {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 38px;
  height: 38px;
  padding: 0 0 2px;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--muted);
  background: #f8fafc;
  font-size: 25px;
  line-height: 1;
  cursor: pointer;
}

.drawer-state,
.drawer-session-state {
  margin: 22px 0;
  padding: 17px;
  border: 1px solid var(--line);
  border-radius: 14px;
  color: var(--muted);
  background: #f8fafc;
  font-size: 14px;
  line-height: 1.6;
}

.drawer-session-state strong {
  display: block;
  margin-bottom: 4px;
  color: var(--navy);
}

.drawer-session-state p {
  margin: 0;
}

.drawer-session-state.is-active {
  border-color: #bbf7d0;
  color: #166534;
  background: #f0fdf4;
}

.drawer-session-state a {
  display: inline-block;
  margin-top: 9px;
  color: var(--indigo);
  font-weight: 700;
}

.login-form {
  display: grid;
  gap: 10px;
  margin-top: 24px;
}

.login-form > p:first-child {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.login-form label {
  margin-top: 4px;
  font-size: 13px;
  font-weight: 700;
}

.login-form input {
  width: 100%;
  min-height: 46px;
  padding: 11px 13px;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  color: var(--navy);
  background: #ffffff;
  font: inherit;
  font-size: 14px;
}

.login-form input:focus {
  border-color: var(--indigo);
  outline: 3px solid rgba(79, 70, 229, 0.12);
}

.primary-button,
.secondary-button,
.danger-button {
  width: 100%;
  min-height: 46px;
  margin-top: 10px;
  padding: 11px 16px;
  border-radius: 11px;
  font: inherit;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: filter 160ms ease, transform 160ms ease;
}

.primary-button {
  border: 0;
  color: #ffffff;
  background: linear-gradient(100deg, var(--blue), var(--indigo));
  box-shadow: 0 8px 20px rgba(79, 70, 229, 0.18);
}

.secondary-button {
  border: 1px solid var(--line);
  color: #475569;
  background: #ffffff;
}

.danger-button {
  border: 1px solid #fecaca;
  color: var(--red);
  background: #fef2f2;
}

.primary-button:hover,
.secondary-button:hover,
.danger-button:hover {
  filter: brightness(0.97);
  transform: translateY(-1px);
}

.primary-button:disabled,
.secondary-button:disabled,
.danger-button:disabled {
  cursor: wait;
  opacity: 0.6;
  transform: none;
}

.form-error {
  margin: 4px 0;
  padding: 11px 13px;
  border: 1px solid #fecaca;
  border-radius: 10px;
  color: var(--red);
  background: #fef2f2;
  font-size: 13px;
  line-height: 1.5;
}

.setup-hint,
.control-note {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}

.setup-hint code {
  color: var(--indigo);
  font-size: 11px;
}

.dashboard-link {
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.signed-in-card {
  display: flex;
  align-items: center;
  gap: 11px;
  margin: 22px 0 16px;
  padding: 14px;
  border: 1px solid #bbf7d0;
  border-radius: 13px;
  background: #f0fdf4;
}

.signed-in-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--green);
}

.signed-in-card strong,
.signed-in-card span {
  display: block;
}

.signed-in-card strong {
  color: #166534;
  font-size: 14px;
}

.signed-in-card div span {
  margin-top: 3px;
  color: #15803d;
  font-size: 12px;
  overflow-wrap: anywhere;
}

.join-page {
  display: grid;
  place-items: center;
  min-width: 320px;
  min-height: 100vh;
  min-height: 100svh;
  padding: 24px 18px;
  background: linear-gradient(145deg, #eef2ff, #f8fafc 55%, #e0e7ff);
}

.join-shell {
  width: min(100%, 1180px);
}

.join-card {
  width: min(100%, 540px);
  margin: 0 auto;
  padding: clamp(24px, 5vw, 38px);
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.13);
}

.join-brand {
  display: flex;
  align-items: center;
  gap: 11px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--line);
}

.join-brand img {
  width: 42px;
  height: 42px;
}

.join-brand strong,
.join-brand div span {
  display: block;
}

.join-brand strong {
  font-size: 21px;
  letter-spacing: -0.6px;
}

.join-brand div span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
}

.online-badge {
  margin-left: auto;
  padding: 7px 10px;
  border-radius: 999px;
  color: var(--green);
  background: var(--green-bg);
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.join-content,
.joined-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 38px 0 28px;
  text-align: center;
}

.join-icon,
.joined-icon {
  display: grid;
  place-items: center;
  width: 68px;
  height: 68px;
  margin-bottom: 20px;
  border-radius: 20px;
}

.join-icon svg,
.joined-icon svg {
  width: 34px;
  height: 34px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.join-icon.is-checking {
  color: var(--amber);
  background: var(--amber-bg);
}

.join-icon.is-valid,
.joined-icon {
  color: var(--green);
  background: var(--green-bg);
}

.join-icon.is-invalid {
  color: var(--red);
  background: var(--red-bg);
}

.join-badge {
  padding: 7px 11px;
  border-radius: 999px;
  color: var(--amber);
  background: var(--amber-bg);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.join-badge.is-valid {
  color: var(--green);
  background: var(--green-bg);
}

.join-badge.is-invalid {
  color: var(--red);
  background: var(--red-bg);
}

.join-content h1,
.joined-content h1,
.scan-idle h1,
.scan-result h1 {
  margin: 17px 0 9px;
  color: var(--navy);
  font-size: clamp(24px, 5vw, 32px);
  letter-spacing: -0.8px;
  line-height: 1.2;
}

.join-content p,
.joined-content p,
.scan-idle p,
.scan-result p {
  max-width: 410px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}

.join-time {
  margin-top: 13px;
  color: var(--muted);
  font-size: 12px;
}

.join-form {
  display: grid;
  gap: 9px;
  padding-top: 4px;
}

.join-form label {
  color: var(--navy);
  font-size: 13px;
  font-weight: 800;
}

.join-form input {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid #cbd5e1;
  border-radius: 11px;
  outline: none;
  color: var(--navy);
  background: #ffffff;
  font: inherit;
  font-size: 15px;
}

.join-form input:focus {
  border-color: var(--indigo);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12);
}

.join-device {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  text-align: center;
}

.join-footer {
  margin: 0;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
  line-height: 1.6;
  text-align: center;
}

.scanner-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 24px;
  min-height: 620px;
}

.scanner-camera-panel {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 24px;
  border-radius: 26px;
  color: #ffffff;
  background: #0f172a;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.2);
}

.scanner-camera-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 20px;
}

.scanner-camera-header strong {
  font-size: 20px;
  letter-spacing: -0.4px;
}

.camera-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.camera-status::before {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  content: "";
}

.camera-status.is-checking {
  color: #fbbf24;
}

.camera-status.is-valid {
  color: #86efac;
}

.camera-status.is-invalid {
  color: #fca5a5;
}

.scanner-viewport {
  position: relative;
  display: grid;
  flex: 1;
  min-height: 420px;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 20px;
  background: #020617;
}

.scanner-viewport video,
.scan-snapshot {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.scan-snapshot {
  position: absolute;
  inset: 0;
}

.camera-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 30px;
  color: #cbd5e1;
  text-align: center;
}

.camera-placeholder svg {
  width: 46px;
  height: 46px;
  margin-bottom: 6px;
  fill: none;
  stroke: #94a3b8;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.camera-placeholder strong {
  color: #ffffff;
  font-size: 17px;
}

.camera-placeholder span {
  max-width: 260px;
  font-size: 13px;
  line-height: 1.6;
}

.scanner-corner {
  position: absolute;
  width: 54px;
  height: 54px;
  border-color: #60a5fa;
  border-style: solid;
  border-width: 0;
  filter: drop-shadow(0 0 8px rgba(59, 130, 246, 0.45));
}

.scanner-corner.top-left {
  top: 16%;
  left: 16%;
  border-top-width: 4px;
  border-left-width: 4px;
  border-radius: 10px 0 0;
}

.scanner-corner.top-right {
  top: 16%;
  right: 16%;
  border-top-width: 4px;
  border-right-width: 4px;
  border-radius: 0 10px 0 0;
}

.scanner-corner.bottom-left {
  bottom: 16%;
  left: 16%;
  border-bottom-width: 4px;
  border-left-width: 4px;
  border-radius: 0 0 0 10px;
}

.scanner-corner.bottom-right {
  right: 16%;
  bottom: 16%;
  border-right-width: 4px;
  border-bottom-width: 4px;
  border-radius: 0 0 10px;
}

.scanner-sweep-line {
  position: absolute;
  top: 20%;
  right: 19%;
  left: 19%;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, #818cf8 20%, #38bdf8 80%, transparent);
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.75);
  animation: scanner-sweep 2.6s ease-in-out infinite alternate;
}

.scan-overlay {
  position: absolute;
  bottom: 24px;
  left: 50%;
  padding: 9px 15px;
  border: 1px solid rgba(134, 239, 172, 0.35);
  border-radius: 999px;
  color: #bbf7d0;
  background: rgba(15, 23, 42, 0.88);
  font-size: 12px;
  font-weight: 800;
  transform: translateX(-50%);
}

.camera-help {
  min-height: 20px;
  margin: 15px 0 0;
  color: #cbd5e1;
  font-size: 12px;
  line-height: 1.6;
}

.camera-retry {
  min-height: 42px;
  margin-top: 12px;
  border: 1px solid rgba(148, 163, 184, 0.4);
  border-radius: 10px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
  font: inherit;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.scanner-details {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  padding: clamp(28px, 4vw, 46px);
  border: 1px solid var(--line);
  border-radius: 26px;
  background: #ffffff;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.1);
}

.scan-eyebrow {
  display: inline-block;
  color: var(--indigo);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 1.1px;
  text-transform: uppercase;
}

.scan-idle h1,
.scan-result h1 {
  margin-top: 16px;
}

.scan-instructions {
  display: grid;
  gap: 12px;
  margin-top: 28px;
}

.scan-instructions span {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #475569;
  font-size: 13px;
  font-weight: 700;
}

.scan-instructions strong {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 9px;
  color: var(--indigo);
  background: #eef2ff;
  font-size: 12px;
}

.scan-ready-badge {
  display: inline-flex;
  align-self: flex-start;
  margin-top: 22px;
  padding: 9px 13px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.scan-ready-badge.is-checking {
  color: var(--amber);
  background: var(--amber-bg);
}

.scan-ready-badge.is-valid {
  color: var(--green);
  background: var(--green-bg);
}

.scan-ready-badge.is-invalid {
  color: var(--red);
  background: var(--red-bg);
}

.scan-result .primary-button {
  align-self: stretch;
  margin-top: 24px;
}

.scan-error {
  padding: 18px;
  border: 1px solid #fecaca;
  border-radius: 14px;
  color: var(--red);
  background: #fef2f2;
}

.scan-error strong {
  font-size: 15px;
}

.scan-error p {
  margin: 7px 0 0;
  font-size: 13px;
  line-height: 1.6;
}

.join-page.is-upload {
  background: #f8fafc;
}

.join-page.is-upload.is-phone-device {
  background: #ffffff;
}

.upload-workspace {
  width: min(100%, 1180px);
  margin: 0 auto;
  padding: 30px 0 20px;
}

.upload-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 0 4px 25px;
  border-bottom: 1px solid var(--line);
}

.upload-brand {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 0;
}

.upload-brand img {
  width: 48px;
  height: 48px;
}

.upload-brand h1 {
  margin: 0;
  font-size: 27px;
  letter-spacing: -0.8px;
  line-height: 1.15;
}

.upload-brand p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.upload-header .online-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--blue);
  background: #eff6ff;
}

.online-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
}

.upload-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(330px, 0.88fr);
  align-items: start;
  gap: 28px;
  margin-top: 28px;
}

.upload-panel,
.ready-panel,
.request-card {
  border: 1px solid var(--line);
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 15px 40px rgba(15, 23, 42, 0.055);
}

.upload-panel {
  padding: 27px;
}

.upload-section-heading {
  display: none;
}

.upload-section-heading h2,
.ready-panel h2,
.request-card h2 {
  margin: 0;
  color: var(--navy);
  font-size: 22px;
  letter-spacing: -0.55px;
}

.upload-section-heading p {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.upload-dropzone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 354px;
  margin-top: 0;
  padding: 28px 20px;
  border: 2px dashed #a5b4fc;
  border-radius: 18px;
  background: #fbfcff;
  text-align: center;
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.upload-dropzone:hover,
.upload-dropzone.is-dragging,
.upload-dropzone:focus-within {
  border-color: var(--indigo);
  background: #eef2ff;
}

.upload-dropzone.is-dragging {
  transform: scale(1.01);
}

.upload-dropzone[aria-busy="true"] {
  cursor: wait;
  opacity: 0.72;
}

.upload-cloud {
  display: grid;
  width: 78px;
  height: 78px;
  margin-bottom: 21px;
  place-items: center;
  border-radius: 24px;
  color: #818cf8;
  background: linear-gradient(145deg, #eef2ff, #f5f3ff);
}

.upload-cloud svg {
  width: 43px;
  height: 43px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.45;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.upload-dropzone > strong {
  font-size: 20px;
  letter-spacing: -0.45px;
}

.upload-dropzone > span:not(.upload-cloud):not(.file-type-chips):not(.browse-files-button) {
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.file-type-chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 7px;
  margin-top: 18px;
}

.file-type-chips span {
  padding: 6px 10px;
  border: 1px solid #e0e7ff;
  border-radius: 7px;
  color: #4f46e5;
  background: #eef2ff;
  font-size: 10px;
  font-weight: 800;
}

.browse-files-button {
  margin-top: 23px;
  padding: 11px 20px;
  border: 1px solid #c7d2fe;
  border-radius: 10px;
  color: #4338ca;
  background: #eef2ff;
  font-size: 12px;
  font-weight: 800;
}

.upload-current {
  margin-top: 18px;
  padding: 15px;
  border: 1px solid #c7d2fe;
  border-radius: 12px;
  background: #eef2ff;
}

.upload-current-copy {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.upload-current-copy strong {
  overflow: hidden;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upload-current-copy span {
  color: #4338ca;
  font-size: 11px;
  line-height: 1.5;
}

.upload-current progress {
  display: block;
  width: 100%;
  height: 8px;
  margin-top: 12px;
  overflow: hidden;
  border: 0;
  border-radius: 999px;
  background: #c7d2fe;
  accent-color: var(--indigo);
}

.upload-current progress::-webkit-progress-bar {
  border-radius: 999px;
  background: #c7d2fe;
}

.upload-current progress::-webkit-progress-value {
  border-radius: 999px;
  background: linear-gradient(90deg, var(--blue), var(--indigo));
}

.upload-current progress::-moz-progress-bar {
  border-radius: 999px;
  background: linear-gradient(90deg, var(--blue), var(--indigo));
}

.upload-panel > .form-error {
  margin-top: 16px;
}

.upload-limit-note {
  margin: 15px 0 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.6;
  text-align: center;
}

.upload-side {
  display: grid;
  gap: 20px;
  min-width: 0;
}

.ready-panel {
  min-height: 260px;
  padding: 24px;
}

.ready-heading-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.file-count {
  padding: 6px 9px;
  border-radius: 999px;
  color: var(--indigo);
  background: #eef2ff;
  font-size: 10px;
  font-weight: 800;
  white-space: nowrap;
}

.ready-panel > p {
  margin: 7px 0 17px;
  color: var(--muted);
  font-size: 11px;
}

.file-list {
  display: grid;
  gap: 10px;
}

.file-option {
  display: grid;
  grid-template-columns: auto 39px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #ffffff;
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease;
}

.file-option:hover,
.file-option.is-selected {
  border-color: #a5b4fc;
  background: #f5f7ff;
}

.file-option:has(input:focus-visible) {
  outline: 3px solid rgba(79, 70, 229, 0.25);
  outline-offset: 2px;
}

.file-option:has(input:disabled) {
  cursor: default;
}

.file-option input {
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: var(--indigo);
}

.file-type-icon {
  display: grid;
  width: 39px;
  height: 39px;
  place-items: center;
  border-radius: 10px;
  color: #4338ca;
  background: #eef2ff;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.2px;
}

.file-option-copy {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.file-option-copy strong {
  overflow: hidden;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.file-option-copy > span {
  color: var(--green);
  font-size: 10px;
  font-weight: 700;
}

.file-ready-check {
  color: var(--green);
  font-size: 17px;
  font-weight: 900;
}

.files-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 164px;
  padding: 18px;
  color: var(--muted);
  text-align: center;
}

.files-empty svg {
  width: 37px;
  height: 37px;
  margin-bottom: 12px;
  fill: none;
  stroke: #94a3b8;
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.files-empty strong {
  color: #475569;
  font-size: 13px;
}

.files-empty span {
  max-width: 230px;
  margin-top: 6px;
  font-size: 11px;
  line-height: 1.5;
}

.request-card {
  padding: 24px;
  background: #f8fafc;
}

.request-card h2 {
  font-size: 20px;
}

.request-card p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.55;
}

.request-actions {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(100px, 0.8fr);
  gap: 10px;
  margin-top: 18px;
}

.request-actions .primary-button,
.request-actions .secondary-button {
  min-height: 46px;
  margin: 0;
  padding: 10px 12px;
  font-size: 12px;
}

.request-pending {
  display: flex;
  align-items: flex-start;
  gap: 13px;
}

.request-pending-icon {
  display: grid;
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 12px;
  color: var(--amber);
  background: var(--amber-bg);
}

.request-pending-icon svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.request-pending strong {
  font-size: 15px;
}

.request-pending p {
  margin-top: 4px;
}

.pending-file-name {
  display: block;
  margin-top: 8px;
  overflow-wrap: anywhere;
  color: #475569;
  font-size: 11px;
  font-weight: 700;
}

.workspace-notice {
  margin: -4px 4px 0;
  color: var(--green);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.5;
  text-align: center;
}

.upload-footer {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  margin-top: 25px;
  padding: 18px 4px 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 10px;
  line-height: 1.6;
}

.upload-footer span:first-child {
  color: #475569;
  font-weight: 700;
}

.is-phone-device .upload-workspace {
  max-width: 480px;
  padding: 24px 20px 28px;
}

.is-phone-device .upload-header {
  align-items: flex-start;
  gap: 12px;
  padding-bottom: 20px;
}

.is-phone-device .upload-brand {
  gap: 10px;
}

.is-phone-device .upload-brand img {
  width: 41px;
  height: 41px;
}

.is-phone-device .upload-brand h1 {
  font-size: 23px;
}

.is-phone-device .upload-header .online-badge {
  margin-top: 3px;
  padding: 6px 8px;
  font-size: 9px;
}

.is-phone-device .upload-grid {
  grid-template-columns: 1fr;
  gap: 22px;
  margin-top: 23px;
}

.is-phone-device .upload-panel {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.is-phone-device .upload-section-heading {
  display: block;
}

.is-phone-device .upload-section-heading h2 {
  font-size: 23px;
}

.is-phone-device .upload-dropzone {
  min-height: 268px;
  margin-top: 18px;
  padding: 24px 15px;
}

.is-phone-device .upload-cloud {
  width: 68px;
  height: 68px;
  margin-bottom: 17px;
  border-radius: 21px;
}

.is-phone-device .upload-cloud svg {
  width: 37px;
  height: 37px;
}

.is-phone-device .upload-dropzone > strong {
  font-size: 18px;
}

.is-phone-device .file-type-chips {
  margin-top: 15px;
}

.is-phone-device .browse-files-button {
  margin-top: 18px;
}

.is-phone-device .ready-panel {
  min-height: 0;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.is-phone-device .files-empty {
  min-height: 125px;
}

.is-phone-device .request-card {
  padding: 21px;
}

.is-phone-device .request-actions {
  grid-template-columns: minmax(0, 1.4fr) minmax(90px, 0.8fr);
}

.is-phone-device .upload-footer {
  flex-direction: column;
  gap: 7px;
  margin-top: 20px;
  text-align: center;
}

@keyframes scanner-sweep {
  from {
    transform: translateY(0);
  }
  to {
    transform: translateY(210px);
  }
}

@media (max-width: 820px) {
  .scanner-layout {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .upload-grid {
    grid-template-columns: 1fr;
  }

  .upload-side {
    gap: 18px;
  }

  .scanner-camera-panel {
    min-height: 500px;
  }

  .scanner-viewport {
    min-height: 340px;
  }
}

@media (max-width: 560px) {
  .join-page {
    padding: 18px 14px;
  }

  .upload-workspace {
    padding: 22px 0 16px;
  }

  .upload-header {
    gap: 12px;
    padding-bottom: 19px;
  }

  .upload-brand {
    gap: 9px;
  }

  .upload-brand img {
    width: 40px;
    height: 40px;
  }

  .upload-brand h1 {
    font-size: 21px;
  }

  .upload-brand p {
    font-size: 10px;
  }

  .upload-header .online-badge {
    padding: 6px 8px;
    font-size: 9px;
  }

  .upload-grid {
    gap: 20px;
    margin-top: 22px;
  }

  .upload-panel,
  .ready-panel,
  .request-card {
    padding: 20px;
    border-radius: 17px;
  }

  .upload-dropzone {
    min-height: 300px;
    margin-top: 0;
    padding: 24px 14px;
  }

  .upload-dropzone > strong {
    font-size: 18px;
  }

  .upload-footer {
    flex-direction: column;
    gap: 7px;
    text-align: center;
  }

  .join-card {
    padding: 25px 22px;
  }

  .join-page.is-scanner {
    display: block;
    padding: 0;
    background: #0f172a;
  }

  .is-scanner .join-shell {
    width: 100%;
  }

  .is-scanner .scanner-layout {
    display: flex;
    flex-direction: column;
    gap: 0;
    min-height: 100vh;
    min-height: 100svh;
  }

  .is-scanner .scanner-camera-panel {
    min-height: 54vh;
    min-height: 54svh;
    padding: 22px 18px;
    border-radius: 0;
    box-shadow: none;
  }

  .is-scanner .scanner-viewport {
    min-height: 300px;
  }

  .is-scanner .scanner-details {
    position: relative;
    z-index: 1;
    min-height: 46vh;
    min-height: 46svh;
    margin-top: -18px;
    padding: 30px 24px;
    border-radius: 24px 24px 0 0;
  }

  .is-scanner .join-brand {
    padding-bottom: 18px;
  }

  .is-scanner .scan-idle h1,
  .is-scanner .scan-result h1 {
    font-size: 26px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .scanner-sweep-line {
    animation: none;
  }
}

@media (max-width: 900px) {
  .classroom-app {
    overflow-x: clip;
  }

  .display-layout {
    grid-template-columns: minmax(230px, 280px) minmax(0, 1fr);
    gap: 34px;
  }

  .mode-card {
    grid-template-columns: 40px minmax(0, 1fr) 22px;
    gap: 11px;
    min-height: 88px;
    padding: 16px;
  }

  .mode-icon {
    width: 40px;
    height: 40px;
  }

  .smartboard-backdrop {
    left: 34%;
  }
}

@media (max-width: 680px) {
  .classroom-app {
    padding: 22px 18px 26px;
  }

  .brand-logo {
    width: 42px;
    height: 42px;
  }

  .brand-name {
    font-size: 24px;
  }

  .brand-tagline {
    font-size: 11px;
  }

  .settings-icon {
    width: 42px;
    height: 42px;
  }

  .display-layout {
    grid-template-columns: 1fr;
    gap: 42px;
    padding: 44px 0 54px;
  }

  .mode-column {
    width: min(100%, 420px);
    margin: 0 auto;
  }

  .mode-card {
    min-height: 84px;
  }

  .smartboard-backdrop {
    top: 39%;
    right: -14%;
    bottom: 5%;
    left: -14%;
  }

  .qr-surface {
    width: min(72vw, 300px);
  }

  .scan-title-row {
    gap: 12px;
  }

  .scan-title-row h1 {
    font-size: clamp(23px, 6.5vw, 30px);
    white-space: normal;
  }

  .scan-copy > p {
    max-width: 310px;
    margin-right: auto;
    margin-left: auto;
    line-height: 1.6;
  }
}

@media (max-width: 380px) {
  .upload-brand p {
    max-width: 145px;
  }

  .file-option {
    grid-template-columns: auto 34px minmax(0, 1fr) auto;
    gap: 8px;
    padding: 10px;
  }

  .file-type-icon {
    width: 34px;
    height: 34px;
  }

  .request-actions {
    grid-template-columns: minmax(0, 1.25fr) minmax(82px, 0.75fr);
    gap: 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .offline-card {
    transition: none;
  }
}

.dashboard-body {
  min-width: 320px;
  background:
    radial-gradient(circle at 8% 0%, rgba(219, 234, 254, 0.7), transparent 30%),
    radial-gradient(circle at 96% 12%, rgba(224, 231, 255, 0.55), transparent 26%),
    #f8fafc;
}

.dashboard-page {
  width: min(100%, 1540px);
  margin: 0 auto;
  padding: clamp(22px, 3vw, 46px);
}

.dashboard-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 26px;
}

.dashboard-brand {
  min-width: 0;
  color: inherit;
  text-decoration: none;
}

.dashboard-subtitle {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}

.dashboard-header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 18px;
  min-width: 0;
}

.dashboard-section-label {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 11px 15px;
  border: 1px solid #c7d2fe;
  border-radius: 999px;
  color: #4338ca;
  background: #eef2ff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.55px;
  text-align: center;
  text-transform: uppercase;
}

.dashboard-section-label svg {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.dashboard-text-link,
.dashboard-text-button {
  flex: 0 0 auto;
  padding: 8px 0;
  border: 0;
  color: #475569;
  background: transparent;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}

.dashboard-text-link:hover,
.dashboard-text-button:hover {
  color: var(--indigo);
  text-decoration: underline;
}

.dashboard-text-button:disabled {
  cursor: wait;
  opacity: 0.6;
}

.dashboard-text-link:focus-visible,
.dashboard-text-button:focus-visible,
.dashboard-refresh-button:focus-visible,
.dashboard-brand:focus-visible {
  outline: 3px solid rgba(79, 70, 229, 0.3);
  outline-offset: 4px;
}

.dashboard-board {
  padding: clamp(20px, 2.4vw, 34px);
  border: 1px solid #e2e8f0;
  border-radius: 27px;
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 22px 60px rgba(15, 23, 42, 0.075);
}

.dashboard-session-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 24px;
}

.dashboard-session-copy,
.dashboard-session-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.dashboard-session-time {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.dashboard-live-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.dashboard-live-status::before {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  content: "";
}

.dashboard-live-status.is-online {
  color: var(--green);
}

.dashboard-live-status.is-offline {
  color: var(--red);
}

.dashboard-live-status.is-checking {
  color: var(--amber);
}

.dashboard-refresh-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 38px;
  padding: 8px 13px;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: #475569;
  background: #ffffff;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.dashboard-refresh-button:hover:not(:disabled) {
  border-color: #c7d2fe;
  color: var(--indigo);
  background: #f5f3ff;
}

.dashboard-refresh-button:disabled {
  cursor: wait;
  opacity: 0.6;
}

.dashboard-refresh-button svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.dashboard-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.metric-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 132px;
  padding: 24px 26px;
  border: 1px solid;
  border-radius: 19px;
}

.metric-card > div {
  min-width: 0;
}

.metric-card strong {
  display: block;
  margin-bottom: 7px;
  font-size: clamp(38px, 3.4vw, 52px);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -1.8px;
}

.metric-card > div > span {
  display: block;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.45;
}

.metric-joined {
  border-color: #bfdbfe;
  color: #1d4ed8;
  background: #eff6ff;
}

.metric-asking {
  border-color: #fde68a;
  color: #a16207;
  background: #fffbeb;
}

.metric-accepted {
  border-color: #bbf7d0;
  color: #15803d;
  background: #f0fdf4;
}

.metric-icon {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 58px;
  height: 58px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.68);
}

.metric-icon svg {
  width: 31px;
  height: 31px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.dashboard-columns {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  align-items: start;
  gap: 22px;
  margin-top: 24px;
}

.dashboard-approved-column {
  display: grid;
  gap: 20px;
  min-width: 0;
}

.moderation-panel {
  min-width: 0;
  min-height: 474px;
  padding: 24px;
  border: 1px solid;
  border-radius: 21px;
}

.asking-panel {
  border-color: #e2e8f0;
  background: #f8fafc;
}

.approved-panel {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.panel-title-group {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.panel-icon {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 39px;
  height: 39px;
  border-radius: 12px;
  color: #475569;
  background: #ffffff;
  box-shadow: 0 3px 10px rgba(15, 23, 42, 0.05);
}

.approved-panel .panel-icon {
  color: var(--green);
}

.panel-icon svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.panel-heading h2 {
  margin: 0;
  color: var(--navy);
  font-size: 17px;
  line-height: 1.35;
  letter-spacing: -0.35px;
}

.panel-heading p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.approved-panel .panel-heading p {
  color: #15803d;
}

.panel-count {
  flex: 0 0 auto;
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.panel-count.is-waiting {
  color: #a16207;
  background: #fef3c7;
}

.panel-count.is-approved {
  color: #15803d;
  background: #dcfce7;
}

.stage-notice {
  margin: 17px 0;
  padding: 10px 12px;
  border: 1px dashed #cbd5e1;
  border-radius: 10px;
  color: #64748b;
  background: rgba(255, 255, 255, 0.65);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.55;
}

.approved-panel .stage-notice {
  border-color: #86efac;
  color: #166534;
  background: rgba(255, 255, 255, 0.6);
}

.request-list,
.approved-list {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.dashboard-request-card,
.dashboard-approved-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-width: 0;
  padding: 16px;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.025);
}

.dashboard-approved-card {
  border-color: #86efac;
  background: #ffffff;
}

.dashboard-request-main {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 0;
}

.dashboard-avatar {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 41px;
  height: 41px;
  border-radius: 12px;
  color: #4338ca;
  background: #eef2ff;
  font-size: 13px;
  font-weight: 800;
}

.dashboard-identity {
  min-width: 0;
}

.dashboard-name-row {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
}

.dashboard-student-name {
  overflow: hidden;
  color: var(--navy);
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dashboard-device {
  flex: 0 0 auto;
  padding: 3px 7px;
  border-radius: 999px;
  color: #475569;
  background: #f1f5f9;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.25px;
  text-transform: uppercase;
}

.dashboard-file-line {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  margin-top: 7px;
  color: var(--muted);
  font-size: 11px;
}

.dashboard-file-type {
  flex: 0 0 auto;
  padding: 3px 5px;
  border-radius: 5px;
  color: #4338ca;
  background: #eef2ff;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.35px;
}

.dashboard-file-name {
  overflow: hidden;
  min-width: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dashboard-file-size {
  flex: 0 0 auto;
  white-space: nowrap;
}

.dashboard-moderation-actions {
  display: flex;
  flex: 0 0 auto;
  gap: 8px;
}

.moderation-preview {
  min-height: 37px;
  padding: 8px 13px;
  border: 1px solid;
  border-radius: 9px;
  font: inherit;
  font-size: 11px;
  font-weight: 800;
}

.moderation-preview:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

.moderation-preview.is-accept {
  border-color: #86efac;
  color: #15803d;
  background: #dcfce7;
}

.moderation-preview.is-reject {
  border-color: #fecaca;
  color: #b91c1c;
  background: #fef2f2;
}

.dashboard-queue-number {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 35px;
  height: 35px;
  border-radius: 50%;
  color: #15803d;
  background: #dcfce7;
  font-size: 13px;
  font-weight: 800;
}

.dashboard-approved-status {
  display: grid;
  justify-items: end;
  flex: 0 0 auto;
  gap: 6px;
}

.dashboard-accepted-badge {
  padding: 6px 9px;
  border-radius: 999px;
  color: #15803d;
  background: #dcfce7;
  font-size: 10px;
  font-weight: 800;
}

.dashboard-queue-status {
  color: #64748b;
  font-size: 10px;
  font-weight: 700;
}

.dashboard-queue-status.is-live {
  color: #15803d;
}

.dashboard-queue-status.is-next {
  color: #a16207;
}

.dashboard-queue-status.is-completed {
  color: #475569;
}

.panel-empty {
  display: grid;
  justify-items: center;
  min-height: 245px;
  padding: 38px 20px;
  color: var(--muted);
  text-align: center;
}

.empty-icon {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  margin-bottom: 14px;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  color: #94a3b8;
  background: #ffffff;
}

.approved-panel .empty-icon {
  border-color: #bbf7d0;
  color: #4ade80;
}

.empty-icon svg {
  width: 25px;
  height: 25px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.panel-empty strong {
  color: #475569;
  font-size: 14px;
}

.panel-empty p {
  max-width: 350px;
  margin: 8px 0 0;
  font-size: 12px;
  line-height: 1.65;
}

.activity-log {
  display: flex;
  align-items: center;
  gap: 15px;
  min-width: 0;
  padding: 21px 23px;
  border: 1px solid #bfdbfe;
  border-radius: 18px;
  background: #eff6ff;
}

.activity-icon {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 43px;
  height: 43px;
  border-radius: 13px;
  color: #2563eb;
  background: #dbeafe;
}

.activity-icon svg {
  width: 23px;
  height: 23px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.activity-log h2 {
  margin: 0 0 5px;
  color: #1e3a8a;
  font-size: 14px;
}

.activity-log p {
  margin: 0;
  color: #475569;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.6;
  overflow-wrap: anywhere;
}

.dashboard-footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 22px;
  color: #94a3b8;
  font-size: 11px;
  font-weight: 600;
}

.dashboard-state {
  display: grid;
  justify-items: center;
  min-height: 430px;
  padding: 70px 24px;
  border: 1px solid #e2e8f0;
  border-radius: 24px;
  color: var(--muted);
  background: #ffffff;
  box-shadow: 0 18px 50px rgba(15, 23, 42, 0.06);
  text-align: center;
}

.dashboard-state strong {
  margin-top: 17px;
  color: var(--navy);
  font-size: 19px;
}

.dashboard-state p {
  max-width: 480px;
  margin: 9px 0 0;
  font-size: 13px;
  line-height: 1.6;
}

.dashboard-state .primary-button {
  width: auto;
  min-width: 150px;
  margin-top: 22px;
}

.dashboard-state.is-error {
  border-color: #fecaca;
  background: #fffafa;
}

.dashboard-state.is-error strong {
  color: var(--red);
}

.dashboard-spinner {
  width: 34px;
  height: 34px;
  border: 3px solid #e0e7ff;
  border-top-color: var(--indigo);
  border-radius: 50%;
  animation: dashboard-spin 800ms linear infinite;
}

@keyframes dashboard-spin {
  to {
    transform: rotate(360deg);
  }
}

@media (max-width: 1180px) {
  .dashboard-header {
    align-items: flex-start;
  }

  .dashboard-header-actions {
    flex-wrap: wrap;
    gap: 10px 16px;
  }

  .dashboard-section-label {
    order: 3;
    width: 100%;
  }

  .dashboard-columns {
    grid-template-columns: 1fr;
  }

  .moderation-panel {
    min-height: 0;
  }

  .panel-empty {
    min-height: 190px;
  }
}

@media (max-width: 760px) {
  .dashboard-page {
    padding: 20px 14px;
  }

  .dashboard-header {
    flex-direction: column;
    gap: 17px;
    margin-bottom: 20px;
  }

  .dashboard-header-actions {
    justify-content: flex-start;
    width: 100%;
  }

  .dashboard-section-label {
    width: fit-content;
    max-width: 100%;
    font-size: 9px;
  }

  .dashboard-board {
    padding: 18px;
    border-radius: 20px;
  }

  .dashboard-session-bar,
  .dashboard-session-copy,
  .dashboard-session-actions {
    align-items: flex-start;
    flex-direction: column;
  }

  .dashboard-session-actions {
    width: 100%;
  }

  .dashboard-refresh-button {
    width: 100%;
  }

  .dashboard-metrics {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .metric-card {
    min-height: 108px;
    padding: 19px 20px;
  }

  .metric-card strong {
    font-size: 39px;
  }

  .metric-icon {
    width: 49px;
    height: 49px;
  }

  .moderation-panel {
    padding: 18px;
    border-radius: 17px;
  }

  .panel-heading {
    flex-direction: column;
    gap: 12px;
  }

  .dashboard-request-card,
  .dashboard-approved-card {
    align-items: stretch;
    flex-direction: column;
    gap: 13px;
  }

  .dashboard-moderation-actions {
    width: 100%;
  }

  .moderation-preview {
    flex: 1;
    min-height: 42px;
  }

  .dashboard-approved-status {
    justify-items: start;
    display: flex;
    flex-wrap: wrap;
  }

  .dashboard-footer {
    flex-direction: column;
    gap: 5px;
  }
}

@media (max-width: 420px) {
  .dashboard-subtitle {
    max-width: 250px;
    font-size: 11px;
    line-height: 1.45;
  }

  .dashboard-header-actions {
    gap: 8px 14px;
  }

  .dashboard-text-link,
  .dashboard-text-button {
    font-size: 12px;
  }

  .dashboard-board {
    padding: 14px;
  }

  .dashboard-session-copy {
    gap: 8px;
  }

  .metric-card {
    gap: 12px;
    padding: 17px;
  }

  .metric-card > div > span {
    font-size: 12px;
  }

  .metric-icon {
    width: 43px;
    height: 43px;
    border-radius: 13px;
  }

  .metric-icon svg {
    width: 26px;
    height: 26px;
  }

  .moderation-panel {
    padding: 15px;
  }

  .panel-heading h2 {
    font-size: 15px;
  }

  .dashboard-request-card,
  .dashboard-approved-card {
    padding: 13px;
  }

  .dashboard-request-main {
    align-items: flex-start;
  }

  .dashboard-avatar {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    font-size: 11px;
  }

  .dashboard-name-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 5px;
  }

  .dashboard-student-name {
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
  }

  .dashboard-file-line {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .dashboard-file-name {
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
  }

  .activity-log {
    align-items: flex-start;
    padding: 17px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .dashboard-spinner {
    animation: none;
  }
}

.presentation-stage {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 14px;
  width: min(100%, 1600px);
  height: calc(100svh - 190px);
  min-height: 480px;
  margin: 0 auto;
}

.presentation-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
}

.presentation-identity,
.presentation-toolbar-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.presentation-identity > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.presentation-identity strong {
  overflow: hidden;
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.presentation-identity > div > span {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.presentation-live-badge {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  border-radius: 999px;
  color: #166534;
  background: #dcfce7;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.presentation-live-badge > span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.13);
}

.presentation-slide-status {
  flex: 0 0 auto;
  color: #475569;
  font-size: 12px;
  font-weight: 800;
}

.presentation-fullscreen {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: #4338ca;
  background: #eef2ff;
  cursor: pointer;
  font-size: 11px;
  font-weight: 800;
}

.presentation-fullscreen svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.presentation-surface {
  position: relative;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  border: 1px solid #1e293b;
  border-radius: 20px;
  background: #0f172a;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.18);
}

.presentation-frame,
.presentation-image {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #ffffff;
}

.presentation-image {
  object-fit: contain;
}

.presentation-message {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 16px;
  padding: 24px;
  color: #e2e8f0;
  background: #0f172a;
  text-align: center;
}

.presentation-message strong {
  font-size: 15px;
}

.presentation-stage:fullscreen {
  width: 100vw;
  height: 100vh;
  padding: 18px;
  border-radius: 0;
  background: #eef2ff;
}

.student-presentation-card {
  display: grid;
  gap: 15px;
  padding: 20px;
  border: 1px solid #c7d2fe;
  border-radius: 18px;
  background: #eef2ff;
}

.student-presentation-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.student-presentation-heading strong {
  display: block;
  font-size: 16px;
}

.student-presentation-heading p {
  margin: 5px 0 0;
  color: #475569;
  font-size: 11px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.student-status-badge {
  flex: 0 0 auto;
  padding: 6px 9px;
  border-radius: 999px;
  font-size: 9px;
  font-weight: 900;
  text-transform: uppercase;
}

.student-status-badge.is-live {
  color: #166534;
  background: #dcfce7;
}

.student-status-badge.is-accepted {
  color: #166534;
  background: #dcfce7;
}

.student-status-badge.is-rejected {
  color: #b91c1c;
  background: #fee2e2;
}

.student-status-badge.is-completed {
  color: #475569;
  background: #e2e8f0;
}

.slide-controls {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.slide-controls button {
  min-height: 44px;
  margin: 0;
  padding: 9px 12px;
  font-size: 12px;
}

.slide-position {
  grid-column: 1 / -1;
  color: #4338ca;
  font-size: 11px;
  font-weight: 800;
  text-align: center;
}

.live-presentation-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 20px;
  padding: 18px 20px;
  border: 1px solid #86efac;
  border-radius: 18px;
  background: #f0fdf4;
}

.live-presentation-copy {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.live-presentation-copy strong {
  font-size: 15px;
}

.live-presentation-copy span {
  overflow: hidden;
  color: #475569;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.live-presentation-card .danger-button {
  flex: 0 0 auto;
  min-height: 40px;
  margin: 0;
  padding: 9px 13px;
  font-size: 11px;
}

@media (max-width: 760px) {
  .presentation-stage {
    height: calc(100svh - 170px);
    min-height: 420px;
  }

  .presentation-toolbar {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
    padding: 13px;
  }

  .presentation-toolbar-actions {
    justify-content: space-between;
    width: 100%;
  }

  .presentation-identity {
    width: 100%;
  }

  .live-presentation-card {
    align-items: stretch;
    flex-direction: column;
  }
}
