/* Scoped to the Homey half-map listings area; no global header/menu changes. */
.half-map-wrap .vrbs-hotels-status {
  margin: 12px 16px 8px;
  padding: 9px 12px;
  background: #f5f7fa;
  border: 1px solid #e5eaf1;
  border-radius: 4px;
  color: #45515e;
  font-size: 13px;
  line-height: 1.5;
}
#homey_halfmap_listings_container .vrbs-hotel-card { position: relative; }
#homey_halfmap_listings_container .vrbs-hotel-card .item-media img {
  display: block;
  width: 100%;
  height: 180px;
  object-fit: cover;
}
#homey_halfmap_listings_container .vrbs-hotel-card .vrbs-image-fallback {
  display: flex; align-items: center; justify-content: center;
  height: 180px; background: #e7ecf1; color: #627384;
}
#homey_halfmap_listings_container .vrbs-hotel-card .item-media-price .item-price {
  font-size: 15px;
}
#homey_halfmap_listings_container .vrbs-hotel-card .vrbs-hotel-meta,
#homey_halfmap_listings_container .vrbs-hotel-card .vrbs-hotel-price-context {
  font-size: 12px; color: #667085; margin-top: 5px;
}
#homey_halfmap_listings_container .vrbs-hotel-card .vrbs-hotel-link { margin-top: 10px; }
@media (max-width: 767px) {
  .half-map-wrap .vrbs-hotels-status { margin: 10px 12px; }
  #homey_halfmap_listings_container .vrbs-hotel-card .item-media img { height: 220px; }
}

/* Independent destination map, positioned over Homey's empty-listings map.
   This makes location searches usable even if Homey's default map has no markers. */
.half-map-wrap .half-map-right-wrap.vrbs-map-active { isolation: isolate; }
.half-map-wrap .vrbs-map-active #vrbs-hotels-map {
  position: absolute !important;
  z-index: 12;
  inset: 0;
  width: 100%;
  height: 100%;
  background: #e5e9e7;
}
.half-map-wrap .vrbs-map-active .map-next-prev-actions,
.half-map-wrap .vrbs-map-active .map-arrows-actions,
.half-map-wrap .vrbs-map-active .map-zoom-actions,
.half-map-wrap .vrbs-map-active > #homey-map-loading { display: none !important; }
.half-map-wrap .vrbs-map-caption {
  position: absolute;
  z-index: 20;
  bottom: 24px;
  left: 12px;
  right: 12px;
  max-width: 460px;
  padding: 8px 11px;
  background: rgba(255, 255, 255, .95);
  box-shadow: 0 2px 8px rgba(0, 0, 0, .12);
  color: #3f4a54;
  border-radius: 4px;
  font-size: 12px;
  line-height: 1.4;
  pointer-events: none;
}
.half-map-wrap #vrbs-hotels-map .leaflet-container { z-index: 1; }
@media (max-width: 768px) {
  .half-map-wrap .vrbs-map-active #vrbs-hotels-map { min-height: 300px; }
  .half-map-wrap .vrbs-map-caption { left: 8px; right: 8px; bottom: 10px; font-size: 11px; }
}
@media (max-width: 768px) {
  .half-map-wrap .half-map-right-wrap.vrbs-map-active { min-height: 340px; }
}

/* v0.4.0: clear in-progress hotel search instead of a premature "No results". */
.half-map-wrap.vrbs-hotels-searching #homey_halfmap_listings_container > .map-notfound,
.half-map-wrap.vrbs-hotels-has-hotels #homey_halfmap_listings_container > .map-notfound,
.half-map-wrap.vrbs-hotels-searching #homey-halfmap .map-notfound,
.half-map-wrap.vrbs-hotels-has-hotels #homey-halfmap .map-notfound {
  display: none !important;
}
.half-map-wrap.vrbs-hotels-searching .vrbs-hotels-status {
  display: flex; align-items: center; flex-wrap: wrap; gap: 9px;
  padding: 13px 16px; color: #163f69; background: #f0f7ff; border-color: #d2e4f5;
}
.half-map-wrap.vrbs-hotels-searching .vrbs-hotels-status small {
  width: 100%; padding-left: 30px; margin-top: -5px; font-size: 12px; color: #657b8f;
}
.half-map-wrap .vrbs-loading-spinner {
  display: inline-block; width: 20px; height: 20px; flex: none;
  border-radius: 100%; border: 3px solid #b7daf1; border-top-color: #0e67bb;
  animation: vrbs-hotel-spin 0.8s linear infinite;
}
@keyframes vrbs-hotel-spin { to { transform: rotate(360deg); } }
.half-map-wrap .vrbs-hotel-skeletons { padding: 8px 16px 15px; }
.half-map-wrap .vrbs-hotel-skeleton {
  display: flex; align-items: stretch; gap: 16px;
  min-height: 140px; margin-bottom: 15px; padding: 10px;
  border: 1px solid #e8edf2; border-radius: 6px; background: #fff;
}
.half-map-wrap .vrbs-skeleton-photo,
.half-map-wrap .vrbs-skeleton-line {
  display: block; background: #e8eef4;
  background-image: linear-gradient(100deg, transparent 0%, rgba(255,255,255,.75) 42%, transparent 82%);
  background-size: 220% 100%; animation: vrbs-hotel-shimmer 1.6s ease-in-out infinite;
}
.half-map-wrap .vrbs-skeleton-photo { width: 36%; min-width: 130px; max-width: 220px; border-radius: 4px; }
.half-map-wrap .vrbs-skeleton-content { flex: 1; padding-top: 12px; }
.half-map-wrap .vrbs-skeleton-line { height: 13px; border-radius: 4px; margin-bottom: 18px; }
.half-map-wrap .vrbs-skeleton-line.wide { width: 86%; height: 20px; }
.half-map-wrap .vrbs-skeleton-line.medium { width: 65%; }
.half-map-wrap .vrbs-skeleton-line.short { width: 38%; }
@keyframes vrbs-hotel-shimmer { to { background-position-x: -220%; } }
.half-map-wrap .vrbs-hotels-map-loading {
  position: absolute; z-index: 16; inset: 0; background: rgba(239,247,251,.94);
  display: flex; align-items: center; justify-content: center;
  flex-direction: column; gap: 11px; padding: 24px; text-align: center; color: #254c6d;
}
.half-map-wrap .vrbs-hotels-map-loading .vrbs-loading-spinner { width: 38px; height: 38px; border-width: 4px; }
.half-map-wrap .vrbs-hotels-map-loading span { font-size: 13px; }
@media (max-width: 767px) {
  .half-map-wrap .vrbs-hotel-skeleton { min-height: 116px; gap: 10px; }
  .half-map-wrap .vrbs-skeleton-photo { min-width: 90px; }
  .half-map-wrap.vrbs-hotels-searching .vrbs-hotels-status small { padding-left: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .half-map-wrap .vrbs-loading-spinner, .half-map-wrap .vrbs-skeleton-photo,
  .half-map-wrap .vrbs-skeleton-line { animation: none; }
}
