
/* TMTS HBook Drawer v1.2.2 — Visibility & Transition Fix */
#tmts-hbook-drawer {
  position: fixed;
  top: 0;
  right: -500px; /* hidden by default */
  width: 500px;
  height: 100vh;
  background: #fff;
  color: #000;
  overflow: hidden;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  transition: right 0.4s ease;
  box-shadow: -4px 0 10px rgba(0,0,0,0.1);
}

#tmts-hbook-drawer.open {
  right: 0; /* slides in */
}

.tmts-hb-drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.3);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease;
  z-index: 9999;
}

.tmts-hb-drawer-overlay.active {
  opacity: 1;
  visibility: visible;
}

#tmts-hbook-drawer .tmts-hb-drawer-content {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 40px 30px 80px;
}

#tmts-hbook-drawer .tmts-hb-drawer-content::-webkit-scrollbar {
  width: 8px;
}
#tmts-hbook-drawer .tmts-hb-drawer-content::-webkit-scrollbar-thumb {
  background: rgba(0,0,0,0.2);
  border-radius: 4px;
}

/* TMTS HBook Drawer v1.2.3 — Keith Wood datepick layering + background fixes */
.hb-datepick-popup-wrapper,
.hb-datepick-popup,
.hb-datepick-wrapper,
.hb-datepick,
.datepick-popup,
.datepick {
  background: #fff !important;
  color: #000 !important;
  border: 1px solid rgba(0,0,0,.12) !important;
  border-radius: 6px !important;
  box-shadow: 0 8px 24px rgba(0,0,0,.18) !important;
  z-index: 100020 !important; /* above drawer (10000) & overlay (9999) */
}

.hb-datepick table,
.datepick table {
  background: #fff !important;
}

.hb-datepick th,
.hb-datepick td,
.datepick th,
.datepick td {
  background: #fff !important;
  color: #000 !important;
}

/* Selected / hover states for contrast */
.hb-datepick .datepick-selected,
.datepick .datepick-selected {
  background: #000 !important;
  color: #fff !important;
}

/* jQuery UI fallback just in case */
#ui-datepicker-div,
.ui-datepicker {
  background: #fff !important;
  color: #000 !important;
  border: 1px solid rgba(0,0,0,.12) !important;
  border-radius: 6px !important;
  box-shadow: 0 8px 24px rgba(0,0,0,.18) !important;
  z-index: 100020 !important;
}

/* TMTS HBook Drawer v1.2.7 — Ensure Keith Wood popup always visible */
.datepick-popup, .hb-datepick-popup, .hb-datepick-wrapper, .hb-datepick, .datepick {
  z-index: 100020 !important;
  background: #fff !important;
}

/* TMTS HBook Drawer v1.2.8 — datepick popup visibility & theme consistency */
.hb-datepick-popup-wrapper,
.hb-datepick-popup,
.hb-datepick,
.datepick-popup,
.datepick {
  z-index: 100020 !important; /* above overlay & drawer */
  background: #fff !important;
}
