/* ============================================================
 * 公告管理 + 课表查询 + 物流查询 模块样式
 * 白色背景 + 卡片式设计，蓝色(#3B82F6)+紫色(#8B5CF6)渐变主题
 * 与 style.css 中的通用类（.page-header/.form-*/.btn/.empty-state 等）共用
 * ============================================================ */

/* ---------- 通用：模块页背景 ---------- */
.ann-mod-permission,
.schedule-page,
.ann-list-wrap,
.ann-detail-card,
.lg-search-card {
  background: #f3f7fc;
}

/* ============================================================
 * 一、公告管理（管理员）
 * ============================================================ */
.ann-mod-permission {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding: 80px 24px;
  text-align: center;
}
.ann-perm-icon { font-size: 56px; }
.ann-perm-text { font-size: 16px; color: #64748b; margin-bottom: 8px; }

.ann-admin-toolbar {
  display: flex;
  gap: 12px;
  margin: 16px 0 20px;
  flex-wrap: wrap;
}
.ann-admin-list { display: flex; flex-direction: column; gap: 14px; }
.ann-admin-row {
  display: flex;
  align-items: center;
  gap: 14px;
  background: #fff;
  border-radius: 16px;
  padding: 18px;
  border: 1px solid #eef2f7;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
}
.ann-admin-main { flex: 1; min-width: 0; }
.ann-admin-title {
  font-size: 16px; font-weight: 600; color: #1e293b;
  margin-bottom: 6px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.ann-admin-summary {
  font-size: 13px; color: #64748b; line-height: 1.6;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.ann-admin-meta { display: flex; gap: 14px; margin-top: 8px; font-size: 12px; color: #94a3b8; }
.ann-admin-ops { display: flex; gap: 8px; flex-shrink: 0; }
.ann-op-btn {
  border: none; cursor: pointer; font-size: 13px; font-weight: 500;
  padding: 8px 16px; border-radius: 10px; transition: all .2s;
}
.ann-op-btn.edit { background: #eff6ff; color: #2563eb; }
.ann-op-btn.edit:hover { background: #dbeafe; }
.ann-op-btn.del { background: #fef2f2; color: #dc2626; }
.ann-op-btn.del:hover { background: #fee2e2; }

/* 公告编辑器图片 */
.ann-img-list { display: flex; flex-wrap: wrap; gap: 12px; }
.ann-img-item {
  position: relative; width: 96px; height: 96px; border-radius: 12px; overflow: hidden;
}
.ann-img-item img { width: 100%; height: 100%; object-fit: cover; }
.ann-img-del {
  position: absolute; top: 4px; right: 4px; width: 22px; height: 22px;
  background: rgba(0,0,0,.6); color: #fff; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; font-size: 14px; line-height: 1;
  cursor: pointer;
}
.ann-img-add {
  width: 96px; height: 96px; border: 2px dashed #cbd5e1; border-radius: 12px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  color: #94a3b8; font-size: 12px; cursor: pointer; gap: 4px;
}
.ann-img-add:hover { border-color: #3b82f6; color: #3b82f6; }
.ann-img-add span:first-child { font-size: 24px; line-height: 1; }

/* ============================================================
 * 二、公告列表（用户）
 * ============================================================ */
.ann-list-wrap { display: flex; flex-direction: column; gap: 14px; }
.ann-list-card {
  background: #fff; border-radius: 18px; padding: 18px;
  border: 1px solid #eef2f7; box-shadow: 0 2px 12px rgba(15,23,42,.04);
  cursor: pointer; transition: transform .15s, box-shadow .15s;
}
.ann-list-card:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(15,23,42,.08); }
.ann-list-head { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 10px; }
.ann-list-bell { font-size: 22px; }
.ann-list-head-text { flex: 1; min-width: 0; }
.ann-list-title { font-size: 16px; font-weight: 600; color: #1e293b; line-height: 1.4; }
.ann-list-date { font-size: 12px; color: #94a3b8; margin-top: 2px; }
.ann-list-summary {
  font-size: 14px; color: #475569; line-height: 1.6;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.ann-list-imgs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.ann-list-imgs img {
  width: 84px; height: 84px; border-radius: 10px; object-fit: cover; background: #f1f5f9;
}
.ann-list-foot {
  margin-top: 12px; padding-top: 10px; border-top: 1px solid #f1f5f9;
  font-size: 13px; color: #2563eb; font-weight: 500;
}

/* ============================================================
 * 三、公告详情
 * ============================================================ */
.ann-detail-bar { margin-bottom: 12px; }
.ann-back-btn {
  background: #fff; border: 1px solid #e2e8f0; color: #475569;
  padding: 8px 18px; border-radius: 10px; font-size: 14px; cursor: pointer;
}
.ann-back-btn:hover { color: #2563eb; border-color: #bfdbfe; }
.ann-detail-card {
  background: #fff; border-radius: 20px; padding: 24px;
  border: 1px solid #eef2f7; box-shadow: 0 2px 12px rgba(15,23,42,.04);
}
.ann-detail-title-row { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.ann-detail-bell { font-size: 26px; }
.ann-detail-title { font-size: 20px; font-weight: 700; color: #1e293b; line-height: 1.4; margin: 0; }
.ann-detail-meta { font-size: 13px; color: #94a3b8; margin-bottom: 14px; }
.ann-detail-divider { height: 1px; background: #f1f5f9; margin-bottom: 18px; }
.ann-detail-content {
  font-size: 15px; color: #334155; line-height: 1.8;
  white-space: pre-wrap; word-break: break-word;
}
.ann-detail-imgs { display: flex; flex-direction: column; gap: 12px; margin-top: 18px; }
.ann-detail-imgs img {
  width: 100%; border-radius: 12px; background: #f1f5f9; cursor: zoom-in;
}

/* ============================================================
 * 四、课表：超级管理员统计 + 学号弹窗
 * ============================================================ */
.sch-stats-card {
  margin: 16px 0; background: #fff; border-radius: 16px; padding: 18px;
  border: 1px solid #e2e8f0; box-shadow: 0 4px 12px rgba(15,23,42,.06);
}
.sch-stats-title { font-size: 15px; font-weight: 600; color: #1e293b; margin-bottom: 12px; cursor: pointer; }
.sch-stats-grid { display: flex; justify-content: space-around; }
.sch-stat { text-align: center; }
.sch-stat-num { font-size: 26px; font-weight: 700; color: #3b82f6; }
.sch-stat-label { font-size: 12px; color: #64748b; margin-top: 2px; }
.sch-stats-actions { display: flex; justify-content: center; gap: 10px; margin-top: 14px; }
.sch-mini-btn {
  background: #eff6ff; color: #2563eb; border: 1px solid #bfdbfe;
  padding: 6px 14px; border-radius: 16px; font-size: 12px; cursor: pointer;
}
.sch-mini-btn:hover { background: #dbeafe; }

/* 学号列表弹窗 */
.sch-modal-mask {
  position: fixed; inset: 0; background: rgba(0,0,0,.6); z-index: 9999;
  display: flex; align-items: center; justify-content: center;
}
.sch-modal-box {
  width: 86%; max-width: 420px; max-height: 74vh; background: #fff;
  border-radius: 16px; overflow: hidden; display: flex; flex-direction: column;
}
.sch-modal-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 16px 18px; border-bottom: 1px solid #f1f5f9; font-weight: 600; color: #1e293b;
}
.sch-modal-close { cursor: pointer; color: #94a3b8; font-size: 18px; }
.sch-modal-count { text-align: center; font-size: 12px; color: #64748b; padding: 10px; }
.sch-modal-scroll { overflow-y: auto; max-height: 50vh; padding: 0 18px 16px; }
.sch-user-row {
  display: flex; align-items: center; padding: 10px 0; border-bottom: 1px solid #f5f5f5;
}
.sch-user-idx { width: 36px; color: #94a3b8; font-size: 13px; }
.sch-user-id { flex: 1; font-size: 14px; color: #334155; font-weight: 500; }
.sch-user-del {
  font-size: 12px; color: #dc2626; border: 1px solid #fca5a5; background: #fff;
  padding: 4px 12px; border-radius: 14px; cursor: pointer;
}

/* 今日列高亮 */
.schedule-day-col.today-col { background: linear-gradient(180deg, rgba(59,130,246,.08), rgba(139,92,246,.05)); }
.schedule-table-header .schedule-day-col.today-col {
  background: linear-gradient(135deg, #3b82f6, #8b5cf6); color: #fff;
}
.today-dot {
  display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  background: #fff; margin-left: 4px; vertical-align: middle;
}

/* ============================================================
 * 五、课程 / 订单 详情弹窗（统一）
 * ============================================================ */
.cd-overlay {
  position: fixed; inset: 0; background: rgba(15,23,42,.55); z-index: 10000;
  display: flex; align-items: center; justify-content: center; padding: 20px;
}
.cd-modal {
  width: 100%; max-width: 400px; background: #fff; border-radius: 18px; overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,.25);
}
.cd-head { padding: 18px 20px; color: #fff; }
.cd-name { font-size: 17px; font-weight: 700; margin-bottom: 4px; }
.cd-sub { font-size: 13px; opacity: .9; }
.cd-body { padding: 16px 20px; }
.cd-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 0; border-bottom: 1px solid #f3f4f6; gap: 12px;
}
.cd-row:last-child { border-bottom: none; }
.cd-label { color: #6b7280; font-size: 13px; flex-shrink: 0; }
.cd-value { color: #1f2937; font-size: 13px; font-weight: 500; text-align: right; word-break: break-all; }
.cd-foot { padding: 0 20px 18px; }
.cd-foot .btn { width: 100%; }

/* ============================================================
 * 六、物流查询
 * ============================================================ */
.lg-search-card {
  background: #fff; border-radius: 18px; padding: 20px;
  border: 1px solid #eef2f7; box-shadow: 0 2px 12px rgba(15,23,42,.04);
  margin: 16px 0;
}
.lg-input-group { margin-bottom: 14px; }
.lg-input-wrapper { position: relative; }
.lg-input-wrapper .form-input { padding-right: 40px; }
.lg-clear {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  width: 22px; height: 22px; border-radius: 50%; background: #e2e8f0; color: #64748b;
  display: flex; align-items: center; justify-content: center; cursor: pointer; font-size: 14px;
}
.lg-clear:hover { background: #cbd5e1; }

.lg-history-card {
  background: #fff; border-radius: 16px; padding: 16px; margin-bottom: 16px;
  border: 1px solid #eef2f7;
}
.lg-history-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.lg-history-title { font-size: 14px; font-weight: 600; color: #334155; }
.lg-history-clear { font-size: 12px; color: #94a3b8; cursor: pointer; }
.lg-history-list { display: flex; flex-wrap: wrap; gap: 8px; }
.lg-history-item {
  display: inline-flex; align-items: center; gap: 6px;
  background: #f1f5f9; padding: 6px 14px; border-radius: 16px;
  font-size: 13px; color: #475569; cursor: pointer;
}
.lg-history-item:hover { background: #e2e8f0; }

.lg-result-head { display: flex; justify-content: space-between; align-items: center; margin: 18px 4px 12px; }
.lg-result-title { font-size: 16px; font-weight: 700; color: #1e293b; }
.lg-result-count { font-size: 13px; color: #94a3b8; }

.lg-order-list { display: flex; flex-direction: column; gap: 12px; }
.lg-order-card {
  background: #fff; border-radius: 16px; padding: 16px;
  border: 1px solid #eef2f7; box-shadow: 0 2px 10px rgba(15,23,42,.04); cursor: pointer;
  transition: transform .15s, box-shadow .15s;
}
.lg-order-card:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(15,23,42,.08); }
.lg-order-head { margin-bottom: 10px; }
.lg-order-title-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.lg-order-title {
  font-size: 15px; font-weight: 600; color: #1e293b;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.lg-order-sub { font-size: 12px; color: #94a3b8; margin-top: 4px; }
.lg-order-fields { display: flex; flex-direction: column; gap: 6px; }
.lg-field { display: flex; justify-content: space-between; gap: 12px; font-size: 13px; }
.lg-field-label { color: #94a3b8; flex-shrink: 0; }
.lg-field-value { color: #334155; text-align: right; word-break: break-all; }
.lg-status-text { color: #2563eb; font-weight: 500; }

/* 状态标签 */
.lg-status-tag {
  font-size: 11px; padding: 3px 10px; border-radius: 10px; flex-shrink: 0; font-weight: 500;
}
.lg-status-success { background: #dcfce7; color: #16a34a; }
.lg-status-processing { background: #dbeafe; color: #2563eb; }
.lg-status-pending { background: #fef9c3; color: #ca8a04; }
.lg-status-failed { background: #fee2e2; color: #dc2626; }
.lg-status-default { background: #f1f5f9; color: #64748b; }

/* 骨架屏 */
.lg-skeleton { display: flex; flex-direction: column; gap: 12px; }
.lg-skeleton-card {
  height: 80px; border-radius: 16px; background: #fff;
  position: relative; overflow: hidden; border: 1px solid #eef2f7;
}
.lg-skeleton-card::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.6), transparent);
  animation: lgShine 1.4s infinite;
}
@keyframes lgShine { from { transform: translateX(-100%); } to { transform: translateX(100%); } }

.lg-footer-tip { text-align: center; font-size: 12px; color: #b0b8c4; padding: 24px 0; }

/* ============================================================
 * 七、响应式
 * ============================================================ */
@media (max-width: 640px) {
  .ann-admin-row { flex-direction: column; align-items: stretch; }
  .ann-admin-ops { justify-content: flex-end; }
  .sch-stats-grid { gap: 8px; }
  .sch-stat-num { font-size: 22px; }
  .cd-modal { max-width: 100%; }
  .lg-order-title-row { flex-direction: column; align-items: flex-start; gap: 6px; }
}

/* 周视图在小屏可横向滚动 */
.schedule-table-wrapper { overflow-x: auto; }
.schedule-table { min-width: 640px; }
