/* ==========================================
   GLOBAL NOTIFICATION SYSTEM STYLES
   For toast-style notifications (success, error, info, warning)
   Used by notification-system.js
   ========================================== */

/* Notification container */
.notification-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 30000; /* CRITICAL FIX: Higher than loading overlays (20000) to ensure visibility */
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

/* Base notification styles */
.notification {
  min-width: 300px;
  max-width: 400px;
  padding: 16px 20px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 15px;
  font-weight: 500;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  animation: slideInNotification 0.4s ease;
  pointer-events: auto;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

/* Legacy support - use .notification class instead */

/* Notification type styles */
.notification-success {
  background: linear-gradient(135deg, rgba(46, 204, 113, 0.95), rgba(46, 204, 113, 0.85));
  color: #fff;
}

.notification-error {
  background: linear-gradient(135deg, rgba(233, 69, 96, 0.95), rgba(233, 69, 96, 0.85));
  color: #fff;
}

.notification-info {
  background: linear-gradient(135deg, rgba(0, 123, 255, 0.95), rgba(0, 123, 255, 0.85));
  color: #fff;
}

.notification-warning {
  background: linear-gradient(135deg, rgba(255, 193, 7, 0.95), rgba(255, 193, 7, 0.85));
  color: #000;
}

/* Notification elements */
.notification-icon {
  font-size: 20px;
}

.notification-message {
  flex: 1;
}

.notification-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  width: 100%;
  background: rgba(255, 255, 255, 0.3);
  /* Animation uses notificationProgress from shared-components.css */
}

/* Progress bar styles are in shared-components.css to avoid duplication */

/* Animations */
@keyframes slideInNotification {
  from {
    opacity: 0;
    transform: translateX(100%);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideOutNotification {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(100%);
  }
}

/* Progress bar animation is defined in shared-components.css as notificationProgress */

/* Notification dismiss animation */
.notification-dismissing {
  animation: slideOutNotification 0.3s ease forwards;
}

/* Notification exit animation for close button */
.notification-exit {
  animation: slideOutNotification 0.3s ease forwards;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
  .notification-container {
    left: 10px;
    right: 10px;
    top: 10px;
  }

  .notification,
  .global-notification {
    min-width: auto;
    max-width: none;
  }
}

/* Dark theme support */
@media (prefers-color-scheme: dark) {
  .notification-warning {
    color: #000;
  }
}

/* Accessibility improvements */
.notification:focus,
.global-notification:focus {
  outline: 2px solid rgba(255, 255, 255, 0.5);
  outline-offset: 2px;
}

/* Notification close button */
.notification-close {
  position: absolute;
  top: 8px;
  right: 8px;
  background: none;
  border: none;
  color: inherit;
  font-size: 20px;
  cursor: pointer;
  opacity: 0.7;
  transition: opacity 0.2s;
  padding: 0;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.notification-close:hover {
  opacity: 1;
}

/* Notification content wrapper */
.notification-content {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  padding-right: 30px; /* Space for close button */
}

/* Notification hover state */
.notification:hover,
.global-notification:hover {
  transform: translateX(-5px);
  transition: transform 0.2s ease;
}
