:root {
  --bg: #f4f7fb;
  --panel: #ffffff;
  --text: #17211b;
  --muted: #657267;
  --line: #dce5de;
  --primary: #1f6feb;
  --primary-dark: #1859bd;
  --primary-soft: #eaf2ff;
  --warn: #b05d00;
  --danger: #b42318;
  --blue: #1f6feb;
  --green: #1f8f61;
  --orange: #d97706;
  --shadow: 0 12px 28px rgba(26, 45, 34, 0.08);
  --shadow-press: 0 5px 12px rgba(26, 45, 34, 0.1);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: radial-gradient(circle at top, #eef5ff 0, var(--bg) 360px);
  color: var(--text);
  font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  letter-spacing: 0;
}

body.quiz-screen-active {
  height: 100vh;
  overflow: hidden;
}

button,
input,
select {
  font: inherit;
}

button {
  transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease, border-color 0.12s ease;
  -webkit-tap-highlight-color: transparent;
}

button:active {
  transform: translateY(1px);
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid rgba(31, 111, 235, 0.22);
  outline-offset: 2px;
}

.app-shell {
  min-height: 100vh;
  padding: 18px;
}

.phone-frame {
  max-width: 430px;
  min-height: calc(100vh - 36px);
  margin: 0 auto;
  background: #f7f9fc;
  border: 1px solid #dbe6f2;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.topbar {
  padding: 18px 20px;
  background: #ffffff;
  border-bottom: 1px solid var(--line);
}

.topbar h1 {
  margin: 0;
  font-size: 24px;
  line-height: 1.25;
}

.topbar p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 16px;
}

.mini-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 54px;
  padding: 0 14px;
  color: #ffffff;
  background: linear-gradient(135deg, #235a9b, #1f4f8f);
  font-size: 17px;
}

.mini-top strong {
  font-size: 17px;
}

.student-top-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 44%;
}

.student-top-actions #studentName {
  max-width: 86px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: right;
}

.switch-account {
  min-width: 76px;
  min-height: 30px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
  font-size: 13px;
  line-height: 1;
}

.mini-main {
  min-height: calc(100vh - 90px);
  padding: 18px 14px 28px;
  background: linear-gradient(180deg, #eef4fb 0%, #f7f9fc 42%, #f7f9fc 100%);
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 8px 0 16px;
}

.section-head h1 {
  margin: 0;
  font-size: 24px;
  color: #203248;
}

.section-head span {
  color: #a2acb8;
  font-size: 15px;
}

.library-card {
  display: flex;
  gap: 16px;
  align-items: center;
  min-height: 104px;
  border: 1px solid #e1eaf4;
  border-radius: 8px;
  padding: 18px;
  margin-bottom: 16px;
  background: #fff;
  box-shadow: 0 8px 18px rgba(23, 64, 120, 0.05);
}

.muted-card h2,
.library-card h2 {
  margin: 0 0 6px;
  font-size: 20px;
}

.muted-card p,
.library-card p {
  margin: 0;
  color: #a1aab4;
  font-size: 15px;
}

.library-icon {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 8px;
  color: #d06c12;
  background: #fff3e5;
  font-size: 30px;
}

.activate-card {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  min-height: 96px;
  border: 0;
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 18px;
  color: #fff;
  background: linear-gradient(135deg, #337bdb, #245c9e);
  box-shadow: 0 12px 20px rgba(31, 92, 168, 0.18);
  text-align: left;
  cursor: pointer;
}

.activate-card:hover {
  box-shadow: 0 14px 24px rgba(31, 92, 168, 0.22);
}

.activate-card .plus-box {
  display: grid;
  place-items: center;
  flex: 0 0 68px;
  width: 68px;
  height: 68px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.16);
  font-size: 34px;
}

.activate-card strong,
.activate-card em {
  display: block;
}

.activate-card strong {
  font-size: 20px;
  font-style: normal;
  margin-bottom: 6px;
}

.activate-card em {
  color: rgba(255, 255, 255, 0.78);
  font-size: 15px;
  font-style: normal;
}

.activate-card b {
  margin-left: auto;
  font-size: 38px;
  font-weight: 400;
}

.quick-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 18px;
}

.big-action {
  min-height: 116px;
  border: 0;
  border-radius: 8px;
  color: #fff;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 10px 18px rgba(34, 60, 94, 0.12);
}

.big-action:hover {
  box-shadow: 0 14px 24px rgba(34, 60, 94, 0.16);
}

.big-action:active {
  box-shadow: var(--shadow-press);
}

.big-action span,
.big-action strong {
  display: block;
}

.big-action span {
  font-size: 34px;
  line-height: 1;
  margin-bottom: 10px;
}

.big-action strong {
  font-size: 21px;
}

.big-action.blue {
  background: linear-gradient(135deg, #2d74d8, #1f5ca8);
}

.big-action.orange {
  background: linear-gradient(135deg, #e89532, #c96a12);
}

.big-action.green {
  background: linear-gradient(135deg, #2b9d76, #16745c);
}

.big-action:disabled,
.big-action.disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

.practice-card.disabled {
  opacity: 0.58;
}

.practice-card {
  display: flex;
  gap: 14px;
  align-items: center;
  width: 100%;
  border: 1px solid #c8dcf8;
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 12px;
  background: #ffffff;
  text-align: left;
  cursor: default;
  box-shadow: 0 8px 16px rgba(31, 79, 143, 0.05);
}

.practice-card.secondary {
  border-color: #ecd7ad;
  background: #fffaf2;
}

.practice-card .library-icon {
  width: 56px;
  height: 56px;
  color: #1f6feb;
  background: #eef6ff;
}

.practice-card h2 {
  margin: 0 0 6px;
  font-size: 19px;
}

.practice-card p {
  margin: 0;
  color: #8994a3;
}

.badge {
  display: inline-block;
  border-radius: 999px;
  padding: 4px 8px;
  margin-left: 8px;
  color: #167a58;
  background: #e3f6ec;
  font-size: 13px;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(27, 35, 46, 0.58);
}

.modal-card {
  width: min(460px, 100%);
  border-radius: 8px;
  padding: 24px;
  background: #fff;
  box-shadow: 0 18px 42px rgba(18, 32, 48, 0.22);
}

.modal-card h2 {
  margin: 0 0 20px;
  text-align: center;
}

.button-row.two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 14px;
}

.main {
  padding: 18px;
}

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  margin-bottom: 14px;
}

.panel h2 {
  margin: 0 0 14px;
  font-size: 22px;
}

.field {
  display: block;
  margin-bottom: 14px;
}

.field span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 16px;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #c9d4dd;
  border-radius: 6px;
  padding: 10px 12px;
  background: #fff;
  color: var(--text);
  font-size: 18px;
}

input:focus,
select:focus,
textarea:focus {
  border-color: #6ea2ed;
}

input,
select {
  min-height: 48px;
}

textarea {
  min-height: 180px;
  resize: vertical;
  line-height: 1.5;
}

.button-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.btn {
  min-height: 50px;
  border: 0;
  border-radius: 6px;
  padding: 0 18px;
  color: #fff;
  background: linear-gradient(135deg, #2f78dd, #1f61b8);
  cursor: pointer;
  font-weight: 700;
  box-shadow: 0 7px 14px rgba(31, 97, 184, 0.16);
}

.btn:hover {
  background: linear-gradient(135deg, #286dcc, var(--primary-dark));
  box-shadow: 0 10px 18px rgba(31, 97, 184, 0.2);
}

.btn.secondary {
  color: #17604b;
  background: #e6f5ee;
  box-shadow: none;
}

.btn.blue {
  background: linear-gradient(135deg, #2f78dd, #1f61b8);
}

.btn.ghost {
  color: #334155;
  background: #eef3f7;
  box-shadow: none;
}

.btn.ghost:hover,
.btn.secondary:hover {
  background: #e3ebf2;
  box-shadow: none;
}

.btn.full {
  width: 100%;
  margin-bottom: 10px;
  font-size: 20px;
}

.status {
  min-height: 28px;
  color: var(--muted);
  font-size: 16px;
}

.status.error {
  color: var(--danger);
}

.course-title {
  font-size: 26px;
  font-weight: 800;
  margin-bottom: 6px;
}

.course-label {
  color: var(--muted);
  font-size: 18px;
  margin-bottom: 18px;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 14px;
}

.metric {
  border: 1px solid #dde7ef;
  border-radius: 8px;
  padding: 12px;
  background: #fbfdff;
}

.metric strong {
  display: block;
  font-size: 24px;
}

.metric span {
  color: var(--muted);
  font-size: 14px;
}

.question-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  margin: 0;
  box-shadow: 0 8px 18px rgba(34, 60, 94, 0.05);
}

.question-head {
  color: #41607d;
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 8px;
}

.question-content {
  flex: 0 0 150px;
  min-height: 150px;
  max-height: 150px;
  overflow-y: auto;
  overscroll-behavior: contain;
  font-size: 20px;
  line-height: 1.55;
  margin-bottom: 16px;
  padding-right: 4px;
  word-break: break-word;
}

.option-list {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: 2px;
}

.quiz-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  flex: 0 0 auto;
  margin-top: 14px;
}

#quizView #submitBtn,
#quizView #backHomeBtn {
  flex: 0 0 44px;
  min-height: 44px;
  width: 100%;
  margin: 0;
  font-size: 17px;
}

.quiz-nav .btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.option {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  min-height: 58px;
  padding: 13px 12px;
  border: 1px solid #cfddea;
  border-radius: 8px;
  margin-bottom: 11px;
  background: #ffffff;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(34, 60, 94, 0.04);
}

.option:hover {
  border-color: #8fb7ef;
  background: #f2f7ff;
}

.option:has(input:checked) {
  border-color: #2f78dd;
  background: #edf5ff;
  box-shadow: 0 6px 14px rgba(47, 120, 221, 0.12);
}

.option input {
  width: 20px;
  min-height: 20px;
  margin-top: 4px;
}

.option span {
  font-size: 19px;
  line-height: 1.4;
}

@media (max-width: 420px) {
  .question-card {
    padding: 16px 14px;
  }

  .question-content {
    flex-basis: 142px;
    min-height: 142px;
    max-height: 142px;
    font-size: 19px;
  }

  .option {
    min-height: 58px;
    padding: 12px 11px;
  }

  .option span {
    font-size: 18px;
  }
}

.result-score {
  font-size: 42px;
  font-weight: 800;
  color: var(--primary);
  margin: 8px 0;
}

.review-list {
  margin: 16px 0;
}

.review-item {
  border: 1px solid var(--line);
  border-left: 4px solid var(--danger);
  border-radius: 8px;
  padding: 14px;
  margin-bottom: 12px;
  background: #fff;
}

.review-item.correct {
  border-left-color: var(--primary);
}

.review-item h3 {
  margin: 0 0 10px;
  font-size: 18px;
  line-height: 1.45;
}

.review-line {
  margin: 6px 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.5;
}

.review-line strong {
  color: var(--text);
}

.analysis-box {
  margin-top: 10px;
  padding: 10px;
  border-radius: 6px;
  background: #f3f8f5;
  color: var(--text);
  line-height: 1.6;
}

.hidden {
  display: none !important;
}

.admin-layout {
  display: grid;
  grid-template-columns: 200px 1fr;
  min-height: 100vh;
  background: #f2f5f8;
  color: #233044;
}

.ref-sidebar {
  background: #2f435b;
  color: #c8d4e3;
  overflow-y: auto;
}

.ref-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 54px;
  padding: 0 22px;
  color: #fff;
  font-size: 16px;
  font-weight: 800;
}

.brand-mark {
  width: 28px;
  height: 28px;
  background: linear-gradient(135deg, #d8e1ec, #7f8da3);
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
}

.ref-nav,
.ref-subnav {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 54px;
  border: 0;
  padding: 0 20px;
  color: #d7e2ee;
  background: transparent;
  text-align: left;
  cursor: pointer;
  box-shadow: none;
}

.ref-nav b {
  margin-left: auto;
  font-weight: 400;
}

.ref-subnav {
  min-height: 50px;
  padding-left: 38px;
  color: #e7eef7;
  background: #223348;
}

.ref-nav.active,
.ref-nav:hover,
.ref-subnav.active,
.ref-subnav:hover {
  color: #42a5ff;
  background: #152232;
}

.ref-main {
  min-width: 0;
  background: #fff;
}

.ref-topbar {
  display: flex;
  align-items: center;
  height: 50px;
  border-bottom: 1px solid #e5e9ef;
  background: #fff;
}

.hamburger {
  width: 48px;
  height: 50px;
  border: 0;
  color: #233044;
  background: #fff;
  font-size: 22px;
  box-shadow: none;
}

.crumb {
  color: #66758a;
  font-size: 14px;
}

.agent-quota-top {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: 18px;
  font-size: 13px;
  color: #526277;
}

.agent-quota-top span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 26px;
  padding: 0 10px;
  border: 1px solid #d9e5f5;
  border-radius: 4px;
  background: #f6faff;
}

.agent-quota-top b {
  color: #1d6bd8;
  font-size: 14px;
}

.top-icons {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-left: auto;
  padding-right: 18px;
  color: #4b5563;
  font-size: 22px;
}

.top-icons strong {
  font-size: 14px;
}

.top-action {
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid #d7e1ee;
  border-radius: 6px;
  background: #ffffff;
  color: #2f5f9f;
  font-size: 13px;
  white-space: nowrap;
}

.top-action.ghost {
  color: #6b778c;
}

.check-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 8px;
  padding: 8px;
  border: 1px solid #d8e0ea;
  border-radius: 6px;
  background: #f8fafc;
}

.check-line {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 6px 8px;
  border-radius: 4px;
  background: #fff;
  color: #26364a;
  font-size: 14px;
}

.check-line input {
  width: 16px;
  height: 16px;
}

.avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #e5e7eb;
}

.tab-strip {
  display: flex;
  gap: 4px;
  height: 34px;
  border-bottom: 1px solid #dfe5ec;
  padding: 4px 14px 0;
  background: #fff;
}

.tab-strip button {
  min-height: 26px;
  border: 1px solid #d5dde7;
  border-radius: 0;
  padding: 0 12px;
  color: #233044;
  background: #fff;
  font-size: 13px;
  box-shadow: none;
}

.tab-strip button.active {
  border-color: #409eff;
  color: #fff;
  background: #409eff;
}

.ref-view {
  padding: 20px;
  background: #fff;
}

.stat-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
  margin-bottom: 20px;
}

.dash-stat {
  display: grid;
  grid-template-columns: 64px 1fr;
  grid-template-rows: 34px 24px;
  align-items: center;
  min-height: 100px;
  border: 1px solid #dde5ee;
  border-radius: 6px;
  padding: 16px 20px;
  background: #fff;
}

.dash-stat span {
  grid-row: 1 / 3;
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border-radius: 12px;
  color: #fff;
  font-size: 28px;
}

.dash-stat strong {
  padding-left: 18px;
  color: #1f2937;
  font-size: 30px;
  line-height: 1;
}

.dash-stat em {
  padding-left: 18px;
  color: #6b7280;
  font-style: normal;
}

.dash-stat.purple span { background: linear-gradient(135deg, #7f6bd8, #6548ba); }
.dash-stat.cyan span { background: linear-gradient(135deg, #35c8e8, #1fb6d4); }
.dash-stat.pink span { background: linear-gradient(135deg, #ec78c9, #e54c9d); }
.dash-stat.green span { background: linear-gradient(135deg, #3fe490, #22cf79); }
.dash-stat.orange span { background: linear-gradient(135deg, #ff9b77, #ffd549); }

.ref-card,
.chart-card {
  position: relative;
  border: 1px solid #dde5ee;
  border-radius: 4px;
  margin-bottom: 20px;
  padding: 16px 20px;
  background: #fff;
}

.ref-card.compact h2,
.chart-card h2 {
  margin: 0 0 14px;
  font-size: 16px;
  font-weight: 500;
}

.ref-filter {
  display: grid;
  grid-template-columns: repeat(3, minmax(250px, 1fr));
  gap: 18px 34px;
  margin-bottom: 18px;
}

.ref-filter label {
  display: grid;
  grid-template-columns: 70px 1fr;
  align-items: center;
  gap: 10px;
}

.ref-filter label span {
  color: #233044;
  font-weight: 700;
  text-align: right;
}

.ref-filter input,
.ref-filter select {
  min-height: 32px;
  border: 1px solid #d6dee8;
  border-radius: 4px;
  padding: 5px 10px;
  font-size: 14px;
}

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

.student-ops-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 12px;
}

.quick-workbench {
  display: grid;
  grid-template-columns: repeat(4, minmax(160px, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.quick-workbench button {
  display: grid;
  gap: 6px;
  min-height: 74px;
  border: 1px solid #dbe6f3;
  border-radius: 6px;
  padding: 14px 16px;
  background: #fff;
  color: #26364a;
  text-align: left;
  box-shadow: 0 4px 12px rgba(37, 70, 116, 0.05);
}

.quick-workbench button:hover {
  border-color: #2677d9;
  background: #f7fbff;
}

.quick-workbench strong {
  color: #155fb3;
  font-size: 16px;
}

.quick-workbench span {
  color: #63758c;
  font-size: 13px;
  line-height: 1.4;
}

.agent-metric-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(120px, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.agent-metric {
  display: grid;
  gap: 6px;
  padding: 14px 16px;
  border: 1px solid #d9e6f5;
  border-radius: 6px;
  background: #fff;
}

.agent-metric span {
  color: #65758d;
  font-size: 13px;
}

.agent-metric strong {
  color: #155fb3;
  font-size: 24px;
  line-height: 1;
}

.summary-chip {
  min-height: 34px;
  border: 1px solid #d6e1ee;
  border-radius: 6px;
  padding: 0 14px;
  background: #f8fbff;
  color: #38506d;
  font-size: 14px;
  box-shadow: none;
}

.summary-chip.active,
.summary-chip:hover {
  border-color: #2677d9;
  background: #eef6ff;
  color: #145fb3;
}

.student-filter-card {
  margin-bottom: 12px;
}

.filter-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(170px, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.filter-grid label {
  display: grid;
  gap: 6px;
}

.filter-grid span {
  color: #42536b;
  font-size: 13px;
  font-weight: 700;
}

.filter-grid input,
.filter-grid select {
  min-height: 34px;
  border: 1px solid #d6dee8;
  border-radius: 4px;
  padding: 5px 10px;
  background: #fff;
  font-size: 14px;
}

.batch-summary,
.student-card-summary {
  display: grid;
  gap: 4px;
  margin-bottom: 12px;
  padding: 12px;
  border: 1px solid #d9e6f5;
  border-radius: 6px;
  background: #f7fbff;
  color: #40536a;
}

.batch-summary strong {
  color: #155fb3;
  font-size: 16px;
}

.batch-summary span,
.student-card-summary p {
  margin: 0;
  font-size: 13px;
}

.card-expiry-row {
  align-items: center;
  gap: 12px;
}

.card-expiry-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.card-expiry-actions input[type="date"] {
  width: 150px;
  min-height: 34px;
  border: 1px solid #d6dee8;
  border-radius: 6px;
  padding: 0 8px;
  background: #fff;
}

.small-btn {
  min-height: 34px;
  padding: 0 12px;
  font-size: 13px;
}

.filter-actions .btn,
.action-row .outline,
.ref-card .btn {
  min-height: 32px;
  border-radius: 4px;
  padding: 0 16px;
  font-size: 14px;
  box-shadow: none;
}

.btn.export {
  position: absolute;
  right: 96px;
  bottom: 36px;
  min-height: 32px;
  background: #67c23a;
}

.action-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 4px 0 10px;
}

.outline {
  border: 1px solid #d6dee8;
  border-radius: 4px;
  background: #fff;
  cursor: pointer;
}

.outline.blue { color: #409eff; border-color: #b8d8ff; background: #ecf5ff; }
.outline.green { color: #67c23a; border-color: #c2e7b0; background: #f0f9eb; }
.outline.orange { color: #e6a23c; border-color: #f5dab1; background: #fdf6ec; }
.outline.gray { color: #606266; border-color: #dcdfe6; background: #f4f4f5; }

.ref-tools {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin: 14px 0 8px;
}

.ref-tools button {
  width: 34px;
  height: 34px;
  border: 1px solid #d9e1eb;
  border-radius: 50%;
  color: #4b5563;
  background: #fff;
  box-shadow: none;
}

.ref-table {
  width: 100%;
  border-collapse: collapse;
  border: 0;
  font-size: 14px;
}

.ref-table th,
.ref-table td {
  border-bottom: 1px solid #e7ecf2;
  padding: 11px 16px;
  text-align: center;
  vertical-align: middle;
}

.ref-table th {
  color: #233044;
  background: #f6f7f9;
  font-weight: 700;
}

.empty-cell {
  height: 60px;
  color: #8b97a8;
}

.pager {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin: 20px 0;
}

.pager button,
.pager select,
.pager input {
  width: auto;
  min-height: 32px;
  border: 1px solid #d6dee8;
  border-radius: 4px;
  padding: 0 12px;
  background: #fff;
  box-shadow: none;
  font-size: 14px;
}

.pager button.active {
  border-color: #409eff;
  color: #fff;
  background: #409eff;
}

.pager input {
  width: 56px;
  text-align: center;
}

.student-pager {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  margin: 14px 0 20px;
  color: #4f6075;
  font-size: 13px;
}

.student-pager strong {
  color: #253348;
  font-weight: 700;
}

.student-pager select,
.student-pager input {
  height: 30px;
  min-height: 30px;
  border: 1px solid #d6dee8;
  border-radius: 4px;
  background: #ffffff;
  box-shadow: none;
  color: #253348;
  font-size: 13px;
}

.student-pager select {
  padding: 0 8px;
}

.student-pager input {
  width: 52px;
  padding: 0 6px;
  text-align: center;
}

.student-pager label {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.student-pager button {
  min-height: 30px;
  padding: 0 10px;
  font-size: 13px;
}

.student-pager button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.tag {
  display: inline-block;
  border-radius: 4px;
  padding: 4px 8px;
}

.tag.green { color: #67c23a; background: #f0f9eb; border: 1px solid #c2e7b0; }
.tag.orange { color: #e6a23c; background: #fdf6ec; border: 1px solid #f5dab1; }
.tag.blue { color: #409eff; background: #ecf5ff; border: 1px solid #b8d8ff; }
.danger-text { color: #ff4d4f; }

.fake-chart {
  min-height: 390px;
  padding: 30px 40px;
  background: linear-gradient(180deg, #f7f9fc 0%, #ffffff 100%);
}

.legend {
  text-align: right;
  color: #606266;
}

.legend span {
  display: inline-block;
  width: 8px;
  height: 8px;
  margin: 0 8px 0 22px;
}

.legend .good,
.bar.good { background: #67c23a; }
.legend .normal,
.bar.normal { background: #409eff; }
.legend .bad,
.bar.bad { background: #f56c6c; }

.ring-wrap {
  position: relative;
  display: grid;
  place-items: center;
  height: 280px;
}

.ring {
  width: 210px;
  height: 210px;
  border-radius: 50%;
  background: conic-gradient(#67c23a calc(var(--p, 0) * 1%), #f56c6c 0);
  box-shadow: inset 0 0 0 26px #eef3f8;
}

.ring-center {
  position: absolute;
  display: grid;
  place-items: center;
  width: 118px;
  height: 118px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 10px 22px rgba(35, 50, 78, 0.08);
}

.ring-center strong {
  font-size: 30px;
  color: #2b3a55;
}

.ring-center span {
  color: #8a97a8;
  font-size: 14px;
}

.chart-summary {
  display: flex;
  justify-content: center;
  gap: 30px;
  color: #5b6577;
  font-size: 14px;
}

.chart-summary span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.good-dot,
.bad-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.good-dot { background: #67c23a; }
.bad-dot { background: #f56c6c; }

.bar-group {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 42px;
  height: 300px;
  border-bottom: 1px solid #dfe5ec;
}

.bar {
  position: relative;
  width: 96px;
  border-radius: 4px 4px 0 0;
}

.bar b {
  position: absolute;
  top: -24px;
  width: 100%;
  text-align: center;
  color: #606266;
}

.admin-shell {
  max-width: 1180px;
  margin: 0 auto;
  padding: 22px;
}

.login-page {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 24px;
  background: linear-gradient(135deg, #eef5ff, #f7fbff);
}

.login-box {
  width: min(420px, 100%);
  border: 1px solid #dce5f2;
  border-radius: 8px;
  padding: 28px;
  background: #fff;
  box-shadow: var(--shadow);
}

.login-box h1 {
  margin: 0 0 22px;
  text-align: center;
  font-size: 26px;
}

.manager {
  display: grid;
  grid-template-columns: 232px 1fr;
  min-height: 100vh;
  background: #f1f5f9;
}

.sidebar {
  background: #263447;
  color: #d9e4f2;
  padding: 0 12px 20px;
}

.brand {
  height: 62px;
  display: flex;
  align-items: center;
  padding: 0 10px;
  color: #fff;
  font-size: 19px;
  font-weight: 800;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 12px;
}

.nav-group {
  padding: 16px 10px 6px;
  color: #8494aa;
  font-size: 13px;
}

.nav-item {
  display: block;
  width: 100%;
  min-height: 42px;
  border: 0;
  border-radius: 6px;
  padding: 0 12px;
  margin-bottom: 4px;
  color: #dbe6f5;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.nav-item:hover,
.nav-item.active {
  color: #fff;
  background: #2f78dd;
}

.manager-main {
  min-width: 0;
  padding: 18px;
}

.manager-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  min-height: 70px;
  border: 1px solid #dde7ef;
  border-radius: 8px;
  padding: 14px 18px;
  margin-bottom: 16px;
  background: #fff;
}

.manager-top h1 {
  margin: 0;
  font-size: 24px;
}

.manager-top p {
  margin: 5px 0 0;
  color: var(--muted);
}

.view-panel {
  display: block;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 14px;
}

.stat-card {
  border: 1px solid #dde7ef;
  border-radius: 8px;
  padding: 18px;
  background: #fff;
}

.stat-card strong {
  display: block;
  color: #1f61b8;
  font-size: 34px;
  line-height: 1;
  margin-bottom: 8px;
}

.stat-card span {
  color: var(--muted);
}

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

/* Reference backend alignment: compact Element-style admin pages. */
.admin-layout {
  grid-template-columns: 200px 1fr;
  background: #ffffff;
  color: #303133;
  font-size: 14px;
}

.ref-sidebar {
  background: #304156;
  color: #bfcbd9;
}

.ref-brand {
  height: 50px;
  padding: 0 16px;
  color: #ffffff;
  font-size: 15px;
  white-space: nowrap;
}

.brand-mark {
  width: 34px;
  height: 24px;
  border-radius: 2px;
  background: repeating-linear-gradient(135deg, #d7dee8 0 3px, #8fa0b5 3px 6px);
  clip-path: polygon(0 0, 78% 0, 100% 50%, 78% 100%, 0 100%, 20% 50%);
}

.ref-nav,
.ref-subnav {
  min-height: 56px;
  padding: 0 20px;
  color: #d7e4f2;
  font-size: 14px;
}

.ref-nav span {
  width: 20px;
  color: #bfcbd9;
  text-align: center;
}

.ref-subnav {
  min-height: 50px;
  padding-left: 70px;
  background: #1f2d3d;
  color: #d7e4f2;
}

.ref-nav.active,
.ref-nav:hover,
.ref-subnav.active,
.ref-subnav:hover {
  color: #409eff;
  background: #1f2d3d;
}

.ref-main {
  background: #ffffff;
}

.ref-topbar {
  height: 50px;
  border-bottom: 1px solid #eef0f3;
  box-shadow: 0 1px 3px rgba(0, 21, 41, 0.06);
}

.hamburger {
  color: #303133;
  font-size: 22px;
}

.crumb {
  color: #606266;
  font-size: 14px;
}

.agent-quota-top {
  margin-left: 18px;
}

.top-icons {
  gap: 14px;
  color: #606266;
  font-size: 20px;
}

.top-icons strong {
  color: #303133;
  font-size: 14px;
}

.tab-strip {
  height: 34px;
  padding: 4px 15px 0;
  border-bottom: 1px solid #d8dce5;
  background: #ffffff;
  box-shadow: 0 1px 3px rgba(0, 21, 41, 0.08);
}

.tab-strip button {
  min-height: 26px;
  border: 1px solid #d8dce5;
  border-radius: 0;
  padding: 0 10px;
  color: #495060;
  background: #ffffff;
  font-size: 13px;
}

.tab-strip button.active {
  border-color: #409eff;
  color: #ffffff;
  background: #409eff;
}

.ref-view {
  padding: 20px;
  background: #ffffff;
}

.ref-filter {
  display: grid;
  grid-template-columns: repeat(4, minmax(230px, 1fr));
  gap: 18px 28px;
  margin: 0 0 18px;
  align-items: center;
}

.ref-filter label {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 10px;
  align-items: center;
}

.ref-filter label span {
  color: #303133;
  font-weight: 700;
  text-align: right;
}

.ref-filter input,
.ref-filter select {
  min-height: 32px;
  height: 32px;
  border: 1px solid #dcdfe6;
  border-radius: 4px;
  padding: 0 11px;
  color: #606266;
  background: #ffffff;
  font-size: 14px;
}

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

.filter-actions .btn,
.action-row .outline,
.ref-card .btn {
  min-height: 32px;
  height: 32px;
  border-radius: 4px;
  padding: 0 15px;
  font-size: 14px;
  font-weight: 500;
  box-shadow: none;
}

.btn.blue {
  background: #409eff;
}

.btn.blue:hover {
  background: #66b1ff;
}

.btn.ghost {
  border: 1px solid #dcdfe6;
  color: #606266;
  background: #ffffff;
}

.action-row {
  gap: 10px;
  margin: 6px 0 10px;
}

.outline {
  height: 32px;
  min-height: 32px;
  border-radius: 4px;
  padding: 0 15px;
  font-size: 14px;
  font-weight: 500;
}

.outline.blue { color: #409eff; border-color: #b3d8ff; background: #ecf5ff; }
.outline.green { color: #67c23a; border-color: #c2e7b0; background: #f0f9eb; }
.outline.orange { color: #e6a23c; border-color: #f5dab1; background: #fdf6ec; }
.outline.gray { color: #909399; border-color: #d3d4d6; background: #f4f4f5; }

.ref-tools {
  margin-left: auto;
  margin-top: 0;
  margin-bottom: 0;
}

.ref-tools button {
  width: 32px;
  height: 32px;
  border-color: #dcdfe6;
  color: #606266;
  background: #ffffff;
}

.table-wrap {
  width: 100%;
  overflow-x: auto;
}

.ref-table {
  min-width: 1080px;
  color: #303133;
  font-size: 13px;
}

.ref-table th,
.ref-table td {
  height: 36px;
  border-bottom: 1px solid #ebeef5;
  padding: 7px 10px;
  text-align: center;
  white-space: nowrap;
}

.ref-table th {
  color: #303133;
  background: #f8f8f9;
  font-weight: 700;
}

.ref-table tbody tr:hover {
  background: #f5f7fa;
}

.tag {
  border-radius: 4px;
  padding: 3px 7px;
  line-height: 1.2;
}

.tag.red { color: #f56c6c; background: #fef0f0; border: 1px solid #fbc4c4; }

.student-mobile-list {
  display: none;
}

.student-table-panel .table-wrap {
  border: 1px solid #edf1f6;
  border-radius: 6px;
  background: #ffffff;
}

.student-table-panel .ref-table {
  min-width: 1040px;
  table-layout: fixed;
}

.student-table-panel .ref-table th,
.student-table-panel .ref-table td {
  overflow: hidden;
  padding: 6px 7px;
  font-size: 12px;
  text-overflow: ellipsis;
}

.student-table-panel .ref-table th:nth-child(1),
.student-table-panel .ref-table td:nth-child(1) { width: 34px; }
.student-table-panel .ref-table th:nth-child(2),
.student-table-panel .ref-table td:nth-child(2) { width: 210px; }
.student-table-panel .ref-table th:nth-child(3),
.student-table-panel .ref-table td:nth-child(3) { width: 200px; }
.student-table-panel .ref-table th:nth-child(4),
.student-table-panel .ref-table td:nth-child(4) { width: 126px; }
.student-table-panel .ref-table th:nth-child(5),
.student-table-panel .ref-table td:nth-child(5) { width: 180px; }
.student-table-panel .ref-table th:nth-child(6),
.student-table-panel .ref-table td:nth-child(6) { width: 122px; }
.student-table-panel .ref-table th:nth-child(7),
.student-table-panel .ref-table td:nth-child(7) { width: 58px; }
.student-table-panel .ref-table th:nth-child(8),
.student-table-panel .ref-table td:nth-child(8) { width: 160px; }

.student-table-panel .ref-table td:nth-child(2),
.student-table-panel .ref-table td:nth-child(3),
.student-table-panel .ref-table td:nth-child(5),
.student-table-panel .ref-table td:last-child {
  white-space: normal;
}

.student-table-panel input[type="checkbox"] {
  width: 15px;
  height: 15px;
  min-height: 0;
  margin: 0;
  vertical-align: middle;
  box-shadow: none;
}

.student-cell {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 2px 8px;
  text-align: left;
  line-height: 1.25;
}

.student-cell strong {
  color: #1f2d3d;
  font-size: 13px;
}

.student-cell span {
  color: #4f5f73;
  font-size: 12px;
}

.student-cell em {
  grid-column: 1 / -1;
  color: #65758a;
  font-size: 12px;
  font-style: normal;
}

.student-cell i {
  grid-column: 1 / -1;
  color: #8592a3;
  font-size: 12px;
  font-style: normal;
}

.bank-cell {
  display: -webkit-box;
  overflow: hidden;
  color: #314155;
  line-height: 1.35;
  text-align: left;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.practice-cell {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
}

.practice-cell span {
  display: grid;
  gap: 2px;
  min-width: 0;
  padding: 5px 4px;
  border-radius: 5px;
  background: #f6f8fb;
  line-height: 1.1;
}

.practice-cell b {
  color: #1f2d3d;
  font-size: 14px;
}

.practice-cell i {
  color: #7a8797;
  font-size: 11px;
  font-style: normal;
}

.practice-cell .good {
  background: #f0f9eb;
}

.practice-cell .good b {
  color: #3c9a24;
}

.practice-cell .warn {
  background: #fff7e8;
}

.practice-cell .warn b {
  color: #d88914;
}

.practice-cell .muted b {
  color: #8a96a8;
}

.link-btn {
  border: 0;
  padding: 0 2px;
  color: #409eff;
  background: transparent;
  box-shadow: none;
  cursor: pointer;
  font-size: 13px;
  line-height: 1.6;
}

.link-btn:hover {
  color: #66b1ff;
  text-decoration: underline;
}

.link-btn.danger {
  color: #d92d20;
}

.pager {
  justify-content: flex-end;
  gap: 10px;
  margin: 20px 0 0;
  color: #606266;
}

.pager button,
.pager select,
.pager input {
  height: 32px;
  min-height: 32px;
  border: 1px solid #dcdfe6;
  border-radius: 4px;
  color: #606266;
  background: #ffffff;
  font-size: 14px;
}

.pager button.active {
  border-color: #409eff;
  color: #ffffff;
  background: #409eff;
}

.stat-row {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 20px;
}

.dash-stat {
  min-height: 92px;
  border: 0;
  border-radius: 4px;
  box-shadow: 0 1px 6px rgba(0, 21, 41, 0.08);
}

.history-modal {
  background: rgba(0, 0, 0, 0.45);
}

.history-card,
.form-modal-card {
  border-radius: 4px;
}

.history-card.wide {
  width: min(1120px, calc(100vw - 48px));
}

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.admin-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  margin-bottom: 18px;
}

.admin-header h1 {
  margin: 0;
}

.admin-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.admin-grid .wide {
  grid-column: 1 / -1;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  font-size: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

th,
td {
  border-bottom: 1px solid var(--line);
  padding: 10px;
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--muted);
  background: #f5f8fb;
}

tbody tr:hover {
  background: #f9fbfe;
}

.student-stats-page {
  background: #fff;
}

.stats-filter {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px 42px;
  margin-bottom: 28px;
}

.stats-filter label {
  display: grid;
  grid-template-columns: 70px 1fr;
  align-items: center;
  gap: 10px;
}

.stats-filter span {
  color: #334155;
  font-weight: 700;
  text-align: right;
}

.stats-filter input,
.stats-filter select {
  min-height: 34px;
  padding: 6px 10px;
  font-size: 14px;
}

.stats-actions {
  display: flex;
  gap: 10px;
  grid-column: 1 / -1;
  padding-left: 0;
}

.stats-actions .btn {
  min-height: 36px;
  padding: 0 18px;
  font-size: 14px;
}

.stats-toolbar {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-bottom: 8px;
}

.round-tool {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid #d8e1eb;
  border-radius: 50%;
  color: #475569;
  background: #fff;
  cursor: pointer;
}

.link-btn {
  border: 0;
  color: #1f6feb;
  background: transparent;
  cursor: pointer;
  font-weight: 700;
}

.history-modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 52px 24px;
  background: rgba(0, 0, 0, 0.45);
}

.history-card {
  position: relative;
  width: min(900px, 100%);
  max-height: calc(100vh - 90px);
  overflow: auto;
  border-radius: 6px;
  padding: 18px 16px 24px;
  background: #fff;
}

.form-modal-card {
  position: relative;
  width: min(500px, 100%);
  max-height: calc(100vh - 90px);
  overflow: auto;
  border-radius: 4px;
  padding: 18px 16px 16px;
  background: #fff;
}

.form-modal-card h2 {
  margin: 0 0 16px;
  color: #303133;
  font-size: 18px;
  font-weight: 500;
}

.student-form {
  display: grid;
  gap: 14px;
}

.student-form label {
  display: grid;
  grid-template-columns: 90px 1fr;
  align-items: start;
  gap: 10px;
}

.student-form label span {
  padding-top: 9px;
  color: #303133;
  text-align: right;
  font-weight: 700;
}

.student-form i {
  color: #f56c6c;
  font-style: normal;
}

.student-form input,
.student-form select,
.student-form textarea {
  min-height: 32px;
  border: 1px solid #dcdfe6;
  border-radius: 4px;
  padding: 5px 10px;
  font-size: 14px;
}

.student-form textarea {
  min-height: 54px;
}

.student-form .check-line {
  align-items: center;
}

.check-line em {
  color: #409eff;
  font-style: normal;
}

.check-line input {
  width: auto;
  min-height: auto;
  margin-right: 6px;
}

.form-tip {
  margin: -2px 0 16px 100px;
  color: #909399;
  font-size: 13px;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 18px;
}

.modal-actions .btn {
  min-height: 32px;
  border-radius: 4px;
  padding: 0 18px;
  font-size: 14px;
  box-shadow: none;
}

.import-box {
  color: #606266;
  font-size: 14px;
}

.upload-drop {
  display: grid;
  place-items: center;
  height: 184px;
  border: 1px dashed #d9e1eb;
  border-radius: 4px;
  margin-bottom: 10px;
}

.upload-drop .cloud {
  color: #a8abb2;
  font-size: 58px;
}

.upload-drop strong {
  color: #606266;
  font-weight: 400;
}

.upload-drop span {
  color: #409eff;
}

.import-check {
  display: block;
  margin: 12px 0 8px;
  color: #409eff;
}

.history-card h2 {
  margin: 0 0 16px;
  font-size: 18px;
  font-weight: 500;
}

.history-close {
  position: absolute;
  top: 12px;
  right: 14px;
  border: 0;
  color: #64748b;
  background: transparent;
  font-size: 22px;
  cursor: pointer;
}

.score-pill {
  display: inline-block;
  min-width: 44px;
  border-radius: 4px;
  padding: 4px 8px;
  text-align: center;
}

.score-pill.pass {
  color: #1f6feb;
  background: #eaf2ff;
  border: 1px solid #bfdbfe;
}

.score-pill.fail {
  color: #d97706;
  background: #fff7ed;
  border: 1px solid #fed7aa;
}

.answer-detail-box {
  margin-top: 14px;
  max-height: 520px;
  overflow: auto;
  border: 1px solid #edf0f5;
  border-radius: 4px;
}

.answer-detail-box .ref-table {
  margin: 0;
  min-width: 780px;
}

.answer-detail-box .ref-table th,
.answer-detail-box .ref-table td {
  vertical-align: top;
}

.tag.red {
  color: #f56c6c;
  background: #fef0f0;
}

.note {
  color: var(--muted);
  line-height: 1.7;
}

@media (max-width: 760px) {
  .manager {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
  }

  .admin-grid,
  .metric-grid,
  .stat-grid,
  .form-grid,
  .two-col,
  .stats-filter {
    grid-template-columns: 1fr;
  }

  .stats-filter label {
    grid-template-columns: 1fr;
  }

  .stats-filter span {
    text-align: left;
  }

  .admin-header {
    align-items: flex-start;
    flex-direction: column;
  }

  html,
  body {
    max-width: 100%;
    overflow-x: hidden;
  }

  .admin-layout {
    display: block;
    width: 100%;
    min-height: 100vh;
    overflow-x: hidden;
    background: #f5f7fb;
  }

  .ref-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 40;
    width: min(82vw, 292px);
    height: 100vh;
    transform: translateX(-105%);
    transition: transform 0.18s ease;
    box-shadow: 8px 0 22px rgba(15, 23, 42, 0.22);
  }

  .admin-layout.sidebar-open .ref-sidebar {
    transform: translateX(0);
  }

  .admin-layout.sidebar-open::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 30;
    background: rgba(15, 23, 42, 0.35);
  }

  .ref-brand {
    height: 52px;
    padding: 0 14px;
  }

  .ref-brand strong {
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .ref-nav,
  .ref-subnav {
    min-height: 48px;
    padding: 0 16px;
    font-size: 15px;
  }

  .ref-subnav {
    padding-left: 52px;
  }

  .ref-main {
    width: 100%;
    min-width: 0;
    background: #f5f7fb;
  }

  .ref-topbar {
    position: sticky;
    top: 0;
    z-index: 25;
    display: grid;
    grid-template-columns: 46px minmax(0, 1fr) auto;
    align-items: center;
    height: auto;
    min-height: 50px;
    gap: 0;
    background: #ffffff;
  }

  .hamburger {
    display: grid;
    place-items: center;
    width: 46px;
    height: 50px;
    font-size: 20px;
  }

  .crumb {
    min-width: 0;
    overflow: hidden;
    padding-right: 8px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .agent-quota-top {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    width: 100%;
    margin: 0;
    padding: 0 10px 8px;
    gap: 6px;
    font-size: 12px;
  }

  .agent-quota-top.hidden {
    display: none !important;
  }

  .agent-quota-top span {
    justify-content: center;
    min-width: 0;
    padding: 0 6px;
  }

  .top-icons {
    grid-column: 3;
    gap: 6px;
    padding-right: 8px;
    font-size: 0;
  }

  .top-icons > span:not(.avatar),
  .top-icons strong {
    display: none;
  }

  .top-action {
    min-height: 30px;
    padding: 0 8px;
    font-size: 12px;
  }

  .avatar {
    display: none;
  }

  .tab-strip {
    position: sticky;
    top: 50px;
    z-index: 20;
    display: flex;
    width: 100%;
    height: auto;
    min-height: 42px;
    overflow-x: auto;
    padding: 6px 8px;
    gap: 6px;
    -webkit-overflow-scrolling: touch;
  }

  .tab-strip button {
    flex: 0 0 auto;
    min-height: 30px;
    white-space: nowrap;
  }

  .ref-view {
    width: 100%;
    min-width: 0;
    padding: 10px;
  }

  .stat-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .dash-stat {
    min-height: 78px;
    padding: 12px 10px;
  }

  .dash-stat span {
    width: 38px;
    height: 38px;
    font-size: 17px;
  }

  .dash-stat strong {
    font-size: 24px;
  }

  .dash-stat em {
    font-size: 12px;
  }

  .ref-card,
  .chart-card {
    width: 100%;
    margin: 10px 0;
    padding: 10px;
    overflow: hidden;
  }

  .ref-filter {
    grid-template-columns: 1fr;
    gap: 10px;
    margin-bottom: 12px;
  }

  .ref-filter label {
    grid-template-columns: 72px minmax(0, 1fr);
    gap: 8px;
  }

  .ref-filter label span {
    text-align: left;
    font-size: 13px;
  }

  .ref-filter input,
  .ref-filter select {
    width: 100%;
    min-width: 0;
  }

  .filter-actions,
  .action-row,
  .modal-actions,
  .pager {
    flex-wrap: wrap;
    justify-content: flex-start;
  }

  .action-row {
    gap: 8px;
  }

  .action-row .outline,
  .filter-actions .btn,
  .ref-card .btn {
    flex: 0 0 auto;
  }

  .ref-tools {
    margin-left: 0;
  }

  .student-ops-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 7px;
  }

  .summary-chip {
    min-height: 30px;
    padding: 0 7px;
    font-size: 12px;
  }

  .student-filter-card {
    padding: 9px;
  }

  .filter-grid {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 10px;
  }

  .filter-grid label:first-child {
    grid-column: 1 / -1;
  }

  .filter-grid span {
    font-size: 12px;
  }

  .filter-grid input,
  .filter-grid select {
    min-height: 32px;
    padding: 4px 8px;
    font-size: 13px;
  }

  .filter-actions {
    gap: 8px;
    font-size: 12px;
  }

  .filter-actions .btn,
  .ref-card .btn {
    min-height: 30px;
    padding: 0 12px;
    font-size: 13px;
  }

  .action-row .outline {
    min-height: 30px;
    padding: 0 11px;
    font-size: 13px;
  }

  .student-table-panel {
    display: none;
  }

  .student-mobile-list {
    display: grid;
    gap: 9px;
  }

  .student-mobile-card {
    display: grid;
    gap: 8px;
    padding: 10px;
    border: 1px solid #e4ebf3;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(31, 56, 88, 0.04);
  }

  .student-mobile-head {
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
  }

  .student-mobile-check {
    display: grid;
    place-items: center;
  }

  .student-mobile-check input,
  .student-row-check,
  #checkAllStudents {
    width: 18px;
    height: 18px;
    margin: 0;
  }

  .student-mobile-head strong {
    display: block;
    color: #1f2d3d;
    font-size: 15px;
    line-height: 1.25;
  }

  .student-mobile-head em {
    display: block;
    margin-top: 2px;
    color: #7b8797;
    font-size: 12px;
    font-style: normal;
    line-height: 1.25;
  }

  .student-mobile-id,
  .student-mobile-bank {
    overflow: hidden;
    color: #3d4b5f;
    font-size: 12px;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .student-mobile-id {
    padding: 0 0 2px 36px;
    color: #5d6b7d;
  }

  .student-mobile-bank {
    padding: 7px 8px;
    border-radius: 6px;
    background: #f6f8fb;
  }

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

  .student-mobile-metrics span {
    display: grid;
    gap: 2px;
    padding: 7px 5px;
    border-radius: 6px;
    background: #f8fbff;
    text-align: center;
  }

  .student-mobile-metrics b {
    color: #1769c2;
    font-size: 15px;
    line-height: 1;
  }

  .student-mobile-metrics i {
    color: #748295;
    font-size: 11px;
    font-style: normal;
  }

  .student-mobile-meta {
    display: grid;
    gap: 3px;
    color: #66758a;
    font-size: 12px;
    line-height: 1.35;
  }

  .student-mobile-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 12px;
    padding-top: 7px;
    border-top: 1px solid #eef2f6;
  }

  .student-mobile-actions .link-btn {
    min-height: 24px;
    font-size: 13px;
  }

  .table-wrap {
    width: 100%;
    max-width: calc(100vw - 20px);
    overflow-x: auto;
    border: 1px solid #ebeef5;
    border-radius: 4px;
    background: #ffffff;
    -webkit-overflow-scrolling: touch;
  }

  .ref-table {
    min-width: 920px;
    font-size: 13px;
  }

  .ref-table th,
  .ref-table td {
    height: 36px;
    padding: 7px 9px;
  }

  .pager {
    gap: 6px;
    font-size: 12px;
  }

  .student-pager {
    justify-content: flex-start;
    gap: 7px;
    margin: 12px 0 18px;
    font-size: 12px;
  }

  .student-pager span:nth-child(2) {
    display: none;
  }

  .student-pager select,
  .student-pager input {
    height: 30px;
    min-height: 30px;
    font-size: 12px;
  }

  .student-pager button {
    min-height: 30px;
    padding: 0 9px;
    font-size: 12px;
  }

  .pager button,
  .pager select,
  .pager input {
    height: 30px;
    min-height: 30px;
  }

  .modal {
    z-index: 60;
    align-items: start;
    padding: 10px;
    overflow-y: auto;
  }

  .modal-card,
  .form-modal-card,
  .history-card,
  .history-card.wide {
    width: 100%;
    max-width: calc(100vw - 20px);
    max-height: calc(100vh - 20px);
    padding: 14px;
    overflow: auto;
  }

  .modal-card h2,
  .form-modal-card h2 {
    margin-bottom: 12px;
    font-size: 17px;
  }

  .student-form label,
  .form-grid,
  .two-col {
    grid-template-columns: 1fr;
  }

  .student-form label span {
    padding-top: 0;
    text-align: left;
  }

  .student-form input,
  .student-form select,
  .student-form textarea {
    width: 100%;
    min-width: 0;
  }

  .form-tip {
    margin: 0 0 12px;
  }

  .history-card .table-wrap,
  .answer-detail-box {
    max-width: 100%;
  }
}

@media (min-width: 761px) and (max-width: 1280px) {
  html,
  body {
    max-width: 100%;
    overflow-x: hidden;
  }

  .admin-layout {
    grid-template-columns: 180px minmax(0, 1fr);
    overflow-x: hidden;
  }

  .ref-sidebar {
    width: 180px;
  }

  .ref-brand {
    padding: 0 12px;
  }

  .ref-brand strong {
    max-width: 126px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .ref-nav,
  .ref-subnav {
    padding: 0 14px;
  }

  .ref-subnav {
    padding-left: 46px;
  }

  .ref-main {
    min-width: 0;
    overflow: hidden;
  }

  .ref-topbar {
    min-width: 0;
  }

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

  .top-icons {
    gap: 8px;
    padding-right: 10px;
  }

  .top-icons > span:not(.avatar) {
    display: none;
  }

  .ref-view {
    min-width: 0;
    padding: 14px;
  }

  .stat-row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
  }

  .ref-card,
  .chart-card {
    overflow: hidden;
  }

  .ref-filter {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px 16px;
  }

  .ref-filter label {
    grid-template-columns: 72px minmax(0, 1fr);
  }

  .ref-filter label span {
    text-align: left;
  }

  .ref-filter input,
  .ref-filter select {
    min-width: 0;
    width: 100%;
  }

  .filter-actions,
  .action-row,
  .pager {
    flex-wrap: wrap;
  }

  .ref-tools {
    margin-left: 0;
  }

  .table-wrap {
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}

/* Student mini-program skin */
.student-app { min-height: 100vh; background: #eef0f4; font-family: "PingFang SC", "Microsoft YaHei", Arial, sans-serif; }
.wx-phone { position: relative; width: min(100vw, 414px); min-height: 100vh; margin: 0 auto; overflow: hidden; background: #f5f6f9; }
.wx-main { min-height: calc(100vh - 50px); padding-bottom: 64px; }
.wx-page { min-height: calc(100vh - 64px); }
.wx-blue-head { position: relative; min-height: 67px; padding: 31px 18px 10px; background: #1f63ff; color: #fff; }
.home-head { display: flex; align-items: flex-start; gap: 12px; }
.wx-title { display: inline-flex; align-items: center; gap: 5px; min-height: 30px; }
.wx-title strong { font-size: 17px; font-weight: 800; }
.wx-title span { font-size: 13px; opacity: 0.9; }
.wx-mine-shortcut { margin-left: auto; min-width: 45px; height: 28px; border: 0; border-radius: 16px; background: rgba(0, 0, 0, 0.08); color: #fff; font-size: 14px; font-weight: 700; }
.wx-capsule { display: inline-flex; align-items: center; gap: 8px; height: 28px; padding: 0 9px; border-radius: 16px; background: rgba(0, 0, 0, 0.16); color: #fff; font-weight: 700; }
.wx-capsule i { width: 1px; height: 14px; background: rgba(255, 255, 255, 0.34); }
.wx-capsule em { width: 15px; height: 15px; border: 2px solid #fff; border-radius: 50%; }
.home-action-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin: 17px 18px 24px; }
.study-tile { display: grid; place-items: center; align-content: center; gap: 14px; min-height: 128px; border: 0; border-radius: 9px; color: #fff; box-shadow: none; }
.study-tile strong { font-size: 20px; font-weight: 800; }
.study-tile.blue { background: #225cff; }
.study-tile.orange { background: #ff7608; }
.play-icon { width: 0; height: 0; border-top: 14px solid transparent; border-bottom: 14px solid transparent; border-left: 25px solid #fff; margin-left: 7px; }
.refresh-icon { font-size: 38px; line-height: 1; }
.bank-title-row { display: flex; justify-content: space-between; align-items: center; padding: 0 18px; margin-bottom: 13px; }
.bank-title-row h2 { margin: 0; color: #1d2433; font-size: 20px; font-weight: 800; }
.bank-title-row span { color: #a4adbb; font-size: 14px; }
.bank-empty-card { display: flex; align-items: center; gap: 14px; min-height: 85px; margin: 0 18px 15px; padding: 16px; border: 1px solid #e2e5ec; border-radius: 10px; background: #fff; }
.empty-icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 12px; background: #fff5ee; color: #ff6b1a; font-size: 27px; }
.bank-empty-card h3 { margin: 0 0 5px; font-size: 18px; color: #1f2937; }
.bank-empty-card p { margin: 0; color: #8d96a5; font-size: 14px; }
.activate-banner { display: flex; align-items: center; gap: 14px; width: calc(100% - 36px); min-height: 84px; margin: 0 18px; padding: 14px 15px; border: 0; border-radius: 10px; background: #225cff; color: #fff; text-align: left; box-shadow: 0 8px 16px rgba(34, 92, 255, 0.22); }
.activate-banner .plus-box { display: grid; place-items: center; flex: 0 0 50px; width: 50px; height: 50px; border-radius: 10px; background: rgba(255, 255, 255, 0.2); font-size: 26px; }
.activate-banner strong, .activate-banner em { display: block; }
.activate-banner strong { margin-bottom: 4px; font-size: 16px; font-weight: 800; }
.activate-banner em { color: rgba(255, 255, 255, 0.86); font-size: 13px; font-style: normal; }
.activate-banner b { margin-left: auto; font-size: 28px; font-weight: 400; }
#practiceChoices { margin: 0 18px 15px; }
#practiceChoices .wx-bank-card { display: flex; align-items: center; gap: 15px; width: 100%; min-height: 86px; margin-bottom: 12px; padding: 15px 16px; border: 1px solid #e2e5ec; border-radius: 10px; background: #fff; color: #1f2937; text-align: left; }
.bank-line-icon { position: relative; display: grid; place-items: center; flex: 0 0 50px; width: 50px; height: 50px; border-radius: 7px; background: #edf5ff; border: 0; }
.bank-line-icon.diagonal::before { content: ""; width: 24px; height: 24px; border: 2px solid #1f63ff; background: repeating-linear-gradient(45deg, transparent 0 3px, #1f63ff 3px 5px); }
.bank-line-icon.list::before { content: ""; width: 24px; height: 20px; border-top: 2px solid #1f63ff; border-bottom: 2px solid #1f63ff; background: linear-gradient(#1f63ff, #1f63ff) center/100% 2px no-repeat; }
.bank-card-main { min-width: 0; }
#practiceChoices .wx-bank-card h2 { display: flex; align-items: center; gap: 8px; margin: 0 0 7px; font-size: 18px; line-height: 1.2; color: #1d2433; }
#practiceChoices .wx-bank-card h2 em { padding: 2px 6px; border-radius: 10px; background: #dff7eb; color: #009a55; font-size: 12px; font-style: normal; font-weight: 800; white-space: nowrap; }
#practiceChoices .wx-bank-card p { margin: 0; color: #8d96a5; font-size: 13px; line-height: 1.25; }
.mine-head { min-height: 150px; padding-top: 45px; }
.profile-row { display: flex; align-items: center; gap: 16px; }
.profile-avatar { display: grid; place-items: center; width: 66px; height: 66px; border-radius: 50%; background: rgba(255, 255, 255, 0.2); font-size: 35px; color: #fff; }
.profile-row h1 { margin: 0; font-size: 25px; line-height: 1.2; font-weight: 800; }
.profile-row p { margin: 5px 0 0; font-size: 14px; font-weight: 700; }
.mine-head .wx-capsule { position: absolute; top: 27px; right: 14px; }
.mine-info-card { margin: -15px 17px 18px; padding: 14px 16px 12px; border-radius: 10px; background: #fff; box-shadow: 0 8px 18px rgba(26, 32, 44, 0.08); }
.mine-info-card div { display: flex; justify-content: space-between; align-items: center; min-height: 37px; color: #2d3748; font-size: 15px; }
.mine-info-card strong { font-size: 15px; font-weight: 700; }
.font-size-pill { padding: 7px 12px; border-radius: 18px; background: #f2f7ff; color: #1f63ff; font-size: 13px !important; }
.mine-menu { padding: 0 17px; }
.mine-menu button { display: flex; align-items: center; width: 100%; height: 56px; border: 0; background: transparent; color: #1f2937; text-align: left; }
.mine-menu strong { font-size: 16px; font-weight: 700; }
.mine-menu b { margin-left: auto; color: #c7ced8; font-size: 19px; font-weight: 400; }
.menu-icon { width: 22px; height: 22px; margin-right: 16px; color: #1f63ff; }
.menu-icon::before { color: #1f63ff; font-size: 23px; font-weight: 800; }
.menu-icon.pie::before { content: "◔"; }
.menu-icon.headset::before { content: "◖"; }
.menu-icon.history::before { content: "↺"; }
.menu-icon.gear::before { content: "⚙"; }
.logout-panel-btn { width: calc(100% - 34px); height: 47px; margin: 18px 17px 0; border: 1px solid #ffb5b5; border-radius: 9px; background: #fff; color: #ff4d3f; font-size: 16px; font-weight: 700; }
.wx-tabbar { position: fixed; left: 50%; bottom: 0; z-index: 20; display: grid; grid-template-columns: 1fr 1fr; width: min(100vw, 414px); height: 50px; transform: translateX(-50%); border-top: 1px solid #e5e7eb; background: #fff; }
.wx-tabbar button { display: grid; place-items: center; align-content: center; gap: 3px; border: 0; background: transparent; color: #a5acb8; font-size: 12px; font-weight: 700; }
.wx-tabbar button.active { color: #1f63ff; }
.tab-home, .tab-mine { position: relative; width: 18px; height: 18px; }
.tab-home::before { content: ""; position: absolute; left: 1px; top: 6px; width: 16px; height: 11px; background: currentColor; clip-path: polygon(0 45%, 50% 0, 100% 45%, 88% 45%, 88% 100%, 12% 100%, 12% 45%); }
.tab-mine::before { content: ""; position: absolute; left: 5px; top: 1px; width: 8px; height: 8px; border-radius: 50%; background: currentColor; box-shadow: 0 10px 0 4px currentColor; }
.quiz-top-card, .result-panel { margin: 14px; padding: 16px; border-radius: 10px; background: #fff; }

#quizView {
  display: flex;
  flex-direction: column;
  height: calc(100vh - 51px);
  min-height: 0;
  overflow: hidden;
  padding: 10px 12px 10px;
}

#quizView.hidden {
  display: none;
}

#quizView .quiz-top-card {
  flex: 0 0 auto;
  margin: 0 0 8px;
  padding: 10px 12px;
}

#quizView .quiz-top-card h2 {
  margin: 0 0 4px;
  font-size: 17px;
  line-height: 1.2;
}

#quizView .quiz-top-card p {
  margin: 0;
  font-size: 13px;
  line-height: 1.3;
}

#quizForm {
  flex: 1 1 auto;
  min-height: 0;
  margin: 0 0 8px;
}

#quizView #backHomeBtn {
  margin-top: 8px;
}

/* Student screenshot match polish */
.student-app { background: #f1f2f6; }
.wx-phone { background: #f3f4f8; }
.wx-main { min-height: calc(100vh - 51px); padding-bottom: 64px; }
.wx-blue-head { min-height: 68px; padding: 30px 18px 9px; background: #2462f6; }
.home-head { align-items: center; gap: 12px; }
.wx-title { min-height: 29px; }
.wx-title strong { font-size: 18px; letter-spacing: 0; }
.wx-title span { font-size: 12px; transform: translateY(1px); }
.wx-mine-shortcut { min-width: 44px; height: 28px; margin-left: auto; border-radius: 15px; background: rgba(23, 61, 189, 0.44); font-size: 14px; }
.wx-capsule { height: 28px; gap: 8px; padding: 0 9px; border-radius: 15px; background: rgba(28, 66, 187, 0.58); }
.wx-capsule span { font-size: 16px; line-height: 1; transform: translateY(-2px); }
.wx-capsule b { font-size: 15px; line-height: 1; }
.wx-capsule em { width: 14px; height: 14px; border-width: 2px; }
.home-action-grid { gap: 18px; margin: 16px 18px 24px; }
.study-tile { min-height: 128px; border-radius: 10px; }
.study-tile strong { font-size: 20px; line-height: 1; }
.study-tile.blue { background: #235cf7; }
.study-tile.orange { background: #ff7908; }
.play-icon { border-top-width: 14px; border-bottom-width: 14px; border-left-width: 25px; margin: 0 0 2px 8px; }
.refresh-icon { display: block; width: 34px; height: 34px; font-size: 0; }
.refresh-icon::before { content: ""; display: block; width: 25px; height: 25px; margin: 4px auto 0; border: 4px solid #fff; border-left-color: transparent; border-radius: 50%; transform: rotate(-35deg); }
.refresh-icon::after { content: ""; position: relative; display: block; width: 0; height: 0; left: 20px; top: -29px; border-left: 7px solid #fff; border-top: 5px solid transparent; border-bottom: 5px solid transparent; transform: rotate(34deg); }
.bank-title-row { padding: 0 18px; margin-bottom: 12px; }
.bank-title-row h2 { font-size: 20px; line-height: 1; }
.bank-title-row span { font-size: 14px; color: #9ea8b7; }
.bank-empty-card { min-height: 86px; margin: 0 18px 14px; padding: 16px 15px; border-color: #dfe3eb; border-radius: 9px; }
.empty-icon { position: relative; width: 48px; height: 48px; border-radius: 10px; background: #fff5ef; font-size: 0; }
.empty-icon::before { content: ""; width: 18px; height: 23px; border: 2px solid #ff6e1f; border-radius: 2px; background: linear-gradient(#ff6e1f, #ff6e1f) 5px 7px/8px 2px no-repeat, linear-gradient(#ff6e1f, #ff6e1f) 5px 12px/8px 2px no-repeat, linear-gradient(#ff6e1f, #ff6e1f) 5px 17px/8px 2px no-repeat; }
.empty-icon::after { content: ""; position: absolute; right: 12px; top: 12px; width: 7px; height: 7px; border: 2px solid #ff6e1f; border-radius: 2px; background: #fff5ef; }
.bank-empty-card h3 { margin-bottom: 6px; font-size: 18px; line-height: 1.15; }
.bank-empty-card p { font-size: 13px; line-height: 1.25; color: #8994a4; }
.activate-banner { min-height: 84px; padding: 14px 15px; border-radius: 10px; background: #235cf7; }
.activate-banner .plus-box { width: 50px; height: 50px; flex-basis: 50px; font-size: 28px; line-height: 1; }
.activate-banner strong { font-size: 16px; line-height: 1.2; }
.activate-banner em { font-size: 13px; line-height: 1.2; }
.activate-banner b { font-size: 25px; line-height: 1; }
#practiceChoices { margin: 0 18px 15px; }
#practiceChoices .wx-bank-card { min-height: 86px; margin-bottom: 13px; padding: 15px 16px; border-color: #dfe3eb; border-radius: 9px; gap: 16px; }
#practiceChoices .wx-bank-card.selected { border-color: #2f78dd; background: #f1f7ff; box-shadow: 0 8px 18px rgba(47, 120, 221, 0.12); }
#practiceChoices .wx-bank-card.disabled { opacity: 0.55; }
.bank-line-icon { flex-basis: 50px; width: 50px; height: 50px; border-radius: 8px; background: #eef6ff; }
.bank-line-icon.diagonal::before { width: 25px; height: 25px; border-width: 2px; background: repeating-linear-gradient(45deg, transparent 0 3px, #2165ff 3px 5px); }
.bank-line-icon.list::before { width: 24px; height: 20px; border-top-width: 2px; border-bottom-width: 2px; background-size: 100% 2px; }
#practiceChoices .wx-bank-card h2 { margin-bottom: 7px; font-size: 18px; line-height: 1.1; }
#practiceChoices .wx-bank-card h2 em { padding: 2px 6px; border-radius: 9px; font-size: 12px; }
#practiceChoices .wx-bank-card p { font-size: 13px; color: #8792a3; }
.mine-head { min-height: 150px; padding: 45px 18px 20px; }
.profile-row { gap: 17px; }
.profile-avatar { position: relative; width: 66px; height: 66px; background: rgba(255, 255, 255, 0.18); font-size: 0; }
.profile-avatar::before { content: ""; position: absolute; left: 25px; top: 20px; width: 16px; height: 16px; border-radius: 50%; background: #fff; }
.profile-avatar::after { content: ""; position: absolute; left: 19px; top: 38px; width: 28px; height: 15px; border-radius: 15px 15px 10px 10px; background: #fff; opacity: 0.96; }
.profile-row h1 { font-size: 25px; line-height: 1.15; }
.profile-row p { margin-top: 6px; font-size: 14px; }
.mine-info-card { margin: -15px 17px 19px; padding: 13px 16px 12px; border-radius: 9px; }
.mine-info-card div { min-height: 37px; font-size: 15px; }
.mine-info-card strong { font-size: 15px; }
.font-size-pill { padding: 7px 12px; border-radius: 17px; }
.mine-menu { padding: 2px 17px 0; }
.mine-menu button { height: 56px; }
.mine-menu strong { font-size: 16px; }
.menu-icon { position: relative; width: 27px; height: 27px; margin-right: 16px; font-size: 0; color: #2364ff; }
.menu-icon::before { content: ""; position: absolute; inset: 4px; font-size: 0; }
.menu-icon.pie::before { border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; }
.menu-icon.pie::after { content: ""; position: absolute; right: 5px; top: 4px; width: 8px; height: 8px; border-radius: 0 9px 0 0; border-top: 2px solid currentColor; border-right: 2px solid currentColor; }
.menu-icon.headset::before { left: 5px; right: 5px; top: 5px; bottom: 4px; border: 2px solid currentColor; border-bottom: 0; border-radius: 14px 14px 0 0; }
.menu-icon.headset::after { content: ""; position: absolute; left: 3px; right: 3px; top: 14px; height: 9px; background: linear-gradient(currentColor, currentColor) left/6px 9px no-repeat, linear-gradient(currentColor, currentColor) right/6px 9px no-repeat; border-radius: 3px; }
.menu-icon.history::before { width: 17px; height: 17px; border: 2px solid currentColor; border-left-color: transparent; border-radius: 50%; transform: rotate(-35deg); }
.menu-icon.history::after { content: ""; position: absolute; right: 4px; top: 4px; width: 0; height: 0; border-left: 6px solid currentColor; border-top: 4px solid transparent; border-bottom: 4px solid transparent; transform: rotate(30deg); }
.menu-icon.gear::before { inset: 5px; border: 3px solid currentColor; border-radius: 50%; box-shadow: 0 -5px 0 -2px currentColor, 0 5px 0 -2px currentColor, 5px 0 0 -2px currentColor, -5px 0 0 -2px currentColor; }
.logout-panel-btn { height: 47px; margin-top: 17px; border-radius: 8px; }
.wx-tabbar { height: 51px; border-top-color: #e0e3ea; }
.wx-tabbar button { gap: 3px; font-size: 12px; }

/* Student app redesign override */
.student-app {
  --sa-bg: #f3f6fb;
  --sa-surface: #ffffff;
  --sa-surface-soft: #f8fbff;
  --sa-border: #dbe4f0;
  --sa-text: #132033;
  --sa-muted: #738097;
  --sa-brand: #245bf5;
  --sa-brand-deep: #1844c0;
  --sa-accent: #ff7f1f;
  --sa-shadow: 0 12px 30px rgba(20, 32, 51, 0.08);
  --sa-shadow-soft: 0 8px 18px rgba(20, 32, 51, 0.05);
  background: var(--sa-bg);
  color: var(--sa-text);
}
.wx-phone { background: linear-gradient(180deg, #f7f9fd 0%, #f2f5fa 100%); }
.wx-main { min-height: calc(100vh - 52px); padding-bottom: 66px; }
.wx-blue-head {
  min-height: 72px;
  padding: 28px 18px 10px;
  background: linear-gradient(180deg, #225cf3 0%, #1d4fe0 100%);
  box-shadow: inset 0 -1px 0 rgba(255, 255, 255, 0.08);
}
.home-head { align-items: center; gap: 12px; }
.wx-title strong { font-size: 18px; letter-spacing: 0; }
.wx-title span { font-size: 12px; opacity: 0.88; }
.wx-mine-shortcut {
  min-width: 48px;
  height: 30px;
  padding: 0 12px;
  border-radius: 15px;
  background: rgba(8, 27, 93, 0.26);
  font-size: 13px;
  font-weight: 700;
}
.wx-capsule {
  height: 30px;
  padding: 0 10px;
  border-radius: 15px;
  background: rgba(8, 27, 93, 0.34);
}
.wx-capsule span { font-size: 15px; line-height: 1; }
.wx-capsule b { font-size: 15px; line-height: 1; }
.home-action-grid { gap: 14px; margin: 16px 18px 22px; }
.study-tile {
  min-height: 120px;
  border-radius: 14px;
  box-shadow: var(--sa-shadow);
}
.study-tile strong { font-size: 19px; letter-spacing: 0; }
.study-tile.blue { background: linear-gradient(180deg, #2f69ff 0%, #245cf5 100%); }
.study-tile.orange { background: linear-gradient(180deg, #ff8b25 0%, #ff7f1f 100%); }
.play-icon {
  position: relative;
  width: 34px;
  height: 34px;
  margin-left: 6px;
  border: 2px solid rgba(255, 255, 255, 0.94);
  border-radius: 50%;
}
.play-icon::before {
  content: "";
  position: absolute;
  left: 12px;
  top: 8px;
  width: 0;
  height: 0;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-left: 12px solid rgba(255, 255, 255, 0.98);
}
.refresh-icon {
  position: relative;
  width: 34px;
  height: 34px;
  font-size: 0;
}
.refresh-icon::before {
  content: "";
  position: absolute;
  inset: 4px;
  border: 3px solid #fff;
  border-left-color: transparent;
  border-radius: 50%;
  transform: rotate(-38deg);
}
.refresh-icon::after {
  content: "";
  position: absolute;
  right: 4px;
  top: 6px;
  width: 0;
  height: 0;
  border-left: 8px solid #fff;
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
  transform: rotate(30deg);
}
.bank-title-row { margin-bottom: 12px; }
.bank-title-row h2 { font-size: 19px; letter-spacing: 0; }
.bank-title-row span { font-size: 13px; color: var(--sa-muted); }
.bank-empty-card,
.mine-info-card,
.quiz-top-card,
.result-panel {
  border: 1px solid var(--sa-border);
  border-radius: 14px;
  background: var(--sa-surface);
  box-shadow: var(--sa-shadow-soft);
}
.bank-empty-card { min-height: 88px; }
.empty-icon {
  position: relative;
  width: 48px;
  height: 48px;
  font-size: 0;
  border-radius: 12px;
  background: #fff4ec;
  color: var(--sa-accent);
}
.empty-icon::before {
  content: "";
  width: 18px;
  height: 22px;
  border: 2px solid currentColor;
  border-radius: 2px;
  background: linear-gradient(currentColor, currentColor) 4px 5px/8px 2px no-repeat,
    linear-gradient(currentColor, currentColor) 4px 10px/8px 2px no-repeat,
    linear-gradient(currentColor, currentColor) 4px 15px/8px 2px no-repeat;
}
.empty-icon::after {
  content: "";
  position: absolute;
  right: 11px;
  top: 11px;
  width: 7px;
  height: 7px;
  border: 2px solid currentColor;
  border-radius: 2px;
  background: #fff4ec;
}
.bank-empty-card h3 { font-size: 17px; }
.bank-empty-card p { color: var(--sa-muted); font-size: 13px; line-height: 1.35; }
.activate-banner {
  border-radius: 14px;
  background: linear-gradient(180deg, #2b65ff 0%, #245cf5 100%);
  box-shadow: var(--sa-shadow);
}
.activate-banner .plus-box {
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.16);
}
#practiceChoices .wx-bank-card {
  border: 1px solid var(--sa-border);
  border-radius: 14px;
  box-shadow: var(--sa-shadow-soft);
}
#practiceChoices .wx-bank-card.selected {
  border-color: #2f69ff;
  background: #f3f7ff;
}
.bank-line-icon {
  border-radius: 12px;
  background: #eef4ff;
  color: var(--sa-brand);
}
.bank-line-icon.diagonal::before {
  border-color: currentColor;
  background: repeating-linear-gradient(45deg, transparent 0 3px, currentColor 3px 5px);
}
.bank-line-icon.list::before {
  border-top-color: currentColor;
  border-bottom-color: currentColor;
  background: linear-gradient(currentColor, currentColor) center/100% 2px no-repeat;
}
#practiceChoices .wx-bank-card h2 { font-size: 17px; }
#practiceChoices .wx-bank-card h2 em { border-radius: 999px; background: #e9f2ff; color: var(--sa-brand); }
#practiceChoices .wx-bank-card p { color: var(--sa-muted); }
.mine-head { min-height: 154px; }
.profile-avatar {
  position: relative;
  background: rgba(255, 255, 255, 0.18);
  font-size: 0;
}
.profile-avatar::before {
  content: "";
  position: absolute;
  left: 25px;
  top: 18px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
}
.profile-avatar::after {
  content: "";
  position: absolute;
  left: 18px;
  top: 38px;
  width: 30px;
  height: 15px;
  border-radius: 15px 15px 10px 10px;
  background: #fff;
}
.profile-row h1 { font-size: 24px; letter-spacing: 0; }
.profile-row p { font-size: 13px; }
.mine-info-card {
  margin: -14px 17px 18px;
  padding: 14px 16px 12px;
}
.mine-info-card div { min-height: 38px; font-size: 14px; }
.mine-info-card strong { font-size: 14px; }
.font-size-pill {
  border-radius: 999px;
  background: #eef4ff;
  color: var(--sa-brand);
}
.mine-menu button { height: 54px; }
.mine-menu strong { font-size: 15px; }
.menu-icon {
  width: 26px;
  height: 26px;
  margin-right: 14px;
  color: var(--sa-brand);
}
.menu-icon.pie::before { border-color: currentColor; border-right-color: transparent; }
.menu-icon.headset::before { border-color: currentColor; border-bottom: 0; }
.menu-icon.history::before { border-color: currentColor; border-left-color: transparent; }
.menu-icon.gear::before { border-color: currentColor; }
.logout-panel-btn {
  height: 46px;
  border-radius: 12px;
  border-color: #f1b7b7;
  color: #db4a4a;
}
.wx-tabbar {
  height: 52px;
  border-top-color: #dfe5ee;
}
.wx-tabbar button {
  gap: 3px;
  font-size: 12px;
  letter-spacing: 0;
}
.tab-home::before { background: currentColor; }
.tab-mine::before { background: currentColor; }
.quiz-top-card {
  margin: 12px;
  padding: 14px 14px 12px;
}
.quiz-top-card h2 { font-size: 16px; line-height: 1.25; }
.quiz-top-card p { color: var(--sa-muted); font-size: 13px; line-height: 1.45; }
#quizView {
  padding: 10px 12px;
  height: calc(100vh - 52px);
}
.question-card {
  border: 1px solid var(--sa-border);
  border-radius: 16px;
  box-shadow: var(--sa-shadow-soft);
}
.question-head {
  font-size: 14px;
  color: var(--sa-brand);
}
.question-content {
  font-size: 18px;
  line-height: 1.6;
  color: var(--sa-text);
}
.option {
  border: 1px solid #d8e1ee;
  border-radius: 14px;
  box-shadow: 0 3px 10px rgba(16, 24, 40, 0.03);
}
.option:hover { background: #f7faff; border-color: #a7c0ff; }
.option:has(input:checked) {
  border-color: var(--sa-brand);
  background: #eff4ff;
  box-shadow: 0 8px 16px rgba(36, 91, 245, 0.12);
}
.option input { accent-color: var(--sa-brand); }
.option span { font-size: 16px; line-height: 1.45; }
.result-score { color: var(--sa-brand); }
.review-item { border-color: var(--sa-border); border-radius: 14px; }
.review-item h3 { font-size: 17px; line-height: 1.4; }
.analysis-box { background: #f5f8ff; border-radius: 12px; }

/* Final student-front polish */
.student-app {
  --sa-bg: #f4f7fb;
  --sa-surface: #ffffff;
  --sa-surface-soft: #f7faff;
  --sa-border: #dbe4f0;
  --sa-text: #122033;
  --sa-muted: #748096;
  --sa-brand: #245cf5;
  --sa-brand-deep: #1947c0;
  --sa-accent: #f58a22;
  --sa-shadow: 0 14px 30px rgba(18, 32, 51, 0.08);
  --sa-shadow-soft: 0 8px 18px rgba(18, 32, 51, 0.05);
  background: linear-gradient(180deg, #f7f9fd 0%, #f3f6fb 100%);
  color: var(--sa-text);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.wx-phone {
  background: linear-gradient(180deg, #f7f9fd 0%, #f1f5fb 100%);
}

.wx-main {
  min-height: calc(100vh - 52px);
  padding-bottom: 66px;
}

.wx-page {
  min-height: calc(100vh - 66px);
}

.wx-blue-head {
  min-height: 72px;
  padding: 28px 18px 10px;
  background: linear-gradient(180deg, #245ef6 0%, #1d4fe0 100%);
  box-shadow: inset 0 -1px 0 rgba(255, 255, 255, 0.08);
}

.home-head {
  align-items: center;
  gap: 12px;
}

.wx-title {
  min-height: 30px;
}

.wx-title strong {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0;
}

.wx-title span {
  font-size: 12px;
  opacity: 0.86;
}

.wx-mine-shortcut {
  min-width: 48px;
  height: 30px;
  padding: 0 12px;
  border-radius: 15px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(8, 27, 93, 0.25);
  font-size: 13px;
  font-weight: 700;
}

.wx-capsule {
  height: 30px;
  padding: 0 10px;
  border-radius: 15px;
  background: rgba(8, 27, 93, 0.34);
}

.wx-capsule span {
  font-size: 15px;
  line-height: 1;
}

.wx-capsule b {
  font-size: 15px;
  line-height: 1;
}

.home-action-grid {
  gap: 14px;
  margin: 16px 18px 22px;
}

.study-tile {
  min-height: 120px;
  border-radius: 16px;
  box-shadow: var(--sa-shadow);
}

.study-tile strong {
  font-size: 19px;
  letter-spacing: 0;
}

.study-tile.blue {
  background: linear-gradient(180deg, #2f69ff 0%, #245cf5 100%);
}

.study-tile.orange {
  background: linear-gradient(180deg, #ff8b25 0%, #ff7f1f 100%);
}

.play-icon {
  position: relative;
  width: 34px;
  height: 34px;
  margin-left: 6px;
  border: 2px solid rgba(255, 255, 255, 0.94);
  border-radius: 50%;
}

.play-icon::before {
  content: "";
  position: absolute;
  left: 12px;
  top: 8px;
  width: 0;
  height: 0;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-left: 12px solid rgba(255, 255, 255, 0.98);
}

.refresh-icon {
  position: relative;
  width: 34px;
  height: 34px;
  font-size: 0;
}

.refresh-icon::before {
  content: "";
  position: absolute;
  inset: 4px;
  border: 3px solid #fff;
  border-left-color: transparent;
  border-radius: 50%;
  transform: rotate(-38deg);
}

.refresh-icon::after {
  content: "";
  position: absolute;
  right: 4px;
  top: 6px;
  width: 0;
  height: 0;
  border-left: 8px solid #fff;
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
  transform: rotate(30deg);
}

.bank-title-row {
  margin-bottom: 12px;
}

.bank-title-row h2 {
  font-size: 19px;
  letter-spacing: 0;
}

.bank-title-row span {
  font-size: 13px;
  color: var(--sa-muted);
}

.bank-empty-card,
.mine-info-card,
.quiz-top-card,
.result-panel {
  border: 1px solid var(--sa-border);
  border-radius: 16px;
  background: var(--sa-surface);
  box-shadow: var(--sa-shadow-soft);
}

.bank-empty-card {
  min-height: 88px;
}

.empty-icon {
  position: relative;
  width: 48px;
  height: 48px;
  font-size: 0;
  border-radius: 12px;
  background: #fff4ec;
  color: var(--sa-accent);
}

.empty-icon::before {
  content: "";
  width: 18px;
  height: 22px;
  border: 2px solid currentColor;
  border-radius: 2px;
  background: linear-gradient(currentColor, currentColor) 4px 5px/8px 2px no-repeat,
    linear-gradient(currentColor, currentColor) 4px 10px/8px 2px no-repeat,
    linear-gradient(currentColor, currentColor) 4px 15px/8px 2px no-repeat;
}

.empty-icon::after {
  content: "";
  position: absolute;
  right: 11px;
  top: 11px;
  width: 7px;
  height: 7px;
  border: 2px solid currentColor;
  border-radius: 2px;
  background: #fff4ec;
}

.bank-empty-card h3 {
  font-size: 17px;
}

.bank-empty-card p {
  color: var(--sa-muted);
  font-size: 13px;
  line-height: 1.35;
}

.activate-banner {
  border-radius: 16px;
  background: linear-gradient(180deg, #2b65ff 0%, #245cf5 100%);
  box-shadow: var(--sa-shadow);
}

.activate-banner .plus-box {
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.16);
}

#practiceChoices .wx-bank-card {
  border: 1px solid var(--sa-border);
  border-radius: 16px;
  box-shadow: var(--sa-shadow-soft);
}

#practiceChoices .wx-bank-card.selected {
  border-color: #2f69ff;
  background: #f3f7ff;
}

.bank-line-icon {
  border-radius: 12px;
  background: #eef4ff;
  color: var(--sa-brand);
}

.bank-line-icon.diagonal::before {
  border-color: currentColor;
  background: repeating-linear-gradient(45deg, transparent 0 3px, currentColor 3px 5px);
}

.bank-line-icon.list::before {
  border-top-color: currentColor;
  border-bottom-color: currentColor;
  background: linear-gradient(currentColor, currentColor) center/100% 2px no-repeat;
}

#practiceChoices .wx-bank-card h2 {
  font-size: 17px;
}

#practiceChoices .wx-bank-card h2 em {
  border-radius: 999px;
  background: #e9f2ff;
  color: var(--sa-brand);
}

#practiceChoices .wx-bank-card p {
  color: var(--sa-muted);
}

.mine-head {
  min-height: 154px;
}

.profile-avatar {
  position: relative;
  width: 66px;
  height: 66px;
  background: rgba(255, 255, 255, 0.18);
  font-size: 0;
}

.profile-avatar::before {
  content: "";
  position: absolute;
  left: 25px;
  top: 20px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
}

.profile-avatar::after {
  content: "";
  position: absolute;
  left: 19px;
  top: 38px;
  width: 28px;
  height: 15px;
  border-radius: 15px 15px 10px 10px;
  background: #fff;
  opacity: 0.96;
}

.profile-row h1 {
  font-size: 25px;
  line-height: 1.15;
}

.profile-row p {
  margin-top: 6px;
  font-size: 14px;
}

.mine-info-card {
  margin: -15px 17px 19px;
  padding: 13px 16px 12px;
}

.mine-info-card div {
  min-height: 37px;
  font-size: 15px;
}

.mine-info-card strong {
  font-size: 15px;
}

.font-size-pill {
  padding: 7px 12px;
  border-radius: 17px;
}

.mine-menu {
  padding: 2px 17px 0;
}

.mine-menu button {
  height: 56px;
}

.mine-menu strong {
  font-size: 16px;
}

.menu-icon {
  position: relative;
  width: 27px;
  height: 27px;
  margin-right: 16px;
  font-size: 0;
  color: #2364ff;
}

.menu-icon::before {
  content: "";
  position: absolute;
  inset: 4px;
  font-size: 0;
}

.menu-icon.pie::before {
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
}

.menu-icon.pie::after {
  content: "";
  position: absolute;
  right: 5px;
  top: 4px;
  width: 8px;
  height: 8px;
  border-radius: 0 9px 0 0;
  border-top: 2px solid currentColor;
  border-right: 2px solid currentColor;
}

.menu-icon.headset::before {
  left: 5px;
  right: 5px;
  top: 5px;
  bottom: 4px;
  border: 2px solid currentColor;
  border-bottom: 0;
  border-radius: 14px 14px 0 0;
}

.menu-icon.headset::after {
  content: "";
  position: absolute;
  left: 3px;
  right: 3px;
  top: 14px;
  height: 9px;
  background: linear-gradient(currentColor, currentColor) left/6px 9px no-repeat, linear-gradient(currentColor, currentColor) right/6px 9px no-repeat;
  border-radius: 3px;
}

.menu-icon.history::before {
  width: 17px;
  height: 17px;
  border: 2px solid currentColor;
  border-left-color: transparent;
  border-radius: 50%;
  transform: rotate(-35deg);
}

.menu-icon.history::after {
  content: "";
  position: absolute;
  right: 4px;
  top: 4px;
  width: 0;
  height: 0;
  border-left: 6px solid currentColor;
  border-top: 4px solid transparent;
  border-bottom: 4px solid transparent;
  transform: rotate(30deg);
}

.menu-icon.gear::before {
  inset: 5px;
  border: 3px solid currentColor;
  border-radius: 50%;
  box-shadow: 0 -5px 0 -2px currentColor, 0 5px 0 -2px currentColor, 5px 0 0 -2px currentColor, -5px 0 0 -2px currentColor;
}

.logout-panel-btn {
  height: 47px;
  margin-top: 17px;
  border-radius: 10px;
}

.wx-tabbar {
  height: 52px;
  border-top-color: #e0e3ea;
}

.wx-tabbar button {
  gap: 3px;
  font-size: 12px;
}

.quiz-top-card {
  margin: 12px;
  padding: 14px 14px 12px;
}

.quiz-top-card h2 {
  font-size: 16px;
  line-height: 1.25;
}

.quiz-top-card p {
  color: var(--sa-muted);
  font-size: 13px;
  line-height: 1.45;
}

#quizView {
  padding: 10px 12px;
  height: calc(100vh - 52px);
}

#quizView .quiz-top-card {
  margin: 0 0 8px;
}

#quizForm {
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.question-card {
  border: 1px solid var(--sa-border);
  border-radius: 16px;
  box-shadow: var(--sa-shadow-soft);
}

.question-head {
  font-size: 14px;
  color: var(--sa-brand);
}

.question-content {
  font-size: 18px;
  line-height: 1.6;
  color: var(--sa-text);
}

.option {
  border: 1px solid #d8e1ee;
  border-radius: 14px;
  box-shadow: 0 3px 10px rgba(16, 24, 40, 0.03);
}

.option:hover {
  background: #f7faff;
  border-color: #a7c0ff;
}

.option:has(input:checked) {
  border-color: var(--sa-brand);
  background: #eff4ff;
  box-shadow: 0 8px 16px rgba(36, 91, 245, 0.12);
}

.option input {
  accent-color: var(--sa-brand);
}

.option span {
  font-size: 16px;
  line-height: 1.45;
}

.quiz-nav {
  margin-top: 12px;
  gap: 10px;
}

.quiz-nav .btn {
  min-height: 48px;
  font-size: 16px;
}

.result-score {
  color: var(--sa-brand);
}

.review-item {
  border-color: var(--sa-border);
  border-radius: 14px;
}

.review-item h3 {
  font-size: 17px;
  line-height: 1.4;
}

.analysis-box {
  background: #f5f8ff;
  border-radius: 12px;
}

.student-record-card {
  width: min(460px, 100%);
  max-height: min(78vh, 760px);
  overflow: hidden;
}

.record-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.record-modal-head h2 {
  margin: 0;
  font-size: 20px;
}

.history-close {
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: #eef3f8;
  color: #5f6a7a;
  font-size: 22px;
  line-height: 1;
}

.student-record-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.student-record-summary div {
  padding: 12px 10px;
  border-radius: 12px;
  background: #f6f9ff;
  text-align: center;
}

.student-record-summary strong {
  display: block;
  color: #245cf5;
  font-size: 22px;
  line-height: 1.1;
}

.student-record-summary span {
  color: #768197;
  font-size: 12px;
}

.record-tip {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  color: #5e6878;
  font-size: 13px;
}

.student-record-list {
  max-height: 48vh;
  overflow-y: auto;
  padding-right: 4px;
}

.practice-report-list {
  display: grid;
  gap: 10px;
  margin-bottom: 12px;
  max-height: 22vh;
  overflow-y: auto;
  padding-right: 4px;
}

.practice-report-item {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 14px;
  border: 1px solid #dbe4f0;
  border-radius: 14px;
  background: #f8fbff;
}

.practice-report-item h3 {
  margin: 0 0 4px;
  font-size: 15px;
}

.practice-report-item p {
  margin: 0;
  color: #7b8797;
  font-size: 12px;
  line-height: 1.4;
}

.practice-report-meta {
  display: grid;
  align-content: center;
  justify-items: end;
  min-width: 92px;
  color: #245cf5;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.5;
}

.student-record-item {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 14px;
  margin-bottom: 10px;
  border: 1px solid #dbe4f0;
  border-radius: 14px;
  background: #fff;
}

.student-record-item h3 {
  margin: 0 0 6px;
  font-size: 16px;
}

.student-record-item p {
  margin: 0;
  color: #7b8797;
  font-size: 13px;
}

.record-score {
  display: grid;
  place-items: center;
  min-width: 76px;
  padding: 8px 10px;
  border-radius: 12px;
  text-align: center;
}

.record-score strong {
  font-size: 24px;
  line-height: 1;
}

.record-score span {
  margin-top: 4px;
  font-size: 12px;
}

.record-score.pass {
  color: #1f8f61;
  background: #ecfaf3;
}

.record-score.fail {
  color: #b42318;
  background: #fff1f1;
}

.record-empty {
  padding: 24px 16px;
  color: #738097;
  text-align: center;
}

.record-empty.error {
  color: #b42318;
}

.settings-row {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  min-height: 54px;
  border: 0;
  border-bottom: 1px solid #edf1f6;
  background: #fff;
  color: #1f2937;
  text-align: left;
  font-size: 16px;
}

.settings-row span {
  color: #a8b1bf;
  font-size: 22px;
}

.settings-row.danger strong {
  color: #b42318;
}
