/* ============ 学员课时管理 v2 样式 ============ */

.student-hours-page {
  padding: 16px;
  min-height: calc(100vh - 120px);
  background: #f5f6fa;
  font-family: var(--font-family, "PingFang SC", "Microsoft YaHei", sans-serif);
}

/* --- 工具栏 --- */
.sh-toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  background: #fff;
  border-radius: var(--radius-md, 10px);
  margin-bottom: 16px;
  box-shadow: var(--shadow-sm, 0 1px 3px rgba(0,0,0,0.06));
  flex-wrap: wrap;
}

.sh-toolbar-group {
  display: flex;
  align-items: center;
  gap: 6px;
}

.sh-toolbar-group > label {
  font-size: 12px;
  color: #888;
  white-space: nowrap;
  font-weight: 500;
}

.sh-select,
.sh-input {
  padding: 5px 10px;
  border: 1px solid #ddd;
  border-radius: var(--radius-sm, 6px);
  font-size: 13px;
  background: #fff;
  outline: none;
}

.sh-select:focus,
.sh-input:focus {
  border-color: var(--primary, #F18D24);
}

.sh-toolbar-spacer { flex: 1; }

/* --- 主内容 --- */
.sh-main {
  display: flex;
  gap: 16px;
  min-height: calc(100vh - 220px);
}

.sh-list-panel {
  width: 420px;
  flex-shrink: 0;
}

.sh-detail-panel {
  flex: 1;
  min-width: 0;
}

/* --- 统计摘要栏 --- */
.sh-summary-bar {
  display: flex;
  gap: 16px;
  padding: 10px 14px;
  background: #fff;
  border-radius: var(--radius-sm, 6px);
  margin-bottom: 10px;
  font-size: 13px;
  box-shadow: var(--shadow-sm, 0 1px 3px rgba(0,0,0,0.06));
}

.sh-summary-bar strong {
  color: var(--primary, #F18D24);
  font-size: 16px;
}

.sh-low-warning {
  color: #F44336;
}

.sh-low-warning strong { color: #F44336; }

/* --- 学员卡片列表 --- */
.sh-student-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sh-student-card {
  background: #fff;
  border-radius: var(--radius-sm, 6px);
  padding: 12px 14px;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all var(--transition-fast, .15s);
  box-shadow: var(--shadow-sm, 0 1px 3px rgba(0,0,0,0.06));
}

.sh-student-card:hover {
  box-shadow: var(--shadow-md, 0 4px 12px rgba(0,0,0,0.08));
  border-color: #e0e0e0;
}

.sh-student-card.selected {
  border-color: var(--primary, #F18D24);
  background: #fffaf5;
}

.sh-student-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.sh-student-name {
  font-weight: 600;
  font-size: 14px;
}

.sh-student-course-tag {
  font-size: 11px;
  padding: 2px 8px;
  background: var(--primary-light, #fce6c8);
  color: var(--primary-dark, #d97a1f);
  border-radius: 10px;
  font-weight: 500;
}

.sh-student-card-body { }

.sh-hours-info {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 6px;
}

.sh-hours-big {
  font-size: 22px;
  font-weight: 700;
  color: #333;
}

.sh-hours-big small {
  font-size: 12px;
  color: #999;
  font-weight: 400;
  margin-left: 2px;
}

.sh-hours-total {
  font-size: 12px;
  color: #999;
}

.sh-hours-bar {
  height: 6px;
  background: #eee;
  border-radius: 3px;
  margin-bottom: 6px;
  overflow: hidden;
}

.sh-hours-bar-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.3s;
}

.sh-hours-meta {
  display: flex;
  gap: 12px;
  font-size: 11px;
  color: #bbb;
}

/* --- 详情面板 --- */
.sh-detail-panel {
  background: #fff;
  border-radius: var(--radius-md, 10px);
  box-shadow: var(--shadow-sm, 0 1px 3px rgba(0,0,0,0.06));
  overflow: hidden;
}

.sh-detail-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: 300px;
  color: #bbb;
}

.sh-detail-empty h3 { font-size: 18px; margin-bottom: 8px; color: #999; }
.sh-detail-empty p { font-size: 14px; }

.sh-detail-content {
  padding: 20px;
}

.sh-detail-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid #f0f0f0;
}

.sh-detail-header h3 { margin: 0; font-size: 18px; }

.sh-detail-total {
  text-align: center;
}

.sh-total-big {
  display: block;
  font-size: 32px;
  font-weight: 700;
  color: var(--primary, #F18D24);
}

.sh-total-label {
  font-size: 12px;
  color: #999;
}

/* --- 课时账户卡片 --- */
.sh-accounts-list { }

.sh-accounts-list h4 {
  font-size: 14px;
  margin: 0 0 12px;
  color: #666;
}

.sh-account-card {
  background: #fafbfc;
  border-radius: var(--radius-sm, 6px);
  padding: 14px;
  margin-bottom: 10px;
  border-left: 4px solid #4CAF50;
  transition: border-color 0.2s;
}

.sh-account-card.sh-account-low {
  border-left-color: #F44336;
  background: #fff5f5;
}

.sh-account-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.sh-account-header h5 {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
}

.sh-account-body {
  display: flex;
  gap: 16px;
  margin-bottom: 10px;
}

.sh-account-stat {
  text-align: center;
  flex: 1;
}

.sh-stat-num {
  font-size: 20px;
  font-weight: 700;
  color: #333;
}

.sh-stat-label {
  font-size: 11px;
  color: #999;
  margin-top: 2px;
}

.sh-account-extras {
  display: flex;
  gap: 14px;
  font-size: 12px;
  color: #888;
  margin-bottom: 8px;
}

.sh-account-progress {
  display: flex;
  align-items: center;
  gap: 8px;
}

.sh-progress-bar {
  flex: 1;
  height: 6px;
  background: #eee;
  border-radius: 3px;
  overflow: hidden;
}

.sh-progress-fill {
  height: 100%;
  background: #4CAF50;
  border-radius: 3px;
  transition: width 0.3s;
}

.sh-account-low .sh-progress-fill { background: #F44336; }

.sh-progress-text {
  font-size: 11px;
  color: #999;
  white-space: nowrap;
}

/* --- 响应式 --- */
@media (max-width: 900px) {
  .sh-main { flex-direction: column; }
  .sh-list-panel { width: 100%; }
}
