.articles-filter-block {
  position: relative;
  width: 100%;
  padding: 0 $gutter;
  margin: 48px 0;

  @include sm {
    padding: 0 $gutter-mobile;
    margin: 32px 0;
  }

  &__wrapper {
    width: 100%;
    max-width: $header-content-width;
    margin: 0 auto;
  }

  &__container {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    .articles-filter-block--events &,
    .articles-filter-block--events-past & {
      align-items: flex-start;
      max-width: 675px;
    }
  }

  &__title {
    font-size: 4.8rem;
    margin: 0 0 24px;
  }

  &__subtitle {
    font-size: 2.1rem;
    color: $primary-color;
    margin: 0 0 24px;
  }

  &__filters {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    margin: 8px 0 0;

    .articles-filter-block--events &,
    .articles-filter-block--events-past & {
      justify-content: flex-start;
    }
  }

  &__filter {
    position: relative;
    margin-right: 25px;
    width: 100%;
    max-width: 200px;
    border: 1px solid $gray-border;
    border-radius: 6px;

    &:last-child {
      margin-right: 0;
    }

    &.js-open {
      .articles-filter-block__filter-options {
        transform: translateY(0);
        opacity: 1;
        pointer-events: all;
      }
    }

    &.js-disabled {
      opacity: 0.6;
      pointer-events: none;
    }
  }

  &__filter-open {
    display: block;
    width: 100%;
    font-size: 1.1rem;
    font-weight: 700;
    position: relative;
    padding-right: 20px;
    padding: 14px 16px 12px;

    &:after {
      content: " ";
      border-style: solid;
      border-width: 0 2px 2px 0;
      width: 7px;
      height: 7px;
      display: block;
      position: absolute;
      right: 17px;
      top: 18px;
      transform: rotate(45deg);
    }
  }

  &__filter-selected-item {
    font-size: 1.6rem;
    font-weight: 700;
  }

  &__filter-options {
    position: absolute;
    width: 100%;
    left: 0;
    padding-right: 0;
    margin-top: 4px;
    background: #fff;
    z-index: 999;
    box-shadow: 0 3px 7px 0 rgba(21,38,68,.25);
    pointer-events: none;
    opacity: 0;
    transform: translateY(20px);
    transition: all 250ms ease-out;

    ul {
      max-height: 300px;
      overflow-y: auto;
      overflow-x: hidden;
      min-width: 130px;
      padding: 12px;
      margin-top: 0;
      margin-bottom: 0;
    }

    li {
      padding: 0;
    }
  }

  &__filter-option {
    display: block;
    padding: 6px 25px 4px;
    transition: background-color 250ms linear;

    &:hover {
      background-color: $gray-10;
    }
  }

  &__child-options {
    display: none;
  }
}
