/* ============================================================
   VENUE DASHBOARD
   ============================================================ */

body { background: radial-gradient(ellipse 100% 40% at 50% 0%, rgba(216,179,106,0.06), transparent 60%), var(--black); min-height: 100vh; }

.v-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--sp-4) var(--sp-5);
  border-bottom: 1px solid rgba(244,232,209,0.08);
  position: sticky;
  top: 0;
  background: rgba(11,9,8,0.85);
  backdrop-filter: blur(16px);
  z-index: 80;
  flex-wrap: wrap;
  gap: var(--sp-3);
}
.v-header-left { display: flex; align-items: center; gap: var(--sp-3); }
.v-logo { width: 36px; height: 36px; object-fit: contain; }
.v-venue-name { font-size: 22px; }
.v-date { font-size: 12px; }
.v-header-right { display: flex; gap: 8px; flex-wrap: wrap; }

.v-main {
  max-width: 1280px;
  margin: 0 auto;
  padding: var(--sp-5);
  display: flex;
  flex-direction: column;
  gap: var(--sp-5);
}

.v-footer {
  max-width: 1280px;
  margin: 0 auto;
  padding: var(--sp-5);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

/* ---------- Stat cards ---------- */
.stat-cards-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: var(--sp-3); }
@media (max-width: 860px) { .stat-cards-grid { grid-template-columns: repeat(2, 1fr); } }
.v-stat-card { padding: var(--sp-4); position: relative; overflow: hidden; }
.v-stat-card .vs-label { font-size: 12px; color: var(--cream-faint); text-transform: uppercase; letter-spacing: 0.06em; }
.v-stat-card .vs-value { font-family: 'Cormorant Garamond', serif; font-size: 40px; color: var(--gold); margin-top: 6px; }
.v-stat-card .vs-sub { font-size: 12px; color: var(--cream-faint); margin-top: 4px; }

/* ---------- Section layout ---------- */
.v-grid-2 { display: grid; grid-template-columns: 2fr 1fr; gap: var(--sp-5); align-items: start; }
.v-grid-2 > * { min-width: 0; }
@media (max-width: 980px) { .v-grid-2 { grid-template-columns: 1fr; } }

.flex-col { min-width: 0; }
.v-section { padding: var(--sp-4) var(--sp-4) var(--sp-5); min-width: 0; }
.v-section-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: var(--sp-3); flex-wrap: wrap; gap: 8px; }
.v-section-head h3 { font-size: 20px; }

/* ---------- Tables ---------- */
.v-table-wrap { overflow-x: auto; }
table.v-table { width: 100%; border-collapse: collapse; font-size: 13.5px; min-width: 560px; }
table.v-table th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--cream-faint); padding: 8px 10px; border-bottom: 1px solid rgba(244,232,209,0.1); }
table.v-table td { padding: 12px 10px; border-bottom: 1px solid rgba(244,232,209,0.05); vertical-align: middle; }
table.v-table tr:last-child td { border-bottom: none; }
.guest-cell { display: flex; align-items: center; gap: 10px; }
.mini-avatar { width: 32px; height: 32px; border-radius: 50%; background: linear-gradient(135deg, var(--gold-dim), var(--emerald)); display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; color: #0B0908; flex-shrink: 0; }
.timer-cell { font-variant-numeric: tabular-nums; font-weight: 600; color: var(--gold); }
.status-pill { display: inline-flex; align-items: center; gap: 5px; padding: 4px 10px; border-radius: var(--r-full); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; }
.status-pill.checked_in { background: rgba(216,179,106,0.14); color: var(--gold); }
.status-pill.phone_stored { background: rgba(216,179,106,0.14); color: var(--gold); }
.status-pill.active { background: rgba(31,75,67,0.35); color: #7FD4BC; }
.status-pill.reserved { background: rgba(244,232,209,0.08); color: var(--cream-dim); }
.status-pill.completed { background: rgba(244,232,209,0.06); color: var(--cream-faint); }
.row-actions { display: flex; gap: 6px; flex-wrap: wrap; }

.empty-row { padding: var(--sp-5); text-align: center; color: var(--cream-faint); font-size: 13px; }

/* ---------- Phone inventory ---------- */
.pouch-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.pouch-slot {
  aspect-ratio: 1;
  border-radius: var(--r-sm);
  border: 1px solid rgba(244,232,209,0.1);
  background: var(--surface-2);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  font-size: 10px;
  color: var(--cream-faint);
  text-align: center;
  padding: 4px;
  transition: all var(--t-fast) var(--ease);
}
.pouch-slot.occupied { background: rgba(216,179,106,0.1); border-color: rgba(216,179,106,0.4); color: var(--gold); }
.pouch-slot .ps-icon { font-size: 16px; }
.pouch-slot .ps-name { font-size: 9px; line-height: 1.2; word-break: break-word; }

/* ---------- Emergency ---------- */
.emg-banner {
  background: linear-gradient(90deg, var(--oxblood), var(--oxblood-bright));
  color: #FBEAE7;
  padding: 14px var(--sp-5);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-3);
  flex-wrap: wrap;
  animation: emgSlide 400ms var(--ease);
  position: sticky;
  top: 0;
  z-index: 90;
}
@keyframes emgSlide { from { transform: translateY(-100%); } to { transform: translateY(0); } }
.emg-banner .eb-text { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; }
.emg-banner .eb-actions { display: flex; gap: 8px; }
.emg-banner.acked { background: linear-gradient(90deg, #2b2321, #332824); color: var(--cream-dim); }

.emg-trigger-card { display: flex; flex-direction: column; gap: var(--sp-3); }

/* ---------- Analytics ---------- */
.chart-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-4); }
@media (max-width: 700px) { .chart-row { grid-template-columns: 1fr; } }
.chart-box { padding: var(--sp-4); }
.chart-box h4 { font-size: 15px; margin-bottom: var(--sp-3); }
.bar-chart { display: flex; align-items: flex-end; gap: 8px; height: 120px; }
.bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; justify-content: flex-end; height: 100%; }
.bar-fill { width: 100%; border-radius: 4px 4px 0 0; background: linear-gradient(180deg, var(--gold), var(--gold-dim)); }
.bar-col .bar-label { font-size: 10px; color: var(--cream-faint); }
.bar-col.today .bar-fill { background: linear-gradient(180deg, #E4C27E, var(--gold)); box-shadow: 0 0 12px rgba(216,179,106,0.4); }

/* ---------- Scan overlay ---------- */
.scan-modal {
  position: fixed; inset: 0; background: rgba(0,0,0,0.7); backdrop-filter: blur(6px);
  display: flex; align-items: center; justify-content: center; z-index: 500;
  animation: fadeIn 200ms ease;
}
.scan-card {
  background: var(--surface-2); border: 1px solid rgba(216,179,106,0.3); border-radius: var(--r-lg);
  padding: var(--sp-6); text-align: center; width: 320px; box-shadow: var(--shadow-lift);
}
.scan-ring {
  width: 96px; height: 96px; margin: 0 auto var(--sp-4);
  border-radius: 50%; border: 3px solid rgba(216,179,106,0.2); border-top-color: var(--gold);
  animation: spin 1s linear infinite;
}
.scan-check {
  width: 96px; height: 96px; margin: 0 auto var(--sp-4); border-radius: 50%;
  background: rgba(31,75,67,0.3); border: 1px solid var(--emerald-bright);
  display: flex; align-items: center; justify-content: center; font-size: 40px; color: #7FD4BC;
  animation: modalPop 400ms var(--ease);
}

/* ---------- Events management ---------- */
.event-mgmt-row { display: flex; gap: var(--sp-3); align-items: center; padding: 12px 0; border-bottom: 1px solid rgba(244,232,209,0.06); }
.event-mgmt-row:last-child { border-bottom: none; }
.event-mgmt-row .em-img { width: 52px; height: 52px; border-radius: 10px; background-size: cover; background-position: center; flex-shrink: 0; }
.event-mgmt-row .em-body { flex: 1; min-width: 0; }
.event-mgmt-row h4 { font-size: 15px; }
.event-mgmt-row .em-meta { font-size: 12px; color: var(--cream-faint); margin-top: 2px; }
.seats-bar { width: 100px; height: 6px; border-radius: 3px; background: rgba(244,232,209,0.1); overflow: hidden; flex-shrink: 0; }
.seats-bar-fill { height: 100%; background: var(--gold); }
