.notifications-head { display: flex; justify-content: space-between; gap: 16px; align-items: center; margin-bottom: 16px; }
.notifications-head h1 { margin: 0 0 4px; font: 500 28px/36px var(--font); }
.notifications-actions { display: flex; gap: 8px; align-items: center; }
.notification-day { margin: 0; padding: 14px 8px 8px; font-size: 13px; color: var(--gray); }
.notification-row { display: flex; align-items: center; gap: 12px; min-height: 72px; padding: 12px 8px; border-bottom: 1px solid var(--border); }
.notification-row:last-child { border-bottom: 0; }
.notification-row--unread { background: #fffdf2; }
.notification-content { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.notification-text { color: var(--ink); font-size: 15px; line-height: 22px; }
.notification-filters { margin: 0 0 12px; }
.notification-meta { margin: 0; display: flex; align-items: center; gap: 4px; font-size: 13px; }
.notification-community { color: var(--gray); }
.notification-read { display: grid; place-items: center; width: 28px; height: 28px; padding: 0; border: 0; background: none; cursor: pointer; }
.notification-read span { width: 10px; height: 10px; border-radius: 50%; background: var(--blue); transition: background .15s; }
.notification-read:hover span, .notification-read:focus-visible span { background: var(--ink); }
.notification-system { display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--yellow); font-weight: 700; }
.preference-row { padding: 10px 0; border-bottom: 1px solid var(--border); }
.notification-preferences h1 { margin-top: 0; }
.notification-preferences h2 { font-size: 20px; }
.notification-bell { position: relative; }
.notification-bell.is-open { background: var(--card); border: 1px solid var(--border); color: var(--ink); }

/* Painel ancorado no sino, no lugar de navegar para a central (medidas do Skool) */
.notification-menu { position: relative; }
.notification-panel { position: absolute; right: -4px; top: 56px; display: flex; flex-direction: column; width: 500px; max-width: calc(100vw - 32px); max-height: min(560px, calc(100vh - 120px)); background: var(--card); border: 1px solid var(--border); border-radius: var(--r-md); box-shadow: var(--shadow-ui); z-index: 1200; overflow: hidden; }
.panel-head { display: flex; align-items: center; gap: 16px; padding: 14px 20px; border-bottom: 1px solid var(--border); }
.panel-title { flex: 1; font: 500 16px/24px var(--font); color: var(--ink); }
.panel-head form { display: flex; }
.panel-filter-wrap { position: relative; display: inline-flex; align-items: center; color: var(--gray); }
.panel-filter-wrap .icon { position: absolute; right: 0; pointer-events: none; }
.panel-filter { height: 28px; padding: 0 20px 0 4px; border: 0; background: none; appearance: none; color: var(--gray); font: 400 14px/20px var(--font); cursor: pointer; }
.panel-list { flex: 1; overflow-y: auto; overscroll-behavior: contain; }
.panel-row { display: flex; align-items: center; padding: 12px 20px; border-bottom: 1px solid var(--border); color: var(--ink); }
.panel-link { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 0; color: inherit; }
.panel-row:last-child { border-bottom: 0; }
.panel-row:hover { background: var(--surface); }
.panel-avatar { position: relative; flex: none; }
.panel-origin { position: absolute; left: -4px; bottom: -4px; display: grid; place-items: center; width: 18px; height: 18px; border-radius: var(--r-sm); border: 2px solid var(--card); background: var(--gray); color: #fff; font: 700 8px/1 var(--font); overflow: hidden; }
.panel-origin img { width: 100%; height: 100%; object-fit: cover; }
.panel-origin:has(img) { background: var(--card); }
.panel-content { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.panel-text { font: 400 15px/21px var(--font); }
.panel-time { color: var(--gray); }
.panel-preview { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--gray); font: 400 14px/20px var(--font); }
/* Lida recua: opacidade no avatar (sem texto) e cinza mais escuro no texto, que
   precisa continuar legível — opacidade no bloco todo derruba o contraste. */
.panel-row:not(.panel-row--unread) .panel-avatar,
.notification-row:not(.notification-row--unread) .avatar,
.notification-row:not(.notification-row--unread) .notification-system { opacity: .55; }
.panel-row:not(.panel-row--unread) .panel-text,
.notification-row:not(.notification-row--unread) .notification-text { color: #6b6b6b; }
.read-toggle { display: flex; flex: none; margin-left: 8px; }
.read-toggle button { display: grid; place-items: center; width: 28px; height: 28px; padding: 0; border: 0; border-radius: 50%; background: none; cursor: pointer; }
.read-toggle button:hover { background: var(--surface); }
.read-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--blue); }
.read-dot--read { background: none; border: 2px solid var(--gray); opacity: 0; transition: opacity .1s; }
.panel-row:hover .read-dot--read, .notification-row:hover .read-dot--read, .read-toggle button:focus-visible .read-dot--read { opacity: 1; }
.panel-empty { margin: 0; padding: 32px 20px; text-align: center; color: var(--gray); }
.panel-foot { display: block; padding: 12px; border-top: 1px solid var(--border); text-align: center; color: var(--blue); font: 500 14px/20px var(--font); }
.panel-foot:hover { background: var(--surface); }

.notification-badge { position: absolute; top: 3px; right: 1px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: var(--red-today); color: #fff; font: 700 10px/17px var(--font); text-align: center; }
@media (max-width: 767px) {
  /* celular: o container perde o padding (cards de ponta a ponta); título, botões e filtros ganham margem */
  .notifications-head { align-items: flex-start; flex-direction: column; padding: 0 16px; }
  .notifications-actions { width: 100%; }
  /* os dois botões na mesma linha: menores para caber em 360px */
  .notifications-actions .btn-sm { height: 36px; padding: 0 10px; font-size: 12px; }
  .notification-filters { padding: 0 16px; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .notification-filters .pill { flex: none; }
}
