/*
 * 教师工作台视觉覆盖层
 * 依据：/design.md 的布局、层级与组件规范；品牌主题沿用原有紫色。
 * 约束：只覆盖视觉与响应式，不改变业务 DOM、状态和事件。
 */

body.ui-teacher {
  --primary: #5b67d3;
  --primary-hover: #4b57c1;
  --primary-soft: #eef0fb;
  --primary-selected: #eef0fb;
  --primary-tinted: #eef0fb;
  --success: #237849;
  --warning: #86610a;
  --danger: #b83f55;
  --status-blue: #256ba5;
  --status-green: #237849;
  --bg: #f8fafa;
  --surface: #ffffff;
  --surface-2: #f7f8f8;
  --border: #e9edee;
  --border-2: #e9edee;
  --text: #181b1d;
  --text-2: #555d62;
  --text-weak: #737b80;
  --text-icon: #60686e;
  --topbar-h: 60px;
  --radius-sm: 4px;
  --radius: 6px;
  --radius-card: 12px;
  --shadow: 0 1px 2px rgb(16 24 40 / 3%);
  --shadow-card: 0 1px 2px rgb(16 24 40 / 3%);
  --shadow-lg: 0 8px 24px rgb(16 24 40 / 10%);
  background: var(--bg);
  color: var(--text);
  font-family: Inter, "SF Pro Text", "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  letter-spacing: 0;
  font-variant-numeric: tabular-nums;
}

body.ui-teacher ::selection {
  color: #fff;
  background: #075d61;
}

body.ui-teacher button,
body.ui-teacher input,
body.ui-teacher select,
body.ui-teacher textarea {
  font: inherit;
}

body.ui-teacher button:focus-visible,
body.ui-teacher a:focus-visible,
body.ui-teacher input:focus-visible,
body.ui-teacher select:focus-visible,
body.ui-teacher textarea:focus-visible {
  outline: 2px solid #075d61 !important;
  outline-offset: 2px;
}

body.ui-teacher ::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

body.ui-teacher ::-webkit-scrollbar-track {
  background: transparent;
}

body.ui-teacher ::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  border-radius: 999px;
  background: #cdd4d5;
  background-clip: padding-box;
}

/* Controls */
body.ui-teacher .btn {
  min-height: 36px;
  padding: 0 12px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0;
  box-shadow: none;
  transition: background-color 160ms ease-out, border-color 160ms ease-out,
    color 160ms ease-out, box-shadow 160ms ease-out, transform 120ms ease-out;
}

body.ui-teacher .btn:not(:disabled):hover {
  transform: none;
}

body.ui-teacher .btn:not(:disabled):active {
  transform: translateY(1px);
}

body.ui-teacher .btn-primary {
  border: 1px solid #064d50;
  background: #064d50;
  color: #fff;
  box-shadow: none;
}

body.ui-teacher .btn-primary:hover {
  border-color: #043f42;
  background: #043f42;
  box-shadow: none;
}

body.ui-teacher .btn-primary:active {
  border-color: #033336;
  background: #033336;
}

body.ui-teacher .btn-outline {
  border: 1px solid #dfe5e6;
  background: #fff;
  color: #303638;
}

body.ui-teacher .btn-outline:hover {
  border-color: #bfcacb;
  background: #f2f5f5;
  color: #064d50;
  box-shadow: none;
}

body.ui-teacher .btn-ghost {
  background: transparent;
  color: var(--text-2);
}

body.ui-teacher .btn-ghost:hover {
  background: #f2f5f5;
  color: var(--text);
}

body.ui-teacher .btn-danger {
  background: #b83f55;
  color: #fff;
}

body.ui-teacher .btn:disabled {
  border-color: #e9edee;
  background: #f7f8f8;
  color: #a8afb3;
  box-shadow: none;
  opacity: 1;
}

body.ui-teacher .input,
body.ui-teacher input:not([type="checkbox"]):not([type="radio"]),
body.ui-teacher select,
body.ui-teacher textarea {
  min-height: 38px;
  border: 1px solid #dfe5e6;
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  box-shadow: none;
  transition: border-color 160ms ease-out, box-shadow 160ms ease-out,
    background-color 160ms ease-out;
}

body.ui-teacher .input:hover,
body.ui-teacher input:not([type="checkbox"]):not([type="radio"]):hover,
body.ui-teacher select:hover,
body.ui-teacher textarea:hover {
  border-color: #c7d0d1;
}

body.ui-teacher .input:focus,
body.ui-teacher input:focus,
body.ui-teacher select:focus,
body.ui-teacher textarea:focus {
  border-color: #075d61 !important;
  box-shadow: 0 0 0 3px rgb(7 93 97 / 12%);
}

body.ui-teacher input:disabled,
body.ui-teacher select:disabled,
body.ui-teacher textarea:disabled {
  border-color: #e9edee;
  background: #f7f8f8;
  color: #a8afb3;
}

/* Application shell */
body.ui-teacher .shell {
  min-height: 100dvh;
  background: var(--bg);
}

body.ui-teacher .main {
  background: var(--bg);
}

body.ui-teacher .topbar {
  height: 60px;
  min-height: 60px;
  padding: 0 20px;
  gap: 16px;
  border-bottom: 1px solid #e9edee;
  background: rgb(255 255 255 / 96%);
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

body.ui-teacher .tb-context,
body.ui-teacher .tb-actions {
  gap: 8px;
}

body.ui-teacher .tb-context-copy {
  gap: 8px;
}

body.ui-teacher .tb-title {
  color: var(--text);
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.01em;
}

body.ui-teacher .tb-topic {
  color: var(--text-muted, #737b80);
  font-size: 12px;
}

body.ui-teacher .sb-toggle {
  min-width: 68px;
  height: 36px;
  padding: 0 10px;
  gap: 6px;
  border: 1px solid #dfe5e6;
  border-radius: 8px;
  background: #fff;
  color: #555d62;
  font-size: 13px;
  font-weight: 500;
  box-shadow: none;
}

body.ui-teacher .sb-toggle:hover {
  border-color: #bfcacb;
  background: #f2f5f5;
  color: #064d50;
  box-shadow: none;
  transform: none;
}

body.ui-teacher .sb-toggle-icon {
  color: #075d61;
  font-size: 16px;
  transform: none;
}

body.ui-teacher .teacher-context-switcher {
  position: relative;
  left: auto;
  top: auto;
  z-index: 92;
  width: 236px;
  flex: 0 1 236px;
  transform: none;
}

body.ui-teacher .teacher-context-trigger {
  min-width: 0;
  min-height: 42px;
  padding: 5px 34px 5px 12px;
  border: 1px solid #dfe5e6;
  border-radius: 8px;
  background: #fff;
  box-shadow: none;
}

body.ui-teacher .teacher-context-trigger:hover,
body.ui-teacher .teacher-context-trigger[aria-expanded="true"] {
  border-color: #aebbbc;
  background: #f7f8f8;
}

body.ui-teacher .teacher-context-trigger small {
  color: #737b80;
  font-size: 10px;
}

body.ui-teacher .teacher-context-trigger strong {
  color: #181b1d;
  font-size: 13px;
  font-weight: 600;
}

body.ui-teacher .teacher-context-trigger em {
  color: #737b80;
  font-size: 10px;
}

body.ui-teacher .teacher-context-chevron {
  right: 11px;
  color: #075d61;
}

body.ui-teacher .teacher-context-menu {
  top: calc(100% + 8px);
  width: 400px;
  padding: 16px;
  border: 1px solid #e1e6e7;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 8px 24px rgb(16 24 40 / 10%);
}

body.ui-teacher .teacher-context-menu-head strong {
  font-size: 14px;
  font-weight: 600;
}

body.ui-teacher .teacher-context-menu-head span {
  color: #737b80;
  font-size: 12px;
}

body.ui-teacher .teacher-context-menu label {
  font-weight: 500;
}

body.ui-teacher .teacher-context-menu select {
  min-height: 38px;
  border-radius: 8px;
}

body.ui-teacher .tb-active-classroom-slot {
  width: min(520px, 42vw);
  gap: 8px;
}

body.ui-teacher .tb-active-classroom-name {
  font-size: 13px;
  font-weight: 500;
}

body.ui-teacher .tb-active-classroom-status,
body.ui-teacher .prep-context-chip {
  border-radius: 4px;
  background: #e6f0ef;
  color: #075d61;
  font-size: 11px;
  font-weight: 500;
}

body.ui-teacher .active-classroom-return {
  border-color: #a9bebf !important;
  background: #fff !important;
  color: #064d50 !important;
  font-weight: 500 !important;
  box-shadow: none;
}

body.ui-teacher .active-classroom-return:hover {
  border-color: #075d61 !important;
  background: #e6f0ef !important;
}

body.ui-teacher .tb-return-schedule {
  min-height: 36px;
  padding: 0 14px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 500;
  box-shadow: none;
}

body.ui-teacher .tb-code {
  border: 1px solid #cbdadb;
  border-radius: 8px;
  background: #f7fafa;
  color: #555d62;
}

body.ui-teacher .tb-code b {
  color: #075d61;
  font-size: 18px;
  letter-spacing: 0.12em;
}

/* Drawer navigation */
body.ui-teacher .sb-backdrop {
  background: rgb(24 27 29 / 24%);
  transition: opacity 180ms ease-out;
}

body.ui-teacher .sidebar {
  width: 240px;
  border-right: 1px solid #e9edee;
  background: #fff;
  box-shadow: none;
  transition: transform 180ms ease-out;
}

body.ui-teacher .sidebar.open {
  box-shadow: 8px 0 24px rgb(16 24 40 / 8%);
}

body.ui-teacher .sb-brand {
  min-height: 60px;
  padding: 10px 12px;
  gap: 8px;
  border-bottom: 1px solid #f1f3f4;
}

body.ui-teacher .sb-brand img {
  height: 28px;
}

body.ui-teacher .sb-brand .brand-title {
  color: #181b1d;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0;
}

body.ui-teacher .sb-brand .brand-sub {
  color: #737b80;
  font-size: 10px;
}

body.ui-teacher .sb-close {
  min-width: 62px;
  height: 32px;
  padding: 0 8px;
  border-color: #e1e6e7;
  border-radius: 6px;
  color: #555d62;
  font-size: 11px;
  font-weight: 500;
}

body.ui-teacher .sb-close:hover {
  border-color: #bfcacb;
  background: #f2f5f5;
  color: #064d50;
}

body.ui-teacher .sb-nav {
  padding: 8px 12px 16px;
  border-top: 0;
}

body.ui-teacher .sb-nav .nav-group-title {
  padding: 18px 10px 7px;
  color: #737b80;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
}

body.ui-teacher .sb-nav a.nav-item {
  min-height: 40px;
  margin: 0 0 2px;
  padding: 4px 10px;
  gap: 8px;
  border: 0;
  border-radius: 8px;
  color: #555d62;
  font-size: 13px;
  font-weight: 400;
}

body.ui-teacher .sb-nav a.nav-item:hover {
  background: #f2f5f5;
  color: #181b1d;
}

body.ui-teacher .sb-nav a.nav-item.active {
  border: 0;
  background: #e5efed;
  color: #075d61;
  font-weight: 500;
  box-shadow: none;
}

body.ui-teacher .sb-nav a.nav-item .icon {
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
  border-radius: 6px;
  background: transparent;
  color: #60686e;
}

body.ui-teacher .sb-nav a.nav-item:hover .icon,
body.ui-teacher .sb-nav a.nav-item.active .icon {
  background: transparent;
  color: #075d61;
}

body.ui-teacher .sb-nav a.nav-item .badge-count {
  min-height: 18px;
  padding: 1px 6px;
  border-radius: 4px;
  background: #e6f0ef !important;
  color: #075d61 !important;
  font-size: 10px;
}

body.ui-teacher .sb-foot {
  min-height: 52px;
  padding: 10px 12px;
  border-top: 1px solid #f1f3f4;
  background: #fff;
}

/* Workspace home */
body.ui-teacher .stage {
  margin: 0;
  border: 0;
  border-radius: 0;
  background: #f8fafa;
  box-shadow: none;
  overflow: hidden;
}

body.ui-teacher .workspace-home {
  padding: 24px 24px 40px;
  background: #f8fafa;
}

body.ui-teacher .workspace-intro,
body.ui-teacher .teacher-identity-gate,
body.ui-teacher .workspace-sections {
  width: min(1180px, 100%);
  margin-left: auto;
  margin-right: auto;
}

body.ui-teacher .workspace-intro {
  align-items: flex-start;
  margin-bottom: 20px;
  padding: 4px 0 0;
}

body.ui-teacher .workspace-eyebrow {
  margin-bottom: 4px;
  color: #737b80;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

body.ui-teacher .workspace-intro h1 {
  color: #181b1d;
  font-size: 24px;
  line-height: 30px;
  font-weight: 600;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

body.ui-teacher .workspace-intro p {
  max-width: 64ch;
  margin-top: 4px;
  color: #737b80;
  font-size: 13px;
  line-height: 20px;
}

body.ui-teacher .teacher-identity-gate {
  margin-bottom: 16px;
}

body.ui-teacher .teacher-identity-card {
  padding: 20px;
  border: 1px solid #e3e9e9;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 1px 2px rgb(16 24 40 / 3%);
}

body.ui-teacher .teacher-identity-eyebrow {
  color: #075d61;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.06em;
}

body.ui-teacher .teacher-identity-card h1 {
  margin: 4px 0;
  font-size: 20px;
  line-height: 28px;
  font-weight: 600;
}

body.ui-teacher .teacher-identity-lead {
  max-width: 68ch;
  margin-bottom: 16px;
  color: #555d62;
  font-size: 13px;
  line-height: 20px;
}

body.ui-teacher .teacher-identity-fields {
  gap: 12px;
}

body.ui-teacher .teacher-identity-field label {
  margin-bottom: 6px;
  font-size: 12px;
  font-weight: 500;
}

body.ui-teacher .teacher-identity-field select {
  min-height: 40px;
  border-color: #dfe5e6;
  border-radius: 8px;
  font-size: 13px;
}

body.ui-teacher .teacher-identity-status {
  margin-top: 10px;
  color: #737b80;
}

body.ui-teacher .teacher-identity-actions {
  margin-top: 12px;
  padding-top: 12px;
  border-color: #f1f3f4;
}

body.ui-teacher .teacher-identity-actions .btn {
  min-height: 36px;
  padding: 0 14px;
  font-size: 13px;
}

body.ui-teacher .workspace-sections {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

body.ui-teacher .workspace-section {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  align-content: start;
  padding: 16px;
  border: 1px solid #e9edee;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 1px 2px rgb(16 24 40 / 3%);
}

body.ui-teacher .workspace-section-head {
  min-height: 42px;
  padding: 0;
}

body.ui-teacher .workspace-section-head strong {
  color: #181b1d;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0;
}

body.ui-teacher .workspace-section-head span {
  margin-top: 2px;
  color: #737b80;
  font-size: 11px;
  line-height: 16px;
}

body.ui-teacher .workspace-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

body.ui-teacher .workspace-card {
  min-height: 104px;
  padding: 14px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: #f7f8f8;
  color: #181b1d;
  box-shadow: none;
  transition: background-color 160ms ease-out, border-color 160ms ease-out,
    box-shadow 160ms ease-out;
}

body.ui-teacher .workspace-card:hover {
  border-color: #c6d5d6;
  background: #f2f5f5;
  box-shadow: none;
  transform: none;
}

body.ui-teacher .workspace-card:active {
  background: #eaf0f0;
}

body.ui-teacher .workspace-card-icon {
  width: 30px;
  height: 30px;
  margin-bottom: 12px;
  border-radius: 6px;
  background: #e6f0ef;
  color: #075d61;
  font-size: 12px;
  font-weight: 600;
}

body.ui-teacher .workspace-card strong {
  margin-bottom: 3px;
  font-size: 14px;
  font-weight: 600;
}

body.ui-teacher .workspace-card small {
  color: #737b80;
  font-size: 11px;
  line-height: 16px;
  text-wrap: pretty;
}

/* Functional panels */
body.ui-teacher .panel-overlay,
body.ui-teacher .panel-overlay.wide {
  inset: 0;
  border: 0;
  border-radius: 0;
  background: #f8fafa;
  box-shadow: none;
}

body.ui-teacher .panel-overlay.on {
  animation: teacherPanelIn 160ms ease-out;
}

@keyframes teacherPanelIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: none; }
}

body.ui-teacher .po-head {
  height: 56px;
  min-height: 56px;
  padding: 0 20px;
  border-bottom: 1px solid #e9edee;
  background: #fff;
}

body.ui-teacher .po-head .title {
  color: #181b1d;
  font-size: 16px;
  font-weight: 600;
}

body.ui-teacher .po-head .close {
  width: auto;
  min-width: 88px;
  height: 34px;
  padding: 0 10px;
  border: 1px solid #dfe5e6;
  border-radius: 6px;
  background: #fff;
  color: #555d62;
  font-size: 12px;
  font-weight: 500;
}

body.ui-teacher .po-head .close:hover {
  border-color: #bfcacb;
  background: #f2f5f5;
  color: #064d50;
}

body.ui-teacher .po-body {
  padding: 20px;
  background: #f8fafa;
}

body.ui-teacher .row,
body.ui-teacher .ctrl-section,
body.ui-teacher .card,
body.ui-teacher .panel,
body.ui-teacher .stat-card {
  border: 1px solid #e9edee;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 1px 2px rgb(16 24 40 / 3%);
}

body.ui-teacher .row {
  padding: 12px;
  border-radius: 8px;
}

body.ui-teacher .row:hover {
  border-color: #c6d5d6;
  background: #f7fafa;
  box-shadow: none;
}

body.ui-teacher .row.active {
  border-color: #9db9ba;
  background: #e6f0ef;
}

body.ui-teacher .empty,
body.ui-teacher .prep-region-empty {
  color: #737b80;
  font-size: 13px;
}

body.ui-teacher .modal-overlay {
  background: rgb(24 27 29 / 34%);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

body.ui-teacher .modal {
  padding: 20px;
  border: 1px solid #e1e6e7;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 8px 24px rgb(16 24 40 / 10%);
}

body.ui-teacher .modal h3 {
  font-size: 16px;
  font-weight: 600;
}

/* Course schedule and canvas library */
body.ui-teacher .prep-workspace-shell {
  width: min(1320px, 100%);
}

body.ui-teacher .prep-workspace-toolbar {
  gap: 16px;
  margin-bottom: 16px;
}

body.ui-teacher .prep-workspace-title h2 {
  color: #181b1d;
  font-size: 22px;
  line-height: 30px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

body.ui-teacher .prep-workspace-title p {
  max-width: 68ch;
  margin-top: 3px;
  color: #737b80;
  font-size: 12px;
  line-height: 18px;
}

body.ui-teacher .prep-workspace-grid {
  grid-template-columns: minmax(0, 1.45fr) minmax(340px, 0.8fr);
  gap: 12px;
}

body.ui-teacher .prep-workspace-pane {
  border: 1px solid #e9edee;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 1px 2px rgb(16 24 40 / 3%);
}

body.ui-teacher .prep-pane-head {
  min-height: 60px;
  padding: 12px 16px;
  border-bottom: 1px solid #f1f3f4;
  background: #fff;
}

body.ui-teacher .prep-pane-title strong {
  color: #181b1d;
  font-size: 15px;
  font-weight: 600;
}

body.ui-teacher .prep-pane-title span {
  margin-top: 2px;
  color: #737b80;
  font-size: 11px;
}

body.ui-teacher .prep-pane-body {
  padding: 12px;
}

body.ui-teacher .prep-library-tabs,
body.ui-teacher .resource-tabs,
body.ui-teacher .kb-scope-switch {
  gap: 2px;
  padding: 3px;
  border: 0;
  border-radius: 8px;
  background: #f1f3f4;
}

body.ui-teacher .prep-library-tab,
body.ui-teacher .resource-tab,
body.ui-teacher .kb-scope-switch button {
  min-height: 32px;
  border-radius: 6px;
  color: #555d62;
  font-size: 12px;
  font-weight: 500;
}

body.ui-teacher .prep-library-tab.active,
body.ui-teacher .resource-tab.active,
body.ui-teacher .kb-scope-switch button.active {
  background: #fff;
  color: #075d61;
  box-shadow: 0 2px 5px rgb(16 24 40 / 8%);
}

body.ui-teacher .schedule-head {
  margin-bottom: 14px;
}

body.ui-teacher .schedule-day-title {
  font-size: 20px;
  line-height: 28px;
  font-weight: 600;
}

body.ui-teacher .schedule-day-subtitle,
body.ui-teacher .schedule-meta {
  color: #737b80;
}

body.ui-teacher .schedule-timeline {
  gap: 8px;
}

body.ui-teacher .schedule-timeline::before {
  background: #dbe4e4;
}

body.ui-teacher .schedule-item {
  min-height: 96px;
  padding: 14px 16px;
  gap: 12px;
  border: 1px solid #e9edee;
  border-radius: 10px;
  background: #fff;
  box-shadow: none;
}

body.ui-teacher .schedule-item:hover {
  border-color: #c6d5d6;
  background: #fdfefe;
}

body.ui-teacher .schedule-time {
  color: #303638;
  font-weight: 600;
}

body.ui-teacher .schedule-dot {
  border-width: 3px;
  background: #075d61;
  box-shadow: 0 0 0 2px rgb(7 93 97 / 16%);
}

body.ui-teacher .schedule-copy strong {
  color: #181b1d;
  font-size: 14px;
  font-weight: 600;
}

body.ui-teacher .schedule-source {
  min-height: 20px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 500;
}

body.ui-teacher .schedule-source.cidp {
  background: #e6f0ef;
  color: #075d61;
}

body.ui-teacher .schedule-source.local {
  background: #f1f3f4;
  color: #60686e;
}

body.ui-teacher .schedule-sync-warning {
  border-color: #eadba9;
  border-radius: 8px;
  background: #fff9e8;
  color: #6e5515;
}

body.ui-teacher .lesson-canvas-link {
  border-radius: 8px;
  background: #f7f8f8;
}

body.ui-teacher .lesson-canvas-link label {
  color: #737b80;
  font-weight: 500;
  letter-spacing: 0;
}

body.ui-teacher .lesson-canvas-select {
  height: 36px;
  border-color: #dfe5e6;
  border-radius: 8px;
}

body.ui-teacher .lesson-canvas-state {
  border-radius: 4px;
  background: #fff3c8;
  color: #86610a;
  font-weight: 500;
}

body.ui-teacher .lesson-canvas-state.ready {
  background: #dcf8e7;
  color: #237849;
}

body.ui-teacher .prep-library-list {
  gap: 8px;
}

body.ui-teacher .prep-library-card,
body.ui-teacher .resource-card,
body.ui-teacher .knowledge-card {
  border: 1px solid #e9edee;
  border-radius: 10px;
  background: #fff;
  box-shadow: none;
}

body.ui-teacher .prep-library-card {
  padding: 12px;
}

body.ui-teacher .prep-library-card:hover,
body.ui-teacher .resource-card:hover,
body.ui-teacher .knowledge-card:hover {
  border-color: #c6d5d6;
  box-shadow: none;
  transform: none;
}

body.ui-teacher .prep-library-card-icon,
body.ui-teacher .resource-file-icon,
body.ui-teacher .prep-avatar,
body.ui-teacher .picker-space-icon {
  border-radius: 6px;
  background: #e6f0ef;
  color: #075d61;
}

body.ui-teacher .prep-library-card-copy strong,
body.ui-teacher .resource-card-title {
  color: #181b1d;
  font-size: 13px;
  font-weight: 600;
}

body.ui-teacher .prep-library-card-copy small,
body.ui-teacher .resource-card-desc,
body.ui-teacher .resource-card-meta {
  color: #737b80;
}

body.ui-teacher .prep-library-card-actions {
  border-top-color: #f1f3f4;
}

/* Control and resource modules */
body.ui-teacher .ctrl-section {
  padding: 16px;
}

body.ui-teacher .ctrl-section-title {
  color: #737b80;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
}

body.ui-teacher .ctrl-mode-btn {
  min-height: 48px;
  border: 1px solid #e9edee;
  border-radius: 8px;
  background: #fff;
  color: #555d62;
}

body.ui-teacher .ctrl-mode-btn:hover {
  border-color: #bfcacb;
  background: #f2f5f5;
  color: #064d50;
}

body.ui-teacher .ctrl-mode-btn.active {
  border-color: #9db9ba;
  background: #e6f0ef;
  color: #075d61;
  box-shadow: none;
}

body.ui-teacher .ctrl-toggle.on {
  background: #075d61;
}

body.ui-teacher .ctrl-diag,
body.ui-teacher .resource-hint,
body.ui-teacher #body-record > div:first-child,
body.ui-teacher .kb-browse-grant-zone,
body.ui-teacher .resource-file-grant-bar,
body.ui-teacher .picker-hero {
  border-color: #e1e8e8 !important;
  border-radius: 10px;
  background: #f7fafa !important;
  box-shadow: none;
}

body.ui-teacher .picker-hero-icon {
  border-radius: 8px;
  background: #075d61;
  box-shadow: none;
}

body.ui-teacher .resource-grid {
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 12px;
}

body.ui-teacher .resource-card {
  min-height: 156px;
  padding: 16px;
}

/* Status colors */
body.ui-teacher .dot.g { background: #237849; }
body.ui-teacher .dot.o { background: #86610a; }
body.ui-teacher .dot.r { background: #b83f55; }

body.ui-teacher .av-dot {
  border-radius: 4px;
  background: #f1f3f4;
  color: #737b80;
}

body.ui-teacher .av-dot.on {
  background: #e6f0ef;
  color: #075d61;
}

body.ui-teacher .code-clickable:hover {
  background: #e6f0ef;
  color: #075d61;
}

/* Responsive */
@media (max-width: 1199px) {
  body.ui-teacher .workspace-sections {
    grid-template-columns: 1fr;
  }

  body.ui-teacher .workspace-section {
    grid-template-columns: 150px minmax(0, 1fr);
  }

  body.ui-teacher .prep-workspace-grid {
    grid-template-columns: 1fr;
  }

  body.ui-teacher .prep-library-list {
    max-height: none;
  }

  body.ui-teacher .teacher-context-switcher {
    width: 210px;
    flex-basis: 210px;
  }
}

@media (max-width: 820px) {
  body.ui-teacher .topbar {
    padding: 0 12px;
  }

  body.ui-teacher .teacher-context-switcher {
    width: min(210px, 36vw);
    flex-basis: min(210px, 36vw);
  }

  body.ui-teacher .tb-context-copy {
    display: none;
  }

  body.ui-teacher .workspace-home {
    padding: 20px 16px 32px;
  }

  body.ui-teacher .workspace-section {
    grid-template-columns: 1fr;
  }

  body.ui-teacher .po-body {
    padding: 16px;
  }
}

@media (max-width: 640px) {
  body.ui-teacher .topbar {
    min-height: 60px;
    grid-template-columns: minmax(0, 1fr) auto;
    padding: 0 8px;
    gap: 6px;
  }

  body.ui-teacher .sb-toggle {
    min-width: 44px;
    width: 44px;
    height: 44px;
    padding: 0;
  }

  body.ui-teacher .sb-toggle > span:last-child {
    display: none;
  }

  body.ui-teacher .teacher-context-switcher {
    width: min(190px, calc(100vw - 120px));
    flex-basis: min(190px, calc(100vw - 120px));
  }

  body.ui-teacher .teacher-context-trigger {
    min-height: 44px;
    padding-left: 10px;
  }

  body.ui-teacher .teacher-context-trigger small,
  body.ui-teacher .teacher-context-trigger em {
    display: none;
  }

  body.ui-teacher .teacher-context-menu {
    position: fixed;
    left: 8px;
    top: 68px;
    width: calc(100vw - 16px);
  }

  body.ui-teacher .sidebar {
    width: min(88vw, 300px);
  }

  body.ui-teacher .workspace-home {
    padding: 18px 12px 28px;
  }

  body.ui-teacher .workspace-intro {
    margin-bottom: 14px;
  }

  body.ui-teacher .workspace-intro h1 {
    font-size: 22px;
    line-height: 28px;
  }

  body.ui-teacher .teacher-identity-card,
  body.ui-teacher .workspace-section {
    padding: 14px;
  }

  body.ui-teacher .teacher-identity-fields,
  body.ui-teacher .workspace-grid {
    grid-template-columns: 1fr;
  }

  body.ui-teacher .workspace-card {
    min-height: 92px;
  }

  body.ui-teacher .po-head {
    padding: 0 12px;
  }

  body.ui-teacher .po-body {
    padding: 12px;
  }

  body.ui-teacher .prep-workspace-toolbar,
  body.ui-teacher .prep-pane-head {
    align-items: stretch;
    flex-direction: column;
  }

  body.ui-teacher .prep-workspace-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  body.ui-teacher .prep-workspace-actions .btn,
  body.ui-teacher .schedule-actions .btn {
    min-height: 44px;
    justify-content: center;
  }

  body.ui-teacher .modal {
    width: calc(100% - 24px);
    padding: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.ui-teacher *,
  body.ui-teacher *::before,
  body.ui-teacher *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/*
 * 可读性校正：恢复品牌紫色，并提升 Logo、字号与呼吸感。
 * 这组规则放在文件末尾，确保只调整视觉，不改变任何结构或行为。
 */
body.ui-teacher {
  font-size: 14px;
}

body.ui-teacher ::selection,
body.ui-teacher .btn-primary,
body.ui-teacher .picker-hero-icon,
body.ui-teacher .ctrl-toggle.on,
body.ui-teacher .schedule-dot {
  background-color: #5b67d3;
}

body.ui-teacher button:focus-visible,
body.ui-teacher a:focus-visible,
body.ui-teacher input:focus-visible,
body.ui-teacher select:focus-visible,
body.ui-teacher textarea:focus-visible {
  outline-color: #5b67d3 !important;
}

body.ui-teacher .btn-primary {
  border-color: #5b67d3;
}

body.ui-teacher .btn-primary:hover {
  border-color: #4b57c1;
  background: #4b57c1;
}

body.ui-teacher .btn-primary:active {
  border-color: #3f49ac;
  background: #3f49ac;
}

body.ui-teacher .input:focus,
body.ui-teacher input:focus,
body.ui-teacher select:focus,
body.ui-teacher textarea:focus {
  border-color: #5b67d3 !important;
  box-shadow: 0 0 0 3px rgb(91 103 211 / 14%);
}

body.ui-teacher .sb-toggle-icon,
body.ui-teacher .teacher-context-chevron,
body.ui-teacher .tb-code b,
body.ui-teacher .sb-nav a.nav-item.active,
body.ui-teacher .sb-nav a.nav-item:hover .icon,
body.ui-teacher .sb-nav a.nav-item.active .icon,
body.ui-teacher .sb-nav a.nav-item .badge-count,
body.ui-teacher .teacher-identity-eyebrow,
body.ui-teacher .workspace-card-icon,
body.ui-teacher .prep-library-tab.active,
body.ui-teacher .resource-tab.active,
body.ui-teacher .kb-scope-switch button.active,
body.ui-teacher .schedule-source.cidp,
body.ui-teacher .prep-library-card-icon,
body.ui-teacher .resource-file-icon,
body.ui-teacher .prep-avatar,
body.ui-teacher .picker-space-icon,
body.ui-teacher .ctrl-mode-btn.active,
body.ui-teacher .av-dot.on,
body.ui-teacher .code-clickable:hover {
  color: #5b67d3 !important;
}

body.ui-teacher .tb-active-classroom-status,
body.ui-teacher .prep-context-chip,
body.ui-teacher .active-classroom-return:hover,
body.ui-teacher .sb-nav a.nav-item.active,
body.ui-teacher .sb-nav a.nav-item .badge-count,
body.ui-teacher .workspace-card-icon,
body.ui-teacher .schedule-source.cidp,
body.ui-teacher .prep-library-card-icon,
body.ui-teacher .resource-file-icon,
body.ui-teacher .prep-avatar,
body.ui-teacher .picker-space-icon,
body.ui-teacher .ctrl-mode-btn.active,
body.ui-teacher .av-dot.on,
body.ui-teacher .code-clickable:hover {
  background: #eef0fb !important;
}

body.ui-teacher .active-classroom-return {
  border-color: #bbc0eb !important;
  color: #4b57c1 !important;
}

body.ui-teacher .active-classroom-return:hover,
body.ui-teacher .ctrl-mode-btn.active {
  border-color: #9fa7e2 !important;
}

body.ui-teacher .teacher-context-trigger:hover,
body.ui-teacher .teacher-context-trigger[aria-expanded="true"],
body.ui-teacher .workspace-card:hover,
body.ui-teacher .schedule-item:hover,
body.ui-teacher .prep-library-card:hover,
body.ui-teacher .resource-card:hover,
body.ui-teacher .knowledge-card:hover,
body.ui-teacher .row:hover {
  border-color: #c9cdf0;
}

body.ui-teacher .btn-outline:hover,
body.ui-teacher .btn-ghost:hover,
body.ui-teacher .sb-toggle:hover,
body.ui-teacher .sb-close:hover,
body.ui-teacher .sb-nav a.nav-item:hover,
body.ui-teacher .po-head .close:hover,
body.ui-teacher .ctrl-mode-btn:hover {
  background: #f6f6fc;
  color: #4b57c1;
}

body.ui-teacher .btn {
  min-height: 40px;
  padding-inline: 16px;
  font-size: 14px;
}

body.ui-teacher .btn-sm {
  min-height: 36px;
  padding-inline: 13px;
  font-size: 13px;
}

body.ui-teacher .input,
body.ui-teacher input:not([type="checkbox"]):not([type="radio"]),
body.ui-teacher select,
body.ui-teacher textarea {
  min-height: 42px;
  font-size: 14px;
}

body.ui-teacher .topbar {
  height: 68px;
  min-height: 68px;
  padding-inline: 24px;
  gap: 20px;
}

body.ui-teacher .tb-context,
body.ui-teacher .tb-actions {
  gap: 12px;
}

body.ui-teacher .tb-title {
  font-size: 18px;
  font-weight: 600;
}

body.ui-teacher .tb-topic {
  font-size: 14px;
}

body.ui-teacher .sb-toggle {
  min-width: 76px;
  height: 40px;
  padding-inline: 12px;
  font-size: 14px;
}

body.ui-teacher .teacher-context-switcher {
  width: 268px;
  flex-basis: 268px;
}

body.ui-teacher .teacher-context-trigger {
  min-height: 50px;
  padding: 7px 38px 7px 14px;
}

body.ui-teacher .teacher-context-trigger small,
body.ui-teacher .teacher-context-trigger em {
  font-size: 11px;
}

body.ui-teacher .teacher-context-trigger strong {
  font-size: 15px;
}

body.ui-teacher .sidebar {
  width: 264px;
}

body.ui-teacher .sb-brand {
  min-height: 82px;
  padding: 12px 16px;
  gap: 12px;
}

body.ui-teacher .sb-brand img {
  width: auto;
  height: 48px;
}

body.ui-teacher .sb-brand .brand-title {
  font-size: 20px;
  line-height: 28px;
}

body.ui-teacher .sb-brand .brand-sub {
  font-size: 12px;
  line-height: 18px;
}

body.ui-teacher .sb-close {
  min-width: 68px;
  height: 36px;
  font-size: 12px;
}

body.ui-teacher .sb-nav {
  padding: 10px 14px 20px;
}

body.ui-teacher .sb-nav .nav-group-title {
  padding: 22px 10px 8px;
  font-size: 12px;
}

body.ui-teacher .sb-nav a.nav-item {
  min-height: 46px;
  margin-bottom: 4px;
  padding: 7px 10px;
  gap: 10px;
  font-size: 14px;
}

body.ui-teacher .sb-nav a.nav-item .icon {
  width: 32px;
  height: 32px;
  flex-basis: 32px;
}

body.ui-teacher .workspace-home {
  padding: 34px 32px 52px;
}

body.ui-teacher .workspace-intro,
body.ui-teacher .teacher-identity-gate,
body.ui-teacher .workspace-sections {
  width: min(1280px, 100%);
}

body.ui-teacher .workspace-intro {
  margin-bottom: 26px;
  padding-top: 8px;
}

body.ui-teacher .workspace-eyebrow {
  margin-bottom: 7px;
  font-size: 12px;
}

body.ui-teacher .workspace-intro h1 {
  font-size: 30px;
  line-height: 38px;
}

body.ui-teacher .workspace-intro p {
  margin-top: 7px;
  font-size: 15px;
  line-height: 24px;
}

body.ui-teacher .teacher-identity-gate {
  margin-bottom: 22px;
}

body.ui-teacher .teacher-identity-card {
  padding: 26px;
}

body.ui-teacher .teacher-identity-eyebrow {
  font-size: 12px;
}

body.ui-teacher .teacher-identity-card h1 {
  margin: 7px 0 5px;
  font-size: 25px;
  line-height: 32px;
}

body.ui-teacher .teacher-identity-lead {
  margin-bottom: 22px;
  font-size: 15px;
  line-height: 24px;
}

body.ui-teacher .teacher-identity-fields {
  gap: 18px;
}

body.ui-teacher .teacher-identity-field label {
  margin-bottom: 8px;
  font-size: 14px;
}

body.ui-teacher .teacher-identity-field select {
  min-height: 46px;
  font-size: 15px;
}

body.ui-teacher .teacher-identity-status {
  margin-top: 14px;
  font-size: 13px;
}

body.ui-teacher .teacher-identity-actions {
  margin-top: 18px;
  padding-top: 16px;
  gap: 12px;
}

body.ui-teacher .teacher-identity-actions .btn {
  min-height: 42px;
  padding-inline: 18px;
  font-size: 14px;
}

body.ui-teacher .workspace-sections {
  gap: 18px;
}

body.ui-teacher .workspace-section {
  gap: 16px;
  padding: 22px;
}

body.ui-teacher .workspace-section-head {
  min-height: 50px;
}

body.ui-teacher .workspace-section-head strong {
  font-size: 16px;
}

body.ui-teacher .workspace-section-head span {
  margin-top: 4px;
  font-size: 13px;
  line-height: 19px;
}

body.ui-teacher .workspace-grid {
  gap: 12px;
}

body.ui-teacher .workspace-card {
  min-height: 128px;
  padding: 18px;
}

body.ui-teacher .workspace-card-icon {
  width: 38px;
  height: 38px;
  margin-bottom: 16px;
  font-size: 14px;
}

body.ui-teacher .workspace-card strong {
  margin-bottom: 6px;
  font-size: 16px;
}

body.ui-teacher .workspace-card small {
  font-size: 13px;
  line-height: 20px;
}

body.ui-teacher .po-head {
  height: 64px;
  min-height: 64px;
  padding-inline: 24px;
}

body.ui-teacher .po-head .title {
  font-size: 18px;
}

body.ui-teacher .po-body {
  padding: 26px;
}

body.ui-teacher .prep-workspace-toolbar {
  gap: 22px;
  margin-bottom: 22px;
}

body.ui-teacher .prep-workspace-title h2 {
  font-size: 28px;
  line-height: 36px;
}

body.ui-teacher .prep-workspace-title p {
  margin-top: 6px;
  font-size: 14px;
  line-height: 22px;
}

body.ui-teacher .prep-workspace-grid {
  grid-template-columns: minmax(0, 1.3fr) minmax(400px, 0.9fr);
  gap: 18px;
}

body.ui-teacher .prep-pane-head {
  min-height: 72px;
  padding: 16px 20px;
}

body.ui-teacher .prep-pane-title strong {
  font-size: 17px;
}

body.ui-teacher .prep-pane-title span {
  margin-top: 4px;
  font-size: 13px;
}

body.ui-teacher .prep-pane-body {
  padding: 18px;
}

body.ui-teacher #prep-library-region .prep-pane-head {
  align-items: stretch;
  flex-direction: column;
  gap: 12px;
}

body.ui-teacher #prep-library-region .prep-library-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  width: 100%;
}

body.ui-teacher #prep-library-region .prep-library-tab {
  white-space: nowrap;
}

body.ui-teacher .prep-library-tab,
body.ui-teacher .resource-tab,
body.ui-teacher .kb-scope-switch button {
  min-height: 36px;
  padding-inline: 15px;
  font-size: 13px;
}

body.ui-teacher .schedule-day-title {
  font-size: 24px;
  line-height: 32px;
}

body.ui-teacher .schedule-day-subtitle,
body.ui-teacher .schedule-meta {
  font-size: 13px;
}

body.ui-teacher .schedule-timeline {
  gap: 12px;
}

body.ui-teacher .schedule-item {
  min-height: 112px;
  padding: 18px 20px;
  gap: 18px;
}

body.ui-teacher .schedule-copy strong {
  font-size: 16px;
}

body.ui-teacher .prep-library-list {
  gap: 12px;
}

body.ui-teacher .prep-library-card {
  padding: 16px;
}

body.ui-teacher .prep-library-card-copy strong,
body.ui-teacher .resource-card-title {
  font-size: 15px;
}

body.ui-teacher .prep-library-card-copy small,
body.ui-teacher .resource-card-desc,
body.ui-teacher .resource-card-meta {
  font-size: 12px;
  line-height: 19px;
}

@media (max-width: 1199px) {
  body.ui-teacher .prep-workspace-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  body.ui-teacher .topbar {
    height: 64px;
    min-height: 64px;
    padding-inline: 12px;
  }

  body.ui-teacher .teacher-context-switcher {
    width: min(230px, 38vw);
    flex-basis: min(230px, 38vw);
  }

  body.ui-teacher .workspace-home {
    padding: 26px 18px 40px;
  }

  body.ui-teacher .workspace-section {
    padding: 18px;
  }

  body.ui-teacher .prep-workspace-grid {
    grid-template-columns: 1fr;
  }

  body.ui-teacher .po-body {
    padding: 18px;
  }
}

@media (max-width: 640px) {
  body.ui-teacher .topbar {
    height: 60px;
    min-height: 60px;
    padding-inline: 8px;
  }

  body.ui-teacher .sb-toggle {
    min-width: 44px;
    width: 44px;
    height: 44px;
    padding: 0;
  }

  body.ui-teacher .teacher-context-switcher {
    width: min(194px, calc(100vw - 118px));
    flex-basis: min(194px, calc(100vw - 118px));
  }

  body.ui-teacher .teacher-context-trigger {
    min-height: 44px;
    padding-block: 5px;
  }

  body.ui-teacher .sidebar {
    width: min(90vw, 320px);
  }

  body.ui-teacher .sb-brand {
    min-height: 72px;
  }

  body.ui-teacher .sb-brand img {
    height: 40px;
  }

  body.ui-teacher .workspace-home {
    padding: 22px 14px 34px;
  }

  body.ui-teacher .workspace-intro h1 {
    font-size: 26px;
    line-height: 34px;
  }

  body.ui-teacher .workspace-intro p {
    font-size: 14px;
    line-height: 22px;
  }

  body.ui-teacher .teacher-identity-card,
  body.ui-teacher .workspace-section {
    padding: 16px;
  }

  body.ui-teacher .workspace-card {
    min-height: 108px;
    padding: 16px;
  }

  body.ui-teacher .po-head {
    height: 58px;
    min-height: 58px;
    padding-inline: 12px;
  }

  body.ui-teacher .po-body {
    padding: 14px;
  }

  body.ui-teacher .prep-workspace-title h2 {
    font-size: 24px;
    line-height: 32px;
  }
}

/*
 * v3 —— 参考 CIDP 首页重排教师工作台。
 * 顶栏承载品牌与账号；首页引导居中；功能分组纵向排列、组内横向排列。
 */
body.ui-teacher .sb-foot {
  display: none;
}

body.ui-teacher .topbar {
  grid-template-columns: minmax(0, 1fr) auto;
  overflow: visible;
}

body.ui-teacher .topbar-brand {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 10px;
  min-width: 150px;
}

body.ui-teacher .topbar-brand img {
  display: block;
  width: 42px;
  height: 42px;
  object-fit: contain;
}

body.ui-teacher .topbar-brand-copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 1px;
}

body.ui-teacher .topbar-brand-copy strong {
  color: #202842;
  font-size: 17px;
  font-weight: 750;
  line-height: 21px;
  letter-spacing: -0.02em;
}

body.ui-teacher .topbar-brand-copy small {
  color: #7a8297;
  font-size: 10px;
  line-height: 14px;
  white-space: nowrap;
}

body.ui-teacher .teacher-account {
  position: relative;
  z-index: 140;
  flex: 0 0 auto;
}

body.ui-teacher .teacher-account summary {
  list-style: none;
}

body.ui-teacher .teacher-account summary::-webkit-details-marker {
  display: none;
}

body.ui-teacher .teacher-account-trigger {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 176px;
  min-height: 46px;
  padding: 5px 10px 5px 6px;
  border: 1px solid #e1e4f3;
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  user-select: none;
  transition: border-color 180ms ease, background-color 180ms ease,
    box-shadow 180ms ease, transform 120ms ease;
}

body.ui-teacher .teacher-account-trigger:hover,
body.ui-teacher .teacher-account[open] .teacher-account-trigger {
  border-color: #c9cdf0;
  background: #fafaff;
  box-shadow: 0 8px 22px rgb(63 73 172 / 10%);
}

body.ui-teacher .teacher-account-trigger:active {
  transform: translateY(1px);
}

body.ui-teacher .teacher-account-avatar {
  display: inline-grid;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  place-items: center;
  border-radius: 10px;
  background: #eef0fb;
  color: #4b57c1;
  font-size: 14px;
  font-weight: 750;
}

body.ui-teacher .teacher-account-copy {
  display: flex;
  min-width: 0;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 1px;
  text-align: left;
}

body.ui-teacher .teacher-account-copy strong {
  overflow: hidden;
  max-width: 140px;
  color: #202842;
  font-size: 12px;
  font-weight: 650;
  line-height: 17px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.ui-teacher .teacher-account-copy small {
  color: #8a91a5;
  font-size: 10px;
  line-height: 14px;
}

body.ui-teacher .teacher-account-chevron {
  color: #7e86a0;
  font-size: 12px;
  transition: transform 180ms ease;
}

body.ui-teacher .teacher-account[open] .teacher-account-chevron {
  transform: rotate(180deg);
}

body.ui-teacher .teacher-account-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 268px;
  padding: 12px;
  border: 1px solid #e1e4f3;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 20px 48px rgb(34 43 91 / 16%);
}

body.ui-teacher .teacher-account-menu-head {
  padding: 8px 8px 14px;
  border-bottom: 1px solid #eff0f7;
}

body.ui-teacher .teacher-account-menu-head small,
body.ui-teacher .teacher-account-menu-head strong,
body.ui-teacher .teacher-account-menu-head span {
  display: block;
}

body.ui-teacher .teacher-account-menu-head small {
  color: #8a91a5;
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.08em;
}

body.ui-teacher .teacher-account-menu-head strong {
  margin-top: 5px;
  color: #202842;
  font-size: 14px;
  font-weight: 700;
}

body.ui-teacher .teacher-account-menu-head span {
  margin-top: 4px;
  color: #737b8f;
  font-size: 11px;
  line-height: 17px;
}

body.ui-teacher .teacher-account-logout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 40px;
  margin-top: 8px;
  padding: 0 10px;
  border-radius: 8px;
  color: #b83f55;
  font-size: 13px;
  font-weight: 650;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 160ms ease, color 160ms ease;
}

body.ui-teacher .teacher-account-logout::after {
  content: "退出";
  color: #c78a97;
  font-size: 10px;
  font-weight: 500;
}

body.ui-teacher .teacher-account-logout:hover {
  background: #fff2f4;
  color: #9f2f45;
}

body.ui-teacher .workspace-home {
  background:
    radial-gradient(circle at 50% -120px, rgb(91 103 211 / 9%), transparent 360px),
    #f8f9fd;
}

body.ui-teacher .workspace-intro {
  display: flex;
  align-items: center;
  justify-content: center;
  width: min(820px, 100%);
  margin-bottom: 34px;
  padding: 22px 0 30px;
  border-bottom: 1px solid #e4e6f3;
  text-align: center;
}

body.ui-teacher .workspace-intro > div {
  width: 100%;
}

body.ui-teacher .workspace-eyebrow {
  margin-bottom: 10px;
  color: #5b67d3;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
}

body.ui-teacher .workspace-intro h1 {
  font-size: clamp(32px, 4vw, 46px);
  line-height: 1.14;
  font-weight: 750;
  letter-spacing: -0.045em;
}

body.ui-teacher .workspace-intro p {
  max-width: 650px;
  margin: 12px auto 0;
  color: #71798d;
  font-size: 16px;
  line-height: 26px;
}

body.ui-teacher .workspace-sections {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 18px;
  width: min(1180px, 100%);
}

body.ui-teacher .workspace-section {
  display: grid;
  grid-template-columns: minmax(170px, 0.28fr) minmax(0, 1fr);
  gap: 30px;
  align-items: stretch;
  padding: 24px;
  border-color: #e4e6f0;
  border-radius: 16px;
  box-shadow: 0 8px 26px rgb(39 49 92 / 5%);
}

body.ui-teacher .workspace-section-head {
  display: flex;
  min-height: 0;
  flex-direction: column;
  justify-content: center;
  padding: 4px 8px 4px 2px;
}

body.ui-teacher .workspace-section-head strong {
  color: #202842;
  font-size: 18px;
  line-height: 26px;
}

body.ui-teacher .workspace-section-head span {
  max-width: 18ch;
  margin-top: 6px;
  color: #7b8294;
  font-size: 13px;
  line-height: 20px;
}

body.ui-teacher .workspace-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

body.ui-teacher .workspace-card {
  min-height: 142px;
  padding: 18px;
  border-color: transparent;
  border-radius: 12px;
  background: #f7f7fc;
}

body.ui-teacher .workspace-card:hover {
  border-color: #c9cdf0;
  background: #f3f3fc;
  box-shadow: 0 10px 22px rgb(63 73 172 / 8%);
  transform: translateY(-2px);
}

body.ui-teacher .workspace-card:active {
  transform: translateY(0);
}

body.ui-teacher .workspace-card-icon {
  width: 40px;
  height: 40px;
  margin-bottom: 18px;
  border-radius: 10px;
}

@media (max-width: 1120px) {
  body.ui-teacher .topbar-brand-copy {
    display: none;
  }

  body.ui-teacher .topbar-brand {
    min-width: 42px;
  }

  body.ui-teacher .workspace-section {
    grid-template-columns: 150px minmax(0, 1fr);
  }

  body.ui-teacher .workspace-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 820px) {
  body.ui-teacher .topbar-brand {
    display: none;
  }

  body.ui-teacher .teacher-account-trigger {
    min-width: 44px;
    width: 44px;
    padding: 5px;
  }

  body.ui-teacher .teacher-account-copy,
  body.ui-teacher .teacher-account-chevron {
    display: none;
  }

  body.ui-teacher .workspace-intro {
    margin-bottom: 24px;
    padding: 12px 0 24px;
  }

  body.ui-teacher .workspace-section {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  body.ui-teacher .workspace-section-head {
    padding: 0;
  }

  body.ui-teacher .workspace-section-head span {
    max-width: none;
  }
}

@media (max-width: 640px) {
  body.ui-teacher .workspace-intro {
    align-items: center;
    text-align: center;
  }

  body.ui-teacher .workspace-intro h1 {
    font-size: 30px;
    line-height: 38px;
  }

  body.ui-teacher .workspace-intro p {
    font-size: 14px;
    line-height: 22px;
  }

  body.ui-teacher .workspace-grid {
    grid-template-columns: 1fr;
  }

  body.ui-teacher .workspace-section {
    padding: 18px;
  }

  body.ui-teacher .workspace-card {
    min-height: 118px;
  }

  body.ui-teacher .teacher-account-menu {
    position: fixed;
    top: 66px;
    right: 8px;
    width: min(268px, calc(100vw - 16px));
  }
}
