/**
 * Add-to-cart toast — Minow Mango
 * Direction-neutral: logical properties only (ADR 0001).
 */

.mm-toast-region {
  position: fixed;
  inset-block-end: clamp(16px, 3vh, 32px);
  inset-inline: 0;
  display: flex;
  justify-content: center;
  padding-inline: 16px;
  z-index: 9997; /* above page content, below the drawer backdrop (9998) */
  pointer-events: none;
}

.mm-toast {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 12px;
  max-inline-size: min(480px, 100%);
  padding-block: 12px;
  padding-inline: 20px 12px;
  background: var(--clr-secondary, #0a946f);
  color: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.25);
  animation: mm-toast-in 0.25s ease;
}

.mm-toast--error {
  background: #7f1d1d;
}

@keyframes mm-toast-in {

  from { opacity: 0; transform: translateY(12px); }

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

@media (prefers-reduced-motion: reduce) {

  .mm-toast { animation: none; }
}

.mm-toast__message {
  margin: 0;

  /* Beat the global `p { color: var(--clr-text) }` rule so the message stays
     white on every variant instead of resolving dark-on-dark. */
  color: inherit;

  /* The ~13px root font makes plain rem sizes fall under the 14px type floor;
     bold-at-14px is the deliberate WCAG route for white on the brand green. */
  font-size: max(14px, 0.9rem);
  font-weight: 700;
  line-height: 1.6;
}

.mm-toast__action {
  flex-shrink: 0;
  border: none;
  cursor: pointer;
  background: var(--clr-primary, #f58220);
  color: #fff;
  font: inherit;
  font-size: max(13px, 0.85rem);
  font-weight: 700;
  padding-block: 8px;
  padding-inline: 14px;
  border-radius: 8px;
  transition: background 0.15s ease;
}

.mm-toast__action:hover {
  background: var(--clr-primary-700, #cf6311);
}

.mm-toast__dismiss {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  inline-size: 28px;
  block-size: 28px;
  border: none;
  cursor: pointer;
  background: transparent;
  color: rgba(255, 255, 255, 0.7);
  border-radius: 6px;
}

.mm-toast__dismiss:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
}
