/* Staff header notifications — responsive (desktop / tablet / mobile) */

.staff-notifications-wrap {
  position: relative;
  display: flex;
  align-items: center;
  flex-shrink: 0;
  overflow: visible;
}

.staff-notifications-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: none;
  border-radius: 8px;
  background: none;
  color: var(--text-secondary, #5c6370);
  cursor: pointer;
  transition: color 0.2s ease, background 0.2s ease, opacity 0.2s ease;
  font-family: inherit;
  -webkit-tap-highlight-color: transparent;
  overflow: visible;
  flex-shrink: 0;
}

.staff-notifications-btn:hover,
.staff-notifications-btn.is-open,
.staff-notifications-btn.has-unread {
  color: var(--text-primary, #1f2428);
  background: var(--page-background, #f7f7f5);
}

.staff-notifications-btn:focus-visible {
  outline: 2px solid rgba(245, 194, 26, 0.6);
  outline-offset: 2px;
}

.staff-notifications-btn:active {
  opacity: 0.7;
}

.staff-notifications-icon {
  display: block;
  flex-shrink: 0;
  pointer-events: none;
  width: 22px;
  height: 22px;
}

.staff-notifications-badge {
  position: absolute;
  top: 4px;
  right: 2px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  border: 2px solid var(--card-background, #fff);
  background: #e53935;
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  line-height: 12px;
  text-align: center;
  display: none;
  box-sizing: border-box;
  letter-spacing: -0.02em;
  pointer-events: none;
  z-index: 1;
}

.staff-notif-pulse .staff-notifications-icon {
  animation: staffNotifRing 0.55s ease 3;
}

@keyframes staffNotifRing {
  0%, 100% { transform: rotate(0); }
  15% { transform: rotate(12deg); }
  30% { transform: rotate(-10deg); }
  45% { transform: rotate(8deg); }
  60% { transform: rotate(-6deg); }
  75% { transform: rotate(0); }
}

.staff-notifications-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  z-index: 1090;
}

.staff-notifications-backdrop.open {
  display: block;
}

.staff-notifications-panel {
  display: none;
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: min(360px, calc(100vw - 24px));
  max-height: min(420px, 70vh);
  background: var(--card-background, #fff);
  border: 1px solid var(--border-color, #e9ecef);
  border-radius: 14px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.14);
  z-index: 1100;
  overflow: hidden;
  flex-direction: column;
}

.staff-notifications-panel.open {
  display: flex;
}

.staff-notifications-panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-color, #e9ecef);
  background: var(--page-background, #fafaf8);
}

.staff-notifications-panel__head h4 {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary, #1f2428);
  font-family: inherit;
}

.staff-notifications-panel__actions {
  display: flex;
  gap: 8px;
}

.staff-notifications-mark-read {
  border: none;
  background: none;
  color: var(--text-secondary, #666);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  padding: 4px 6px;
}

.staff-notifications-mark-read:hover {
  color: var(--primary-hover, #d4a416);
}

.staff-notifications-list {
  overflow-y: auto;
  flex: 1;
  padding: 8px;
}

.staff-notif-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  width: 100%;
  text-align: left;
  border: none;
  background: transparent;
  border-radius: 10px;
  padding: 10px;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s ease;
}

.staff-notif-item:hover {
  background: var(--page-background, #fafaf8);
}

.staff-notif-item--unread {
  background: rgba(245, 194, 26, 0.1);
}

.staff-notif-item__icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(245, 194, 26, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--primary-hover, #d4a416);
}

.staff-notif-item__body {
  flex: 1;
  min-width: 0;
}

.staff-notif-item__title {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary, #1f2428);
  line-height: 1.35;
}

.staff-notif-item__meta {
  display: block;
  font-size: 11px;
  color: var(--text-secondary, #666);
  margin-top: 2px;
}

.staff-notif-item__time {
  font-size: 10px;
  color: var(--text-secondary, #999);
  flex-shrink: 0;
}

.staff-notifications-empty {
  padding: 28px 16px;
  text-align: center;
  color: var(--text-secondary, #666);
  font-size: 13px;
}

@media (max-width: 991px) {
  .staff-notifications-btn {
    width: 38px;
    height: 38px;
    border-radius: 8px;
  }

  .staff-notifications-icon {
    width: 20px;
    height: 20px;
  }

  .staff-notifications-panel {
    position: fixed;
    top: auto;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    max-width: 100%;
    max-height: 75vh;
    border-radius: 16px 16px 0 0;
  }

  .staff-notifications-panel.open {
    display: flex;
  }
}
