/* ════════════════════════════════════════
   notifications.css — Toasts + Centro
════════════════════════════════════════ */

/* ── Toast container ── */
#notification-tray {
  position: fixed;
  bottom: 64px;
  right: 14px;
  z-index: 99998;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}

/* ── Toast individual ── */
.os-notification {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: #1e1e1e;
  color: #fff;
  border-radius: 8px;
  padding: 10px 12px;
  min-width: 280px;
  max-width: 340px;
  box-shadow: 0 4px 18px #0006;
  pointer-events: all;
  opacity: 0;
  transform: translateX(30px);
  transition: opacity .25s ease, transform .25s ease;
  border-left: 3px solid #245edb;
  font-family: Arial, sans-serif;
}

.os-notification.notif-visible {
  opacity: 1;
  transform: translateX(0);
}

.os-notification.notif-exit {
  opacity: 0;
  transform: translateX(30px);
}

/* Icono emoji */
.notif-icon {
  font-size: 22px;
  flex-shrink: 0;
  margin-top: 1px;
}

/* Icono imagen de app */
.notif-app-icon {
  width: 28px;
  height: 28px;
  object-fit: contain;
  flex-shrink: 0;
  margin-top: 2px;
  border-radius: 4px;
}

/* Avatar de personaje (foto) → círculo */
.notif-app-icon.notif-photo {
  object-fit: cover;
  border-radius: 50%;
}

.notif-content {
  flex: 1;
  min-width: 0;
}

.notif-title {
  font-size: 12px;
  font-weight: bold;
  color: #fff;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.notif-body {
  font-size: 11px;
  color: #bbb;
  line-height: 1.4;
}

.notif-close {
  background: none;
  border: none;
  color: #888;
  font-size: 13px;
  cursor: pointer;
  padding: 0 2px;
  flex-shrink: 0;
  line-height: 1;
  margin-top: 1px;
}
.notif-close:hover { color: #fff; }


/* ── Systray botón notificaciones ── */
#notif-systray-btn {
  position: relative;
  cursor: pointer;
  padding: 4px 8px;
  font-size: 15px;
  border-radius: 4px;
  user-select: none;
  display: flex;
  align-items: center;
  color: #fff;
  transition: background .15s;
}
#notif-systray-btn:hover {
  background: rgba(255,255,255,.15);
}

#notif-systray-badge {
  position: absolute;
  top: 1px;
  right: 1px;
  background: #e02020;
  color: #fff;
  font-size: 9px;
  font-weight: bold;
  min-width: 14px;
  height: 14px;
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 3px;
  pointer-events: none;
  font-family: Arial, sans-serif;
}


/* ── Centro de notificaciones (panel) ── */
#notif-center {
  position: fixed;
  bottom: 58px;
  right: 10px;
  width: 320px;
  max-height: 460px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 4px 24px #0005;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  font-family: Arial, sans-serif;
  animation: nc-appear .15s ease;
}

@keyframes nc-appear {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

.nc-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  background: #f5f5f5;
  border-bottom: 1px solid #e0e0e0;
  font-size: 13px;
  font-weight: bold;
  color: #333;
  flex-shrink: 0;
}

.nc-header button {
  font-size: 11px;
  background: none;
  border: none;
  color: #888;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 3px;
  transition: background .1s;
}
.nc-header button:hover {
  background: #fee;
  color: #e00;
}

.nc-list {
  overflow-y: auto;
  flex: 1;
}
.nc-list::-webkit-scrollbar { width: 5px; }
.nc-list::-webkit-scrollbar-track { background: #f5f5f5; }
.nc-list::-webkit-scrollbar-thumb { background: #ddd; border-radius: 3px; }

.nc-empty {
  padding: 36px 20px;
  text-align: center;
  color: #aaa;
  font-size: 12px;
  line-height: 1.6;
}

/* ── Item del centro ── */
.nc-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 14px;
  border-bottom: 1px solid #f0f0f0;
  transition: background .1s;
  cursor: default;
}
.nc-item:last-child { border-bottom: none; }
.nc-item:hover      { background: #f9f9f9; }

.nc-item.unread {
  background: #fff8f0;
  border-left: 3px solid #ff6000;
}
.nc-item.unread:hover { background: #fff2e0; }

.nc-item-icon {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.nc-item-icon img  {
  width: 28px;
  height: 28px;
  object-fit: contain;
  border-radius: 4px;
}
.nc-item-icon span { font-size: 20px; }

.nc-item-content { flex: 1; min-width: 0; }

.nc-item-title {
  font-size: 12px;
  font-weight: bold;
  color: #222;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nc-item-body {
  font-size: 11px;
  color: #666;
  margin-top: 2px;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.nc-item-time {
  font-size: 10px;
  color: #bbb;
  flex-shrink: 0;
  margin-top: 2px;
  white-space: nowrap;
}