﻿:root {
  color-scheme: light;
  --console-ink: #0f172a;
  --console-muted: #64748b;
  --console-blue: #4f46e5;
  --console-line: #e2e8f0;
  --console-bg: #f6f8fb;
  --console-sidebar: #101828;
  --console-sidebar-soft: #1c2a40;
  --console-card: #ffffff;
  font-family: "Microsoft YaHei", "PingFang SC", "Segoe UI", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  background: var(--console-bg);
  color: var(--console-ink);
}

.console-login-body {
  min-height: 100vh;
  background:
    radial-gradient(circle at 18% 14%, rgb(110 167 255 / 0.7), transparent 34%),
    radial-gradient(circle at 74% 22%, rgb(156 92 255 / 0.74), transparent 34%),
    linear-gradient(135deg, #6279ee 0%, #7660c7 46%, #7f4aae 100%);
}

.console-login-shell {
  display: grid;
  width: min(420px, calc(100% - 32px));
  min-height: 100vh;
  margin: 0 auto;
  align-content: center;
  gap: 28px;
  padding: 24px 0 54px;
}

.console-login-brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 13px;
  min-height: 78px;
  padding: 12px 18px;
  border: 1px solid rgb(255 255 255 / 0.28);
  border-radius: 20px;
  background: rgb(255 255 255 / 0.13);
  box-shadow: 0 20px 48px rgb(38 25 94 / 0.16);
  backdrop-filter: blur(14px);
}

.console-login-brand strong {
  color: #ffffff;
  font-size: 24px;
  font-weight: 950;
}

.console-login-card {
  display: grid;
  gap: 18px;
  min-height: 520px;
  padding: 70px 28px 34px;
  border: 1px solid rgb(255 255 255 / 0.34);
  border-radius: 28px;
  background: rgb(255 255 255 / 0.94);
  box-shadow: 0 24px 64px rgb(38 25 94 / 0.2);
}

.console-login-heading span {
  color: var(--console-ink);
  font-size: 30px;
  font-weight: 950;
}

.console-login-card label {
  display: grid;
  gap: 8px;
}

.console-login-card label span {
  color: var(--console-ink);
  font-size: 13px;
  font-weight: 850;
}

.console-login-card input {
  width: 100%;
  min-height: 46px;
  padding: 0 14px;
  border: 1px solid #d9deec;
  border-radius: 14px;
  background: #ffffff;
  color: var(--console-ink);
  font-size: 15px;
}

.console-login-card input:focus {
  border-color: #6d5df6;
  box-shadow: 0 0 0 4px rgb(109 93 246 / 0.13);
  outline: none;
}

.console-login-remember {
  display: flex !important;
  align-items: center;
  gap: 9px;
  color: #53617d;
  font-size: 13px;
  font-weight: 800;
}

.console-login-remember input {
  width: 16px;
  height: 16px;
  min-height: auto;
  padding: 0;
  accent-color: #6d5df6;
}

.console-login-remember span {
  color: #53617d !important;
}

.console-login-card button {
  min-height: 46px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, #7f73ff, #7545b8);
  color: #ffffff;
  cursor: pointer;
  font-weight: 950;
}

.console-login-error {
  padding: 11px 13px;
  border: 1px solid #fecaca;
  border-radius: 14px;
  background: #fff1f2;
  color: #be123c;
  font-size: 13px;
  font-weight: 750;
}

a,
button {
  font: inherit;
}

.console-shell {
  min-height: 100vh;
  background: var(--console-bg);
}

.console-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 86px;
  padding: 0 38px;
  border-bottom: 1px solid var(--console-line);
  background: #ffffff;
}

.console-brand {
  display: inline-flex;
  align-items: center;
  gap: 18px;
  color: var(--console-ink);
  text-decoration: none;
}

.brand-icon {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 6px;
  background: #4f46e5;
  color: #ffffff;
  font-size: 20px;
  font-weight: 950;
}

.console-brand strong {
  font-size: 25px;
  font-weight: 950;
  letter-spacing: 0;
}

.console-brand em {
  padding: 7px 12px;
  border-radius: 999px;
  background: #eef2ff;
  color: #4338ca;
  font-size: 13px;
  font-style: normal;
  font-weight: 900;
}

.console-actions {
  display: flex;
  align-items: center;
  gap: 24px;
}

.refresh-link {
  color: #64748b;
  font-size: 28px;
  text-decoration: none;
}

.role-pill {
  min-height: 38px;
  padding: 9px 18px;
  border: 1px solid #dbe5f3;
  border-radius: 10px;
  background: #f8fafc;
  color: #0f2344;
  font-size: 14px;
  font-weight: 900;
}

.logout-button {
  min-height: 38px;
  padding: 0 18px;
  border: 1px solid #ff0054;
  border-radius: 10px;
  background: #ffffff;
  color: #ff0054;
  cursor: pointer;
  font-weight: 850;
}

.console-layout {
  display: grid;
  grid-template-columns: 318px minmax(0, 1fr);
  min-height: calc(100vh - 86px);
}

.console-sidebar {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  padding: 28px 23px;
  background: var(--console-sidebar);
  color: #ffffff;
}

.sidebar-caption {
  margin: 0 15px 18px;
  color: #7790c6;
  font-size: 14px;
  font-weight: 800;
}

.sidebar-nav {
  display: grid;
  gap: 14px;
}

.sidebar-item {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  min-height: 45px;
  padding: 0 18px;
  border-radius: 9px;
  color: #b7c7ec;
  text-decoration: none;
}

.sidebar-item span {
  color: #8592ff;
  font-size: 19px;
  font-weight: 900;
}

.sidebar-item strong {
  font-size: 15px;
  font-weight: 850;
}

.sidebar-item.active,
.sidebar-item:hover {
  background: var(--console-sidebar-soft);
  color: #ffffff;
}

.assistant-card {
  margin-top: auto;
  padding: 22px 20px;
  border: 1px solid #2b3d59;
  border-radius: 13px;
  background: #17253a;
}

.assistant-card strong {
  display: block;
  color: #7d88ff;
  font-size: 16px;
  font-weight: 950;
}

.assistant-card p {
  margin: 12px 0 0;
  color: #b8c7e6;
  font-size: 14px;
  line-height: 1.72;
}

.console-main {
  min-width: 0;
  padding: 40px min(70px, 5vw);
}

.page-heading {
  margin-bottom: 30px;
}

.page-heading h1 {
  margin: 0;
  color: var(--console-ink);
  font-size: 28px;
  font-weight: 950;
  letter-spacing: 0;
}

.page-heading p {
  margin: 7px 0 0;
  color: #50668a;
  font-size: 15px;
}

.action-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
}

.action-strip a {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 16px;
  border-radius: 10px;
  background: #4f46e5;
  color: #ffffff;
  text-decoration: none;
  font-size: 14px;
  font-weight: 900;
}

.action-button {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 16px;
  border: 0;
  border-radius: 10px;
  background: #4f46e5;
  color: #ffffff;
  cursor: pointer;
  font-size: 14px;
  font-weight: 900;
}

.inline-filter select {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid #dbe5f3;
  border-radius: 10px;
  background: #ffffff;
  color: var(--console-ink);
  font-size: 14px;
  font-weight: 850;
}

.action-strip .action-danger,
.row-actions .danger-link {
  background: #ffe4e6;
  color: #be123c;
}

.student-search-card {
  margin-bottom: 20px;
  padding: 18px 20px;
  border: 1px solid #e5eaf2;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 12px 32px rgb(15 23 42 / 0.04);
}

.student-search-form {
  display: flex;
  align-items: end;
  gap: 12px;
}

.student-search-form label {
  display: grid;
  flex: 1;
  gap: 8px;
}

.student-search-form span {
  color: var(--console-ink);
  font-size: 13px;
  font-weight: 950;
}

.student-search-form input {
  width: 100%;
  min-height: 42px;
  padding: 0 14px;
  border: 1px solid #dbe5f3;
  border-radius: 12px;
  color: var(--console-ink);
  font: inherit;
}

.student-search-form button,
.student-search-form a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 18px;
  border: 0;
  border-radius: 10px;
  background: #4f46e5;
  color: #ffffff;
  cursor: pointer;
  text-decoration: none;
  font-weight: 900;
}

.student-search-form a {
  background: #e0e7ff;
  color: #3730a3;
}

.row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.row-actions form {
  margin: 0;
}

.row-actions a,
.row-actions button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 0 10px;
  border: 0;
  border-radius: 8px;
  background: #eef2ff;
  color: #3730a3;
  cursor: pointer;
  text-decoration: none;
  font-size: 12px;
  font-weight: 900;
}

.row-actions .warning-action {
  background: #fef3c7;
  color: #b45309;
}

.row-actions .danger-action {
  background: #ffe4e6;
  color: #be123c;
}

.section-heading-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 28px 12px;
}

.secondary-card .section-heading-row h2 {
  margin: 0;
  padding: 0;
  line-height: 38px;
}

.section-heading-row form {
  margin: 0;
}

.section-heading-row .danger-action {
  min-height: 38px;
  padding: 0 18px;
  border: 0;
  border-radius: 12px;
  background: #ffe4e6;
  color: #be123c;
  cursor: pointer;
  font-weight: 900;
  font-size: 15px;
}

.bulk-delete-button {
  min-height: 30px;
  padding: 0 10px;
  border: 0;
  border-radius: 8px;
  background: #ffe4e6;
  color: #be123c;
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
}

.inline-grade-form {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin: 0;
}

.inline-grade-form input {
  min-height: 30px;
  border: 1px solid #dbe3f0;
  border-radius: 8px;
  padding: 0 8px;
}

.inline-grade-form input[name="score"] {
  width: 72px;
}

.inline-grade-form input[name="comment"] {
  width: 150px;
}

.inline-grade-form button,
.point-actions button {
  min-height: 30px;
  border: 0;
  border-radius: 8px;
  background: #eef2ff;
  color: #3730a3;
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
}

.point-actions {
  gap: 6px;
}

.answer-preview {
  min-height: 120px;
  padding: 14px;
  border: 1px solid #dbe3f0;
  border-radius: 12px;
  background: #f8fafc;
  color: #0f172a;
  line-height: 1.8;
  white-space: normal;
}

.submission-detail-card h2 {
  padding: 24px 30px 10px;
  font-size: 28px;
  line-height: 1.25;
  font-weight: 950;
}

.submission-detail-card .console-table th,
.submission-detail-card .console-table td {
  padding: 20px 30px;
  font-size: 18px;
  line-height: 1.6;
}

.submission-detail-card .console-table th {
  width: 168px;
  color: #50668a;
  font-size: 16px;
  font-weight: 950;
}

.submission-detail-card .detail-link {
  font-size: 18px;
}

.submission-detail-card .answer-preview {
  min-height: 170px;
  padding: 20px;
  font-size: 20px;
  line-height: 1.7;
}

.papers-console-card .section-heading-row h2 {
  font-size: 28px;
  line-height: 1.25;
  font-weight: 950;
}

.papers-console-table th,
.papers-console-table td {
  padding: 20px 28px;
}

.papers-console-table th {
  color: #50668a;
  font-size: 16px;
  font-weight: 950;
}

.papers-console-table td,
.papers-console-table td strong,
.papers-console-table .detail-link {
  font-size: 18px;
  line-height: 1.55;
}

.papers-console-table td strong {
  font-weight: 950;
}
.papers-console-table .paper-title-link {
  color: #0f172a;
  text-decoration: none;
}

.papers-console-table .paper-title-link:hover {
  color: #4f46e5;
  text-decoration: underline;
}

.papers-console-table .submission-student-name {
  color: #1e2a44;
  font-size: 21px;
  font-weight: 950;
}


.papers-console-table .type-badge {
  min-height: 32px;
  padding: 0 12px;
  border-radius: 10px;
  font-size: 17px;
  font-weight: 900;
}

.papers-console-table input[type="checkbox"] {
  width: 18px;
  height: 18px;
}

.papers-console-table .row-actions {
  gap: 8px;
}

.papers-console-table .row-actions a,
.papers-console-table .row-actions button,
.papers-console-table .inline-grade-form button,
.papers-console-table .point-actions button,
.papers-console-table .bulk-delete-button {
  min-height: 38px;
  padding: 0 14px;
  border-radius: 10px;
  font-size: 17px;
  line-height: 1;
}

.papers-console-table .inline-grade-form {
  gap: 8px;
}

.papers-console-table .inline-grade-form input {
  min-height: 38px;
  padding: 0 10px;
  border-radius: 10px;
  font-size: 18px;
}

.papers-console-table .inline-grade-form input[name="score"] {
  width: 88px;
}

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

.stat-grid article {
  padding: 18px;
  border: 1px solid #e5eaf2;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 12px 32px rgb(15 23 42 / 0.04);
}

.stat-grid span,
.stat-grid strong {
  display: block;
}

.stat-grid span {
  color: #64748b;
  font-size: 13px;
  font-weight: 850;
}

.stat-grid strong {
  margin-top: 7px;
  color: #0f172a;
  font-size: 24px;
  font-weight: 950;
}

.data-card {
  overflow: hidden;
  border: 1px solid #e5eaf2;
  border-radius: 24px;
  background: var(--console-card);
  box-shadow:
    0 1px 2px rgb(15 23 42 / 0.08),
    0 18px 44px rgb(15 23 42 / 0.04);
}

.secondary-card {
  margin-top: 22px;
}

.secondary-card h2 {
  margin: 0;
  padding: 22px 28px 0;
  color: var(--console-ink);
  font-size: 22px;
}

.resource-folder-grid {
  display: grid;
  gap: 16px;
}

.resource-folder {
  overflow: hidden;
  border: 1px solid #e5eaf2;
  border-radius: 22px;
  background: #ffffff;
  box-shadow:
    0 1px 2px rgb(15 23 42 / 0.08),
    0 18px 44px rgb(15 23 42 / 0.04);
}

.resource-folder header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 24px;
  border-bottom: 1px solid #eef2f7;
  background: #f8fafc;
}

.resource-folder header div {
  display: flex;
  align-items: center;
  gap: 12px;
}

.folder-icon {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 10px;
  background: #eef2ff;
  color: #4f46e5;
  font-size: 17px;
  font-weight: 950;
}

.resource-folder header strong {
  color: var(--console-ink);
  font-size: 17px;
  font-weight: 950;
}

.resource-folder header em {
  color: #64748b;
  font-size: 13px;
  font-style: normal;
  font-weight: 850;
}

.folder-resource-list {
  display: grid;
}

.folder-resource-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 16px 24px;
  border-bottom: 1px solid #eef2f7;
}

.folder-resource-row:last-child {
  border-bottom: 0;
}

.resource-title-block {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.resource-title-block strong {
  color: #0f172a;
  font-size: 15px;
  font-weight: 950;
}

.resource-title-block span {
  color: #64748b;
  font-size: 13px;
  font-weight: 750;
}

.folder-empty {
  margin: 0;
  padding: 18px 24px;
  color: #7b8ba8;
  font-size: 14px;
  font-weight: 800;
}

.console-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}

.console-table th,
.console-table td {
  padding: 18px 30px;
  border-bottom: 1px solid #eef2f7;
  text-align: left;
  vertical-align: middle;
}

.console-table th {
  background: #f8fafc;
  color: #536b95;
  font-size: 13px;
  font-weight: 950;
}

.console-table td {
  color: #40567a;
  font-size: 14px;
}

.console-table tr:last-child td {
  border-bottom: 0;
}

.console-table td strong {
  color: #0f172a;
  font-weight: 950;
}

.score-badge,
.type-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 25px;
  padding: 0 9px;
  border-radius: 7px;
  font-size: 13px;
  font-weight: 950;
}

.score-badge.income,
.type-badge.green {
  background: #dcfce7;
  color: #059669;
}

.score-badge.expense {
  background: #ffe4e6;
  color: #e11d48;
}

.type-badge.orange {
  background: #fef3c7;
  color: #d97706;
}

.type-badge.blue {
  background: #e0f2fe;
  color: #0369a1;
}

/* 启灵点行内调节按钮 */
.qiling-stepper {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.qiling-stepper .stepper-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 1px solid #d1d5db;
  border-radius: 50%;
  background: #fff;
  color: #40567a;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  line-height: 1;
  padding: 0;
  transition: all 0.15s;
}
.qiling-stepper .stepper-btn:hover {
  background: #4f46e5;
  color: #fff;
  border-color: #4f46e5;
}
.qiling-stepper .stepper-btn:active {
  transform: scale(0.93);
}
.qiling-stepper .stepper-value {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  min-height: 26px;
  padding: 0 6px;
  border: 1px solid #e2e8f0;
  border-radius: 13px;
  background: #fff;
  color: #0f172a;
  font-size: 13px;
  font-weight: 950;
}
.qiling-stepper .stepper-saving {
  opacity: 0.5;
  pointer-events: none;
}

/* 编辑表单启灵点 +/- 按钮组 */
.form-stepper {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.form-stepper .stepper-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: 1px solid #d1d5db;
  border-radius: 50%;
  background: #fff;
  color: #40567a;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  line-height: 1;
  padding: 0;
  flex-shrink: 0;
  transition: all 0.15s;
}
.form-stepper .stepper-btn:hover {
  background: #4f46e5;
  color: #fff;
  border-color: #4f46e5;
}
.form-stepper .stepper-btn:active {
  transform: scale(0.93);
}
.form-stepper input {
  width: 80px;
  text-align: center;
  /* 隐藏原生 number 滚动条 */
  -moz-appearance: textfield;
}
.form-stepper input::-webkit-outer-spin-button,
.form-stepper input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.empty-row {
  height: 150px;
  text-align: center !important;
  color: #7b8ba8 !important;
}

.console-messages {
  display: grid;
  gap: 10px;
  margin-bottom: 18px;
}

.console-message {
  padding: 13px 16px;
  border-radius: 12px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 14px;
  font-weight: 850;
}

.console-message.error {
  background: #fff1f2;
  color: #be123c;
}

.console-message.success {
  background: #ecfdf5;
  color: #047857;
}

.form-card {
  padding: 30px;
}

.console-form {
  display: grid;
  gap: 26px;
}

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

.console-form label {
  display: grid;
  gap: 8px;
}

.console-form .checkbox-line {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
}

.console-form .checkbox-line input {
  width: 16px;
  min-height: 16px;
  accent-color: #4f46e5;
}

.console-form label span {
  color: var(--console-ink);
  font-size: 14px;
  font-weight: 950;
}

.form-span-2 {
  grid-column: 1 / -1;
}

.agent-config-form {
  gap: 22px;
}

.agent-list {
  display: grid;
  gap: 18px;
}

.skill-config-section {
  display: grid;
  gap: 16px;
  margin-top: 4px;
  padding-top: 22px;
  border-top: 1px solid #e5eaf2;
}

.section-subheader {
  display: grid;
  gap: 6px;
}

.section-subheader strong {
  color: var(--console-ink);
  font-size: 20px;
  font-weight: 950;
}

.section-subheader span {
  color: #64748b;
  font-size: 14px;
  font-weight: 750;
}

.skill-list {
  display: grid;
  gap: 18px;
}

.agent-config-card,
.skill-config-card {
  display: grid;
  gap: 18px;
  padding: 20px;
  border: 1px solid #e5eaf2;
  border-radius: 16px;
  background: #f8fafc;
}

.skill-config-card {
  background: #ffffff;
}

.agent-config-card header,
.skill-config-card header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.agent-config-card header strong,
.skill-config-card header strong {
  color: var(--console-ink);
  font-size: 18px;
  font-weight: 950;
}

.secondary-button.remove-agent-button,
.secondary-button.remove-skill-button {
  min-height: 34px;
  padding: 0 12px;
  border: 0;
  border-radius: 10px;
  background: #fee2e2;
  color: #be123c;
  cursor: pointer;
  font-size: 13px;
  font-weight: 900;
}

.secondary-button.remove-agent-button:disabled,
.secondary-button.remove-skill-button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.console-form input,
.console-form select,
.console-form textarea {
  width: 100%;
  min-height: 44px;
  padding: 0 13px;
  border: 1px solid #dbe5f3;
  border-radius: 12px;
  background: #ffffff;
  color: var(--console-ink);
  font: inherit;
}

.console-form input:focus,
.console-form select:focus,
.console-form textarea:focus {
  border-color: #4f46e5;
  box-shadow: 0 0 0 4px rgb(79 70 229 / 0.12);
  outline: none;
}

.console-form textarea {
  min-height: 118px;
  padding-top: 12px;
  resize: vertical;
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.form-actions button,
.form-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 18px;
  border: 0;
  border-radius: 10px;
  background: #4f46e5;
  color: #ffffff;
  cursor: pointer;
  text-decoration: none;
  font-weight: 900;
}

.form-actions a {
  background: #e0e7ff;
  color: #3730a3;
}

.form-actions .secondary-button {
  background: #e0e7ff;
  color: #3730a3;
}

.danger-button {
  background: #be123c !important;
}

.delete-confirm-box {
  padding: 22px;
  border: 1px solid #fecdd3;
  border-radius: 16px;
  background: #fff1f2;
  color: #9f1239;
}

.delete-confirm-box strong {
  display: block;
  margin-bottom: 8px;
  font-size: 20px;
  font-weight: 950;
}

.delete-confirm-box p {
  margin: 6px 0 0;
}

.qwen-chat-box {
  display: grid;
  gap: 16px;
}

.qwen-chat-header {
  display: grid;
  gap: 6px;
}

.qwen-chat-header strong {
  color: var(--console-ink);
  font-size: 20px;
  font-weight: 950;
}

.qwen-chat-header span {
  color: #64748b;
  font-size: 14px;
  font-weight: 750;
}

.qwen-chat-input {
  display: grid;
  gap: 8px;
}

.qwen-chat-result {
  display: grid;
  gap: 12px;
  min-height: 180px;
  max-height: 360px;
  overflow-y: auto;
  padding: 16px;
  border: 1px solid #e5eaf2;
  border-radius: 16px;
  background: #f8fafc;
}

.qwen-chat-message {
  display: grid;
  gap: 8px;
  max-width: 880px;
  padding: 14px 16px;
  border-radius: 14px;
  background: #ffffff;
  color: #334155;
}

.qwen-chat-message.user {
  justify-self: end;
  background: #eef2ff;
}

.qwen-chat-message.assistant {
  justify-self: start;
  background: #ecfdf5;
}

.qwen-chat-message.error {
  justify-self: start;
  background: #fff1f2;
  color: #be123c;
}

.qwen-chat-message strong {
  color: #0f172a;
  font-size: 13px;
  font-weight: 950;
}

.qwen-chat-message p {
  margin: 0;
  white-space: pre-wrap;
  line-height: 1.7;
  font-size: 14px;
}

#qwen-chat-submit:disabled {
  cursor: not-allowed;
  opacity: 0.68;
}

.tokens-cell {
  display: grid;
  gap: 5px;
  color: #334155;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.45;
}

.tokens-cell span {
  display: inline-block;
  padding: 5px 8px;
  border-radius: 10px;
  background: #eef6ff;
}

.tokens-empty {
  color: #94a3b8;
  font-size: 12px;
  font-weight: 800;
}

.toggle-field {
  align-content: start;
}

.toggle-field input[type="checkbox"] {
  width: 22px;
  min-height: 22px;
  accent-color: #4f46e5;
}

.console-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgb(15 23 42 / 0.42);
}

.console-modal-backdrop[hidden] {
  display: none;
}

.console-modal-card {
  width: min(720px, 100%);
  padding: 26px;
  border: 1px solid #e5eaf2;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 26px 80px rgb(15 23 42 / 0.26);
}

.console-modal-card header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.console-modal-card header strong {
  color: var(--console-ink);
  font-size: 22px;
  font-weight: 950;
}

.console-modal-card header button {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: #eef2ff;
  color: #3730a3;
  cursor: pointer;
  font-size: 20px;
  font-weight: 950;
}

.payment-preview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.payment-preview-grid article {
  display: grid;
  gap: 10px;
  min-height: 180px;
  place-items: center;
  padding: 18px;
  border: 1px dashed #cbd5e1;
  border-radius: 16px;
  background: #f8fafc;
}

.payment-preview-grid span {
  color: #334155;
  font-size: 13px;
  font-weight: 900;
}

.payment-preview-grid img {
  width: 140px;
  height: 140px;
  border-radius: 12px;
  object-fit: cover;
}

.payment-preview-grid em {
  color: #64748b;
  font-style: normal;
  font-weight: 850;
}

code {
  display: inline-block;
  max-width: 420px;
  overflow: hidden;
  color: #334155;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 920px) {
  .console-header,
  .console-actions {
    align-items: flex-start;
    flex-direction: column;
  }

  .console-header {
    gap: 16px;
    padding: 18px;
  }

  .console-layout {
    grid-template-columns: 1fr;
  }

  .console-sidebar {
    min-height: auto;
  }

  .assistant-card {
    margin-top: 24px;
  }

  .console-main {
    padding: 28px 18px;
  }

  .data-card {
    overflow-x: auto;
  }

  .console-table {
    min-width: 760px;
  }

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

  .stat-grid,
  .payment-preview-grid {
    grid-template-columns: 1fr;
  }
}




.resource-grade-folder-grid {
  gap: 18px;
}

.resource-grade-folder {
  overflow: hidden;
}

.resource-grade-folder > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 72px;
  padding: 18px 24px;
  border-bottom: 1px solid #eef2f7;
  background: #f8fafc;
  cursor: pointer;
  list-style: none;
}

.resource-grade-folder > summary::-webkit-details-marker {
  display: none;
}

.resource-grade-folder > summary div {
  display: flex;
  align-items: center;
  gap: 12px;
}

.resource-grade-folder > summary strong {
  color: var(--console-ink);
  font-size: 19px;
  font-weight: 950;
}

.resource-grade-folder > summary em {
  color: #64748b;
  font-size: 14px;
  font-style: normal;
  font-weight: 900;
}

.resource-grade-folder[open] > summary {
  background: #eef2ff;
}

.resource-semester-grid {
  display: grid;
  gap: 14px;
  padding: 18px;
  background: #fbfcff;
}

.resource-semester-folder {
  overflow: hidden;
  border: 1px solid #e5eaf2;
  border-radius: 16px;
  background: #ffffff;
}

.resource-semester-folder > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid #eef2f7;
  background: #ffffff;
}

.resource-semester-folder > summary strong {
  color: #1e2a44;
  font-size: 16px;
  font-weight: 950;
}

.resource-semester-folder > summary em {
  color: #64748b;
  font-size: 13px;
  font-style: normal;
  font-weight: 850;
}

.resource-title-link {
  color: #0f172a;
  text-decoration: none;
}

.resource-title-link:hover {
  color: #4f46e5;
  text-decoration: underline;
}

.resource-semester-folder > summary {
  cursor: pointer;
  list-style: none;
}

.resource-semester-folder > summary::-webkit-details-marker {
  display: none;
}

.resource-semester-folder[open] > summary {
  background: #f8fafc;
}
