/* Compact layout for the current Dash date-picker implementation. */
.legacy-cutoff-control > .dash-datepicker {
  height: 38px;
  margin-bottom: 10px;
}

.legacy-cutoff-picker {
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  box-sizing: border-box;
  height: 38px;
  min-height: 38px;
  padding: 2px 10px !important;
}

.legacy-cutoff-picker > div {
  flex: 1 1 auto;
  min-width: 0;
}

.legacy-cutoff-picker input.dash-datepicker-input {
  box-sizing: border-box !important;
  width: 100% !important;
  height: 32px !important;
  min-width: 0 !important;
  padding: 0 !important;
  font-size: 14px !important;
  line-height: 22px !important;
}

.legacy-cutoff-picker .dash-datepicker-caret-icon {
  flex: 0 0 auto;
  margin-left: 8px;
}

/* Legacy cutoff control and reusable hover information popup. */
.legacy-cutoff-control {
  width: min(100%, 320px);
  color: #173b63;
}

.legacy-cutoff-header {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 2px;
}

.legacy-cutoff-label {
  margin: 0;
  color: #24496d;
  font-size: 14px;
  font-weight: 600;
}

.hover-info {
  position: relative;
  display: inline-flex;
}

.hover-info__trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  padding: 0;
  border: 1px solid #9eb0c1;
  border-radius: 50%;
  background: transparent;
  color: #7890a5;
  font-size: 10px;
  font-weight: 700;
  cursor: help;
  transition:
    background-color 150ms ease,
    border-color 150ms ease,
    color 150ms ease;
}

.hover-info__trigger:hover,
.hover-info:focus-within .hover-info__trigger {
  border-color: #71869a;
  background: #71869a;
  color: #fff;
}

.hover-info__popup {
  position: absolute;
  z-index: 1000;
  top: calc(100% + 8px);
  left: 0;
  width: min(340px, calc(100vw - 32px));
  padding: 10px 12px;
  border: 1px solid #cbd8e5;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 6px 18px rgb(28 63 95 / 16%);
  color: #24496d;
  font-size: 12px;
  font-weight: 400;
  line-height: 1.45;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-4px);
  transition:
    opacity 150ms ease,
    transform 150ms ease;
  visibility: hidden;
}

.hover-info__trigger:hover + .hover-info__popup,
.hover-info__popup:hover,
.hover-info:focus-within .hover-info__popup {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
  visibility: visible;
}

#filters-offcanvas .hover-info {
  flex: 1 1 0;
  min-width: 0;
}

#filters-offcanvas .hover-info__popup {
  left: 0;
  right: auto;
  max-width: 100%;
  box-sizing: border-box;
  overflow-wrap: anywhere;
}
