/* Шрифт */
:root {
  /* --font-family: "Inter", sans-serif; */
  --base-font-size: 16px;
  --font-size-sm: calc(var(--base-font-size) - 1px);
  --font-size-xs: calc(var(--base-font-size) - 4px);
}

/* Скругление */
:root {
  --br-xs: 4px;
  --br-sm: 6px;
  --br: 8px;
}

/* Тени */
:root {
  --shadow: 0 8px 32px -4px rgba(103, 111, 123, 0.1);
}

/* Переходы */
:root {
  --tr25: .25s;
  --tr15: .15s;
}

/* Цвета */
:root {
  --white-100: rgba(255, 255, 255, 1);
  --white-80: rgba(255, 255, 255, 0.8);
  --gray-100: #eef1f6;
  --gray-700: #333d4c;
  --gray-50: #f5f7fa;
  --gray-900: #181d25;
  --primary-main: #f55266;

  /* Основные цвета темы */
  --background: var(--white-100);
}

.s-catalog-menu {
  position: absolute;
  top: 287px;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  height: auto;
  min-height: 300px;
  padding: 0 0 30px;
  border-radius: var(--br);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  z-index: -1;
  transition: var(--tr25);
}

.s-catalog-menu.is-open {
  top: 225px;
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  z-index: 1000;
}

.catalog-menu {
  display: grid;
  grid-template-columns: minmax(250px, 306px) 1fr;
  grid-gap: 4px;
  height: 542px;
}


.catalog-menu__aside {
  border: 1px solid var(--gray-100);
  border-radius: 16px;
  padding: 12px;
  min-width: 250px;
  box-shadow: var(--shadow);
  background: var(--background);
}

.catalog-menu__list {
  > li {
    list-style-type: none;

    > a {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
      color: var(--gray-700);
      transition: var(--tr25);
      border-radius: var(--br);
      padding: 8px 12px;
      width: 100%;
      min-height: 38px;
      font-weight: 500;
      font-size: var(--font-size-sm);
      line-height: 1.57;
    }
  }
}

@media (hover: hover) {
  .catalog-menu a:hover,
  .catalog-menu__category a.is-parent:hover {
    color: var(--primary-main);
  }
}

.catalog-menu__list a.is-active {
  color: var(--primary-main);
  background-color: var(--gray-50);

}

.catalog-menu__content {
  display: flex;
  height: 100%;
  border: 1px solid var(--gray-100);
  border-radius: 16px;
  box-shadow: var(--shadow);
  background: var(--background);
  width: 100%;
  gap: 30px;
  padding: 24px 24px 24px 20px;
  /* max-height: 542px; */
  overflow-y: auto;
}

.catalog-menu__content > div {
  width: 100%;
}

.catalog-menu__category {
  .lvl-1 {
    list-style-type: none;
    padding: 0;

    > li {
      .lvl-2 {
        padding: 0;

        > li {
          list-style-type: none;
          padding: 0;

          .lvl-3 {
            list-style-type: none;
            padding: 0;

            > li {
              list-style-type: none;
              padding: 0;
            }
          }
        }
      }
    }
  }

  > li {
    list-style-type: none;

    > a {
      display: inline-flex;
      font-size: var(--font-size-sm);
      line-height: 1.57;
      color: var(--gray-700);
      padding: 2px 0;
    }
  }
}


.catalog-menu__category a.is-parent {
  font-weight: 600;
  font-size: 16px;
  line-height: 1.5;
  color: var(--gray-900);
}

.catalog-menu__category {
  display: flex;
  gap: 20px;
  justify-content: space-between;

  .catalog-menu__banner {
    width: 100%;
    max-width: 600px;
    min-width: 300px;
    display: flex;
    justify-content: flex-end;

    > a {
      display: flex;

      > img {
        width: 100%;
        object-position: center;
        object-fit: cover;
        border-radius: 16px;
      }
    }

    > img {
      border-radius: 16px;
    }
  }
}

ul.lvl-1 a,
ul.lvl-2 a {
  padding: 5px 10px;
  list-style-type: none;
}

ul.lvl-2 {
  position: relative;
  z-index: 1;
  min-width: 150px;
}

ul.lvl-2 a {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  border-radius: var(--br);
}

@media (hover: hover) {
  ul.lvl-2 a:hover {
    background-color: var(--gray-50);
    width: max-content;
  }
  ul.lvl-2 li:has(ul.lvl-3):hover {
    ul.lvl-3 {
      opacity: 1;
      visibility: visible;
      pointer-events: auto;
      z-index: 2;
    }
  }
}

ul.lvl-3 {
  position: absolute;
  top: 0;
  left: 100%;
  padding: 0 24px !important;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  z-index: -1;
  transition: var(--tr25);
  width: 320px;
}

.icon {
  width: 26px;
  height: 26px;
}

.icon.icon-sm {
  width: 21px;
  height: 22px;
}

@media (max-width: 1200px) {
  .catalog-menu__banner {
    display: none;
  }
}

@media (max-width: 1023px) {
  .s-catalog-menu {
    display: none !important;
  }
}