/* 鑫好兴工作系统 H5 - 全局样式 */

/* CSS 变量 */
:root {
  --primary-50: #f0f4ff;
  --primary-100: #e0e9ff;
  --primary-200: #c7d6fe;
  --primary-300: #a4b8fc;
  --primary-400: #8093f8;
  --primary-500: #5a6ff2;
  --primary-600: #4650e6;
  --primary-700: #3a41cb;

  --success: #10b981;
  --success-light: #d1fae5;
  --success-dark: #059669;

  --warning: #f59e0b;
  --warning-light: #fef3c7;
  --warning-dark: #d97706;

  --error: #ef4444;
  --error-light: #fee2e2;

  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;

  --bg-primary: #f8fafc;
  --bg-secondary: #ffffff;

  --text-primary: #1f2937;
  --text-secondary: #4b5563;
  --text-tertiary: #9ca3af;

  --border-light: #e5e7eb;
  --shadow-sm: 0 2px 10px rgba(31, 41, 55, 0.06);
  --shadow-md: 0 10px 28px rgba(31, 41, 55, 0.1);
  --shadow-lg: 0 18px 45px rgba(31, 41, 55, 0.14);
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-2xl: 24px;
}

/* Reset */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { font-size: 16px; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: var(--text-primary);
  background:
    radial-gradient(circle at 20% -10%, rgba(90, 111, 242, 0.12), transparent 36%),
    radial-gradient(circle at 120% 0%, rgba(16, 185, 129, 0.1), transparent 30%),
    var(--bg-primary);
  min-height: 100vh;
  line-height: 1.5;
}

a {
  color: inherit;
  text-decoration: none;
}

/* 登录页 */
.login-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background:
    radial-gradient(circle at 10% 10%, rgba(255,255,255,0.2), transparent 28%),
    radial-gradient(circle at 90% 90%, rgba(255,255,255,0.14), transparent 34%),
    linear-gradient(140deg, var(--primary-500), var(--primary-700));
}

.login-logo { font-size: 64px; margin-bottom: 16px; }
.login-title { font-size: 24px; color: #fff; font-weight: 600; }
.login-subtitle { font-size: 14px; color: rgba(255,255,255,0.8); margin-bottom: 48px; }

.login-form {
  width: 100%;
  max-width: 320px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  border-radius: var(--radius-2xl);
  padding: 32px 24px;
  box-shadow: var(--shadow-lg);
}

/* 表单 */
.form-group { margin-bottom: 20px; }
.form-label { display: block; font-size: 14px; color: var(--text-primary); margin-bottom: 8px; font-weight: 500; }
.form-input {
  width: 100%;
  height: 48px;
  padding: 0 16px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  font-size: 16px;
  background: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.form-input:focus {
  outline: none;
  border-color: var(--primary-500);
  box-shadow: 0 0 0 3px rgba(90, 111, 242, 0.14);
}

/* 按钮 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 48px;
  padding: 0 24px;
  border-radius: var(--radius-lg);
  font-size: 16px;
  font-weight: 500;
  border: none;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, background-color 0.2s;
}
.btn-primary { background: var(--primary-500); color: #fff; }
.btn-primary:hover { background: var(--primary-600); box-shadow: var(--shadow-sm); }
.btn-primary:disabled { background: var(--gray-300); }
.btn-secondary { background: var(--gray-100); color: var(--text-secondary); }
.btn-secondary:hover { background: var(--gray-200); }
.btn-danger { background: var(--error); color: #fff; }
.btn-danger:hover { background: #dc2626; box-shadow: var(--shadow-sm); }
.btn-block { width: 100%; }
.btn-sm { height: 36px; padding: 0 16px; font-size: 14px; }
.btn:active { transform: translateY(1px); }

/* 企业微信登录按钮 */
.btn-wework {
  background: #07C160;
  color: #fff;
}
.btn-wework:hover {
  background: #06ad56;
}
.btn-wework:active {
  background: #059b4c;
}

/* 企业微信登录分隔线 */
.wework-divider {
  display: flex;
  align-items: center;
  margin: 20px 0;
}
.wework-divider::before,
.wework-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-light);
}
.wework-divider span {
  padding: 0 16px;
  font-size: 12px;
  color: var(--text-tertiary);
}

/* 首页 */
.home-page { padding-bottom: 32px; }

/* 导航栏 */
.nav-bar {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  height: 56px;
  padding: 0 16px;
  background: linear-gradient(135deg, var(--primary-500), var(--primary-600));
  color: #fff;
  box-shadow: 0 6px 20px rgba(58, 65, 203, 0.24);
}
.nav-back {
  width: 40px;
  font-size: 24px;
  cursor: pointer;
}
.nav-title { flex: 1; text-align: center; font-size: 18px; font-weight: 500; margin-right: 40px; }

/* 容器 */
.container { padding: 16px; }

/* 卡片 */
.card {
  background: var(--bg-secondary);
  border-radius: var(--radius-xl);
  padding: 16px;
  margin-bottom: 16px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  transition: transform 0.2s, box-shadow 0.2s;
}
@media (hover: hover) {
  .card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
  }
}

/* 用户头部 */
.user-header { display: flex; justify-content: space-between; align-items: center; }
.user-info { display: flex; align-items: center; gap: 12px; }
.avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-500), var(--primary-600));
  display: flex;
  align-items: center;
  justify-content: center;
}
.avatar-text { color: #fff; font-size: 20px; font-weight: 600; }
.user-name { font-size: 18px; font-weight: 600; }
.user-role { font-size: 12px; color: var(--text-tertiary); margin-top: 2px; }
.today-date { font-size: 12px; color: var(--text-tertiary); }

/* 统计网格 */
.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; text-align: center; padding: 8px 0; }
.stat-item { cursor: pointer; }
.stat-value { font-size: 28px; font-weight: 700; display: block; }
.stat-value.pending { color: var(--warning); }
.stat-value.repairing { color: #3b82f6; }
.stat-value.completed { color: var(--success); }
.stat-label { font-size: 12px; color: var(--text-tertiary); margin-top: 4px; display: block; }

.stats-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 16px;
  margin-top: 16px;
  border-top: 1px solid var(--border-light);
  color: var(--primary-500);
  font-size: 14px;
  cursor: pointer;
}

/* 分区标题 */
.section-title { font-size: 14px; font-weight: 600; margin-bottom: 12px; }

/* 操作网格 */
.action-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.action-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 12px;
  cursor: pointer;
  border-radius: var(--radius-lg);
  transition: background-color 0.2s, transform 0.2s;
}
.action-item:hover { background: rgba(90, 111, 242, 0.06); }
.action-item:active { background: var(--gray-50); transform: scale(0.97); }
.action-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  box-shadow: inset 0 0 0 1px rgba(90, 111, 242, 0.08);
}
.action-text { font-size: 12px; color: var(--text-secondary); text-align: center; }

/* 状态标签 */
.status-tag {
  display: inline-block;
  font-size: 12px;
  padding: 2px 8px;
  border-radius: 12px;
}
.status-pending { background: var(--warning-light); color: var(--warning-dark); }
.status-repairing { background: rgba(59,130,246,0.1); color: #3b82f6; }
.status-completed { background: var(--success-light); color: var(--success); }
.status-rejected { background: var(--gray-100); color: var(--gray-500); }

/* Tab栏 */
.tabs-bar {
  display: flex;
  background: var(--bg-secondary);
  padding: 4px;
  border-radius: var(--radius-xl);
  margin-bottom: 16px;
}
.tab-item {
  flex: 1;
  text-align: center;
  padding: 10px;
  border-radius: var(--radius-lg);
  font-size: 14px;
  color: var(--text-secondary);
  cursor: pointer;
}
.tab-item.active { background: var(--primary-500); color: #fff; font-weight: 500; }

/* 列表项 */
.list-item {
  background: var(--bg-secondary);
  border-radius: var(--radius-xl);
  padding: 16px;
  margin-bottom: 12px;
  border: 1px solid var(--border-light);
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}
.list-item:hover {
  border-color: rgba(90, 111, 242, 0.28);
  box-shadow: var(--shadow-md);
}
.list-item:active { transform: scale(0.98); }

/* 信息网格 */
.info-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.info-item { display: flex; flex-direction: column; gap: 4px; }
.info-label { font-size: 12px; color: var(--text-tertiary); }
.info-value { font-size: 14px; color: var(--text-primary); }

/* 空状态 */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 60px 20px;
  color: var(--text-tertiary);
}
.empty-icon { font-size: 48px; margin-bottom: 12px; }
.empty-text { font-size: 14px; }

/* 底部弹窗 */
.popup-mask {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 200;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
}
.popup-mask.show { opacity: 1; visibility: visible; }
.popup-container {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  background: #fff;
  border-radius: var(--radius-2xl) var(--radius-2xl) 0 0;
  z-index: 201;
  transform: translateY(100%);
  transition: transform 0.3s;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
}
.popup-container.show { transform: translateY(0); }
.popup-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  border-bottom: 1px solid var(--border-light);
}
.popup-title { font-size: 18px; font-weight: 600; }
.popup-close { font-size: 28px; color: var(--text-tertiary); cursor: pointer; line-height: 1; }
.popup-content { flex: 1; overflow-y: auto; padding: 16px; }
.popup-footer {
  display: flex;
  gap: 12px;
  padding: 16px;
  border-top: 1px solid var(--border-light);
  background: #fff;
}
.popup-footer .btn { flex: 1; }

/* Radio 组 */
.radio-group { display: flex; flex-wrap: wrap; gap: 8px; }
.radio-item {
  display: flex;
  align-items: center;
  padding: 8px 12px;
  background: var(--gray-50);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
}
.radio-item:has(input:checked) {
  background: var(--primary-50);
  border-color: var(--primary-500);
  color: var(--primary-600);
}
.radio-item input { margin-right: 6px; }
.radio-item.selected {
  background: var(--primary-50);
  border-color: var(--primary-500);
  color: var(--primary-600);
}

/* 表单 */
.form-textarea {
  width: 100%;
  min-height: 80px;
  padding: 12px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  font-size: 14px;
  resize: vertical;
  font-family: inherit;
}
.form-textarea:focus { outline: none; border-color: var(--primary-500); }

/* 车辆选择 */
.vehicle-card {
  background: var(--gray-50);
  border: 2px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 16px;
  margin-bottom: 12px;
  cursor: pointer;
  transition: all 0.2s;
}
.vehicle-card.selected { border-color: var(--primary-500); background: var(--primary-50); }
.vehicle-no-text { font-size: 18px; font-weight: 600; }
.vehicle-info { font-size: 12px; color: var(--text-tertiary); margin-top: 4px; }

/* 加载中 */
.loading-overlay {
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
}
.loading-content { text-align: center; }
.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--border-light);
  border-top-color: var(--primary-500);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto 12px;
}
@keyframes spin { to { transform: rotate(360deg); } }
.loading-text { font-size: 14px; color: var(--text-tertiary); }

/* 确认框 */
.confirm-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
}
.confirm-dialog {
  width: 300px;
  background: #fff;
  border-radius: var(--radius-2xl);
  padding: 24px;
}
.confirm-title { font-size: 18px; font-weight: 600; margin-bottom: 12px; }
.confirm-message { font-size: 14px; color: var(--text-secondary); margin-bottom: 20px; }
.confirm-buttons { display: flex; gap: 12px; }
.confirm-btn { flex: 1; height: 44px; border: none; border-radius: var(--radius-lg); font-size: 14px; cursor: pointer; }
.confirm-btn.cancel { background: var(--gray-100); color: var(--text-secondary); }
.confirm-btn.ok { background: var(--primary-500); color: #fff; }

/* Toast */
.toast {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(0,0,0,0.8);
  color: #fff;
  padding: 12px 24px;
  border-radius: var(--radius-lg);
  font-size: 14px;
  z-index: 1000;
  opacity: 0;
  transition: opacity 0.3s;
}
.toast.show { opacity: 1; }

/* 隐藏 */
.hidden { display: none !important; }

/* 页面底部留白 */
.page-with-bottom-bar { padding-bottom: 80px; }

/* 搜索栏 */
.search-bar {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
}
.search-input {
  flex: 1;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  font-size: 14px;
  background: #fff;
}
.search-input:focus { outline: none; border-color: var(--primary-500); }
.search-btn {
  height: 40px;
  padding: 0 16px;
  background: var(--primary-500);
  color: #fff;
  border: none;
  border-radius: var(--radius-lg);
  font-size: 14px;
  cursor: pointer;
}
.search-btn:hover {
  background: var(--primary-600);
}

/* 搜索提示 */
.search-tip {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  background: var(--primary-50);
  border-radius: var(--radius-lg);
  margin-bottom: 12px;
  font-size: 13px;
  color: var(--primary-600);
}
.clear-btn {
  color: var(--error);
  cursor: pointer;
  font-size: 12px;
}

/* Tab计数 */
.tab-count {
  display: block;
  font-size: 18px;
  font-weight: 600;
}
.tab-count.danger { color: var(--error); }
.tab-count.warning { color: var(--warning); }
.tab-count.success { color: var(--success); }
.tab-item.active .tab-count { color: #fff; }

/* 底部操作栏 */
.bottom-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  gap: 12px;
  padding: 12px 16px;
  background: #fff;
  border-top: 1px solid var(--border-light);
  z-index: 100;
  box-shadow: 0 -8px 18px rgba(31, 41, 55, 0.07);
}
.add-btn {
  width: 100%;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--primary-500);
  color: #fff;
  border: none;
  border-radius: var(--radius-lg);
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
}
.add-btn:disabled { background: var(--gray-300); cursor: not-allowed; }
.add-btn.success { background: var(--success); }
.add-icon { font-size: 20px; }
.add-btn:hover { background: var(--primary-600); }
.add-btn.success:hover { background: var(--success-dark); }

/* 加载更多 */
.loading-more, .no-more {
  text-align: center;
  padding: 16px;
  font-size: 13px;
  color: var(--text-tertiary);
}

/* 通用加载状态 */
.loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px;
}

/* 导航右侧 */
.nav-right {
  width: 40px;
  text-align: center;
  cursor: pointer;
  font-size: 18px;
}

/* 采购总价头部 */
.total-header {
  background: linear-gradient(135deg, var(--primary-500), #7c3aed);
  color: #fff;
  padding: 20px;
  text-align: center;
  border-radius: var(--radius-xl);
  margin-bottom: 16px;
}

.total-label {
  font-size: 13px;
  opacity: 0.9;
  margin-bottom: 4px;
}

.total-amount {
  font-size: 28px;
  font-weight: 700;
}

/* 表单卡片 */
.form-card {
  background: #fff;
  border-radius: var(--radius-xl);
  padding: 16px;
  margin-bottom: 12px;
  border: 1px solid var(--border-light);
}

.form-card .section-title {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--text-primary);
}

/* 需求汇总项 */
.summary-item {
  padding: 12px;
  background: var(--gray-50);
  border-radius: var(--radius-lg);
  margin-bottom: 8px;
  cursor: pointer;
}

.summary-item:active {
  background: var(--gray-100);
}

.part-info {
  margin-bottom: 8px;
}

.part-name {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-primary);
}

.part-name-big {
  font-size: 20px;
  font-weight: 500;
  color: var(--text-primary);
}

.part-name-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.part-model {
  font-size: 12px;
  color: var(--text-tertiary);
  margin-top: 2px;
}

.quantity-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--text-secondary);
}

.quantity-col {
  flex: 1;
  text-align: center;
}

.quantity-col:first-child {
  text-align: left;
}

.quantity-col:last-child {
  text-align: right;
}

.qty-label {
  color: var(--text-tertiary);
  font-size: 11px;
}

.qty-value {
  font-weight: 500;
  color: var(--text-primary);
}

.qty-value.success {
  color: var(--success);
}

.qty-value.primary {
  color: var(--primary-500);
}

.priority-badge {
  display: inline-block;
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 4px;
  color: #fff;
}

.priority-badge.warning {
  background: #f59e0b;
}

.priority-badge.danger {
  background: #ef4444;
}

.request-count {
  font-size: 11px;
  color: var(--text-tertiary);
  margin-top: 2px;
}

/* 已确认采购项 */
.confirmed-item, .manual-item {
  display: flex;
  align-items: center;
  padding: 12px;
  border-bottom: 1px solid var(--border-light);
}

.confirmed-item:last-child, .manual-item:last-child {
  border-bottom: none;
}

.confirmed-info, .manual-info {
  flex: 1;
}

.confirmed-name, .manual-name {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
}

.confirmed-detail, .manual-detail {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.confirmed-meta {
  font-size: 11px;
  color: var(--text-tertiary);
  margin-top: 2px;
}

.confirmed-actions, .manual-actions {
  padding-left: 12px;
}

.action-btn {
  color: var(--error);
  font-size: 13px;
  cursor: pointer;
}

/* 三列表单 */
.form-row {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
}

.form-col {
  flex: 1;
}

/* 来源申请单列表 */
.request-title {
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 8px;
  color: var(--text-secondary);
}

.request-item {
  font-size: 12px;
  color: var(--text-secondary);
  padding: 6px 0;
  border-bottom: 1px solid var(--gray-100);
}

.request-item .priority {
  margin-left: 8px;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 11px;
}

.request-item .priority.warning {
  background: var(--warning-light);
  color: var(--warning-dark);
}

.request-item .priority.danger {
  background: var(--error-light);
  color: var(--error);
}

/* 搜索结果 */
.search-results {
  margin-top: 12px;
}

.tag {
  display: inline-block;
  padding: 6px 12px;
  background: var(--gray-100);
  border-radius: var(--radius-lg);
  margin: 4px;
  cursor: pointer;
  font-size: 13px;
}

.tag:active {
  background: var(--gray-200);
}

.tag-info {
  margin-left: 6px;
  color: var(--text-tertiary);
  font-size: 12px;
}

.search-loading, .no-result {
  text-align: center;
  padding: 20px;
  color: var(--text-tertiary);
  font-size: 13px;
}

/* 已选配件卡片 */
.selected-part-card {
  background: var(--gray-50);
  padding: 12px;
  border-radius: var(--radius-lg);
  margin-top: 8px;
}

.selected-part-name {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
}

.selected-part-detail {
  font-size: 12px;
  color: var(--text-tertiary);
  margin-top: 4px;
}

.bottom-bar .btn {
  flex: 1;
}

.row-between {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.row-between-start {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.d-flex {
  display: flex;
}

.gap-8 {
  gap: 8px;
}

.flex-1 {
  flex: 1;
}

.w-80 {
  width: 80px;
}

.text-12 { font-size: 12px; }
.text-13 { font-size: 13px; }
.text-14 { font-size: 14px; }
.text-15 { font-size: 15px; }
.text-16 { font-size: 16px; }
.text-18 { font-size: 18px; }
.text-20 { font-size: 20px; }
.text-24 { font-size: 24px; }

.fw-500 { font-weight: 500; }
.fw-600 { font-weight: 600; }
.fw-700 { font-weight: 700; }

.text-primary { color: var(--text-primary); }
.text-secondary { color: var(--text-secondary); }
.text-tertiary { color: var(--text-tertiary); }
.text-brand { color: var(--primary-500); }
.text-success { color: var(--success); }
.text-warning { color: var(--warning); }
.text-error { color: var(--error); }

.lh-15 { line-height: 1.5; }
.lh-16 { line-height: 1.6; }
.text-center { text-align: center; }
.text-right { text-align: right; }

.mb-4 { margin-bottom: 4px; }
.mb-0 { margin-bottom: 0; }
.mb-8 { margin-bottom: 8px; }
.mb-12 { margin-bottom: 12px; }
.mb-16 { margin-bottom: 16px; }
.mt-4 { margin-top: 4px; }
.mt-8 { margin-top: 8px; }
.mt-12 { margin-top: 12px; }
.mt-16 { margin-top: 16px; }
.pt-16 { padding-top: 16px; }
.p-10 { padding: 10px; }
.p-20 { padding: 20px; }
.py-60 { padding-top: 60px; padding-bottom: 60px; }

.border-top {
  border-top: 1px solid var(--border-light);
}

.rounded-8 {
  border-radius: 8px;
}

.bg-gray-50 {
  background: var(--gray-50);
}

.overflow-y-auto {
  overflow-y: auto;
}

.max-h-300 {
  max-height: 300px;
}

.full-span {
  grid-column: span 2;
}

.radio-item-stack {
  margin-bottom: 8px;
}

.desc-text {
  font-size: 13px;
  color: var(--text-secondary);
}

.desc-note {
  font-size: 12px;
  color: var(--text-tertiary);
}

.id-card-info {
  margin-top: 8px;
  padding: 10px;
  background: var(--gray-50);
  border-radius: 8px;
}

.id-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 13px;
}

.id-card-label {
  color: var(--text-tertiary);
}

.id-card-value {
  font-weight: 500;
}

.loading-compact {
  padding: 10px;
}

.loading-spinner-sm {
  width: 20px;
  height: 20px;
  border-width: 2px;
}

.tab-count-muted {
  color: var(--gray-400);
}

.empty-inline-note {
  color: var(--text-tertiary);
  font-size: 13px;
}

/* 首页图标色板 */
.action-icon-danger { background: rgba(239, 68, 68, 0.12); }
.action-icon-violet { background: rgba(139, 92, 246, 0.14); }
.action-icon-blue { background: rgba(59, 130, 246, 0.12); }
.action-icon-green { background: rgba(16, 185, 129, 0.14); }
.action-icon-lime { background: rgba(34, 197, 94, 0.14); }
.action-icon-orange { background: rgba(249, 115, 22, 0.14); }
.action-icon-indigo { background: rgba(99, 102, 241, 0.14); }
.action-icon-pink { background: rgba(236, 72, 153, 0.14); }
.action-icon-amber { background: rgba(245, 158, 11, 0.14); }

.logout-panel {
  padding: 20px 0 28px;
  text-align: center;
}

:focus-visible {
  outline: 2px solid rgba(90, 111, 242, 0.42);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
