
:root {
  --primary: #1a73e8;
  --primary-light: #e8f0fe;
  --success: #0d904f;
  --warning: #e37400;
  --danger: #d93025;
  --bg: #f5f6fa;
  --card: #ffffff;
  --text: #202124;
  --text-secondary: #5f6368;
  --border: #dadce0;
  --shadow: 0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.06);
  --radius: 12px;
  --radius-sm: 8px;
  --transition: 0.2s ease;
}
* { margin:0; padding:0; box-sizing:border-box; -webkit-tap-highlight-color: transparent; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  background: var(--bg); color: var(--text); line-height: 1.5; min-height: 100vh;
  /* 移动端触控优化：禁止横向溢出、下拉留白回弹干扰、长按选词 */
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: contain;
  -webkit-user-select: none; user-select: none;
  padding-bottom: env(safe-area-inset-bottom);
}
/* 可输入区域恢复选择/光标 */
input, textarea, select { -webkit-user-select: text; user-select: text; }
/* 去除交互元素的双击缩放延迟 */
.btn, .toggle-btn, .tab, .sidebar-item, .photo-upload, .check-row, .bell, .role-tag, .driver-identity { touch-action: manipulation; }
/* 滚动区域惯性滚动（iOS） */
.main, .modal, .notif-panel, .table-wrap, .review-record-body { -webkit-overflow-scrolling: touch; }
/* ── Top Header ── */
.header {
  background: var(--primary); color: #fff; padding: 0 20px;
  display: flex; align-items: center; justify-content: space-between; height: 56px;
  position: sticky; top: 0; z-index: 100;
}
.header h1 { font-size: 17px; font-weight: 600; letter-spacing: 0.3px; }
.header .role-tag {
  font-size: 12px; background: rgba(255,255,255,0.2); padding: 3px 10px;
  border-radius: 20px; cursor: pointer; border: 1px solid rgba(255,255,255,0.3);
}
.header .role-tag:hover { background: rgba(255,255,255,0.3); }

/* ── Tab Navigation ── */
.tabs {
  display: flex; background: var(--card); border-bottom: 1px solid var(--border);
  position: sticky; top: 56px; z-index: 99;
}
.tab {
  flex:1; text-align: center; padding: 12px; font-size: 14px; font-weight: 500;
  color: var(--text-secondary); cursor: pointer; border-bottom: 2px solid transparent;
  transition: var(--transition); position: relative;
}
.tab.active { color: var(--primary); border-bottom-color: var(--primary); }
.tab:hover { background: var(--primary-light); }

/* ── Sidebar (Admin) ── */
.admin-layout { display: flex; min-height: calc(100vh - 56px - 46px); }
.sidebar {
  width: 200px; background: var(--card); border-right: 1px solid var(--border);
  padding: 16px 0; flex-shrink: 0;
}
.sidebar-item {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 10px 20px; font-size: 14px; color: var(--text-secondary);
  cursor: pointer; transition: var(--transition); border-left: 3px solid transparent;
  text-decoration: none; white-space: nowrap;
}
.nav-badge {
  background: var(--danger); color: #fff; border-radius: 10px; font-size: 11px; font-weight: 700;
  min-width: 18px; height: 18px; padding: 0 5px; display: inline-flex; align-items: center;
  justify-content: center; flex-shrink: 0;
}
.sidebar-item:hover { background: var(--primary-light); color: var(--primary); }
.sidebar-item.active { color: var(--primary); border-left-color: var(--primary); background: var(--primary-light); font-weight: 600; }

/* ── Main Content ── */
.main { flex:1; padding: 20px; overflow-y: auto; }
.page { display:none; }
.page.active { display:block; }

/* ── Cards ── */
.card { background: var(--card); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); margin-bottom: 16px; }
.card-title { font-size: 16px; font-weight: 600; margin-bottom: 12px; color: var(--text); }
.card-subtitle { font-size: 13px; color: var(--text-secondary); margin-bottom: 16px; }

/* ── Stats Grid ── */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; margin-bottom: 20px; }
.stat-card { background: var(--card); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow); }
.stat-card .label { font-size: 12px; color: var(--text-secondary); margin-bottom: 4px; }
.stat-card .value { font-size: 28px; font-weight: 700; }
.stat-card .value.danger { color: var(--danger); }
.stat-card .value.warning { color: var(--warning); }
.stat-card .value.success { color: var(--success); }
.stat-card .value.primary { color: var(--primary); }

/* ── Form ── */
.form-group { margin-bottom: 16px; }
.form-label { display: block; font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 6px; }
.form-label .required { color: var(--danger); margin-left: 2px; }
.form-input, .form-select {
  width: 100%; padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--radius-sm);
  font-size: 14px; color: var(--text); background: var(--card); transition: var(--transition);
  outline: none; font-family: inherit;
}
.form-input:focus, .form-select:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(26,115,232,0.12); }
.form-select { cursor: pointer; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M3 4.5l3 3 3-3' fill='none' stroke='%235f6368' stroke-width='1.5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 32px; }
.form-hint { font-size: 12px; color: var(--text-secondary); margin-top: 4px; }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 10px 20px; border: none; border-radius: var(--radius-sm);
  font-size: 14px; font-weight: 500; cursor: pointer; transition: var(--transition);
  font-family: inherit; white-space: nowrap;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: #1557b0; }
.btn-primary:disabled { background: #a8c7fa; cursor: not-allowed; }
.btn-success { background: var(--success); color: #fff; }
.btn-success:hover { background: #0a7a3e; }
.btn-outline { background: transparent; color: var(--primary); border: 1px solid var(--primary); }
.btn-outline:hover { background: var(--primary-light); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #b3261e; }
.btn-sm { padding: 6px 12px; font-size: 12px; }
.btn-lg { padding: 14px 28px; font-size: 16px; border-radius: var(--radius); }
.btn-block { width: 100%; }
.btn-group { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 20px; }

/* ── 吸底操作栏（移动端提交流程更顺手）── */
.submit-actions {
  position: sticky; bottom: 0; z-index: 30;
  display: flex; gap: 10px; margin-top: 20px;
  padding: 12px 0 4px;
  background: linear-gradient(to top, var(--bg) 70%, rgba(245,246,250,0));
}
.submit-actions .btn { flex: 1; }

/* ── 前端(司导端)顶部 Tab 栏 ── */
.fe-tabs { position: sticky; top: 56px; z-index: 99; }

/* ── Steps ── */
.steps { display: flex; margin-bottom: 24px; }
.step { flex:1; text-align: center; position: relative; }
.step::after {
  content: ''; position: absolute; top: 14px; left: calc(50% + 20px); width: calc(100% - 40px);
  height: 2px; background: var(--border);
}
.step:last-child::after { display: none; }
.step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px; border-radius: 50%; background: var(--border); color: var(--text-secondary);
  font-size: 13px; font-weight: 600; position: relative; z-index: 1;
}
.step.active .step-num { background: var(--primary); color: #fff; }
.step.done .step-num { background: var(--success); color: #fff; }
.step.done::after { background: var(--success); }
.step-label { font-size: 11px; color: var(--text-secondary); margin-top: 4px; }
.step.active .step-label { color: var(--primary); font-weight: 600; }

/* ── Photo Upload Grid ── */
.photo-section { margin-bottom: 24px; }
.photo-section-title { font-size: 15px; font-weight: 600; margin-bottom: 12px; padding-bottom: 8px; border-bottom: 1px solid var(--border); }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.photo-item { position: relative; }
.photo-label { font-size: 12px; color: var(--text-secondary); margin-bottom: 6px; font-weight: 500; }
.photo-upload {
  width: 100%; aspect-ratio: 4/3; border: 2px dashed var(--border); border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center; cursor: pointer;
  transition: var(--transition); background: #fafbfc; overflow: hidden; position: relative;
}
.photo-upload:hover { border-color: var(--primary); background: var(--primary-light); }
.photo-upload.has-image { border-style: solid; border-color: var(--border); }
.photo-upload img { width: 100%; height: 100%; object-fit: cover; }
.photo-placeholder { text-align: center; color: var(--text-secondary); }
.photo-placeholder .icon { font-size: 28px; display: block; margin-bottom: 4px; }
.photo-placeholder .text { font-size: 11px; }
.photo-remove {
  position: absolute; top: 4px; right: 4px; width: 22px; height: 22px;
  background: rgba(0,0,0,0.6); color: #fff; border-radius: 50%; display: flex;
  align-items: center; justify-content: center; font-size: 14px; cursor: pointer; border: none;
  display: none;
}
.photo-upload.has-image + .photo-remove { display: flex; }

/* ── Score Badge ── */
.score-badge {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 50%; font-size: 15px; font-weight: 700;
  color: #fff; flex-shrink: 0;
}
.score-badge.level-danger { background: var(--danger); }
.score-badge.level-warning { background: var(--warning); }
.score-badge.level-mild { background: #f9ab00; }
.score-badge.level-perfect { background: var(--success); }

.level-tag {
  display: inline-block; padding: 2px 10px; border-radius: 20px; font-size: 12px; font-weight: 600;
}
.level-tag.danger { background: #fce8e6; color: var(--danger); }
.level-tag.warning { background: #fef7e0; color: var(--warning); }
.level-tag.mild { background: #fef7e0; color: #e37400; }
.level-tag.perfect { background: #e6f4ea; color: var(--success); }

.missing-tag {
  display: inline-block; padding: 2px 10px; border-radius: 20px; font-size: 12px; font-weight: 600;
  color: var(--text-secondary); background: #f1f3f4; white-space: nowrap;
}
.missing-tag.has-missing { background: #fce8e6; color: var(--danger); }

/* ── Table ── */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
thead th {
  background: #f8f9fa; padding: 10px 12px; text-align: left; font-weight: 600;
  color: var(--text-secondary); border-bottom: 2px solid var(--border); white-space: nowrap;
}
tbody td { padding: 10px 12px; border-bottom: 1px solid var(--border); }
tbody tr:hover { background: #f8f9fa; }
.photo-thumb { width: 50px; height: 38px; object-fit: cover; border-radius: 4px; border: 1px solid var(--border); }

/* ── Alert / Toasts ── */
.toast {
  position: fixed; top: 20px; right: 20px; z-index: 9999;
  padding: 12px 20px; border-radius: var(--radius-sm); font-size: 14px; font-weight: 500;
  color: #fff; box-shadow: 0 4px 12px rgba(0,0,0,0.2); animation: slideIn 0.3s ease;
  max-width: 400px;
}
.toast.success { background: var(--success); }
.toast.error { background: var(--danger); }
.toast.info { background: var(--primary); }
.toast.warning { background: var(--warning); }
@keyframes slideIn {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* ── Notification Popup ── */
.notify-popup {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.5);
  z-index: 9998; display: flex; align-items: center; justify-content: center;
  animation: fadeIn 0.2s ease;
}
@keyframes fadeIn { from { opacity:0; } to { opacity:1; } }
.notify-card {
  background: #fff; border-radius: var(--radius); padding: 28px; max-width: 420px; width: 90%;
  box-shadow: 0 8px 30px rgba(0,0,0,0.2);
}
.notify-icon { font-size: 40px; text-align: center; margin-bottom: 8px; }
.notify-title { font-size: 18px; font-weight: 700; text-align: center; margin-bottom: 6px; }
.notify-desc { font-size: 13px; color: var(--text-secondary); text-align: center; margin-bottom: 16px; line-height: 1.6; }
.notify-recipients { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-bottom: 16px; }
.notify-recipient {
  background: var(--primary-light); color: var(--primary); padding: 4px 12px;
  border-radius: 20px; font-size: 12px; font-weight: 500;
}
.notify-score {
  display: flex; align-items: center; justify-content: center; gap: 8px; margin-bottom: 16px;
}
.notify-btn { width: 100%; }

/* ── Modal ── */
.modal-overlay {
  position: fixed; top:0;left:0;right:0;bottom:0; background: rgba(0,0,0,0.5);
  z-index: 9997; display: flex; align-items: center; justify-content: center;
}
.modal {
  background: #fff; border-radius: var(--radius); padding: 24px; max-width: 480px; width: 90%;
  box-shadow: 0 8px 30px rgba(0,0,0,0.2); max-height: 80vh; overflow-y: auto;
}
.modal-title { font-size: 17px; font-weight: 700; margin-bottom: 16px; }

/* ── Empty State ── */
.empty {
  text-align: center; padding: 60px 20px; color: var(--text-secondary);
}
.empty .icon { font-size: 48px; display: block; margin-bottom: 12px; opacity: 0.5; }
.empty .text { font-size: 14px; }

/* ── Loading ── */
.loading-overlay {
  position: fixed; top:0;left:0;right:0;bottom:0; background: rgba(255,255,255,0.85);
  z-index: 9999; display: flex; flex-direction: column; align-items: center; justify-content: center;
}
.spinner {
  width: 40px; height: 40px; border: 3px solid var(--border);
  border-top-color: var(--primary); border-radius: 50%; animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.loading-text { margin-top: 12px; color: var(--text-secondary); font-size: 14px; }

/* ── Detail Photo Grid ── */
.detail-photo-card {
  background: var(--card); border-radius: var(--radius-sm); overflow: hidden;
  box-shadow: var(--shadow); position: relative;
}
.detail-photo-card img { width: 100%; aspect-ratio: 4/3; object-fit: cover; display: block; }
.detail-photo-info {
  padding: 8px 10px; display: flex; align-items: center; justify-content: space-between;
}
.detail-photo-name { font-size: 12px; color: var(--text-secondary); }

/* ── Push Log ── */
.push-log-item {
  padding: 12px; border-left: 3px solid var(--border); margin-bottom: 8px;
  background: #fafbfc; border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}
.push-log-item.danger { border-left-color: var(--danger); }
.push-log-item.warning { border-left-color: var(--warning); }
.push-log-item.mild { border-left-color: #f9ab00; }
.push-log-time { font-size: 11px; color: var(--text-secondary); }
.push-log-roles { margin-top: 4px; display: flex; gap: 4px; flex-wrap: wrap; }

/* ── Responsive ── */
@media (max-width: 768px) {
  .admin-layout { flex-direction: column; }
  .sidebar {
    width: 100%; display: flex; overflow-x: auto; padding: 8px;
    border-right: none; border-bottom: 1px solid var(--border);
  }
  .sidebar-item { flex-shrink: 0; border-left: none; border-bottom: 3px solid transparent; white-space: nowrap; }
  .sidebar-item.active { border-left-color: transparent; border-bottom-color: var(--primary); }
  .photo-grid { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .main { padding: 12px; }
}

/* ── 移动端（手机）深度适配：更顺手的触控与布局 ── */
@media (max-width: 640px) {
  /* 顶部 Tab 占满整行，左右等分 */
  .fe-tabs { display: flex; background: var(--card); border-bottom: 1px solid var(--border); }
  .fe-tabs .sidebar-item {
    flex: 1 1 0; justify-content: center; padding: 14px 8px;
    border-left: none; border-bottom: 3px solid transparent;
  }
  .fe-tabs .sidebar-item.active { border-bottom-color: var(--primary); }

  /* 输入框放大到 16px，避免 iOS 聚焦时页面自动缩放 */
  .form-input, .form-select { font-size: 16px; padding: 12px 14px; }

  /* 按钮触控区 ≥44px，切换按钮更大气 */
  .btn { padding: 12px 20px; min-height: 44px; font-size: 15px; border-radius: var(--radius-sm); }
  .btn-lg { padding: 15px; font-size: 17px; }
  .btn-sm { padding: 8px 14px; min-height: 36px; }
  .toggle-btn { padding: 8px 18px; min-height: 40px; font-size: 15px; }

  /* 吸底操作栏贴底 + 适配刘海/底部安全区 */
  .submit-actions {
    position: sticky; bottom: 0; margin: 16px -12px -12px; padding: 12px 12px calc(12px + env(safe-area-inset-bottom));
    background: var(--card); border-top: 1px solid var(--border);
    box-shadow: 0 -4px 16px rgba(0,0,0,0.06); border-radius: var(--radius) var(--radius) 0 0;
  }

  /* 步骤条更紧凑，标签不换行挤压 */
  .steps { margin-bottom: 16px; }
  .step-label { font-size: 10px; }
  .step-num { width: 26px; height: 26px; font-size: 12px; }
  .step::after { top: 13px; }

  /* 照片网格 2 列、点按区域更大 */
  .photo-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .photo-upload { aspect-ratio: 1 / 1; }
  .photo-label { font-size: 13px; margin-bottom: 8px; }

  /* 勾选项：名称与开关上下不挤，整行可点 */
  .check-row { align-items: center; }
  .check-name { font-size: 15px; }
  .check-hint { font-size: 12px; }

  /* 通知面板在小屏不溢出右侧 */
  .notif-panel { width: calc(100vw - 24px); right: 12px; top: 52px; }

  /* 弹窗在小屏更贴边、留出安全区 */
  .modal { width: 94%; max-height: 86vh; padding: 20px; padding-bottom: calc(20px + env(safe-area-inset-bottom)); }

  /* 卡片内边距收紧 */
  .card { padding: 16px; }

  /* 头部更紧凑，标题字号略缩 */
  .header { padding: 0 12px; height: 52px; }
  .header h1 { font-size: 16px; }
  .fe-tabs { top: 52px; }
  .tabs { top: 52px; }

  /* 统计卡在小屏两列 */
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
}

/* 极窄屏（≤360px）进一步收紧步骤标签 */
@media (max-width: 360px) {
  .step-label { display: none; }
  .step { padding: 0 2px; }
}

/* ── Header Actions (driver) ── */
.header-actions { display: flex; align-items: center; gap: 12px; }
.driver-identity {
  padding: 5px 10px; border-radius: 20px; border: 1px solid rgba(255,255,255,0.4);
  background: rgba(255,255,255,0.15); color: #fff; font-size: 12px; cursor: pointer; outline: none;
  max-width: 120px;
}
.driver-identity option { color: #202124; }
.bell-wrap { position: relative; }
.bell {
  position: relative; font-size: 20px; cursor: pointer; width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center; border-radius: 50%;
  background: rgba(255,255,255,0.15); transition: var(--transition);
}
.bell:hover { background: rgba(255,255,255,0.3); }
.btn-logout {
  padding: 5px 14px; border-radius: 20px; border: 1px solid rgba(255,255,255,0.5);
  background: rgba(255,255,255,0.12); color: #fff; font-size: 13px; cursor: pointer;
  outline: none; transition: var(--transition); white-space: nowrap;
}
.btn-logout:hover { background: rgba(255,255,255,0.28); }
.badge {
  position: absolute; top: -2px; right: -2px; min-width: 18px; height: 18px; padding: 0 4px;
  background: var(--danger); color: #fff; border-radius: 9px; font-size: 11px; font-weight: 700;
  display: flex; align-items: center; justify-content: center; border: 2px solid var(--primary);
}
.notif-panel {
  position: absolute; top: 44px; right: 0; width: 320px; max-height: 70vh; overflow-y: auto;
  background: #fff; border-radius: var(--radius); box-shadow: 0 8px 30px rgba(0,0,0,0.2); z-index: 200;
  color: var(--text);
}
.notif-panel-head {
  display: flex; justify-content: space-between; align-items: center; padding: 12px 14px;
  border-bottom: 1px solid var(--border); font-size: 13px; font-weight: 600;
}
.notif-mark-all { color: var(--primary); font-size: 12px; cursor: pointer; font-weight: 500; }
.notif-empty { padding: 30px; text-align: center; color: var(--text-secondary); font-size: 13px; }
.notif-item {
  display: flex; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--border); cursor: pointer;
  position: relative; transition: var(--transition);
}
.notif-item:hover { background: #f8f9fa; }
.notif-item.read { opacity: 0.6; }
.notif-item-icon { font-size: 20px; }
.notif-item-body { flex: 1; }
.notif-item-title { font-size: 13px; font-weight: 600; }
.notif-item-reason { font-size: 12px; color: var(--text-secondary); margin-top: 2px; }
.notif-item-time { font-size: 11px; color: var(--text-secondary); margin-top: 4px; }
.notif-unread-dot { position: absolute; top: 14px; right: 10px; width: 8px; height: 8px; border-radius: 50%; background: var(--danger); }

/* ── Module / checklist (driver submit + admin review) ── */
.module-block { margin-bottom: 20px; border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; background: #fff; }
.module-title { font-size: 14px; font-weight: 700; padding: 10px 12px; background: #f7f8fa; border-bottom: 1px solid var(--border); }
.sub-title { font-size: 13px; font-weight: 600; color: var(--text-secondary); margin: 12px 0 8px; padding-left: 2px; }
.check-list { padding: 10px 12px; display: flex; flex-direction: column; gap: 10px; }
.check-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.check-main { flex: 1; min-width: 0; }
.check-name { font-size: 14px; font-weight: 500; }
.check-hint { font-size: 12px; color: var(--text-secondary); margin-top: 3px; line-height: 1.45; }
.check-toggle { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.toggle-btn { padding: 4px 14px; border: 1px solid var(--border); background: #fff; border-radius: 20px; font-size: 13px; cursor: pointer; color: var(--text-secondary); transition: all .15s; }
.toggle-btn:hover { border-color: var(--primary); }
.toggle-btn.on { background: var(--primary); color: #fff; border-color: var(--primary); }
.check-done { font-size: 12px; font-weight: 600; color: var(--success); margin-left: 4px; white-space: nowrap; }
.check-done.pending { color: #b0b0b0; }
.photo-hint { font-size: 12px; color: var(--text-secondary); margin: 6px 0 10px; line-height: 1.5; background: #f7f8fa; padding: 8px 10px; border-radius: var(--radius-sm); }
.detail-photo-empty { width: 100%; aspect-ratio: 4/3; background: #f0f0f0; display: flex; align-items: center; justify-content: center; color: #ccc; font-size: 24px; }
.review-module-title { font-size: 14px; font-weight: 600; margin: 16px 0 8px; padding-bottom: 6px; border-bottom: 1px solid var(--border); }
.review-subtitle { font-size: 13px; font-weight: 600; color: var(--text-secondary); margin: 10px 0 6px; }

/* ── Review badges & cards (admin) ── */
.review-group-title { font-size: 14px; font-weight: 600; margin: 14px 0 8px; }
.review-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.review-card {
  border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; background: #fff;
  display: flex; flex-direction: column;
}
.review-photo { width: 100%; aspect-ratio: 4/3; background: #f0f0f0; }
.review-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.review-photo-empty { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: #ccc; font-size: 28px; }
.review-info { padding: 8px 10px; display: flex; flex-direction: column; gap: 4px; }
.review-name { font-size: 13px; font-weight: 600; }
.review-reason { font-size: 12px; color: var(--danger); }
.review-actions { padding: 0 10px 10px; display: flex; gap: 8px; }
/* AI 视觉初审结论 */
.ai-note { font-size: 12px; color: var(--text-secondary); background: var(--primary-light); border: 1px solid #c6dbff; padding: 6px 10px; border-radius: var(--radius-sm); margin-bottom: 10px; }
.review-ai { display: flex; align-items: flex-start; gap: 6px; flex-wrap: wrap; }
.ai-score-badge { display: inline-block; padding: 1px 8px; border-radius: 20px; font-size: 11px; font-weight: 700; color: #fff; }
.ai-score-badge.green { background: var(--success); }
.ai-score-badge.yellow { background: var(--warning); }
.ai-score-badge.red { background: var(--danger); }
.ai-conclusion { font-size: 12px; color: var(--text-secondary); line-height: 1.4; }
.review-ai.ai-none { color: #9aa0a6; font-size: 12px; }
/* 司导端缩略图 AI 分 */
.photo-upload { position: relative; }
.ai-pill { position: absolute; right: 6px; bottom: 6px; padding: 1px 7px; border-radius: 20px; font-size: 11px; font-weight: 700; color: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); }
.ai-pill.green { background: var(--success); }
.ai-pill.yellow { background: var(--warning); }
.ai-pill.red { background: var(--danger); }
.review-actions .btn { flex: 1; }
/* 已确认/已驳回：确认或驳回按钮变成 ✅ 禁用态 */
.review-done { opacity: 1; cursor: default; font-weight: 600; }
/* 未上传图片：标灰、不可操作 */
.review-card-empty { background: #fafafa; border-style: dashed; }
.review-card-empty .review-photo { background: #f2f2f2; }
.review-actions-disabled {
  flex: 1; text-align: center; padding: 7px 0; margin: 0 10px 10px;
  background: #f1f1f1; color: #b0b0b0; border-radius: var(--radius-sm); font-size: 12px;
}
.review-badge {
  display: inline-block; padding: 2px 10px; border-radius: 20px; font-size: 11px; font-weight: 600; align-self: flex-start;
}
.review-badge.review-pending { background: #e8eaed; color: #5f6368; }
.review-badge.review-confirmed { background: #e6f4ea; color: var(--success); }
.review-badge.review-rejected { background: #fce8e6; color: var(--danger); }

/* ── 审核管理：可折叠记录 + 状态徽标 ── */
.review-record { border: 1px solid var(--border); border-radius: var(--radius-sm); margin-bottom: 16px; background: #fff; overflow: hidden; }
.review-record-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 12px 14px; cursor: pointer; background: #fafbfc; transition: var(--transition); }
.review-record-head:hover { background: #f1f3f4; }
.rr-left { display: flex; align-items: center; gap: 8px; min-width: 0; }
.rr-toggle { font-size: 13px; color: var(--text-secondary); flex-shrink: 0; width: 14px; text-align: center; }
.rr-info { font-size: 13px; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rr-info strong { font-weight: 600; }
.rr-right { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.review-record-body { padding: 14px; }
.review-record-body.collapsed { display: none; }
.status-badge { display: inline-block; padding: 2px 10px; border-radius: 20px; font-size: 11px; font-weight: 600; white-space: nowrap; }
.status-badge.status-completed { background: #e6f4ea; color: var(--success); }
.status-badge.status-pending { background: #e8eaed; color: var(--text-secondary); }
/* 提交审核栏：固定在展开内容底部 */
.rr-submit-bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 16px; padding-top: 14px; border-top: 1px dashed var(--border); }
.review-hint { font-size: 12px; color: var(--text-secondary); }

/* ── Logout button (admin) ── */
.logout-btn { color: #fff; border-color: rgba(255,255,255,0.5); }
.logout-btn:hover { background: rgba(255,255,255,0.15); }

/* ── Login Overlay ── */
.login-overlay {
  position: fixed; top:0; left:0; right:0; bottom:0; background: var(--primary);
  z-index: 10000; display: flex; align-items: center; justify-content: center;
}
.login-card {
  background: #fff; border-radius: var(--radius); padding: 32px; width: 90%; max-width: 360px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.25); text-align: center;
}
.login-logo { font-size: 40px; margin-bottom: 8px; }
.login-title { font-size: 18px; font-weight: 700; margin-bottom: 4px; }
.login-sub { font-size: 13px; color: var(--text-secondary); margin-bottom: 20px; }
.login-card .form-group { text-align: left; }
.login-hint { font-size: 12px; color: var(--text-secondary); margin-top: 16px; }
.login-error {
  display: none; font-size: 13px; color: #fff; background: var(--danger);
  border-radius: var(--radius); padding: 8px 12px; margin-top: 12px; text-align: center;
}
