/*
  Minimal public motion.
  Only the search dropdowns open with a soft motion.
*/

@keyframes cs-stop-dropdown-in{
  from{
    opacity: 0;
    transform: translateX(-50%) translateY(-8px) scale(.98);
    clip-path: inset(0 0 52% 0 round 18px);
    filter: blur(2px);
  }
  to{
    opacity: 1;
    transform: translateX(-50%) translateY(0) scale(1);
    clip-path: inset(0 0 0 0 round 18px);
    filter: blur(0);
  }
}

@keyframes cs-stop-dropdown-inline-in{
  from{
    opacity: 0;
    transform: translateY(-8px) scale(.985);
    clip-path: inset(0 0 56% 0 round 18px);
    filter: blur(2px);
  }
  to{
    opacity: 1;
    transform: translateY(0) scale(1);
    clip-path: inset(0 0 0 0 round 18px);
    filter: blur(0);
  }
}

.ui-public .modern-searchbar .location-dropdown.modern-dropdown:not(.d-none){
  animation: cs-stop-dropdown-in 320ms cubic-bezier(.16, 1, .3, 1) both;
  transform-origin: top center;
  will-change: opacity, transform, filter;
}

.ui-public .modern-searchbar .location-picker.inline-dropdown .location-dropdown.modern-dropdown:not(.d-none){
  animation-name: cs-stop-dropdown-inline-in;
}

.ui-public .modern-searchbar .pax-dropdown:not(.d-none){
  animation: cs-stop-dropdown-in 320ms cubic-bezier(.16, 1, .3, 1) both;
  transform-origin: top center;
  will-change: opacity, transform, filter;
}

.ui-public .modern-searchbar .pax-picker.inline-dropdown .pax-dropdown:not(.d-none){
  animation-name: cs-stop-dropdown-inline-in;
}

@media (max-width: 991.98px){
  .ui-public .landing-shell .modern-searchbar .pax-picker.inline-dropdown .pax-dropdown:not(.d-none){
    position: absolute !important;
    left: 0 !important;
    right: 0 !important;
    top: auto !important;
    bottom: calc(100% + 8px) !important;
    width: 100% !important;
    max-height: min(300px, calc(100vh - 180px)) !important;
    overflow-y: auto !important;
    z-index: 160 !important;
  }
}

@media (prefers-reduced-motion: reduce){
  .ui-public .modern-searchbar .location-dropdown.modern-dropdown:not(.d-none),
  .ui-public .modern-searchbar .pax-dropdown:not(.d-none){
    animation-duration: .01ms !important;
    animation-delay: 0ms !important;
  }
}
