:root {
  --blue: #409eff;
  --blue-line: #2f8fed;
  --border: #e7ebf0;
  --line: #eef1f5;
  --text: #1f2d3d;
  --muted: #606d7b;
  --bg: #f3f6fa;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 1440px;
  color: var(--text);
  background: var(--bg);
  font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  font-size: 14px;
}

button,
input {
  font: inherit;
}

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 200px;
  background: #fff;
  border-right: 1px solid var(--border);
}

.brand {
  display: flex;
  align-items: flex-start;
  height: 112px;
  padding: 14px 8px 10px 15px;
  border-bottom: 1px solid var(--border);
  overflow: hidden;
}

.brand-text {
  display: grid;
  flex: 1;
  min-width: 0;
  line-height: 1.18;
  font-size: 18px;
  color: #1e3a56;
  letter-spacing: 0;
  word-break: keep-all;
}

.logo-mark {
  position: relative;
  width: 34px;
  height: 34px;
  margin: 7px 8px 0 0;
  flex: 0 0 34px;
}

.logo-mark span {
  position: absolute;
  left: 14px;
  top: 1px;
  width: 6px;
  height: 17px;
  border-radius: 8px 8px 2px 2px;
  transform-origin: 3px 16px;
}

.logo-mark span:nth-child(1) { background: #41b95e; transform: rotate(0deg); }
.logo-mark span:nth-child(2) { background: #f6b739; transform: rotate(60deg); }
.logo-mark span:nth-child(3) { background: #2aa4e8; transform: rotate(120deg); }
.logo-mark span:nth-child(4) { background: #89c541; transform: rotate(180deg); }
.logo-mark span:nth-child(5) { background: #f07c28; transform: rotate(240deg); }
.logo-mark span:nth-child(6) { background: #1aa5a8; transform: rotate(300deg); }

.side-nav {
  padding-top: 0;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  height: 50px;
  padding: 0 17px;
  border: 0;
  background: transparent;
  color: #303b47;
  text-align: left;
  cursor: default;
}

.nav-item.active {
  background: #f8fbff;
}

.icon-search,
.icon-user {
  position: relative;
  display: inline-block;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
}

.icon-search::before {
  content: "";
  position: absolute;
  width: 10px;
  height: 10px;
  border: 1.8px solid #1f2d3d;
  border-radius: 50%;
  left: 0;
  top: 0;
}

.icon-search::after {
  content: "";
  position: absolute;
  width: 7px;
  height: 1.8px;
  background: #1f2d3d;
  transform: rotate(45deg);
  left: 9px;
  top: 11px;
}

.icon-user::before {
  content: "";
  position: absolute;
  width: 8px;
  height: 8px;
  border: 1.5px solid #1f2d3d;
  border-radius: 50%;
  left: 4px;
  top: 0;
}

.icon-user::after {
  content: "";
  position: absolute;
  width: 14px;
  height: 8px;
  border: 1.5px solid #1f2d3d;
  border-bottom: 0;
  border-radius: 12px 12px 0 0;
  left: 1px;
  top: 10px;
}

.main-shell {
  margin-left: 200px;
  min-height: 100vh;
  padding-bottom: 10px;
}

.topbar {
  height: 45px;
  background: #fff;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 6px 0 18px;
}

.crumbs {
  display: flex;
  gap: 9px;
  align-items: center;
  color: #303b47;
}

.user-tools {
  display: flex;
  align-items: center;
  gap: 18px;
}

.icon-button,
.drop-button {
  border: 0;
  background: transparent;
  color: #111;
  height: 30px;
  min-width: 30px;
}

.user-mask {
  width: 112px;
  height: 22px;
  background: linear-gradient(90deg, #eef1f4, #c8ccd0 50%, #eef1f4);
  filter: blur(2px);
}

.tabs {
  height: 35px;
  display: flex;
  align-items: stretch;
  background: #fff;
  border-bottom: 1px solid #dfe5ec;
  padding-left: 10px;
}

.tab {
  min-width: 86px;
  padding: 0 16px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: #1f2d3d;
}

.tab.active {
  color: var(--blue-line);
  border-bottom-color: var(--blue-line);
}

.disclaimer-banner {
  margin: 8px 8px 0;
  padding: 10px 16px;
  border: 1px solid #ffe8a1;
  background: #fff3cd;
  color: #856404;
  text-align: center;
  font-size: 14px;
  line-height: 1.5;
}

.disclaimer-banner a {
  color: #0b72d9;
  text-decoration: none;
}

.disclaimer-banner a:hover {
  text-decoration: underline;
}

.workflow {
  height: 62px;
  margin: 8px 8px 0;
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff;
  border: 1px solid #e8edf3;
  padding: 0 14px;
}

.back-button,
.back-list {
  height: 32px;
  border: 1px solid var(--blue);
  border-radius: 4px;
  background: var(--blue);
  color: #fff;
  padding: 0 16px;
}

.back-button {
  position: relative;
  z-index: 2;
}

.steps {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 34px;
  padding: 0;
  margin: 0 0 0 2px;
}

.steps li {
  position: relative;
  min-width: 108px;
  height: 62px;
  display: flex;
  align-items: center;
  color: #1f2d3d;
  white-space: nowrap;
}

.steps li::before,
.steps li::after {
  content: "";
  position: absolute;
  top: 50%;
  border-top: 1.5px solid currentColor;
  border-right: 1.5px solid currentColor;
  width: 10px;
  height: 10px;
  transform: translateY(-50%) rotate(45deg);
}

.steps li::before {
  left: -24px;
}

.steps li::after {
  left: -17px;
}

.steps .current {
  border-bottom: 2px solid var(--blue-line);
  color: #111;
}

.steps .disabled {
  color: #c7cbd1;
}

.batch-bar {
  height: 34px;
  margin: 0 8px;
  display: flex;
  align-items: center;
  gap: 0;
  background: #f1f4f8;
  color: #248ce8;
  border-left: 1px solid #e8edf3;
  border-right: 1px solid #e8edf3;
}

.back-list {
  height: 32px;
  border-radius: 3px;
  margin-right: 0;
}

.batch-bar .red {
  color: #e75252;
  margin-left: 6px;
}

.form-panel {
  margin: 0 8px 8px;
  background: #fff;
  border: 1px solid #e4e9f0;
  border-top: 0;
}

.table-wrap {
  overflow-x: auto;
  max-height: calc(100vh - 183px);
  overflow-y: auto;
}

.volunteer-table {
  min-width: 1690px;
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  background: #fff;
}

.volunteer-table th,
.volunteer-table td {
  border: 1px solid var(--line);
  text-align: center;
  vertical-align: middle;
}

.volunteer-table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  height: 82px;
  background: #f4f7fb;
  font-weight: 700;
  color: #1f2d3d;
  line-height: 1.65;
}

.volunteer-table tbody tr {
  height: 67px;
}

.drag-col { width: 34px; }
.num-col { width: 52px; }
.school-col { width: 178px; }
.group-col { width: 174px; }
.major-col { width: 174px; }
.choice-col { width: 108px; }
.action-col { width: 120px; }

.drag-handle {
  width: 25px;
  height: 34px;
  border: 0;
  background: transparent;
  color: #7f8995;
  cursor: grab;
  font-size: 17px;
  line-height: 1;
  letter-spacing: -4px;
  padding: 0 6px 0 0;
  writing-mode: vertical-rl;
}

.drag-handle:active {
  cursor: grabbing;
}

.volunteer-table tbody tr.dragging {
  opacity: 0.55;
}

.volunteer-table tbody tr.drag-over td {
  background: #eef7ff;
  border-top-color: #409eff;
  border-bottom-color: #409eff;
}

.num-cell {
  color: #4c5968;
}

.cell-input {
  width: calc(100% - 24px);
  height: 32px;
  border: 1px solid #d9dfe7;
  border-radius: 3px;
  background: #fff;
  padding: 3px 8px;
  outline: 0;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.cell-input:focus {
  border-color: #7bbaf8;
  box-shadow: 0 0 0 2px rgba(64, 158, 255, 0.12);
}

.choice-box {
  display: grid;
  gap: 7px;
  justify-content: start;
  padding-left: 10px;
  text-align: left;
  color: #4d5967;
  font-size: 13px;
}

.choice-box label {
  display: flex;
  align-items: center;
  gap: 6px;
}

.choice-box input {
  appearance: none;
  width: 12px;
  height: 12px;
  margin: 0;
  border: 1px solid #d8dde4;
  border-radius: 50%;
  background: #fff;
}

.choice-box input:checked {
  border-color: var(--blue);
  box-shadow: inset 0 0 0 3px #fff;
  background: var(--blue);
}

.row-actions {
  display: inline-flex;
  border: 1px solid #d9dde4;
  border-radius: 9px;
  overflow: hidden;
  height: 24px;
  background: #fff;
}

.row-actions button {
  min-width: 24px;
  height: 22px;
  border: 0;
  border-right: 1px solid #d9dde4;
  background: #fff;
  color: #5f6975;
  padding: 0;
}

.row-actions button:last-child {
  border-right: 0;
}

.row-actions button:disabled {
  color: #c4c9cf;
  background: #fafafa;
}

.submit-strip {
  position: sticky;
  bottom: 0;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border-top: 1px solid #e4e9ef;
  background: #fff;
  z-index: 3;
}

.submit-button {
  border: 0;
  background: transparent;
  color: #333;
  cursor: pointer;
}

.save-status {
  min-width: 640px;
  color: #f56c6c;
  font-size: 13px;
  text-align: left;
}

@media (max-width: 900px) {
  body {
    min-width: 900px;
  }

  .sidebar {
    width: 160px;
  }

  .main-shell {
    margin-left: 160px;
  }

  .brand-text {
    font-size: 16px;
  }
}
