/* ============================================================
   EFFECT CONTROL — PUSH & IN-APP NOTIFICATION STYLES
   ============================================================ */

.nav-notif-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.nav-notif-btn {
  background: var(--bg-card, #111);
  border: 1px solid var(--border, #222);
  color: var(--text, #fff);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-notif-btn:hover {
  border-color: var(--yellow, #f5c518);
  color: var(--yellow, #f5c518);
  transform: translateY(-1px);
}

.notif-badge {
  position: absolute;
  top: -3px;
  right: -3px;
  background: #ef4444;
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  min-width: 18px;
  height: 18px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  border: 2px solid var(--bg, #0a0a0a);
  animation: notifPulse 2s infinite;
}

@keyframes notifPulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.12); }
  100% { transform: scale(1); }
}

/* Dropdown */
.notif-dropdown {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  width: 360px;
  max-width: 90vw;
  background: #111;
  border: 2px solid var(--border, #262626);
  border-radius: 14px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(255, 255, 255, 0.05);
  display: none;
  flex-direction: column;
  z-index: 9999;
  overflow: hidden;
  animation: notifFadeIn 0.18s ease-out;
}

.notif-dropdown.show {
  display: flex;
}

@keyframes notifFadeIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

.notif-header {
  padding: 14px 18px;
  background: #161616;
  border-bottom: 1px solid #262626;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.notif-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 1.5px;
  color: var(--text, #fff);
}

.notif-unread-count {
  font-size: 10px;
  font-weight: 800;
  background: rgba(245, 197, 24, 0.15);
  color: var(--yellow, #f5c518);
  border: 1px solid rgba(245, 197, 24, 0.3);
  padding: 2px 6px;
  border-radius: 4px;
}

.notif-mark-all-btn {
  background: none;
  border: none;
  color: var(--text-muted, #888);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 4px;
  transition: color 0.15s;
}

.notif-mark-all-btn:hover {
  color: var(--yellow, #f5c518);
  text-decoration: underline;
}

.notif-list {
  max-height: 380px;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.notif-list::-webkit-scrollbar {
  width: 5px;
}
.notif-list::-webkit-scrollbar-track {
  background: transparent;
}
.notif-list::-webkit-scrollbar-thumb {
  background: #333;
  border-radius: 3px;
}

.notif-item {
  padding: 14px 18px;
  border-bottom: 1px solid #1e1e1e;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  transition: background 0.15s;
  cursor: pointer;
  position: relative;
  text-decoration: none;
  color: inherit;
}

.notif-item:last-child {
  border-bottom: none;
}

.notif-item:hover {
  background: #191919;
}

.notif-item.unread {
  background: rgba(245, 197, 24, 0.04);
}

.notif-item.unread::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--yellow, #f5c518);
}

.notif-item-icon {
  font-size: 20px;
  flex-shrink: 0;
  line-height: 1;
  padding-top: 2px;
}

.notif-item-content {
  flex: 1;
  min-width: 0;
}

.notif-item-title {
  font-size: 13px;
  font-weight: 800;
  color: var(--text, #fff);
  margin-bottom: 4px;
  line-height: 1.35;
}

.notif-item-msg {
  font-size: 12px;
  color: var(--text-muted, #aaa);
  line-height: 1.45;
  margin-bottom: 6px;
}

.notif-item-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
}

.notif-item-time {
  color: #666;
  font-weight: 600;
}

.notif-item-action {
  color: var(--yellow, #f5c518);
  font-weight: 800;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.notif-item-action:hover {
  text-decoration: underline;
}

.notif-empty, .notif-loading {
  padding: 36px 20px;
  text-align: center;
  color: var(--text-muted, #777);
  font-size: 13px;
}

.notif-footer {
  padding: 10px 18px;
  background: #141414;
  border-top: 1px solid #262626;
  display: flex;
  justify-content: center;
}

.notif-desktop-btn {
  background: none;
  border: none;
  color: var(--text-muted, #888);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px;
  border-radius: 4px;
  transition: color 0.15s;
}

.notif-desktop-btn:hover {
  color: var(--yellow, #f5c518);
}

/* ============================================================
   FLOATING PUSH NOTIFICATION TOAST BANNER
   ============================================================ */

.notif-toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  gap: 12px;
  pointer-events: none;
  max-width: 400px;
  width: calc(100% - 48px);
}

.notif-toast {
  pointer-events: auto;
  background: #141414;
  border: 2px solid var(--yellow, #f5c518);
  border-radius: 12px;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.75), 0 0 20px rgba(245, 197, 24, 0.15);
  padding: 16px;
  display: flex;
  gap: 14px;
  align-items: flex-start;
  transform: translateX(120%);
  opacity: 0;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
}

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

.notif-toast-icon {
  font-size: 24px;
  flex-shrink: 0;
  line-height: 1;
}

.notif-toast-body {
  flex: 1;
  min-width: 0;
}

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

.notif-toast-title {
  font-size: 14px;
  font-weight: 900;
  color: #fff;
  letter-spacing: 0.3px;
}

.notif-toast-close {
  background: none;
  border: none;
  color: #888;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  padding: 0 4px;
  transition: color 0.15s;
}

.notif-toast-close:hover {
  color: #fff;
}

.notif-toast-message {
  font-size: 12px;
  color: #bbb;
  line-height: 1.45;
  margin-bottom: 10px;
}

.notif-toast-action {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--yellow, #f5c518);
  color: #000;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.8px;
  padding: 6px 14px;
  border-radius: 6px;
  text-decoration: none;
  transition: opacity 0.15s;
}

.notif-toast-action:hover {
  opacity: 0.9;
}

/* ============================================================
   BACKDROP OVERLAY (MOBILE)
   ============================================================ */

.notif-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 9998;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.notif-backdrop.show {
  opacity: 1;
  pointer-events: auto;
}

/* ============================================================
   RESPONSIVE (MOBILE & TABLET <= 768px)
   ============================================================ */

@media (max-width: 768px) {
  /* Notification Dropdown: Centered, full comfortable screen width */
  .notif-dropdown {
    position: fixed;
    top: calc(var(--nav-h, 72px) + 8px);
    left: 12px;
    right: 12px;
    width: auto;
    max-width: calc(100vw - 24px);
    max-height: calc(85vh - var(--nav-h, 72px));
    border-radius: 16px;
    border-color: #333;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.95), 0 0 0 1px rgba(245, 197, 24, 0.25);
    z-index: 10000;
  }

  .notif-header {
    padding: 12px 14px;
    gap: 8px;
  }

  .notif-title {
    font-size: 11px;
    letter-spacing: 1px;
    gap: 6px;
  }

  .notif-unread-count {
    font-size: 9.5px;
    padding: 2px 5px;
  }

  .notif-mark-all-btn {
    font-size: 11px;
    padding: 4px;
  }

  .notif-list {
    max-height: calc(85vh - var(--nav-h, 72px) - 100px);
    -webkit-overflow-scrolling: touch;
  }

  .notif-item {
    padding: 12px 14px;
    gap: 10px;
  }

  .notif-item-icon {
    font-size: 18px;
  }

  .notif-item-title {
    font-size: 13px;
    line-height: 1.35;
  }

  .notif-item-msg {
    font-size: 12px;
    line-height: 1.4;
  }

  .notif-footer {
    padding: 10px 14px;
  }

  .notif-desktop-btn {
    font-size: 11px;
  }

  /* Toast Banner on Mobile */
  .notif-toast-container {
    bottom: 16px;
    left: 12px;
    right: 12px;
    width: auto;
    max-width: none;
    gap: 8px;
    z-index: 10001;
  }

  .notif-toast {
    padding: 14px;
    gap: 12px;
    border-radius: 12px;
    transform: translateY(120%);
  }

  .notif-toast.show {
    transform: translateY(0);
  }

  .notif-toast-icon {
    font-size: 22px;
  }

  .notif-toast-title {
    font-size: 13px;
  }

  .notif-toast-message {
    font-size: 12px;
    margin-bottom: 8px;
    line-height: 1.4;
  }

  .notif-toast-action {
    padding: 6px 12px;
    font-size: 10.5px;
    letter-spacing: 0.5px;
  }
}

@media (max-width: 360px) {
  .notif-dropdown {
    left: 8px;
    right: 8px;
    max-width: calc(100vw - 16px);
  }
  .notif-toast-container {
    left: 8px;
    right: 8px;
  }
}

