* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
  background: #f4f6fa;
  color: #1a2233;
  min-height: 100vh;
}

.topbar {
  background: #16305c;
  color: #fff;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.topbar .brand { font-size: 18px; font-weight: 700; letter-spacing: 1px; }
.topbar .brand span { color: #e8b64c; }
.topbar .user { font-size: 14px; opacity: .9; }
.topbar button {
  margin-left: 12px; padding: 5px 14px; border: 1px solid rgba(255,255,255,.4);
  background: transparent; color: #fff; border-radius: 6px; cursor: pointer; font-size: 13px;
}
.topbar button:hover { background: rgba(255,255,255,.12); }

.container { max-width: 860px; margin: 0 auto; padding: 32px 20px; }

/* 居中卡片（首页/登录） */
.center-wrap {
  min-height: 100vh; display: flex; flex-direction: column;
  align-items: center; justify-content: center; padding: 20px;
}
.hero-title { font-size: 30px; font-weight: 800; color: #16305c; margin-bottom: 6px; }
.hero-title span { color: #c9962e; }
.hero-sub { color: #8a93a6; font-size: 14px; margin-bottom: 40px; }

.card {
  background: #fff; border-radius: 14px; padding: 28px;
  box-shadow: 0 4px 20px rgba(22,48,92,.08);
}

.role-row { display: flex; gap: 24px; }
.role-card {
  width: 220px; text-align: center; padding: 36px 24px; cursor: pointer;
  transition: transform .15s, box-shadow .15s; text-decoration: none; color: inherit;
  background: #fff; border-radius: 14px; box-shadow: 0 4px 20px rgba(22,48,92,.08);
}
.role-card:hover { transform: translateY(-4px); box-shadow: 0 8px 28px rgba(22,48,92,.16); }
.role-card .icon { font-size: 44px; margin-bottom: 14px; }
.role-card .name { font-size: 18px; font-weight: 700; color: #16305c; }
.role-card .desc { font-size: 13px; color: #8a93a6; margin-top: 6px; }

/* 表单 */
.form-card { width: 340px; }
.form-card h2 { font-size: 20px; color: #16305c; margin-bottom: 20px; text-align: center; }
input[type=text], input[type=password] {
  width: 100%; padding: 11px 14px; border: 1px solid #d5dbe7; border-radius: 8px;
  font-size: 15px; margin-bottom: 14px; outline: none;
}
input:focus { border-color: #16305c; }
.login-remember { display: flex; align-items: center; gap: 6px; margin: 2px 0 12px; color: #6f7b90; font-size: 13px; cursor: pointer; }
.login-remember input { width: 16px; height: 16px; margin: 0; accent-color: #16305c; }
.btn {
  display: inline-block; width: 100%; padding: 11px; border: none; border-radius: 8px;
  background: #16305c; color: #fff; font-size: 15px; font-weight: 600; cursor: pointer;
}
.btn:hover { background: #1d3d75; }
.btn:disabled { background: #9aa7bd; cursor: not-allowed; }
.btn-small { width: auto; padding: 6px 14px; font-size: 13px; }
.btn-danger { background: #c0392b; }
.btn-danger:hover { background: #d64535; }
.err { color: #c0392b; font-size: 13px; min-height: 18px; margin-bottom: 8px; text-align: center; }
.back-link { margin-top: 18px; font-size: 13px; color: #8a93a6; text-decoration: none; }
.back-link:hover { color: #16305c; }

/* 区块 */
.section { margin-bottom: 28px; }
.section h3 {
  font-size: 16px; color: #16305c; margin-bottom: 14px;
  border-left: 4px solid #e8b64c; padding-left: 10px;
}

/* 列表 */
.video-item, .student-item {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px; background: #fff; border-radius: 10px; margin-bottom: 10px;
  box-shadow: 0 2px 8px rgba(22,48,92,.06);
}
.video-item .title { font-weight: 600; font-size: 15px; }
.video-item .meta, .student-item .meta { font-size: 12px; color: #8a93a6; margin-top: 3px; }
.empty { color: #8a93a6; font-size: 14px; text-align: center; padding: 30px 0; }

/* 通知 */
.notice-item {
  background: #fff; border-radius: 12px; margin-bottom: 12px;
  box-shadow: 0 2px 8px rgba(22,48,92,.06);
}
.notice-item summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 22px; color: #16305c; font-size: 17px; font-weight: 700; cursor: pointer;
  list-style: none;
}
.notice-item summary::-webkit-details-marker { display: none; }
.notice-summary-action { color: #8a93a6; font-size: 13px; font-weight: 500; }
.notice-summary-action::after { content: '展开 ▾'; }
.notice-item[open] { padding-bottom: 22px; }
.notice-item[open] .notice-summary-action::after { content: '收起 ▴'; }
.notice-body { padding: 0 24px; }
.notice-date { color: #8a93a6; font-size: 12px; margin-bottom: 18px; }
.notice-content { color: #36435c; font-size: 14px; line-height: 1.9; }
.notice-content p { margin-bottom: 10px; }
.notice-content p:last-child { margin-bottom: 0; }

/* 老师端通知管理 */
.notice-form { display: flex; flex-direction: column; gap: 14px; }
.notice-form label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; color: #5d6880; }
.notice-form input[type=text], .notice-form textarea {
  width: 100%; margin: 0; padding: 10px 12px; border: 1px solid #d5dbe7;
  border-radius: 8px; font: inherit; color: #1a2233; outline: none;
}
.notice-form textarea { min-height: 140px; line-height: 1.6; resize: vertical; }
.notice-form input[type=text]:focus, .notice-form textarea:focus { border-color: #16305c; }
.notice-form .notice-reminder { flex-direction: row; align-items: center; gap: 8px; color: #36435c; }
.notice-reminder input { width: 16px; height: 16px; accent-color: #16305c; }
.notice-form-actions { display: flex; justify-content: flex-end; gap: 10px; }
.notice-admin-item {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 16px;
  padding: 16px 18px; margin-bottom: 10px; background: #fff; border-radius: 10px;
  box-shadow: 0 2px 8px rgba(22,48,92,.06);
}
.notice-admin-main { min-width: 0; flex: 1; }
.notice-admin-title { color: #16305c; font-weight: 700; font-size: 15px; }
.notice-admin-preview { margin-top: 7px; color: #5d6880; font-size: 13px; line-height: 1.55; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.notice-admin-actions { display: flex; flex-shrink: 0; gap: 8px; }

/* 老师端测验成绩 */
.score-board { margin-bottom: 16px; background: #fff; border-radius: 12px; box-shadow: 0 2px 8px rgba(22,48,92,.06); }
.score-board-head { display: flex; justify-content: space-between; align-items: center; padding: 20px 22px; cursor: pointer; list-style: none; }
.score-board-head::-webkit-details-marker { display: none; }
.score-board-toggle { color: #8a93a6; font-size: 13px; }
.score-board-toggle::after { content: '展开 ▾'; }
.score-board[open] .score-board-toggle::after { content: '收起 ▴'; }
.score-board-body { padding: 0 22px 22px; }
.score-board-title { color: #16305c; font-size: 17px; font-weight: 700; }
.score-stats { display: grid; grid-template-columns: repeat(4, 1fr); margin: 18px 0; border: 1px solid #e8edf5; border-radius: 10px; overflow: hidden; }
.score-stats-archived { grid-template-columns: repeat(3, 1fr); }
.score-stats > div { min-width: 0; padding: 13px 8px; text-align: center; border-right: 1px solid #e8edf5; }
.score-stats > div:last-child { border-right: 0; }
.score-stats b { display: block; color: #16305c; font-size: 19px; }
.score-stats span { display: block; margin-top: 4px; color: #8a93a6; font-size: 12px; }
.score-table-wrap { overflow-x: auto; }
.score-table { width: 100%; min-width: 570px; border-collapse: collapse; font-size: 13px; }
.score-table th { color: #7b879c; font-weight: 600; background: #f7f9fc; }
.score-table th, .score-table td { padding: 11px 12px; border-bottom: 1px solid #e8edf5; text-align: left; white-space: nowrap; }
.score-table tr:last-child td { border-bottom: 0; }
.score-status { display: inline-block; padding: 3px 8px; border-radius: 12px; font-size: 12px; }
.score-wrong-btn { margin-left: 8px; padding: 4px 9px; }
.score-submitted { color: #2f7d42; background: #e8f6ec; }
.score-active { color: #9a6b15; background: #fdf3e3; }
.score-pending { color: #7b879c; background: #eef1f5; }
.wrong-answer-modal { width: 680px; }
.wrong-answer-item { padding: 14px 0; border-bottom: 1px solid #e8edf5; }
.wrong-answer-item:last-child { border-bottom: 0; }
.wrong-answer-question { color: #16305c; font-size: 15px; font-weight: 700; line-height: 1.6; margin-bottom: 8px; }
.wrong-answer-line, .wrong-answer-reason { color: #5d6880; font-size: 13px; line-height: 1.7; }
.wrong-answer-line b, .wrong-answer-reason b { color: #36435c; }
.wrong-answer-correct { color: #2f7d42; }
.wrong-answer-reason { margin-top: 7px; color: #9a6b15; }

/* 测验与成绩 */
.test-item {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 20px; background: #fff; border-radius: 12px;
  box-shadow: 0 2px 8px rgba(22,48,92,.06);
}
#testList { display: flex; flex-direction: column; gap: 16px; }
.test-item .title { color: #16305c; font-size: 16px; font-weight: 700; margin-bottom: 6px; }
.test-item .meta { color: #7b879c; font-size: 13px; line-height: 1.7; }
.test-status { flex-shrink: 0; border-radius: 16px; padding: 6px 10px; font-size: 12px; }
.test-side { display: flex; flex-direction: column; align-items: flex-end; gap: 9px; }
.test-result { color: #2f7d42; font-size: 12px; white-space: nowrap; }
.test-upcoming { background: #fdf3e3; color: #9a6b15; }
.test-open { background: #e8f6ec; color: #2f7d42; }
.test-closed { background: #eef1f5; color: #7b879c; }
.notice-modal {
  position: fixed; inset: 0; z-index: 20; align-items: center; justify-content: center;
  padding: 20px; background: rgba(15, 30, 58, .42);
}
.notice-modal-card {
  width: min(420px, 100%); background: #fff; border-radius: 16px; padding: 30px;
  text-align: center; box-shadow: 0 16px 48px rgba(8, 24, 54, .25);
}
.notice-modal-icon { font-size: 34px; margin-bottom: 10px; }
.notice-modal-card h2 { color: #16305c; font-size: 20px; margin-bottom: 10px; }
.notice-modal-card p { color: #6f7b90; font-size: 14px; }
.notice-modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 24px; }
.notice-modal-actions button { border: 0; border-radius: 8px; padding: 9px 16px; font-size: 14px; cursor: pointer; }
.notice-later { background: #eef2f8; color: #5d6880; }
.notice-view { background: #16305c; color: #fff; }
.notice-view:hover { background: #1d3d75; }

/* 在线答题 */
.exam-head {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  margin-bottom: 16px; padding: 20px; background: #fff; border-radius: 12px;
  box-shadow: 0 2px 8px rgba(22,48,92,.06);
}
.exam-head h2 { color: #16305c; font-size: 20px; margin-bottom: 7px; }
.exam-head p { color: #6f7b90; font-size: 13px; }
.exam-actions { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.exam-actions b { color: #c0392b; font-variant-numeric: tabular-nums; }
.exam-question { margin-bottom: 12px; padding: 18px 20px; background: #fff; border-radius: 12px; box-shadow: 0 2px 8px rgba(22,48,92,.06); }
.exam-question h3 { color: #293650; font-size: 15px; line-height: 1.6; margin-bottom: 12px; }
.exam-question h3 span { color: #8a93a6; font-size: 12px; font-weight: 500; }
.exam-options { display: flex; flex-direction: column; gap: 7px; }
.exam-options label { display: flex; align-items: flex-start; gap: 8px; padding: 9px 10px; border-radius: 7px; color: #43506a; font-size: 14px; cursor: pointer; }
.exam-options label:hover { background: #f4f7fb; }
.exam-options input { margin-top: 2px; accent-color: #16305c; }
.exam-result { max-width: 470px; margin: 48px auto; text-align: center; }
.exam-result-icon { font-size: 42px; margin-bottom: 12px; }
.exam-result h2 { color: #16305c; margin-bottom: 8px; }
.exam-result p { color: #6f7b90; font-size: 14px; margin: 8px 0; }
.exam-result strong { display: block; color: #c0392b; font-size: 38px; margin: 10px 0; }
.review-question { border-left: 4px solid #35a35a; }
.review-question.review-error { border-left-color: #c0392b; }
.review-option { display: flex; align-items: center; gap: 6px; padding: 9px 10px; color: #43506a; font-size: 14px; border-radius: 7px; }
.review-option-correct { color: #216735; background: #edf8ef; }
.review-option-wrong { color: #a83232; background: #fff0f0; }
.review-option em { margin-left: auto; font-style: normal; font-size: 12px; font-weight: 600; }
.review-summary { margin-top: 12px; color: #43506a; font-size: 14px; line-height: 1.6; }
.wrong-reason { display: flex; align-items: center; gap: 10px; margin-top: 14px; color: #5d6880; font-size: 13px; }
.wrong-reason select { padding: 7px 9px; border: 1px solid #d5dbe7; border-radius: 7px; background: #fff; color: #36435c; font-size: 13px; }

/* 上传 */
.upload-row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.material-access-picker, .material-access-controls { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; color: #697790; font-size: 12px; }
.material-access-picker { margin-top: 10px; }
.material-access-picker label, .material-access-controls label { display: inline-flex; align-items: center; gap: 3px; cursor: pointer; white-space: nowrap; }
.material-access-picker input, .material-access-controls input { width: 14px; height: 14px; margin: 0; accent-color: #16305c; }
.material-access-controls { margin-top: 9px; }
.material-admin-item { align-items: flex-start; }
.upload-row input[type=text] { flex: 1; min-width: 180px; margin-bottom: 0; }
.progress-wrap { margin-top: 12px; display: none; }
.progress-bar { height: 8px; background: #e3e8f1; border-radius: 4px; overflow: hidden; }
.progress-bar > div { height: 100%; width: 0; background: #e8b64c; transition: width .2s; }
.progress-text { font-size: 12px; color: #8a93a6; margin-top: 4px; }

/* 上课确认 */
.confirm-banner {
  background: #fdf3e3; border: 1px solid #e8b64c; color: #9a6b15;
  border-radius: 10px; padding: 12px 16px; margin-bottom: 16px;
  font-size: 14px; cursor: pointer;
}
.confirm-banner:hover { background: #fbebd0; }
.confirm-banner b { color: #c0392b; }
.tab-badge {
  display: inline-block; min-width: 18px; height: 18px; line-height: 18px;
  text-align: center; background: #c0392b; color: #fff; border-radius: 9px;
  font-size: 11px; margin-left: 5px; padding: 0 5px;
}

.product-access-note {
  margin: -4px 0 18px;
  padding: 10px 14px;
  border-radius: 8px;
  background: #eef5ff;
  color: #456387;
  font-size: 13px;
}
.confirm-btn { margin-top: 8px; background: #e8b64c; }
.confirm-btn:hover { background: #d9a838; }
.confirm-done { margin-top: 8px; font-size: 12px; color: #2f7d42; }
.not-confirmed {
  font-size: 13px; color: #a8722a; background: #fdf6ea;
  border-radius: 8px; padding: 10px 14px; margin-bottom: 10px;
}
/* 课表下内嵌的确认情况 */
.sched-block { margin-bottom: 10px; }
.confirm-box {
  background: #f7f9fc; border-radius: 0 0 10px 10px;
  padding: 10px 14px; margin: -6px 2px 0; font-size: 13px;
}
.confirm-head { font-weight: 600; color: #16305c; margin-bottom: 6px; }
.confirm-line { color: #2f7d42; padding: 2px 0; }
.confirm-line .confirm-detail { color: #8a93a6; font-size: 12px; margin-left: 4px; }
.confirm-pending { color: #a8722a; }
/* 老师端学员背诵进度迷你条 */
.prog-mini { position: relative; height: 9px; background: #e3e8f1; border-radius: 5px; margin-top: 6px; max-width: 300px; overflow: hidden; }
.prog-mini > div[class^="prog-"] { height: 100%; border-radius: 5px; }
.prog-ahead { background: #35a35a; }   /* 跟上/超前=绿 */
.prog-behind { background: #d0463a; }  /* 落后=红 */
.prog-idle { background: #b7c0d0; }    /* 非当前轮=灰 */
/* 应背到位置的灰线 */
.prog-marker { position: absolute; top: -2px; bottom: -2px; width: 2px; background: #5d6880; z-index: 2; }
.badge-behind { background: #c0392b; color: #fff; }
.badge-ahead { background: #35a35a; color: #fff; }

/* 分区标签页 */
.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.tab {
  padding: 10px 22px; border-radius: 10px; cursor: pointer;
  font-size: 15px; font-weight: 600; color: #8a93a6;
  background: #fff; box-shadow: 0 2px 8px rgba(22,48,92,.06);
}
.tab:hover { color: #16305c; }
.tab.active { background: #16305c; color: #fff; }

/* 子标签 */
.subtabs { display: flex; gap: 6px; margin-bottom: 16px; }
.subtab {
  padding: 7px 16px; border-radius: 8px; cursor: pointer;
  font-size: 14px; font-weight: 600; color: #8a93a6; background: #eef2f9;
}
.subtab.active { background: #16305c; color: #fff; }

/* 背诵打卡 */
.recite-head {
  background: #fff; border-radius: 12px; padding: 16px 18px;
  box-shadow: 0 4px 20px rgba(22,48,92,.08); margin-bottom: 16px;
}
.recite-round { font-size: 17px; font-weight: 800; color: #16305c; }
.recite-progress-text { font-size: 13px; color: #5d6880; margin: 6px 0 8px; }
.recite-progress-text b { color: #16305c; }
.recite-bar { position: relative; height: 12px; background: #e3e8f1; border-radius: 6px; margin-bottom: 12px; }
.recite-bar > div[class^="recite-fill"] { height: 100%; border-radius: 6px; transition: width .3s; }
.recite-fill-ahead { background: #35a35a; }
.recite-fill-behind { background: #d0463a; }
.recite-next { background: #16305c; }
.recite-hist { font-size: 12px; color: #8a93a6; margin-bottom: 14px; }
.recite-round-card { background: #fff; border-radius: 12px; box-shadow: 0 2px 8px rgba(22,48,92,.06); margin-bottom: 12px; overflow: hidden; }
.recite-round-card summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 18px; color: #16305c; font-weight: 800; }
.recite-round-card summary::-webkit-details-marker { display: none; }
.recite-round-card summary::after { content: '⌄'; color: #8a93a6; margin-left: 8px; transition: transform .2s; }
.recite-round-card[open] summary::after { transform: rotate(180deg); }
.recite-round-progress { display: inline-block; margin-left: 9px; color: #697790; font-size: 13px; font-weight: 600; }
.recite-round-body { padding: 0 14px 14px; border-top: 1px solid #edf0f5; }
.recite-month { font-size: 12px; color: #8a93a6; font-weight: 700; padding: 14px 4px 6px; }
.recite-lock, .recite-active, .recite-pending { display: inline-block; margin-left: 7px; padding: 3px 8px; border-radius: 12px; font-size: 11px; vertical-align: 1px; }
.recite-lock { background: #eef1f5; color: #7b879c; }
.recite-active { background: #e8f6ec; color: #2f7d42; }
.recite-pending { background: #fdf3e3; color: #9a6b15; }
.recite-round-note { color: #6c7890; font-size: 13px; line-height: 1.7; margin: 14px 4px 12px; }
.teacher-recite-round { margin-bottom: 12px; }
.teacher-recite-round summary small { color: #7b879c; font-size: 12px; font-weight: 600; margin-left: 8px; }
.teacher-recite-note { margin: 12px 4px 8px; }
.dictation-board {
  margin-top: 16px; overflow: hidden; border: 1px solid #e8edf5; border-radius: 12px;
  background: #fff; box-shadow: 0 4px 14px rgba(22, 48, 92, .04);
}
.dictation-board summary {
  display: flex; align-items: center; gap: 10px; padding: 16px 18px; color: #16305c;
  cursor: pointer; font-size: 16px; font-weight: 800; list-style: none;
}
.dictation-board summary::-webkit-details-marker { display: none; }
.dictation-board summary::after { content: '⌄'; margin-left: 4px; color: #8a93a6; font-size: 18px; transition: transform .18s ease; }
.dictation-board[open] summary::after { transform: rotate(180deg); }
.dictation-summary-note { margin-left: auto; color: #8a93a6; font-size: 12px; font-weight: 600; }
.dictation-board-body { padding: 0 16px 16px; border-top: 1px solid #edf0f5; }
.dictation-intro { margin: 13px 2px; color: #697790; font-size: 13px; line-height: 1.6; }
.dictation-week { padding: 13px 2px; border-top: 1px solid #edf0f5; }
.dictation-week-head { display: flex; align-items: center; gap: 8px; color: #697790; font-size: 12px; }
.dictation-week-head b { color: #16305c; font-size: 15px; }
.dictation-week-head em { margin-left: auto; border-radius: 12px; padding: 3px 8px; font-style: normal; font-weight: 700; }
.dictation-open .dictation-week-head em { color: #2f8550; background: #e8f6ed; }
.dictation-upcoming .dictation-week-head em { color: #9a6b15; background: #fff3d9; }
.dictation-closed .dictation-week-head em { color: #78859a; background: #eef1f5; }
.dictation-task { margin: 8px 0; color: #3c4a63; font-size: 13px; }
.dictation-week textarea {
  display: block; box-sizing: border-box; width: 100%; min-height: 74px; resize: vertical;
  border: 1px solid #d5dbe7; border-radius: 8px; padding: 9px 10px; color: #263653; font: inherit; font-size: 13px;
}
.dictation-week textarea:disabled { background: #f7f8fa; color: #8a93a6; }
.dictation-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-top: 9px; }
.dictation-actions .att-add input { display: none; }
.dictation-disabled { opacity: .55; cursor: not-allowed; }
.dictation-remove { border: 0; background: transparent; color: #a24a43; cursor: pointer; font-size: 12px; }
.dictation-remove:disabled { opacity: .5; cursor: not-allowed; }
.dictation-updated { margin-top: 7px; color: #8a93a6; font-size: 11px; }
.teacher-dictation-board { margin: 0 0 18px; }
.teacher-dictation-week { border-top: 1px solid #edf0f5; }
.teacher-dictation-week:first-child { border-top: 0; }
.teacher-dictation-week summary { display: flex; align-items: center; gap: 10px; padding: 14px 2px; cursor: pointer; list-style: none; color: #16305c; font-size: 14px; font-weight: 700; }
.teacher-dictation-week summary::-webkit-details-marker { display: none; }
.teacher-dictation-week summary::after { content: '⌄'; color: #8a93a6; font-size: 16px; transition: transform .18s ease; }
.teacher-dictation-week[open] summary::after { transform: rotate(180deg); }
.teacher-dictation-week summary em { margin-left: auto; color: #7b879c; font-style: normal; font-size: 12px; font-weight: 600; }
.teacher-dictation-week-body { padding: 0 2px 12px; }
.dictation-teacher-entry { padding: 12px 14px; margin-bottom: 8px; border-radius: 9px; background: #f7f9fc; }
.dictation-teacher-entry-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; color: #16305c; font-size: 14px; }
.dictation-teacher-entry-head span { color: #8a93a6; font-size: 11px; white-space: nowrap; }
.dictation-teacher-text { margin-top: 8px; color: #43506a; font-size: 13px; line-height: 1.7; white-space: normal; word-break: break-word; }
.dictation-teacher-file { display: inline-block; margin-top: 8px; color: #24558f; font-size: 12px; text-decoration: none; }
.dictation-teacher-file:hover { text-decoration: underline; }
.dictation-teacher-empty { padding: 14px 0; }
.recite-item {
  display: flex; align-items: center; gap: 10px;
  background: #fff; border-radius: 10px; padding: 12px 14px; margin-bottom: 8px;
  box-shadow: 0 2px 8px rgba(22,48,92,.06); cursor: pointer;
}
.recite-item input { width: 18px; height: 18px; flex-shrink: 0; accent-color: #16305c; }
.recite-date { font-size: 12px; color: #8a93a6; width: 44px; flex-shrink: 0; }
.recite-topic { flex: 1; font-weight: 600; font-size: 15px; }
.recite-pages { font-size: 13px; color: #16305c; font-weight: 700; }
.recite-pages small { display: block; margin-top: 2px; color: #76548e; font-size: 11px; font-weight: 700; }
.recite-done { background: #f2f8f3; }
.recite-locked { cursor: default; opacity: .72; }
.recite-done .recite-topic { color: #8a93a6; text-decoration: line-through; }

/* 板块分组 */
.video-stage {
  margin: 12px 0; overflow: hidden; border: 1px solid #e8edf5; border-radius: 12px;
  background: #fff; box-shadow: 0 4px 14px rgba(22, 48, 92, .04);
}
.video-stage summary {
  display: flex; align-items: center; gap: 10px; padding: 16px 18px; color: #16305c;
  cursor: pointer; font-weight: 800; list-style: none;
}
.video-stage summary::-webkit-details-marker { display: none; }
.video-stage summary::after {
  content: '⌄'; margin-left: 6px; color: #8a93a6; font-size: 18px;
  transition: transform .18s ease;
}
.video-stage[open] summary::after { transform: rotate(180deg); }
.video-stage-status {
  margin-left: auto; border-radius: 14px; padding: 3px 9px; font-size: 12px; font-weight: 700;
}
.video-stage-ready { color: #2f8550; background: #e8f6ed; }
.video-stage-empty { color: #78859a; background: #eef1f5; }
.video-stage-body { padding: 0 14px 14px; border-top: 1px solid #edf0f5; }
.video-stage-placeholder { padding: 14px 4px 2px; color: #8a93a6; font-size: 13px; }
.replay-group > .video-stage-body { padding-top: 2px; }
.replay-substage { margin: 10px 0; background: #f9fbfe; box-shadow: none; }
.replay-substage > summary { padding: 13px 15px; }
.replay-substage > .video-stage-body { background: #fff; }
.material-category .video-item { margin: 0; border-radius: 0; box-shadow: none; border-bottom: 1px solid #edf0f5; }
.material-category .video-item:last-child { border-bottom: 0; }
.material-subcategory { margin: 8px 0; border: 1px solid #e5ebf3; border-radius: 10px; overflow: hidden; }
.material-subcategory > summary { padding: 10px 12px; background: #f8faff; }
.material-subcategory > .video-stage-body { background: #fff; }
.teacher-video-stage .video-stage-body { padding-bottom: 0; }
.teacher-video-stage .video-item { border-radius: 0; box-shadow: none; border-bottom: 1px solid #edf0f5; margin: 0; }
.teacher-video-stage .video-item:last-child { border-bottom: 0; }
.stage-access-controls { margin: 0 -14px; padding: 12px 16px; border-bottom: 1px solid #edf0f5; background: #f8fafd; }
.stage-access-controls .btn { padding: 5px 10px; }
.course-center-item {
  display: flex; align-items: center; gap: 14px; padding: 10px 4px;
  border-bottom: 1px solid #edf0f5;
}
.course-center-item:last-child { border-bottom: 0; }
.course-center-past { background: linear-gradient(90deg, rgba(244, 247, 251, .75), transparent); }
.course-center-date {
  width: 50px; flex-shrink: 0; border-radius: 9px; padding: 7px 0; text-align: center;
  background: #eef2f9; color: #16305c;
}
.course-center-date b { display: block; font-size: 19px; line-height: 1.1; }
.course-center-date span { display: block; margin-top: 3px; color: #7a879c; font-size: 10px; }
.course-center-main { flex: 1; min-width: 0; }
.course-center-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.course-center-actions .att-row { margin-top: 0; }
.course-replay-pending, .course-checkin-wait { color: #8a93a6; font-size: 12px; }
.course-checkin { min-width: 164px; text-align: right; }
.course-checkin-done { color: #2f8550; font-size: 12px; font-weight: 700; line-height: 1.5; }
.course-replay-extra-title { margin: 14px 4px 6px; color: #697790; font-size: 12px; font-weight: 800; }
@media (max-width: 720px) {
  .course-center-item { flex-wrap: wrap; }
  .course-center-main { min-width: calc(100% - 64px); }
  .course-center-actions { width: 100%; margin-left: 64px; }
  .course-checkin { width: 100%; min-width: 0; text-align: left; margin-left: 64px; }
  .teacher-video-stage .video-item { align-items: stretch; flex-direction: column; gap: 10px; }
  .teacher-video-stage .video-actions { margin-left: 0; justify-content: flex-end; }
}
.cat-header {
  font-size: 15px; font-weight: 700; color: #16305c;
  margin: 22px 0 10px; padding-left: 10px; border-left: 4px solid #16305c;
}
.cat-select {
  padding: 10px 8px; border: 1px solid #d5dbe7; border-radius: 8px;
  font-size: 14px; background: #fff; color: #1a2233; outline: none;
}
.cat-small { padding: 5px 4px; font-size: 12px; }
.video-actions { display: flex; gap: 8px; align-items: center; flex-shrink: 0; margin-left: 12px; }

/* 附件 */
.att-row { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; align-items: center; }
.att-chip {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 12px; padding: 3px 10px; border-radius: 20px;
  background: #eef2f9; color: #16305c; text-decoration: none;
}
.att-chip a { color: #16305c; text-decoration: none; }
.att-chip a:hover, a.att-chip:hover { text-decoration: underline; }
.att-chip b { cursor: pointer; color: #c0392b; font-weight: 700; margin-left: 2px; }
.att-add {
  font-size: 12px; padding: 3px 10px; border-radius: 20px; cursor: pointer;
  border: 1px dashed #9aa7bd; color: #8a93a6;
}
.att-add:hover { border-color: #16305c; color: #16305c; }
.att-label { font-size: 13px; color: #8a93a6; }

/* 月历 */
.cal-month-thumbnails {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px;
  margin-bottom: 24px;
}
.cal-month-thumb {
  position: relative; cursor: zoom-in; border-radius: 14px; outline: none;
  transition: transform .18s ease, box-shadow .18s ease;
}
.cal-month-thumb:hover, .cal-month-thumb:focus-visible {
  transform: translateY(-2px); box-shadow: 0 8px 22px rgba(22, 48, 92, .13);
}
.cal-month-thumb .cal-month { margin: 0; padding: 13px; min-height: 232px; }
.cal-month-thumb .cal-title { font-size: 14px; margin-bottom: 7px; }
.cal-month-thumb .cal-grid { gap: 2px; }
.cal-month-thumb .cal-head { padding: 2px 0; font-size: 10px; }
.cal-month-thumb .cal-cell { min-height: 34px; padding: 2px; border-radius: 5px; }
.cal-month-thumb .cal-daynum { margin-bottom: 1px; font-size: 9px; }
.cal-month-thumb .cal-chip, .cal-month-thumb .cal-rec {
  margin-bottom: 1px; padding: 1px 2px; font-size: 7px; line-height: 1.2;
}
.cal-month-thumb .cal-rec b { font-size: 7px; }
.cal-thumb-hint {
  position: absolute; right: 10px; bottom: 9px; border-radius: 12px; padding: 3px 7px;
  background: rgba(22, 48, 92, .84); color: #fff; font-size: 10px; font-weight: 700;
}
.cal-month {
  background: #fff; border-radius: 14px; padding: 18px;
  box-shadow: 0 4px 20px rgba(22,48,92,.08); margin-bottom: 20px;
}
.cal-title { font-size: 16px; font-weight: 800; color: #16305c; margin-bottom: 12px; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-head { text-align: center; font-size: 12px; color: #8a93a6; padding: 4px 0; font-weight: 600; }
.cal-cell {
  min-height: 58px; border-radius: 8px; background: #f7f9fc;
  padding: 4px; overflow: hidden;
}
.cal-empty { background: transparent; }
.cal-today { outline: 2px solid #e8b64c; background: #fdf8ec; }
.cal-daynum { font-size: 12px; font-weight: 700; color: #5d6880; margin-bottom: 2px; }
.cal-chip {
  font-size: 10.5px; line-height: 1.35; padding: 2px 4px; border-radius: 4px;
  background: #e4ebf7; color: #16305c; margin-bottom: 2px; font-weight: 600;
  word-break: break-all;
}
.cal-chip.cat-强化 { background: #fdf3e3; color: #9a6b15; }
.cal-chip.cat-强化阶段-会计补充 { background: #fdf3e3; color: #9a6b15; }
.cal-chip.cat-冲刺 { background: #fdeaea; color: #a83232; }
.cal-chip small { font-size: .9em; font-weight: 500; }
.teacher-cal-editable { cursor: pointer; }
.teacher-cal-editable:hover, .teacher-cal-editable:focus-visible { outline: 2px solid #e8b64c; background: #fff9e9; }
.teacher-cal-add { display: block; margin-top: 3px; color: #8a93a6; font-size: 10px; }
.cal-month-thumb .teacher-cal-add { display: none; }
.teacher-day-mask { z-index: 220; }
.teacher-day-dialog { width: min(760px, 100%); background: #fff; }
.teacher-day-dialog h3, .teacher-day-dialog h4 { color: #16305c; margin: 8px 0 14px; }
.teacher-day-item { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; padding: 12px 0; border-bottom: 1px solid #e3e8f0; }
.teacher-day-item .confirm-box { flex-basis: 100%; margin-top: 0; }
.teacher-day-actions { display: flex; align-items: flex-start; gap: 6px; }
.teacher-day-rec { padding: 10px; border-radius: 8px; background: #f0edf7; margin-bottom: 10px; }
.teacher-day-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.teacher-day-form input, .teacher-day-form select { width: 100%; min-width: 0; padding: 10px; border: 1px solid #cbd3e1; border-radius: 8px; font: inherit; }
.teacher-day-form button { justify-self: start; }
@media (max-width: 600px) { .teacher-day-form { grid-template-columns: 1fr; } }
.chip-past { opacity: .5; }
.chip-next { box-shadow: 0 0 0 2px #e8b64c; }

/* 背诵任务 chip */
.cal-rec {
  font-size: 10px; line-height: 1.3; padding: 2px 4px; border-radius: 4px;
  background: #f0edf7; color: #5b4a86; margin-bottom: 2px; word-break: break-all;
}
.cal-rec b { font-size: 10px; color: #16305c; font-weight: 700; }
.cal-rec em { font-size: 9px; color: #76548e; font-style: normal; font-weight: 700; }
.cal-rec-easy { background: #e8f6ec; color: #2f7d42; }
.cal-rec-key { background: #fbf0d8; color: #9a6b15; box-shadow: 0 0 0 1px #e8b64c inset; }
.cal-rec-rest { background: transparent; color: #a8b0be; font-style: italic; }
.cal-rest { background: #f0f1f4; }

/* 图例 */
.cal-legend {
  display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 14px;
  font-size: 12px; color: #5d6880;
}
.cal-legend span { display: inline-flex; align-items: center; gap: 3px; }
.cal-legend .lg { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }
.cal-legend .lg-class { background: #e4ebf7; }

.calendar-preview-mask {
  position: fixed; z-index: 200; inset: 0; display: flex; align-items: center; justify-content: center;
  padding: 28px; background: rgba(16, 31, 59, .58);
}
.calendar-preview-dialog {
  position: relative; width: min(1120px, 100%); max-height: calc(100vh - 56px); overflow: auto;
  border-radius: 16px; background: #f4f6fa; padding: 18px;
}
.calendar-preview-dialog .cal-month { margin: 0; }
.calendar-preview-close {
  position: sticky; z-index: 1; float: right; margin: -8px -8px 0 8px; width: 32px; height: 32px;
  border: 0; border-radius: 50%; background: #16305c; color: #fff; cursor: pointer; font-size: 24px; line-height: 1;
}
@media (max-width: 720px) {
  .cal-month-thumbnails { grid-template-columns: 1fr; }
  .calendar-preview-mask { padding: 12px; }
  .calendar-preview-dialog { max-height: calc(100vh - 24px); padding: 10px; }
}

/* 课表 */
.sched-item { justify-content: flex-start; gap: 16px; }
.sched-date {
  width: 52px; flex-shrink: 0; text-align: center;
  background: #eef2f9; border-radius: 10px; padding: 8px 0;
}
.sched-day { font-size: 20px; font-weight: 800; color: #16305c; line-height: 1.2; }
.sched-week { font-size: 11px; color: #8a93a6; }
.sched-past { opacity: .55; }
.sched-next { border: 2px solid #e8b64c; }
.badge {
  display: inline-block; font-size: 11px; font-weight: 600;
  padding: 2px 8px; border-radius: 10px; margin-left: 8px; vertical-align: 1px;
}
.badge-today { background: #c0392b; color: #fff; }
.badge-next { background: #e8b64c; color: #fff; }
.badge-done { background: #e3e8f1; color: #8a93a6; }

/* 学生信息卡片 */
.student-tag-group {
  margin-bottom: 14px; border: 1px solid #e4eaf3; border-radius: 12px;
  background: #fff; overflow: hidden; box-shadow: 0 2px 8px rgba(22,48,92,.04);
}
.student-products-picker { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; margin-top: 10px; color: #526784; font-size: 12px; }
.student-products-picker label { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.student-legacy-access { margin-top: 12px; color: #75839a; font-size: 12px; }
.student-legacy-access summary { cursor: pointer; }
.student-legacy-access select { display: block; max-width: 100%; margin-top: 8px; padding: 7px; border: 1px solid #d0daea; border-radius: 7px; }
.student-legacy-access .meta { margin: 7px 0 0; }
.student-ledger-scroll { overflow-x: auto; background: #fff; border: 1px solid #dfe7f2; border-radius: 12px; }
.student-ledger { width: 100%; min-width: 920px; border-collapse: collapse; color: #233957; font-size: 13px; }
.student-ledger th, .student-ledger td { padding: 7px 10px; border-bottom: 1px solid #e8edf5; text-align: left; vertical-align: middle; }
.student-ledger th { background: #eaf1fb; color: #16305c; font-weight: 800; white-space: nowrap; }
.student-ledger tr:last-child td { border-bottom: 0; }
.student-ledger-sequence { width: 52px; color: #8390a8; font-weight: 800; }
.student-ledger-amount { white-space: nowrap; font-weight: 700; }
.student-product-chip { display: inline-block; margin: 2px 4px 2px 0; padding: 3px 7px; border-radius: 7px; color: #244878; background: #edf4ff; white-space: nowrap; }
.student-ledger-name { display: flex; align-items: center; gap: 10px; white-space: nowrap; }
.student-ledger-name button, .student-ledger-reveal { border: 0; background: none; padding: 0; color: #476899; cursor: pointer; font-size: 11px; }
.student-ledger-password { display: inline-block; min-width: 52px; }
.student-tag-group summary {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 16px; color: #16305c; font-size: 16px; font-weight: 700;
  cursor: pointer; list-style: none;
}
.student-tag-group summary::-webkit-details-marker { display: none; }
.student-tag-group summary::after { content: '⌄'; color: #8390a8; font-size: 18px; font-weight: 400; }
.student-tag-group[open] summary::after { content: '⌃'; }
.student-tag-count {
  margin-left: auto; color: #8390a8; font-size: 13px; font-weight: 500;
}
.student-tag-group-body { padding: 0 12px 2px; border-top: 1px solid #edf1f6; }
.student-tag-manager {
  margin: 0 0 14px; border: 1px solid #e4eaf3; border-radius: 12px; background: #fff;
}
.student-tag-manager summary {
  padding: 13px 16px; color: #16305c; cursor: pointer; font-weight: 700; list-style: none;
}
.student-tag-manager summary::-webkit-details-marker { display: none; }
.student-tag-manager summary span { margin-left: 10px; color: #8390a8; font-size: 12px; font-weight: 400; }
.student-tag-manager-body { padding: 0 16px 14px; }
.student-tag-row {
  display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid #edf1f6;
}
.student-tag-row b { min-width: 110px; color: #16305c; }
.student-tag-row span { color: #8390a8; font-size: 12px; margin-right: auto; }
.student-tag-add { display: flex; gap: 8px; margin-top: 10px; }
.student-tag-add input { max-width: 220px; margin: 0; }
.student-block { margin-bottom: 10px; }
.stu-actions { display: flex; gap: 6px; flex-shrink: 0; }
.stu-num {
  display: inline-block; background: #16305c; color: #fff; font-size: 12px;
  font-weight: 700; padding: 2px 9px; border-radius: 6px; margin-right: 6px; vertical-align: 2px;
}
.stu-num-none { background: #c3cad6; color: #fff; font-weight: 500; }
.stu-card {
  background: #f7f9fc; border-radius: 0 0 10px 10px; margin: -6px 2px 0;
  padding: 12px 14px; font-size: 13px; color: #3a4761;
}
.stu-card-row { font-weight: 600; color: #16305c; margin-bottom: 6px; }
.stu-card-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.stu-card-chips span {
  background: #e4ebf7; color: #16305c; border-radius: 20px;
  padding: 2px 10px; font-size: 12px;
}
.stu-card-notes {
  background: #fff; border-left: 3px solid #e8b64c; border-radius: 4px;
  padding: 8px 10px; margin-bottom: 8px; color: #5d6880; line-height: 1.5;
}
.stu-card-btns { display: flex; gap: 8px; }

/* 弹窗 */
.modal-mask {
  position: fixed; inset: 0; background: rgba(22,48,92,.4);
  display: flex; align-items: center; justify-content: center; z-index: 100; padding: 20px;
}
.modal-box {
  background: #fff; border-radius: 14px; padding: 24px; width: 460px; max-width: 100%;
  max-height: 90vh; overflow-y: auto; box-shadow: 0 10px 40px rgba(0,0,0,.2);
}
.modal-box h3 { color: #16305c; margin-bottom: 16px; border: none; padding: 0; }
.card-form { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.card-form label { display: flex; flex-direction: column; font-size: 13px; color: #5d6880; gap: 4px; }
.card-form label input, .card-form label textarea {
  padding: 8px 10px; border: 1px solid #d5dbe7; border-radius: 8px; font-size: 14px; margin: 0;
}
.card-form-full { grid-column: 1 / -1; }
.modal-btns { display: flex; justify-content: flex-end; gap: 10px; margin-top: 18px; }
.modal-btns .btn { width: auto; padding: 8px 20px; }

/* 播放器 */
.player-wrap {
  position: relative; background: #000; border-radius: 12px; overflow: hidden;
  user-select: none; -webkit-user-select: none;
}
.player-wrap video { display: block; width: 100%; max-height: 70vh; }
.watermark {
  position: absolute; top: 10%; left: 10%; pointer-events: none; z-index: 10;
  color: rgba(255,255,255,.35); font-size: 15px; font-weight: 600;
  text-shadow: 0 0 4px rgba(0,0,0,.5); white-space: nowrap;
  transition: top 1.2s ease, left 1.2s ease;
}
.player-title { font-size: 18px; font-weight: 700; color: #16305c; margin: 18px 0 6px; }
.player-notice { font-size: 12px; color: #b0784a; margin-bottom: 16px; }

/* 基础阶段总成绩 */
.basic-score-head { margin-bottom: 16px; }
.basic-score-hero { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.basic-score-hero strong { font-size: 34px; color: #16305c; }
.basic-score-hero strong small { font-size: 16px; color: #8a93a6; }
.basic-score-hero span { color: #8a93a6; font-weight: 600; }
.grade-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 18px; }
.grade-card { background: #fff; border-radius: 12px; padding: 16px; box-shadow: 0 5px 18px rgba(22,48,92,.07); display: flex; flex-direction: column; gap: 4px; }
.grade-card b { font-size: 24px; color: #16305c; }
.grade-card b small { color: #8a93a6; font-size: 13px; }
.grade-card span { font-size: 14px; color: #53627d; font-weight: 600; }
.grade-card em { font-size: 12px; color: #8a93a6; font-style: normal; }
.score-action-card { margin-bottom: 16px; }
.score-action-card h3, .score-form h3 { color: #16305c; margin: 0 0 8px; }
.score-action-card p { color: #6b7890; margin: 0 0 12px; }
.score-form { background: #fff; border-radius: 12px; padding: 20px; box-shadow: 0 5px 18px rgba(22,48,92,.07); display: flex; flex-direction: column; gap: 12px; }
.score-form label { color: #3e4c65; font-size: 14px; font-weight: 600; display: flex; flex-direction: column; gap: 6px; }
.score-form select, .score-form textarea { border: 1px solid #d5dbe7; border-radius: 8px; padding: 9px 10px; font: inherit; color: #263954; }
.score-form textarea { resize: vertical; }
.score-form-note { color: #61708a; font-size: 14px; }
.attendance-modal-card { width: 520px; }
.attendance-options { display: flex; flex-wrap: wrap; gap: 9px; margin: 18px 0; }
.attendance-option { appearance: none; border: 1px solid #d5dbe7; background: #f7f9fc; color: #53627d; border-radius: 20px; padding: 8px 14px; font-size: 14px; cursor: pointer; }
.attendance-option.selected { background: #e5f4e9; border-color: #54ae6b; color: #277d41; font-weight: 700; }
.classroom-score-input { display: inline-flex; gap: 5px; align-items: center; white-space: nowrap; }
.classroom-score-input input { width: 58px; border: 1px solid #d5dbe7; border-radius: 6px; padding: 6px; font: inherit; }

/* AI 批改 */
.ai-grading-hero, .ai-score-card { background: linear-gradient(135deg, #16305c, #284f88); border-radius: 16px; padding: 24px; color: #fff; display: flex; justify-content: space-between; gap: 18px; align-items: center; margin-bottom: 16px; }
.ai-kicker { display: inline-block; color: #f2cd75; font-weight: 700; font-size: 12px; letter-spacing: .6px; margin-bottom: 7px; }
.ai-grading-hero h2 { font-size: 26px; margin: 0; }
.ai-total { color: #f2cd75; font-weight: 700; white-space: nowrap; }
.ai-grading-hero p { color: rgba(255,255,255,.8); font-size: 14px; line-height: 1.7; max-width: 650px; margin: 8px 0 0; }
.ai-plan { align-self: stretch; min-width: 104px; display: flex; flex-direction: column; justify-content: center; align-items: center; border-left: 1px solid rgba(255,255,255,.22); font-weight: 800; }
.ai-plan small { font-size: 12px; font-weight: 500; color: #dce7fa; margin-top: 5px; }
.ai-grading-form { display: flex; flex-direction: column; gap: 14px; margin-bottom: 22px; }
.ai-scope-note { margin: 0; padding: 10px 12px; border-radius: 8px; background: #fff7e6; color: #8a5b0a; font-size: 13px; font-weight: 600; line-height: 1.6; }
.ai-form-head { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; }
.ai-form-head h3, .ai-history h3, .ai-result-section h3 { color: #16305c; font-size: 17px; }
.ai-form-head span { color: #8a93a6; font-size: 12px; }
.ai-grading-form label { color: #3e4c65; font-size: 13px; font-weight: 700; display: flex; flex-direction: column; gap: 6px; }
.ai-grading-form textarea, .ai-grading-form select, .ai-grading-form input { width: 100%; margin: 0; border: 1px solid #d5dbe7; border-radius: 8px; padding: 10px 12px; font: inherit; font-weight: 400; color: #263954; background: #fff; }
.ai-grading-form textarea { min-height: 110px; resize: vertical; line-height: 1.7; }
.ai-grading-form #aiAnswer { min-height: 420px; }
.ai-form-grid { display: grid; grid-template-columns: 1fr 130px; gap: 12px; }
.ai-image-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; color: #7b879c; font-size: 12px; }
.ai-image-input { display: inline-flex !important; width: auto; flex-direction: row !important; align-items: center; border: 1px dashed #b9c7de; color: #53627d !important; border-radius: 8px; padding: 8px 10px; cursor: pointer; }
.ai-image-input input { display: none; }
.ai-image-zone { display: inline-flex; align-self: flex-start; align-items: center; min-height: 38px; padding: 7px 12px; border: 1px dashed #b9c7de; border-radius: 8px; color: #53627d; background: #f8fafd; font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; transition: border-color .18s, background .18s; }
.ai-image-zone:hover, .ai-image-zone:focus-visible, .ai-image-zone-dragover { border-color: #3f6da7; background: #edf4ff; outline: none; }
.ai-image-zone-disabled { opacity: .55; cursor: not-allowed; }
.ai-image-file { display: none; }
.ai-image-hint { margin: -5px 0 0; color: #7b879c; font-size: 12px; line-height: 1.5; }
.ai-image-hint:empty { display: none; }
.ai-form-actions { display: flex; align-items: center; justify-content: space-between; gap: 14px; color: #8a93a6; font-size: 12px; }
.ai-form-actions .btn { flex: 0 0 auto; }
.ai-form-actions { justify-content: flex-end; }
.ai-retry-note { color: #16305c; background: #edf3fb; border-radius: 8px; padding: 10px 12px; font-weight: 700; font-size: 13px; }
.ai-retry-note button { margin-left: 12px; border: 0; background: transparent; color: #536c98; cursor: pointer; text-decoration: underline; }
.ai-grading-form textarea[readonly] { background: #f4f6fa; color: #53627d; }
.ai-history { margin-top: 22px; }
.ai-history h3 { margin-bottom: 10px; }
.ai-history-item { width: 100%; background: #fff; box-shadow: 0 2px 8px rgba(22,48,92,.06); border-radius: 10px; margin-bottom: 8px; padding: 12px 14px; display: flex; justify-content: space-between; gap: 12px; align-items: center; color: inherit; }
.ai-history-summary { min-width: 0; }
.ai-history-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.ai-history-actions span { color: #277d41; font-size: 13px; white-space: nowrap; }
.ai-history-actions button { border: 1px solid #d5dbe7; background: #fff; color: #16305c; border-radius: 7px; padding: 7px 10px; cursor: pointer; white-space: nowrap; }
.ai-history-actions .ai-retry-btn { background: #16305c; border-color: #16305c; color: #fff; }
.ai-history-item b { display: block; color: #263954; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 600px; }
.ai-history-item small { color: #8a93a6; display: block; margin-top: 4px; }
.ai-history-item em { color: #277d41; font-style: normal; font-size: 13px; white-space: nowrap; }
.ai-grading-locked { text-align: center; max-width: 520px; margin: 50px auto; }
.ai-grading-locked .ai-icon { font-size: 38px; margin-bottom: 10px; }
.ai-grading-locked h2 { color: #16305c; margin-bottom: 10px; }
.ai-grading-locked p { color: #7b879c; font-size: 14px; line-height: 1.7; }
.ai-result-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 4px 0 14px; color: #8a93a6; font-size: 12px; }
.ai-back { margin: 0; cursor: pointer; border: 0; background: transparent; }
.ai-score-card { align-items: stretch; }
.ai-score-card > div:first-child { display: flex; flex-direction: column; }
.ai-score-card span { color: #d9e7ff; font-size: 13px; }
.ai-score-card strong { font-size: 46px; line-height: 1.1; margin: 7px 0; }
.ai-score-card strong small { font-size: 16px; color: #f1d486; }
.ai-score-card p { color: #dce7fa; font-size: 12px; }
.ai-score-note { border-left: 1px solid rgba(255,255,255,.24); padding: 8px 0 8px 22px; align-self: center; font-size: 13px; line-height: 1.8; color: #e6efff; }
.ai-question-card { background: #fffdf6; border: 1px solid #f3dfac; border-radius: 12px; padding: 16px 18px; margin-bottom: 14px; }
.ai-question-card span { color: #a4771d; font-size: 12px; font-weight: 700; }
.ai-question-card p { color: #263954; font-size: 15px; font-weight: 600; line-height: 1.75; margin-top: 6px; }
.ai-result-section { background: #fff; box-shadow: 0 3px 12px rgba(22,48,92,.07); border-radius: 13px; padding: 20px; margin-bottom: 14px; }
.ai-result-section h3 { border-left: 4px solid #e8b64c; padding-left: 9px; margin-bottom: 16px; }
.ai-dimension-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.ai-dimension { border: 1px solid #e5eaf2; border-radius: 9px; padding: 12px; }
.ai-dimension > div { display: flex; justify-content: space-between; gap: 10px; color: #263954; }
.ai-dimension span { color: #277d41; font-weight: 700; }
.ai-dimension p { color: #6d7b92; font-size: 12px; line-height: 1.6; margin-top: 8px; }
.ai-structure-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ai-structure-grid article { background: #f7f9fc; border-radius: 9px; padding: 14px; }
.ai-structure-grid span, .ai-language-table span { color: #8a93a6; font-size: 12px; }
.ai-structure-grid b { display: block; color: #16305c; line-height: 1.6; margin: 7px 0; }
.ai-structure-grid p, .ai-structure-grid li { color: #5d6880; font-size: 13px; line-height: 1.65; }
.ai-structure-grid ul { padding-left: 18px; }
.ai-type-guidance { border: 1px solid #dce7f6; background: #f7faff !important; }
.ai-type-guidance p { margin: 8px 0; }
.ai-type-guidance strong { color: #263954; }
.ai-knowledge-lead { color: #697790; font-size: 13px; line-height: 1.7; margin: -4px 0 13px; }
.ai-knowledge-table { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.ai-knowledge-table article, .ai-case-note { border: 1px solid #e5eaf2; border-radius: 9px; padding: 12px; }
.ai-knowledge-table b { color: #16305c; display: block; font-size: 14px; }
.ai-knowledge-table span { font-size: 12px; color: #a4771d; margin-top: 4px; display: block; }
.ai-knowledge-table p, .ai-case-note p { color: #5d6880; font-size: 13px; line-height: 1.6; margin: 8px 0; }
.ai-knowledge-table p strong { color: #3e4c65; }
.ai-knowledge-table small, .ai-case-note small { color: #8a93a6; font-size: 11px; }
.ai-case-note { margin-top: 12px; background: #fbfcfe; }
.ai-case-note b { color: #16305c; }
.ai-language-table { display: flex; flex-direction: column; gap: 9px; margin-bottom: 14px; }
.ai-language-table article { display: grid; grid-template-columns: 1fr 1.3fr; gap: 14px; background: #f8fafc; padding: 12px; border-radius: 8px; }
.ai-language-table p { color: #3e4c65; font-size: 13px; line-height: 1.6; margin-top: 4px; }
.ai-language-table article > div:last-child p { color: #277d41; font-weight: 600; }
.ai-language-table small { color: #8a93a6; font-size: 11px; line-height: 1.5; }
.ai-language-empty { border: 1px dashed #cfd8e7; background: #fafbfd; border-radius: 8px; color: #7b879c; padding: 13px; font-size: 13px; line-height: 1.65; margin-bottom: 14px; }
.ai-optimized { margin-top: 12px; background: #f4f8ff; border-left: 3px solid #5d88c7; padding: 14px; color: #3e4c65; font-size: 14px; line-height: 1.8; }
.ai-optimized-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 7px; }
.ai-optimized b { color: #16305c; display: block; }
.ai-optimized-head .btn { flex: 0 0 auto; }
.ai-optimized-content { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.9; }
.ai-optimized-heading { color: #16305c; font-weight: 700; }
.ai-optimized small { display: block; color: #8a93a6; font-size: 11px; margin-top: 8px; }
.ai-highlight { background: #fff1a8; color: inherit; border-radius: 3px; padding: 1px 2px; box-decoration-break: clone; -webkit-box-decoration-break: clone; }
.ai-added { font-weight: 600; }
.ai-highlight-key { display: inline-block; width: 10px; height: 10px; background: #fff1a8; border: 1px solid #e3ca61; border-radius: 2px; vertical-align: -1px; margin-right: 4px; }
.ai-disclaimer { color: #9aa5b7; background: #f0f2f5; border-radius: 8px; padding: 12px 14px; font-size: 12px; line-height: 1.65; }
.ai-teacher-note { color: #64718a; font-size: 13px; line-height: 1.7; margin-bottom: 14px; }
.ai-weak-summary { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; background: #fff8e8; color: #795717; padding: 12px 14px; border-radius: 10px; margin-bottom: 12px; font-size: 13px; }
.ai-weak-summary span, .ai-teacher-dims span { background: #fff; border-radius: 12px; padding: 4px 8px; font-size: 12px; }
.ai-teacher-record { background: #fff; border-radius: 10px; box-shadow: 0 2px 8px rgba(22,48,92,.06); margin-bottom: 9px; }
.ai-teacher-record summary { list-style: none; cursor: pointer; padding: 14px 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.ai-teacher-record summary::-webkit-details-marker { display: none; }
.ai-teacher-record summary b { color: #16305c; display: block; }
.ai-teacher-record summary small { color: #8a93a6; display: block; margin-top: 4px; }
.ai-teacher-record summary em { color: #277d41; font-style: normal; font-weight: 700; white-space: nowrap; }
.ai-teacher-record-body { border-top: 1px solid #eef1f5; padding: 14px 16px; color: #53627d; font-size: 13px; line-height: 1.75; }
.ai-teacher-record-body p { margin-bottom: 10px; white-space: pre-wrap; }
.ai-teacher-dims { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 10px; }
.ai-teacher-dims span { color: #277d41; background: #edf8f0; }

@media (max-width: 560px) {
  .notice-admin-item { flex-direction: column; }
  .notice-admin-actions { align-self: flex-end; }
  .exam-head { align-items: flex-start; flex-direction: column; }
  .exam-actions { width: 100%; justify-content: space-between; }
  .score-board-head { padding: 16px; }
  .score-board-body { padding: 0 16px 16px; }
  .grade-grid { grid-template-columns: repeat(2, 1fr); }
  .basic-score-hero { align-items: flex-start; gap: 8px; flex-direction: column; }
  .ai-grading-hero, .ai-score-card { align-items: flex-start; flex-direction: column; }
  .ai-plan, .ai-score-note { border-left: 0; border-top: 1px solid rgba(255,255,255,.24); padding: 12px 0 0; align-items: flex-start; width: 100%; }
  .ai-form-grid, .ai-dimension-grid, .ai-structure-grid, .ai-knowledge-table, .ai-language-table article { grid-template-columns: 1fr; }
  .ai-form-actions, .ai-result-head { align-items: flex-start; flex-direction: column; }
  .ai-form-actions { align-items: flex-end; }
  .ai-history-item { align-items: flex-start; flex-direction: column; }
  .ai-history-actions { justify-content: flex-start; }
}
.material-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.material-actions .btn { text-decoration: none; white-space: nowrap; }
.test-stage-section { margin: 0 0 28px; }
.test-stage-section h3 { margin: 0 0 16px; padding-left: 12px; border-left: 4px solid #e8b643; color: #16305c; }
.permission-matrix-intro { margin-bottom: 14px; }
.permission-matrix-scroll { overflow-x: auto; border: 1px solid #dce5f1; border-radius: 14px; background: #fff; box-shadow: 0 4px 14px rgba(22, 48, 92, .04); }
.permission-matrix { border-collapse: separate; border-spacing: 0; min-width: 1450px; width: 100%; color: #233957; font-size: 12px; }
.permission-matrix caption { text-align: left; padding: 17px 20px 12px; font-size: 16px; font-weight: 800; color: #16305c; }
.permission-matrix th, .permission-matrix td { border-top: 1px solid #e6ecf4; border-right: 1px solid #e6ecf4; padding: 8px 5px; text-align: center; }
.permission-matrix tr > :last-child { border-right: 0; }
.permission-matrix thead th { font-weight: 800; white-space: nowrap; }
.permission-level-one th { background: #e9f0fa; color: #16305c; }
.permission-level-one th[colspan] { background: #dce9fa; }
.permission-level-two th { background: #f3f7fc; color: #244878; }
.permission-level-two th[colspan] { background: #e8f1fd; }
.permission-level-three th { background: #f7f9fd; color: #526784; }
.permission-matrix thead small { display: block; margin-top: 3px; font-size: 11px; font-weight: 500; color: #7d8da7; }
.permission-matrix tbody th { min-width: 132px; background: #fff; color: #16305c; text-align: left; font-weight: 750; white-space: nowrap; }
.permission-matrix tbody tr:nth-child(even) th, .permission-matrix tbody tr:nth-child(even) td { background: #fafbfd; }
.permission-matrix thead tr:first-child th:first-child, .permission-matrix tbody th { position: sticky; left: 0; z-index: 1; }
.permission-matrix thead tr:first-child th:first-child { z-index: 2; }
.permission-pending { color: #a0abbd; font-size: 12px; white-space: nowrap; }
.permission-matrix-note { margin-top: 12px; line-height: 1.6; }
.permission-editor-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0 0 14px; }
.permission-editor-bar label { color: #526784; font-size: 13px; font-weight: 700; }
.permission-editor-bar select { border: 1px solid #cbd8ea; border-radius: 9px; padding: 9px 12px; color: #16305c; background: #fff; min-width: 190px; font: inherit; }
#permissionDraftMessage { color: #657590; font-size: 12px; }
.permission-matrix tbody tr.permission-editing-row > th,
.permission-matrix tbody tr.permission-editing-row > td { background: #edf5ff; }
.permission-cell-select { width: 86px; max-width: 100%; min-width: 78px; border: 1px solid #c9d7e9; border-radius: 7px; padding: 6px 2px; background: #fff; color: #16305c; font: inherit; font-size: 11px; font-weight: 650; }
.permission-cell-select:focus { outline: 2px solid #608bd0; outline-offset: 1px; }
.permission-value { display: inline-block; white-space: nowrap; border-radius: 12px; padding: 4px 8px; font-size: 12px; font-weight: 700; }
.permission-unset { color: #8c9ab0; background: #f0f3f7; }
.permission-allow { color: #247144; background: #e6f6ec; }
.permission-deny { color: #a94432; background: #fff0eb; }
.permission-row-progress { min-width: 105px; color: #657590; font-size: 12px; white-space: nowrap; }
.permission-active-section { color: #16305c; background: #e6effd; border-radius: 9px; padding: 9px 12px; font-size: 13px; font-weight: 800; }
.permission-section-switch { background: #eef2f8; color: #365375; }
.permission-matrix tbody td.permission-replay-cell { background: #f3f8ff; }
.permission-matrix tbody td.permission-edit-cell { background: #f3f8ff; }
.permission-matrix tbody td.permission-saved-cell { background: #fafbfd; }
.permission-matrix tbody td.permission-unconfirmed-cell { background: #fafbfd; }
.permission-expand-button { margin-left: auto; background: #e7eefb; color: #16305c; }
body.permission-fullscreen { overflow: hidden; }
body.permission-fullscreen #panePermissions { position: fixed; inset: 0; z-index: 1000; display: block !important; box-sizing: border-box; overflow: auto; padding: 18px 24px 30px; background: #f2f5fb; }
body.permission-fullscreen #panePermissions .section { max-width: none; width: 100%; margin: 0; }
body.permission-fullscreen #panePermissions .permission-matrix { min-width: 1450px; }
body.permission-fullscreen #panePermissions .permission-matrix-scroll { max-height: calc(100vh - 205px); overflow: auto; }
body.permission-fullscreen #panePermissions .permission-expand-button { background: #16305c; color: #fff; }
@media (max-width: 720px) { .permission-expand-button { margin-left: 0; } body.permission-fullscreen #panePermissions { padding: 14px; } }
