/* Toast Notification Styles */
.toast-container {
  position: fixed;
  top: 100px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  width: 90%;
  max-width: 500px;
  pointer-events: none;
}

.toast {
  background: #fff;
  border-radius: 15px;
  padding: 20px 25px;
  margin-bottom: 15px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
  display: flex;
  align-items: center;
  gap: 15px;
  opacity: 0;
  transform: translateY(-20px);
  transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  pointer-events: auto;
  position: relative;
  overflow: hidden;
}

.toast::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 5px;
  background: var(--toast-color);
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

.toast.hide {
  opacity: 0;
  transform: translateY(-20px) scale(0.9);
}

.toast-icon {
  width: 45px;
  height: 45px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: #fff;
  background: var(--toast-color);
  flex-shrink: 0;
}

.toast-content {
  flex: 1;
}

.toast-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 5px;
  color: #1a1a1a;
}

.toast-message {
  font-size: 14px;
  color: #666;
  line-height: 1.5;
}

.toast-close {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: none;
  background: #f5f5f5;
  color: #666;
  font-size: 18px;
  cursor: pointer;
  transition: all 0.3s ease;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.toast-close:hover {
  background: #e0e0e0;
  color: #333;
}

.toast-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  background: var(--toast-color);
  width: 100%;
  transform-origin: left;
  animation: progress 5s linear forwards;
  opacity: 0.3;
}

@keyframes progress {
  from {
    transform: scaleX(1);
  }
  to {
    transform: scaleX(0);
  }
}

/* Toast Types */
.toast.toast-success {
  --toast-color: #10b981;
}

.toast.toast-error {
  --toast-color: #ef4444;
}

.toast.toast-warning {
  --toast-color: #f59e0b;
}

.toast.toast-info {
  --toast-color: #3b82f6;
}

/* RTL Support */
.toast {
  direction: rtl;
  text-align: right;
}

.toast::before {
  left: auto;
  right: 0;
}

.toast-progress {
  transform-origin: right;
}

/* Responsive */
@media (max-width: 768px) {
  .toast-container {
    top: 80px;
    width: 95%;
  }

  .toast {
    padding: 15px 20px;
  }

  .toast-icon {
    width: 40px;
    height: 40px;
    font-size: 20px;
  }

  .toast-title {
    font-size: 15px;
  }

  .toast-message {
    font-size: 13px;
  }
}
