/*
 * ============================================================
 * INSTRUCTION SORTING — BOYKOVDOCS PAGE STYLE
 * ============================================================
 */

.boykovInstructionSort {
  width: 100%;

  display: flex;
  align-items: center;
  justify-content: space-between;

  gap: 20px;

  margin:
    4px
    0
    22px;

  padding:
    13px
    0
    12px;

  border-top:
    1px solid
    rgba(20, 30, 50, .10);

  border-bottom:
    1px solid
    rgba(20, 30, 50, .10);

  font-family:
    Comfortaa,
    sans-serif;
}


/*
 * Лейбл
 */

.boykovInstructionSort__label {
  position: relative;

  display: inline-flex;
  align-items: center;

  color: #7b8493;

  font-family:
    Comfortaa,
    sans-serif;

  font-size: 12px;
  line-height: 1.3;
  font-weight: 500;

  letter-spacing: .02em;
}


.boykovInstructionSort__label::before {
  content: "";

  width: 5px;
  height: 5px;

  margin-right: 8px;

  border-radius: 50%;

  background: #4278d3;
}


/*
 * Группа переключателей
 */

.boykovInstructionSort__buttons {
  display: inline-flex;
  align-items: center;

  gap: 5px;

  padding: 0;

  border: 0;

  background: transparent;
}


/*
 * Кнопка
 */

.boykovInstructionSort__button {
  appearance: none;

  position: relative;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  min-height: 36px;

  padding:
    9px
    14px;

  border:
    1px solid
    transparent;

  border-radius: 10px;

  background: transparent;

  color: #626c7c;

  font-family:
    Comfortaa,
    sans-serif;

  font-size: 12px;
  line-height: 1;
  font-weight: 500;

  white-space: nowrap;

  cursor: pointer;

  transition:
    color .18s ease,
    background-color .18s ease,
    border-color .18s ease,
    transform .18s ease,
    box-shadow .18s ease;
}


/*
 * Hover
 */

.boykovInstructionSort__button:hover {
  color: #4278d3;

  background:
    rgba(66, 120, 211, .055);

  border-color:
    rgba(66, 120, 211, .10);

  transform:
    translateY(-1px);
}


/*
 * Активный вариант
 */

.boykovInstructionSort__button--active {
  color: #356dbf;

  background:
    rgba(66, 120, 211, .075);

  border-color:
    rgba(66, 120, 211, .18);

  box-shadow:
    0 5px 16px
    rgba(66, 120, 211, .08);

  font-weight: 600;
}


/*
 * Небольшая синяя линия
 * под активной сортировкой
 */

.boykovInstructionSort__button--active::after {
  content: "";

  position: absolute;

  left: 14px;
  right: 14px;
  bottom: 4px;

  height: 1px;

  border-radius: 1px;

  background:
    rgba(66, 120, 211, .65);

  transform-origin: left center;
}


/*
 * Keyboard focus
 */

.boykovInstructionSort__button:focus-visible {
  outline:
    2px solid
    rgba(66, 120, 211, .35);

  outline-offset: 2px;
}


/*
 * ============================================================
 * MOBILE
 * ============================================================
 */

@media (max-width: 700px) {

  .boykovInstructionSort {
    align-items: flex-start;

    gap: 10px;

    margin:
      2px
      0
      17px;

    padding:
      11px
      0;
  }


  .boykovInstructionSort__label {
    padding-top: 10px;

    font-size: 11px;
  }


  .boykovInstructionSort__label::before {
    width: 4px;
    height: 4px;

    margin-right: 6px;
  }


  .boykovInstructionSort__buttons {
    gap: 3px;
  }


  .boykovInstructionSort__button {
    min-height: 34px;

    padding:
      8px
      9px;

    border-radius: 9px;

    font-size: 11px;
  }


  .boykovInstructionSort__button--active::after {
    left: 9px;
    right: 9px;
  }

}


/*
 * Очень узкие экраны
 */

@media (max-width: 420px) {

  .boykovInstructionSort {
    display: block;
  }


  .boykovInstructionSort__label {
    padding-top: 0;

    margin-bottom: 8px;
  }


  .boykovInstructionSort__buttons {
    width: 100%;

    display: grid;

    grid-template-columns:
      1fr
      1fr;
  }


  .boykovInstructionSort__button {
    width: 100%;
  }

}
