/* ═══════════════════════════════════════════════════════════════════════
   BeautyPROF Admin v2 — Premium Design System
   Built with: Inter font, CSS Custom Properties, Glass morphism
   ═══════════════════════════════════════════════════════════════════════ */

/* ── THEME TOKENS ──────────────────────────────────────────────────── */
:root, [data-theme="dark"] {
  --a-bg: #0c0c0f;
  --a-bg-2: #111116;
  --a-bg-3: #16161c;
  --a-surface: #1a1a22;
  --a-surface-2: #1f1f28;
  --a-surface-3: #24242e;
  --a-border: rgba(255,255,255,.08);
  --a-border-2: rgba(255,255,255,.12);
  --a-text: #f0eff4;
  --a-text-2: #b8b5c4;
  --a-text-3: #7c7a8a;
  --a-primary: #7c5cff;
  --a-primary-hover: #6a48f0;
  --a-primary-soft: rgba(124,92,255,.12);
  --a-accent: #00d4aa;
  --a-accent-soft: rgba(0,212,170,.12);
  --a-warning: #ffb347;
  --a-warning-soft: rgba(255,179,71,.12);
  --a-danger: #ff5c6c;
  --a-danger-soft: rgba(255,92,108,.12);
  --a-info: #5cc8ff;
  --a-info-soft: rgba(92,200,255,.12);
  --a-gold: #c7a27c;
  --a-gold-soft: rgba(199,162,124,.12);
  --a-glass: rgba(26,26,34,.72);
  --a-glass-border: rgba(255,255,255,.06);
  --a-shadow: 0 4px 24px rgba(0,0,0,.4);
  --a-shadow-lg: 0 16px 48px rgba(0,0,0,.5);
  --a-radius: 12px;
  --a-radius-lg: 16px;
  --a-radius-xl: 20px;
  --a-radius-full: 999px;
  --a-transition: all .2s cubic-bezier(.4,0,.2,1);
  --a-sidebar-w: 260px;
  --a-header-h: 64px;
  --a-font: Inter, -apple-system, BlinkMacSystemFont, Segoe UI, sans-serif;
  --a-font-mono: JetBrains Mono, Fira Code, monospace;
}

[data-theme="light"] {
  --a-bg: #f4f4f8;
  --a-bg-2: #eeeef3;
  --a-bg-3: #e8e8ee;
  --a-surface: #ffffff;
  --a-surface-2: #f8f8fb;
  --a-surface-3: #f0f0f5;
  --a-border: rgba(0,0,0,.08);
  --a-border-2: rgba(0,0,0,.12);
  --a-text: #111116;
  --a-text-2: #555566;
  --a-text-3: #888899;
  --a-primary: #6644dd;
  --a-primary-hover: #5533cc;
  --a-primary-soft: rgba(102,68,221,.08);
  --a-accent: #00a882;
  --a-accent-soft: rgba(0,168,130,.08);
  --a-warning: #e89b30;
  --a-warning-soft: rgba(232,155,48,.08);
  --a-danger: #e04454;
  --a-danger-soft: rgba(224,68,84,.08);
  --a-info: #3daae0;
  --a-info-soft: rgba(61,170,224,.08);
  --a-gold: #a0784e;
  --a-gold-soft: rgba(160,120,78,.08);
  --a-glass: rgba(255,255,255,.82);
  --a-glass-border: rgba(0,0,0,.06);
  --a-shadow: 0 4px 24px rgba(0,0,0,.08);
  --a-shadow-lg: 0 16px 48px rgba(0,0,0,.12);
}

/* ── RESET & BASE ──────────────────────────────────────────────────── */
.admin-body * { box-sizing: border-box; }
.admin-body {
  margin: 0;
  font-family: var(--a-font);
  background: var(--a-bg);
  color: var(--a-text);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* ── LAYOUT ────────────────────────────────────────────────────────── */
.a-layout {
  display: grid;
  grid-template-columns: var(--a-sidebar-w) 1fr;
  grid-template-rows: var(--a-header-h) 1fr;
  min-height: 100vh;
}

.a-sidebar {
  grid-row: 1 / -1;
  background: var(--a-bg-2);
  border-right: 1px solid var(--a-border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  width: var(--a-sidebar-w);
  z-index: 100;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--a-border) transparent;
}

.a-header {
  grid-column: 2;
  background: var(--a-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--a-glass-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  position: sticky;
  top: 0;
  z-index: 90;
  height: var(--a-header-h);
}

.a-main {
  grid-column: 2;
  padding: 28px;
  min-width: 0;
  max-width: 1600px;
}

/* ── SIDEBAR ───────────────────────────────────────────────────────── */
.a-sidebar-brand {
  padding: 20px 20px 16px;
  border-bottom: 1px solid var(--a-border);
  display: flex;
  align-items: center;
  gap: 12px;
}
.a-sidebar-brand img {
  height: 30px;
  filter: var(--logo-filter, none);
}
.a-sidebar-brand .brand-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--a-primary);
  background: var(--a-primary-soft);
  padding: 3px 8px;
  border-radius: 6px;
}

.a-sidebar-user {
  padding: 16px 20px;
  border-bottom: 1px solid var(--a-border);
  display: flex;
  align-items: center;
  gap: 12px;
}
.a-sidebar-avatar {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--a-primary), var(--a-accent));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 14px;
  color: #fff;
  flex-shrink: 0;
}
.a-sidebar-username {
  font-weight: 600;
  font-size: 13px;
  line-height: 1.3;
}
.a-sidebar-role {
  font-size: 11px;
  color: var(--a-text-3);
}

.a-nav { padding: 12px 10px; flex: 1; }
.a-nav-group {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--a-text-3);
  padding: 16px 12px 6px;
  margin-top: 4px;
}
.a-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--a-radius);
  color: var(--a-text-2);
  text-decoration: none;
  font-weight: 500;
  font-size: 13.5px;
  transition: var(--a-transition);
  position: relative;
  margin: 2px 0;
}
.a-nav-item:hover {
  background: var(--a-primary-soft);
  color: var(--a-text);
}
.a-nav-item.active {
  background: var(--a-primary);
  color: #fff;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(124,92,255,.3);
}
.a-nav-item i { font-size: 18px; width: 20px; text-align: center; }
.a-nav-badge {
  margin-left: auto;
  background: var(--a-primary-soft);
  color: var(--a-primary);
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--a-radius-full);
  min-width: 22px;
  text-align: center;
}
.a-nav-item.active .a-nav-badge {
  background: rgba(255,255,255,.2);
  color: #fff;
}

.a-sidebar-footer {
  padding: 12px 10px;
  border-top: 1px solid var(--a-border);
}

/* ── HEADER ────────────────────────────────────────────────────────── */
.a-page-title {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -.02em;
}
.a-page-subtitle {
  font-size: 12px;
  color: var(--a-text-3);
  margin-top: 2px;
}
.a-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ── CARDS ──────────────────────────────────────────────────────────── */
.a-card {
  background: var(--a-surface);
  border: 1px solid var(--a-border);
  border-radius: var(--a-radius-lg);
  padding: 24px;
  box-shadow: var(--a-shadow);
  transition: var(--a-transition);
}
.a-card:hover { border-color: var(--a-border-2); }
.a-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  gap: 12px;
}
.a-card-title {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -.01em;
}

/* ── STAT CARDS ────────────────────────────────────────────────────── */
.a-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}
.a-stat-card {
  background: var(--a-surface);
  border: 1px solid var(--a-border);
  border-radius: var(--a-radius-lg);
  padding: 20px;
  display: flex;
  align-items: flex-start;
  gap: 14px;
  transition: var(--a-transition);
}
.a-stat-card:hover {
  border-color: var(--a-border-2);
  transform: translateY(-2px);
  box-shadow: var(--a-shadow-lg);
}
.a-stat-icon {
  width: 44px; height: 44px;
  border-radius: var(--a-radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}
.a-stat-icon.purple { background: var(--a-primary-soft); color: var(--a-primary); }
.a-stat-icon.green { background: var(--a-accent-soft); color: var(--a-accent); }
.a-stat-icon.orange { background: var(--a-warning-soft); color: var(--a-warning); }
.a-stat-icon.red { background: var(--a-danger-soft); color: var(--a-danger); }
.a-stat-icon.blue { background: var(--a-info-soft); color: var(--a-info); }
.a-stat-icon.gold { background: var(--a-gold-soft); color: var(--a-gold); }
.a-stat-value {
  font-size: 28px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -.03em;
}
.a-stat-label {
  font-size: 12px;
  color: var(--a-text-3);
  font-weight: 500;
  margin-top: 4px;
}
.a-stat-change {
  font-size: 11px;
  font-weight: 600;
  margin-top: 6px;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 6px;
  border-radius: 6px;
}
.a-stat-change.up { background: var(--a-accent-soft); color: var(--a-accent); }
.a-stat-change.down { background: var(--a-danger-soft); color: var(--a-danger); }

/* ── BUTTONS ───────────────────────────────────────────────────────── */
.a-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 16px;
  border-radius: var(--a-radius);
  font-weight: 600;
  font-size: 13px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: var(--a-transition);
  text-decoration: none;
  white-space: nowrap;
  font-family: var(--a-font);
  line-height: 1.4;
}
.a-btn i { font-size: 16px; }
.a-btn-primary {
  background: var(--a-primary);
  color: #fff;
  box-shadow: 0 2px 8px rgba(124,92,255,.3);
}
.a-btn-primary:hover {
  background: var(--a-primary-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(124,92,255,.4);
}
.a-btn-accent {
  background: var(--a-accent);
  color: #0c0c0f;
}
.a-btn-accent:hover { filter: brightness(1.1); transform: translateY(-1px); }
.a-btn-ghost {
  background: var(--a-surface-2);
  color: var(--a-text-2);
  border-color: var(--a-border);
}
.a-btn-ghost:hover {
  background: var(--a-surface-3);
  color: var(--a-text);
  border-color: var(--a-border-2);
}
.a-btn-danger {
  background: var(--a-danger-soft);
  color: var(--a-danger);
  border-color: rgba(255,92,108,.2);
}
.a-btn-danger:hover {
  background: var(--a-danger);
  color: #fff;
}
.a-btn-sm { padding: 6px 10px; font-size: 12px; border-radius: 8px; }
.a-btn-sm i { font-size: 14px; }
.a-btn-lg { padding: 12px 24px; font-size: 15px; border-radius: 14px; }
.a-btn-icon {
  width: 36px; height: 36px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: var(--a-surface-2);
  color: var(--a-text-2);
  border: 1px solid var(--a-border);
  cursor: pointer;
  transition: var(--a-transition);
  font-size: 16px;
  font-family: var(--a-font);
}
.a-btn-icon:hover {
  background: var(--a-primary-soft);
  color: var(--a-primary);
  border-color: var(--a-primary);
}

/* ── TABLES ─────────────────────────────────────────────────────────── */
.a-table-wrap {
  overflow-x: auto;
  border-radius: var(--a-radius-lg);
  border: 1px solid var(--a-border);
}
.a-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.a-table th {
  background: var(--a-surface-2);
  padding: 12px 14px;
  text-align: left;
  font-weight: 600;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--a-text-3);
  border-bottom: 1px solid var(--a-border);
  white-space: nowrap;
  position: sticky;
  top: 0;
  z-index: 2;
}
.a-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--a-border);
  vertical-align: middle;
}
.a-table tbody tr {
  transition: var(--a-transition);
}
.a-table tbody tr:hover {
  background: var(--a-primary-soft);
}
.a-table tbody tr:last-child td { border-bottom: none; }

/* ── BADGES & PILLS ────────────────────────────────────────────────── */
.a-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: var(--a-radius-full);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.a-badge-active { background: var(--a-accent-soft); color: var(--a-accent); }
.a-badge-past { background: rgba(148, 163, 184, 0.16); color: #94a3b8; border: 1px solid rgba(148, 163, 184, 0.25); }
.a-badge-archived { background: var(--a-surface-3); color: var(--a-text-3); }
.a-badge-draft { background: var(--a-warning-soft); color: var(--a-warning); }
.a-badge-cancelled { background: var(--a-danger-soft); color: var(--a-danger); }
.a-badge-private { background: var(--a-info-soft); color: var(--a-info); }
.a-badge-registered { background: var(--a-primary-soft); color: var(--a-primary); }
.a-badge-checked_in { background: var(--a-accent-soft); color: var(--a-accent); }
.a-badge-no_show { background: var(--a-warning-soft); color: var(--a-warning); }
.a-badge-test { background: var(--a-surface-3); color: var(--a-text-3); }

/* ── FORMS ──────────────────────────────────────────────────────────── */
.a-input, .a-select, .a-textarea {
  width: 100%;
  padding: 10px 14px;
  background: var(--a-bg-3);
  border: 1px solid var(--a-border);
  border-radius: var(--a-radius);
  color: var(--a-text);
  font-size: 13.5px;
  font-family: var(--a-font);
  transition: var(--a-transition);
  outline: none;
}
.a-input:focus, .a-select:focus, .a-textarea:focus {
  border-color: var(--a-primary);
  box-shadow: 0 0 0 3px var(--a-primary-soft);
}
.a-input::placeholder { color: var(--a-text-3); }
.a-textarea { min-height: 80px; resize: vertical; }
.a-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--a-text-2);
  margin-bottom: 6px;
}
.a-form-group { margin-bottom: 16px; }
.a-form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}
.a-form-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--a-border);
}

.a-search-box {
  position: relative;
  max-width: 320px;
}
.a-search-box i {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--a-text-3);
  font-size: 16px;
  pointer-events: none;
}
.a-search-box input {
  padding-left: 38px;
}

/* ── TABS ───────────────────────────────────────────────────────────── */
.a-tabs {
  display: flex;
  gap: 4px;
  padding: 4px;
  background: var(--a-bg-3);
  border-radius: var(--a-radius);
  overflow-x: auto;
  scrollbar-width: none;
}
.a-tabs::-webkit-scrollbar { display: none; }
.a-tab {
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  color: var(--a-text-3);
  cursor: pointer;
  white-space: nowrap;
  transition: var(--a-transition);
  border: none;
  background: none;
  font-family: var(--a-font);
}
.a-tab:hover { color: var(--a-text); background: var(--a-surface); }
.a-tab.active {
  background: var(--a-primary);
  color: #fff;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(124,92,255,.3);
}
.a-tab .tab-count {
  font-size: 11px;
  margin-left: 4px;
  opacity: .7;
}

/* ── TOAST ──────────────────────────────────────────────────────────── */
.a-toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}
.a-toast {
  background: var(--a-surface);
  border: 1px solid var(--a-border);
  border-radius: var(--a-radius);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: var(--a-shadow-lg);
  font-size: 13.5px;
  font-weight: 500;
  min-width: 300px;
  max-width: 420px;
  pointer-events: auto;
  animation: toastIn .3s cubic-bezier(.2,1,.3,1);
}
.a-toast.removing { animation: toastOut .25s ease forwards; }
.a-toast-success { border-left: 3px solid var(--a-accent); }
.a-toast-error { border-left: 3px solid var(--a-danger); }
.a-toast-info { border-left: 3px solid var(--a-info); }
.a-toast-warning { border-left: 3px solid var(--a-warning); }
@keyframes toastIn { from { opacity:0; transform:translateX(40px); } to { opacity:1; transform:translateX(0); } }
@keyframes toastOut { from { opacity:1; transform:translateX(0); } to { opacity:0; transform:translateX(40px); } }

/* ── MODAL ──────────────────────────────────────────────────────────── */
.a-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.6);
  backdrop-filter: blur(6px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}
.a-modal-overlay.open { display: flex; }
.a-modal {
  background: var(--a-surface);
  border: 1px solid var(--a-border);
  border-radius: var(--a-radius-xl);
  box-shadow: var(--a-shadow-lg);
  max-width: 680px;
  width: 100%;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  animation: modalIn .25s cubic-bezier(.2,1,.3,1);
}
@keyframes modalIn { from { opacity:0; transform:scale(.95) translateY(10px); } to { opacity:1; transform:scale(1) translateY(0); } }
.a-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--a-border);
}
.a-modal-title { font-size: 18px; font-weight: 700; }
.a-modal-body {
  padding: 24px;
  overflow-y: auto;
  flex: 1;
}
.a-modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding: 16px 24px;
  border-top: 1px solid var(--a-border);
}

/* ── DETAIL GRID ───────────────────────────────────────────────────── */
.a-detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.a-detail-item { display: flex; flex-direction: column; gap: 3px; }
.a-detail-item.full { grid-column: 1 / -1; }
.a-detail-key {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--a-text-3);
}
.a-detail-val {
  font-size: 13.5px;
  color: var(--a-text);
  word-break: break-word;
}
.a-detail-section {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--a-border);
}
.a-detail-section-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 14px;
  color: var(--a-primary);
}

/* ── CHARTS ─────────────────────────────────────────────────────────── */
.a-chart-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 24px;
}

/* ── TOOLBAR ───────────────────────────────────────────────────────── */
.a-toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.a-toolbar-divider {
  width: 1px;
  height: 28px;
  background: var(--a-border);
}

/* ── EMPTY STATE ───────────────────────────────────────────────────── */
.a-empty {
  text-align: center;
  padding: 48px 24px;
  color: var(--a-text-3);
}
.a-empty i { font-size: 48px; margin-bottom: 16px; display: block; opacity: .4; }
.a-empty-title { font-size: 16px; font-weight: 600; margin-bottom: 6px; color: var(--a-text-2); }
.a-empty-text { font-size: 13px; }

/* ── LOADING ───────────────────────────────────────────────────────── */
.a-spinner {
  width: 20px; height: 20px;
  border: 2px solid var(--a-border);
  border-top-color: var(--a-primary);
  border-radius: 50%;
  animation: spin .6s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.a-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 40px;
  color: var(--a-text-3);
  font-size: 13px;
}

/* ── CONFIRM DIALOG ────────────────────────────────────────────────── */
.a-confirm-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.5);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
}
.a-confirm-box {
  background: var(--a-surface);
  border: 1px solid var(--a-border);
  border-radius: var(--a-radius-xl);
  padding: 28px;
  max-width: 400px;
  width: 100%;
  text-align: center;
  box-shadow: var(--a-shadow-lg);
  animation: modalIn .2s cubic-bezier(.2,1,.3,1);
}
.a-confirm-icon {
  width: 56px; height: 56px;
  border-radius: 16px;
  margin: 0 auto 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
}
.a-confirm-title { font-size: 17px; font-weight: 700; margin-bottom: 8px; }
.a-confirm-text { font-size: 13px; color: var(--a-text-3); margin-bottom: 20px; line-height: 1.5; }
.a-confirm-actions { display: flex; gap: 10px; justify-content: center; }

/* ── MOBILE ────────────────────────────────────────────────────────── */
.a-mobile-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--a-text);
  font-size: 22px;
  cursor: pointer;
  padding: 4px;
}
.a-sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 99;
}

/* ═══════════════════════════════════════════════════════════════════════
   MOBILE-FIRST RESPONSIVE — Premium mobile admin experience
   ═══════════════════════════════════════════════════════════════════════ */

/* ── TABLET (≤1024px) ──────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .a-layout {
    grid-template-columns: 1fr;
    grid-template-rows: var(--a-header-h) 1fr;
  }
  .a-main { padding: 20px 16px; grid-column: 1; }
  .a-header { grid-column: 1; padding: 0 16px; }

  /* Sidebar: slide-over drawer */
  .a-sidebar {
    transform: translateX(-100%);
    transition: transform .3s cubic-bezier(.4,0,.2,1);
    box-shadow: none;
  }
  .a-sidebar.open {
    transform: translateX(0);
    box-shadow: 8px 0 40px rgba(0,0,0,.5);
  }
  .a-sidebar-overlay.open { display: block; }
  .a-mobile-toggle { display: flex; }

  /* Charts stack vertically */
  .a-chart-grid { grid-template-columns: 1fr; }

  /* Stats: 2 per row on tablet */
  .a-stats-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }

  /* Detail modal: full-width grid */
  .a-detail-grid { grid-template-columns: 1fr; }

  /* Tables get horizontal scroll */
  .a-table-wrap {
    -webkit-overflow-scrolling: touch;
    overflow-x: auto;
  }
  .a-table { min-width: 700px; }
}

/* ── MOBILE (≤768px) ───────────────────────────────────────────────── */
@media (max-width: 768px) {
  :root {
    --a-header-h: 56px;
    --a-radius: 10px;
    --a-radius-lg: 14px;
    --a-radius-xl: 16px;
  }

  .a-main { padding: 16px 12px; }

  /* Header: compact */
  .a-header { padding: 0 12px; gap: 8px; }
  .a-page-title { font-size: 16px; }
  .a-page-subtitle { display: none; }

  /* Mobile toggle: larger touch target */
  .a-mobile-toggle {
    width: 40px; height: 40px;
    font-size: 20px;
    margin-right: 8px;
  }

  /* Sidebar: full-screen on mobile */
  .a-sidebar { width: 280px; }
  .a-sidebar-brand { padding: 16px; }
  .a-sidebar-brand img { height: 26px; }
  .a-sidebar-user { padding: 12px 16px; }
  .a-sidebar-avatar { width: 32px; height: 32px; font-size: 13px; }
  .a-nav { padding: 8px 6px; }
  .a-nav-item { padding: 12px 12px; font-size: 14px; min-height: 44px; }
  .a-nav-item i { font-size: 20px; }

  /* Stat cards: 1 per row */
  .a-stats-grid { grid-template-columns: 1fr; gap: 10px; }
  .a-stat-card { padding: 16px; }
  .a-stat-value { font-size: 24px; }

  /* Cards */
  .a-card { padding: 16px; border-radius: var(--a-radius-lg); }
  .a-card-header { margin-bottom: 14px; flex-wrap: wrap; gap: 8px; }
  .a-card-title { font-size: 14px; }

  /* Tabs: horizontal scroll, compact */
  .a-tabs {
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    flex-wrap: nowrap;
    padding: 3px;
    gap: 2px;
  }
  .a-tabs::-webkit-scrollbar { display: none; }
  .a-tab {
    padding: 8px 12px;
    font-size: 12px;
    flex-shrink: 0;
    min-height: 36px;
  }

  /* Toolbar: stack vertically */
  .a-toolbar {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .a-search-box { max-width: 100% !important; }
  .a-toolbar .a-select { max-width: 100% !important; }

  /* Tables: mobile-optimized */
  .a-table-wrap { border-radius: var(--a-radius); }
  .a-table { min-width: 600px; font-size: 12px; }
  .a-table th { padding: 10px 10px; font-size: 10px; }
  .a-table td { padding: 10px 10px; }
  .a-truncate { max-width: 120px; }

  /* Buttons: larger touch targets */
  .a-btn { padding: 10px 16px; min-height: 40px; font-size: 13px; }
  .a-btn-lg { padding: 12px 20px; font-size: 14px; min-height: 44px; }
  .a-btn-icon { width: 40px; height: 40px; font-size: 18px; }
  .a-btn-sm { min-height: 36px; }

  /* Forms: full-width, proper spacing */
  .a-form-row { grid-template-columns: 1fr; gap: 12px; }
  .a-input, .a-select, .a-textarea {
    padding: 12px 14px;
    font-size: 16px; /* Prevents iOS zoom on focus */
    min-height: 44px;
  }
  .a-label { font-size: 13px; margin-bottom: 4px; }
  .a-form-group { margin-bottom: 14px; }
  .a-form-actions {
    flex-direction: column;
    gap: 8px;
  }
  .a-form-actions .a-btn { width: 100%; justify-content: center; }

  /* Modal: full-screen on mobile */
  .a-modal-overlay { padding: 0; align-items: flex-end; }
  .a-modal {
    max-width: 100%;
    max-height: 92vh;
    border-radius: var(--a-radius-xl) var(--a-radius-xl) 0 0;
    animation: modalSlideUp .3s cubic-bezier(.2,1,.3,1);
  }
  @keyframes modalSlideUp {
    from { opacity: 0; transform: translateY(100%); }
    to { opacity: 1; transform: translateY(0); }
  }
  .a-modal-header { padding: 16px 18px; }
  .a-modal-title { font-size: 16px; }
  .a-modal-body { padding: 16px 18px; }
  .a-modal-footer {
    padding: 12px 18px;
    flex-direction: column;
    gap: 8px;
  }
  .a-modal-footer .a-btn,
  .a-modal-footer .a-select { width: 100%; }
  .a-modal-footer .a-select { min-height: 44px; }

  /* Detail grid: single column */
  .a-detail-grid { grid-template-columns: 1fr; gap: 10px; }
  .a-detail-key { font-size: 10px; }
  .a-detail-val { font-size: 13px; }
  .a-detail-section { margin-top: 16px; padding-top: 12px; }

  /* Toast: full-width on mobile */
  .a-toast-container {
    top: auto;
    bottom: 12px;
    right: 12px;
    left: 12px;
  }
  .a-toast {
    min-width: 0;
    max-width: 100%;
    font-size: 13px;
    padding: 12px 16px;
  }

  /* Confirm: centered with padding */
  .a-confirm-box {
    margin: 0 16px;
    padding: 24px 20px;
  }
  .a-confirm-actions {
    flex-direction: column;
    gap: 8px;
  }
  .a-confirm-actions .a-btn { width: 100%; justify-content: center; }

  /* Empty state */
  .a-empty { padding: 32px 16px; }
  .a-empty i { font-size: 40px; }

  /* Badges */
  .a-badge { font-size: 10px; padding: 3px 8px; }

  /* Utility */
  .a-mt-24 { margin-top: 16px; }
  .a-mb-24 { margin-bottom: 16px; }
}

/* ── SMALL PHONE (≤400px) ──────────────────────────────────────────── */
@media (max-width: 400px) {
  .a-main { padding: 12px 8px; }
  .a-header { padding: 0 8px; }
  .a-page-title { font-size: 14px; }
  .a-sidebar { width: 260px; }
  .a-stat-card { padding: 14px; gap: 10px; }
  .a-stat-icon { width: 38px; height: 38px; font-size: 18px; }
  .a-stat-value { font-size: 22px; }
  .a-stat-label { font-size: 11px; }
  .a-card { padding: 14px; }
  .a-card-title { font-size: 13px; }
  .a-table { min-width: 500px; }
  .a-tab { padding: 6px 10px; font-size: 11px; }
  .a-nav-item { font-size: 13px; padding: 10px; }
}

/* ── TOUCH OPTIMIZATIONS ───────────────────────────────────────────── */
@media (pointer: coarse) {
  /* Ensure all interactive elements are at least 44px */
  .a-btn, .a-btn-icon, .a-tab, .a-nav-item, .a-input, .a-select {
    min-height: 44px;
  }
  .a-btn-icon { width: 44px; height: 44px; }
  
  /* Disable hover effects on touch */
  .a-stat-card:hover { transform: none; box-shadow: var(--a-shadow); }
  .a-btn-primary:hover { transform: none; }
  .a-table tbody tr:hover { background: transparent; }
  
  /* Active states for touch instead */
  .a-btn:active { opacity: .8; transform: scale(.97); }
  .a-btn-icon:active { opacity: .7; }
  .a-nav-item:active { opacity: .7; }
  .a-table tbody tr:active { background: var(--a-primary-soft); }
}

/* ── LANDSCAPE PHONE ───────────────────────────────────────────────── */
@media (max-height: 500px) and (orientation: landscape) {
  :root { --a-header-h: 48px; }
  .a-main { padding: 12px; }
  .a-stats-grid { grid-template-columns: repeat(3, 1fr); }
  .a-sidebar { width: 240px; }
  .a-modal { max-height: 95vh; }
}

/* ── SAFE AREA (notch phones) ──────────────────────────────────────── */
@supports (padding: env(safe-area-inset-bottom)) {
  .a-sidebar {
    padding-bottom: env(safe-area-inset-bottom);
  }
  .a-modal {
    padding-bottom: env(safe-area-inset-bottom);
  }
  .a-toast-container {
    bottom: calc(12px + env(safe-area-inset-bottom));
  }
}

/* ── PREVENT OVERFLOW ──────────────────────────────────────────────── */
.admin-body {
  overflow-x: hidden;
  min-width: 0;
}
.a-layout { min-width: 0; }
.a-main { min-width: 0; overflow-x: hidden; }
.a-header { min-width: 0; }
.a-card { min-width: 0; overflow: hidden; }
.a-table-wrap { min-width: 0; }

/* ── SCROLLBAR ─────────────────────────────────────────────────────── */
.admin-body ::-webkit-scrollbar { width: 6px; height: 6px; }
.admin-body ::-webkit-scrollbar-track { background: transparent; }
.admin-body ::-webkit-scrollbar-thumb { background: var(--a-border-2); border-radius: 10px; }
.admin-body ::-webkit-scrollbar-thumb:hover { background: var(--a-primary); }

/* ── UTILITY ───────────────────────────────────────────────────────── */
.a-flex { display: flex; }
.a-items-center { align-items: center; }
.a-justify-between { justify-content: space-between; }
.a-gap-8 { gap: 8px; }
.a-gap-12 { gap: 12px; }
.a-gap-16 { gap: 16px; }
.a-mt-16 { margin-top: 16px; }
.a-mt-24 { margin-top: 24px; }
.a-mb-16 { margin-bottom: 16px; }
.a-mb-24 { margin-bottom: 24px; }
.a-text-muted { color: var(--a-text-3); }
.a-text-sm { font-size: 12px; }
.a-font-mono { font-family: var(--a-font-mono); font-size: 12px; }
.a-truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 200px; }
.a-code { background: var(--a-bg-3); padding: 2px 6px; border-radius: 4px; font-family: var(--a-font-mono); font-size: 11.5px; }


/* Sidebar close button — visible only on mobile */
.a-sidebar .a-mobile-toggle { display: none !important; }
@media (max-width: 1024px) {
  .a-sidebar .a-mobile-toggle { display: flex !important; }
}



/* ── TABLE CARD & PAGINATION FIX ────────────────────────────────────── */
.a-card > .a-table-wrap {
  border: none !important;
  border-radius: 0 !important;
}

.a-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  border-top: 1px solid var(--a-border);
  background: var(--a-surface);
  flex-wrap: wrap;
  gap: 12px;
}

.a-pagination-info {
  font-size: 13px;
  color: var(--a-text-muted);
}

.a-pagination-btns {
  display: flex;
  align-items: center;
  gap: 4px;
}

.a-page-btn {
  min-width: 32px;
  height: 32px;
  padding: 0 8px;
  border-radius: var(--a-radius);
  border: 1px solid var(--a-border);
  background: var(--a-surface-2);
  color: var(--a-text-main);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: var(--a-transition);
}

.a-page-btn:hover {
  background: var(--a-primary-soft);
  color: var(--a-primary);
  border-color: var(--a-primary);
}

.a-page-btn.active {
  background: var(--a-primary);
  color: #ffffff;
  border-color: var(--a-primary);
}

.a-page-btn:disabled {
  opacity: .4;
  cursor: not-allowed;
  background: var(--a-surface-2);
  color: var(--a-text-muted);
  border-color: var(--a-border);
}

/* ── DASHBOARD GRID & LEADERBOARD ───────────────────────────────────── */
@media (max-width: 1024px) {
  .dash-main-grid {
    grid-template-columns: 1fr !important;
  }
}

.leaderboard-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-bottom: 1px solid var(--a-border);
  gap: 12px;
}
.leaderboard-row:last-child { border-bottom: none; }
.leaderboard-rank {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--a-surface-2);
  color: var(--a-text-muted);
  font-weight: 700;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.leaderboard-rank.top-1 { background: rgba(255, 179, 71, 0.15); color: #ffb347; }
.leaderboard-rank.top-2 { background: rgba(167, 139, 250, 0.15); color: #a78bfa; }
.leaderboard-rank.top-3 { background: rgba(92, 200, 255, 0.15); color: #5cc8ff; }

.leaderboard-bar-wrap {
  flex: 1;
  min-width: 0;
}
.leaderboard-bar {
  height: 6px;
  background: var(--a-border);
  border-radius: 3px;
  overflow: hidden;
  margin-top: 4px;
}
.leaderboard-fill {
  height: 100%;
  background: var(--a-primary);
  border-radius: 3px;
}


/* ── CUSTOM SELECT ENGINE (DARK SAAS DROP-DOWN) ──────────────────────── */
.a-custom-select-wrap {
  position: relative;
  display: inline-block;
  width: 100%;
  min-width: 0;
}
.a-custom-select-trigger {
  width: 100%;
  padding: 10px 14px;
  background: var(--a-bg-3);
  border: 1px solid var(--a-border);
  border-radius: var(--a-radius);
  color: var(--a-text);
  font-size: 13.5px;
  font-family: var(--a-font);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  cursor: pointer;
  outline: none;
  transition: var(--a-transition);
  text-align: left;
  min-height: 40px;
}
.a-custom-select-trigger:hover,
.a-custom-select-wrap.open .a-custom-select-trigger {
  border-color: var(--a-primary);
  background: var(--a-surface-2);
}
.a-custom-select-trigger .a-cs-label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
}
.a-custom-select-trigger i {
  font-size: 16px;
  color: var(--a-text-3);
  transition: transform .2s ease;
  flex-shrink: 0;
}
.a-custom-select-wrap.open .a-custom-select-trigger i {
  transform: rotate(180deg);
  color: var(--a-primary);
}

.a-custom-select-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  min-width: 100%;
  width: max-content;
  max-width: 460px;
  max-height: 280px;
  overflow-y: auto;
  background: var(--a-surface);
  border: 1px solid var(--a-border-2);
  border-radius: var(--a-radius-lg);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.5), 0 4px 12px rgba(0, 0, 0, 0.3);
  z-index: 1200;
  padding: 6px;
  display: none;
  animation: csFadeIn .18s cubic-bezier(.2, 1, .3, 1);
}
@keyframes csFadeIn {
  from { opacity: 0; transform: translateY(-6px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.a-custom-select-wrap.open .a-custom-select-dropdown {
  display: block;
}

.a-custom-select-item {
  padding: 10px 14px;
  font-size: 13px;
  color: var(--a-text-2);
  border-radius: var(--a-radius);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  transition: all .12s ease;
  line-height: 1.35;
  margin-bottom: 2px;
}
.a-custom-select-item:last-child { margin-bottom: 0; }
.a-custom-select-item:hover {
  background: var(--a-primary-soft);
  color: var(--a-primary);
}
.a-custom-select-item.selected {
  background: var(--a-primary);
  color: #ffffff;
  font-weight: 600;
}
.a-custom-select-item .cs-check {
  font-size: 14px;
  opacity: 0;
}
.a-custom-select-item.selected .cs-check {
  opacity: 1;
}

/* Custom Scrollbar inside Custom Select Menu */
.a-custom-select-dropdown::-webkit-scrollbar { width: 5px; }
.a-custom-select-dropdown::-webkit-scrollbar-track { background: transparent; }
.a-custom-select-dropdown::-webkit-scrollbar-thumb { background: var(--a-border-2); border-radius: 4px; }


/* ── LARGE BRIGHT REGISTRATIONS BADGE ───────────────────────────────── */
.a-badge-regs {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 10px;
  background: rgba(124, 92, 255, 0.25);
  color: #c4b5fd;
  border: 1px solid rgba(167, 139, 250, 0.6);
  font-size: 16px;
  font-weight: 800;
  text-decoration: none;
  transition: var(--a-transition);
  box-shadow: 0 2px 12px rgba(124, 92, 255, 0.25);
}
.a-badge-regs:hover {
  background: var(--a-primary);
  color: #ffffff;
  border-color: var(--a-primary);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(124, 92, 255, 0.5);
}
.a-badge-regs i {
  font-size: 17px;
  color: #a78bfa;
}
.a-badge-regs:hover i {
  color: #ffffff;
}


/* ── CANCELLED & ARCHIVED ROW STYLING ──────────────────────────────── */
.a-table tr.a-tr-cancelled {
  background: rgba(220, 38, 38, 0.14) !important;
}
.a-table tr.a-tr-cancelled:hover {
  background: rgba(220, 38, 38, 0.22) !important;
}

.a-table tr.a-tr-archived {
  background: rgba(148, 163, 184, 0.06) !important;
  opacity: 0.55;
}

.a-table tr.a-tr-past {
  opacity: 0.65;
}


/* ── SORTABLE TABLE HEADERS ─────────────────────────────────────────── */
th.a-sortable {
  cursor: pointer;
  user-select: none;
  transition: var(--a-transition);
}
th.a-sortable:hover {
  color: var(--a-primary);
  background: var(--a-surface-3);
}
th.a-sortable i {
  font-size: 13px;
  margin-left: 4px;
  opacity: .5;
  transition: transform .2s ease, opacity .2s ease;
}
th.a-sortable:hover i,
th.a-sortable.asc i,
th.a-sortable.desc i {
  opacity: 1;
  color: var(--a-primary);
}
th.a-sortable.asc i {
  transform: rotate(180deg);
}


/* Dropdown opening upwards when near screen bottom */
.a-custom-select-wrap.drop-up .a-custom-select-dropdown {
  top: auto !important;
  bottom: calc(100% + 6px) !important;
  animation: csFadeUp .18s cubic-bezier(.2, 1, .3, 1) !important;
}
@keyframes csFadeUp {
  from { opacity: 0; transform: translateY(6px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* ── TOGGLE CHIP (filter pill) ─────────────────────────────────────── */
.a-toggle-chip { display:inline-flex; align-items:center; gap:7px; padding:8px 14px; border-radius:999px;
  border:1px solid var(--a-border); background:var(--a-surface-2, var(--a-surface)); color:var(--a-text-2);
  font-size:12.5px; font-weight:600; cursor:pointer; white-space:nowrap; user-select:none;
  transition:all .18s ease; line-height:1; }
.a-toggle-chip i { font-size:15px; opacity:.75; transition:opacity .18s ease; }
.a-toggle-chip input[type="checkbox"] { position:absolute; opacity:0; width:0; height:0; margin:0; pointer-events:none; }
.a-toggle-chip:hover { border-color:var(--a-primary); color:var(--a-text-main); }
.a-toggle-chip:hover i { opacity:1; }
.a-toggle-chip.active, .a-toggle-chip:has(input:checked) { background:var(--a-primary); border-color:var(--a-primary); color:#fff;
  box-shadow:0 4px 14px rgba(124,92,255,.35); }
.a-toggle-chip.active i, .a-toggle-chip:has(input:checked) i { opacity:1; }
.a-toggle-chip.active::after, .a-toggle-chip:has(input:checked)::after { content:'✓'; margin-left:2px; font-size:11px; font-weight:800; }
.a-toggle-chip input:focus-visible + i { outline:2px solid var(--a-primary); outline-offset:2px; border-radius:4px; }

/* ── CHIP ROW: быстрые фильтры, всегда одна строка ─────────────────── */
.a-chip-row { display:flex; align-items:center; gap:8px; flex:0 0 auto; flex-wrap:nowrap; }

/* ── CLICKABLE STAT CARD ───────────────────────────────────────────── */
.a-stat-click { cursor:pointer; transition:transform .15s ease, border-color .15s ease, box-shadow .15s ease; }
.a-stat-click:hover { transform:translateY(-2px); border-color:var(--a-primary); box-shadow:0 6px 18px rgba(124,92,255,.25); }
.a-stat-click.a-stat-active { border-color:var(--a-primary); background:var(--a-primary-soft); box-shadow:0 0 0 1px var(--a-primary) inset; }
.a-stat-click.a-stat-active .a-stat-value { color:var(--a-primary); }

/* ── ROW ACTION COLORS (различимые цвета кнопок) ───────────────────── */
.a-btn-icon.act-view    { color:#5cc8ff; }               /* глаз — голубой */
.a-btn-icon.act-view:hover    { background:rgba(92,200,255,.14); border-color:#5cc8ff; }
.a-btn-icon.act-checkin { color:#00d4aa; }               /* чекин — бирюзовый */
.a-btn-icon.act-checkin:hover { background:rgba(0,212,170,.14); border-color:#00d4aa; }
.a-btn-icon.act-test    { color:#b8b5c4; }               /* колба неактивна — серый */
.a-btn-icon.act-test:hover    { color:#ffb347; background:rgba(255,179,71,.14); border-color:#ffb347; }
.a-btn-icon.act-test-on { color:#ffb347; background:rgba(255,179,71,.16); border-color:#ffb347; } /* тест активен — янтарный */
.a-btn-icon.act-bitrix  { color:#a78bfa; }               /* Bitrix — светло-фиолетовый */
.a-btn-icon.act-bitrix:hover  { background:rgba(167,139,250,.14); border-color:#a78bfa; }

.a-btn-icon.act-del  { color:#ff5c6c; }               /* удалить — красный */
.a-btn-icon.act-del:hover  { background:rgba(255,92,108,.14); border-color:#ff5c6c; }


/* ═══════════════════════════════════════════════════════════════════════
   PREMIUM LUXURY UI & MICRO-INTERACTIONS
   ═══════════════════════════════════════════════════════════════════════ */

/* ── KBD Shortcut Badges ───────────────────────────────────────────── */
.a-kbd {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px 6px;
  font-family: var(--a-font-mono, monospace);
  font-size: 11px;
  font-weight: 700;
  color: var(--a-text-2);
  background: var(--a-surface-3, rgba(255, 255, 255, 0.08));
  border: 1px solid var(--a-border);
  border-bottom: 2px solid var(--a-border);
  border-radius: 6px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
  line-height: 1;
}

/* ── Global Header Search & Shortcut Hint ──────────────────────────── */
.a-header-shortcut-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--a-surface-2, rgba(255, 255, 255, 0.04));
  border: 1px solid var(--a-border);
  color: var(--a-text-2);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s ease;
}
.a-header-shortcut-btn:hover {
  background: var(--a-surface-3, rgba(255, 255, 255, 0.08));
  border-color: var(--a-primary);
  color: var(--a-text-main);
  transform: translateY(-1px);
}

/* ── Detail Modal Contact & Action Bar ─────────────────────────────── */
.a-contact-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 14px 18px;
  background: var(--a-surface-2, rgba(255, 255, 255, 0.03));
  border: 1px solid var(--a-border);
  border-radius: 12px;
  margin-bottom: 20px;
}
.a-contact-phone {
  font-family: monospace;
  font-size: 16px;
  font-weight: 800;
  color: var(--a-text-main);
  letter-spacing: .02em;
}
.a-btn-wa {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 8px;
  background: rgba(37, 211, 102, 0.15);
  color: #25d366;
  border: 1px solid rgba(37, 211, 102, 0.4);
  font-size: 12.5px;
  font-weight: 700;
  text-decoration: none;
  transition: all .2s ease;
}
.a-btn-wa:hover {
  background: #25d366;
  color: #ffffff;
  border-color: #25d366;
  box-shadow: 0 4px 14px rgba(37, 211, 102, 0.35);
  transform: translateY(-1px);
}

/* ── Status Switcher Pills in Detail Modal ─────────────────────────── */
.a-status-pills {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  align-items: center;
}
.a-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid var(--a-border);
  background: var(--a-surface-2);
  color: var(--a-text-2);
  transition: all .18s ease;
}
.a-status-pill:hover {
  transform: translateY(-1px);
  border-color: currentColor;
}
.a-status-pill.active {
  color: #ffffff !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}
.a-status-pill[data-st="registered"].active { background: var(--a-primary); border-color: var(--a-primary); }
.a-status-pill[data-st="checked_in"].active { background: var(--a-success, #00d4aa); border-color: var(--a-success, #00d4aa); }
.a-status-pill[data-st="no_show"].active    { background: var(--a-warning, #ffb347); border-color: var(--a-warning, #ffb347); }
.a-status-pill[data-st="test"].active       { background: var(--a-text-3, #94a3b8); border-color: var(--a-text-3, #94a3b8); }
.a-status-pill[data-st="cancelled"].active  { background: var(--a-danger, #ff5c6c); border-color: var(--a-danger, #ff5c6c); }

/* ── Copyable Chip Pill ────────────────────────────────────────────── */
.a-copy-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: var(--a-surface-2, rgba(255, 255, 255, 0.04));
  border: 1px solid var(--a-border);
  border-radius: 6px;
  font-size: 12px;
  color: var(--a-text-main);
  cursor: pointer;
  transition: all .15s ease;
}
.a-copy-chip:hover {
  border-color: var(--a-primary);
  background: var(--a-primary-soft);
  color: var(--a-primary);
}
.a-copy-chip i { font-size: 13px; opacity: .7; }

/* ── Quick Date Presets ────────────────────────────────────────────── */
.a-date-presets {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 8px;
}
.a-date-preset-btn {
  padding: 4px 10px;
  font-size: 11.5px;
  font-weight: 600;
  border-radius: 6px;
  background: var(--a-surface-2);
  border: 1px solid var(--a-border);
  color: var(--a-text-2);
  cursor: pointer;
  transition: all .15s ease;
}
.a-date-preset-btn:hover, .a-date-preset-btn.active {
  background: var(--a-primary-soft);
  border-color: var(--a-primary);
  color: var(--a-primary);
}

/* ── Sticky Table Header with Blur ─────────────────────────────────── */
.a-table thead th {
  position: sticky;
  top: 0;
  background: var(--a-surface, #181824);
  z-index: 5;
  box-shadow: 0 1px 0 var(--a-border);
}

/* ── Live Pulse Indicator ──────────────────────────────────────────── */
.a-live-indicator {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  color: var(--a-success, #00d4aa);
}
.a-pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--a-success, #00d4aa);
  box-shadow: 0 0 0 rgba(0, 212, 170, 0.6);
  animation: aPulse 2s infinite;
}
@keyframes aPulse {
  0% { box-shadow: 0 0 0 0 rgba(0, 212, 170, 0.7); }
  70% { box-shadow: 0 0 0 8px rgba(0, 212, 170, 0); }
  100% { box-shadow: 0 0 0 0 rgba(0, 212, 170, 0); }
}

/* ── Glassmorphism Modals ──────────────────────────────────────────── */
.a-modal-overlay {
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  background: rgba(10, 10, 16, 0.75) !important;
}
.a-modal {
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.6), 0 0 0 1px var(--a-border) !important;
  animation: aModalIn .22s cubic-bezier(.16, 1, .3, 1) !important;
}
@keyframes aModalIn {
  from { opacity: 0; transform: scale(.95) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}
