/* Overlay */
.cart-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0); /* start transparent */
  z-index: 9998;
  pointer-events: none; /* not clickable initially */
  transition: background-color 0.4s ease;
  display: block; /* always in DOM */
}

/* Overlay active state */
.cart-overlay.active {
  background: rgba(0, 0, 0, 0.8);
  pointer-events: auto; /* clickable */
}

/* Cart modal */
.cart-modal {
  position: fixed;
  top: 0;
  right: 0;
  width: 418px;
  height: 100%;
  background: var(--black_white50);
  box-shadow: -2px 0 8px rgba(0, 0, 0, 0.3);
  z-index: 9999;
  overflow-y: auto;
  scrollbar-width: thin;
  transform: translateX(100%); /* hidden offscreen */
  transition: transform 0.4s ease;
  display: block; /* always in DOM */
}

.empty-cart-logo {
  display: flex; 
  flex-direction: column; 
  align-items: center;
  justify-content: center;
  gap: 24px;
  flex: 1;
}
.empty-cart-logo > img {
  width: 91.54px;
  height: 70px;
}

.continue-shopping-controller {
  margin-bottom: 32px;
  transition: margin-bottom 0.4s ease;
}

/* Cart active state */
.cart-modal.active {
  transform: translateX(0); /* slide in */
}

/* upper part */
.mini-cart-upper-part {
  display: flex;
  align-items: center;
  color: var(--black_white950);
  background: var(--black_white50);
  gap: 12px;
  justify-content: space-between;
  padding: 32px 24px 24px;
  border-bottom: 1px solid var(--neutral200);
  position: -webkit-sticky;
  position: sticky;
  top: 0;
  z-index: 1;
  transition: padding 0.4s ease;
}
.mini-cart-upper-part svg {
  height: 26px;
  width: 26px;
}
.mini-cart-title {
  display: flex;
  align-items: center;
  gap: 8px;
}
.mini-cart-title svg {
  height: 40px;
  width: 40px;
}
.cart-close {
  transition: color 0.4s ease;
}
.cart-close:hover {
  color: var(--primary500);
  cursor: pointer;
}

.cart-items {
  display: flex;
  flex-direction: column;
  min-height: calc(100vh - 97px);
  padding: 24px 24px 0px;
  transition: padding 0.4s ease;
}
.cart-items ul {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
/* cart-item */
.prop-cart-item {
  border-bottom: 1px solid var(--neutral200);
}
.prop-cart-item:last-child {
  border-bottom: none;
}
.mini-cart-item-inner {
  display: flex;
  gap: 16px;
  padding-bottom: 16px;
}
.mini-cart-thumbnail {
  height: 110px;
  width: 110px;
  min-width: 110px;
  border-radius: 8px;
  overflow: hidden;
}
.mini-cart-thumbnail img {
  height: 100%;
  width: 100%;
  -o-object-fit: contain;
     object-fit: contain;
}
.mini-cart-details {
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}
.mini-cart-product-name a {
  color: var(--black_white950);
}
.mini-cart-price .btn-sm-medium {
  color: var(--primary500);
}
.mini-cart-price .body-sm-regular {
  color: var(--neutral400);
}
.quantity-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.custom-remove-btn {
  display: block;
  color: var(--neutral500);
  width: -webkit-max-content;
  width: -moz-max-content;
  width: max-content;
  transition: color 0.4s ease;
}
.custom-remove-btn svg {
  height: 20px;
  width: 20px;
}
.custom-remove-btn:hover {
  color: var(--primary500);
}
/* bottom part */
.continue-shopping-controller {
  margin-top: auto;
}
.mini-cart-bottom-part {
  margin-top: auto;
  position: -webkit-sticky;
  position: sticky;
  bottom: 0;
  padding-top: 32px;
  padding-bottom: 32px;
  color: var(--black_white950);
  background: var(--black_white50);
  transition: padding-top 0.4s ease, padding-bottom 0.4s ease;
}
.mini-cart-bottom-part::before {
  content: "";
  position: absolute;
  top: 0;
  left: -24px;
  right: -24px;
  height: 1px;
  background: var(--neutral200);
}
.lock-icon {
  height: 18px;
  width: 18px;
}
.total-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.total-title span.body-sm-regular {
  color: var(--neutral400);
}
.mini-cart-description {
  color: var(--neutral500);
  padding: 12px 0 16px;
}

/* ??? */
.checkout-btn {
  display: block;
  background: #000;
  color: #fff;
  text-align: center;
  padding: 10px;
  text-decoration: none;
}

.added_to_cart.wc-forward {
  display: none;
}
@media (max-width: 768px) {
  .mini-cart-upper-part {
    padding: 30px 16px 24px;
  }
  .cart-items {
    padding: 20px 16px 0px;
  }
  .cart-modal {
    width: 100%;
  }
  /* bottom part */
  .mini-cart-bottom-part {
    padding-top: 16px;
  }
  .mini-cart-bottom-part::before {
    right: -16px;
    left: -16px;
  }
  .mini-cart-bottom-part {
    padding-bottom: 24px;
  }
  .continue-shopping-controller {
    margin-bottom: 24px;
  }
}
