/* ============================
   Calendar (FullCalendar)
============================ */
:root {
  --leefhub-calendar-event-bg: var(--lh-primary, #e52d8f);
  --leefhub-calendar-event-hover: var(--lh-primary-hover, #c0277d);
  --leefhub-calendar-event-text: var(--lh-primary-text, #ffffff);
}

/* Calendar container sizing */
#leefhub-calendar {
  width: 100%;
  max-width: 1100px;
  margin: 2rem auto;
  overflow: visible !important;
  height: auto !important;
  min-height: 500px;
  display: block !important;
  position: relative;
}

/* Fix squished height / mobile overlapping */
.fc-scroller {
  overflow: visible !important;
  height: auto !important;
}
.fc-daygrid-body {
  min-height: 400px !important;
}

/* Hide the small time/graphic bar in list view */
.fc-list-event-graphic {
  display: none !important;
}

/* Hide the default time column in list view */
.fc-list-event-time {
  display: none !important;
}

/* Align title nicely after removing the left columns */
.fc-list-event-title {
  padding-left: 0 !important;
}

/* 🎨 Clean up the all-day row background (keep all-day events visible) */
#leefhub-calendar .fc-timegrid-all-day,
#leefhub-calendar .fc-timegrid-divider {
  background: transparent !important;   /* remove the gray/white fill */
  border: none !important;              /* remove the dividing line */
  height: auto !important;
  min-height: auto !important;
  margin: 0 !important;
  padding: 0 !important;
}

/* Adjust the top of the grid for smooth continuity */
#leefhub-calendar .fc-timegrid-slot-label,
#leefhub-calendar .fc-timegrid-slots {
  border-top: none !important;
}

/* Optional: visually merge all-day area with the times below */
#leefhub-calendar .fc-scrollgrid-sync-inner {
  background: transparent !important;
}

/* Optional: give all-day events a soft divider if needed */
#leefhub-calendar .fc-timegrid-all-day .fc-daygrid-day {
  border-bottom: 1px solid rgba(0,0,0,0.05);
}

/* ============================
   CLEAN MODERN EVENT PILL STYLE
============================ */
.fc-event {
  background: var(--leefhub-calendar-event-bg, #e52d8f) !important;
  color: var(--leefhub-calendar-event-text, #ffffff) !important;
  border: none !important;
  border-radius: 10px !important;

  padding: 8px 10px !important;
  margin: 4px 0 !important;

  display: flex;
  flex-direction: column;
  align-items: flex-start;

  box-shadow: 0 2px 6px rgba(0,0,0,0.12);
  transition: 0.2s ease;
  font-size: 0.85rem;
  line-height: 1.3;

  text-overflow: ellipsis;
  white-space: normal !important;
  overflow: hidden !important;
}

.fc-event:hover {
  background: var(--leefhub-calendar-event-hover, #c0277d) !important;
  transform: translateY(-2px);
}

/* Title */
.fc-event .event-title {
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 3px;
  text-align: left;
  width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Time */
.fc-event .event-time {
  font-size: 0.8rem;
  opacity: 0.9;
}

/* ============================
   FullCalendar Toolbar Buttons
============================ */

/* General toolbar layout */
.fc-toolbar.fc-header-toolbar {
  display: flex !important;
  flex-wrap: wrap !important;
  justify-content: space-between !important;
  align-items: center !important;
  gap: 0.75rem !important;
  margin-bottom: 1.5rem !important;
  padding: 6px 2px;
}

/* Title styling */
.fc-toolbar-title {
  font-size: 1.25rem !important;
  font-weight: 600 !important;
  text-align: center;
}

/* Left chunk (prev/next/today buttons) */
.fc .fc-toolbar-chunk:first-child {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

/* Button group (month/list/week) */
.fc .fc-button-group {
  display: flex;
  gap: 0.4rem;
}

/* Buttons */
.fc .fc-button {
  background: var(--leefhub-calendar-event-bg, #0073aa) !important;
  color: var(--leefhub-calendar-event-text, #ffffff) !important;
  border: none !important;
  border-radius: 6px !important;
  padding: 6px 12px !important;
  font-size: 0.9rem !important;
  font-weight: 500 !important;
  transition: background 0.2s ease, transform 0.15s ease;
  box-shadow: none !important;
  margin: 0 2px !important;
}

/* Active and hover states */
.fc .fc-button:hover,
.fc .fc-button.fc-button-active {
  background: var(--leefhub-calendar-event-hover, #005f8d) !important;
  color: #fff !important;
  transform: translateY(-1px);
}

/* Disabled button */
.fc .fc-button:disabled {
  background: #ccc !important;
  color: #666 !important;
  cursor: not-allowed;
}

/* Mobile-friendly toolbar layout */
@media (max-width: 600px) {
  .fc-toolbar.fc-header-toolbar {
    flex-direction: column;
    align-items: stretch !important;
    gap: 0.75rem;
  }

  .fc-toolbar-chunk {
    width: 100%;
    text-align: center;
  }

  .fc-toolbar-chunk:first-child {
    justify-content: center;
  }

  .fc-button {
    flex: 1;
    min-width: 90px;
  }
}

/* ============================
   Tooltip
============================ */
.leefhub-tooltip-content {
  text-align: center;
  padding: 12px 16px;
}
.leefhub-tooltip-content h4 {
  margin: 0 0 4px;
  font-size: 16px;
}
.leefhub-tooltip-content p {
  margin: 0 0 10px;
  font-size: 14px;
}
.leefhub-tooltip-content button {
  background: var(--lh-primary, #e52d8f);
  color: #fff !important;
  border: none;
  padding: 8px 16px;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.15s ease;
}
.leefhub-tooltip-content button:hover {
  background: var(--lh-primary-hover, #c0277d);
  transform: translateY(-1px);
}
.tippy-box[data-theme~='light-border'] {
  background: var(--lh-surface, #f9f9f9);
  color: var(--lh-text, #222);
  border: 1px solid var(--lh-border, #e0e0e0);
  box-shadow: var(--lh-shadow, 0 2px 6px rgba(0,0,0,0.05));
}

/* ============================
   Loader Overlay
============================ */
/* #leefhub-calendar-loader {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.85);
  z-index: 9999;
  backdrop-filter: blur(3px);
}
#leefhub-calendar-loader .spinner {
  border: 5px solid #e0e0e0;
  border-top: 5px solid #fc36e7;
  border-radius: 50%;
  width: 56px;
  height: 56px;
  animation: leefhub-spin 0.9s linear infinite;
}
@keyframes leefhub-spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
} */

/* ============================
   Event Cards (List/Grid view)
============================ */
.leefhub-events-grid {
  display: block;
  margin: 2rem 0;
}
.leefhub-card.leef-event {
  border: 1px solid #ddd;
  border-radius: 8px;
  background: #fff;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
  margin-bottom: 20px;
}
.leefhub-card.leef-event:last-child { margin-bottom: 0; }
.leefhub-card-body { padding: 16px; }
.leefhub-card-title {
  margin: 0 0 8px;
  font-size: 1.1rem;
}
.leefhub-card-time {
  color: #666;
  margin: 0;
}
.leefhub-card-footer {
  border-top: 1px solid #eee;
  padding: 12px 16px;
  text-align: right;
}

/* ============================
   Call-to-action Buttons
============================ */
.leefhub-card-button,
.leefhub-book-btn {
  background: var(--leefhub-shortcode-btn-bg, #0073aa);
  color: var(--leefhub-shortcode-btn-text, #fff);
  border: none;
  border-radius: 6px;
  padding: 10px 16px;
  font-size: 1rem;
  font-weight: 600;
  display: inline-block;
  text-align: center;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
  text-decoration: none;
}
.leefhub-card-button:hover,
.leefhub-book-btn:hover {
  background: var(--leefhub-shortcode-btn-hover, #005f8d);
  text-decoration: none;
}

/* ============================
   Booking Form
============================ */
.leefhub-booking-form {
  max-width: 700px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
  padding: 40px;
  font-size: 17px;
  line-height: 1.6;
  color: #333;
}
.leefhub-booking-title {
  font-size: 26px;
  font-weight: 600;
  margin-bottom: 10px;
}
.leefhub-booking-time {
  font-size: 18px;
  margin-bottom: 20px;
  color: #666;
}
.leefhub-booking-user {
  background: #f8f8f8;
  border-radius: 6px;
  padding: 12px 15px;
  margin-bottom: 25px;
  font-size: 16px;
}
.leefhub-form-row {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 30px;
}
.leefhub-form-row label {
  font-weight: 600;
  font-size: 18px;
}
.leefhub-form-row input {
  width: 90px;
  font-size: 18px;
  padding: 6px 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
}

/* ============================================
   Booking Form Buttons (Global Calendar Colors)
============================================ */
.leefhub-btn,
.leefhub-book-btn {
  background: var(--leefhub-calendar-event-bg);
  color: var(--leefhub-calendar-event-text);
  border: none;
  border-radius: 8px;
  padding: 12px 20px;
  font-size: 1rem;
  font-weight: 600;
  display: inline-block;
  text-align: center;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.15s ease;
  text-decoration: none;
  width: 100%;
  box-sizing: border-box;
}
.leefhub-btn:hover,
.leefhub-book-btn:hover {
  background: var(--leefhub-calendar-event-hover);
  color: var(--leefhub-calendar-event-text);
  transform: translateY(-1px);
}

/* ============================
   My Bookings List
============================ */
.leefhub-bookings-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.leefhub-booking-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid #eee;
}
.leefhub-booking-item:last-child { border-bottom: none; }
.leefhub-booking-details {
  display: flex;
  flex-direction: column;
}
.leefhub-booking-title {
  font-weight: 600;
  margin-bottom: 4px;
}
.leefhub-booking-time,
.leefhub-booking-seats {
  font-size: 0.9rem;
  color: #666;
}

/* ============================
   Status Badges
============================ */
.leefhub-badge {
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 600;
  color: #fff;
  min-width: 80px;
  text-align: center;
}
.leefhub-status-confirmed { background: #2e8540; }
.leefhub-status-pending   { background: #e0a800; }
.leefhub-status-cancelled { background: #dc3545; }

/* ============================
   Button Row
============================ */
.leefhub-button-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.leefhub-button-row .leefhub-form {
  flex: 1;
  margin: 0;
}
.leefhub-button-row .leefhub-book-btn {
  width: 100%;
}

/* ============================
   Responsive Adjustments
============================ */
@media (max-width: 1024px) {
  #leefhub-calendar { min-height: 450px; }
}
@media (max-width: 768px) {
  #leefhub-calendar { min-height: 600px !important; width: 95%; }
  .fc-toolbar-title { font-size: 1rem !important; text-align: center; flex: 1 1 100%; }
  .fc-timeGridWeek-button, .fc-timeGridDay-button { display: none !important; }
  .leefhub-booking-form { padding: 25px; }
}
@media (max-width: 480px) {
  #leefhub-calendar { min-height: 650px !important; }
  .fc-button { font-size: 0.8rem !important; padding: 4px 8px !important; }
  .leefhub-booking-form { padding: 20px; }
}

/* Ensure first time slot (12am) sits flush to top */
#leefhub-calendar .fc-timegrid-slots {
  margin-top: 0 !important;
}

/* Booking form field sizing */
.leefhub-form-row input[type="text"],
.leefhub-form-row input[type="email"] {
  width: 100%;
  max-width: 480px;
  box-sizing: border-box;
}
.leefhub-form-row { margin-bottom: 14px; }

/* Keep the single-seat input narrow and disabled look */
#leef-seats[readonly] {
  max-width: 80px;
  background-color: #f9f9f9;
  cursor: not-allowed;
}

.entry-content tr td {
    border-top: 1px solid #eee;
    padding: 6px 10px !important;
}