/* Toast + pulso no ícone ao adicionar ao carrinho (WooCommerce AJAX) */
.kond-atc-toast {
  position: fixed;
  z-index: 100000;
  left: 50%;
  bottom: max(24px, env(safe-area-inset-bottom, 0px));
  max-width: calc(100vw - 32px);
  width: min(400px, calc(100vw - 32px));
  padding: 14px 18px 14px 16px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.35;
  color: #0f172a;
  background: #fff;
  border: 1px solid rgba(13, 83, 252, 0.14);
  border-radius: 14px;
  box-shadow:
    0 4px 6px rgba(15, 23, 42, 0.04),
    0 18px 48px rgba(13, 83, 252, 0.12);
  pointer-events: none;
  opacity: 0;
  transform: translateX(-50%) translateY(20px) scale(0.96);
  transition:
    opacity 0.38s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.38s cubic-bezier(0.16, 1, 0.3, 1);
}

.kond-atc-toast.kond-atc-toast--vis {
  opacity: 1;
  transform: translateX(-50%) translateY(0) scale(1);
}

.kond-atc-toast__ic {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #0d53fc, #77d1f3);
  color: #fff;
  font-size: 18px;
}

.kond-atc-toast__txt {
  flex: 1;
  min-width: 0;
}

.kond-atc-badge-pulse {
  animation: kondAtcBadgePulse 0.75s cubic-bezier(0.16, 1, 0.3, 1) 1;
}

@keyframes kondAtcBadgePulse {
  0% {
    transform: scale(1);
  }
  35% {
    transform: scale(1.22);
  }
  100% {
    transform: scale(1);
  }
}

/* Flyer: miniatura que viaja até o ícone do carrinho */
.kond-atc-flyer {
  position: fixed;
  z-index: 99999;
  pointer-events: none;
  border-radius: 12px;
  overflow: hidden;
  box-shadow:
    0 8px 28px rgba(15, 23, 42, 0.18),
    0 2px 8px rgba(13, 83, 252, 0.12);
  transform-origin: center center;
  will-change: transform, opacity;
  contain: strict;
}

.kond-atc-flyer img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  vertical-align: top;
}

.kond-atc-flyer--fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #0d53fc, #77d1f3);
  color: #fff;
  font-size: 22px;
}

@media (prefers-reduced-motion: reduce) {
  .kond-atc-toast {
    transition: opacity 0.2s ease;
    transform: translateX(-50%) translateY(0);
  }

  .kond-atc-toast:not(.kond-atc-toast--vis) {
    transform: translateX(-50%) translateY(8px);
  }

  .kond-atc-badge-pulse {
    animation: none;
  }

  .kond-atc-flyer {
    display: none !important;
  }
}
