/* === USER FEATURES STYLES: Notifications, Reports, Security === */

/* ===== NOTIFICATION LIST ===== */
.notif-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.notif-item {
  background: var(--color-glass);
  backdrop-filter: blur(12px);
  border: var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-4) var(--space-5);
  display: flex;
  align-items: flex-start;
  gap: var(--space-4);
  cursor: pointer;
  transition: all 0.2s ease;
}

.notif-item:hover {
  transform: translateX(4px);
  border-color: var(--color-primary);
  box-shadow: 0 0 0 1px rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.1);
}

.notif-item--unread {
  background: linear-gradient(135deg, rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.06), var(--color-glass));
  border-color: rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.2);
}

.notif-item__icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.15), rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.05));
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.notif-item--unread .notif-item__icon {
  background: linear-gradient(135deg, rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.25), rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.1));
}

.notif-item__content {
  flex: 1;
}

.notif-item__text {
  font-size: var(--fs-sm);
  line-height: var(--lh-relaxed);
  margin-bottom: 4px;
}

.notif-item--unread .notif-item__text {
  font-weight: var(--fw-semibold);
}

.notif-item__time {
  font-size: var(--fs-xs);
  color: var(--color-text-tertiary);
}

.notif-item__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-primary);
  flex-shrink: 0;
  margin-top: 6px;
  animation: adminPulse 2s infinite;
}

/* ===== ROLE-BASED NOTIFICATION COLORS ===== */

/* --- User (blue) --- */
.notif-item--role-user {
  border-left: 4px solid #3b82f6;
}
.notif-item--role-user .notif-item__icon {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(59, 130, 246, 0.05));
  color: #3b82f6;
}
.notif-item--role-user.notif-item--unread .notif-item__icon {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.25), rgba(59, 130, 246, 0.1));
}
.notif-item--role-user.notif-item--unread {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.06), var(--color-glass));
  border-left-color: #3b82f6;
  border-right-color: transparent;
  border-top-color: rgba(59, 130, 246, 0.15);
  border-bottom-color: rgba(59, 130, 246, 0.15);
}
.notif-item--role-user:hover {
  border-color: #3b82f6;
  border-left-color: #3b82f6;
  box-shadow: 0 0 0 1px rgba(59, 130, 246, 0.1);
}
.notif-item--role-user .notif-item__dot {
  background: #3b82f6;
}

/* --- Developer (green) --- */
.notif-item--role-developer {
  border-left: 4px solid #22c55e;
}
.notif-item--role-developer .notif-item__icon {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.15), rgba(34, 197, 94, 0.05));
  color: #22c55e;
}
.notif-item--role-developer.notif-item--unread .notif-item__icon {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.25), rgba(34, 197, 94, 0.1));
}
.notif-item--role-developer.notif-item--unread {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.06), var(--color-glass));
  border-left-color: #22c55e;
  border-right-color: transparent;
  border-top-color: rgba(34, 197, 94, 0.15);
  border-bottom-color: rgba(34, 197, 94, 0.15);
}
.notif-item--role-developer:hover {
  border-color: #22c55e;
  border-left-color: #22c55e;
  box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.1);
}
.notif-item--role-developer .notif-item__dot {
  background: #22c55e;
}

/* --- Admin (orange) --- */
.notif-item--role-admin {
  border-left: 4px solid #f97316;
}
.notif-item--role-admin .notif-item__icon {
  background: linear-gradient(135deg, rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.15), rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.05));
  color: #f97316;
}
.notif-item--role-admin.notif-item--unread .notif-item__icon {
  background: linear-gradient(135deg, rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.25), rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.1));
}
.notif-item--role-admin.notif-item--unread {
  background: linear-gradient(135deg, rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.06), var(--color-glass));
  border-left-color: #f97316;
  border-right-color: transparent;
  border-top-color: rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.15);
  border-bottom-color: rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.15);
}
.notif-item--role-admin:hover {
  border-color: #f97316;
  border-left-color: #f97316;
  box-shadow: 0 0 0 1px rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.1);
}
.notif-item--role-admin .notif-item__dot {
  background: #f97316;
}

/* --- Role Badge (emoji label next to time) --- */
.notif-role-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 10px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 100px;
  margin-left: var(--space-2);
  vertical-align: middle;
  line-height: 1.4;
}
.notif-role-badge--user {
  background: rgba(59, 130, 246, 0.12);
  color: #3b82f6;
}
.notif-role-badge--developer {
  background: rgba(34, 197, 94, 0.12);
  color: #16a34a;
}
.notif-role-badge--admin {
  background: rgba(var(--accent-r), var(--accent-g), var(--accent-b), 0.12);
  color: #f97316;
}

/* ===== NOTIFICATION BADGE ===== */
.notif-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: white;
  font-size: 10px;
  font-weight: 700;
  min-width: 16px;
  height: 16px;
  border-radius: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  line-height: 1;
  animation: adminPulse 2s infinite;
}

.notif-btn-wrap {
  position: relative;
  display: flex;
}

/* ===== REPORT MODAL ===== */
.report-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
  animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.report-modal {
  background: var(--color-surface);
  border: var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  width: 100%;
  max-width: 480px;
  box-shadow: var(--shadow-2xl);
  animation: slideUp 0.3s ease;
}

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

.report-modal__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-4);
}

.report-modal__header h3 {
  font-size: var(--fs-lg);
  font-weight: var(--fw-semibold);
}

.report-modal__close {
  background: none;
  border: none;
  font-size: var(--fs-xl);
  cursor: pointer;
  color: var(--color-text-secondary);
  padding: var(--space-1);
  border-radius: var(--radius-sm);
  transition: all 0.15s;
}

.report-modal__close:hover {
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
}

.report-modal__target {
  font-size: var(--fs-sm);
  color: var(--color-text-secondary);
  margin-bottom: var(--space-4);
  padding: var(--space-3);
  background: var(--color-glass);
  border-radius: var(--radius-md);
}

.report-modal__reasons {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  margin-bottom: var(--space-4);
}

.report-reason {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  cursor: pointer;
  font-size: var(--fs-sm);
  transition: background 0.15s;
}

.report-reason:hover {
  background: var(--color-glass);
}

.report-reason input[type="radio"] {
  accent-color: var(--color-primary);
  width: 16px;
  height: 16px;
}

.report-modal__details {
  margin-bottom: var(--space-4);
  min-height: 80px;
  resize: vertical;
}

.report-modal__actions {
  display: flex;
  justify-content: flex-end;
  gap: var(--space-3);
}

/* ===== REPORT BUTTON (inline on pages) ===== */
.report-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  background: none;
  border: none;
  color: var(--color-text-tertiary);
  font-size: var(--fs-xs);
  cursor: pointer;
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-sm);
  transition: all 0.15s;
}

.report-btn:hover {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.06);
}

/* ===== SECURITY SETTINGS ===== */
.security-sections {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}

.security-section__title {
  font-size: var(--fs-base);
  font-weight: var(--fw-semibold);
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-4);
  padding-bottom: var(--space-3);
  border-bottom: var(--border-subtle);
}

.security-section__title--danger {
  color: #ef4444;
}

.security-danger-zone {
  border-color: rgba(239, 68, 68, 0.2) !important;
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.04), var(--color-glass)) !important;
}

.security-danger-text {
  font-size: var(--fs-sm);
  color: var(--color-text-secondary);
  margin-bottom: var(--space-4);
  line-height: var(--lh-relaxed);
}

/* ===== SIDEBAR ADMIN/DEV LINK STYLES ===== */
.sidebar__link--admin,
.sidebar__link--dev {
  border-left: 2px solid transparent;
}

.sidebar__link--admin {
  border-left-color: rgba(239, 68, 68, 0.4);
}

.sidebar__link--dev {
  border-left-color: rgba(34, 197, 94, 0.4);
}

/* ===== MESSAGE BADGE ===== */
.msg-badge {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: white;
  font-size: 10px;
  font-weight: 700;
  min-width: 16px;
  height: 16px;
  border-radius: 100px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  line-height: 1;
  margin-left: auto;
  animation: adminPulse 2s infinite;
}

/* ===== PROMO MOD HIGHLIGHTING ===== */
.mod-card--promoted {
  border: 2px solid rgba(245, 158, 11, 0.5) !important;
  box-shadow: 0 0 16px rgba(245, 158, 11, 0.15);
  position: relative;
}

.promo-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 100px;
  letter-spacing: 0.02em;
}

.home-top-mod--promoted {
  border: 2px solid rgba(245, 158, 11, 0.5);
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.12);
}
