/* =====================================================
   SuppTree — Shared Notification Bell Styles (Welle 11)
   =====================================================
   Stile für window.SUPPTREE_NOTIFICATION_BELL. Klassen-Präfix
   `stn-*` (für „SuppTree Notification"). Mobile-friendly:
   max-width 360px Popover, scrollbarer Body.
   ===================================================== */

.stn-bell {
  position: relative;
  display: inline-block;
  vertical-align: middle;
}

.stn-bell-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: transparent;
  border: 1px solid var(--border, #e5e7eb);
  border-radius: 8px;
  cursor: pointer;
  padding: 0;
  font-size: 16px;
  line-height: 1;
  transition: background 0.15s ease;
  color: inherit;
}
.stn-bell-btn:hover { background: var(--bg-hover, rgba(0,0,0,0.04)); }
.stn-bell-btn:focus { outline: 2px solid var(--green-accent, #00A67E); outline-offset: 1px; }

.stn-bell-icon { font-size: 18px; line-height: 1; }

.stn-bell-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  background: #dc2626;
  color: #ffffff;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--white, #ffffff);
  box-sizing: content-box;
  line-height: 1;
}

/* ----------------------------------------------------- */
/* Popover */
/* ----------------------------------------------------- */
.stn-pop {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  width: 360px;
  max-width: 92vw;
  background: var(--white, #ffffff);
  border: 1px solid var(--border, #e5e7eb);
  border-radius: 10px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.18);
  z-index: 9000;
  display: flex;
  flex-direction: column;
  max-height: 70vh;
  color: #111827;
}

.stn-pop-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border, #e5e7eb);
  background: var(--cream, #f8f9fa);
  border-radius: 10px 10px 0 0;
}
.stn-pop-title {
  flex: 1;
  font-weight: 700;
  font-size: 14px;
}
.stn-pop-close {
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: 14px;
  color: inherit;
  padding: 2px 6px;
  border-radius: 4px;
}
.stn-pop-close:hover { background: rgba(0,0,0,0.06); }

.stn-pop-body {
  flex: 1;
  overflow-y: auto;
  padding: 6px 0;
}

.stn-pop-foot {
  padding: 8px 12px;
  border-top: 1px solid var(--border, #e5e7eb);
  font-size: 10px;
  color: #6b7280;
  background: var(--cream, #f8f9fa);
  border-radius: 0 0 10px 10px;
  line-height: 1.4;
}

/* ----------------------------------------------------- */
/* Gruppen + Items */
/* ----------------------------------------------------- */
.stn-group {
  padding: 4px 0 6px;
  border-bottom: 1px solid var(--border, #e5e7eb);
}
.stn-group:last-child { border-bottom: none; }

.stn-group-head {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px 4px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  color: #6b7280;
}
.stn-group-icon { font-size: 13px; }
.stn-group-label { flex: 1; }
.stn-group-count {
  background: var(--green-light, #E8F5E9);
  color: var(--green-dark, #1a5a3a);
  font-size: 10px;
  font-weight: 800;
  padding: 1px 7px;
  border-radius: 999px;
}

.stn-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  width: 100%;
  padding: 8px 12px;
  background: transparent;
  border: none;
  border-left: 3px solid transparent;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
  color: inherit;
  transition: background 0.12s ease;
}
.stn-item:hover { background: var(--bg-hover, rgba(0,0,0,0.04)); }
.stn-item:focus { outline: 2px solid var(--green-accent, #00A67E); outline-offset: -2px; }

.stn-sev {
  flex-shrink: 0;
  width: 8px;
  height: 8px;
  margin-top: 7px;
  border-radius: 50%;
  background: #9ca3af;
}
.stn-sev-kritisch { background: #dc2626; }
.stn-sev-hoch     { background: #ef4444; }
.stn-sev-mittel   { background: #f59e0b; }
.stn-sev-niedrig  { background: #3b82f6; }
.stn-sev-info     { background: #6b7280; }

.stn-item-body {
  flex: 1;
  min-width: 0;
}
.stn-item-title {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.3;
  word-wrap: break-word;
}
.stn-item-sub {
  font-size: 11px;
  color: #6b7280;
  margin-top: 2px;
  line-height: 1.35;
  word-wrap: break-word;
}
.stn-item-ts {
  font-size: 10px;
  color: #9ca3af;
  margin-top: 3px;
}
.stn-item-arr {
  flex-shrink: 0;
  font-size: 16px;
  color: #9ca3af;
  margin-top: 4px;
}

.stn-empty {
  padding: 24px 16px;
  text-align: center;
  color: #6b7280;
  font-size: 13px;
}
