/* Completely redesigned notification system with better visual hierarchy, gradients, icons, and animations */

/* Container */
.notify-container {
  position: fixed;
  right: 24px;
  bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  z-index: 9999;
  pointer-events: none;
}

/* Toast base - Premium design */
.notify {
  min-width: 340px;
  max-width: 440px;

  padding: 16px 20px;
  border-radius: 14px;

  color: #fafafa;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.6;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;

  /* Premium glassmorphism effect */
  background: linear-gradient(135deg, rgba(20, 20, 20, 0.9) 0%, rgba(30, 30, 30, 0.85) 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);

  box-shadow: 0 0 1px rgba(255, 255, 255, 0.1), 0 8px 32px rgba(0, 0, 0, 0.5), inset 0 0 0 1px rgba(255, 255, 255, 0.05);

  animation: toastIn 0.4s cubic-bezier(0.16, 1, 0.3, 1), toastOut 0.5s ease forwards;
  animation-delay: 0s, var(--delay);
  pointer-events: auto;
  overflow: hidden;
  position: relative;
}

/* Add subtle background accent bar */
.notify::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: currentColor;
  opacity: 0.7;
}

/* Icon container */
.notify .icon {
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
}

/* Texto wrapper */
.notify .content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.notify .message {
  font-weight: 500;
  letter-spacing: 0.3px;
}

.notify .subtitle {
  font-size: 12px;
  opacity: 0.7;
  font-weight: 400;
}

/* Botão fechar */
.notify button {
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.5);
  font-size: 18px;
  cursor: pointer;
  opacity: 0.6;
  transition: opacity 0.2s, color 0.2s, transform 0.2s;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
}

.notify button:hover {
  opacity: 1;
  color: #fafafa;
  background: rgba(255, 255, 255, 0.1);
  transform: scale(1.1);
}

/* ================= CORES POR TIPO ================= */

/* Sucesso - Verde vibrante */
.notify.success {
  color: #22c55e;
  background: linear-gradient(135deg, rgba(16, 50, 20, 0.9) 0%, rgba(20, 35, 25, 0.85) 100%);
  border: 1px solid rgba(34, 197, 94, 0.15);
}

.notify.success .icon {
  background: rgba(34, 197, 94, 0.15);
  color: #22c55e;
}

/* Erro - Vermelho (principal do Hakari) */
.notify.error {
  color: #fca5a5;
  background: linear-gradient(135deg, rgba(50, 15, 15, 0.95) 0%, rgba(40, 20, 20, 0.9) 100%);
  border: 1px solid rgba(220, 38, 38, 0.2);
}

.notify.error .icon {
  background: rgba(220, 38, 38, 0.15);
  color: #dc2626;
}

/* Warning - Âmbar */
.notify.warning {
  color: #fbbf24;
  background: linear-gradient(135deg, rgba(50, 35, 10, 0.95) 0%, rgba(40, 30, 15, 0.9) 100%);
  border: 1px solid rgba(245, 158, 11, 0.15);
}

.notify.warning .icon {
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
}

/* Info - Azul */
.notify.info {
  color: #93c5fd;
  background: linear-gradient(135deg, rgba(15, 25, 50, 0.95) 0%, rgba(20, 30, 45, 0.9) 100%);
  border: 1px solid rgba(59, 130, 246, 0.15);
}

.notify.info .icon {
  background: rgba(59, 130, 246, 0.15);
  color: #3b82f6;
}

/* ================= ANIMAÇÕES ================= */

@keyframes toastIn {
  from {
    opacity: 0;
    transform: translateX(100px) translateY(20px) scale(0.9);
  }
  to {
    opacity: 1;
    transform: translateX(0) translateY(0) scale(1);
  }
}

@keyframes toastOut {
  to {
    opacity: 0;
    transform: translateX(120px) translateY(20px) scale(0.85);
  }
}

/* Responsive */
@media (max-width: 480px) {
  .notify-container {
    right: 12px;
    bottom: 12px;
    left: 12px;
    gap: 12px;
  }

  .notify {
    min-width: auto;
    max-width: none;
    padding: 14px 16px;
  }

  .notify .icon {
    width: 28px;
    height: 28px;
    font-size: 16px;
  }
}
