/* =====================================================================
   Opera Populi : cloche des notifications et tiroir des votes reçus (addendum V4, section 3)
   ===================================================================== */

/* ---------- Cloche de l'en-tête + pastille ---------- */
.news-btn { position: relative; padding-inline: var(--sp-2); min-width: 2.25rem; }
.news-badge {
  position: absolute; top: -.35rem; right: -.35rem; display: grid; place-items: center;
  min-width: 1.25rem; height: 1.25rem; padding: 0 .3rem; border-radius: 999px;
  background: var(--accent); color: var(--accent-ink); box-shadow: 0 0 0 2px var(--bg);
  font-size: var(--fs-2xs); font-weight: var(--fw-bold); line-height: 1;
}
@media (max-width: 30rem) { .news-btn { min-height: 2.75rem; } }

/* ---------- Tiroir latéral (dialog natif, modale) ---------- */
.drawer {
  position: fixed; inset: 0 0 0 auto; margin: 0; padding: 0;
  width: min(25rem, 100vw); max-width: 100vw; height: 100dvh; max-height: 100dvh;
  border: 0; border-left: 1px solid var(--line); border-radius: var(--r-lg) 0 0 var(--r-lg);
  background: var(--surface); color: var(--text); box-shadow: var(--shadow-lg);
}
.drawer::backdrop { background: rgb(20 12 8 / .5); }
.drawer[open] { animation: drawer-in .28s var(--ease-out); }
@keyframes drawer-in { from { translate: 100% 0; } }
.drawer__panel { display: flex; flex-direction: column; height: 100%; }
.drawer__head {
  display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3);
  padding: max(1rem, env(safe-area-inset-top)) clamp(1rem, 4vw, 1.5rem) 1rem; border-bottom: 1px solid var(--line);
}
.drawer__title { display: flex; align-items: center; gap: .5rem; font-size: var(--fs-xl); }
.drawer__title .icon { color: var(--accent-text); }
.drawer__close {
  display: grid; place-items: center; width: 2.5rem; height: 2.5rem; border-radius: var(--r-sm);
  color: var(--text-muted); transition: background-color var(--dur), color var(--dur);
}
.drawer__close:hover { background: var(--surface-3); color: var(--text); }
.drawer__body { flex: 1; display: grid; align-content: start; gap: var(--sp-4); overflow-y: auto; padding: clamp(1rem, 4vw, 1.5rem); }
.drawer__foot { padding: 1rem clamp(1rem, 4vw, 1.5rem) max(1rem, env(safe-area-inset-bottom)); border-top: 1px solid var(--line); }
@media (max-width: 39.99rem) {
  .drawer { width: 100vw; border-left: 0; border-radius: 0; }
}
@media (prefers-reduced-motion: reduce) { .drawer[open] { animation: none; } }

/* ---------- Votes reçus ---------- */
.news-list { display: grid; gap: .6rem; }
.news-item {
  display: grid; grid-template-columns: auto 1fr; align-items: start; gap: .75rem; padding: .85rem 1rem;
  border: 1px solid color-mix(in srgb, var(--accent) 22%, transparent); border-radius: var(--r-md); background: var(--accent-soft);
  overflow-wrap: anywhere;
}
.news-item__icon { display: grid; place-items: center; width: 2.25rem; height: 2.25rem; border-radius: var(--r-sm); background: var(--surface); color: var(--accent-text); }
.news-item__delta { color: var(--accent-text); }
.news-item__total { color: var(--text-muted); }
.news-empty { padding-block: var(--sp-5); }

/* ---------- Carte "Mes idées" : votes du groupe ---------- */
.idea__votes-new { color: var(--accent-text); font-weight: var(--fw-bold); }
