@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700;800&display=swap');

body.ref-theme {
  position: relative;
  min-height: 100vh;
  overflow-x: hidden;
  isolation: isolate;
  font-family: 'Poppins', 'PingFang SC', 'Microsoft YaHei', sans-serif !important;
  background: url('back.jpg') center center / cover no-repeat fixed !important;
  color: #fff;
}

body.ref-theme::before {
  content: '';
  position: fixed;
  inset: 0;
  background: linear-gradient(180deg, rgba(4, 9, 20, 0.28), rgba(4, 9, 20, 0.62));
  z-index: -2;
}

body.ref-theme::after {
  content: '';
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 20% 20%, rgba(255,255,255,0.08), transparent 24%),
    radial-gradient(circle at 82% 16%, rgba(255,255,255,0.06), transparent 22%),
    radial-gradient(circle at 50% 90%, rgba(255,255,255,0.05), transparent 18%);
  z-index: -1;
  pointer-events: none;
}

body.ref-theme {
  font-family: inherit;
}

/* 确保Font Awesome图标使用正确的字体 */
body.ref-theme .fas, body.ref-theme .far, body.ref-theme .fab, body.ref-theme .fal, body.ref-theme .fad {
  font-family: 'Font Awesome 6 Free' !important;
}

body.ref-theme.light-mode::before {
  background: linear-gradient(180deg, rgba(8, 14, 28, 0.22), rgba(8, 14, 28, 0.52));
}

body.ref-theme .page-wrap,
body.ref-theme .container,
body.ref-theme .confirm-page {
  position: relative;
  z-index: 1;
}

body.ref-theme .confirm-page {
  background: transparent !important;
}

body.ref-theme .back-link,
body.ref-theme .page-controls {
  z-index: 3 !important;
}

body.ref-theme .back-link,
body.ref-theme .header-card p,
body.ref-theme .login-link,
body.ref-theme .bottom-links,
body.ref-theme .sub,
body.ref-theme .qr-section .qr-text p,
body.ref-theme .check-text,
body.ref-theme .stat-card .label,
body.ref-theme .modal-field label,
body.ref-theme th,
body.ref-theme .loading,
body.ref-theme .loading-row td,
body.ref-theme .empty-row td,
body.ref-theme #admin-name {
  color: rgba(255, 255, 255, 0.86) !important;
}

body.ref-theme .header-card,
body.ref-theme .form-card,
body.ref-theme .card,
body.ref-theme .stat-card,
body.ref-theme .table-wrap,
body.ref-theme .modal,
body.ref-theme .top-bar,
body.ref-theme .qr-section,
body.ref-theme .check-label,
body.ref-theme .radio-card {
  background: rgba(255, 255, 255, 0.12) !important;
  border: 1px solid rgba(255, 255, 255, 0.20) !important;
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.26) !important;
  backdrop-filter: blur(40px);
  -webkit-backdrop-filter: blur(40px);
}

body.ref-theme .header-card,
body.ref-theme .form-card,
body.ref-theme .card,
body.ref-theme .stat-card,
body.ref-theme .modal {
  border-radius: 24px !important;
}

body.ref-theme .table-wrap,
body.ref-theme .qr-section,
body.ref-theme .check-label,
body.ref-theme .radio-card {
  border-radius: 22px !important;
}

body.ref-theme .top-bar {
  background: rgba(255, 255, 255, 0.08) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.18) !important;
}

body.ref-theme .header-card h1,
body.ref-theme .card h1,
body.ref-theme .section-title span,
body.ref-theme .radio-info h3,
body.ref-theme .success-panel h2,
body.ref-theme .logo,
body.ref-theme .check-text strong,
body.ref-theme .form-label,
body.ref-theme td,
body.ref-theme .id-val,
body.ref-theme .badge,
body.ref-theme .confirm-btn,
body.ref-theme .btn-outline,
body.ref-theme .btn-primary,
body.ref-theme .btn-danger,
body.ref-theme .btn-success,
body.ref-theme .tab.active {
  color: #fff !important;
}

body.ref-theme .header-card h1,
body.ref-theme .card h1 {
  background: none !important;
  -webkit-text-fill-color: #fff !important;
  font-size: clamp(1.8rem, 3vw, 2.8rem) !important;
  letter-spacing: 0.06em;
  font-weight: 700 !important;
  text-shadow: 0 8px 30px rgba(0, 0, 0, 0.28);
}

body.ref-theme .header-card p,
body.ref-theme .sub {
  font-size: 1rem !important;
}

body.ref-theme .input-wrap {
  border: 1px solid rgba(255, 255, 255, 0.56);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.12);
}

body.ref-theme .input-wrap:focus-within {
  border-color: rgba(255, 255, 255, 0.92);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.10), 0 0 18px rgba(255, 255, 255, 0.18);
}

body.ref-theme .form-input,
body.ref-theme .form-select {
  min-height: 58px;
  border: none !important;
  border-radius: 999px !important;
  background: transparent !important;
  color: #fff !important;
  box-shadow: none !important;
}

body.ref-theme .search-input,
body.ref-theme .modal-field select,
body.ref-theme .modal-field input {
  min-height: 56px;
  padding: 0 20px !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, 0.08) !important;
  border: 1px solid rgba(255, 255, 255, 0.40) !important;
  color: #fff !important;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.12);
}

body.ref-theme .search-input:focus,
body.ref-theme .modal-field select:focus,
body.ref-theme .modal-field input:focus {
  outline: none;
  border-color: rgba(255, 255, 255, 0.92) !important;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.10), 0 0 18px rgba(255, 255, 255, 0.18);
}

body.ref-theme .form-input::placeholder,
body.ref-theme .search-input::placeholder,
body.ref-theme .modal-field input::placeholder {
  color: rgba(255, 255, 255, 0.88) !important;
}

body.ref-theme .form-select option,
body.ref-theme .modal-field select option {
  background: #0f172a;
  color: #fff;
}

body.ref-theme .input-icon,
body.ref-theme .select-arrow,
body.ref-theme .toggle-pw {
  color: rgba(255, 255, 255, 0.92) !important;
}

body.ref-theme input[type="date"].form-input::-webkit-calendar-picker-indicator {
  filter: invert(1);
}

body.ref-theme .ctrl-btn,
body.ref-theme .ctrl {
  border-radius: 999px !important;
  border: 1px solid rgba(255, 255, 255, 0.56) !important;
  background: rgba(255, 255, 255, 0.08) !important;
  color: #fff !important;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.10);
}

body.ref-theme .ctrl-btn:hover,
body.ref-theme .ctrl:hover {
  background: rgba(255, 255, 255, 0.16) !important;
  color: #fff !important;
}

body.ref-theme .submit-btn,
body.ref-theme .send-code-btn,
body.ref-theme .confirm-btn,
body.ref-theme .btn,
body.ref-theme .tab {
  border-radius: 999px !important;
  border: 1px solid rgba(255, 255, 255, 0.65) !important;
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.18) !important;
  font-weight: 600 !important;
  transition: transform 0.2s ease, opacity 0.2s ease, background-color 0.2s ease;
}

body.ref-theme .submit-btn,
body.ref-theme .send-code-btn,
body.ref-theme .confirm-btn,
body.ref-theme .btn-primary,
body.ref-theme .tab.active {
  background: rgba(255, 255, 255, 0.96) !important;
  color: #111827 !important;
}

body.ref-theme .btn-outline,
body.ref-theme .btn-danger,
body.ref-theme .btn-success,
body.ref-theme .tab,
body.ref-theme .btn {
  background: rgba(255, 255, 255, 0.10) !important;
  color: #fff !important;
}

body.ref-theme .submit-btn:hover,
body.ref-theme .send-code-btn:hover,
body.ref-theme .confirm-btn:hover,
body.ref-theme .btn:hover,
body.ref-theme .tab:hover {
  transform: translateY(-1px);
  opacity: 0.95;
}

body.ref-theme .msg-error,
body.ref-theme .msg-success,
body.ref-theme .confirmed-badge,
body.ref-theme .toast {
  border-radius: 18px !important;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

body.ref-theme .msg-error,
body.ref-theme .toast-error {
  background: rgba(239, 68, 68, 0.16) !important;
  border: 1px solid rgba(248, 113, 113, 0.42) !important;
  color: #fff0f0 !important;
}

body.ref-theme .msg-success,
body.ref-theme .toast-success,
body.ref-theme .confirmed-badge {
  background: rgba(34, 197, 94, 0.16) !important;
  border: 1px solid rgba(74, 222, 128, 0.42) !important;
  color: #f0fff4 !important;
}

body.ref-theme .radio-card:hover,
body.ref-theme .check-label:hover,
body.ref-theme .qr-section:hover {
  border-color: rgba(255, 255, 255, 0.44) !important;
}

body.ref-theme .radio-card.selected {
  background: rgba(255, 255, 255, 0.18) !important;
  border-color: rgba(255, 255, 255, 0.72) !important;
}

body.ref-theme .radio-dot {
  border-color: rgba(255, 255, 255, 0.6) !important;
}

body.ref-theme .radio-card.selected .radio-dot::after {
  background: #fff !important;
}

body.ref-theme thead tr {
  background: rgba(255, 255, 255, 0.08) !important;
}

body.ref-theme td,
body.ref-theme th {
  border-color: rgba(255, 255, 255, 0.10) !important;
}

body.ref-theme tr:hover td {
  background: rgba(255, 255, 255, 0.06) !important;
}

body.ref-theme .badge,
body.ref-theme .badge-green,
body.ref-theme .badge-gray,
body.ref-theme .badge-blue,
body.ref-theme .badge-amber {
  background: rgba(255, 255, 255, 0.12) !important;
  border: 1px solid rgba(255, 255, 255, 0.28) !important;
}

body.ref-theme .check-icon {
  background: rgba(255, 255, 255, 0.12) !important;
  border: 1px solid rgba(255, 255, 255, 0.24);
}

body.ref-theme .check-icon i {
  color: #fff !important;
}

body.ref-theme .actions {
  gap: 14px;
}

@media (max-width: 768px) {
  body.ref-theme .header-card h1,
  body.ref-theme .card h1 {
    font-size: 1.9rem !important;
    letter-spacing: 0.04em;
  }

  body.ref-theme .top-bar {
    padding: 14px 16px !important;
  }
}
