/* =========================
   DIG - Woo Toast Notice
   ========================= */

:root{
  --dig-toast-bg: rgba(7, 12, 9, 0.86);
  --dig-toast-border: rgba(45,255,111,0.35);
  --dig-toast-text: rgba(245,250,246,0.92);
  --dig-toast-muted: rgba(245,250,246,0.70);
  --dig-toast-accent: #2dff6f;
}

.dig-toast-wrap{
  position: fixed;
  top: 18px;
  right: 18px;
  z-index: 999999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

@media (max-width: 640px){
  .dig-toast-wrap{
    left: 12px;
    right: 12px;
    top: 12px;
  }
}

.dig-toast{
  pointer-events: auto;
  display: grid;
  grid-template-columns: 22px 1fr auto 28px;
  gap: 12px;
  align-items: center;

  width: min(520px, calc(100vw - 24px));
  padding: 14px 14px;
  border-radius: 18px;

  border: 1px solid var(--dig-toast-border);
  background: var(--dig-toast-bg);
  backdrop-filter: blur(10px);

  color: var(--dig-toast-text);
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  box-shadow: 0 18px 40px rgba(0,0,0,0.35);

  transform: translateY(-10px);
  opacity: 0;
  animation: digToastIn .18s ease forwards;
}

@keyframes digToastIn{
  to { transform: translateY(0); opacity: 1; }
}

.dig-toast.is-leave{
  animation: digToastOut .16s ease forwards;
}
@keyframes digToastOut{
  to { transform: translateY(-10px); opacity: 0; }
}

.dig-toast__icon{
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(45,255,111,0.14);
  border: 1px solid rgba(45,255,111,0.30);
  color: var(--dig-toast-accent);
  font-weight: 900;
  line-height: 1;
}

.dig-toast__msg{
  font-size: 14px;
  line-height: 1.35;
  color: var(--dig-toast-text);
}
.dig-toast__msg b,
.dig-toast__msg strong{ color: var(--dig-toast-text); }

.dig-toast__btn{
  /* important khusus tombol biar ga ketumpuk theme/woo */
  all: unset;
  cursor: pointer;
  user-select: none;

  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 42px;
  padding: 0 16px;
  border-radius: 999px;

  background: var(--dig-toast-accent);
  color: #062012;
  font-weight: 900;
  font-size: 14px;

  border: 1px solid rgba(45,255,111,0.75);
}

.dig-toast__btn:hover{ opacity: .95; }

.dig-toast__close{
  all: unset;
  cursor: pointer;

  width: 28px;
  height: 28px;
  border-radius: 10px;

  display: grid;
  place-items: center;

  border: 1px solid rgba(255,255,255,0.10);
  background: rgba(255,255,255,0.04);
  color: rgba(245,250,246,0.86);
  font-size: 18px;
  line-height: 1;
}

.dig-toast__close:hover{
  border-color: rgba(45,255,111,0.25);
  background: rgba(45,255,111,0.08);
}

/* Sembunyikan notice bawaan Woo (tapi tetap ada utk JS ambil isi) */
.woocommerce-notices-wrapper{
  position: absolute !important;
  left: -99999px !important;
  top: -99999px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* hormati reduce motion */
@media (prefers-reduced-motion: reduce){
  .dig-toast{ animation: none; transform: none; opacity: 1; }
  .dig-toast.is-leave{ animation: none; opacity: 0; }
}
