/* APD 173.0.0 — SEARCH INTERACTION + SUBMIT STABILITY HOTFIX */
@media (min-width:1180px) {
  /* ---------------------------------------------------------------
     Keep the expanded search bar and its panels fully above the dimmer.
     This fixes the "everything is gray / cannot select" issue.
     --------------------------------------------------------------- */
  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header {
    isolation:isolate !important;
    z-index:5200 !important;
  }

  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header .apd5-header-row,
  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header .apd5-header-search-row {
    position:relative !important;
    overflow:visible !important;
    z-index:5210 !important;
  }

  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header #apd5-search {
    position:relative !important;
    z-index:5220 !important;
    overflow:visible !important;
    align-items:center !important;
  }

  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header #apd5-search .apd5-search-field {
    position:relative !important;
    z-index:5221 !important;
  }

  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header #apd5-search .apd5-search-field.is-open {
    z-index:5230 !important;
  }

  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header #apd5-search .apd5-search-panel {
    z-index:5240 !important;
    opacity:1 !important;
    filter:none !important;
    pointer-events:auto !important;
    background:#fff !important;
  }

  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-search-backdrop:not([hidden]) {
    z-index:5190 !important;
    pointer-events:auto !important;
    background:rgba(0,0,0,.24) !important;
  }

  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header #apd5-search [data-search-panel],
  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header #apd5-search [data-search-panel] *,
  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header #apd5-search .apd5-destination-option,
  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header #apd5-search .apd5-destination-option * {
    pointer-events:auto !important;
  }

  /* ---------------------------------------------------------------
     Buscar button: keep it vertically centered and stop the tiny flicker.
     --------------------------------------------------------------- */
  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header #apd5-search .apd5-search-submit,
  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header #apd5-search .apd5-search-submit > span,
  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header #apd5-search .apd5-search-submit .apd5-icon,
  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header #apd5-search .apd5-search-submit svg {
    animation:none !important;
    transition:none !important;
    transform:none !important;
  }

  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header #apd5-search .apd5-search-submit {
    align-self:center !important;
    place-self:center !important;
    justify-self:center !important;
    vertical-align:middle !important;
    margin-top:0 !important;
    margin-bottom:0 !important;
    top:auto !important;
    bottom:auto !important;
    line-height:1 !important;
    will-change:auto !important;
  }

  /* Entry (top-of-page) expanded search alignment. */
  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header.is-discovery-context:not(.is-compact) #apd5-search .apd5-search-submit,
  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header.is-discovery-context:not(.is-compact) #apd5-search.has-open-panel .apd5-search-submit {
    place-self:center !important;
    align-self:center !important;
    justify-self:center !important;
    margin:0 10px 0 0 !important;
  }

  /* Sticky compact expanded state alignment. */
  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header.is-discovery-context.is-compact.is-search-expanded #apd5-search .apd5-search-submit,
  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header.is-discovery-context.is-compact.is-search-expanded #apd5-search.has-open-panel .apd5-search-submit {
    place-self:center !important;
    align-self:center !important;
    justify-self:center !important;
    margin:8px 8px 8px 0 !important;
  }

  /* Preserve the larger Airbnb-like open pill from 172 without jumping. */
  html body.apd173-search-interaction-fix.apd-marketplace-ui #apd5-header.is-discovery-context.is-compact.is-search-expanded #apd5-search.has-open-panel .apd5-search-submit {
    width:114px !important;
    min-width:114px !important;
    max-width:114px !important;
    height:56px !important;
    min-height:56px !important;
    max-height:56px !important;
    padding:0 17px !important;
    gap:7px !important;
  }
}
