/* ==========================================================================
   San Modesto Vet Clinic - Top-Right Toast Notifications
   Based on Gold, Black, White & Navy palette with entrance slide animation
   ========================================================================== */

.toast-container {
  position: fixed;
  top: 1.5rem;
  right: 1.5rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  pointer-events: none;
  max-width: 400px;
  width: calc(100% - 3rem);
}

.toast-alert {
  pointer-events: auto;
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  padding: 1rem 1.25rem;
  background: var(--navy-dark);
  border-radius: var(--radius-md);
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.6), 0 0 15px rgba(212, 175, 55, 0.1);
  color: var(--white);
  border: 1px solid var(--black-border);
  position: relative;
  overflow: hidden;
  transform: translateX(120%);
  opacity: 0;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
}

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

.toast-alert.hide {
  transform: translateX(120%);
  opacity: 0;
}

/* Success Toast - Gold & Emerald */
.toast-alert.toast-success {
  border-left: 4px solid var(--gold-primary);
  border-color: var(--gold-border);
}

.toast-alert.toast-success .toast-icon {
  color: var(--gold-primary);
  background: rgba(212, 175, 55, 0.15);
  border: 1px solid var(--gold-border);
}

/* Error / Failed Toast - Gold & Crimson */
.toast-alert.toast-error {
  border-left: 4px solid var(--danger);
  border-color: rgba(239, 68, 68, 0.3);
}

.toast-alert.toast-error .toast-icon {
  color: var(--danger);
  background: var(--danger-bg);
  border: 1px solid rgba(239, 68, 68, 0.3);
}

/* Warning Toast */
.toast-alert.toast-warning {
  border-left: 4px solid var(--warning);
  border-color: rgba(245, 158, 11, 0.3);
}

.toast-alert.toast-warning .toast-icon {
  color: var(--warning);
  background: var(--warning-bg);
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.toast-icon {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.toast-icon svg {
  width: 17px;
  height: 17px;
}

.toast-content {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.toast-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--white);
  line-height: 1.3;
}

.toast-message {
  font-size: 0.78rem;
  color: var(--text-secondary);
  margin-top: 0.2rem;
  line-height: 1.4;
}

.toast-close {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
  margin-left: 0.5rem;
}

.toast-close:hover {
  color: var(--white);
  background: rgba(255, 255, 255, 0.1);
}

/* Progress bar inside toast */
.toast-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 2.5px;
  background: var(--gold-gradient);
  width: 100%;
  animation: toastProgress 4.5s linear forwards;
}

.toast-alert.toast-error .toast-progress {
  background: var(--danger);
}

@keyframes toastProgress {
  from { width: 100%; }
  to { width: 0%; }
}
