/* ===== Filter Bar ===== */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  padding: 16px;
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  margin-bottom: 20px;
}
.filter-bar .input,
.filter-bar .select { min-width: 140px; }
.filter-actions { display: flex; gap: 8px; margin-left: auto; }

/* ===== Tabs ===== */
.tabs {
  display: flex;
  border-bottom: 2px solid #e2e8f0;
  margin-bottom: 24px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.tab {
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 500;
  color: #64748b;
  border: none;
  background: none;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  white-space: nowrap;
  transition: color 0.2s, border-color 0.2s;
}
.tab:hover { color: #6B46C1; }
.tab.active { color: #6B46C1; border-bottom-color: #6B46C1; }

/* ===== Sub Nav (Settings secondary nav) ===== */
.settings-layout {
  display: flex;
  gap: 24px;
  min-height: calc(100vh - 180px);
}
.settings-nav {
  width: 200px;
  flex-shrink: 0;
  background: white;
  border-radius: 12px;
  padding: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  height: fit-content;
}
.settings-nav-item {
  display: block;
  width: 100%;
  padding: 10px 16px;
  border: none;
  background: none;
  text-align: left;
  font-size: 14px;
  color: #64748b;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.settings-nav-item:hover { background: #f8fafc; color: #1e293b; }
.settings-nav-item.active { background: #f3f0ff; color: #6B46C1; font-weight: 600; }
.settings-content { flex: 1; min-width: 0; }

/* ===== Toggle Switch ===== */
.toggle {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
}
.toggle input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: #cbd5e1;
  border-radius: 24px;
  transition: background 0.3s;
}
.toggle-slider::before {
  content: '';
  position: absolute;
  width: 18px;
  height: 18px;
  left: 3px;
  bottom: 3px;
  background: white;
  border-radius: 50%;
  transition: transform 0.3s;
}
.toggle input:checked + .toggle-slider { background: #6B46C1; }
.toggle input:checked + .toggle-slider::before { transform: translateX(20px); }

/* ===== Breadcrumbs ===== */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: #64748b;
  margin-bottom: 16px;
}
.breadcrumb a, .breadcrumb-back {
  color: #6B46C1;
  cursor: pointer;
  text-decoration: none;
}
.breadcrumb a:hover, .breadcrumb-back:hover { text-decoration: underline; }
.breadcrumb-separator { color: #cbd5e1; }

/* ===== Loading Spinner ===== */
.loading-spinner {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 0;
}
.spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #e2e8f0;
  border-top-color: #6B46C1;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ===== Empty State ===== */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: #94a3b8;
}
.empty-state h3 { color: #64748b; margin-bottom: 8px; }
.empty-state p { font-size: 14px; }

/* ===== Avatar ===== */
.avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 16px;
  color: white;
  background: #6B46C1;
}
.avatar-sm { width: 32px; height: 32px; font-size: 13px; }
.avatar-lg { width: 56px; height: 56px; font-size: 22px; }

/* ===== Color Picker ===== */
.color-picker-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.color-swatch {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  cursor: pointer;
  border: 2px solid transparent;
  transition: border-color 0.2s, transform 0.2s;
}
.color-swatch:hover { transform: scale(1.1); }
.color-swatch.selected { border-color: #1e293b; }

/* ===== Scope/Branch Pills ===== */
.pill-group { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.pill {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}
.pill-scope { background: #f3f0ff; color: #6B46C1; }
.pill-branch { background: #ecfdf5; color: #065f46; }
.pill-role { background: #eff6ff; color: #1d4ed8; }

/* ===== Dropdown Menu ===== */
.dropdown-menu {
  position: absolute;
  top: 100%;
  right: 0;
  min-width: 160px;
  background: white;
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.12);
  z-index: 1000;
  padding: 6px;
  margin-top: 4px;
}
.dropdown-item {
  display: block;
  width: 100%;
  padding: 8px 14px;
  border: none;
  background: none;
  text-align: left;
  font-size: 14px;
  color: #334155;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.15s;
}
.dropdown-item:hover { background: #f8fafc; }

/* ===== Date Picker Wrapper ===== */
.date-input {
  display: flex;
  align-items: center;
  gap: 4px;
}
.date-input input[type="date"],
.date-input input[type="datetime-local"] {
  padding: 8px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-size: 13px;
  color: #334155;
  background: white;
}

/* ===== Scheduler Redesign ===== */
.scheduler-container {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Top toolbar */
.scheduler-filters {
  display: flex;
  align-items: center;
  gap: 12px;
  background: white;
  padding: 12px 18px;
  border-radius: 12px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07);
  flex-wrap: wrap;
}
.scheduler-filters label {
  font-size: 12px;
  font-weight: 700;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  white-space: nowrap;
}
.scheduler-filters .input {
  min-width: 180px;
}
.scheduler-actions {
  display: flex;
  gap: 8px;
  margin-left: auto;
}

/* Calendar card */
.scheduler-week {
  background: white;
  border-radius: 12px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07);
  overflow: hidden;
  border: 1px solid #e2e8f0;
}

/* Day header row — 7-column grid */
.week-date-row {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  background: #f8fafc;
  border-bottom: 2px solid #e2e8f0;
}
.day-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 4px 10px;
  font-size: 11px;
  font-weight: 700;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  border-right: 1px solid #e2e8f0;
  cursor: default;
}
.day-header:last-child { border-right: none; }
.day-header .date {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: 700;
  color: #1e293b;
  margin-top: 4px;
  border-radius: 50%;
}
.day-header.today { color: #6366f1; }
.day-header.today .date {
  background: #6366f1;
  color: white;
  box-shadow: 0 2px 8px rgba(99,102,241,0.35);
}

/* Day grid — 7-column grid */
.week-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
}
.day-column {
  border-right: 1px solid #f1f5f9;
  padding: 8px 6px;
  min-height: 440px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.day-column:last-child { border-right: none; }
.day-shifts {
  display: flex;
  flex-direction: column;
  gap: 5px;
  flex: 1;
}

/* Shift blocks */
.shift-block {
  border-radius: 7px;
  padding: 7px 9px;
  cursor: pointer;
  transition: transform 0.12s, box-shadow 0.12s;
  border-left: 3px solid rgba(0,0,0,0.18);
}
.shift-block:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(0,0,0,0.18);
}
.shift-name {
  font-size: 12px;
  font-weight: 700;
  color: white;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.shift-time {
  font-size: 10px;
  color: rgba(255,255,255,0.82);
  margin-top: 2px;
}

/* Add shift button */
.btn-add-shift {
  width: 100%;
  padding: 7px 4px;
  border: 1.5px dashed #cbd5e1;
  background: transparent;
  border-radius: 7px;
  color: #cbd5e1;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  transition: all 0.15s;
  margin-top: auto;
  font-family: inherit;
}
.btn-add-shift:hover {
  border-color: #6366f1;
  color: #6366f1;
  background: rgba(99,102,241,0.06);
}

/* Staff legend strip */
.scheduler-staff-panel {
  background: white;
  border-radius: 12px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07);
  padding: 14px 18px;
  border: 1px solid #e2e8f0;
}
.scheduler-staff-panel h3 {
  font-size: 11px;
  font-weight: 700;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin: 0 0 10px;
}
#staff-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.staff-item {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 20px;
  padding: 4px 12px 4px 8px;
}
.staff-color {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}
.staff-name { font-size: 12px; font-weight: 600; color: #334155; }
.shift-count { font-size: 11px; color: #94a3b8; margin-left: 2px; }
.staff-clocked-in { border-color: #10b981; background: #ecfdf5; }
.clock-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #10b981; flex-shrink: 0;
  animation: clock-pulse 1.5s infinite;
}
@keyframes clock-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}
.staff-panel-section { margin-bottom: 10px; }
.staff-panel-section:last-child { margin-bottom: 0; }
.staff-panel-heading {
  font-size: 10px; font-weight: 700; color: #64748b;
  text-transform: uppercase; letter-spacing: 0.06em;
  margin: 0 0 6px; padding: 0;
}
#staff-list { flex-direction: column; }

/* Scheduler page header controls */
.scheduler-header-controls { display: flex; align-items: center; gap: 8px; }

/* ===== Week Stats Bar ===== */
.sched-stats {
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
  background: white; border-radius: 10px; padding: 10px 18px;
  border: 1px solid #e2e8f0; margin-bottom: 14px;
}
.sched-stat-label { font-size: 13px; font-weight: 700; color: #1e293b; margin-right: auto; }
.sched-stat { font-size: 12px; color: #64748b; }
.sched-stat strong { color: #1e293b; font-size: 14px; }
.sched-stat-live strong { color: #10b981; }

/* ===== Shift Block Enhancements ===== */
.shift-block-top { display: flex; justify-content: space-between; align-items: center; }
.shift-att-dot {
  width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0;
}
.shift-att-dot.live { background: #22c55e; animation: clock-pulse 1.5s infinite; }
.shift-att-dot.done { background: rgba(255,255,255,0.6); }
.shift-branch-label { font-size: 9px; opacity: 0.75; margin-top: 2px; }
.shift-note-label { font-size: 9px; opacity: 0.65; font-style: italic; margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ===== Weekly Hours Summary Table ===== */
.scheduler-hours-panel {
  background: white; border-radius: 12px; padding: 14px 18px;
  border: 1px solid #e2e8f0; box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}
.scheduler-hours-panel h3 {
  font-size: 11px; font-weight: 700; color: #94a3b8;
  text-transform: uppercase; letter-spacing: 0.07em; margin: 0 0 10px;
}
.hours-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.hours-table th {
  font-size: 10px; text-transform: uppercase; letter-spacing: 0.05em;
  color: #94a3b8; padding: 6px 8px; border-bottom: 2px solid #e2e8f0; text-align: center;
}
.hours-table th:first-child { text-align: left; }
.hours-table td { padding: 7px 8px; border-bottom: 1px solid #f1f5f9; text-align: center; }
.hours-table td:first-child { text-align: left; }
.hours-name { display: flex; align-items: center; gap: 6px; font-weight: 600; color: #334155; white-space: nowrap; }
.staff-color-sm { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.hours-cell.empty { color: #cbd5e1; }
.hours-total { font-weight: 700; color: #1e293b; }
.hours-actual { font-weight: 600; color: #3b82f6; }
.hours-variance { font-weight: 600; }
.hours-variance.over { color: #10b981; }
.hours-variance.under { color: #ef4444; }

/* ===== Employee Contact Directory ===== */
.scheduler-contacts-panel {
  background: white; border-radius: 12px; padding: 14px 18px;
  border: 1px solid #e2e8f0; box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}
.scheduler-contacts-panel h3 {
  font-size: 11px; font-weight: 700; color: #94a3b8;
  text-transform: uppercase; letter-spacing: 0.07em; margin: 0 0 12px;
}
.contacts-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px;
}
.contact-card {
  display: flex; gap: 12px; padding: 12px; border-radius: 10px;
  border: 1px solid #e2e8f0; background: #f8fafc; transition: box-shadow 0.15s;
}
.contact-card:hover { box-shadow: 0 2px 8px rgba(0,0,0,0.06); }
.contact-avatar {
  width: 40px; height: 40px; border-radius: 50%; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  color: white; font-weight: 700; font-size: 14px;
}
.contact-info { min-width: 0; }
.contact-name { font-weight: 700; font-size: 13px; color: #1e293b; }
.contact-role { margin: 2px 0 6px; }
.contact-detail { font-size: 12px; color: #64748b; margin-bottom: 2px; }
.contact-detail a { color: #3b82f6; text-decoration: none; }
.contact-detail a:hover { text-decoration: underline; }

/* Legacy selectors kept for other uses */
.scheduler-calendar { flex: 1; background: white; border-radius: 12px; box-shadow: 0 2px 8px rgba(0,0,0,0.06); overflow: hidden; }
.scheduler-nav { display: flex; align-items: center; gap: 12px; }
.staff-dot { width: 10px; height: 10px; border-radius: 50%; }
.staff-role { font-size: 11px; color: #94a3b8; }

/* ===== Report Charts ===== */
.payments-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }
.payment-card { padding: 20px; border-radius: 12px; }
.payment-card.payment-cash { background: #f0fdfa; }
.payment-card.payment-card-type { background: #eff6ff; }
.payment-amount { font-size: 24px; font-weight: 700; margin-bottom: 8px; }
.payment-cash .payment-amount { color: #0D9488; }
.payment-card-type .payment-amount { color: #3B82F6; }
.payment-bar { height: 8px; border-radius: 4px; background: #e2e8f0; overflow: hidden; }
.payment-bar-fill { height: 100%; border-radius: 4px; transition: width 0.5s ease; }
.payment-cash .payment-bar-fill { background: #0D9488; }
.payment-card-type .payment-bar-fill { background: #3B82F6; }

.bar-chart { display: flex; align-items: flex-end; gap: 8px; height: 200px; padding: 16px 0; }
.bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.bar { width: 100%; border-radius: 4px 4px 0 0; background: #6B46C1; transition: height 0.5s ease; min-height: 4px; }
.bar-label { font-size: 11px; color: #64748b; }
.bar-value { font-size: 11px; font-weight: 600; color: #1e293b; }

/* ===== Form Layout Helpers ===== */
.form-row { display: flex; gap: 16px; margin-bottom: 16px; }
.form-row .form-group { flex: 1; }
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: 13px; font-weight: 500; color: #334155; margin-bottom: 6px; }
.form-group .input,
.form-group .select,
.form-group textarea { width: 100%; }

/* ===== Card Actions ===== */
.card-actions { display: flex; gap: 8px; margin-top: 12px; }

/* ===== Setup Tabs ===== */
.setup-tabs { display: flex; gap: 0; margin-bottom: 24px; border-bottom: 2px solid #e2e8f0; }
.setup-tab {
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 500;
  color: #64748b;
  background: none;
  border: none;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
}
.setup-tab:hover { color: #6B46C1; }
.setup-tab.active { color: #6B46C1; border-bottom-color: #6B46C1; }

/* ===== Receipt Preview ===== */
.receipt-preview {
  max-width: 300px;
  margin: 0 auto;
  font-family: monospace;
  font-size: 12px;
  line-height: 1.5;
  padding: 20px;
  background: #fafafa;
  border: 1px dashed #ccc;
  border-radius: 4px;
}
.receipt-success { text-align: center; padding: 20px 0; }
.receipt-check { font-size: 48px; color: #0D9488; margin-bottom: 12px; }
.receipt-total { font-size: 28px; font-weight: 700; color: #1e293b; margin: 8px 0; }
.receipt-change { font-size: 16px; color: #0D9488; margin-bottom: 16px; }

/* ===== Login Page ===== */
.login-screen {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: linear-gradient(135deg, #1E1E2D 0%, #2d1b69 50%, #6B46C1 100%);
}
.login-card {
  background: white;
  border-radius: 16px;
  padding: 40px;
  width: 100%;
  max-width: 400px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}
.login-logo { text-align: center; margin-bottom: 32px; }
.login-logo h1 { font-size: 28px; color: #1e293b; margin: 8px 0 4px; }
.login-logo p { color: #64748b; font-size: 14px; }
.login-logo-img { max-width: 280px; width: 100%; height: auto; margin: 0 auto 8px; display: block; border-radius: 12px; }
.logo-icon-lg { font-size: 40px; }
.login-form .form-group { margin-bottom: 20px; }
.login-error { background: #fef2f2; color: #dc2626; padding: 10px 14px; border-radius: 8px; font-size: 13px; margin-bottom: 16px; }
.btn-block { width: 100%; }
.shake { animation: shake 0.5s; }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-8px); }
  75% { transform: translateX(8px); }
}

/* ===== Global Search Modal ===== */
.global-search { padding: 0; }
.global-search .input-lg { font-size: 16px; padding: 14px 16px; }
.search-results { max-height: 400px; overflow-y: auto; margin-top: 12px; }
.search-section { margin-bottom: 16px; }
.search-section h4 { font-size: 12px; text-transform: uppercase; color: #64748b; margin-bottom: 8px; letter-spacing: 0.5px; }
.search-result-item { display: block; padding: 10px 12px; border-radius: 8px; color: #334155; cursor: pointer; transition: background 0.15s; text-decoration: none; }
.search-result-item:hover { background: #f8fafc; }

/* ===== Customer Search (POS) ===== */
.customer-search-results { max-height: 300px; overflow-y: auto; margin: 12px 0; }
.customer-result { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 8px; cursor: pointer; transition: background 0.15s; }
.customer-result:hover { background: #f8fafc; }
.customer-result-avatar { width: 36px; height: 36px; border-radius: 50%; background: #6B46C1; color: white; display: flex; align-items: center; justify-content: center; font-weight: 600; font-size: 14px; }
.customer-result-name { font-weight: 500; color: #1e293b; }
.customer-result-phone { font-size: 13px; color: #64748b; }

/* ===== Drafts List ===== */
.drafts-list { }
.draft-item { display: flex; justify-content: space-between; align-items: center; padding: 12px; border-bottom: 1px solid #f1f5f9; }
.draft-item:last-child { border-bottom: none; }
.draft-name { font-weight: 500; color: #1e293b; }
.draft-meta { font-size: 13px; color: #64748b; }
.draft-actions { display: flex; gap: 8px; }

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .settings-layout { flex-direction: column; }
  .settings-nav { width: 100%; }
  .scheduler-container { flex-direction: column; }
  .scheduler-staff { width: 100%; }
  .week-date-row { grid-template-columns: repeat(7, 1fr); overflow-x: auto; }
  .week-days { grid-template-columns: repeat(7, minmax(80px, 1fr)); overflow-x: auto; }
  .day-column { min-height: 200px; }
  .scheduler-actions { margin-left: 0; }
  .filter-bar { flex-direction: column; }
  .filter-actions { width: 100%; justify-content: flex-end; }
}

/* ===== Dashboard ===== */
.db-loading { display: flex; justify-content: center; align-items: center; min-height: 300px; }

/* Header */
.db-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; flex-wrap: wrap; gap: 12px; }
.db-header-left { display: flex; align-items: center; gap: 12px; }
.db-title { font-size: 24px; font-weight: 700; color: #1e293b; margin: 0; }
.db-back-btn { color: #6366f1; font-weight: 500; padding: 6px 10px; }
.db-date-tabs { display: flex; gap: 4px; background: #f1f5f9; border-radius: 8px; padding: 3px; }
.db-tab { background: transparent; border: none; padding: 6px 16px; border-radius: 6px; font-size: 13px; font-weight: 500; color: #64748b; cursor: pointer; transition: all 0.15s; }
.db-tab.active { background: white; color: #1e293b; box-shadow: 0 1px 3px rgba(0,0,0,0.1); }

/* Summary strip (multi view) */
.db-summary-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 24px; }
.db-summary-kpi { background: white; border-radius: 10px; padding: 16px 20px; border: 1px solid #e2e8f0; }
.db-kpi-label { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: #94a3b8; margin-bottom: 4px; }
.db-kpi-value { font-size: 22px; font-weight: 700; color: #1e293b; }
.db-kpi-denom { font-size: 14px; font-weight: 400; color: #94a3b8; }

/* Branch grid cards */
.db-branch-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.db-branch-card { background: white; border-radius: 12px; border: 1px solid #e2e8f0; padding: 20px; cursor: pointer; transition: all 0.18s; }
.db-branch-card:hover { border-color: #6366f1; box-shadow: 0 4px 16px rgba(99,102,241,0.12); transform: translateY(-1px); }
.db-bc-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.db-bc-name { font-size: 15px; font-weight: 700; color: #1e293b; }
.db-bc-status { font-size: 12px; font-weight: 600; padding: 3px 8px; border-radius: 20px; }
.db-bc-status.open { color: #16a34a; background: #dcfce7; }
.db-bc-status.closed { color: #94a3b8; background: #f1f5f9; }
.db-bc-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 12px; }
.db-bc-metric-val { font-size: 18px; font-weight: 700; color: #1e293b; }
.db-bc-metric-label { font-size: 11px; color: #94a3b8; margin-top: 2px; }
.db-bc-top { font-size: 12px; color: #64748b; background: #f8fafc; border-radius: 6px; padding: 6px 10px; margin-bottom: 10px; }
.db-bc-cta { font-size: 12px; font-weight: 600; color: #6366f1; text-align: right; }

/* KPI row (single view) */
.db-kpi-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 20px; }
.db-kpi-card { background: white; border-radius: 12px; border: 1px solid #e2e8f0; padding: 20px; display: flex; gap: 14px; align-items: flex-start; }
.db-kpi-icon { font-size: 24px; }
.db-kpi-body { flex: 1; }
.db-kpi-big { font-size: 26px; font-weight: 700; color: #1e293b; line-height: 1.1; margin: 4px 0; }
.db-kpi-prev { display: flex; align-items: center; gap: 4px; font-size: 12px; margin-top: 4px; }
.db-kpi-prevlabel { color: #94a3b8; }

/* Change badges */
.db-change { font-size: 12px; font-weight: 600; padding: 2px 6px; border-radius: 4px; }
.db-change.up { color: #16a34a; background: #dcfce7; }
.db-change.down { color: #dc2626; background: #fee2e2; }
.db-change.neutral { color: #94a3b8; background: #f1f5f9; }

/* Row / column layout */
.db-row { display: grid; grid-template-columns: 2fr 1fr; gap: 16px; margin-bottom: 20px; }
.db-col-2 { }
.db-col-1 { }
.db-card { background: white; border-radius: 12px; border: 1px solid #e2e8f0; padding: 20px; height: 100%; box-sizing: border-box; }
.db-card-title { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: #94a3b8; margin-bottom: 16px; }
.db-empty { color: #94a3b8; font-size: 14px; text-align: center; padding: 32px 0; }

/* Shift card */
.db-shift-card { }
.db-shift-status-badge { display: inline-block; font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 20px; margin-bottom: 14px; }
.db-shift-status-badge.open { color: #16a34a; background: #dcfce7; }
.db-shift-status-badge.closed { color: #94a3b8; background: #f1f5f9; }
.db-shift-hint { font-size: 13px; color: #94a3b8; }
.db-shift-rows { display: flex; flex-direction: column; gap: 8px; }
.db-shift-row { display: flex; justify-content: space-between; font-size: 13px; color: #64748b; }
.db-shift-row span:last-child { font-weight: 600; color: #1e293b; }
.db-shift-total { border-top: 1px solid #f1f5f9; padding-top: 8px; margin-top: 4px; }
.db-shift-total span:last-child { color: #6366f1; font-size: 15px; }
.db-shift-closed { text-align: center; }

/* Hourly chart */
.db-chart-meta { display: flex; justify-content: space-between; font-size: 12px; color: #94a3b8; margin-bottom: 10px; }
.db-bar-chart { display: flex; align-items: flex-end; gap: 2px; height: 100px; position: relative; }
.db-bar-wrap { flex: 1; display: flex; flex-direction: column; align-items: center; height: 100%; justify-content: flex-end; position: relative; }
.db-bar { width: 70%; background: #6366f1; border-radius: 3px 3px 0 0; min-height: 2px; transition: height 0.3s; }
.db-bar-wrap:hover .db-bar { background: #4f46e5; }
.db-bar-label { font-size: 9px; color: #94a3b8; margin-top: 4px; white-space: nowrap; }

/* Top items */
.db-top-list { display: flex; flex-direction: column; gap: 10px; }
.db-top-item { display: flex; align-items: center; gap: 12px; }
.db-top-rank { width: 22px; height: 22px; border-radius: 50%; background: #f1f5f9; font-size: 11px; font-weight: 700; color: #64748b; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.db-top-item:nth-child(1) .db-top-rank { background: #fef3c7; color: #d97706; }
.db-top-item:nth-child(2) .db-top-rank { background: #f1f5f9; color: #64748b; }
.db-top-item:nth-child(3) .db-top-rank { background: #fde8d0; color: #c2410c; }
.db-top-info { flex: 1; }
.db-top-name { font-size: 13px; font-weight: 500; color: #1e293b; margin-bottom: 4px; }
.db-top-bar-wrap { height: 4px; background: #f1f5f9; border-radius: 2px; }
.db-top-bar { height: 100%; background: #6366f1; border-radius: 2px; transition: width 0.4s; }
.db-top-meta { text-align: right; }
.db-top-rev { font-size: 13px; font-weight: 700; color: #1e293b; }
.db-top-qty { font-size: 11px; color: #94a3b8; }

/* Customer donut */
.db-cust-mix { display: flex; flex-direction: column; align-items: center; gap: 20px; padding: 8px 0; }
.db-donut { width: 120px; height: 120px; border-radius: 50%; position: relative; display: flex; align-items: center; justify-content: center; }
.db-donut::after { content: ''; position: absolute; width: 76px; height: 76px; background: white; border-radius: 50%; }
.db-donut-inner { position: relative; z-index: 1; text-align: center; }
.db-donut-val { font-size: 22px; font-weight: 700; color: #1e293b; }
.db-donut-sub { font-size: 11px; color: #94a3b8; }
.db-cust-legend { display: flex; flex-direction: column; gap: 10px; width: 100%; }
.db-legend-item { display: flex; align-items: center; gap: 8px; font-size: 13px; color: #64748b; }
.db-legend-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.db-legend-item strong { margin-left: auto; color: #1e293b; }
.db-legend-item small { color: #94a3b8; font-weight: 400; }

@media (max-width: 1024px) {
  .db-summary-strip { grid-template-columns: repeat(2, 1fr); }
  .db-kpi-row { grid-template-columns: repeat(2, 1fr); }
  .db-row { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .db-summary-strip { grid-template-columns: 1fr 1fr; }
  .db-kpi-row { grid-template-columns: 1fr 1fr; }
  .db-branch-grid { grid-template-columns: 1fr; }
}

/* ── Low Stock Alerts (Dashboard) ── */
.db-low-stock-card {
  background: white;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  padding: 20px;
  margin-bottom: 20px;
}
.db-low-stock-card .db-card-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #94a3b8;
  margin-bottom: 16px;
}
.db-low-stock-badge {
  font-size: 11px;
  font-weight: 700;
  text-transform: none;
  letter-spacing: 0;
  color: #dc2626;
  background: #fef2f2;
  padding: 3px 10px;
  border-radius: 20px;
}
.db-low-stock-list {
  overflow-x: auto;
}
.db-low-stock-header {
  display: grid;
  grid-template-columns: 2fr 1fr 80px 80px;
  gap: 12px;
  padding: 0 0 8px;
  font-size: 11px;
  font-weight: 600;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-bottom: 1px solid #f1f5f9;
}
.db-low-stock-row {
  display: grid;
  grid-template-columns: 2fr 1fr 80px 80px;
  gap: 12px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid #f8fafc;
  font-size: 13px;
}
.db-low-stock-row:last-child { border-bottom: none; }

.db-ls-product { display: flex; flex-direction: column; gap: 1px; }
.db-ls-name { font-weight: 600; color: #1e293b; }
.db-ls-sku { font-size: 11px; color: #94a3b8; }
.db-ls-location { color: #64748b; font-size: 12px; }
.db-ls-qty { font-weight: 700; }
.db-ls-reorder { color: #94a3b8; font-size: 12px; }

.db-ls-status {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
}
.db-ls-status.out {
  color: #dc2626;
  background: #fef2f2;
}
.db-ls-status.low {
  color: #d97706;
  background: #fffbeb;
}

/* Low stock badge on branch cards */
.db-bc-lowstock {
  font-size: 11px;
  color: #d97706;
  background: #fffbeb;
  border-radius: 6px;
  padding: 4px 8px;
  margin-bottom: 10px;
  font-weight: 600;
}

@media (max-width: 600px) {
  .db-low-stock-header,
  .db-low-stock-row {
    grid-template-columns: 1.5fr 1fr 60px 60px;
    gap: 8px;
  }
}

/* ============================================================================
   REPORTS PAGE
   ============================================================================ */

.rp-page { padding: 0 0 40px; }

/* Header */
.rp-header {
  display: flex; align-items: flex-start; justify-content: space-between;
  flex-wrap: wrap; gap: 12px; margin-bottom: 16px;
}
.rp-header h1 { margin: 0; font-size: 1.5rem; }
.rp-controls {
  display: flex; align-items: center; flex-wrap: wrap; gap: 8px;
}
.rp-select {
  padding: 6px 10px; border: 1px solid var(--border); border-radius: 6px;
  background: var(--card-bg); font-size: 0.85rem; cursor: pointer;
}
.rp-date-input {
  padding: 6px 10px; border: 1px solid var(--border); border-radius: 6px;
  background: var(--card-bg); font-size: 0.85rem;
}
.rp-custom-dates { display: flex; align-items: center; gap: 6px; }
.btn-sm { padding: 6px 12px; font-size: 0.8rem; }

/* Preset buttons */
.rp-preset-group { display: flex; flex-wrap: wrap; gap: 4px; }
.rp-preset-btn {
  padding: 5px 10px; border: 1px solid var(--border); border-radius: 5px;
  background: var(--card-bg); font-size: 0.78rem; cursor: pointer;
  color: var(--text-secondary); transition: all 0.15s;
}
.rp-preset-btn:hover  { border-color: var(--primary); color: var(--primary); }
.rp-preset-btn.active { background: var(--primary); color: #fff; border-color: var(--primary); }

/* Tabs */
.rp-tabs {
  display: flex; gap: 0; border-bottom: 2px solid var(--border); margin-bottom: 20px;
}
.rp-tab {
  padding: 10px 20px; background: none; border: none; border-bottom: 3px solid transparent;
  margin-bottom: -2px; cursor: pointer; font-size: 0.9rem; color: var(--text-secondary);
  transition: all 0.15s; font-weight: 500;
}
.rp-tab:hover  { color: var(--primary); }
.rp-tab.active { color: var(--primary); border-bottom-color: var(--primary); }

/* Loading / Error */
.rp-loading {
  display: flex; align-items: center; justify-content: center;
  gap: 12px; padding: 60px; color: var(--text-secondary);
}
.rp-error {
  padding: 20px; background: #fef2f2; border: 1px solid #fecaca;
  border-radius: 8px; color: #dc2626;
}
.rp-empty { color: var(--text-secondary); font-style: italic; padding: 12px 0; }

/* Sections */
.rp-section {
  background: var(--card-bg); border: 1px solid var(--border);
  border-radius: 10px; padding: 20px; margin-bottom: 16px;
}
.rp-section h3 { margin: 0 0 16px; font-size: 1rem; }
.rp-two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }

/* Compare badge */
.rp-compare-badge {
  display: inline-block; padding: 4px 10px; border-radius: 20px;
  background: var(--primary-light, #eff6ff); color: var(--primary);
  font-size: 0.8rem; margin-bottom: 16px;
}

/* KPI Cards */
.rp-kpi-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.rp-kpi-card {
  display: flex; align-items: center; gap: 12px;
  background: var(--bg); border: 1px solid var(--border);
  border-radius: 8px; padding: 14px;
}
.rp-kpi-icon { font-size: 1.4rem; }
.rp-kpi-label { font-size: 0.78rem; color: var(--text-secondary); margin-bottom: 2px; }
.rp-kpi-value { font-size: 1.3rem; font-weight: 700; }
.rp-kpi-prev  { font-size: 0.75rem; color: var(--text-secondary); margin-top: 2px; }

/* Pct badges */
.rp-pct { font-size: 0.75rem; font-weight: 600; padding: 1px 5px; border-radius: 3px; margin-left: 4px; }
.rp-pct.up   { background: #dcfce7; color: #16a34a; }
.rp-pct.down { background: #fee2e2; color: #dc2626; }
.rp-pct.flat { background: #f3f4f6; color: #6b7280; }

/* Meta row */
.rp-meta-row {
  display: flex; flex-wrap: wrap; gap: 16px;
  padding-top: 12px; margin-top: 12px; border-top: 1px solid var(--border);
  font-size: 0.85rem; color: var(--text-secondary);
}

/* Timeline Chart */
.rp-tl-chart {
  display: flex; align-items: flex-end; gap: 4px;
  height: 140px; padding-bottom: 28px; overflow-x: auto;
}
.rp-tl-bar-wrap {
  display: flex; flex-direction: column; align-items: center;
  min-width: 24px; flex: 1; height: 100%; justify-content: flex-end;
}
.rp-tl-bars { display: flex; align-items: flex-end; gap: 2px; width: 100%; height: calc(100% - 20px); }
.rp-tl-bar { flex: 1; border-radius: 3px 3px 0 0; min-height: 3px; transition: height 0.3s; }
.rp-tl-bar.cur  { background: var(--primary, #3b82f6); }
.rp-tl-bar.prev { background: #bfdbfe; }
.rp-tl-label { font-size: 0.65rem; color: var(--text-secondary); margin-top: 4px; text-align: center; white-space: nowrap; }
.rp-tl-legend { display: flex; gap: 16px; margin-top: 8px; font-size: 0.8rem; }
.rp-leg-cur  { color: var(--primary); }
.rp-leg-prev { color: #93c5fd; }

/* Payments */
.rp-pay-row {
  display: grid; grid-template-columns: 80px 1fr 90px 50px;
  align-items: center; gap: 10px; margin-bottom: 10px;
}
.rp-pay-method {
  font-size: 0.85rem; font-weight: 600; text-transform: capitalize;
  padding: 2px 8px; border-radius: 4px;
  background: color-mix(in srgb, var(--col) 15%, transparent);
  color: var(--col);
}
.rp-pay-bar-wrap { background: var(--border); border-radius: 4px; height: 8px; overflow: hidden; }
.rp-pay-bar      { height: 100%; border-radius: 4px; }
.rp-pay-amount   { font-size: 0.85rem; font-weight: 600; text-align: right; }
.rp-pay-pct      { font-size: 0.8rem; color: var(--text-secondary); }

/* Categories */
.rp-cat-row { margin-bottom: 10px; }
.rp-cat-name { font-size: 0.83rem; margin-bottom: 3px; }
.rp-cat-name small { color: var(--text-secondary); }
.rp-cat-bars { position: relative; height: 18px; background: var(--border); border-radius: 4px; overflow: hidden; margin-bottom: 3px; }
.rp-cat-bar  { position: absolute; top: 0; left: 0; height: 100%; border-radius: 4px; }
.rp-cat-bar.cur  { background: var(--primary, #3b82f6); }
.rp-cat-bar.prev { background: #bfdbfe; height: 40%; top: 30%; }
.rp-cat-rev { font-size: 0.8rem; color: var(--text-secondary); }

/* Tables */
.rp-table-wrap { overflow-x: auto; }
.rp-table { width: 100%; border-collapse: collapse; font-size: 0.85rem; }
.rp-table th {
  text-align: left; padding: 8px 12px;
  border-bottom: 2px solid var(--border);
  font-size: 0.78rem; font-weight: 600;
  color: var(--text-secondary); white-space: nowrap;
}
.rp-table td { padding: 8px 12px; border-bottom: 1px solid var(--border); }
.rp-table tbody tr:hover { background: var(--bg); }
.rp-num { text-align: right; font-variant-numeric: tabular-nums; }
.rp-sku { color: var(--text-secondary); margin-left: 4px; }

/* Inventory */
.rp-inv-toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; }
.rp-search-input {
  flex: 1; min-width: 200px; padding: 7px 12px;
  border: 1px solid var(--border); border-radius: 6px;
  background: var(--bg); font-size: 0.85rem;
}
.rp-toggle-label { display: flex; align-items: center; gap: 6px; font-size: 0.85rem; cursor: pointer; }

.rp-status {
  display: inline-block; padding: 2px 8px; border-radius: 4px; font-size: 0.75rem; font-weight: 600;
}
.rp-status-ok  { background: #dcfce7; color: #16a34a; }
.rp-status-low { background: #fef9c3; color: #ca8a04; }
.rp-status-out { background: #fee2e2; color: #dc2626; }
.rp-row-low td { background: #fffbeb !important; }
.rp-row-out td { background: #fff1f2 !important; }
.rp-days-warn  { color: #dc2626; font-weight: 600; }

/* Employee */
.rp-emp-list { display: flex; flex-direction: column; gap: 12px; }
.rp-emp-card {
  display: grid; grid-template-columns: 40px 1fr auto 140px;
  align-items: center; gap: 16px;
  background: var(--bg); border: 1px solid var(--border); border-radius: 8px; padding: 14px;
}
.rp-emp-rank { font-size: 1.4rem; text-align: center; }
.rp-emp-name { font-weight: 600; font-size: 0.95rem; }
.rp-emp-role { font-size: 0.75rem; color: var(--text-secondary); background: var(--border); padding: 1px 6px; border-radius: 10px; margin-left: 6px; }
.rp-emp-branch { font-size: 0.8rem; color: var(--text-secondary); }
.rp-emp-top    { font-size: 0.78rem; color: var(--primary); margin-top: 2px; }
.rp-emp-stats  { display: flex; gap: 16px; }
.rp-emp-stat   { text-align: center; }
.rp-emp-sval   { font-size: 0.95rem; font-weight: 700; }
.rp-emp-slbl   { font-size: 0.7rem; color: var(--text-secondary); }
.rp-emp-share  { }
.rp-emp-share-bar {
  height: 6px; background: var(--primary, #3b82f6); border-radius: 3px;
  max-width: 100%; min-width: 2px; margin-bottom: 3px;
}
.rp-emp-share span { font-size: 0.75rem; color: var(--text-secondary); }

/* Margin color coding */
.rp-margin-low { color: #dc2626; font-weight: 600; }
.rp-margin-mid { color: #d97706; font-weight: 600; }
.rp-margin-ok  { color: #16a34a; font-weight: 600; }

/* Warning / Info banners */
.rp-warning-banner {
  background: #fffbeb; border: 1px solid #fbbf24; border-radius: 8px;
  padding: 10px 14px; margin-bottom: 16px; font-size: 0.85rem; color: #92400e;
}
.rp-info-banner {
  background: #eff6ff; border: 1px solid #93c5fd; border-radius: 8px;
  padding: 10px 14px; margin-bottom: 16px; font-size: 0.85rem; color: #1e40af;
}

/* Segment cards */
.rp-segment-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.rp-segment-card {
  background: var(--bg); border: 1px solid var(--border);
  border-radius: 8px; padding: 14px; display: flex; align-items: center; gap: 12px;
}
.rp-segment-icon { font-size: 1.4rem; }
.rp-segment-label { font-size: 0.85rem; font-weight: 600; }
.rp-segment-value { font-size: 1.1rem; font-weight: 700; }
.rp-segment-rev   { font-size: 0.8rem; color: var(--text-secondary); }

/* Responsive */
@media (max-width: 1024px) {
  .rp-kpi-row { grid-template-columns: repeat(2, 1fr); }
  .rp-two-col { grid-template-columns: 1fr; }
  .rp-emp-card { grid-template-columns: 40px 1fr; }
  .rp-emp-stats { display: none; }
  .rp-emp-share { display: none; }
  .rp-segment-cards { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .rp-header { flex-direction: column; }
  .rp-kpi-row { grid-template-columns: 1fr 1fr; }
  .rp-preset-group { display: none; }
  .rp-pay-row { grid-template-columns: 70px 1fr 70px; }
  .rp-pay-pct { display: none; }
}

/* ── Store Multi-Select Picker ──────────────────────────────────────────── */
.rp-store-picker { position: relative; }

.rp-sp-trigger {
  display: flex; align-items: center; gap: 6px;
  padding: 6px 12px; border: 1px solid var(--border); border-radius: 6px;
  background: var(--card-bg); font-size: 0.85rem; cursor: pointer;
  white-space: nowrap; transition: border-color 0.15s;
}
.rp-sp-trigger:hover       { border-color: var(--primary); }
.rp-sp-trigger.has-selection {
  border-color: var(--primary); background: var(--primary-light, #eff6ff); color: var(--primary);
}
.rp-sp-caret { font-size: 0.7rem; opacity: 0.6; }

.rp-sp-dropdown {
  position: absolute; top: calc(100% + 4px); left: 0; z-index: 200;
  width: 280px; background: var(--card-bg); border: 1px solid var(--border);
  border-radius: 8px; box-shadow: 0 8px 24px rgba(0,0,0,0.12);
  overflow: hidden;
}

.rp-sp-search-wrap { padding: 10px 10px 6px; border-bottom: 1px solid var(--border); }
.rp-sp-search {
  width: 100%; padding: 6px 10px; border: 1px solid var(--border); border-radius: 5px;
  background: var(--bg); font-size: 0.83rem; box-sizing: border-box;
}
.rp-sp-search:focus { outline: none; border-color: var(--primary); }

.rp-sp-all {
  display: flex; align-items: center; gap: 8px; padding: 8px 12px;
  cursor: pointer; font-size: 0.85rem; border-bottom: 1px solid var(--border);
  background: var(--bg);
}
.rp-sp-all:hover { background: color-mix(in srgb, var(--primary) 8%, var(--bg)); }
.rp-sp-count { margin-left: auto; font-size: 0.75rem; color: var(--text-secondary); }

.rp-sp-divider { height: 1px; background: var(--border); }

.rp-sp-list {
  max-height: 260px; overflow-y: auto; padding: 4px 0;
}

.rp-sp-group-header {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 12px 4px; cursor: pointer;
  font-size: 0.75rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.06em; color: var(--text-secondary);
}
.rp-sp-group-header:hover { color: var(--text); }

.rp-sp-row {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 12px 6px 20px; cursor: pointer; font-size: 0.85rem;
  transition: background 0.1s;
}
.rp-sp-row:hover { background: color-mix(in srgb, var(--primary) 8%, var(--card-bg)); }
.rp-sp-row input[type=checkbox] { flex-shrink: 0; cursor: pointer; }
.rp-sp-name { flex: 1; }
.rp-sp-state-tag {
  font-size: 0.7rem; padding: 1px 6px; border-radius: 10px;
  background: var(--border); color: var(--text-secondary);
}

.rp-sp-footer {
  display: flex; justify-content: flex-end; gap: 8px;
  padding: 8px 12px; border-top: 1px solid var(--border); background: var(--bg);
}
.rp-sp-clear {
  background: none; border: 1px solid var(--border); color: var(--text-secondary);
}
.rp-sp-clear:hover { border-color: #dc2626; color: #dc2626; }

/* ═══════════════════════════════════════════════════════════
   TAG PILLS  (shared across Inventory Admin, POS, Reports)
═══════════════════════════════════════════════════════════ */

/* Read-only pill (product list, product cards) */
.tag-pill {
  display: inline-flex; align-items: center; gap: 2px;
  padding: 2px 8px; border-radius: 999px;
  background: #ede9fe; color: #5b21b6;
  font-size: 11px; font-weight: 600; letter-spacing: .02em;
  white-space: nowrap;
}

/* List of read-only pills */
.tag-pill-list { display: flex; flex-wrap: wrap; gap: 4px; }

/* Editable pill (product editor modal) */
.tag-pill-editable {
  display: inline-flex; align-items: center; gap: 3px;
  padding: 2px 4px 2px 8px; border-radius: 999px;
  background: #ede9fe; color: #5b21b6;
  font-size: 11px; font-weight: 600;
}

.tag-pill-x {
  all: unset; cursor: pointer; font-size: 13px; line-height: 1;
  color: #7c3aed; padding: 0 2px; border-radius: 50%;
  transition: background .15s;
}
.tag-pill-x:hover { background: #c4b5fd; }

/* Input wrapper — behaves like a multi-value input */
.tag-pill-input-wrapper {
  display: flex; flex-wrap: wrap; align-items: center; gap: 4px;
  min-height: 38px; padding: 4px 8px;
  border: 1px solid var(--border); border-radius: 6px;
  background: var(--bg-secondary);
  cursor: text;
}
.tag-pill-input-wrapper:focus-within { border-color: var(--primary); box-shadow: 0 0 0 2px rgba(99,102,241,.15); }

.tag-pill-text-input {
  all: unset; font-size: 13px; min-width: 100px; flex: 1;
  color: var(--text-primary);
}

/* Autocomplete suggestions dropdown */
.tag-suggestions {
  display: flex; flex-wrap: wrap; gap: 4px;
  margin-top: 4px;
}
.tag-suggestion-btn {
  all: unset; cursor: pointer;
  padding: 2px 10px; border-radius: 999px;
  background: #f3f4f6; color: #374151;
  font-size: 11px; font-weight: 600;
  transition: background .15s;
}
.tag-suggestion-btn:hover { background: #ddd6fe; color: #5b21b6; }

/* Inactive product row */
.row-inactive td { opacity: .55; }

/* Products tab header */
.inv-products-header {
  display: flex; align-items: flex-end; gap: 12px;
  margin-bottom: 16px; flex-wrap: wrap;
}

/* ═══════════════════════════════════════════════════════════
   POS TAG BAR
═══════════════════════════════════════════════════════════ */

.pos-tag-bar {
  display: flex; align-items: center; flex-wrap: wrap; gap: 6px;
  padding: 6px 12px; background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
}
.pos-tag-label { font-size: 13px; color: var(--text-secondary); margin-right: 2px; }

.pos-tag-btn {
  all: unset; cursor: pointer;
  padding: 3px 11px; border-radius: 999px;
  border: 1px solid #c4b5fd; background: #f5f3ff;
  color: #5b21b6; font-size: 12px; font-weight: 600;
  transition: background .15s, color .15s;
}
.pos-tag-btn:hover  { background: #ede9fe; }
.pos-tag-btn.active { background: #7c3aed; color: #fff; border-color: #7c3aed; }

.pos-tag-clear {
  all: unset; cursor: pointer;
  padding: 3px 10px; border-radius: 999px;
  background: #fee2e2; color: #b91c1c;
  font-size: 11px; font-weight: 600;
  transition: background .15s;
}
.pos-tag-clear:hover { background: #fecaca; }

/* Tiny tag on product card */
.pos-product-tag {
  display: inline-block; padding: 1px 6px; border-radius: 999px;
  background: #ede9fe; color: #5b21b6;
  font-size: 10px; font-weight: 600;
}
.pos-product-tag.active { background: #7c3aed; color: #fff; }

/* ═══════════════════════════════════════════════════════════
   REPORTS TAG FILTER BAR
═══════════════════════════════════════════════════════════ */

.rp-tag-bar {
  display: flex; align-items: center; flex-wrap: wrap; gap: 6px;
  padding: 6px 0;
}
.rp-tag-label { font-size: 13px; color: var(--text-secondary); }

.rp-tag-btn {
  all: unset; cursor: pointer;
  padding: 3px 11px; border-radius: 999px;
  border: 1px solid #c4b5fd; background: #f5f3ff;
  color: #5b21b6; font-size: 12px; font-weight: 600;
  transition: background .15s;
}
.rp-tag-btn:hover  { background: #ede9fe; }
.rp-tag-btn.active { background: #7c3aed; color: #fff; border-color: #7c3aed; }

.rp-tag-clear-btn {
  all: unset; cursor: pointer;
  padding: 3px 10px; border-radius: 999px;
  background: #fee2e2; color: #b91c1c;
  font-size: 11px; font-weight: 600;
}
.rp-tag-clear-btn:hover { background: #fecaca; }

/* btn-icon on light backgrounds (data tables) */
.data-table .btn-icon {
  color: var(--color-text-secondary, #666);
  background-color: transparent;
}
.data-table .btn-icon:hover {
  color: var(--color-primary, #6c5ce7);
  background-color: rgba(108, 92, 231, 0.08);
}

/* ─── Tasks page ─────────────────────────────────────────────── */
.tasks-card {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 20px 24px;
}
.tasks-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.task-row:hover {
  background: #f9fafb !important;
}
.task-done .task-row {
  opacity: .75;
}
.btn-sm {
  padding: 5px 12px;
  font-size: 13px;
}

/* ===== Stores (Inventory) ===== */
.stores-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}
.stores-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 18px;
}
.store-inventory-card {
  background: white;
  border-radius: 14px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.07);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: box-shadow 0.15s;
}
.store-inventory-card:hover {
  box-shadow: 0 4px 20px rgba(0,0,0,0.12);
}
.store-card-top {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.store-icon {
  font-size: 28px;
  line-height: 1;
}
.store-info { flex: 1; min-width: 0; }
.store-name { font-size: 16px; font-weight: 600; margin: 0 0 2px; }
.store-location { font-size: 13px; }
.store-card-actions { display: flex; gap: 4px; }
.store-stats {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 12px;
  background: #f8fafc;
  border-radius: 10px;
}
.store-stat {
  flex: 1;
  text-align: center;
}
.stat-number {
  display: block;
  font-size: 22px;
  font-weight: 700;
  color: #1e293b;
  line-height: 1.1;
}
.stat-label {
  display: block;
  font-size: 11px;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.stat-warning .stat-number { color: #e67e22; }
.store-view-btn {
  width: 100%;
  margin-top: auto;
}

/* ===== Settings: User avatar small ===== */
.user-avatar-sm {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 15px;
  flex-shrink: 0;
}

/* ===== Rewards Program Settings ===== */
.rewards-config-card {
  max-width: 640px;
}
.rewards-explainer {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 20px;
  background: linear-gradient(135deg, #fef9c3, #fef3c7);
  border-radius: 12px;
  margin-bottom: 24px;
}
.rewards-icon { font-size: 36px; line-height: 1; }
.rewards-desc h3 { margin: 0 0 4px; }
.rewards-toggle-row {
  margin-bottom: 20px;
}
.toggle-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-size: 15px;
  font-weight: 500;
}
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 46px;
  height: 24px;
  flex-shrink: 0;
}
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: #cbd5e1;
  border-radius: 24px;
  transition: 0.2s;
}
.toggle-slider:before {
  content: '';
  position: absolute;
  height: 18px; width: 18px;
  left: 3px; bottom: 3px;
  background: white;
  border-radius: 50%;
  transition: 0.2s;
}
input:checked + .toggle-slider { background: #6366f1; }
input:checked + .toggle-slider:before { transform: translateX(22px); }
.rewards-form-section { transition: opacity 0.2s; }
.rewards-flow {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.rewards-flow-item {
  flex: 1;
  min-width: 140px;
}
.flow-label {
  font-size: 13px;
  font-weight: 500;
  color: #64748b;
  margin-bottom: 6px;
}
.flow-input-wrap {
  display: flex;
  align-items: center;
  border: 1.5px solid #e2e8f0;
  border-radius: 8px;
  overflow: hidden;
  background: white;
}
.currency-prefix {
  padding: 0 10px;
  background: #f8fafc;
  color: #64748b;
  font-weight: 600;
  border-right: 1.5px solid #e2e8f0;
  align-self: stretch;
  display: flex;
  align-items: center;
}
.flow-input {
  border: none !important;
  border-radius: 0 !important;
  flex: 1;
  padding: 9px 10px;
}
.flow-input:focus { outline: none; box-shadow: none !important; }
.rewards-flow-arrow {
  font-size: 22px;
  color: #6366f1;
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 20px;
}
.rewards-hint {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 12px 16px;
  background: #eff6ff;
  border-radius: 8px;
  font-size: 13px;
  color: #1d4ed8;
  line-height: 1.5;
}
.rewards-settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin: 20px 0;
}
.rewards-settings-grid .form-group { margin-bottom: 0; }
.rewards-settings-grid select.input {
  height: 40px;
  padding: 0 12px;
}
.currency-suffix {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-weight: 600;
  color: #6b7280;
  font-size: 14px;
  pointer-events: none;
}

/* ===== Users list (Settings) ===== */
.users-list-grid { max-width: 860px; }
.users-list { display: flex; flex-direction: column; gap: 2px; }
.user-list-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  background: white;
  border-radius: 10px;
  border: 1px solid #f1f5f9;
  transition: box-shadow 0.12s;
}
.user-list-row:hover { box-shadow: 0 2px 12px rgba(0,0,0,0.07); }
.user-avatar-lg {
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 16px;
  flex-shrink: 0;
}
.user-list-info { flex: 1; min-width: 0; }
.user-list-name { font-weight: 600; font-size: 15px; }
.user-list-meta { margin-top: 2px; }
.user-list-actions { display: flex; gap: 6px; align-items: center; flex-shrink: 0; }

/* ===== Users card grid ===== */
.users-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
  padding: 4px 0;
}
.user-card {
  border-radius: 14px;
  border: 1px solid rgba(0,0,0,0.07);
  padding: 20px 16px 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
  transition: box-shadow 0.15s, transform 0.15s;
}
.user-card:hover {
  box-shadow: 0 4px 20px rgba(0,0,0,0.10);
  transform: translateY(-2px);
}
.user-card-avatar {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 20px;
  margin-bottom: 4px;
  box-shadow: 0 2px 8px rgba(102,126,234,0.35);
}
.user-card-role { margin-bottom: 2px; }
.user-card-name { font-weight: 700; font-size: 15px; color: #1e293b; }
.user-card-meta { font-size: 12px; color: #64748b; line-height: 1.4; }
.user-card-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid rgba(0,0,0,0.07);
  width: 100%;
}

/* ===== Deal cards (legacy pills kept for compatibility) ===== */
.deal-inactive { opacity: 0.55; }
.deal-target-pill {
  display: inline-block;
  font-size: 12px;
  color: #64748b;
  background: #f1f5f9;
  padding: 2px 8px;
  border-radius: 20px;
  margin-top: 2px;
}
.deal-discount-badge {
  font-size: 22px;
  font-weight: 700;
  color: #6366f1;
  margin-bottom: 10px;
}

/* ===== Deals card grid (v2) ===== */
/* ===== Deals tab bar ===== */
.deals-tab-bar {
  display: flex;
  gap: 4px;
  margin-bottom: 20px;
  border-bottom: 2px solid #e2e8f0;
  padding-bottom: 0;
}

.deals-tab {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 18px;
  border: none;
  background: none;
  font-size: 13px;
  font-weight: 600;
  color: #94a3b8;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  border-radius: 6px 6px 0 0;
  transition: color 0.15s, border-color 0.15s, background 0.15s;
}

.deals-tab:hover {
  color: #475569;
  background: #f8fafc;
}

.deals-tab.active {
  color: #6366f1;
  border-bottom-color: #6366f1;
  background: none;
}

.deals-tab-count {
  font-size: 11px;
  font-weight: 700;
  background: #f1f5f9;
  color: #94a3b8;
  padding: 1px 7px;
  border-radius: 10px;
  min-width: 20px;
  text-align: center;
}

.deals-tab.active .deals-tab-count {
  background: #eef2ff;
  color: #6366f1;
}

.deals-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
  padding: 4px 0;
}
.deal-card-v2 {
  background: white;
  border-radius: 14px;
  border: 1px solid #e2e8f0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.15s, transform 0.15s;
}
.deal-card-v2:hover {
  box-shadow: 0 4px 20px rgba(0,0,0,0.10);
  transform: translateY(-2px);
}
.deal-card-accent {
  height: 5px;
  width: 100%;
}
.deal-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 14px 14px 0;
}
.deal-discount-big {
  font-size: 26px;
  font-weight: 800;
  line-height: 1.1;
}
.deal-card-actions {
  display: flex;
  gap: 4px;
  align-items: center;
}

/* Compact icon buttons in deal cards */
.deal-action-btn {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  border: 1px solid transparent;
  background: #f1f5f9;
  color: #64748b;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s;
  flex-shrink: 0;
  line-height: 1;
}

.deal-action-btn:hover {
  background: #e2e8f0;
  color: #1e293b;
}

/* Play / activate — green */
.deal-action-activate {
  color: #10b981;
  background: #f0fdf4;
  border-color: #d1fae5;
}
.deal-action-activate:hover {
  background: #10b981;
  color: white;
  border-color: #10b981;
}

/* Pause — amber */
.deal-action-pause {
  color: #f59e0b;
  background: #fffbeb;
  border-color: #fef3c7;
}
.deal-action-pause:hover {
  background: #f59e0b;
  color: white;
  border-color: #f59e0b;
}

/* Edit — neutral */
.deal-action-edit {
  font-size: 15px;
}

/* Delete — red on hover */
.deal-action-delete:hover {
  background: #fee2e2;
  color: #ef4444;
  border-color: #fecaca;
}
.deal-card-name {
  font-size: 14px;
  font-weight: 600;
  color: #1e293b;
  padding: 8px 14px 2px;
}
.deal-card-target {
  font-size: 12px;
  color: #64748b;
  padding: 0 14px 10px;
}
.deal-card-footer {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  padding: 10px 14px 14px;
  border-top: 1px solid #f1f5f9;
  margin-top: auto;
}

/* ===== Customers table ===== */
.customers-table-wrap {
  overflow-x: auto;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  background: white;
}
.customers-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.customers-table thead tr {
  background: #f8fafc;
  border-bottom: 2px solid #e2e8f0;
}
.customers-table th {
  padding: 12px 16px;
  text-align: left;
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #64748b;
  white-space: nowrap;
}
.customers-table td {
  padding: 12px 16px;
  border-bottom: 1px solid #f1f5f9;
  vertical-align: middle;
  color: #1e293b;
}
.customers-table tbody tr:last-child td { border-bottom: none; }
.customers-table tbody tr:hover { background: #f8fafc; }
.customer-table-name {
  display: flex;
  align-items: center;
  gap: 10px;
}
.customer-initials {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: white;
  font-weight: 700;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.customer-name-text { font-weight: 600; }

/* ===== Location Tab ===== */
.location-header {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.location-groups { display: flex; flex-direction: column; gap: 24px; }
.location-group {
  background: white;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  overflow: hidden;
}
.location-group-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
}
.location-store-icon { font-size: 18px; }
.location-store-name { font-weight: 700; font-size: 15px; color: #1e293b; flex: 1; }
.location-store-count { font-size: 12px; color: #64748b; background: #e2e8f0; padding: 2px 10px; border-radius: 20px; }
.location-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.location-table th {
  padding: 10px 16px;
  text-align: left;
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #94a3b8;
  white-space: nowrap;
}
.location-table th.text-right, .location-table td.text-right { text-align: right; }
.location-table td {
  padding: 11px 16px;
  border-top: 1px solid #f1f5f9;
  color: #334155;
  vertical-align: middle;
}
.location-table tbody tr:hover { background: #f8fafc; }
.location-row-low { background: #fff7ed !important; }
.location-qty {
  font-weight: 700;
  font-size: 15px;
  color: #1e293b;
}
.location-qty-low { color: #ea580c; }

/* ===== Deal product picker ===== */
.deal-product-picker { display: flex; flex-direction: column; gap: 10px; }
.deal-product-filters { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.deal-product-results {
  max-height: 220px;
  overflow-y: auto;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: white;
}
.deal-product-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  cursor: pointer;
  border-bottom: 1px solid #f1f5f9;
  transition: background 0.1s;
}
.deal-product-option:last-child { border-bottom: none; }
.deal-product-option:hover { background: #f0f9ff; }
.deal-product-name { flex: 1; font-weight: 500; font-size: 14px; color: #1e293b; }
.deal-product-sku { font-size: 12px; }
.deal-product-price { font-weight: 600; font-size: 13px; color: #0ea5e9; white-space: nowrap; }
.deal-product-selected {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: #f0fdf4;
  border-radius: 8px;
  border: 1px solid #bbf7d0;
}

/* ===== Location tag pill (read-only, visually distinct from category tags) ===== */
.tag-pill-location {
  background: #e0f2fe;
  color: #0369a1;
  border: 1px solid #bae6fd;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 20px;
  display: inline-block;
  margin: 2px 2px 2px 0;
  font-weight: 500;
}

/* ===== Branches card grid ===== */
.branches-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 16px;
  padding: 4px 0;
}
.branch-card-v2 {
  background: white;
  border-radius: 14px;
  border: 1px solid #e2e8f0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.15s, transform 0.15s;
}
.branch-card-v2:hover {
  box-shadow: 0 4px 20px rgba(0,0,0,0.10);
  transform: translateY(-2px);
}
.branch-card-accent {
  height: 5px;
  width: 100%;
}
.branch-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 14px 8px;
}
.branch-avatar {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  color: white;
  font-weight: 700;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.branch-card-actions { display: flex; gap: 4px; }
.branch-card-name {
  font-size: 16px;
  font-weight: 700;
  color: #1e293b;
  padding: 0 14px 2px;
}
.branch-card-code {
  font-size: 11px;
  font-weight: 600;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0 14px 8px;
}
.branch-card-details {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 8px 14px 16px;
  border-top: 1px solid #f1f5f9;
  margin-top: auto;
}
.branch-detail {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  font-size: 12px;
  color: #475569;
  line-height: 1.4;
}
.branch-detail span:first-child { flex-shrink: 0; font-size: 13px; }

/* ===== Page Tab Bar (Inventory & Settings) ===== */
.page-tab-bar {
  display: flex;
  align-items: center;
  gap: 4px;
  background: white;
  border-radius: 12px;
  padding: 6px;
  margin-bottom: 20px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07);
  border: 1px solid #e2e8f0;
  flex-wrap: wrap;
}
.tab-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border: none;
  background: none;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  color: #64748b;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, box-shadow 0.15s;
  white-space: nowrap;
}
.tab-btn:hover {
  background: #f1f5f9;
  color: #1e293b;
}
.tab-btn.active {
  background: #6B46C1;
  color: white;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(107,70,193,0.25);
}
.tab-icon {
  font-size: 15px;
  line-height: 1;
}

/* ===== Deal Branch Chips (store selector in deal modal) ===== */
.form-hint {
  font-size: 12px;
  color: var(--color-text-lighter, #94a3b8);
  margin: -4px 0 8px;
}

.branch-chips-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.branch-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: 20px;
  border: 1.5px solid var(--color-border-light, #e2e8f0);
  background: var(--color-card-bg, #fff);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  color: var(--color-text-light, #64748b);
  transition: all 0.15s;
  user-select: none;
  /* Reset button defaults */
  font-family: inherit;
  line-height: inherit;
  outline: none;
}

.branch-chip:hover {
  border-color: #6B46C1;
  color: #6B46C1;
}

.branch-chip.active {
  background: #6B46C1;
  border-color: #6B46C1;
  color: white;
}

.branch-chip.active:hover {
  background: #5a35a8;
  border-color: #5a35a8;
}

/* ===== Deal card – branch row ===== */
.deal-card-branches {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 4px 0 2px;
}

.deal-branch-pill {
  font-size: 11px;
  font-weight: 500;
  padding: 2px 8px;
  border-radius: 10px;
  background: #ede9fe;
  color: #5b21b6;
  border: 1px solid #ddd6fe;
  white-space: nowrap;
}

.deal-branch-all {
  background: #f0fdf4;
  color: #166534;
  border-color: #bbf7d0;
}

/* ===== Deals page – Active / Past section headers ===== */
.deals-section-header {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  color: var(--color-text-light, #64748b);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  padding: 4px 2px 8px;
}

.deals-section-header-gap {
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--color-border-light, #e2e8f0);
}

.deals-section-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.deals-section-dot-active   { background: #10b981; }
.deals-section-dot-inactive { background: #94a3b8; }

.deals-section-count {
  margin-left: 2px;
  font-size: 11px;
  font-weight: 600;
  background: var(--color-bg, #f8fafc);
  color: var(--color-text-lighter, #94a3b8);
  padding: 1px 8px;
  border-radius: 10px;
  border: 1px solid var(--color-border-light, #e2e8f0);
}

.deals-section-grid {
  /* inherits deals-card-grid layout, just nested */
}

/* Past deals tab – slight visual dim for all cards */
.deals-section-past .deal-card-v2,
.deals-grid-past .deal-card-v2 {
  opacity: 0.8;
  filter: saturate(0.5);
  transition: opacity 0.15s, filter 0.15s;
}

.deals-section-past .deal-card-v2:hover,
.deals-grid-past .deal-card-v2:hover {
  opacity: 1;
  filter: saturate(1);
}

/* Legacy .btn-icon.reactivate / .deactivate kept for compatibility */
.btn-icon.reactivate,
.btn-icon.deactivate {
  display: none; /* superseded by .deal-action-btn */
}

/* ===== Deal modal – store label row ===== */
.deal-store-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
}

.btn-apply-all-stores {
  font-size: 12px;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: 8px;
  border: 1.5px solid #10b981;
  color: #10b981;
  background: transparent;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}

.btn-apply-all-stores:hover {
  background: #10b981;
  color: white;
}

/* ===== Scanner Page ===== */
.scanner-page {
  padding: 24px;
  max-width: 1200px;
}
.scanner-page-header h2 {
  margin: 0 0 4px;
  font-size: 22px;
  font-weight: 700;
}
.scanner-subtitle {
  margin: 0 0 24px;
  color: var(--color-text-muted, #888);
  font-size: 14px;
}
.scanner-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
@media (max-width: 768px) {
  .scanner-layout {
    grid-template-columns: 1fr;
  }
}

/* Camera panel */
.scanner-camera-panel {
  background: var(--color-card-bg, #fff);
  border-radius: 14px;
  border: 1px solid var(--color-border-light, #eee);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.scanner-controls {
  padding: 16px;
  display: flex;
  gap: 10px;
}
.scanner-start-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
}
.btn-danger {
  background: #e53e3e;
  color: #fff;
  border: none;
}
.btn-danger:hover {
  background: #c53030;
}
.scanner-reader {
  width: 100%;
  min-height: 300px;
  background: #111;
}
.scanner-reader video {
  border-radius: 0 !important;
}
/* hide the default file-scan UI from html5-qrcode */
#scanner-reader__dashboard_section,
#scanner-reader__dashboard_section_csr,
#scanner-reader__header_message {
  display: none !important;
}
.scanner-status {
  padding: 12px 16px;
  font-size: 13px;
  color: var(--color-text-muted, #888);
  border-top: 1px solid var(--color-border-light, #eee);
  text-align: center;
}
.scanner-status.active {
  color: #10b981;
  font-weight: 500;
}

/* Results panel */
.scanner-results-panel {
  background: var(--color-card-bg, #fff);
  border-radius: 14px;
  border: 1px solid var(--color-border-light, #eee);
  display: flex;
  flex-direction: column;
  max-height: 520px;
}
.scanner-results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px;
  border-bottom: 1px solid var(--color-border-light, #eee);
}
.scanner-results-header h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
}
.scanner-results-list {
  flex: 1;
  overflow-y: auto;
  padding: 12px;
}
.scanner-empty {
  text-align: center;
  padding: 40px 16px;
  color: var(--color-text-muted, #888);
  font-size: 14px;
}

/* Result cards */
.scanner-result-card {
  padding: 12px 14px;
  border-radius: 10px;
  margin-bottom: 8px;
  border: 1px solid var(--color-border-light, #eee);
  transition: box-shadow 0.15s;
}
.scanner-result-card:first-child {
  animation: scanPulse 0.3s ease;
}
@keyframes scanPulse {
  0% { transform: scale(0.97); opacity: 0.5; }
  100% { transform: scale(1); opacity: 1; }
}
.scanner-result-card.found {
  border-left: 3px solid #10b981;
}
.scanner-result-card.not-found {
  border-left: 3px solid #e53e3e;
  background: rgba(229,62,62,0.04);
}
.scanner-result-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}
.scanner-result-name {
  font-weight: 600;
  font-size: 14px;
}
.scanner-result-price {
  font-weight: 700;
  color: #10b981;
  font-size: 14px;
}
.scanner-result-details {
  display: flex;
  gap: 12px;
  font-size: 12px;
  color: var(--color-text-muted, #888);
}
.scanner-result-barcode {
  font-family: 'SF Mono', 'Fira Code', monospace;
}
.scanner-result-stock {
  margin-top: 6px;
  font-size: 12px;
  color: var(--color-text-muted, #888);
}
.scanner-result-stock strong {
  color: var(--color-text, #333);
}

/* ============================================================================
   Transfer Product Search Dropdown
   ============================================================================ */
.transfer-product-results {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 50;
  background: var(--color-card-bg, #fff);
  border: 1px solid var(--color-border-light, #e5e7eb);
  border-radius: 8px;
  max-height: 220px;
  overflow-y: auto;
  box-shadow: 0 4px 16px rgba(0,0,0,0.10);
  margin-top: 2px;
}
.transfer-product-result {
  padding: 9px 12px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  transition: background 0.1s;
}
.transfer-product-result:hover {
  background: var(--color-bg-secondary, #f3f4f6);
}
.transfer-product-result + .transfer-product-result {
  border-top: 1px solid var(--color-border-light, #f0f0f0);
}
.transfer-product-result-name {
  font-size: 13px;
  font-weight: 500;
  color: var(--color-text, #111);
}
.transfer-product-result-meta {
  font-size: 11px;
  color: var(--color-text-muted, #999);
  white-space: nowrap;
}
.transfer-product-no-results {
  padding: 12px;
  text-align: center;
  font-size: 13px;
  color: var(--color-text-muted, #999);
}

/* ============================================================================
   Rewards Settings — Type Toggle & Product Rewards
   ============================================================================ */
.reward-type-toggle {
  display: flex;
  gap: 0;
  border: 1px solid var(--color-border-light, #e5e7eb);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 20px;
}
.reward-type-btn {
  flex: 1;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  cursor: pointer;
  border: none;
  background: var(--color-bg, #fff);
  color: var(--color-text-secondary, #6b7280);
  transition: all 0.15s ease;
}
.reward-type-btn:first-child {
  border-right: 1px solid var(--color-border-light, #e5e7eb);
}
.reward-type-btn.active {
  background: #6B46C1;
  color: #fff;
}
.reward-type-btn:hover:not(.active) {
  background: var(--color-bg-secondary, #f9fafb);
}

/* Product reward list in settings */
.reward-product-add-row {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  align-items: flex-end;
}
.reward-product-add-row .form-group {
  flex: 1;
  margin-bottom: 0;
}
.reward-product-search-results {
  background: var(--color-card-bg, #fff);
  border: 1px solid var(--color-border-light, #e5e7eb);
  border-radius: 8px;
  max-height: 160px;
  overflow-y: auto;
  margin-top: -12px;
  margin-bottom: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}
.reward-product-result {
  padding: 8px 12px;
  cursor: pointer;
  font-size: 13px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: background 0.1s;
}
.reward-product-result:hover {
  background: var(--color-bg-secondary, #f3f4f6);
}
.reward-product-result + .reward-product-result {
  border-top: 1px solid var(--color-border-light, #f0f0f0);
}
.reward-products-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.reward-product-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border: 1px solid var(--color-border-light, #e5e7eb);
  border-radius: 10px;
  background: var(--color-bg, #fff);
}
.reward-product-info {
  flex: 1;
}
.reward-product-info .rpi-name {
  font-weight: 600;
  font-size: 13px;
  color: var(--color-text, #111);
}
.reward-product-info .rpi-details {
  font-size: 12px;
  color: var(--color-text-secondary, #6b7280);
  margin-top: 2px;
}
.reward-product-cost {
  font-weight: 700;
  font-size: 14px;
  color: #d97706;
  margin: 0 12px;
  white-space: nowrap;
}
.reward-product-remove {
  background: none;
  border: none;
  color: #ef4444;
  cursor: pointer;
  font-size: 16px;
  padding: 4px 8px;
  border-radius: 6px;
  transition: background 0.1s;
}
.reward-product-remove:hover {
  background: rgba(239,68,68,0.08);
}

/* ===== Card Readers ===== */
.reader-branch-group { margin-bottom: 24px; }
.reader-branch-title {
  font-size: 14px; font-weight: 700; color: #334155;
  margin: 0 0 10px; padding-bottom: 6px;
  border-bottom: 2px solid #e2e8f0;
}
.reader-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.reader-card {
  background: white; border: 1px solid #e2e8f0; border-radius: 12px;
  padding: 16px; transition: box-shadow 0.2s;
}
.reader-card:hover { box-shadow: 0 2px 8px rgba(0,0,0,0.08); }
.reader-card.reader-inactive { opacity: 0.6; }
.reader-card-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.reader-card-name { font-weight: 700; font-size: 14px; color: #1e293b; }
.reader-status-badge {
  font-size: 11px; font-weight: 600; padding: 2px 8px; border-radius: 10px;
}
.reader-status-badge.active { background: #dcfce7; color: #16a34a; }
.reader-status-badge.inactive { background: #fee2e2; color: #dc2626; }
.reader-card-details { margin-bottom: 10px; }
.reader-detail { font-size: 12px; color: #64748b; margin-bottom: 3px; }
.reader-detail .label { font-weight: 600; color: #475569; }
.reader-card-actions { display: flex; gap: 8px; border-top: 1px solid #f1f5f9; padding-top: 10px; }

/* ===== Attendance Tab ===== */
.attendance-filters { margin-bottom: 16px; }
.attendance-filters .form-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; }
.attendance-filters .form-group { flex: 1; min-width: 140px; }
.att-summary {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 16px;
}
.att-stat {
  background: white; border: 1px solid #e2e8f0; border-radius: 10px;
  padding: 14px; text-align: center;
}
.att-stat-value { display: block; font-size: 24px; font-weight: 700; color: #1e293b; }
.att-stat-label { font-size: 11px; color: #94a3b8; text-transform: uppercase; letter-spacing: 0.05em; }
.att-table { width: 100%; }
.att-table th { font-size: 11px; text-transform: uppercase; letter-spacing: 0.05em; color: #94a3b8; }
.att-table td { font-size: 13px; }
.att-status {
  font-size: 11px; font-weight: 600; padding: 2px 8px; border-radius: 10px;
}
.att-status-completed { background: #f0f9ff; color: #3b82f6; }
.att-status-active { background: #dcfce7; color: #16a34a; }
.role-badge {
  font-size: 11px; font-weight: 600; padding: 2px 8px; border-radius: 10px;
  background: #f1f5f9; color: #64748b;
}
.role-badge.role-admin { background: #fef3c7; color: #d97706; }
.role-badge.role-manager { background: #e0e7ff; color: #4f46e5; }
.role-badge.role-cashier { background: #dcfce7; color: #16a34a; }
.role-badge.role-staff { background: #f1f5f9; color: #64748b; }

/* ===== Tax Info Banner ===== */
.tax-info-banner {
  background: #eff6ff; border: 1px solid #bfdbfe; border-radius: 10px;
  padding: 14px 18px; margin-bottom: 18px;
}
.tax-info-banner strong { font-size: 14px; color: #1e40af; display: block; margin-bottom: 4px; }
.tax-info-banner p { font-size: 12px; color: #3b82f6; margin: 0; }

/* ===== Vendor Cards ===== */
.vendor-cards {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 16px;
}
.vendor-card {
  background: #fff; border: 1px solid #e2e8f0; border-radius: 12px; padding: 16px;
  transition: box-shadow 0.15s;
}
.vendor-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.08); }
.vendor-card-header { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.vendor-avatar {
  width: 40px; height: 40px; border-radius: 10px; background: #6366f1; color: #fff;
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 16px;
}
.vendor-card-info { flex: 1; min-width: 0; }
.vendor-card-name { font-weight: 700; font-size: 15px; color: #1e293b; }
.vendor-card-contact { font-size: 12px; color: #94a3b8; }
.vendor-card-details { display: flex; flex-direction: column; gap: 4px; margin-bottom: 12px; }
.vendor-detail-row { font-size: 13px; color: #64748b; }
.vendor-detail-row a { color: #3b82f6; text-decoration: none; }
.vendor-card-actions { display: flex; gap: 8px; align-items: center; border-top: 1px solid #f1f5f9; padding-top: 12px; }
.vendor-search-bar { margin-bottom: 16px; }

/* ===== Expense Filters & Summary ===== */
.expense-filters {
  display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 16px;
}
.expense-summary-bar {
  display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 16px;
}
.expense-summary-bar .att-stat {
  flex: 1; min-width: 120px;
}

/* ===== Refund Modal ===== */
.refund-modal-header {
  display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px;
  padding-bottom: 12px; border-bottom: 1px solid #e2e8f0;
}
.refund-modal-header h3 { margin: 0; font-size: 16px; }
.refund-items-table { width: 100%; margin-bottom: 16px; }
.refund-items-table th {
  font-size: 11px; text-transform: uppercase; color: #94a3b8; padding: 6px 8px;
  text-align: left; border-bottom: 1px solid #e2e8f0;
}
.refund-items-table td { padding: 8px; font-size: 13px; border-bottom: 1px solid #f1f5f9; }
.refund-items-table input[type="number"] {
  width: 60px; padding: 4px 6px; border: 1px solid #d1d5db; border-radius: 6px;
  text-align: center;
}
.refund-total-bar {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 16px; background: #fef2f2; border-radius: 8px; margin-bottom: 16px;
}
.refund-total-bar .refund-total-amount { font-size: 20px; font-weight: 700; color: #dc2626; }
.refund-reason-input {
  width: 100%; padding: 8px 12px; border: 1px solid #d1d5db; border-radius: 8px;
  margin-bottom: 16px; font-size: 14px;
}

/* ===== Age Verification Gate ===== */
.age-gate-modal {
  text-align: center; padding: 8px 0;
}
.age-gate-icon { font-size: 48px; margin-bottom: 12px; }
.age-gate-items {
  background: #fef3c7; border-radius: 8px; padding: 12px 16px; margin: 16px 0;
  text-align: left;
}
.age-gate-items li { font-size: 13px; color: #92400e; padding: 2px 0; }
.age-gate-actions { display: flex; gap: 12px; justify-content: center; margin-top: 20px; }
.age-gate-actions .btn-verify {
  background: #16a34a; color: #fff; border: none; padding: 10px 20px;
  border-radius: 8px; font-size: 14px; font-weight: 600; cursor: pointer;
}
.age-gate-actions .btn-verify:hover { background: #15803d; }

/* ===== Hold/Recall ===== */
.held-orders-list { max-height: 400px; overflow-y: auto; }
.held-order-card {
  border: 1px solid #e2e8f0; border-radius: 10px; padding: 12px 16px; margin-bottom: 10px;
  display: flex; justify-content: space-between; align-items: center;
  background: #fff;
}
.held-order-info { flex: 1; }
.held-order-info .held-time { font-size: 12px; color: #94a3b8; }
.held-order-info .held-customer { font-weight: 600; font-size: 14px; color: #1e293b; }
.held-order-info .held-summary { font-size: 12px; color: #64748b; margin-top: 2px; }
.held-order-info .held-note { font-size: 11px; color: #f59e0b; font-style: italic; margin-top: 2px; }
.held-order-total { font-size: 18px; font-weight: 700; color: #1e293b; margin: 0 16px; }
.held-order-actions { display: flex; gap: 6px; }

/* ===== Customer Purchase History ===== */
.purchase-history-modal { max-height: 500px; overflow-y: auto; }
.purchase-top-products {
  display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; padding-bottom: 16px;
  border-bottom: 1px solid #e2e8f0;
}
.top-product-chip {
  background: #f1f5f9; border-radius: 20px; padding: 6px 12px; font-size: 12px;
  color: #475569; display: flex; align-items: center; gap: 4px;
}
.top-product-chip .top-prod-qty {
  background: #3b82f6; color: #fff; border-radius: 10px; padding: 0 6px;
  font-size: 10px; font-weight: 700;
}
.purchase-history-item {
  border: 1px solid #f1f5f9; border-radius: 8px; padding: 10px 14px; margin-bottom: 8px;
  display: flex; justify-content: space-between; align-items: center;
}
.purchase-history-item:hover { background: #f8fafc; }
.ph-info { flex: 1; }
.ph-date { font-size: 12px; color: #94a3b8; }
.ph-items-preview { font-size: 12px; color: #64748b; margin-top: 2px; }
.ph-total { font-size: 15px; font-weight: 700; color: #1e293b; margin: 0 12px; }
.ph-reorder-btn {
  background: none; border: 1px solid #e2e8f0; border-radius: 6px; padding: 4px 10px;
  font-size: 12px; cursor: pointer; color: #3b82f6;
}
.ph-reorder-btn:hover { background: #eff6ff; }

/* ===== Audit Log ===== */
.audit-action-badge {
  display: inline-flex; align-items: center; gap: 4px; font-size: 11px;
  font-weight: 600; padding: 2px 8px; border-radius: 10px;
  background: #f1f5f9; color: #64748b;
}

/* ===== Form Grid (used by expense/vendor forms) ===== */
.form-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 16px;
}
@media (max-width: 500px) {
  .form-grid { grid-template-columns: 1fr; }
}

/* ===== Refund Badge ===== */
.invoice-badge-refund {
  background: #fef2f2; color: #dc2626; font-size: 11px; font-weight: 600;
  padding: 2px 8px; border-radius: 10px;
}

/* ===== Delivery Cards & Statuses ===== */
.delivery-card { border-left: 3px solid var(--primary); }
.delivery-card .card-header { border-bottom: 1px solid var(--border); padding: 10px 12px; }
.delivery-card .card-body { font-size: 0.85rem; }
.delivery-status-badge { display: inline-block; font-size: 0.7rem; font-weight: 600; padding: 2px 10px; border-radius: 12px; color: #fff; }
.card-grid-3 { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.tab-bar { display: flex; gap: 0; border-bottom: 2px solid var(--border); margin-bottom: 16px; }
.tab-btn { background: none; border: none; padding: 10px 20px; cursor: pointer; font-size: 0.9rem; font-weight: 500; color: var(--text-muted); border-bottom: 2px solid transparent; margin-bottom: -2px; transition: all 0.15s; }
.tab-btn:hover { color: var(--text); }
.tab-btn.active { color: var(--primary); border-bottom-color: var(--primary); }
.toggle-label { display: flex; align-items: center; gap: 8px; cursor: pointer; }
.toggle-label input[type="checkbox"] { width: 18px; height: 18px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-grid { display: flex; flex-direction: column; gap: 12px; }
.status-pill { display: inline-block; padding: 2px 8px; border-radius: 10px; font-size: 0.7rem; font-weight: 600; background: #f1f5f9; color: #64748b; }
.status-pill.status-dropped_off { background: #dcfce7; color: #16a34a; }
.status-pill.status-cancelled { background: #fef2f2; color: #dc2626; }
.status-pill.status-returned { background: #fef2f2; color: #dc2626; }
.status-pill.status-picked_up { background: #fef9c3; color: #ca8a04; }
.status-pill.status-dasher_confirmed { background: #dbeafe; color: #2563eb; }
.status-pill.status-created { background: #f1f5f9; color: #64748b; }
.btn-sm { padding: 4px 10px; font-size: 0.75rem; }
.btn-danger { background: #ef4444; color: #fff; border: none; cursor: pointer; border-radius: 6px; }
.btn-danger:hover { background: #dc2626; }
@media (max-width: 768px) {
  .card-grid-3 { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
}

/* ===== Cash Counting Page ===== */
.cash-kpi-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin-bottom: 20px; }
.cash-kpi { background: var(--bg-secondary, #f8fafc); border: 1px solid var(--border, #e2e8f0); border-radius: 10px; padding: 16px; text-align: center; }
.cash-kpi-label { font-size: 0.75rem; color: var(--text-muted, #94a3b8); margin-bottom: 4px; text-transform: uppercase; letter-spacing: 0.5px; }
.cash-kpi-value { font-size: 1.4rem; font-weight: 700; }
.cash-section { margin-bottom: 24px; }
.cash-section h3 { font-size: 1rem; font-weight: 600; margin-bottom: 10px; }
