/* filters */
.filters {
  display: flex;
  justify-content: flex-start;
}

.filters__show-filters-button {
  background-image: url('/components/assets/');
}

.filter {
  flex-grow: 0;
  flex-shrink: 0;
  margin-right: 1em;
  position: relative;
}

.filter__label {
  font-weight: var(--fw-bold);
  color: var(--burnt-orange);
  margin-bottom: calc(var(--line-height-em) /2);
}

.filter__input {
  border-left: 0;
  border-right: 0;
  border-top: 0;
  border-bottom: 1px solid var(--burnt-orange);
  color: var(--burnt-orange);
  box-shadow: none;
  background-color: transparent;
  width: 100%;
}

.filter__label.dropdown:hover {
  cursor: pointer;
  color: var(--bright-orange);
}

.filter__label.dropdown {
  display: flex;
  align-items: center;
}

.filter__faux-input {
  border-left: 0;
  border-right: 0;
  border-top: 0;
  border-bottom: 1px solid var(--burnt-orange);
  color: var(--burnt-orange);
  box-shadow: none;
  background-color: transparent;
  width: 100%;
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
}

.filter__faux-input.has-dropdown {
  cursor: pointer;
  background-image: url('./assets/down-carat--burnt-orange.png');
  background-repeat: no-repeat;
  background-size: 1em;
  background-position: right;
}

.filter__faux-input.has-dropdown:hover {
  color: var(--bright-orange);
  background-image: url('./assets/down-carat--bright-orange.png');
  border-color: var(--bright-orange);
}

.filter__faux-input__selected-item {
  line-height: 1;
  display: inline-block;
  margin-bottom: 0;
  margin-right: .2em;
  max-width: 55%;
  max-width: 75%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.filter__dropdown {
  position: absolute;
  opacity: 1;
  z-index: 2;
  left: 0;
  width: 100%;
  box-shadow: 0 0px 3px 1px rgba(30, 30, 30, .3);
  background-color: var(--white);
  list-style: none;
  max-height: 28em;
  width: 175%;
  max-width: 23em;
  border-radius: 5px;
  top: calc(var(--line-height-em)*2.5);
}

.filter__dropdown__title {
  position: relative;
  z-index: 1;
  padding: calc( (var(--line-height-em) - 0.8em) /2 ) 1em;
  border-bottom: 1px solid var(--background-white);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.filter__dropdown__label {
  color: var(--burnt-orange);
  margin-bottom: 0;
}

.filter__dropdown__toggle {
  cursor: pointer;
  width: 1em;
  height: 1em;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

.filter__dropdown__toggle.toggle-up {
  background-image: url('./assets/up-carat--burnt-orange.png');
}

.filter__dropdown__toggle.toggle-up:hover {
  background-image: url('./assets/up-carat--bright-orange.png');
}

.filter__dropdown__search {
  width: 100%;
  background-image: url('./assets/search-icon.webp');
  background-repeat: no-repeat;
  background-position: 0 center;
  background-size: 1em;
  border-left: 0;
  border-right: 0;
  border-top: 0;
  border-bottom: 1px solid var(--burnt-orange);
  color: var(--muted);
  box-shadow: none;
  background-color: transparent;
  font-size: .875em;
  padding: calc((var(--line-height-em) - 0.875em )/ 2) calc(1em + .5em);

  margin-bottom: var(--line-height-em);
}

.no-webp .filter__dropdown__search {
  width: 100%;
  background-image: url('./assets/search-icon.png')
}

.filter__dropdown__list {
  padding-left: 0;
  margin-top: 0;
  margin-left: 0;
  margin-bottom: 0;
  max-height: 20em;
  overflow-y: auto;
}

.filter__dropdown__padding {
  padding: 0em 1em var(--line-height-em) 1em;
}

.filter__dropdown-item {
  position: relative;
  list-style: none;
  line-height: 1.4;
  padding: calc(var(--line-height-em)/2) var(--line-height-em) calc(var(--line-height-em)/2) var(--line-height-em);
  margin-right: 1em;
  margin-bottom: 0;
  color: var(--almost-black);
  cursor: pointer;
  color: var(--muted);
  font-weight: var(--fw-medium);
}

.filter__dropdown-item::before {
  content: '';
  margin-top: .15em;
  width: 1em;
  height: 1em;
  position: absolute;
  left: 0;
  background-image: url('./assets/filter-item--unselected.png');
  background-size: contain;
  background-repeat: no-repeat;
}


.filter__dropdown-item.selected::before {
  background-image: url('./assets/filter-item--selected.png');
}

.filter__dropdown-item.selected {
  /* background: var(--background-white); */
}


.filter__dropdown-item:hover {
  color: var(--bright-orange);
}

.filter__dropdown-item:hover::before  {
  opacity: .8;
}


/* ------- month-year-picker ------ */

.month-year-picker {
  position: relative;
}

.myp__dropdown {
  box-shadow: 0 0 3px 1px rgba(30, 30, 30, .3);
  min-width: 15em;
  width: 100%;
  position: absolute;
  padding: calc(var(--line-height-em)) var(--line-height-em) calc(var(--line-height-em)/2) var(--line-height-em);
  background: var(--white);
}

.myp__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.myp__year {
  font-size: var(--fs-small);
  font-weight: var(--fw-medium);
  color: var(--muted);
}

.myp__year-navigator {
  line-height: 1;
  padding: 0;
  width: var(--line-height-em);
  height: var(--line-height-em);
  background-size: 1em;
  background-repeat: no-repeat;
}

.myp__year-navigator.left {
  background-image: url('./assets/left-carat--burnt-orange.png');
}

.myp__year-navigator.left:hover {
  background-image: url('./assets/left-carat--bright-orange.png');
}

.myp__year-navigator.right {
  background-image: url('./assets/right-carat--burnt-orange.png');
}

.myp__year-navigator.right:hover {
  background-image: url('./assets/right-carat--bright-orange.png');
}

.myp__months {
  padding-top: calc(var(--line-height-em)/2);
}

.myp__month {
  padding: .5em;
  cursor: pointer;
}

.myp__month:hover .myp__month-name {
  color: var(--bright-orange);
}

.myp__month.is-inactive {
  cursor: default;
}

.myp__month.is-selected {
  cursor: default;
  color: var(--muted);
  font-weight: var(--fw-bold);
}

.myp__month.is-selected:hover .myp__month-name {
  color: var(--muted);
  font-weight: var(--fw-medium);
}

.myp__month-name {
  display: block;
  text-align: center;
  font-size: var(--fs-small);
  /* font-weight: var(--fw-medium); */
}

.myp__month.is-inactive .myp__month-name, .myp__month.is-inactive:hover .myp__month-name {
  color: var(--extra-muted);
}

/* ------- date range picker ------ */

.drp__selection-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.drp__adjective {
  font-size: var(--fs-small);
}

.drp__start, .drp__end {
  position: relative;
  width: 40%;
}

.drp__selection-wrapper .myp__dropdown {
  right: 0;
}
