/* toast.css — Toast notification styles */

#toast-container {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 400px;
  pointer-events: none;
}

.toast {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  background: #0B0B0B;
  border: 1px solid #8e7164;
  border-radius: 4px;
  color: #fcf9f3;
  font-family: Inter, sans-serif;
  font-size: 13px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  pointer-events: auto;
  opacity: 0;
  transform: translateY(-20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  animation: toast-enter 0.3s ease forwards;
}

@keyframes toast-enter {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.toast-show {
  opacity: 1;
  transform: translateY(0);
}

.toast.toast-show {
  opacity: 1;
  transform: translateY(0);
}

.toast:not(.toast-show) {
  animation: toast-exit 0.3s ease forwards;
}

@keyframes toast-exit {
  from {
    opacity: 1;
    transform: translateY(0);
  }
  to {
    opacity: 0;
    transform: translateY(-20px);
  }
}

/* Toast types */
.toast-success {
  background: #0B0B0B;
  border-color: #8e7164;
}

.toast-success .toast-icon {
  color: #4CAF50;
}

.toast-error {
  background: #0B0B0B;
  border-color: #8e7164;
}

.toast-error .toast-icon {
  color: #FF6B6B;
}

.toast-warning {
  background: #0B0B0B;
  border-color: #8e7164;
}

.toast-warning .toast-icon {
  color: #FFA500;
}

.toast-info {
  background: #0B0B0B;
  border-color: #8e7164;
}

.toast-info .toast-icon {
  color: #FF6600;
}

/* Content layout */
.toast-content {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
}

.toast-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  stroke-width: 2;
}

.toast-message {
  flex: 1;
  line-height: 1.4;
  word-break: break-word;
}

.toast-close {
  background: none;
  border: none;
  color: #c4c7c7;
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: color 0.2s ease;
}

.toast-close:hover {
  color: #fcf9f3;
}

.toast-close:focus-visible {
  outline: 2px solid #FF6600;
  outline-offset: 2px;
  border-radius: 2px;
}

/* Mobile responsive */
@media (max-width: 600px) {
  #toast-container {
    top: 12px;
    right: 12px;
    left: 12px;
    max-width: none;
  }

  .toast {
    padding: 12px 14px;
    font-size: 12px;
  }
}

/* Reduce motion */
@media (prefers-reduced-motion: reduce) {
  .toast {
    animation: none;
    opacity: 1;
    transform: none;
    transition: none;
  }

  @keyframes toast-enter {
    from {
      opacity: 1;
      transform: none;
    }
    to {
      opacity: 1;
      transform: none;
    }
  }

  @keyframes toast-exit {
    from {
      opacity: 1;
      transform: none;
    }
    to {
      opacity: 1;
      transform: none;
    }
  }
}
