/* ── جرس الإشعارات (الهيدر) ───────────────────────────── */
.mt-notif-bell {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.mt-notif-bell__btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid rgba(45, 106, 79, 0.18);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  color: #1B4332;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, transform 0.15s;
}

.mt-notif-bell__btn:hover,
.mt-notif-bell__btn[aria-expanded="true"] {
  background: #ecfdf5;
  border-color: rgba(45, 106, 79, 0.35);
}

.mt-notif-bell__badge {
  position: absolute;
  top: 4px;
  inset-inline-end: 4px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: #dc2626;
  color: #fff;
  font-size: 0.65rem;
  font-weight: 800;
  line-height: 16px;
  text-align: center;
  display: none;
  box-shadow: 0 0 0 2px #fff;
}

.mt-notif-bell__badge.is-visible {
  display: block;
}

.mt-notif-bell__live {
  position: absolute;
  bottom: 6px;
  inset-inline-start: 6px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #9ca3af;
  box-shadow: 0 0 0 2px #fff;
  opacity: 0.85;
}

.mt-notif-bell__live.is-live {
  background: #22c55e;
  animation: mt-notif-pulse 1.8s ease infinite;
}

.mt-notif-bell__live.is-connecting {
  background: #f59e0b;
}

.mt-notif-bell__live.is-offline {
  background: #9ca3af;
}

@keyframes mt-notif-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.15); opacity: 0.75; }
}

.mt-inbox-toasts {
  position: fixed;
  top: 88px;
  inset-inline-end: 16px;
  z-index: 10050;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: min(360px, calc(100vw - 32px));
  pointer-events: none;
}

.mt-inbox-toast {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 12px 14px;
  background: #fff;
  border: 1px solid rgba(45, 106, 79, 0.18);
  border-radius: 14px;
  box-shadow: 0 12px 32px rgba(27, 67, 50, 0.18);
  text-decoration: none;
  color: inherit;
  pointer-events: auto;
  transition: opacity 0.35s, transform 0.35s;
}

.mt-inbox-toast.is-out {
  opacity: 0;
  transform: translateX(12px);
}

.mt-inbox-toast__ic {
  font-size: 1.2rem;
  line-height: 1;
}

.mt-inbox-toast__body strong {
  display: block;
  font-size: 0.86rem;
  color: #1B4332;
  margin-bottom: 2px;
}

.mt-inbox-toast__body span {
  font-size: 0.78rem;
  color: #4b5563;
  line-height: 1.4;
}

html[dir="ltr"] .mt-inbox-toast.is-out {
  transform: translateX(-12px);
}

.mt-notif-bell__panel {
  position: absolute;
  top: calc(100% + 10px);
  inset-inline-end: 0;
  width: min(360px, calc(100vw - 24px));
  max-height: min(420px, 70vh);
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid rgba(45, 106, 79, 0.14);
  border-radius: 16px;
  box-shadow: 0 18px 48px rgba(27, 67, 50, 0.16);
  z-index: 1200;
  overflow: hidden;
}

.mt-notif-bell__panel[hidden] {
  display: none !important;
}

.mt-notif-bell__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 12px 14px;
  border-bottom: 1px solid rgba(45, 106, 79, 0.1);
  font-size: 0.95rem;
  color: #1B4332;
}

.mt-notif-bell__mark-all {
  border: none;
  background: transparent;
  color: #2D6A4F;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 8px;
}

.mt-notif-bell__mark-all:hover {
  background: rgba(45, 106, 79, 0.08);
}

.mt-notif-bell__push {
  padding: 8px 12px 4px;
  border-top: 1px solid rgba(45, 106, 79, 0.12);
  background: linear-gradient(180deg, rgba(236, 253, 245, 0.5), transparent);
}

.mt-notif-bell__push-btn {
  width: 100%;
  border: 1px solid rgba(45, 106, 79, 0.25);
  background: #fff;
  color: #1b4332;
  border-radius: 10px;
  padding: 8px 10px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.mt-notif-bell__push-btn:hover:not(:disabled) {
  background: #ecfdf5;
  border-color: #2d6a4f;
}

.mt-notif-bell__push-btn:disabled {
  opacity: 0.65;
  cursor: wait;
}

.mt-notif-bell__push-btn--test {
  margin-top: 6px;
  border-color: rgba(14, 116, 144, 0.35);
  color: #0e7490;
}

.mt-notif-bell__push-btn--test:hover:not(:disabled) {
  background: #ecfeff;
  border-color: #0e7490;
}

.mt-notif-bell__push-hint {
  margin: 6px 0 0;
  font-size: 0.72rem;
  line-height: 1.45;
  color: #64748b;
  text-align: center;
}

.mt-notif-bell__list {
  overflow-y: auto;
  flex: 1;
  padding: 6px;
}

.mt-notif-bell__item {
  display: flex;
  gap: 10px;
  padding: 10px;
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  transition: background 0.15s;
}

.mt-notif-bell__item:hover {
  background: #f0fdf4;
}

.mt-notif-bell__item.is-unread {
  background: rgba(236, 253, 245, 0.7);
}

.mt-notif-bell__ic {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: #ecfdf5;
  font-size: 1.1rem;
}

.mt-notif-bell__body {
  flex: 1;
  min-width: 0;
}

.mt-notif-bell__title {
  font-size: 0.86rem;
  font-weight: 700;
  color: #1B4332;
  line-height: 1.35;
  margin: 0 0 2px;
}

.mt-notif-bell__text {
  font-size: 0.78rem;
  color: #4b5563;
  margin: 0;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.mt-notif-bell__meta {
  font-size: 0.7rem;
  color: #9ca3af;
  margin-top: 4px;
}

.mt-notif-bell__empty {
  padding: 28px 16px;
  text-align: center;
  color: #6b7280;
  font-size: 0.88rem;
}

.mt-notif-bell__foot {
  padding: 10px 14px;
  border-top: 1px solid rgba(45, 106, 79, 0.1);
  text-align: center;
}

.mt-notif-bell__all {
  font-size: 0.85rem;
  font-weight: 700;
  color: #2D6A4F;
  text-decoration: none;
}

/* ── صفحة مركز الإشعارات ─────────────────────────────── */
.un-inbox-page {
  margin-top: 8px;
}

.un-inbox-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 18px;
  padding: 16px 18px;
  background: linear-gradient(168deg, #ffffff 0%, #f9fdfb 48%, #f0fdf4 100%);
  border: 1px solid rgba(45, 106, 79, 0.12);
  border-radius: 20px;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 8px 28px -14px rgba(27, 67, 50, 0.12);
}

.un-inbox-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  flex: 1;
  min-width: 0;
}

.un-inbox-chip {
  border: 1px solid rgba(45, 106, 79, 0.18);
  background: #fff;
  color: #334155;
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 0.8rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
  box-shadow: 0 1px 2px rgba(27, 67, 50, 0.04);
}

.un-inbox-chip:hover {
  background: rgba(45, 106, 79, 0.08);
  border-color: rgba(45, 106, 79, 0.28);
  color: var(--nt-green-dark, #1b4332);
  transform: translateY(-1px);
}

.un-inbox-chip.is-active {
  background: linear-gradient(135deg, var(--nt-green, #2d6a4f) 0%, #40916c 100%);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 4px 14px -4px rgba(45, 106, 79, 0.45);
}

.un-inbox-chip.is-active:hover {
  color: #fff;
  filter: brightness(1.05);
}

.un-inbox-toolbar #un-mark-all {
  flex-shrink: 0;
  border-radius: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.un-inbox-kpis {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(148px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.un-inbox-kpi {
  padding: 14px 16px;
  border-radius: 18px;
  background: linear-gradient(168deg, #ffffff 0%, #f9fdfb 55%, #f3faf6 100%);
  border: 1px solid rgba(45, 106, 79, 0.1);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.85) inset,
    0 6px 20px -12px rgba(27, 67, 50, 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.un-inbox-kpi:hover {
  transform: translateY(-2px);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 10px 28px -12px rgba(27, 67, 50, 0.14);
}

.un-inbox-kpi strong {
  display: block;
  font-size: 1.45rem;
  color: var(--nt-green-dark, #1b4332);
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
}

.un-inbox-kpi span {
  display: block;
  margin-top: 4px;
  font-size: 0.76rem;
  color: #64748b;
  font-weight: 600;
  line-height: 1.35;
}

.un-inbox-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.un-inbox-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: start;
  padding: 14px 16px;
  background: linear-gradient(168deg, #ffffff 0%, #fafdfb 100%);
  border: 1px solid rgba(45, 106, 79, 0.1);
  border-radius: 18px;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.85) inset;
  transition: box-shadow 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}

.un-inbox-card:hover {
  border-color: rgba(45, 106, 79, 0.18);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 8px 24px -12px rgba(27, 67, 50, 0.12);
}

.un-inbox-card.is-unread {
  border-color: rgba(45, 106, 79, 0.28);
  box-shadow: 0 4px 20px rgba(45, 106, 79, 0.08);
}

.un-inbox-card__icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  background: #ecfdf5;
}

.un-inbox-card__cat {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 999px;
  margin-bottom: 4px;
}

.un-inbox-card__title {
  margin: 0 0 4px;
  font-size: 0.95rem;
  font-weight: 800;
  color: #1B4332;
}

.un-inbox-card__body {
  margin: 0;
  font-size: 0.85rem;
  color: #4b5563;
  line-height: 1.55;
}

.un-inbox-card__time {
  font-size: 0.72rem;
  color: #9ca3af;
  white-space: nowrap;
}

.un-inbox-card__actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: flex-end;
}

.un-inbox-card__link {
  font-size: 0.78rem;
  font-weight: 700;
  color: #2D6A4F;
  text-decoration: none;
}

.un-inbox-empty {
  text-align: center;
  padding: 48px 20px;
  color: #6b7280;
  border: 1px dashed rgba(45, 106, 79, 0.25);
  border-radius: 16px;
  background: #fafdfb;
}

.un-inbox-push-wrap {
  margin-top: 24px;
  padding-top: 8px;
}

.un-inbox-profile-link {
  margin-top: 14px;
}

.un-inbox-push-intro,
.un-inbox-push-wrap > .dashboard-notifications-lead {
  margin-bottom: 12px;
  padding: 10px 14px;
  border-radius: 14px;
  background: rgba(45, 106, 79, 0.06);
  border: 1px solid rgba(45, 106, 79, 0.1);
  font-size: 0.84rem;
  line-height: 1.65;
  color: #475569;
}

/* بطاقة Push — صفحة مركز الإشعارات (تخطيط عمودي واضح) */
.un-inbox-push-wrap .nt-push-opt-in-card {
  margin-bottom: 0;
}

.un-inbox-push-wrap .nt-push-opt-in-card__inner {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  padding: 22px 24px 20px;
}

.un-inbox-push-wrap .nt-push-opt-in-card__header {
  margin-bottom: 16px;
}

.un-inbox-push-wrap .nt-push-opt-in-card__badge {
  width: 52px;
  height: 52px;
  font-size: 1.5rem;
  border-radius: 18px;
}

.un-inbox-push-wrap .nt-push-opt-in-card__actions {
  padding-top: 4px;
  border-top: 1px solid rgba(45, 106, 79, 0.08);
}

.un-inbox-push-wrap .nt-push-opt-in-card__hint {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed rgba(45, 106, 79, 0.12);
}

.un-inbox-push-wrap .nt-push-opt-in-card.is-active {
  border-color: rgba(82, 183, 136, 0.35);
  background:
    radial-gradient(90% 80% at 100% 0%, rgba(82, 183, 136, 0.1) 0%, transparent 55%),
    linear-gradient(165deg, #ffffff 0%, #f0fdf4 50%, #ecfdf5 100%);
}

.un-inbox-push-wrap .nt-push-opt-in-card.is-active .nt-push-opt-in-card__status {
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(82, 183, 136, 0.1);
  border: 1px solid rgba(82, 183, 136, 0.2);
}

.un-inbox-push-wrap .nt-push-opt-in-card.is-denied {
  border-color: rgba(231, 76, 60, 0.25);
  background:
    radial-gradient(90% 80% at 100% 0%, rgba(231, 76, 60, 0.06) 0%, transparent 55%),
    linear-gradient(165deg, #ffffff 0%, #fff5f5 100%);
}

.un-inbox-push-wrap .nt-push-opt-in-card.is-denied .nt-push-opt-in-card__status {
  color: #991b1b;
  background: rgba(254, 226, 226, 0.65);
  border: 1px solid rgba(231, 76, 60, 0.2);
  padding: 10px 14px;
  border-radius: 12px;
}

@media (max-width: 640px) {
  .un-inbox-toolbar {
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
  }

  .un-inbox-toolbar #un-mark-all {
    width: 100%;
    justify-content: center;
    min-height: 44px;
  }

  .un-inbox-filters {
    gap: 6px;
  }

  .un-inbox-chip {
    padding: 7px 12px;
    font-size: 0.78rem;
  }

  .un-inbox-push-wrap .nt-push-opt-in-card__inner {
    padding: 18px 16px 16px;
  }

  .un-inbox-push-wrap .nt-push-opt-in-card__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .un-inbox-push-wrap .nt-push-btn-primary {
    width: 100%;
    justify-content: center;
    text-align: center;
  }
}

html[data-theme="dark"] .mt-notif-bell__btn {
  background: rgba(30, 41, 35, 0.9);
  border-color: rgba(82, 183, 136, 0.25);
  color: #d8f3dc;
}

html[data-theme="dark"] .mt-notif-bell__panel,
html[data-theme="dark"] .un-inbox-card,
html[data-theme="dark"] .un-inbox-kpi {
  background: var(--clr-surface, #1a2e24);
  border-color: var(--clr-border, rgba(82, 183, 136, 0.2));
  color: var(--clr-text, #e8f5e9);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.04) inset,
    var(--shadow-sm, 0 4px 12px rgba(0, 0, 0, 0.2));
}

html[data-theme="dark"] .un-inbox-kpi {
  background: linear-gradient(168deg, var(--clr-surface) 0%, var(--clr-bg-alt) 100%);
}

html[data-theme="dark"] .un-inbox-kpi strong {
  color: var(--clr-primary-dark, #a7f3d0);
}

html[data-theme="dark"] .un-inbox-kpi span {
  color: var(--clr-text-muted, #94a3b8);
}

html[data-theme="dark"] .un-inbox-toolbar {
  background: linear-gradient(168deg, var(--clr-surface) 0%, var(--clr-bg-alt) 55%, rgba(15, 35, 25, 0.9) 100%);
  border-color: var(--clr-border);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.04) inset,
    var(--shadow-md);
}

html[data-theme="dark"] .un-inbox-chip {
  background: var(--clr-bg-alt);
  border-color: var(--clr-border);
  color: var(--clr-text-md);
  box-shadow: none;
}

html[data-theme="dark"] .un-inbox-chip:hover {
  background: var(--clr-primary-bg);
  border-color: rgba(82, 183, 136, 0.35);
  color: var(--clr-primary-dark);
}

html[data-theme="dark"] .un-inbox-chip.is-active {
  background: linear-gradient(135deg, var(--nt-green-light, #52b788) 0%, #40916c 100%);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 4px 14px -4px rgba(0, 0, 0, 0.4);
}

html[data-theme="dark"] .un-inbox-toolbar #un-mark-all {
  background: var(--clr-bg-alt);
  border-color: var(--clr-border);
  color: var(--clr-text-md);
}

html[data-theme="dark"] .un-inbox-toolbar #un-mark-all:hover {
  background: var(--clr-primary-bg);
  color: var(--clr-primary-dark);
  border-color: rgba(82, 183, 136, 0.35);
}

html[data-theme="dark"] .un-inbox-card.is-unread {
  border-color: rgba(82, 183, 136, 0.4);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
  background: linear-gradient(135deg, var(--clr-surface) 0%, rgba(15, 35, 25, 0.95) 100%);
}

html[data-theme="dark"] .un-inbox-card__icon {
  background: var(--clr-primary-bg);
}

html[data-theme="dark"] .un-inbox-card__body {
  color: var(--clr-text-md);
}

html[data-theme="dark"] .un-inbox-card__time {
  color: var(--clr-text-muted);
}

html[data-theme="dark"] .un-inbox-card__link {
  color: var(--nt-green, #74c69d);
}

html[data-theme="dark"] .un-inbox-empty {
  background: var(--clr-bg-alt);
  border-color: var(--clr-border);
  color: var(--clr-text-muted);
}

html[data-theme="dark"] .un-inbox-push-intro,
html[data-theme="dark"] .un-inbox-push-wrap > .dashboard-notifications-lead {
  background: rgba(82, 183, 136, 0.08);
  border-color: var(--clr-border);
  color: var(--clr-text-md);
}

html[data-theme="dark"] .un-inbox-push-wrap .nt-push-opt-in-card.is-active {
  background:
    radial-gradient(90% 80% at 100% 0%, rgba(82, 183, 136, 0.14) 0%, transparent 55%),
    linear-gradient(165deg, var(--clr-surface) 0%, rgba(15, 35, 25, 0.95) 100%);
  border-color: rgba(82, 183, 136, 0.35);
}

html[data-theme="dark"] .un-inbox-push-wrap .nt-push-opt-in-card__actions {
  border-top-color: var(--clr-border);
}

html[data-theme="dark"] .un-inbox-push-wrap .nt-push-opt-in-card__hint {
  border-top-color: var(--clr-border);
}

html[data-theme="dark"] .un-inbox-push-wrap .nt-push-opt-in-card.is-active .nt-push-opt-in-card__status {
  background: rgba(82, 183, 136, 0.15);
  border-color: rgba(82, 183, 136, 0.3);
  color: #a7f3d0;
}

html[data-theme="dark"] .un-inbox-push-wrap .nt-push-opt-in-card.is-denied {
  border-color: rgba(240, 113, 103, 0.35);
  background:
    radial-gradient(90% 80% at 100% 0%, rgba(240, 113, 103, 0.1) 0%, transparent 55%),
    linear-gradient(165deg, var(--clr-surface) 0%, rgba(42, 21, 19, 0.85) 100%);
}

html[data-theme="dark"] .un-inbox-push-wrap .nt-push-opt-in-card.is-denied .nt-push-opt-in-card__status {
  color: #fca5a5;
  background: var(--clr-red-bg);
  border-color: rgba(240, 113, 103, 0.35);
}

html[data-theme="dark"] .mt-notif-bell__title,
html[data-theme="dark"] .un-inbox-card__title {
  color: #d8f3dc;
}

/* معاينة لوحة اليوم */
.dashboard-inbox-preview {
  margin-bottom: 16px;
  padding: 14px 14px 12px;
  border-radius: 16px;
  background: linear-gradient(160deg, #ffffff 0%, #f0fdf4 52%, #ecfdf5 100%);
  border: 1px solid rgba(45, 106, 79, 0.14);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 6px 20px -12px rgba(27, 67, 50, 0.14);
}

.dashboard-inbox-preview__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(45, 106, 79, 0.1);
}

.dashboard-inbox-preview__title {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 800;
  color: #1b4332;
  display: flex;
  align-items: center;
  gap: 8px;
  letter-spacing: -0.01em;
}

.dashboard-inbox-preview__badge {
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  line-height: 20px;
  text-align: center;
  box-shadow: 0 2px 8px -2px rgba(220, 38, 38, 0.45);
}

.dashboard-inbox-preview__all {
  flex-shrink: 0;
  font-size: 0.76rem;
  font-weight: 800;
  color: #2d6a4f;
  text-decoration: none;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(45, 106, 79, 0.08);
  border: 1px solid rgba(45, 106, 79, 0.12);
  transition: background 0.2s ease, color 0.2s ease;
}

.dashboard-inbox-preview__all:hover {
  background: rgba(45, 106, 79, 0.14);
  color: #1b4332;
}

.dashboard-inbox-preview__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 220px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(45, 106, 79, 0.25) transparent;
}

.dashboard-inbox-preview__list::-webkit-scrollbar {
  width: 5px;
}

.dashboard-inbox-preview__list::-webkit-scrollbar-thumb {
  background: rgba(45, 106, 79, 0.22);
  border-radius: 999px;
}

.dashboard-inbox-preview__item {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 10px 10px;
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  border: 1px solid transparent;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}

.dashboard-inbox-preview__item:hover {
  background: rgba(45, 106, 79, 0.07);
  border-color: rgba(45, 106, 79, 0.1);
}

.dashboard-inbox-preview__item.is-unread {
  background: linear-gradient(135deg, rgba(236, 253, 245, 0.95), rgba(209, 250, 229, 0.65));
  border-color: rgba(82, 183, 136, 0.28);
  box-shadow: 0 2px 10px -6px rgba(45, 106, 79, 0.12);
}

.dashboard-inbox-preview__item.is-unread strong {
  color: #14532d;
}

.dashboard-inbox-preview__text {
  flex: 1;
  min-width: 0;
}

.dashboard-inbox-preview__item strong {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  font-size: 0.8rem;
  font-weight: 800;
  color: #1b4332;
  line-height: 1.4;
}

.dashboard-inbox-preview__item small {
  display: block;
  margin-top: 3px;
  font-size: 0.7rem;
  font-weight: 600;
  color: #64748b;
}

.dashboard-inbox-preview__ic {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  line-height: 1;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(45, 106, 79, 0.1);
  box-shadow: 0 1px 4px rgba(27, 67, 50, 0.06);
}

.dashboard-inbox-preview__empty {
  margin: 0;
  padding: 14px 10px;
  font-size: 0.8rem;
  color: #64748b;
  line-height: 1.6;
  text-align: center;
  border-radius: 12px;
  background: rgba(45, 106, 79, 0.05);
  border: 1px dashed rgba(45, 106, 79, 0.18);
}

/* معاينة الإشعارات — الوضع الداكن */
html[data-theme="dark"] .dashboard-inbox-preview {
  background: linear-gradient(160deg, var(--clr-surface) 0%, var(--clr-bg-alt) 55%, rgba(15, 35, 25, 0.9) 100%);
  border-color: var(--clr-border);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.04) inset,
    var(--shadow-md);
}

html[data-theme="dark"] .dashboard-inbox-preview__head {
  border-bottom-color: var(--clr-border);
}

html[data-theme="dark"] .dashboard-inbox-preview__title {
  color: var(--clr-primary-dark);
}

html[data-theme="dark"] .dashboard-inbox-preview__badge {
  background: linear-gradient(135deg, #f87171, #dc2626);
  box-shadow: 0 2px 10px -2px rgba(0, 0, 0, 0.4);
}

html[data-theme="dark"] .dashboard-inbox-preview__all {
  color: var(--clr-primary-dark);
  background: var(--clr-primary-bg);
  border-color: rgba(82, 183, 136, 0.25);
}

html[data-theme="dark"] .dashboard-inbox-preview__all:hover {
  background: rgba(82, 183, 136, 0.2);
  color: var(--clr-text);
}

html[data-theme="dark"] .dashboard-inbox-preview__list {
  scrollbar-color: rgba(82, 183, 136, 0.3) transparent;
}

html[data-theme="dark"] .dashboard-inbox-preview__list::-webkit-scrollbar-thumb {
  background: rgba(82, 183, 136, 0.35);
}

html[data-theme="dark"] .dashboard-inbox-preview__item:hover {
  background: rgba(82, 183, 136, 0.1);
  border-color: var(--clr-border);
}

html[data-theme="dark"] .dashboard-inbox-preview__item.is-unread {
  background: linear-gradient(135deg, rgba(82, 183, 136, 0.16), rgba(15, 35, 25, 0.85));
  border-color: rgba(82, 183, 136, 0.35);
  box-shadow: none;
}

html[data-theme="dark"] .dashboard-inbox-preview__item strong {
  color: var(--clr-text);
}

html[data-theme="dark"] .dashboard-inbox-preview__item.is-unread strong {
  color: #a7f3d0;
}

html[data-theme="dark"] .dashboard-inbox-preview__item small {
  color: var(--clr-text-muted);
}

html[data-theme="dark"] .dashboard-inbox-preview__ic {
  background: var(--clr-bg-alt);
  border-color: var(--clr-border);
  box-shadow: none;
}

html[data-theme="dark"] .dashboard-inbox-preview__empty {
  color: var(--clr-text-md);
  background: var(--clr-bg-alt);
  border-color: var(--clr-border);
}

/* ── جرس الإشعارات — هاتف وشاشات صغيرة ───────────────── */
.mt-notif-bell__panel-close {
  display: none;
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  margin: -4px 0;
  margin-inline-start: auto;
  padding: 0;
  border: none;
  border-radius: 10px;
  background: rgba(45, 106, 79, 0.08);
  color: #1b4332;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.15s;
}

.mt-notif-bell__panel-close:hover {
  background: rgba(45, 106, 79, 0.16);
}

.mt-notif-bell__backdrop {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 10075;
  margin: 0;
  padding: 0;
  border: none;
  background: rgba(15, 23, 42, 0.42);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.mt-notif-bell__backdrop[hidden] {
  display: none !important;
}

@media (max-width: 768px) {
  body.mt-notif-panel-open {
    overflow: hidden;
    touch-action: none;
  }

  .mt-notif-bell.is-open .mt-notif-bell__backdrop:not([hidden]) {
    display: block;
  }

  .mt-notif-bell__panel {
    position: fixed;
    top: calc(var(--notice-height, 0px) + var(--nav-height, 64px) + 8px);
    inset-inline: 12px;
    left: 12px;
    right: 12px;
    width: auto;
    max-width: none;
    max-height: min(520px, calc(100dvh - var(--notice-height, 0px) - var(--nav-height, 64px) - 20px));
    z-index: 10080;
    border-radius: 16px;
    box-shadow: 0 22px 56px rgba(15, 23, 42, 0.28);
  }

  .mt-notif-bell__panel-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .mt-notif-bell__head {
    padding: 14px 12px;
  }

  .mt-notif-bell__guest-intro {
    padding: 0 12px 4px;
    font-size: 0.875rem;
    line-height: 1.55;
  }

  .mt-notif-bell__push {
    padding: 10px 12px 6px;
  }

  .mt-notif-bell__push-btn {
    min-height: 44px;
    padding: 11px 12px;
    font-size: 0.9rem;
  }

  .mt-notif-bell__push-hint {
    font-size: 0.8rem;
    line-height: 1.5;
    margin-top: 8px;
  }

  .mt-notif-bell__foot {
    padding: 10px 12px 14px;
  }

  .mt-notif-bell__all {
    display: block;
    text-align: center;
    padding: 8px 4px;
    font-size: 0.85rem;
  }
}

@media (max-width: 380px) {
  .mt-notif-bell__panel {
    inset-inline: 8px;
    left: 8px;
    right: 8px;
    border-radius: 14px;
  }
}

html[data-theme="dark"] .mt-notif-bell__panel-close {
  background: rgba(82, 183, 136, 0.12);
  color: #d8f3dc;
}

html[data-theme="dark"] .mt-notif-bell__panel-close:hover {
  background: rgba(82, 183, 136, 0.22);
}
