/* ====== 通用Modal - 钉钉风格底部弹窗 ====== */
.modal-overlay {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.5); z-index: 500; display: none; align-items: flex-end; justify-content: center;
}
.modal-overlay.show { display: flex; }
.modal-box {
  background: #fff; border-radius: var(--radius-xl) var(--radius-xl) 0 0;
  width: 100%; max-width: 500px; max-height: 85vh;
  overflow-y: auto; padding: 24px 20px; animation: modalSlideUp 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
@keyframes modalSlideUp { from { transform: translateY(100%); } to { transform: translateY(0); } }
.modal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.modal-title { font-size: 18px; font-weight: 600; }
.modal-close { font-size: 20px; color: var(--text-hint); background: none; padding: 4px; }

/* ====== 详情子页面（全屏覆盖）- 钉钉风格滑入 ====== */
.detail-page {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0;
  background: var(--bg); z-index: 300; display: none; flex-direction: column;
  animation: detailSlideIn 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
@keyframes detailSlideIn { from { transform: translateX(100%); } to { transform: translateX(0); } }
.detail-page.show { display: flex; }
.detail-page-header {
  display: flex; align-items: center; gap: 12px;
  padding: 0 16px; height: var(--header-height);
  background: #fff; border-bottom: 1px solid var(--border-light); flex-shrink: 0;
}
.detail-page-back { font-size: 20px; color: var(--text-secondary); background: none; padding: 4px; }
.detail-page-title { font-size: 17px; font-weight: 600; flex: 1; }
.detail-page-body { flex: 1; overflow-y: auto; padding: 12px 16px; -webkit-overflow-scrolling: touch; }

/* 管理员详情页共用样式 */
.detail-desc { background: linear-gradient(135deg, #e8f0ff, #f0f5ff); padding: 14px 16px; border-radius: var(--radius); margin-bottom: 16px; border-left: 4px solid var(--primary); }
.detail-desc p { font-size: 13px; color: var(--text-secondary); line-height: 1.7; }
.detail-stats { display: flex; gap: 10px; margin-bottom: 16px; }
.detail-stat-item { flex: 1; background: #fff; border-radius: var(--radius); padding: 14px; text-align: center; box-shadow: var(--shadow); }
.detail-stat-val { font-size: 22px; font-weight: 700; color: var(--primary); }
.detail-stat-label { font-size: 11px; color: var(--text-hint); margin-top: 4px; }
.detail-section { margin-bottom: 20px; }
.detail-section h4 { font-size: 15px; font-weight: 600; margin-bottom: 12px; color: var(--text); display: flex; align-items: center; gap: 8px; }
.detail-section h4::before { content: ''; width: 3px; height: 14px; background: var(--primary); border-radius: 2px; }
.detail-card { background: #fff; border-radius: var(--radius); padding: 16px; margin-bottom: 10px; box-shadow: var(--shadow); }
.detail-card-row { display: flex; justify-content: space-between; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--bg-grey); }
.detail-card-row:last-child { border-bottom: none; }
.detail-card-row span:first-child { color: var(--text-hint); font-size: 13px; }
.detail-card-row span:last-child { font-size: 14px; color: var(--text); font-weight: 500; }
.detail-card-actions { display: flex; gap: 8px; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--bg-grey); }
.detail-actions { margin-bottom: 8px; }
.detail-btn { padding: 8px 16px; border-radius: 10px; font-size: 13px; font-weight: 500; border: none; cursor: pointer; transition: all 0.2s; }
.detail-btn-primary { background: var(--primary); color: #fff; box-shadow: 0 2px 8px rgba(51,112,255,0.3); }
.detail-btn-primary:active { background: var(--primary-dark); }
.detail-btn-danger { background: var(--danger); color: #fff; box-shadow: 0 2px 8px rgba(255,59,48,0.3); }
.detail-btn-outline { background: #fff; color: var(--primary); border: 1px solid var(--primary); }

/* P4: 审批进度步骤条 */
.approval-steps { display: flex; align-items: center; margin: 12px 0; padding: 0 4px; }
.approval-step { display: flex; align-items: center; flex: 1; position: relative; }
.approval-step-dot { width: 24px; height: 24px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; color: #fff; background: var(--border); flex-shrink: 0; z-index: 1; transition: all 0.3s; }
.approval-step-dot.done { background: var(--success); }
.approval-step-dot.active { background: var(--primary); box-shadow: 0 0 0 4px rgba(51,112,255,0.2); }
.approval-step-dot.rejected { background: var(--danger); }
.approval-step-dot.waiting { background: var(--text-hint); }
.approval-step-line { flex: 1; height: 2px; background: var(--border); margin: 0 4px; }
.approval-step-line.done { background: var(--success); }
.approval-step-label { font-size: 11px; color: var(--text-hint); margin-top: 4px; text-align: center; white-space: nowrap; max-width: 70px; overflow: hidden; text-overflow: ellipsis; }
.approval-step-info { display: flex; flex-direction: column; align-items: center; }
.approval-step-info.active .approval-step-label { color: var(--primary); font-weight: 600; }
