.floating-widget {
  position: fixed;
  bottom: 25px;
  right: 25px;
  z-index: 60;
}
.widget-button {
  background: transparent !important;
  border: none;
  padding: 0;
  box-shadow: none;
  cursor: pointer;
  transition: transform .25s ease;
}
.widget-button:hover {
  transform: scale(1.1);
}

/* 🔹 Card umum */
.widget-card {
  position: absolute;
  background: #ffffffee;
  backdrop-filter: blur(10px);
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.12);
  padding: 10px 14px;
  color: #1e3a8a;
  font-weight: 600;
  font-size: 14px;
  opacity: 0;
  transform: translateY(10px);
  transition: all .4s ease-out;
}
.widget-card:hover {
  background: #f0f9ff;
  color: #2563eb;
}

/* 🔹 Posisi card */
.widget-card-top {
  bottom: 90px;
  right: 0;
}
.widget-card-left {
  bottom: 0;
  right: 70px;
}

/* 🔹 Transisi muncul */
[x-show="openWidget"].widget-card {
  opacity: 1 !important;
  transform: translateY(0) !important;
}
#purchaseToast {
  position: fixed;
  bottom: 10px;
  left: 10px;
  z-index: 9999 !important;
  width: 320px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.12);
  padding: 10px 14px;
  font-size: 13.5px;
  line-height: 1.5;
  opacity: 0;
  transform: translateY(25px);
  transition: all 0.5s ease;
}

/* Muncul halus */
#purchaseToast.show {
  opacity: 1;
  transform: translateY(0);
  animation: fadeInToast 0.5s ease-out;
}

/* Hilang halus */
#purchaseToast.hide {
  opacity: 0;
  transform: translateY(25px);
  animation: fadeOutToast 0.5s ease-in forwards;
}

/* Animasi keyframes */
@keyframes fadeInToast {
  from { opacity: 0; transform: translateY(25px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeOutToast {
  from { opacity: 1; transform: translateY(0); }
  to { opacity: 0; transform: translateY(25px); }
}

/* 📱 Versi mobile (lebih kecil & mepet kiri) */
@media (max-width: 768px) {
  #purchaseToast {
    width: 180px;
    left: 8px;
    bottom: 8px;
    padding: 7px 10px;
    font-size: 11.5px;
    border-radius: 8px;
    line-height: 1.35;
  }

  /* 🔹 Perbesar judul "Pesanan Sukses!" di mobile */
  #purchaseToast .font-semibold.text-gray-800 {
    font-size: 13px !important;
    font-weight: 700 !important;
    color: #111827 !important; /* sedikit lebih gelap biar kontras */
  }
}

@keyframes fadeInToast {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
.animate-fade-in { animation: fadeInToast 0.4s ease-out; }
@keyframes fadeIn {
  from {opacity: 0; transform: translateY(10px);}
  to {opacity: 1; transform: translateY(0);}
}
.animate-fade-in {animation: fadeIn .4s ease;}
