﻿.toast-container {
  position: fixed;
  bottom: 28px;
  right: 24px;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff;
  border-radius: 14px;
  padding: 14px 16px 14px 14px;
  min-width: 300px;
  max-width: 360px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.13), 0 2px 8px rgba(0,0,0,0.08);
  border-left: 4px solid #111;
  position: relative;
  overflow: hidden;
  pointer-events: all;
  transform: translateX(calc(100% + 32px));
  opacity: 0;
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.3s ease;
}

.toast.show {
  transform: translateX(0);
  opacity: 1;
}

.toast.hiding {
  transform: translateX(calc(100% + 32px));
  opacity: 0;
}

/* Tipos */
.toast--add    { border-left-color: #16a34a; }
.toast--remove { border-left-color: #dc2626; }
.toast--stock  { border-left-color: #d97706; }

/* Ãcono */
.toast-icon {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #fff;
}

.toast--add    .toast-icon { background: #16a34a; }
.toast--remove .toast-icon { background: #dc2626; }
.toast--stock  .toast-icon { background: #d97706; }

/* Thumbnail producto */
.toast-thumb {
  width: 40px;
  height: 40px;
  object-fit: contain;
  border-radius: 8px;
  background: #f5f5f5;
  flex-shrink: 0;
}

/* Texto */
.toast-body { flex: 1; min-width: 0; }

.toast-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: #999;
  margin-bottom: 2px;
}

.toast-msg {
  font-size: 13px;
  font-weight: 600;
  color: #111;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* BotÃ³n cerrar */
.toast-dismiss {
  background: none;
  border: none;
  cursor: pointer;
  color: #bbb;
  padding: 2px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  transition: color 0.2s;
}

.toast-dismiss:hover { color: #555; }

/* Barra de progreso */
.toast-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  width: 100%;
  background: currentColor;
  opacity: 0.15;
  transform-origin: left;
  animation: toast-drain 3.5s linear forwards;
}

@keyframes toast-drain {
  from { transform: scaleX(1); }
  to   { transform: scaleX(0); }
}

@media (max-width: 480px) {
  .toast-container {
    bottom: 16px;
    right: 12px;
    left: 12px;
  }
  .toast {
    min-width: unset;
    max-width: 100%;
  }
}

