
/*
 * Stardust Amelia Top Space Reducer
 * Safe CSS patch: reduces the blank/empty top area in Amelia catalog/booking views.
 * This avoids datepicker/dropdown internals.
 */

/* Reduce outer breathing room inside our Stardust Amelia container */
.sd-amelia-wrap,
.sdw-amelia-inner {
  padding-top: 4px !important;
}

/* Compress common Amelia top/header/filter/search containers */
.sd-amelia-wrap .am-cabinet,
.sd-amelia-wrap .am-catalog,
.sd-amelia-wrap .am-catalog__header,
.sd-amelia-wrap .am-cat__header,
.sd-amelia-wrap .am-category-head,
.sd-amelia-wrap .am-fs__main-heading,
.sd-amelia-wrap .am-fs__main-title,
.sd-amelia-wrap .am-search,
.sd-amelia-wrap .am-search-filter,
.sd-amelia-wrap .am-filter,
.sd-amelia-wrap .am-fs__filter,
.sd-amelia-wrap .am-fs__main-content > div:first-child,
.stardust-booking-widget .am-catalog,
.stardust-booking-widget .am-catalog__header,
.stardust-booking-widget .am-cat__header,
.stardust-booking-widget .am-category-head,
.stardust-booking-widget .am-search,
.stardust-booking-widget .am-search-filter,
.stardust-booking-widget .am-filter,
.stardust-booking-widget .am-fs__filter,
.stardust-booking-widget .am-fs__main-content > div:first-child {
  margin-top: 0 !important;
  padding-top: 0 !important;
}

/* Specifically compress the visible search/filter row without hiding functionality */
.sd-amelia-wrap input[type="search"],
.sd-amelia-wrap input[placeholder*="Search" i],
.stardust-booking-widget input[type="search"],
.stardust-booking-widget input[placeholder*="Search" i] {
  min-height: 38px !important;
  height: 38px !important;
}

/* If Amelia places an icon-only filter button above the search, make it smaller */
.sd-amelia-wrap button[aria-label*="filter" i],
.sd-amelia-wrap button[class*="filter" i],
.stardust-booking-widget button[aria-label*="filter" i],
.stardust-booking-widget button[class*="filter" i] {
  width: 34px !important;
  height: 34px !important;
  min-width: 34px !important;
  min-height: 34px !important;
  padding: 6px !important;
}

/* Reduce gap before the first service card */
.sd-amelia-wrap .am-service:first-of-type,
.sd-amelia-wrap .am-event:first-of-type,
.sd-amelia-wrap [class*="service"]:first-of-type,
.sd-amelia-wrap [class*="event"]:first-of-type,
.stardust-booking-widget .am-service:first-of-type,
.stardust-booking-widget .am-event:first-of-type,
.stardust-booking-widget [class*="service"]:first-of-type,
.stardust-booking-widget [class*="event"]:first-of-type {
  margin-top: 6px !important;
}

/* If the empty area is caused by Amelia's catalog header minimum height */
.sd-amelia-wrap [class*="header"],
.stardust-booking-widget [class*="header"] {
  min-height: unset !important;
}

/* Keep the booking widget itself compact */
.sd-booking-card-compact .sd-amelia-wrap {
  min-height: 240px !important;
}

.sd-booking-card-compact .sd-amelia-compact {
  max-height: 44vh !important;
}
