/**
 * ANBOOST Storefront V1.5 — Toast / feedback polish
 * Restyles toastr visually. Existing toastr.success/error/warning call sites unchanged.
 */

#toast-container {
  z-index: 100000;
  pointer-events: none;
}

#toast-container > div {
  pointer-events: auto;
  width: min(360px, calc(100vw - 1.5rem));
  padding: 0.95rem 1rem 0.95rem 3.25rem;
  margin: 0 0 0.65rem;
  border-radius: var(--sf-radius-md);
  border: 1px solid transparent;
  box-shadow: var(--sf-shadow-md);
  opacity: 1;
  color: var(--sf-heading);
  font-family: var(--sf-font-body);
  font-size: 0.925rem;
  line-height: 1.45;
  background-position: 1rem center;
  transition:
    opacity var(--sf-duration) var(--sf-ease),
    transform var(--sf-duration) var(--sf-ease),
    box-shadow var(--sf-duration) var(--sf-ease);
}

#toast-container > div:hover {
  box-shadow: var(--sf-shadow-lg);
  opacity: 1;
  cursor: default;
}

#toast-container .toast-title {
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 0.15rem;
  color: inherit;
}

#toast-container .toast-message {
  color: inherit;
  opacity: 0.92;
}

#toast-container .toast-message a {
  color: inherit;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

#toast-container .toast-close-button {
  top: 0.45rem;
  right: 0.55rem;
  color: inherit;
  text-shadow: none;
  opacity: 0.55;
  font-weight: 500;
  font-size: 1.15rem;
}

#toast-container .toast-close-button:hover,
#toast-container .toast-close-button:focus {
  opacity: 1;
  color: inherit;
}

#toast-container .toast-progress {
  height: 3px;
  opacity: 0.35;
  background-color: currentColor;
}

/* Success */
#toast-container > .toast-success {
  background-color: var(--sf-success-bg) !important;
  border-color: var(--sf-success-border) !important;
  color: var(--sf-success) !important;
}

/* Error */
#toast-container > .toast-error {
  background-color: var(--sf-error-bg) !important;
  border-color: var(--sf-error-border) !important;
  color: var(--sf-error) !important;
}

/* Warning */
#toast-container > .toast-warning {
  background-color: var(--sf-warning-bg) !important;
  border-color: var(--sf-warning-border) !important;
  color: var(--sf-warning) !important;
}

/* Info */
#toast-container > .toast-info {
  background-color: var(--sf-info-bg) !important;
  border-color: var(--sf-info-border) !important;
  color: var(--sf-info) !important;
}

/* RTL toast close */
[dir="rtl"] #toast-container > div {
  padding: 0.95rem 3.25rem 0.95rem 1rem;
  background-position: right 1rem center;
}

[dir="rtl"] #toast-container .toast-close-button {
  right: auto;
  left: 0.55rem;
}

@media (max-width: 480px) {
  #toast-container.toast-top-right,
  #toast-container.toast-top-left,
  #toast-container.toast-bottom-right,
  #toast-container.toast-bottom-left {
    left: 0.75rem;
    right: 0.75rem;
    width: auto;
  }

  #toast-container > div {
    width: 100%;
  }
}
