/* Mobile Tabbar — Figma */

.sp-tabbar {
  display: none;
}

@media (max-width: 776px) {
  body {
    padding-bottom: calc(64px + env(safe-area-inset-bottom, 0px));
  }

  .sp-tabbar {
    box-sizing: border-box;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 12040;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    height: calc(64px + env(safe-area-inset-bottom, 0px));
    padding: 8px 20px calc(8px + env(safe-area-inset-bottom, 0px));
    margin: 0;
    background: #fff;
    border-top: 1px solid #e6e8ec;
    font-family: Inter, "Helvetica Neue", Arial, sans-serif;
  }

  .sp-tabbar *,
  .sp-tabbar *::before,
  .sp-tabbar *::after {
    box-sizing: border-box;
  }

  .sp-tabbar__btn {
    position: relative;
    display: inline-flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    flex: none;
    width: 48px;
    height: 48px;
    margin: 0;
    padding: 12px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #6d717f;
    text-decoration: none !important;
    isolation: isolate;
    -webkit-tap-highlight-color: transparent;
    transition: background 0.15s ease, color 0.15s ease;
  }

  .sp-tabbar__icon {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
  }

  .sp-tabbar__icon svg {
    display: block;
    width: 20px;
    height: 20px;
  }

  .sp-tabbar__btn--cart .sp-tabbar__icon svg {
    width: 22px;
    height: 21px;
  }

  .sp-tabbar__btn.is-active {
    color: #131927;
  }

  .sp-tabbar__btn.is-filled,
  .sp-tabbar__btn.is-active.is-filled {
    color: #006ab5;
  }

  .sp-tabbar__badge {
    position: absolute;
    top: 2px;
    right: 2px;
    z-index: 2;
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    font-weight: 500;
    font-size: 12px;
    line-height: 16px;
    color: #006ab5;
    pointer-events: none;
  }

  .sp-tabbar__badge[hidden] {
    display: none !important;
  }

  /* Кнопка «Наверх» выше tabbar */
  .scroll_top-footer-main {
    bottom: calc(80px + env(safe-area-inset-bottom, 0px)) !important;
  }

  /* Bitrix24 виджет выше tabbar */
  .b24-widget-button-wrapper,
  .b24-widget-button-position-bottom,
  .b24-widget-button-position-bottom-left,
  .b24-widget-button-position-bottom-middle,
  .b24-widget-button-position-bottom-right,
  .b24-widget-button-position-fixed.b24-widget-button-position-bottom,
  .b24-widget-button-position-fixed.b24-widget-button-position-bottom-left,
  .b24-widget-button-position-fixed.b24-widget-button-position-bottom-middle,
  .b24-widget-button-position-fixed.b24-widget-button-position-bottom-right {
    bottom: calc(80px + env(safe-area-inset-bottom, 0px)) !important;
  }
}
