/* Notifications (planning/26_Notifications.md §6.2): the bell beside the person's name, and the page. */

/* The bell, with how many are unread over its corner. */
.bell { position: relative; flex: none; }
.bell__count {
  position: absolute; top: -3px; right: -4px; min-width: 16px; padding: 0 4px; border-radius: 999px;
  background: var(--info); color: var(--surface); font-size: 10px; font-weight: 600; line-height: 16px; text-align: center;
  font-variant-numeric: tabular-nums; pointer-events: none;
}
.sidebar__user .bell { margin-left: auto; }
[data-sidebar="collapsed"] .sidebar__user { flex-direction: column; }
[data-sidebar="collapsed"] .sidebar__user .bell { margin-left: 0; }
.phonebar .bell { flex: none; }
.phonebar__name + .bell { margin-left: auto; }

/* The page: a calm column, what's new (in bold, with a dot) above what's been seen (D3). */
.notifications { max-width: 720px; gap: var(--space-5); }
.notifications__heading { font-size: var(--text-sm); font-weight: 600; color: var(--text-secondary); }
.notifications__caught-up { color: var(--text-secondary); }

/* A row: the title, when and a new one's ✕ on its first line, the body under them all, so it has a phone's width. */
.notification { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; gap: 2px var(--space-3); }
.notification__title { grid-area: 1 / 1; font-weight: 400; color: var(--text); }
.notification--unread .notification__title { font-weight: 600; }
.notification__dot {
  display: inline-block; width: 8px; height: 8px; margin-right: var(--space-2); border-radius: 50%;
  background: var(--info); vertical-align: 0.1em;
}
.notification__body { grid-area: 2 / 1 / 3 / -1; color: var(--text-secondary); font-size: var(--text-sm); white-space: pre-line; text-wrap: pretty; overflow-wrap: anywhere; }
.notification__time { grid-area: 1 / 2; color: var(--text-tertiary); font-size: var(--text-sm); white-space: nowrap; }
/* ✕ reads a new one without opening it: above the row's link, which covers the rest of the row. */
.notification__read-form { grid-area: 1 / 3; align-self: center; margin-block: -6px; }
.notification__read { position: relative; z-index: 1; }

/* Notification settings (§6.4): what's on for this device, in a box; then each of the person's groups, its choices on
   one line where they fit; then their devices, this one marked (push_controller). */
.notification-settings { max-width: 640px; gap: var(--space-6); }
.notification-status__row { justify-content: space-between; }
.notification-status__row p { flex: 1 1 16rem; }
.notification-status__row p .icon { color: var(--success); }
.notification-group { padding-block: var(--space-2); }
.notification-group__name { padding: 0; font-size: var(--text-base); font-weight: 600; }
.notification-group__choices { gap: var(--space-2) var(--space-5); }
.notification-group__email { gap: var(--space-2); font-size: var(--text-sm); }
.email-offer { align-items: center; flex-wrap: wrap; }
.email-offer p { flex: 1 1 16rem; }
.device { flex-wrap: wrap; }
.device__actions { gap: var(--space-1); margin-inline-start: auto; }
.device__this { display: none; }
.device[data-this-device] .device__this { display: inline; }
