/* Toast уведомления */
.toast-container {
  position: fixed;
  top: 70px;
  right: 20px;
  z-index: 10000;
  pointer-events: none;
}

.toast {
  background: white;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  border-left: 4px solid #ff9100;
  margin-bottom: 10px;
  padding: 16px;
  min-width: 300px;
  max-width: 400px;
  pointer-events: auto;
  transform: translateX(400px);
  opacity: 0;
  transition: all 0.3s ease;
  position: relative;
}

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

.toast.hide {
  transform: translateX(400px);
  opacity: 0;
}

.toast-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.toast-title {
  font-weight: 600;
  color: #1f2937;
  font-size: 14px;
}

.toast-close {
  background: none;
  border: none;
  font-size: 18px;
  color: #6b7280;
  cursor: pointer;
  padding: 0;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

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

.toast-body {
  color: #4b5563;
  font-size: 13px;
  line-height: 1.4;
  margin-bottom: 12px;
}

.toast-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

.toast-btn {
  padding: 6px 12px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 500;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
}

.toast-btn-primary {
  background-color: #ff9100;
  color: white;
}

.toast-btn-primary:hover {
  background-color: #e68200;
  color: white;
}

.toast-btn-secondary {
  background-color: #f3f4f6;
  color: #374151;
  border: 1px solid #d1d5db;
}

.toast-btn-secondary:hover {
  background-color: #e5e7eb;
}

/* Темная тема */
[data-theme="dark"] .toast {
  background: #1f2937;
  color: #f9fafb;
  border-left-color: #ff9100;
}

[data-theme="dark"] .toast-title {
  color: #f9fafb;
}

[data-theme="dark"] .toast-body {
  color: #d1d5db;
}

[data-theme="dark"] .toast-close {
  color: #9ca3af;
}

[data-theme="dark"] .toast-close:hover {
  color: #d1d5db;
}

[data-theme="dark"] .toast-btn-secondary {
  background-color: #374151;
  color: #d1d5db;
  border-color: #4b5563;
}

[data-theme="dark"] .toast-btn-secondary:hover {
  background-color: #4b5563;
}

/* Иконка заказов в хедере - стиль как у Unfold */
.orders-header-icon {
  position: relative;
  display: block;
  cursor: pointer;
  height: 1.125rem; /* h-4.5 в Tailwind = 18px */
  color: #6b7280; /* text-gray-500 */
  transition: color 0.2s ease;
  text-decoration: none;
}

.orders-header-icon:hover {
  color: #374151; /* hover:text-base-700 */
  text-decoration: none;
}

.orders-header-icon .material-symbols-outlined {
  font-size: 18px; /* соответствует h-4.5 */
  line-height: 1;
}

/* Бэдж для иконки заказов */
.orders-header-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  background-color: #ef4444;
  color: white;
  border-radius: 50%;
  width: 16px;
  height: 16px;
  font-size: 9px;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 16px;
  padding: 0;
  box-sizing: border-box;
  animation: pulse 2s infinite;
  border: 1px solid white;
  line-height: 1;
}

.orders-header-badge.hidden {
  display: none;
}

/* Темная тема для иконки заказов */
[data-theme="dark"] .orders-header-icon {
  color: #9ca3af; /* text-gray-400 */
}

[data-theme="dark"] .orders-header-icon:hover {
  color: #d1d5db; /* dark:hover:text-base-200 */
}

[data-theme="dark"] .orders-header-badge {
  border-color: #1f2937; /* темный фон */
}

/* Контейнер для иконки в хедере */
.admin-orders-container {
  position: relative;
  z-index: 1000;
}

/* Резервное размещение иконки (если не нашли хедер) */
body > .admin-orders-container {
  position: fixed;
  top: 20px;
  right: 60px;
  z-index: 10000;
  background: white;
  border-radius: 50%;
  padding: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

[data-theme="dark"] body > .admin-orders-container {
  background: #1f2937;
  border: 1px solid #374151;
}

body > .admin-orders-container .orders-header-icon {
  color: #374151;
}

[data-theme="dark"] body > .admin-orders-container .orders-header-icon {
  color: #d1d5db;
}

/* Бэдж для новых заказов (старый код - оставляем для совместимости) */
.orders-badge {
  position: relative;
}

.orders-badge-count {
  position: absolute;
  top: -8px;
  right: -8px;
  background-color: #ef4444;
  color: white;
  border-radius: 50%;
  width: 18px;
  height: 18px;
  font-size: 10px;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  padding: 0 4px;
  box-sizing: border-box;
  animation: pulse 2s infinite;
}

.orders-badge-count.hidden {
  display: none;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(239, 68, 68, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
  }
}

/* Адаптация для мобильных устройств */
@media (max-width: 768px) {
  .toast-container {
    left: 20px;
    right: 20px;
    top: 20px;
  }
  
  .toast {
    min-width: auto;
    max-width: none;
    transform: translateY(-100px);
  }
  
  .toast.show {
    transform: translateY(0);
  }
  
  .toast.hide {
    transform: translateY(-100px);
  }

  .orders-header-icon {
    height: 1rem; /* немного меньше на мобильных */
  }

  .orders-header-icon .material-symbols-outlined {
    font-size: 16px; /* меньше на мобильных */
  }

  .orders-header-badge {
    width: 14px;
    height: 14px;
    font-size: 8px;
    top: -5px;
    right: -5px;
  }
} 