.elv-notify-stack {
  position: fixed;
  top: calc(1rem + env(safe-area-inset-top, 0px));
  right: calc(1rem + env(safe-area-inset-right, 0px));
  z-index: 12000;
  display: grid;
  gap: 0.65rem;
  width: min(22rem, calc(100vw - 2rem));
  pointer-events: none;
}

.elv-notify {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: start;
  gap: 0.75rem;
  padding: 0.85rem 0.9rem;
  border-radius: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.72);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0.78));
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  box-shadow:
    0 18px 40px rgba(0, 0, 0, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
  opacity: 0;
  transform: translateY(-10px) scale(0.98);
  transition:
    opacity 0.32s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.36s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: auto;
}

.elv-notify.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.elv-notify.is-leaving {
  opacity: 0;
  transform: translateY(-8px) scale(0.97);
  pointer-events: none;
}

.elv-notify--cart {
  transform: translateX(18px) translateY(-6px) scale(0.96);
  transition:
    opacity 0.42s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.48s cubic-bezier(0.34, 1.18, 0.64, 1);
}

.elv-notify--cart.is-visible {
  opacity: 1;
  transform: translateX(0) translateY(0) scale(1);
}

.elv-notify--cart.is-leaving {
  opacity: 0;
  transform: translateX(12px) translateY(-4px) scale(0.97);
}

.elv-notify__icon {
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  margin-top: 0.05rem;
}

.elv-notify--cart .elv-notify__icon {
  background: rgba(0, 0, 0, 0.06);
  color: #111;
  animation: elv-notify-cart-icon 0.55s cubic-bezier(0.34, 1.35, 0.64, 1) 0.1s both;
}

@keyframes elv-notify-cart-icon {
  from {
    transform: scale(0.35);
    opacity: 0;
  }

  55% {
    transform: scale(1.1);
  }

  to {
    transform: scale(1);
    opacity: 1;
  }
}

.elv-notify--cart .elv-notify__body {
  animation: elv-notify-cart-body 0.45s cubic-bezier(0.22, 1, 0.36, 1) 0.14s both;
}

@keyframes elv-notify-cart-body {
  from {
    opacity: 0;
    transform: translateX(6px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.elv-notify--cart .elv-notify__icon::before {
  content: "";
  width: 0.55rem;
  height: 0.9rem;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translate(-1px, -1px);
}

.elv-notify--payment .elv-notify__icon {
  background: linear-gradient(145deg, #111, #333);
  color: #fff;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.18);
}

.elv-notify--payment .elv-notify__icon::before {
  content: "";
  width: 0.55rem;
  height: 0.9rem;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translate(-1px, -1px);
}

.elv-notify__body {
  min-width: 0;
}

.elv-notify__title {
  font-size: 0.86rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: #111;
}

.elv-notify__subtitle {
  margin-top: 0.18rem;
  font-size: 0.76rem;
  line-height: 1.45;
  color: rgba(0, 0, 0, 0.58);
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.elv-notify__close {
  border: none;
  background: transparent;
  color: rgba(0, 0, 0, 0.38);
  font-size: 1.2rem;
  line-height: 1;
  cursor: pointer;
  padding: 0;
  margin-top: -0.1rem;
}

.elv-notify__close:hover {
  color: rgba(0, 0, 0, 0.72);
}

@media (prefers-reduced-motion: reduce) {
  .elv-notify {
    transition: opacity 0.15s ease;
    transform: none;
  }

  .elv-notify.is-visible,
  .elv-notify--cart.is-visible {
    transform: none;
  }

  .elv-notify--cart .elv-notify__icon,
  .elv-notify--cart .elv-notify__body {
    animation: none;
  }
}

@media (max-width: 640px) {
  .elv-notify-stack {
    left: 1rem;
    right: 1rem;
    width: auto;
  }
}
