.bon-mobile-bottom-menu,
.bon-mobile-bottom-menu__spacer {
  display: none;
}

.bon-catalog-mobile__header,
.bon-catalog-mobile__panel-header {
  display: none;
}

@media (max-width: 767.98px) {
  .bon-mobile-bottom-menu__spacer {
    display: block;
    width: 100%;
    height: calc(68px + env(safe-area-inset-bottom));
  }

  .bon-mobile-bottom-menu {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1600;
    display: block;
    width: 100%;
    padding-bottom: env(safe-area-inset-bottom);
    border-top: 1px solid #eeeeee;
    background: rgba(255, 255, 255, 0.98);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
  }

  .bon-mobile-bottom-menu,
  .bon-mobile-bottom-menu * {
    box-sizing: border-box;
  }

  .bon-mobile-bottom-menu__inner {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    width: 100%;
    max-width: 600px;
    height: 68px;
    margin: 0 auto;
  }

  .bon-mobile-bottom-menu__link {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    min-width: 0;
    height: 68px;
    padding: 7px 3px 6px;
    gap: 4px;
    color: #969696;
    text-align: center;
    text-decoration: none;
    transition: color .2s ease, background-color .2s ease;
  }

  .bon-mobile-bottom-menu__link:hover,
  .bon-mobile-bottom-menu__link:focus,
  .bon-mobile-bottom-menu__link:active,
  .bon-mobile-bottom-menu__link.is-active {
    color: #A54BD9;
    text-decoration: none;
    outline: none;
  }

  .bon-mobile-bottom-menu__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 24px;
    width: 24px;
    height: 24px;
    color: currentColor;
    line-height: 1;
  }

  .bon-mobile-bottom-menu__icon svg {
    display: block;
    width: 24px;
    height: 24px;
    max-width: 24px;
    max-height: 24px;
    color: currentColor;
    overflow: visible;
  }

  .bon-mobile-bottom-menu__icon svg [stroke]:not([stroke="none"]) {
    stroke: currentColor !important;
  }

  .bon-mobile-bottom-menu__icon svg [fill]:not([fill="none"]) {
    fill: currentColor !important;
  }

  .bon-mobile-bottom-menu__text {
    display: block;
    width: 100%;
    min-width: 0;
    overflow: hidden;
    font-size: 10px;
    font-weight: 400;
    line-height: 1.1;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .bon-mobile-bottom-menu__link.is-active .bon-mobile-bottom-menu__text {
    font-weight: 500;
  }
}

@media (max-width: 374px) {
  .bon-mobile-bottom-menu__inner,
  .bon-mobile-bottom-menu__link {
    height: 64px;
  }

  .bon-mobile-bottom-menu__spacer {
    height: calc(64px + env(safe-area-inset-bottom));
  }

  .bon-mobile-bottom-menu__icon,
  .bon-mobile-bottom-menu__icon svg {
    width: 22px;
    height: 22px;
    max-width: 22px;
    max-height: 22px;
  }

  .bon-mobile-bottom-menu__text {
    font-size: 9px;
  }
}

/* Catalog item is a button that opens the existing header catalog drawer. */
@media (max-width: 767.98px) {
  button.bon-mobile-bottom-menu__link {
    appearance: none;
    -webkit-appearance: none;

    margin: 0;
    border: 0;
    border-radius: 0;

    background: transparent;
    font: inherit;
    cursor: pointer;
  }

  .bon-mobile-bottom-menu__link.is-catalog-open {
    color: #A54BD9;
  }
}


/* =========================================
   Full-screen mobile catalog drawer
   ========================================= */

@media (max-width: 767.98px) {
  body.bon-catalog-open {
    overflow: hidden !important;
  }

  .bon-catalog {
    position: fixed !important;

    top: 0 !important;
    right: 0 !important;
    bottom: calc(
      68px + env(safe-area-inset-bottom)
    ) !important;
    left: 0 !important;

    z-index: 1550 !important;

    width: 100% !important;
    height: auto !important;
    max-height: none !important;

    margin: 0 !important;
    padding: 0 !important;

    overflow: hidden !important;

    border: 0 !important;
    background: #ffffff !important;
    box-shadow: none !important;
  }

  .bon-catalog > .container-fluid,
  .bon-catalog > .bon-container {
    width: 100% !important;
    max-width: none !important;
    height: 100% !important;

    margin: 0 !important;
    padding: 0 !important;
  }

  .bon-catalog__inner {
    display: flex !important;
    flex-direction: column !important;

    width: 100% !important;
    height: 100% !important;
    min-height: 0 !important;

    margin: 0 !important;
    padding: 0 !important;

    overflow: hidden !important;
  }

  .bon-catalog-mobile__header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    flex: 0 0 54px;

    width: 100%;
    min-height: 54px;
    padding: 0 14px;

    border-bottom: 1px solid #f0f0f0;
    background: #ffffff;
  }

  .bon-catalog-mobile__header-title {
    color: #212121;

    font-size: 17px;
    font-weight: 600;
    line-height: 1.2;
  }

  .bon-catalog-mobile__close {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    flex: 0 0 36px;

    width: 36px;
    height: 36px;
    margin: 0 -7px 0 0;
    padding: 0;

    border: 0;
    border-radius: 50%;

    background: transparent;
    color: #c9c9c9;

    cursor: pointer;
  }

  .bon-catalog-mobile__close svg {
    display: block;

    width: 24px;
    height: 24px;
  }

  .bon-catalog__left,
  .bon-catalog__right {
    flex: 1 1 auto;

    width: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;

    margin: 0 !important;
    padding: 10px 12px 22px !important;

    border: 0 !important;

    overflow-x: hidden !important;
    overflow-y: auto !important;

    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
  }

  .bon-catalog__left {
    display: flex !important;
    flex-direction: column !important;

    gap: 0 !important;
  }

  .bon-catalog__right {
    display: none !important;
  }

  .bon-catalog.is-mobile-panel-open
    .bon-catalog__left {
    display: none !important;
  }

  .bon-catalog.is-mobile-panel-open
    .bon-catalog__right {
    display: block !important;
  }

  .bon-catalog__category {
    display: grid !important;
    grid-template-columns: 24px minmax(0, 1fr) 20px !important;
    align-items: center !important;

    column-gap: 9px !important;

    width: 100% !important;
    min-height: 42px !important;
    padding: 5px 0 !important;

    border: 0 !important;

    background: transparent !important;
    color: #242424 !important;

    font-size: 16px !important;
    font-weight: 400 !important;
    line-height: 1.25 !important;

    text-align: left !important;
    text-decoration: none !important;
  }

  .bon-catalog__category-icon {
    width: 24px !important;
    height: 24px !important;

    color: #a54bd9 !important;
  }

  .bon-catalog__category-icon svg {
    max-width: 22px !important;
    max-height: 22px !important;
  }

  .bon-catalog__category-name {
    min-width: 0;

    overflow: hidden;

    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .bon-catalog__category-arrow {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    width: 20px !important;
    height: 20px !important;

    color: #d5d5d5 !important;
    transform: none !important;
  }

  .bon-catalog__panel {
    display: none !important;

    width: 100%;
    min-height: 100%;

    margin: 0;
    padding: 0;
  }

  .bon-catalog__panel.is-active {
    display: block !important;
  }

  .bon-catalog-mobile__panel-header {
    display: block;

    width: 100%;
    padding: 0 0 8px;
  }

  .bon-catalog-mobile__back {
    display: flex;
    align-items: center;

    width: 100%;
    min-height: 42px;
    margin: 0;
    padding: 0;

    gap: 6px;

    border: 0;

    background: transparent;
    color: #212121;

    font: inherit;
    text-align: left;
    cursor: pointer;
  }

  .bon-catalog-mobile__back svg {
    display: block;
    flex: 0 0 22px;

    width: 22px;
    height: 22px;

    color: #c9c9c9;
  }

  .bon-catalog-mobile__panel-title {
    display: block;
    min-width: 0;
    overflow: hidden;
    font-size: 20px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .bon-catalog-mobile__all {
    display: inline-flex;
    align-items: center;

    min-height: 34px;
    margin: 0;
    padding: 3px 0;

    color: #a54bd9;

    font-size: 16px;
    font-weight: 500;
    line-height: 1.2;

    text-decoration: none;
  }

  .bon-catalog-mobile__all:hover,
  .bon-catalog-mobile__all:focus {
    color: #a54bd9;
    text-decoration: none;
  }

  .bon-catalog__subcategories {
    display: grid !important;
    grid-template-columns: 1fr !important;

    width: 100% !important;
    max-width: none !important;

    column-gap: 0 !important;
    row-gap: 0 !important;
  }

  .bon-catalog__subcategory {
    display: flex !important;
    align-items: center !important;

    width: 100% !important;
    min-height: 42px !important;
    padding: 5px 0 !important;

    color: #212121 !important;

    font-size: 16px !important;
    font-weight: 400 !important;
    line-height: 1.25 !important;

    text-decoration: none !important;
  }

  .bon-catalog__empty {
    padding: 10px 0 !important;
  }
}

@media (max-width: 374px) {
  .bon-catalog {
    bottom: calc(
      64px + env(safe-area-inset-bottom)
    ) !important;
  }
}
