:root {
  --app-bg: #f5f7fa;
  --app-sider: #ffffff;
  --app-surface: #ffffff;
  --app-surface-soft: #fbfcfe;
  --app-border: #e5e8ef;
  --app-text-subtle: #6b778a;
  --app-shadow: rgba(28, 39, 54, 0.04);
}

body {
  margin: 0;
  background: var(--app-bg);
}

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

.main-layout {
  min-width: 0;
}

.app-sider {
  position: sticky;
  top: 0;
  align-self: flex-start;
  height: 100vh;
  background: var(--app-sider);
  border-right: 1px solid var(--app-border);
  box-shadow: 0 8px 30px var(--app-shadow);
  overflow: hidden;
}

.app-sider.is-collapsed {
  width: 72px !important;
  min-width: 72px !important;
  max-width: 72px !important;
  flex: 0 0 72px !important;
}

.app-sider .arco-layout-sider-children {
  display: flex;
  flex-direction: column;
  height: 100vh;
  min-height: 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 64px;
  padding: 0 20px;
}

.brand-mark {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: #e8f7ff;
  color: #165dff;
  font-weight: 800;
}

.brand-name {
  color: #1d2129;
  font-size: 16px;
  font-weight: 700;
}

.sider-menu-wrap {
  flex: 1;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
}

.sider-collapse {
  flex: 0 0 auto;
  padding: 12px 16px 16px;
  background: var(--app-sider);
  border-top: 1px solid var(--app-border);
}

.app-sider.is-collapsed .brand {
  justify-content: center;
  padding: 0;
}

.app-sider.is-collapsed .brand-mark {
  width: 36px;
  height: 36px;
}

.app-sider.is-collapsed .sider-collapse {
  display: flex;
  justify-content: center;
  padding: 12px 0 16px;
}

.app-sider.is-collapsed .sider-collapse .arco-btn {
  width: 40px;
  padding-right: 0;
  padding-left: 0;
}

.app-sider.is-collapsed .arco-menu,
.app-sider.is-collapsed .arco-menu-inner {
  width: 100% !important;
}

.app-sider.is-collapsed .arco-menu-inner {
  display: grid;
  justify-items: center;
}

.app-sider.is-collapsed .arco-menu-item {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px !important;
  margin-right: auto !important;
  margin-left: auto !important;
  padding-right: 0 !important;
  padding-left: 0 !important;
}

.app-sider.is-collapsed .menu-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  font-weight: 700;
}

.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  padding: 0 28px;
  background: var(--app-surface);
  border-bottom: 1px solid var(--app-border);
}

.app-header > div:first-child {
  min-width: 0;
}

.page-title {
  overflow: hidden;
  margin: 0 !important;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.header-actions {
  justify-content: flex-end;
}

.user-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid var(--app-border);
  border-radius: 8px;
  background: var(--app-surface-soft);
}

.role-permission-trigger {
  cursor: pointer;
  user-select: none;
}

.role-permission-trigger:focus-visible {
  outline: 2px solid rgba(22, 93, 255, 0.35);
  outline-offset: 2px;
}

.permission-modal .arco-table-th,
.permission-modal .arco-table-td {
  text-align: center;
}

.permission-modal .arco-table-td:nth-child(2) {
  text-align: left;
}

.permission-mark {
  min-width: 26px;
  justify-content: center;
}

.permission-denied {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 26px;
  color: #86909c;
  font-size: 18px;
  font-weight: 700;
}

.login-conflict-content {
  display: grid;
  gap: 14px;
}

.login-conflict-summary {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--app-border);
  border-radius: 8px;
  background: var(--app-surface-soft);
}

.login-conflict-summary > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.app-content {
  min-width: 0;
  padding: 24px 28px;
  overflow-x: auto;
}

.page-intro {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 16px;
}

.page-intro-text {
  max-width: 720px;
  margin: 0 !important;
  color: var(--app-text-subtle);
}

.toolbar {
  width: 100%;
  margin-bottom: 16px;
}

.subtext {
  margin-top: 4px;
  color: var(--app-text-subtle);
  font-size: 13px;
}

.question-id-cell {
  display: inline-block;
  min-width: 56px;
  white-space: nowrap;
}

.question-description-cell {
  display: block;
  width: 100%;
  max-width: 320px;
  margin: 0 auto;
  overflow: hidden;
  color: #1d2129;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.question-picker-checkbox {
  display: inline-flex;
}

.question-picker-row {
  cursor: pointer;
}

.question-picker-row:hover .arco-table-td {
  background: #f7fbff;
}

.question-picker-row.is-disabled {
  cursor: not-allowed;
}

.danger-modal-content {
  display: grid;
  gap: 16px;
}

.danger-summary {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid #f7c5c5;
  border-radius: 8px;
  background: #fff7f7;
}

.danger-summary > div {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.outline-tag {
  border: 1px solid var(--app-border);
  background: var(--app-surface-soft);
}

.tag-editor {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  min-height: 34px;
}

.tag-input {
  width: 180px;
  min-width: 160px;
}

.group-create-row {
  width: 100%;
}

.group-list {
  display: grid;
  gap: 8px;
}

.group-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  min-height: 44px;
  padding: 8px 12px;
  border: 1px solid var(--app-border);
  border-radius: 8px;
  background: var(--app-surface-soft);
}

.paper-select-trigger {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px dashed #c9d5ec;
  border-radius: 8px;
  background: var(--app-surface-soft);
  color: #1d2129;
  cursor: pointer;
  text-align: left;
}

.paper-select-trigger > span {
  display: grid;
  gap: 4px;
}

.paper-select-trigger:hover {
  border-color: #165dff;
  background: #f7fbff;
}

.difficulty-stars {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 1px;
  min-height: 32px;
}

.difficulty-star {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #c9cdd4;
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
}

.difficulty-star.active {
  color: #f7ba1e;
}

.difficulty-stars.readonly .difficulty-star {
  width: 16px;
  height: 20px;
  cursor: default;
  font-size: 16px;
}

.question-editor-page {
  display: grid;
  gap: 16px;
}

.option-list {
  display: grid;
  gap: 10px;
  width: 100%;
}

.option-row {
  display: grid;
  grid-template-columns: 34px minmax(180px, 1fr) 88px 68px;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--app-border);
  border-radius: 8px;
  background: var(--app-surface-soft);
}

.option-label {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 1px solid var(--app-border);
  border-radius: 50%;
  background: var(--app-surface);
  color: #165dff;
  font-weight: 700;
}

.option-input {
  min-width: 0;
}

.add-option-button {
  width: 132px;
}

.home-page {
  width: 100%;
}

.welcome-card {
  box-sizing: border-box;
  min-height: 274px;
  padding: 12px;
}

.welcome-text {
  max-width: 760px;
  color: var(--app-text-subtle);
  line-height: 1.8;
}

.stack {
  display: grid;
  gap: 12px;
}

.compact-card {
  cursor: pointer;
  transition: all 0.18s ease;
}

.compact-card:hover,
.active-card {
  border-color: #165dff;
  box-shadow: 0 8px 24px rgba(22, 93, 255, 0.08);
}

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

.paper-item {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) 56px;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--app-border);
  border-radius: 8px;
  background: var(--app-surface-soft);
}

.paper-item-main {
  min-width: 0;
}

.paper-item-desc {
  margin-top: 6px;
  overflow: hidden;
  color: #1d2129;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.empty-paper {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 180px;
  border: 1px dashed var(--app-border);
  border-radius: 8px;
  color: var(--app-text-subtle);
  background: var(--app-surface-soft);
}

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

.paper-builder .arco-card {
  height: 100%;
}

.paper-sheet {
  display: grid;
  gap: 22px;
  max-width: 1080px;
  min-height: 720px;
  margin: 0 auto;
  padding: 34px 42px 46px;
  border: 1px solid var(--app-border);
  border-radius: 8px;
  background: var(--app-surface);
  box-shadow: 0 10px 30px var(--app-shadow);
}

.paper-sheet-head {
  display: grid;
  gap: 14px;
  justify-items: center;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--app-border);
  text-align: center;
}

.paper-name-input {
  max-width: 560px;
  text-align: center;
  font-size: 24px;
  font-weight: 700;
}

.paper-section {
  display: grid;
  gap: 14px;
}

.paper-section-toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.paper-section-title-input {
  font-size: 18px;
  font-weight: 700;
}

.paper-section-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 120px;
  padding: 0;
  border: 1px dashed var(--app-border);
  border-radius: 8px;
  color: var(--app-text-subtle);
  appearance: none;
  background: var(--app-surface-soft);
  cursor: pointer;
  font: inherit;
  line-height: 1.5;
  text-align: center;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.paper-section-empty:hover {
  border-color: var(--app-primary);
  color: var(--app-primary);
  background: #f2f8ff;
}

.paper-question-list {
  display: grid;
  gap: 16px;
}

.paper-question-preview {
  display: grid;
  gap: 10px;
  padding: 14px 0;
  border-bottom: 1px solid var(--app-border);
}

.paper-question-preview:last-child {
  border-bottom: 0;
}

.paper-question-meta {
  display: flex;
  align-items: center;
  gap: 8px;
}

.paper-question-meta .arco-btn {
  margin-left: auto;
}

.paper-question-desc {
  margin: 0 !important;
  color: #1d2129;
  line-height: 1.8;
}

.paper-option-list {
  display: grid;
  gap: 8px;
  padding-left: 28px;
}

.paper-option {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  color: #1d2129;
  line-height: 1.7;
}

.paper-option-prefix {
  font-weight: 700;
}

.paper-answer-area {
  min-height: 88px;
  border-bottom: 1px solid var(--app-border);
}

.paper-code-link {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid var(--app-border);
  border-radius: 8px;
  color: #165dff;
  background: var(--app-surface-soft);
  word-break: break-all;
}

.paper-code-link-anchor {
  min-width: 0;
  overflow-wrap: anywhere;
  color: inherit;
}

.subjective-answer-control {
  display: grid;
  gap: 10px;
}

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

.attachment-upload-button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid #165dff;
  border-radius: 4px;
  background: #ffffff;
  color: #165dff;
  cursor: pointer;
  font-size: 14px;
  line-height: 32px;
}

.attachment-upload-button:hover {
  background: #f2f7ff;
}

.attachment-upload-button.is-disabled {
  border-color: var(--app-border);
  color: var(--app-text-subtle);
  cursor: not-allowed;
  opacity: 0.72;
}

.attachment-upload-button input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: inherit;
}

.answer-attachment-list {
  display: grid;
  gap: 8px;
}

.answer-attachment-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  min-height: 48px;
  padding: 8px 10px;
  border: 1px solid var(--app-border);
  border-radius: 6px;
  background: var(--app-surface-soft);
}

.answer-attachment-main {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-width: 0;
}

.answer-attachment-thumb,
.answer-attachment-file {
  width: 36px;
  height: 36px;
  border: 1px solid var(--app-border);
  border-radius: 4px;
  background: #ffffff;
}

.answer-attachment-thumb {
  object-fit: cover;
}

.answer-attachment-file {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--app-text-subtle);
  font-size: 12px;
}

.answer-attachment-text {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.answer-attachment-name {
  overflow: hidden;
  color: #165dff;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.preview-layout {
  display: grid !important;
  grid-template-columns: minmax(168px, 220px) minmax(0, 1fr);
  gap: 16px;
  align-items: flex-start;
}

.preview-layout > .arco-col {
  flex: initial !important;
  max-width: none !important;
  width: auto !important;
}

.preview-sidebar {
  position: sticky;
  top: 88px;
}

.preview-question-nav {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(32px, 1fr));
  gap: 8px;
  width: 100%;
}

.preview-nav-sections {
  display: grid;
  gap: 14px;
  width: 100%;
}

.preview-nav-section {
  display: grid;
  gap: 8px;
}

.preview-nav-section-title {
  overflow: hidden;
  color: var(--app-text-subtle);
  font-size: 12px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.preview-question-nav .preview-nav-button {
  width: 100%;
  min-width: 0;
  padding: 0;
  border-color: var(--app-border) !important;
  background-color: #f2f3f5 !important;
  color: var(--app-text-subtle) !important;
}

.preview-question-nav .preview-nav-button.is-answered {
  border-color: #7bc98d !important;
  background-color: #e8f7ed !important;
  color: #168a3a !important;
}

.preview-nav-sections .preview-question-nav button.preview-nav-button.is-answered {
  border-color: #7bc98d !important;
  background-color: #e8f7ed !important;
  color: #168a3a !important;
}

.preview-question-nav .preview-nav-button.is-correct {
  border-color: #7bc98d !important;
  background-color: #e8f7ed !important;
  color: #168a3a !important;
}

.preview-question-nav .preview-nav-button.is-wrong {
  border-color: #f7a7a3 !important;
  background-color: #fff0ee !important;
  color: #c9372c !important;
}

.preview-question-nav .preview-nav-button.is-graded {
  border-color: #8fb7ff !important;
  background-color: #edf4ff !important;
  color: #165dff !important;
}

.preview-sheet {
  margin: 0;
}

.preview-section {
  display: grid;
  gap: 14px;
}

.preview-section-title {
  margin: 0 !important;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--app-border);
}

.preview-question {
  scroll-margin-top: 96px;
}

.preview-answer-options {
  display: grid !important;
  gap: 10px;
  align-items: start;
  justify-items: start;
}

.preview-answer-options .arco-radio,
.preview-answer-options .arco-checkbox {
  justify-self: start;
  width: fit-content;
  max-width: 100%;
}

.full-width {
  width: 100%;
}

.assessment-summary {
  margin-bottom: 16px;
}

.my-workbench-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.my-workbench-card {
  display: grid;
  gap: 6px;
  min-width: 0;
  padding: 14px 16px;
  border: 1px solid var(--app-border);
  border-radius: 8px;
  background: var(--app-surface);
}

.my-workbench-card.is-live {
  border-color: rgba(255, 125, 0, 0.32);
  background: #fffaf2;
}

.my-workbench-card strong {
  overflow: hidden;
  color: #1d2129;
  font-size: 24px;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.my-workbench-label {
  color: var(--app-text-subtle);
  font-size: 13px;
}

.ability-trend {
  display: grid;
  gap: 16px;
}

.ability-trend-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.ability-trend-metric {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 14px 16px;
  border: 1px solid var(--app-border);
  border-radius: 8px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.ability-trend-metric.is-up {
  border-color: rgba(0, 180, 42, 0.24);
}

.ability-trend-metric.is-down {
  border-color: rgba(247, 114, 52, 0.28);
  background: linear-gradient(180deg, #ffffff 0%, #fff8f3 100%);
}

.ability-trend-metric span {
  color: var(--app-text-subtle);
  font-size: 13px;
}

.ability-trend-metric strong {
  overflow: hidden;
  color: #1d2129;
  font-size: 24px;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ability-trend-metric em {
  overflow: hidden;
  color: var(--app-text-subtle);
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

.data-chart-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}

.ability-chart-card {
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--app-border);
  border-radius: 8px;
  background: var(--app-surface);
}

.ability-chart-card.is-wide {
  grid-column: 1 / -1;
}

.ability-chart-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.ability-chart {
  width: 100%;
  min-width: 0;
}

.ability-chart-empty {
  display: flex;
  align-items: center;
  justify-content: center;
}

.assessment-status-alert {
  margin-bottom: 16px;
}

.assessment-action-bar {
  position: sticky;
  top: 0;
  z-index: 20;
  margin: -8px -4px 16px;
  padding: 12px 4px;
  background: rgba(245, 247, 250, 0.94);
  border-bottom: 1px solid rgba(229, 232, 239, 0.88);
  backdrop-filter: blur(8px);
}

.assessment-countdown {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  min-width: 178px;
  color: #165dff;
}

.assessment-countdown.is-danger {
  color: #f53f3f;
}

.assessment-countdown-label {
  color: var(--app-text-subtle);
  font-size: 13px;
  font-weight: 600;
}

.assessment-countdown-value {
  font-size: 24px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: 0;
  font-variant-numeric: tabular-nums;
}

.draft-save-status {
  color: var(--app-text-subtle);
  font-size: 13px;
  white-space: nowrap;
}

.draft-save-status.is-error {
  color: #f53f3f;
}

.data-metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.data-metric {
  display: grid;
  gap: 8px;
  min-height: 104px;
  padding: 16px;
  border: 1px solid var(--app-border);
  border-radius: 8px;
  background: var(--app-surface);
  box-shadow: 0 8px 24px var(--app-shadow);
}

.data-metric-label,
.data-metric-sub {
  color: var(--app-text-subtle);
  font-size: 13px;
}

.data-metric-value {
  overflow: hidden;
  color: #1d2129;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.data-description-cell {
  display: block;
  max-width: 240px;
  margin: 0 auto;
  overflow: hidden;
  color: #1d2129;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.data-rate-cell {
  display: grid;
  grid-template-columns: minmax(64px, 1fr) 46px;
  gap: 8px;
  align-items: center;
  min-width: 112px;
}

.data-rate-track {
  overflow: hidden;
  height: 8px;
  border-radius: 999px;
  background: #edf1f7;
}

.data-rate-track span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #165dff;
}

.data-rate-value {
  justify-self: end;
  color: #1d2129;
  font-variant-numeric: tabular-nums;
}

.data-detail-section {
  display: grid;
  gap: 10px;
}

.question-detail-chart-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.question-detail-chart-grid.is-single {
  grid-template-columns: minmax(320px, 560px);
  justify-content: center;
}

.log-actor-cell,
.log-target-cell {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.log-detail-cell {
  display: block;
  max-width: 420px;
  margin: 0 auto;
  overflow: hidden;
  color: #4e5969;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recycle-note {
  margin-bottom: 16px;
}

.recycle-summary-cell {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.recycle-summary-title {
  display: block;
  max-width: 520px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.result-summary-card {
  margin-bottom: 16px;
}

.result-comment {
  margin: 12px 0 0 !important;
  color: var(--app-text-subtle);
}

.result-answer-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 12px 0;
}

.result-answer-box {
  min-height: 42px;
  margin-top: 6px;
  padding: 10px 12px;
  border: 1px solid var(--app-border);
  border-radius: 8px;
  background: var(--app-surface-soft);
  color: #1d2129;
  line-height: 1.7;
  white-space: pre-wrap;
  word-break: break-word;
}

.grading-workbench {
  align-items: flex-start;
}

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

.grading-user-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--app-border);
  border-radius: 8px;
  background: var(--app-surface);
  text-align: left;
  cursor: pointer;
}

.grading-user-item > div {
  min-width: 0;
}

.grading-user-item .subtext {
  overflow-wrap: anywhere;
  line-height: 1.45;
}

.grading-user-item .arco-tag {
  flex: 0 0 auto;
}

.grading-user-item:hover {
  border-color: #8fb7ff;
  background: #f7fbff;
}

.grading-user-item.is-active {
  border-color: #165dff;
  background: #edf4ff;
}

.grading-user-item:disabled {
  cursor: not-allowed;
  opacity: 0.62;
}

.grading-score-static,
.grading-score-editor {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  min-height: 34px;
}

.grading-score-static {
  color: #1d2129;
}

.grading-code-link-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
}

.grading-code-link-row .paper-question-desc {
  overflow-wrap: anywhere;
}

.grading-manual-fields,
.result-manual-fields {
  display: grid;
  gap: 8px;
  margin: 12px 0;
}

.grading-field-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.grading-answer-textarea textarea,
.grading-answer-textarea .arco-textarea {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  line-height: 1.7;
}

.grading-summary {
  position: sticky;
  top: 88px;
}

.grading-summary-panel,
.grading-summary-input {
  display: flex;
  justify-content: center;
  width: 100%;
  max-width: 320px;
  margin: 0 auto;
}

.grading-summary-panel .arco-alert {
  width: 100%;
}

.grading-summary-input .arco-textarea,
.grading-summary-input .arco-textarea-wrapper {
  width: 100%;
}

.grading-summary-bottom {
  display: grid;
  gap: 12px;
  padding-top: 10px;
}

.grading-summary-bottom-panel {
  display: grid;
  gap: 12px;
}

.grading-summary-bottom-panel .arco-alert {
  width: 100%;
}

.grading-summary-bottom-panel .arco-btn {
  justify-self: end;
  min-width: 112px;
}

.result-total-comment {
  display: grid;
  gap: 10px;
  padding-top: 6px;
}

@media (max-width: 900px) {
  .preview-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .preview-sidebar {
    position: static;
  }

  .data-metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .my-workbench-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ability-trend-summary,
  .ability-chart-grid,
  .data-chart-grid,
  .question-detail-chart-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 620px) {
  .data-metric-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .my-workbench-summary {
    grid-template-columns: minmax(0, 1fr);
  }

  .ability-trend-summary {
    grid-template-columns: minmax(0, 1fr);
  }
}

.requirements {
  margin: 0;
  padding-left: 18px;
  color: var(--app-text-subtle);
  line-height: 1.8;
}

.code-block {
  margin: 0;
  padding: 18px;
  overflow: auto;
  min-height: 360px;
  border-radius: 8px;
  background: #101828;
  color: #d4e8ff;
  font-size: 13px;
  line-height: 1.7;
}

.upload-box {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 96px;
  margin-bottom: 16px;
  border: 1px dashed var(--app-border);
  border-radius: 8px;
  color: var(--app-text-subtle);
  background: var(--app-surface-soft);
}

.arco-table .arco-table-tr:hover .arco-table-td {
  background: rgba(60, 126, 255, 0.08);
}

@media (max-width: 980px) {
  .page-intro {
    align-items: flex-start;
    flex-direction: column;
  }

  .app-content {
    padding: 18px;
  }

  .option-row {
    grid-template-columns: 34px minmax(0, 1fr);
  }

  .add-option-button {
    width: 100%;
  }
}
