/* --------------------------------------------------------
   MODERN ROOM-WISE AVAILABILITY CALENDAR (FULL CSS)
   Scoped ONLY to .shb-modern-calendar to avoid theme issues
--------------------------------------------------------- */

.shb-modern-calendar {
  max-width: 420px;
  margin: 0 auto;
  padding: 22px;
  background: #ffffff;
  border-radius: 20px;
  box-shadow: 0 6px 24px rgba(0,0,0,0.07);
  font-family: Inter, sans-serif;
  position: relative;
  box-sizing: border-box;
}

/* Multi-calendar grid wrapper (shortcode: [shb_availability_calendars]) */
.shb-calendars-grid{display:grid;gap:26px;align-items:start;grid-template-columns:repeat(var(--shb-cols, 3), minmax(0,1fr));}
.shb-calendars-grid__item{min-width:0;}
@media (max-width: 1024px){.shb-calendars-grid{grid-template-columns:repeat(2,minmax(0,1fr));}}
@media (max-width: 640px){.shb-calendars-grid{grid-template-columns:1fr;}}


/* --------------------------------------------------------
   ROOM TITLE (Glossy, Centered, Premium)
--------------------------------------------------------- */

.shb-modern-calendar .shb-cal-room-title {
  text-align: center;
  margin: 0 0 20px;
  font-size: 18px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;

  background: linear-gradient(135deg, #0f172a, #2563eb, #22c55e);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;

  text-shadow: 0 0 10px rgba(37, 99, 235, 0.2);
}

.shb-modern-calendar .shb-cal-room-title::after {
  content: "";
  display: block;
  width: 70px;
  height: 3px;
  margin: 10px auto 0;
  border-radius: 999px;
  background: linear-gradient(90deg, #22c55e, #2563eb);
}

/* --------------------------------------------------------
   HEADER (Month + Navigation Arrows)
--------------------------------------------------------- */

.shb-cal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.shb-cal-header button {
  background: #ffffff;
  border: 2px solid #d1d5db;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  cursor: pointer;
  color: #1d4ed8;
  font-size: 20px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: 0.2s ease;
}

.shb-cal-header button:hover {
  border-color: #2563eb;
  background: #eff6ff;
}

.shb-cal-title {
  font-size: 24px;
  font-weight: 700;
  flex-grow: 1;
  text-align: center;
  color: #111827;
}

/* --------------------------------------------------------
   LEGEND
--------------------------------------------------------- */

.shb-cal-legend {
  display: flex;
  justify-content: space-between;
  margin-bottom: 18px;
  font-size: 14px;
  padding: 0 4px;
}

.shb-cal-legend div {
  display: flex;
  align-items: center;
  gap: 8px;
}

.shb-cal-legend .lg {
  width: 16px;
  height: 16px;
  border-radius: 4px;
}

.lg-av { background: #b7f7c4; }  /* Available */
.lg-pa { background: #ffe4a3; }  /* Partial */
.lg-bk { background: #ffb4b4; }  /* Partial */
.shb-day.partial {
  background: #ffe4a3;
  color: #92400e;
}

.shb-day.partial:hover {
  background: #ffd88a;
}

/* Booked */
.lg-sl { background: #8db8ff; }  /* Selected */

/* --------------------------------------------------------
   CALENDAR GRID
--------------------------------------------------------- */

.shb-cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 8px;
}

.shb-day-header {
  text-align: center;
  font-weight: 700;
  font-size: 13px;
  padding: 6px 0;
  color: #374151;
}

/* --------------------------------------------------------
   DAY CELLS
--------------------------------------------------------- */

.shb-day {
  padding: 10px 0;
  text-align: center;
  border-radius: 10px;
  font-size: 14px;
  cursor: pointer;
  background: #f3f4f6;
  color: #374151;
  user-select: none;
  transition: 0.2s ease;
}

/* Empty cell (before month start) */
.shb-day.disabled {
  opacity: 0.35;
  background: #f3f4f6 !important;
  cursor: default;
}

/* Available */
.shb-day.available {
  background: #b7f7c4;
  color: #065f46;
}

.shb-day.available:hover {
  background: #9ef3b1;
}

/* Partial */
.shb-day.partial {
  background: #ffe4a3;
  color: #92400e;
}

.shb-day.partial:hover {
  background: #ffd88a;
}

/* Booked */
.shb-day.booked {
  background: #ffb4b4;
  color: #991b1b;
  cursor: not-allowed;
}

/* Selected */
.shb-day.selected {
  background: #8db8ff;
  color: #1d4ed8;
  font-weight: 700;
  box-shadow: 0 0 0 2px #1d4ed8 inset;
}



/* Range selection states */
.shb-day.in-range {
  background: #dbeafe;
  color: #1d4ed8;
}

.shb-day.range-start,
.shb-day.range-end {
  position: relative;
}

.shb-day.range-start::before,
.shb-day.range-end::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 10px;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.45);
  pointer-events: none;
}

/* Click pulse animation */
.shb-day-pulse {
  transform: scale(1.05);
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.20);
}


/* --------------------------------------------------------
   RESPONSIVE (Mobile)
--------------------------------------------------------- */

@media (max-width: 480px) {
  .shb-modern-calendar {
    max-width: 100%;
    padding: 16px;
  }

  .shb-cal-title {
    font-size: 20px;
  }

  .shb-day {
    padding: 8px 0;
    font-size: 12.5px;
  }

  .shb-day-header {
    font-size: 12px;
  }

  .shb-cal-header button {
    width: 42px;
    height: 42px;
    font-size: 18px;
  }
}
