/* ==========================================================================
   Venue Rental & Booking - Frontend Styles
   Ported from the standalone form, namespaced with vrb- prefixes so it does
   not collide with the active theme's styles.
   ========================================================================== */

.vrb-booking-root {
  --vrb-primary: #078599;
  --vrb-primary-light: #0a9cb2;
  --vrb-secondary: #A81010;
  --vrb-slate: #333333;
  --vrb-glass: rgba(255, 255, 255, 0.9);
  --vrb-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
  --vrb-font-main: 'Inter', sans-serif;
  --vrb-font-heading: 'Outfit', sans-serif;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
  color: var(--vrb-slate);
  font-family: var(--vrb-font-main);
  line-height: 1.4;
  font-size: 0.9rem;
  box-sizing: border-box;
}

.vrb-booking-root * {
  box-sizing: border-box;
}

/* Layout grid */
.vrb-booking-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 40px;
  padding-top: 40px;
  padding-bottom: 80px;
}

@media (max-width: 900px) {
  .vrb-booking-grid {
    grid-template-columns: 1fr;
  }
}

/* Glass cards */
.vrb-glass {
  background: var(--vrb-glass);
  backdrop-filter: blur(15px);
  border-radius: 20px;
  padding: 25px;
  box-shadow: var(--vrb-shadow);
  border: 1px solid rgba(255, 255, 255, 0.4);
}

.vrb-calendar-card h4 {
  font-family: var(--vrb-font-heading);
  font-size: 1.1rem;
  color: var(--vrb-primary);
  border-bottom: 2px solid var(--vrb-secondary);
  display: inline-block;
  padding-bottom: 5px;
  margin-bottom: 15px;
}

/* Form title */
.vrb-form-card h3 {
  font-family: var(--vrb-font-heading);
  margin-bottom: 30px;
  color: var(--vrb-primary);
  font-weight: 700;
  border-bottom: 2px solid var(--vrb-secondary);
  padding-bottom: 10px;
  display: inline-block;
}

/* Inputs */
.vrb-input-group {
  margin-bottom: 15px;
}

.vrb-input-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}

.vrb-booking-root label {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  margin-bottom: 5px;
  color: var(--vrb-slate);
  text-transform: uppercase;
  letter-spacing: 0.2px;
}

.vrb-time-pair {
  display: flex;
  gap: 0.5rem;
}

.vrb-booking-root input,
.vrb-booking-root select,
.vrb-booking-root textarea {
  width: 100%;
  padding: 9px 12px;
  border-radius: 8px;
  border: 1px solid #ddd;
  font-family: var(--vrb-font-main);
  font-size: 0.9rem;
  transition: all 0.2s ease;
  background: #fff;
  color: var(--vrb-slate);
}

.vrb-time-pair input {
  flex: 1;
}

.vrb-booking-root input:focus,
.vrb-booking-root select:focus,
.vrb-booking-root textarea:focus {
  outline: none;
  border-color: var(--vrb-primary);
  box-shadow: 0 0 0 3px rgba(7, 133, 153, 0.1);
}

/* Checkboxes */
.vrb-checkbox-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: #f9f9f9;
  padding: 15px;
  border-radius: 10px;
}

.vrb-checkbox-group label {
  display: flex;
  align-items: center;
  gap: 10px;
  text-transform: none;
  font-weight: 400;
  cursor: pointer;
}

.vrb-checkbox-group input,
.vrb-checkbox-inline input {
  width: auto;
}

.vrb-checkbox-inline {
  display: flex;
  align-items: center;
  gap: 10px;
  text-transform: none !important;
  font-weight: 400 !important;
  cursor: pointer;
  font-size: 0.9rem !important;
}

/* Summary box */
.vrb-summary-box {
  background: #f4f6f8;
  border-radius: 12px;
  padding: 20px;
  margin: 25px 0;
}

.vrb-summary-line {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 0.95rem;
}

.vrb-summary-line.total {
  justify-content: center;
  border-top: 1px solid #ddd;
  padding-top: 20px;
  margin-top: 5px;
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--vrb-primary);
}

.vrb-error-text {
  color: var(--vrb-secondary) !important;
  justify-content: center;
}

/* Buttons */
.vrb-primary-btn {
  width: 100%;
  margin-top: 25px;
  padding: 15px;
  background: var(--vrb-primary);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s, background 0.2s;
  font-family: var(--vrb-font-main);
}

.vrb-primary-btn:hover {
  background: var(--vrb-primary-light);
  transform: translateY(-2px);
}

.vrb-primary-btn:active {
  transform: translateY(0);
}

.vrb-primary-btn:disabled {
  background: #999;
  cursor: not-allowed;
  opacity: 0.7;
}

/* Layout preview section */
.vrb-layout-section {
  display: grid;
  grid-template-columns: 1fr 120px;
  gap: 15px;
  align-items: end;
  margin-bottom: 15px;
}

.vrb-preview-box {
  width: 120px;
  height: 90px;
  background: #fff;
  border: 2px solid var(--vrb-secondary);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  cursor: pointer;
  transition: transform 0.2s;
}

.vrb-preview-box:hover {
  transform: scale(1.05);
}

.vrb-preview-box img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #fdfdfd;
}

/* Dynamic pricing info */
.vrb-pricing-info {
  background: rgba(7, 133, 153, 0.05);
  padding: 15px 20px;
  border-left: 4px solid var(--vrb-primary);
  border-radius: 8px;
  font-size: 0.88rem;
  margin-bottom: 20px;
  margin-top: -5px;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.02);
}

.vrb-pricing-info strong {
  color: var(--vrb-primary);
  display: block;
  margin-bottom: 8px;
  font-size: 1rem;
  font-family: var(--vrb-font-heading);
}

.vrb-pricing-info ul {
  list-style-type: none;
  padding-left: 0;
}

.vrb-pricing-info li {
  margin-bottom: 6px;
  line-height: 1.4;
  position: relative;
  padding-left: 15px;
  color: var(--vrb-slate);
}

.vrb-pricing-info li:before {
  content: "•";
  position: absolute;
  left: 0;
  color: var(--vrb-secondary);
  font-weight: bold;
}

/* Active date input highlight */
.vrb-active-date-input {
  border: 2px solid var(--vrb-primary) !important;
  background-color: rgba(7, 133, 153, 0.05) !important;
  box-shadow: 0 0 8px rgba(7, 133, 153, 0.3) !important;
}

/* Form footer */
.vrb-form-footer {
  text-align: center;
  font-size: 0.8rem;
  color: #666;
  margin-top: 25px;
  border-top: 1px solid #eee;
  padding-top: 15px;
  width: 100%;
}

.vrb-divider {
  border: none;
  border-top: 1px solid #eee;
  margin: 20px 0;
}

/* Utility */
.vrb-hidden {
  display: none !important;
}

.vrb-fade-in {
  animation: vrbFadeIn 0.4s ease;
}

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

/* Calendar overrides */
.vrb-booking-root .fc,
#vrb-calendar {
  min-height: 500px;
  background: #fff;
  padding: 15px;
  border-radius: 12px;
}

#vrb-calendar .fc-toolbar-title {
  font-size: 1.25rem;
  font-family: var(--vrb-font-heading);
}

#vrb-calendar .fc-button-primary {
  background: var(--vrb-primary);
  border: none;
}

#vrb-calendar .fc-daygrid-day.fc-day-today {
  background: rgba(7, 133, 153, 0.1);
}

#vrb-calendar .fc-bg-event {
  opacity: 0.85 !important;
}

#vrb-calendar .fc-bg-event .fc-event-title {
  color: #fff !important;
  font-weight: 700 !important;
  font-size: 0.95rem !important;
  padding: 4px;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

/* Calendar legend */
.vrb-calendar-legend {
  display: flex;
  gap: 20px;
  margin-top: 20px;
  font-size: 0.85rem;
}

.vrb-legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
}

.vrb-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}

.vrb-dot.vrb-pending {
  background: #ffcc00;
}

.vrb-dot.vrb-confirmed {
  background: var(--vrb-primary);
}

/* Calendar tooltip */
.vrb-calendar-tooltip {
  position: absolute;
  background: #333;
  color: #fff;
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 0.8rem;
  z-index: 99998;
  opacity: 0;
  transition: opacity 0.2s;
  pointer-events: none;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.vrb-calendar-tooltip.visible {
  opacity: 1;
}

/* Lightbox modal */
.vrb-modal {
  display: none;
  position: fixed;
  z-index: 10000;
  padding-top: 50px;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(5px);
}

.vrb-modal-content {
  margin: auto;
  display: block;
  max-width: 90%;
  max-height: 80vh;
  border-radius: 10px;
  border: 5px solid white;
}

.vrb-close {
  position: absolute;
  top: 15px;
  right: 35px;
  color: #f1f1f1;
  font-size: 40px;
  font-weight: bold;
  transition: 0.3s;
  cursor: pointer;
}

.vrb-close:hover {
  color: var(--vrb-secondary);
}

/* Toast notifications */
.vrb-toast-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.vrb-toast {
  background: #121212;
  color: white;
  padding: 15px 20px;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  border-left: 5px solid var(--vrb-secondary);
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-width: 300px;
  transition: opacity 0.3s ease;
}

.vrb-toast-success {
  border-left-color: #2e8b57;
}

.vrb-toast-close {
  background: none;
  border: none;
  color: white;
  font-size: 1.2rem;
  cursor: pointer;
  margin-left: 15px;
  opacity: 0.7;
}

.vrb-toast-close:hover {
  opacity: 1;
}

/* Mobile adjustments */
@media (max-width: 600px) {
  #vrb-calendar .fc-toolbar.fc-header-toolbar {
    flex-direction: column;
    gap: 15px;
  }

  #vrb-calendar .fc-toolbar-title {
    font-size: 1.1rem;
  }

  #vrb-calendar .fc-bg-event .fc-event-title {
    font-size: 0.7rem !important;
    padding: 1px 2px;
    white-space: normal;
    line-height: 1.2;
  }

  #vrb-calendar {
    min-height: 400px;
    padding: 10px;
  }
}
