/* =========================================================
   THE PLAYGROUND PICKLEBALL - LUXURY SPORTS RESORT DESIGN SYSTEM
   Palette Inspired by Official Brand Emblem:
   - Deep Midnight Navy: #07172C, #0B2545, #132E52
   - Metallic Prestige Gold: #D4AF37, #C5A059, #F5E8BE, #A6801C
   - Electric Court Cerulean: #0284C7, #0096C7, #38BDF8, #E0F2FE
   - Pickleball Neon Lime: #CCFF00, #D4F71E, #A3E635
   - Clean Slate Canvas: #F8FAFC, #FFFFFF, #E2E8F0
========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;800;900&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=Cinzel:wght@600;700;800&display=swap');

:root {
  /* Brand Navy */
  --navy-950: #040d1a;
  --navy-900: #07172C;
  --navy-800: #0B2545;
  --navy-700: #13335e;
  --navy-600: #1d457b;
  --navy-500: #2a5a9e;

  /* Brand Metallic Gold */
  --gold-500: #D4AF37;
  --gold-400: #E5C365;
  --gold-600: #B8860B;
  --gold-700: #936B07;
  --gold-light: #FFF9E6;
  --gold-glow: rgba(212, 175, 55, 0.35);

  /* Electric Court Cerulean */
  --court-blue: #0284C7;
  --court-blue-dark: #0369A1;
  --court-blue-light: #E0F2FE;
  --court-blue-glow: rgba(2, 132, 199, 0.3);

  /* Pickleball Neon Lime */
  --lime-neon: #CCFF00;
  --lime-dark: #84CC16;
  --lime-soft: #F4FDE8;

  /* Surface & Canvas */
  --bg-canvas: #F8FAFC;
  --bg-card: #FFFFFF;
  --text-main: #0B2545;
  --text-muted: #64748B;
  --border-subtle: #E2E8F0;
  --border-focus: #D4AF37;

  /* Fonts */
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: 'Outfit', sans-serif;
  --font-brand: 'Cinzel', serif;
}

body {
  font-family: var(--font-sans);
  color: var(--text-main);
  background-color: var(--bg-canvas);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, .font-display {
  font-family: var(--font-display);
}

.brand-font {
  font-family: var(--font-brand);
  letter-spacing: 0.05em;
}

/* =========================================================
   Navbar & Header Brand Styling
========================================================= */
.navbar-custom {
  background: linear-gradient(180deg, rgba(7, 23, 44, 0.98) 0%, rgba(11, 37, 69, 0.98) 100%);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(212, 175, 55, 0.25);
  box-shadow: 0 4px 25px rgba(0, 0, 0, 0.25);
}

.brand-logo-ring {
  border: 2px solid var(--gold-500);
  border-radius: 10px;
  object-fit: contain;
  background: #ffffff;
  box-shadow: 0 0 12px var(--gold-glow);
  transition: transform 0.3s ease;
}

.brand-logo-ring:hover {
  transform: scale(1.05);
}

.gold-gradient-text {
  background: linear-gradient(135deg, #FFF0B3 0%, #D4AF37 50%, #B8860B 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.gold-badge {
  background: linear-gradient(135deg, #13335e 0%, #0B2545 100%);
  border: 1px solid var(--gold-500);
  color: #FFF0B3;
  box-shadow: 0 2px 8px rgba(212, 175, 55, 0.2);
}

/* =========================================================
   Venue Hero & Stats Card (Courtogo-Inspired Architecture)
========================================================= */
.venue-header-banner {
  background: radial-gradient(circle at top right, rgba(2, 132, 199, 0.12), transparent 50%),
              radial-gradient(circle at bottom left, rgba(212, 175, 55, 0.08), transparent 50%),
              linear-gradient(180deg, #FFFFFF 0%, #F8FAFC 100%);
  border-bottom: 1px solid var(--border-subtle);
}

.venue-avatar-wrap {
  position: relative;
  width: 135px;
  height: 90px;
  border-radius: 14px;
  padding: 4px;
  background: #ffffff;
  border: 2px solid var(--gold-400);
  box-shadow: 0 8px 24px rgba(11, 37, 69, 0.12), 0 0 14px var(--gold-glow);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.venue-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 10px;
  background: #ffffff;
}

.verified-icon {
  color: var(--gold-500);
  filter: drop-shadow(0 2px 4px rgba(212, 175, 55, 0.4));
}

/* Quick Stat Pill Grid */
.stat-pill-group {
  display: inline-grid;
  grid-template-columns: repeat(3, 1fr);
  background: #ffffff;
  border: 1px solid rgba(212, 175, 55, 0.3);
  border-radius: 16px;
  box-shadow: 0 4px 15px rgba(11, 37, 69, 0.06);
  overflow: hidden;
}

.stat-pill-cell {
  padding: 10px 18px;
  border-right: 1px solid var(--border-subtle);
  transition: background-color 0.2s ease;
}

.stat-pill-cell:last-child {
  border-right: none;
}

.stat-pill-cell:hover {
  background-color: var(--gold-light);
}

.stat-pill-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 5px;
}

.stat-pill-value {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 800;
  color: var(--navy-800);
  margin-top: 2px;
}

/* =========================================================
   Courtogo-Style Tab Navigation
========================================================= */
.courtogo-tabs-bar {
  display: flex;
  align-items: center;
  gap: 2px;
  background: #ffffff;
  overflow-x: auto;
  white-space: nowrap;
  scrollbar-width: none;
  min-width: 0;
}

.courtogo-tabs-bar::-webkit-scrollbar {
  display: none;
}

.courtogo-tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 12px 12px;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-muted);
  background: transparent;
  border: none;
  border-bottom: 3px solid transparent;
  margin-bottom: -1px;
  transition: all 0.2s ease;
  cursor: pointer;
  border-radius: 8px 8px 0 0;
  flex-shrink: 0;
}

.courtogo-tab-btn:hover {
  color: var(--navy-800);
  background: rgba(11, 37, 69, 0.03);
}

.courtogo-tab-btn.active {
  color: var(--navy-800);
  border-bottom-color: var(--gold-500);
  background: linear-gradient(180deg, rgba(212, 175, 55, 0.06) 0%, transparent 100%);
}

.courtogo-tab-badge {
  font-size: 11px;
  padding: 2px 7px;
  border-radius: 20px;
  background: rgba(11, 37, 69, 0.08);
  color: var(--navy-800);
  font-weight: 700;
}

.courtogo-tab-btn.active .courtogo-tab-badge {
  background: var(--navy-800);
  color: #FFF0B3;
}

/* =========================================================
   Interactive Multi-Court Schedule Matrix
========================================================= */
.matrix-card {
  background: #ffffff;
  border-radius: 20px;
  border: 1px solid var(--border-subtle);
  box-shadow: 0 10px 30px rgba(11, 37, 69, 0.06);
  overflow: hidden;
}

.matrix-date-toolbar {
  background: #ffffff;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-subtle);
}

.matrix-toolbar-row {
  width: 100%;
}

/* Minimalist Unified Date Stepper */
.matrix-date-stepper {
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  border-radius: 9999px;
  padding: 3px 6px;
  display: inline-flex;
  align-items: center;
  transition: all 0.2s ease;
}

.matrix-date-stepper:hover {
  background: #F1F5F9;
  border-color: #CBD5E1;
}

.date-stepper-btn {
  background: transparent;
  border: none;
  color: var(--navy-800);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.15s ease;
  padding: 0;
  flex-shrink: 0;
}

.date-stepper-btn:hover {
  background: rgba(11, 37, 69, 0.08);
  color: var(--navy-900);
}

.date-stepper-btn:active {
  transform: scale(0.92);
}

.date-stepper-label {
  background: transparent;
  border: none;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 800;
  color: var(--navy-800);
  padding: 4px 10px;
  cursor: pointer;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  user-select: none;
}

.date-stepper-label:hover {
  color: var(--court-blue);
}

/* Minimalist Quick Actions */
.matrix-toolbar-actions {
  display: inline-flex;
  align-items: center;
}

.matrix-action-pill {
  background: #ffffff;
  border: 1.5px solid #CBD5E1;
  color: var(--navy-800);
  font-size: 12px;
  font-weight: 700;
  border-radius: 9999px;
  padding: 5px 14px;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
  line-height: 1.2;
}

.matrix-action-pill:hover {
  background: var(--navy-800);
  color: #ffffff;
  border-color: var(--navy-800);
}

.matrix-action-icon {
  background: #ffffff;
  border: 1.5px solid #CBD5E1;
  color: var(--navy-800);
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.15s ease;
  padding: 0;
  flex-shrink: 0;
}

.matrix-action-icon:hover {
  background: #0B2545;
  color: #ffffff;
  border-color: #0B2545;
}

/* Backward compatibility aliases */
.matrix-date-btn {
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  color: var(--navy-800);
  font-weight: 700;
  border-radius: 12px;
  padding: 8px 14px;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
}

.matrix-date-btn:hover {
  border-color: var(--gold-500);
  background: var(--gold-light);
  color: var(--navy-800);
  box-shadow: 0 2px 8px rgba(212, 175, 55, 0.15);
}

.matrix-date-center-btn {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 800;
  color: var(--navy-800);
}

/* Status Legend */
.matrix-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
  flex-shrink: 0;
}

.legend-swatch {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  flex-shrink: 0;
}

.legend-open {
  background: #FFFFFF;
  border: 1.5px solid #CBD5E1;
}

.legend-selected {
  background: #D4AF37;
  border: 1.5px solid #936B07;
  box-shadow: 0 0 6px rgba(212, 175, 55, 0.4);
}

.legend-taken {
  background: #0B2545;
  border: 1.5px solid #07172C;
}

.legend-pending {
  background: #FEF3C7;
  border: 1.5px solid #F59E0B;
}

.legend-verifying {
  background: #EFF6FF;
  border: 1.5px solid #3B82F6;
}

.legend-blocked {
  background: #F1F5F9;
  border: 1.5px solid #CBD5E1;
}

/* Matrix Table Viewport */
.schedule-matrix-wrapper {
  overflow-x: auto;
  position: relative;
  background: #ffffff;
  scrollbar-width: thin;
  scrollbar-color: var(--gold-500) var(--border-subtle);
}

.matrix-table {
  width: 100%;
  min-width: 680px;
  border-collapse: separate;
  border-spacing: 0;
}

/* Headers */
.matrix-header-cell {
  background: linear-gradient(180deg, #F8FAFC 0%, #EEF2F6 100%);
  border-bottom: 2px solid var(--border-subtle);
  border-right: 1px solid var(--border-subtle);
  padding: 12px 10px;
  text-align: center;
  position: sticky;
  top: 0;
  z-index: 20;
}

.matrix-header-court-title {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 800;
  color: var(--navy-800);
  display: block;
}

.matrix-header-court-rate {
  font-size: 12px;
  font-weight: 700;
  color: var(--court-blue);
  background: var(--court-blue-light);
  padding: 2px 8px;
  border-radius: 12px;
  display: inline-block;
  margin-top: 2px;
}

/* Sticky Time Column */
.matrix-time-header {
  position: sticky;
  left: 0;
  z-index: 30;
  background: #0B2545 !important;
  color: #FFF0B3;
  width: 100px;
  min-width: 95px;
  border-right: 2px solid var(--gold-500) !important;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.matrix-time-cell {
  position: sticky;
  left: 0;
  z-index: 10;
  background: #F8FAFC;
  border-right: 2px solid rgba(11, 37, 69, 0.15);
  border-bottom: 1px solid var(--border-subtle);
  padding: 8px 10px;
  font-size: 12px;
  font-weight: 700;
  color: var(--navy-800);
  text-align: center;
  height: 52px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Slot Cell States */
.matrix-slot-cell {
  border-right: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  height: 52px;
  padding: 4px;
  text-align: center;
  transition: all 0.15s ease;
  user-select: none;
}

.slot-inner {
  width: 100%;
  height: 100%;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  line-height: 1.15;
  padding: 2px 4px;
  transition: all 0.18s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.slot-inner span {
  font-size: 11px;
  font-weight: 700;
  line-height: 1.1;
  display: block;
}

.slot-inner::after {
  display: block;
  font-size: 9.5px;
  line-height: 1.1;
  margin-top: 1px;
  white-space: nowrap;
}

/* 1. AVAILABLE */
.matrix-slot-cell.state-available {
  cursor: pointer;
}

.matrix-slot-cell.state-available .slot-inner {
  background: #ffffff;
  border: 1px solid #CBD5E1;
  color: #334155;
}

.matrix-slot-cell.state-available:hover .slot-inner {
  background: #E0F2FE;
  border-color: var(--court-blue);
  color: var(--court-blue-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(2, 132, 199, 0.15);
}

/* 2. SELECTED */
.matrix-slot-cell.state-selected .slot-inner {
  background: linear-gradient(135deg, #D4AF37 0%, #B8860B 100%);
  border: 1.5px solid #F5E8BE;
  color: #07172C;
  font-weight: 800;
  box-shadow: 0 4px 14px rgba(212, 175, 55, 0.45);
  transform: scale(0.98);
}

.matrix-slot-cell.state-selected .slot-inner::after {
  content: "✓ Selected";
  font-size: 10px;
  color: #07172C;
  font-weight: 900;
}

/* 3. BOOKED / TAKEN */
.matrix-slot-cell.state-booked {
  cursor: not-allowed;
}

.matrix-slot-cell.state-booked .slot-inner {
  background: linear-gradient(135deg, #07172C 0%, #0B2545 100%);
  border: 1px solid #13335e;
  color: #E2E8F0;
  opacity: 0.95;
}

.matrix-slot-cell.state-booked .slot-inner::after {
  content: "Taken";
  font-size: 10px;
  color: #93C5FD;
  font-weight: 700;
}

/* 4. PROCESSING / AWAITING PAYMENT */
.matrix-slot-cell.state-processing {
  cursor: not-allowed;
}

.matrix-slot-cell.state-processing.is-my-slot {
  cursor: pointer;
}

.matrix-slot-cell.state-processing .slot-inner {
  background: #FEF3C7;
  border: 1.5px dashed #F59E0B;
  color: #B45309;
}

.matrix-slot-cell.state-processing .slot-inner::after {
  content: "Awaiting Pay";
  font-size: 10px;
  color: #B45309;
}

.matrix-slot-cell.state-processing.is-my-slot .slot-inner::after {
  content: "Your Hold · Pay";
  font-size: 9.5px;
  font-weight: 800;
  color: #92400E;
}

/* 5. VERIFYING / AWAITING ADMIN CONFIRMATION */
.matrix-slot-cell.state-verifying {
  cursor: not-allowed;
}

.matrix-slot-cell.state-verifying.is-my-slot {
  cursor: pointer;
}

.matrix-slot-cell.state-verifying .slot-inner {
  background: #EFF6FF;
  border: 1.5px solid #3B82F6;
  color: #1D4ED8;
}

.matrix-slot-cell.state-verifying .slot-inner::after {
  content: "Verifying";
  font-size: 10px;
  color: #2563EB;
  font-weight: 700;
}

.matrix-slot-cell.state-verifying.is-my-slot .slot-inner::after {
  content: "Yours · Verifying";
  font-size: 9.5px;
  color: #1E40AF;
  font-weight: 800;
}

.matrix-slot-cell.state-verifying:hover .slot-inner {
  border-color: #1D4ED8;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.25);
}

/* 6. BLOCKED / FACILITY MAINTENANCE */
.matrix-slot-cell.state-blocked {
  cursor: not-allowed;
}

.matrix-slot-cell.state-blocked .slot-inner {
  background: #F1F5F9;
  border: 1.5px solid #CBD5E1;
  color: #64748B;
  opacity: 0.95;
}

.matrix-slot-cell.state-blocked .slot-inner span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 800;
  color: #DC2626;
}

/* Facility Closed Day Highlight in Calendar */
.calendar-day-cell.is-closed-day {
  background: #FEF2F2 !important;
  border-color: #FECACA !important;
  opacity: 0.95;
}

.calendar-day-cell.is-closed-day .calendar-day-number {
  color: #DC2626 !important;
}

/* Open Play Day & Slot Highlights in Calendar & Matrix */
.badge-open-play {
  background: linear-gradient(135deg, #0284C7 0%, #0369A1 100%) !important;
  color: #ffffff !important;
  font-weight: 800 !important;
  letter-spacing: 0.2px;
  box-shadow: 0 2px 6px rgba(2, 132, 199, 0.3);
}

.calendar-day-cell.is-open-play {
  background: #F0F9FF !important;
  border-color: #BAE6FD !important;
  cursor: pointer !important;
  opacity: 1 !important;
}

.calendar-day-cell.is-open-play:hover {
  background: #E0F2FE !important;
  border-color: #0284C7 !important;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(2, 132, 199, 0.18);
}

.calendar-day-cell.is-open-play .calendar-day-number {
  color: #0369A1 !important;
}

.matrix-slot-cell.is-open-play-slot .slot-inner {
  background: #F0F9FF !important;
  border: 1.5px solid #38BDF8 !important;
  color: #0369A1 !important;
}

.matrix-slot-cell.is-open-play-slot .slot-inner span {
  color: #0284C7 !important;
  font-weight: 800 !important;
}

.matrix-slot-cell.is-reserved-slot .slot-inner {
  background: #FFFBEB !important;
  border: 1.5px solid #FCD34D !important;
  color: #B45309 !important;
}

.matrix-slot-cell.is-reserved-slot .slot-inner span {
  color: #D97706 !important;
  font-weight: 800 !important;
}

/* =========================================================
   Floating Sticky Bottom Booking Action Rail
========================================================= */
.floating-booking-rail {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(7, 23, 44, 0.95);
  backdrop-filter: blur(14px);
  border-top: 2px solid var(--gold-500);
  box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.35);
  z-index: 1040;
  padding: 12px 20px;
  transform: translateY(120%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.floating-booking-rail.is-visible {
  transform: translateY(0);
}

.rail-summary-pill {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  padding: 6px 14px;
  color: #ffffff;
  transition: all 0.2s ease;
}

.rail-summary-pill:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.35);
}

.rail-table-btn {
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #ffffff !important;
  border-radius: 9999px;
  padding: 3px 10px;
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
  text-decoration: none;
}

.rail-table-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  border-color: rgba(255, 255, 255, 0.5);
  color: #ffffff !important;
}

.rail-table-btn.is-active {
  background: var(--gold-500);
  border-color: var(--gold-400);
  color: #0B2545 !important;
}

.selected-slots-drawer {
  width: 100%;
  animation: slideUpDrawer 0.22s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes slideUpDrawer {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.drawer-slot-row {
  transition: background-color 0.15s ease;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.drawer-slot-row:hover {
  background-color: rgba(255, 255, 255, 0.07);
}

.drawer-remove-btn {
  color: #f87171;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.25);
  padding: 3px 8px;
  border-radius: 8px;
  font-size: 11px;
  transition: all 0.15s ease;
  cursor: pointer;
}

.drawer-remove-btn:hover {
  background: rgba(239, 68, 68, 0.25);
  color: #ef4444;
  transform: scale(1.05);
}

#tab-content-book {
  padding-bottom: 95px;
}

.rail-price-tag {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 800;
  color: var(--lime-neon);
}

.btn-book-now-gold {
  background: linear-gradient(135deg, #D4AF37 0%, #C5A059 100%);
  color: #07172C;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 15px;
  border: none;
  padding: 10px 24px;
  border-radius: 30px;
  box-shadow: 0 4px 15px rgba(212, 175, 55, 0.4);
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-book-now-gold:hover {
  background: linear-gradient(135deg, #FFF0B3 0%, #D4AF37 100%);
  color: #040d1a;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(212, 175, 55, 0.6);
}

/* =========================================================
   Luxury Checkout Modal
========================================================= */
.modal-checkout-header {
  background: linear-gradient(135deg, var(--navy-900) 0%, var(--navy-800) 100%);
  color: #ffffff;
  border-bottom: 2px solid var(--gold-500);
}

.checkout-summary-box {
  background: var(--gold-light);
  border: 1px solid rgba(212, 175, 55, 0.35);
  border-radius: 14px;
  padding: 14px 18px;
}

/* =========================================================
   Facility Amenities Cards ("About" Tab)
========================================================= */
.amenity-card {
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-radius: 16px;
  padding: 20px;
  transition: all 0.25s ease;
  height: 100%;
}

.amenity-card:hover {
  border-color: var(--gold-500);
  transform: translateY(-4px);
  box-shadow: 0 12px 25px rgba(11, 37, 69, 0.08);
}

.amenity-icon-circle {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(11, 37, 69, 0.08) 0%, rgba(2, 132, 199, 0.1) 100%);
  color: var(--navy-800);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  margin-bottom: 12px;
}

/* =========================================================
   Photo Gallery Grid ("Photos" Tab)
========================================================= */
.gallery-photo-card {
  border-radius: 16px;
  overflow: hidden;
  position: relative;
  background: #0B2545;
  box-shadow: 0 8px 24px rgba(11, 37, 69, 0.12);
  cursor: pointer;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease;
}

.gallery-photo-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 32px rgba(11, 37, 69, 0.22);
}

.gallery-photo-card img {
  width: 100%;
  height: 290px;
  object-fit: cover;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), filter 0.3s ease;
}

.gallery-photo-card:hover img {
  transform: scale(1.04);
}

.gallery-photo-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(7, 23, 44, 0.92) 100%);
  color: #ffffff;
  padding: 24px 16px 14px;
  font-size: 13.5px;
  font-weight: 700;
}

/* =========================================================
   Mobile Optimization
========================================================= */
@media (max-width: 768px) {
  /* Prevent iOS automatic zoom on text input focus */
  input[type="text"],
  input[type="email"],
  input[type="tel"],
  input[type="date"],
  select,
  textarea {
    font-size: 16px !important;
  }

  /* Add clearance at the bottom of the page so the floating rail doesn't cover content */
  .venue-tab-pane {
    padding-bottom: calc(90px + env(safe-area-inset-bottom, 20px));
  }

  .schedule-matrix-wrapper {
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
  }

  .courtogo-tabs-bar {
    -webkit-overflow-scrolling: touch;
  }

  .venue-header-banner {
    padding-top: 14px !important;
    padding-bottom: 10px !important;
  }

  .venue-avatar-wrap {
    width: 58px !important;
    height: 58px !important;
    border-radius: 12px !important;
    border: 1.5px solid var(--gold-400) !important;
    box-shadow: 0 4px 12px rgba(11, 37, 69, 0.08) !important;
    padding: 2px !important;
    flex-shrink: 0;
  }

  .venue-header-banner h1 {
    font-size: 1.25rem !important;
    line-height: 1.2 !important;
    letter-spacing: -0.01em;
  }

  .venue-header-banner p {
    font-size: 11.5px !important;
  }

  .stat-pill-group {
    width: 100% !important;
    border-radius: 12px !important;
    margin-top: 6px !important;
    box-shadow: 0 2px 8px rgba(11, 37, 69, 0.04) !important;
    border: 1px solid rgba(11, 37, 69, 0.08) !important;
  }

  .stat-pill-cell {
    padding: 6px 6px !important;
    text-align: center;
  }

  .stat-pill-label {
    font-size: 8px !important;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    color: #64748B;
  }

  .stat-pill-value {
    font-size: 12px !important;
    font-weight: 800;
    color: var(--navy-800);
  }

  .matrix-date-toolbar {
    padding: 10px;
  }

  .matrix-date-center-btn {
    min-width: 150px;
    font-size: 13px;
    padding: 6px 10px;
  }

  .matrix-header-cell {
    padding: 8px 4px;
    min-width: 120px;
  }

  .matrix-header-court-title {
    font-size: 13px;
  }

  .matrix-header-court-rate {
    font-size: 10px;
    padding: 1px 6px;
  }

  .matrix-slot-cell {
    height: 48px;
  }

  /* Matrix Legend Scrollability on Mobile (Single Line) */
  .matrix-legend-row {
    max-width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    flex-wrap: nowrap !important;
  }

  .matrix-legend-row::-webkit-scrollbar {
    display: none;
  }

  /* Minimalist Date Toolbar on mobile - strictly single-line, zero wrapping */
  .matrix-date-toolbar {
    padding: 8px 10px;
  }

  .matrix-toolbar-row {
    flex-wrap: nowrap !important;
  }

  .matrix-date-stepper {
    padding: 2px 4px;
    background: #F1F5F9;
  }

  .date-stepper-btn {
    width: 28px;
    height: 28px;
    font-size: 11.5px;
  }

  .date-stepper-label {
    font-size: 12px;
    font-weight: 800;
    padding: 2px 6px;
  }

  .matrix-action-pill {
    font-size: 11px;
    padding: 4px 10px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .matrix-action-icon {
    width: 28px;
    height: 28px;
    font-size: 11.5px;
  }

  .matrix-date-btn {
    padding: 6px 10px;
    min-height: 32px;
    font-size: 12px;
  }

  .matrix-date-center-btn {
    min-width: 0;
    font-size: 12px;
    padding: 4px 8px;
    white-space: nowrap;
  }

  /* Matrix table sizing on mobile - strictly mobile only, accommodates all 4 courts without horizontal scroll */
  .schedule-matrix-wrapper {
    overflow-x: auto;
    width: 100%;
  }

  .matrix-table {
    min-width: 0 !important;
    width: 100% !important;
    table-layout: fixed !important;
  }

  .matrix-time-header {
    width: 48px !important;
    min-width: 44px !important;
    max-width: 50px !important;
    font-size: 9.5px !important;
    letter-spacing: 0.3px;
    padding: 6px 1px !important;
    text-align: center;
  }

  .matrix-time-cell {
    width: 48px !important;
    min-width: 44px !important;
    max-width: 50px !important;
    padding: 2px 1px !important;
    height: 44px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
    text-align: center !important;
  }

  .matrix-time-short {
    font-size: 10px !important;
    font-weight: 800 !important;
    color: var(--navy-800) !important;
    white-space: nowrap !important;
    line-height: 1.1 !important;
    text-align: center !important;
  }

  .matrix-header-cell {
    min-width: 0 !important;
    width: calc((100% - 48px) / 4) !important;
    padding: 5px 1px !important;
    text-align: center;
  }

  .matrix-header-court-title {
    font-size: 11px !important;
    font-weight: 800 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    line-height: 1.1 !important;
  }

  .matrix-header-court-rate {
    font-size: 8px !important;
    font-weight: 700 !important;
    padding: 1px 3px !important;
    border-radius: 6px !important;
    white-space: nowrap !important;
    margin-top: 1px !important;
    display: inline-block;
  }

  .matrix-slot-cell {
    min-width: 0 !important;
    width: calc((100% - 48px) / 4) !important;
    height: 44px !important;
    padding: 2px 1px !important;
  }

  .slot-inner {
    border-radius: 6px !important;
    padding: 2px 1px !important;
    line-height: 1.1 !important;
  }

  .slot-inner span {
    font-size: 10px !important;
    font-weight: 700 !important;
    line-height: 1.1 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    max-width: 100% !important;
  }

  .slot-inner::after {
    font-size: 7.5px !important;
    line-height: 1 !important;
    margin-top: 1px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    max-width: 100% !important;
  }

  .matrix-slot-cell.state-blocked .slot-inner span {
    font-size: 8.5px !important;
  }

  .matrix-slot-cell.state-blocked .slot-inner span i {
    font-size: 8px !important;
    margin-right: 2px !important;
  }

  /* Floating rail docks cleanly above the mobile bottom navigation bar */
  .floating-booking-rail {
    bottom: calc(64px + env(safe-area-inset-bottom, 0px));
    padding: 10px 14px;
    border-bottom: 1px solid rgba(212, 175, 55, 0.35);
  }

  .venue-tab-pane,
  #tab-content-book {
    padding-bottom: calc(155px + env(safe-area-inset-bottom, 20px)) !important;
  }

  /* Selected Slots Drawer on Mobile */
  .selected-slots-drawer {
    margin-bottom: 8px;
  }

  .selected-slots-drawer .card {
    border-radius: 14px !important;
  }

  .drawer-slot-card {
    transition: background-color 0.15s ease;
  }

  .drawer-slot-card:hover {
    background-color: rgba(255, 255, 255, 0.08) !important;
  }

  .selected-slots-drawer .drawer-remove-btn {
    padding: 3px 7px;
    min-width: 28px;
    min-height: 28px;
  }
}

/* =========================================================
   Native-Style Mobile Bottom App Bar (< 768px)
========================================================= */
.mobile-bottom-appbar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: calc(64px + env(safe-area-inset-bottom, 0px));
  padding-bottom: env(safe-area-inset-bottom, 0px);
  background: rgba(11, 37, 69, 0.98);
  backdrop-filter: blur(18px);
  border-top: 1.5px solid rgba(212, 175, 55, 0.45);
  box-shadow: 0 -6px 24px rgba(7, 23, 44, 0.35);
  z-index: 1045;
  display: flex;
  align-items: stretch;
  justify-content: space-around;
  user-select: none;
}

.mobile-appbar-btn {
  flex: 1 1 0;
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.65);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 6px 2px;
  font-size: 10.5px;
  font-weight: 600;
  position: relative;
  transition: color 0.18s ease, transform 0.15s ease;
}

.mobile-appbar-btn i {
  font-size: 19px;
  line-height: 1.1;
  transition: transform 0.18s ease, color 0.18s ease;
}

.mobile-appbar-btn.active {
  color: #FDE047;
  font-weight: 800;
}

.mobile-appbar-btn.active i {
  color: #FDE047;
  transform: translateY(-1px) scale(1.08);
}

.mobile-appbar-btn.active::before {
  content: '';
  position: absolute;
  top: 0;
  width: 28px;
  height: 3px;
  background: var(--gold-400);
  border-radius: 0 0 4px 4px;
}

.mobile-appbar-badge {
  position: absolute;
  top: 4px;
  right: calc(50% - 20px);
  font-size: 9.5px;
  padding: 2px 5px;
  border-radius: 999px;
  font-weight: 800;
  line-height: 1;
}

/* Real-Time Pulse Animation for Socket updates */
@keyframes slotPulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.08); box-shadow: 0 0 15px var(--gold-glow); }
  100% { transform: scale(1); }
}

.slot-just-updated {
  animation: slotPulse 0.8s ease-in-out;
}

/* =========================================================
   Interactive Current-Month Calendar Step (Book Court Tab)
========================================================= */
.month-calendar-card {
  background: #ffffff;
  border-radius: 20px;
  border: 1px solid rgba(11, 37, 69, 0.1);
  box-shadow: 0 12px 32px rgba(11, 37, 69, 0.08);
  overflow: hidden;
  width: 100%;
  max-width: 100%;
}

.month-calendar-header {
  background: linear-gradient(135deg, #0B2545 0%, #134074 100%);
  color: #ffffff;
  padding: 18px 24px;
  border-bottom: 2px solid var(--gold-400);
}

.month-calendar-weekdays {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  background: #F8FAFC;
  border-bottom: 1px solid var(--border-subtle);
  text-align: center;
  padding: 10px 8px;
  font-size: 11.5px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--navy-800);
}

.month-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
  padding: 16px;
  background: #ffffff;
  width: 100%;
  box-sizing: border-box;
}

.calendar-day-cell {
  min-width: 0;
  min-height: 76px;
  border-radius: 14px;
  border: 1.5px solid #E2E8F0;
  background: #ffffff;
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: flex-start;
  cursor: pointer;
  transition: all 0.18s ease;
  position: relative;
  user-select: none;
  text-align: left;
  overflow: hidden;
  box-sizing: border-box;
}

.calendar-day-cell:hover:not(.is-disabled):not(.is-empty) {
  border-color: var(--court-blue);
  background: #F0F9FF;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(2, 132, 199, 0.14);
}

.calendar-day-cell.is-today {
  border-color: var(--gold-500);
  background: #FFFBEB;
}

.calendar-day-cell.is-selected {
  background: linear-gradient(135deg, #0B2545 0%, #134074 100%) !important;
  border-color: var(--gold-400) !important;
  color: #ffffff !important;
  box-shadow: 0 8px 20px rgba(11, 37, 69, 0.25);
}

.calendar-day-cell.is-disabled {
  background: #F8FAFC;
  border-color: #F1F5F9;
  color: #CBD5E1;
  cursor: not-allowed;
  opacity: 0.65;
}

.calendar-day-cell.is-empty {
  background: transparent;
  border-color: transparent;
  cursor: default;
  pointer-events: none;
}

.calendar-day-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 2px;
}

.calendar-day-number {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 800;
  color: var(--navy-800);
  line-height: 1.1;
}

.calendar-day-cell.is-selected .calendar-day-number {
  color: #FDE047;
}

.calendar-day-cell.is-disabled .calendar-day-number {
  color: #94A3B8;
}

.calendar-day-badge {
  font-size: 9px;
  padding: 2px 5px;
  border-radius: 999px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
}

.calendar-day-cta {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--court-blue);
  display: inline-flex;
  align-items: center;
  gap: 2px;
  white-space: nowrap;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

.calendar-day-cta-mobile {
  display: none;
}

.calendar-day-cell.is-selected .calendar-day-cta {
  color: #ffffff;
}

.calendar-day-cell.is-disabled .calendar-day-cta {
  color: #CBD5E1;
  font-weight: 500;
}

@media (max-width: 767.98px) {
  .month-calendar-header {
    padding: 10px 12px;
  }
  .month-calendar-header h4 {
    font-size: 1.15rem !important;
  }
  .month-calendar-weekdays {
    padding: 6px 4px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.05em;
    color: #0B2545;
    background: #F1F5F9;
  }
  .month-calendar-grid {
    gap: 4px;
    padding: 6px 6px 10px 6px;
  }
  .calendar-day-cell {
    min-height: 42px;
    padding: 4px 2px;
    border-radius: 8px;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 1px;
  }
  .calendar-day-top {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1px;
  }
  .calendar-day-number {
    font-size: 13.5px;
    font-weight: 800;
  }
  .calendar-day-badge {
    font-size: 7px;
    padding: 1px 4px;
  }
  .calendar-day-cta-desktop {
    display: none !important;
  }
  .calendar-day-cta-mobile {
    display: inline-block;
    font-size: 8px;
    line-height: 1;
    color: #0284C7;
    font-weight: 700;
  }
  /* Bottom padding so mobile app bar never overlaps content */
  .venue-tab-pane {
    padding-bottom: 95px !important;
  }
}

/* =========================================================
   RESERVATION PAGE COMPACT SLOT BUTTONS
   ========================================================= */
.slot-btn {
  padding: 8px 4px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}
.slot-btn.available {
  background: #FFFFFF;
  border: 1px solid #CBD5E1;
  color: #334155;
}
.slot-btn.available:hover {
  background: #E0F2FE;
  border-color: #0284C7;
  color: #0369A1;
}
.slot-btn.selected {
  background: linear-gradient(135deg, #D4AF37 0%, #B8860B 100%) !important;
  border: 1.5px solid #F5E8BE !important;
  color: #07172C !important;
  font-weight: 800 !important;
  box-shadow: 0 3px 10px rgba(212, 175, 55, 0.4);
}
.slot-btn.booked {
  background: linear-gradient(135deg, #07172C 0%, #0B2545 100%) !important;
  border: 1px solid #13335e !important;
  color: #E2E8F0 !important;
  cursor: not-allowed;
  opacity: 0.95;
}
.slot-btn.booked .opacity-75 {
  color: #93C5FD !important;
  font-weight: 700;
}
.slot-btn.processing {
  background: #FEF3C7;
  border: 1.5px dashed #F59E0B;
  color: #B45309;
  cursor: not-allowed;
}

/* =========================================================
   LUXURY PLAYER MEMBERSHIP PASS CARD
   ========================================================= */
.player-membership-card {
  background: linear-gradient(145deg, #07172C 0%, #0B2545 60%, #13335e 100%);
  border: 1px solid rgba(212, 175, 55, 0.35);
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(7, 23, 44, 0.2), 0 0 18px rgba(212, 175, 55, 0.12);
  color: #ffffff;
  position: relative;
  overflow: hidden;
}

.player-pass-glow {
  position: absolute;
  top: -40px;
  right: -40px;
  width: 150px;
  height: 150px;
  background: radial-gradient(circle, rgba(212, 175, 55, 0.25) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.player-pass-watermark {
  position: absolute;
  right: -10px;
  bottom: -20px;
  font-size: 110px;
  color: rgba(255, 255, 255, 0.03);
  pointer-events: none;
  line-height: 1;
}

.player-pass-brand-badge {
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #D4AF37;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
}

.player-pass-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: linear-gradient(135deg, #D4AF37 0%, #B8860B 100%);
  color: #07172C;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 19px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #F5E8BE;
  box-shadow: 0 4px 12px rgba(212, 175, 55, 0.35);
  flex-shrink: 0;
}

.player-pass-name {
  font-size: 1.25rem;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.player-pass-meta-item {
  font-size: 11.5px;
  color: #CBD5E1;
  display: inline-flex;
  align-items: center;
}

@media (max-width: 575.98px) {
  .player-pass-name {
    font-size: 1.15rem;
  }
  .player-pass-avatar {
    width: 44px;
    height: 44px;
    font-size: 17px;
  }
}



