/* ========== LUXURY MINIMAL LIVE CART (Compact Patched) ========== */

.sf-cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(4px);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 9998;
}
.sf-cart-overlay.active {
  opacity: 1;
  visibility: visible;
}

.sf-live-cart-drawer {
  position: fixed;
  top: 0;
  right: -100%;
  width: 420px;
  max-width: 100%;
  height: 100vh;
  background: #fff;
  box-shadow: -4px 0 20px rgba(0, 0, 0, 0.15);
  display: flex;
  flex-direction: column;
  transform: translateX(0);
  transition: right 0.45s cubic-bezier(0.65, 0, 0.35, 1);
  z-index: 9999;
  font-family: 'Inter', 'Helvetica Neue', Arial, sans-serif;
}
.sf-live-cart-drawer.open {
  right: 0;
}

/* ===== HEADER ===== */
.sf-cart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 28px;
  border-bottom: 1px solid #e9e9e9;
  background: #fff;
}
.sf-cart-header h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #111;
  margin: 0;
}
.sf-close-cart {
  background: none;
  border: none;
  color: #111;
  cursor: pointer;
  line-height: 1;
  transition: opacity 0.2s ease;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.sf-close-cart:hover {
  opacity: 0.6;
}

/* ===== BODY ===== */
.sf-cart-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px 28px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  background: #fff;
}
.sf-cart-empty {
  text-align: center;
  color: #777;
  font-size: 1rem;
  margin-top: 40px;
}

/* ===== CART ITEM ===== */
.sf-cart-item {
  display: flex;
  align-items: center;
  gap: 14px;
  border-bottom: 1px solid #f1f1f1;
  padding-bottom: 14px;
}
.sf-cart-thumb img {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid #eee;
}
.sf-cart-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.sf-cart-name {
  font-size: 1rem;
  font-weight: 500;
  color: #111;
}
.sf-cart-price {
  color: #555;
  font-size: 0.95rem;
}

/* ===== QUANTITY SECTION ===== */
.sf-cart-qty {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
}

/* Quantity Buttons (compact + modern) */
.sf-qty-minus,
.sf-qty-plus,
.sf-qty-btn {
  width: 28px !important;
  height: 28px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  border-radius: 6px !important;
  border: 1px solid rgba(0,0,0,0.08) !important;
  background: #fff !important;
  color: #111 !important;
  font-size: 0 !important;
  cursor: pointer;
  transition: all 0.2s ease;
}
.sf-qty-minus:hover,
.sf-qty-plus:hover {
  background: #f3f3f3 !important;
}

/* Quantity Input (matching compact buttons) */
.sf-qty-input {
  width: 42px !important;
  height: 28px !important;
  text-align: center;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 0.9rem;
  color: #111;
  font-weight: 600;
}

/* Remove Button */
.sf-remove-item {
  background: none;
  border: none;
  color: #888;
  width: 28px !important;
  height: 28px !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  cursor: pointer;
  transition: color 0.2s ease, background 0.2s ease;
}
.sf-remove-item:hover {
  color: #000;
  background: #f6f6f6;
}
/* ===== FOOTER ===== */
.sf-cart-footer {
  border-top: 1px solid #e9e9e9;
  background: #fff;
  padding: 18px 28px 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: sticky;
  bottom: 0;
}

.sf-cart-subtotal {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.95rem;
  color: #222;
}
.sf-cart-subtotal strong {
  font-weight: 600;
  font-size: 1rem;
  color: #000;
}

/* ===== ACTION BUTTONS ===== */
.sf-cart-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.sf-cart-view-btn,
.sf-cart-checkout-btn,
.sf-cart-continue {
  display: block;
  text-align: center;
  padding: 11px 16px;
  font-size: 0.93rem;
  font-weight: 500;
  border-radius: 10px;
  transition: all 0.25s ease;
  text-decoration: none;
  cursor: pointer;
}

/* Checkout button (primary) */
.sf-cart-checkout-btn {
  background: #000;
  color: #fff;
  border: none;
}
.sf-cart-checkout-btn:hover {
  background: #222;
}

/* View Cart (secondary) */
.sf-cart-view-btn {
  border: 1px solid #000;
  color: #000;
  background: transparent;
}
.sf-cart-view-btn:hover {
  background: #000;
  color: #fff;
}

/* Continue Shopping (link style) */
.sf-cart-continue {
  color: #777;
  text-decoration: underline;
  text-align: center;
  font-size: 0.88rem;
}
.sf-cart-continue:hover {
  color: #000;
}

/* ===== SCROLLBAR ===== */
.sf-cart-body::-webkit-scrollbar {
  width: 6px;
}
.sf-cart-body::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 4px;
}
.sf-cart-body::-webkit-scrollbar-thumb:hover {
  background: #999;
}

/* ===== OPEN / CLOSE ANIMATION ===== */
.sf-live-cart-drawer {
  transition: right 0.45s cubic-bezier(0.65, 0, 0.35, 1);
}
.sf-live-cart-drawer.open {
  right: 0;
}

/* Smooth bump animation on cart count */
@keyframes bump {
  0% { transform: scale(1); }
  20% { transform: scale(1.2); }
  40% { transform: scale(1); }
  100% { transform: scale(1); }
}
.sf-cart-bump {
  animation: bump 0.4s ease;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 600px) {
  .sf-live-cart-drawer {
    width: 100%;
  }
  .sf-cart-header,
  .sf-cart-body,
  .sf-cart-footer {
    padding-left: 20px;
    padding-right: 20px;
  }
  .sf-cart-thumb img {
    width: 56px;
    height: 56px;
  }
  .sf-cart-item {
    gap: 10px;
  }
  .sf-qty-minus,
  .sf-qty-plus,
  .sf-remove-item {
    width: 26px !important;
    height: 26px !important;
  }
  .sf-qty-input {
    width: 38px !important;
    height: 26px !important;
    font-size: 0.85rem !important;
  }
  .sf-cart-checkout-btn,
  .sf-cart-view-btn {
    font-size: 0.9rem;
    padding: 10px 14px;
  }
}

/* ===== Compact Mode Override for SVG-injected Buttons ===== */
.sf-qty-minus svg,
.sf-qty-plus svg,
.sf-remove-item svg,
.sf-close-cart svg {
  width: 14px !important;
  height: 14px !important;
}

/* --- Force checkout button white text --- */
.sf-cart-checkout-btn {
  color: #fff !important;
  background-color: #000 !important; /* optional: keeps the luxury black look */
  border: 1px solid #000;
  transition: all 0.3s ease;
}

.sf-cart-checkout-btn:hover {
  background-color: #111 !important;
  color: #fff !important;
}

/* Keep your inner cart panel styled correctly */
.sf-live-cart-drawer.open .sf-cart-body,
.sf-live-cart__body,
.sf-cart-scroll {
  flex: 1 1 auto !important;
  min-height: 0 !important;
  overflow-y: auto !important;
  -webkit-overflow-scrolling: touch !important;
  overscroll-behavior: contain !important;
  touch-action: auto !important;
  pointer-events: auto !important;
  max-height: calc(100vh - 140px) !important; /* fits under header/footer */
}

/* ============================================================
   🛒 LUXURY CART ICON — VERIFIED BADGE VERSION
   ============================================================ */

.sf-cart-button,
.sf-cart-btn,
.sf-cart-floating-btn {
  position: fixed !important;
  left: 22px !important;
  bottom: 88px !important;
  width: 58px !important;
  height: 58px !important;
  border-radius: 50% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: #fff !important;
  border: 2px solid #000 !important;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15) !important;
  cursor: pointer !important;
  z-index: 10000 !important;
  transition: all 0.25s ease !important;
}

.sf-cart-button:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.25) !important;
}

/* Cart Icon SVG */
.sf-cart-icon::before {
  content: "" !important;
  display: inline-block !important;
  width: 22px !important;
  height: 22px !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
  background-size: 100% 100% !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' stroke='%23000' fill='none' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' viewBox='0 0 24 24'%3E%3Cpath d='M3 3h2l1.5 9h11L21 7H8'/%3E%3Ccircle cx='10.5' cy='19' r='1.4' fill='%23000'/%3E%3Ccircle cx='17.5' cy='19' r='1.4' fill='%23000'/%3E%3C/svg%3E") !important;
}

/* Red circular badge */
.sf-cart-button .sf-cart-count,
.sf-cart-btn .sf-cart-count,
.sf-cart-floating-btn .sf-cart-count {
  position: absolute !important;
  top: 4px !important;
  right: -4px !important;
  width: 20px !important;
  height: 20px !important;
  border-radius: 50% !important;
  background: #ff3333 !important;
  color: #fff !important;
  font-weight: 700 !important;
  font-size: 11px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-shadow: 0 3px 8px rgba(255, 0, 0, 0.35) !important;
  transform: scale(1);
  transition: transform 0.3s ease;
}

/* Quick pulse animation */
@keyframes sfPulseOnce {
  0% { transform: scale(1); }
  40% { transform: scale(1.4); }
  100% { transform: scale(1); }
}

.sf-cart-pulse-once {
  animation: sfPulseOnce 0.5s ease-out;
}

