.sticky-add-to-cart {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  background: rgba(var(--color-background), 0.98);
  backdrop-filter: blur(10px);
  box-shadow: 0 -2px 10px rgba(var(--color-shadow), 0.1);
  padding: 1rem 1.5rem;
  transform: translateY(100%);
  transition: transform 0.3s ease-in-out;
  border-top: 1px solid rgba(var(--color-foreground), 0.1);
  @media screen and (min-width: 750px) {
    padding: 1rem 5rem;
  }
}

.sticky-add-to-cart.visible {
  transform: translateY(0);
}

.sticky-add-to-cart.hidden {
  display: none;
}

.sticky-add-to-cart__container {
  max-width: var(--page-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 1rem;
  justify-content: space-between;
}

.sticky-add-to-cart__product-info {
  flex: 1 1 auto;
  min-width: 400px;
  max-width: 600px;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  margin-right: auto;
}

.sticky-add-to-cart__product-name {
  font-size: 1.6rem;
  font-weight: 600;
  color: rgba(var(--color-foreground), 0.9);
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  margin: 0;
}

.sticky-add-to-cart__price {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
}

.sticky-add-to-cart__price .price {
  margin: 0;
  display: block !important;
  opacity: 1 !important;
  visibility: visible !important;
}

.sticky-add-to-cart__price .price--sticky {
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.2;
}

.sticky-add-to-cart__price .price--sticky * {
  opacity: 1 !important;
  visibility: visible !important;
}

.sticky-add-to-cart__price .price-item {
  font-size: 1.5rem !important;
  font-weight: 700 !important;
  display: inline-block !important;
  opacity: 1 !important;
  visibility: visible !important;
}

.sticky-add-to-cart__price .price__regular,
.sticky-add-to-cart__price .price__sale {
  display: flex !important;
  align-items: center !important;
  gap: 0.5rem !important;
}

.sticky-add-to-cart__price .price__regular .price-item--regular {
  color: rgba(var(--color-foreground), 0.9);
}

.sticky-add-to-cart__price .price__sale .price-item--regular {
  text-decoration: line-through;
  opacity: 0.5 !important;
  font-size: 1.25rem !important;

}

.sticky-add-to-cart__price .price__sale .price-item--sale {
  color: rgba(var(--color-foreground), 0.9) !important;
}

.sticky-add-to-cart__button {
  flex: 0 1 auto;
  max-width: 300px;
  background-color: rgb(147, 112, 66);
  color: rgb(var(--color-button-text));
  border-radius: var(--buttons-radius-outset);
  border: none;
  box-shadow: none !important;
  padding: 1rem 2rem;
  font-size: 1.6rem;
  text-transform: uppercase;
  cursor: pointer;
  transition: opacity 0.2s ease, transform 0.2s ease;
  position: relative;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
}

.sticky-add-to-cart__button:hover:not(:disabled) {
  opacity: 0.9;
  transform: translateY(-1px);
}

.sticky-add-to-cart__button:active:not(:disabled) {
  transform: translateY(0);
}

.sticky-add-to-cart__button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.sticky-add-to-cart__button.loading {
  pointer-events: none;
}

.sticky-add-to-cart__button:before,
.sticky-add-to-cart__button:after {
  box-shadow: none !important;
}

.sticky-add-to-cart__button-text {
  display: inline-block;
}

.sticky-add-to-cart__button .loading__spinner {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
}

.sticky-add-to-cart__button .loading__spinner.hidden {
  display: none;
}

@media screen and (max-width: 899px) {
  .sticky-add-to-cart {
    padding: 1rem;
  }

  .sticky-add-to-cart__container {
    flex-direction: column;
    gap: 1rem;
    align-items: stretch;
  }

  .sticky-add-to-cart__product-info {
    min-width: 100%;
    max-width: 100%;
    flex-direction: column;
    gap: 0.5rem;
    align-items: flex-start;
  }

  .sticky-add-to-cart__product-name {
    font-size: 1.4rem;
    max-width: none;
    width: 100%;
  }

  .sticky-add-to-cart__price {
    width: 100%;
  }

  .sticky-add-to-cart__price .price--sticky {
    font-size: 1.4rem;
  }

  .sticky-add-to-cart__price .price-item {
    font-size: 1.4rem !important;
  }

  .sticky-add-to-cart__price .price__sale .price-item--regular {
    font-size: 1.2rem !important;
  }

  .sticky-add-to-cart__button {
    width: 100%;
    max-width: 100%;
    padding: 1rem 2rem;
    font-size: 1.4rem;
    margin: 0;
  }
}

body.cart-drawer-open .sticky-add-to-cart,
body.modal-open .sticky-add-to-cart {
  display: none !important;
}

cart-drawer.active ~ sticky-add-to-cart,
cart-drawer.active + sticky-add-to-cart {
  display: none !important;
}

body:has(cart-drawer.active) .sticky-add-to-cart {
  display: none !important;
}

