#btvn-mobile-purchase,
#btvn-mobile-purchase [hidden],
#btvn-mp-contact-panel:not([open]) {
  display: none;
}

@media (max-width: 849px) {
  body.btvn-mobile-purchase-ready {
    --btvn-mp-height: calc(110px + env(safe-area-inset-bottom, 0px));
  }

  body.btvn-mobile-purchase-ready .custom-nav-wrapper {
    display: none !important;
  }

  body.btvn-mobile-purchase-ready #wrapper {
    padding-bottom: var(--btvn-mp-height);
  }

  body.btvn-mobile-purchase-ready #btvn-ssa {
    bottom: calc(var(--btvn-mp-height) + 6px);
  }

  #btvn-mobile-purchase:not([hidden]) {
    position: fixed;
    inset: auto 0 0;
    z-index: 950;
    display: block;
    padding: 6px max(12px, env(safe-area-inset-right)) calc(8px + env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left));
    border-top: 1px solid #e6d5ca;
    background: #fffaf6;
    box-shadow: 0 -4px 20px rgb(59 34 24 / .12);
  }

  #btvn-mobile-purchase :is(.btvn-mp-top, .btvn-mp-row) {
    display: flex;
    gap: 6px;
    align-items: center;
    max-width: 560px;
    margin-inline: auto;
  }

  #btvn-mobile-purchase .btvn-mp-top {
    justify-content: space-between;
    margin-bottom: 6px;
  }

  #btvn-mobile-purchase .btvn-mp-price {
    color: #71331f;
    font-size: clamp(15px, 4vw, 18px);
    font-weight: 800;
    line-height: 1.2;
    font-variant-numeric: tabular-nums;
  }

  #btvn-mobile-purchase .btvn-mp-price .woocommerce-Price-amount {
    color: inherit;
  }

  #btvn-mobile-purchase :is(button, a):not([hidden]) {
    display: inline-flex;
    flex: 1 1 0;
    align-items: center;
    justify-content: center;
    min-width: 0;
    min-height: 44px;
    margin: 0;
    padding: 4px 5px;
    border: 1px solid #863a22;
    border-radius: 9px;
    background: #863a22;
    color: #fff;
    font: inherit;
    font-size: clamp(12px, 3.5vw, 15px);
    font-weight: 750;
    line-height: 1.15;
    text-align: center;
    text-transform: none;
    letter-spacing: normal;
    box-shadow: none;
  }

  #btvn-mobile-purchase button[data-mp-add]:not([hidden]) {
    background: #fffaf6;
    color: #71331f;
  }

  #btvn-mobile-purchase button[data-mp-contact] {
    flex: 0 0 auto;
    min-width: 120px;
    padding-inline: 14px;
    border-color: #af8251;
    background: #f2daba;
    color: #502c1a;
    font-size: 16px;
    font-weight: 800;
  }

  #btvn-mobile-purchase [aria-disabled="true"] {
    opacity: .7;
  }

  #btvn-mobile-purchase :is(button, a):focus-visible {
    outline: 2px solid #492415;
    outline-offset: 2px;
  }

  #btvn-mobile-purchase .btvn-mp-status {
    position: absolute;
    right: 12px;
    bottom: 100%;
    left: 12px;
    width: fit-content;
    max-width: calc(100% - 24px);
    margin: 0 auto 8px;
    border-radius: 9px;
    background: #492415;
    color: #fff;
    padding: 8px 12px;
    font-size: 13px;
    line-height: 1.3;
    pointer-events: none;
  }

  #btvn-mobile-purchase .btvn-mp-status:empty {
    padding: 0;
  }

  body.btvn-mobile-purchase-ready:is(.modal-open, .off-canvas, .mfp-zoom-out-cur) #btvn-mobile-purchase,
  html.btvn-cart-open #btvn-mobile-purchase {
    visibility: hidden;
  }
}

#btvn-mp-contact-panel {
  position: fixed;
  inset: auto 0 0;
  width: min(100%, 560px);
  max-width: 100%;
  margin: 0 auto;
  padding: 6px 12px calc(14px + env(safe-area-inset-bottom));
  border: 1px solid #e6d5ca;
  border-radius: 16px 16px 0 0;
  background: #fffaf6;
  color: #492415;
}

#btvn-mp-contact-panel::backdrop {
  background: rgb(41 25 17 / .52);
}

#btvn-mp-contact-panel .btvn-mp-contact-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

#btvn-mp-contact-panel :is(h2, form) {
  margin: 0;
}

#btvn-mp-contact-panel h2 {
  color: inherit;
  font-size: 17px;
}

#btvn-mp-contact-panel .btvn-mp-contact-header button {
  width: 44px;
  height: 44px;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font-size: 24px;
  box-shadow: none;
}

#btvn-mp-contact-panel .btvn-mp-contact-links {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 4px;
}

#btvn-mp-contact-panel a {
  display: grid;
  min-height: 46px;
  place-items: center;
  padding: 4px;
  border: 1px solid #bb8a72;
  border-radius: 9px;
  color: #71331f;
  font-size: 14px;
  font-weight: 700;
  text-align: center;
}

#btvn-mp-contact-panel :is(button, a):focus-visible {
  outline: 2px solid #492415;
  outline-offset: -3px;
}
