:root {
  --paper: #F3F4F1;
  --card: #FFFFFF;
  --ink: #16202A;
  --muted: #5F6873;
  --rule: #D6DAD4;
  --money: #B3261E;      /* argent : rouge adouci (le rouge vif #DA291C reste réservé au logo) */
  --money-soft: #F6DCDD;
  --infl: #1F5F8B;       /* influence : bleu */
  --infl-soft: #DCE8F1;
  --focus: #F2B705;
  /* groupes parlementaires (couleurs usuelles des partis) */
  --f-G: #6FA83A; --f-S: #D93A3A; --f-GL: #B3AE1F; --f-ME: #EF8C00; --f-RL: #2F6DB3; --f-V: #1F6B35; --f-X: #9AA4AE;
  --yes: #1F5F8B; --no: #B3261E; --abst: #E0A100; --absent: #C9CEC6; --excuse: #8C959E;
  /* Échelle typographique : six tailles, pas une de plus */
  --fs-display: clamp(2rem, 4.6vw, 3.25rem);  /* titre de page (h1) */
  --fs-h2: clamp(1.5rem, 3vw, 2rem);          /* titre de section hors encart */
  --fs-h3: clamp(1.25rem, 2.2vw, 1.5rem);     /* titre d'encart */
  --fs-h4: 1.0625rem;                          /* sous-titre, nom dans une liste */
  --fs-sm: .875rem;                            /* notes, détails, légendes */
  --fs-label: .75rem;                          /* étiquettes en capitales */
  --fs-big: clamp(2rem, 4vw, 2.75rem);        /* grands chiffres */
  --band: #16202A;  /* bandeau des dossiers : encre (choix du 29.09.2026, le rouge plein piquait les yeux) */
  --radius-s: 0;    /* direction « Affiche » : pas d'arrondi, la grille et les filets font la séparation */
  --radius-l: 0;
  color-scheme: light;
  box-sizing: border-box;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #12171D; --card: #1A2129; --ink: #E9ECEF; --muted: #9AA4AE; --rule: #2C3540;
    --money: #F0555D; --money-soft: #3A1E22; --infl: #6FAEDB; --infl-soft: #17303F; color-scheme: dark; --band: #26303B;
    --f-G: #8BC653; --f-S: #F0625D; --f-GL: #D4CF45; --f-ME: #F7A433; --f-RL: #5E97DB; --f-V: #3E9B57; --f-X: #6B7580;
    --yes: #6FAEDB; --no: #F0555D; --abst: #F2C14E; --absent: #3A4552; --excuse: #6B7580;
  }
}
:root[data-theme="dark"] {
  --paper: #12171D; --card: #1A2129; --ink: #E9ECEF; --muted: #9AA4AE; --rule: #2C3540;
  --money: #F0555D; --money-soft: #3A1E22; --infl: #6FAEDB; --infl-soft: #17303F; color-scheme: dark; --band: #26303B;
  --f-G: #8BC653; --f-S: #F0625D; --f-GL: #D4CF45; --f-ME: #F7A433; --f-RL: #5E97DB; --f-V: #3E9B57; --f-X: #6B7580;
  --yes: #6FAEDB; --no: #F0555D; --abst: #F2C14E; --absent: #3A4552; --excuse: #6B7580;
}
*, *::before, *::after { box-sizing: inherit; }
html { scroll-padding-top: calc(env(safe-area-inset-top, 0px) + 64px); }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 16px/1.55 "Schibsted Grotesk", "Helvetica Neue", Arial, sans-serif;
}
/* Chiffres alignés seulement là où ils sont en colonne (sur tout le texte, la virgule s'élargit : « parler , calculés ») */
td.num, th.num { font-variant-numeric: tabular-nums; }  /* seulement en colonne : dans Schibsted, la virgule tabulaire s'élargit (« 4 , 3 mio ») */
/* Trois façons de cliquer, pas plus : souligné fin = ouvrir une fiche ou un lien ; gras souligné rouge + flèche = aller vers une page ; encadré = action.
   Le bleu reste réservé aux données (oui, influence). */
a, button.link { color: var(--ink); text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--money) 55%, transparent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover, button.link:hover { text-decoration-color: var(--money); text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 20px; }

/* En-tête */
.top {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 10;
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: blur(8px); border-bottom: 1px solid var(--rule);
}
.top-inner { display: flex; align-items: center; gap: 24px; min-height: 56px; }
.brand { display: inline-flex; align-items: center; gap: .45em; font-weight: 800; font-size: var(--fs-h4); letter-spacing: -.02em; color: var(--ink); text-decoration: none; white-space: nowrap; }
.brand img { width: 1.5em; height: 1.5em; flex: none; }  /* logo « tampon » : carré rouge, « ? » blanc (img/logo.svg) */
.tabs { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; align-self: stretch; }
.tabs a { display: flex; align-items: center; padding: 0 11px; color: var(--muted); text-decoration: none; white-space: nowrap; font-weight: 700; border-bottom: 3px solid transparent; }
.tabs a:hover { color: var(--ink); }
.tabs a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--money); }
.subnav { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 20px; margin: 28px 0 -18px; padding: 10px 0 0; border-top: 2px solid var(--ink); }
.subnav-label { font-size: var(--fs-label); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ink); margin-right: 4px; display: inline-flex; align-items: center; gap: 8px; }
.subnav-label::before { content: ""; display: inline-block; width: 10px; height: 10px; background: var(--money); }
.subnav a { font-size: 1rem; font-weight: 700; padding: 2px 0 4px; color: var(--muted); text-decoration: none; border-bottom: 3px solid transparent; }
.subnav a:hover { color: var(--ink); }
.subnav a.on { color: var(--ink); border-bottom-color: var(--money); }
/* Filtres : un choix visible, pas un détail */
#tab-dons .filters, #tab-votations .filters, #tab-parlement .filters, #tab-reseaux .filters, #tab-absences .filters, #tab-lobbyistes .filters, #tab-tendances .filters { align-items: center; padding: 10px 0; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--rule); }
#tab-dons .filters::before, #tab-votations .filters::before, #tab-parlement .filters::before, #tab-reseaux .filters::before, #tab-absences .filters::before, #tab-lobbyistes .filters::before, #tab-tendances .filters::before { content: "Filtrer"; font-size: var(--fs-label); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ink); }
.filters[hidden] { display: none; }
#tab-votations .filters.level { border: 0; padding: 0; margin-bottom: 8px; }
#tab-votations .filters.level::before { content: "Niveau"; }
#tab-dons .filters select, #tab-votations .filters select, #tab-parlement .filters select, #tab-reseaux .filters select, #tab-absences .filters select, #tab-lobbyistes .filters select, #tab-tendances .filters select { border: 1px solid var(--ink); font-weight: 700; }

/* Accueil */
.eyebrow { margin: 44px 0 0; font-size: var(--fs-label); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ink); }
.eyebrow::before { content: ""; display: inline-block; width: 12px; height: 12px; margin: 0 10px 2px 0; vertical-align: middle; background: var(--money); }
.hero { font-size: var(--fs-display); line-height: 1.05; letter-spacing: -.035em; font-weight: 800; margin: 10px 0 16px; max-width: 20ch; }
.lede { color: var(--muted); max-width: 62ch; font-size: var(--fs-h4); margin: 0 0 24px; }
.search-big { display: block; }
.search-big input { padding: 14px 18px; font-size: clamp(1.05rem, 3vw, 1.3rem); }
.more-links { margin: 20px 0 0; }
.foot-nav { font-weight: 700; }
.more-links a + a::before, .foot-nav a + a::before { content: " · "; color: var(--muted); font-weight: 400; }
.une-card .big + h3 { margin-top: 2px; }

/* La question de la semaine et la prochaine votation */
.qsem { border-top: 2px solid var(--ink); margin: 0 0 16px; padding: 18px 22px 20px; }
.qsem .big { font-size: clamp(2.6rem, 8vw, 4.4rem); line-height: .95; margin: 8px 0 8px; }
.qsem .fait { margin: 0 0 14px; max-width: 60ch; color: var(--muted); }
.qsem h2.qs-q { margin: 6px 0 6px; font-size: var(--fs-h2); }
.qsem .answers { margin: 12px 0 6px; }
.qsem .answers .btn { font-size: 1rem; font-weight: 700; padding: 10px 26px; }
.qsem .btn[aria-pressed="true"] { outline: 3px solid var(--focus); outline-offset: 2px; }
.qsem .link { align-self: center; }
.qs-bar { display: flex; height: 14px; border-radius: 3px; overflow: hidden; background: var(--money-soft); margin: 8px 0 6px; }
.qs-bar span { background: var(--infl); transition: width .4s; }
.qs-res .summary { margin: 0 0 6px; }
.qs-res .answers { margin: 8px 0 0; }
.home-grid { margin: 0 0 28px; }
.prochaine .list li { padding: 7px 0; }
.promo-card .go { margin-top: 2px; }
.home-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); }
/* Cote de confiance */
.conf-filters { margin: 8px 0 4px; align-items: center; }
.mes-elus, .vot-home { border-top: 2px solid var(--ink); margin: 0 0 16px; padding: 18px 22px 20px; }
.canton-pick { display: inline-flex; align-items: center; gap: 10px; }
.canton-pick select { font-size: 1rem; font-weight: 700; padding: 10px 14px; border: 2px solid var(--ink); }
.list li.elu-row { display: grid; grid-template-columns: 1fr; gap: 6px; padding: 12px 0; }
.elu-row .elu-card-head img { width: 44px; height: 44px; }
.elu-facts { margin: 0; font-size: var(--fs-sm); color: var(--muted); }
.vh-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 12px 28px; }
.vh-grid h3 { margin: 8px 0 6px; }
.vh-grid .pill { margin-left: 6px; }

.conf-filters .btn { text-decoration: none; }
.conf-grid .hint { margin: 10px 0 6px; }
.conf-list { list-style: none; margin: 0 0 12px; padding: 0; }
.conf-list li { display: grid; grid-template-columns: minmax(180px, 1fr) auto; align-items: center; gap: 8px 16px; padding: 8px 0; border-bottom: 1px solid var(--rule); }
.conf-list .elu-card-head img { width: 44px; height: 44px; }
.conf-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.btn.small { padding: 5px 14px; font-size: var(--fs-sm); }
.conf-block .btn[aria-pressed="true"] { outline: 3px solid var(--focus); outline-offset: 2px; }
.conf-q { margin: 0 0 8px; font-weight: 700; }
.conf-lbl { font-weight: 700; font-size: var(--fs-sm); margin-right: 2px; }
.conf-q small { font-weight: 400; }
.conf-res { font-size: var(--fs-sm); color: var(--muted); display: inline-flex; align-items: center; gap: 6px; }
.conf-bar { display: inline-flex; width: 80px; height: 10px; border-radius: 3px; overflow: hidden; background: var(--money-soft); }
.conf-bar span { background: var(--infl); }
.conf-grid { margin-top: 10px; }
.conf-grid h3 { margin-bottom: 8px; }
@media (max-width: 640px) { .conf-list li { grid-template-columns: 1fr; } }
/* S'engager */
.parti-card h3 { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.parti-card .answers { margin: 4px 0 8px; }
.parti-card .btn { text-decoration: none; }
.spot-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 0 20px; }
.spot-row { padding: 10px 0; border-top: 1px solid var(--rule); display: grid; gap: 6px; align-content: start; }
.spot .elu-card-head { gap: 10px; }
.spot .elu-card-head img { width: 36px; height: 36px; }
.spot-kpi { margin: 0; font-size: var(--fs-sm); color: var(--muted); }
.spot-art { margin: 0; font-size: 1rem; }
.spot-art a { font-weight: 600; }
.search-big input {
  width: 100%; font: inherit; font-size: clamp(1.2rem, 3.5vw, 1.6rem); font-weight: 500;
  padding: 18px 20px; border: 2px solid var(--ink); border-radius: var(--radius-l);
  background: var(--card); color: var(--ink);
}
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 32px; }
.chips.row { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin: 10px 0 24px; }
.chips.row .chip { flex: none; }
.chip { font: inherit; font-size: var(--fs-sm); font-weight: 500; padding: 6px 12px; border: 1px solid var(--ink); background: var(--card); color: var(--ink); cursor: pointer; }
.chip:hover { border-color: var(--ink); }

h2 { font-size: var(--fs-h2); line-height: 1.15; letter-spacing: -.025em; margin: 40px 0 10px; }
h3 { font-size: var(--fs-h4); line-height: 1.3; margin: 0 0 12px; }
/* Titre d'encart : un seul format, qu'il soit en h2 (.qs-q) ou en h3 */
.card h2, .card .qs-q, .card > h3 { font-size: var(--fs-h3); line-height: 1.2; letter-spacing: -.02em; margin: 2px 0 10px; }
.note { color: var(--muted); font-size: 1rem; max-width: 70ch; margin: 0 0 20px; }

/* Résultats de recherche */
.group { margin: 0 0 28px; }
.group h3 { display: flex; align-items: baseline; gap: 8px; }
.group h3 small { color: var(--muted); font-weight: 400; }
.hit {
  display: grid; grid-template-columns: 1fr auto; gap: 4px 16px; width: 100%; text-align: left;
  font: inherit; color: inherit; background: var(--card); border: 1px solid var(--rule);
  border-left: 4px solid var(--rule); border-radius: var(--radius-s); padding: 12px 14px; margin: 0 0 6px; cursor: pointer;
}
.hit:hover { border-color: var(--ink); }
.hit, .vote-row, .empty, .charte, .hypo { border-radius: 0; }
.hit.m { border-left-color: var(--money); }
.hit.i { border-left-color: var(--infl); }
.hit strong { font-weight: 700; }
.hit .sub { grid-column: 1 / -1; color: var(--muted); font-size: var(--fs-sm); }
.amount { font-weight: 700; white-space: nowrap; }
.m .amount, .money { color: var(--money); }
.i .amount, .infl { color: var(--infl); }
.empty { padding: 28px; border: 1px dashed var(--rule); border-radius: var(--radius-l); color: var(--muted); }

/* Filtres */
.filters { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 16px; }
.filters input, .filters select {
  font: inherit; font-size: 1rem; padding: 9px 12px;
  border: 1px solid var(--ink); background: var(--card); color: var(--ink); min-width: 0;
}
.filters input[type="search"] { flex: 1 1 220px; }
.filters select { flex: 0 1 auto; max-width: 100%; }
.filters button, .pager button, .btn {
  font: inherit; font-size: 1rem; font-weight: 700; padding: 9px 16px; border-radius: 0;
  border: 1px solid var(--ink); background: var(--ink); color: var(--paper); cursor: pointer;
}
.btn.ghost, .pager button { background: transparent; color: var(--ink); }
.pager button[disabled] { opacity: .35; cursor: default; }
.summary { font-weight: 500; margin: 0 0 10px; }

/* Tableaux */
.table-wrap { overflow-x: auto; border: 0; border-top: 5px solid var(--ink); background: var(--card); }
table { border-collapse: collapse; width: 100%; font-size: var(--fs-sm); font-family: "Archivo", "Schibsted Grotesk", "Helvetica Neue", Arial, sans-serif; font-variant-numeric: tabular-nums; }
th, td { padding: 9px 12px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--rule); }
th { font-size: var(--fs-label); letter-spacing: .14em; text-transform: uppercase; font-weight: 800; color: var(--muted); white-space: nowrap; position: sticky; top: 0; background: var(--card); border-bottom: 2px solid var(--ink); }
td strong, td b { font-weight: 800; }
th button { all: unset; cursor: pointer; }
th button::after { content: " ↕"; color: var(--muted); font-weight: 400; }
td.num, th.num { text-align: right; white-space: nowrap; }
tr.click { cursor: pointer; }
tr.click:hover td { background: color-mix(in srgb, var(--infl-soft) 55%, transparent); }
.tag { display: inline-block; font-size: var(--fs-label); font-weight: 700; letter-spacing: .06em; text-transform: uppercase; padding: 2px 7px; background: var(--paper); border: 1px solid var(--rule); white-space: nowrap; }
.tag.pour { background: var(--infl-soft); border-color: transparent; }
.tag.contre { background: var(--money-soft); border-color: transparent; }
.tag.paid { background: var(--money-soft); border-color: transparent; }
.pager { display: flex; gap: 8px; align-items: center; margin: 12px 0 0; color: var(--muted); }

/* Graphiques */
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 460px), 1fr)); gap: 16px; }
.card { background: var(--card); border: 0; border-top: 1px solid var(--ink); padding: 16px 18px 18px; min-width: 0; }
.card h3 { letter-spacing: -.01em; }
.card.wide { grid-column: 1 / -1; }
/* Intertitre dans un encart (« Par parti », « Par élu ») */
.card p.hint { color: var(--ink); font-size: var(--fs-sm); font-weight: 700; margin: 18px 0 8px; }
.card h2 + p.hint, .card h3 + p.hint, .card .qs-q + p.hint { margin-top: 0; font-weight: 400; color: var(--muted); }
.bars { display: grid; gap: 6px; }
.bar { display: grid; grid-template-columns: minmax(90px, 38%) 1fr auto; gap: 10px; align-items: center; font-size: var(--fs-sm); }
.bar .lbl { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar .lbl button { all: unset; cursor: pointer; }
.bar .lbl button:hover { text-decoration: underline; }
.bar .track { height: 10px; background: var(--paper); overflow: hidden; display: flex; }
.bar .fill { height: 100%; }
.fill.m { background: var(--money); }
.fill.i { background: var(--infl); }
.fill.i2 { background: color-mix(in srgb, var(--infl) 35%, var(--paper)); }
.fill.f-G { background: var(--f-G); } .fill.f-S { background: var(--f-S); } .fill.f-GL { background: var(--f-GL); } .fill.f-ME { background: var(--f-ME); } .fill.f-RL { background: var(--f-RL); } .fill.f-V { background: var(--f-V); } .fill.f-X { background: var(--f-X); }
.cl-parti { margin: 0 0 14px; padding: 0 0 12px; border-bottom: 1px solid var(--rule); }
.cl-sommaire { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 4px; }
.cl-sommaire .chip { font-size: var(--fs-sm); }
.stamp { font-size: var(--fs-label); color: var(--muted); border-top: 1px solid var(--rule); padding-top: 8px; margin: 14px 0 0; }
.card h3 a.anchor { color: inherit; text-decoration: none; }
.card h3 a.anchor:hover { text-decoration: underline; }
.bar .val { font-weight: 700; white-space: nowrap; min-width: 5ch; text-align: right; }
.diverge { display: grid; gap: 10px; }
.dv-row { display: grid; gap: 4px; font-size: var(--fs-sm); }
.dv-bars { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; height: 14px; }
.dv-bars .l { display: flex; justify-content: flex-end; background: var(--paper); border-radius: 3px 0 0 3px; }
.dv-bars .r { display: flex; background: var(--paper); border-radius: 0 3px 3px 0; }
.dv-bars .l span { background: var(--infl); }
.dv-bars .r span { background: var(--money); }
.dv-vals { display: flex; justify-content: space-between; color: var(--muted); font-size: var(--fs-sm); }
.legend { display: flex; gap: 14px; font-size: var(--fs-sm); color: var(--muted); margin: 0 0 10px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 5px; vertical-align: -1px; }
svg.line { width: 100%; height: auto; }

/* Votations */
.vote-day { margin: 0 0 26px; }
.vote-day h3 { border-top: 2px solid var(--ink); padding-top: 12px; }
.vote-row {
  display: grid; gap: 6px; width: 100%; text-align: left; font: inherit; color: inherit; cursor: pointer;
  background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius-s); padding: 12px 14px; margin: 0 0 8px;
}
.vote-row:hover { border-color: var(--ink); }
.vote-row .sub { color: var(--muted); font-size: var(--fs-sm); }
.vr-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.pill { display: inline-block; font-size: var(--fs-label); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: 3px 9px; white-space: nowrap; background: var(--paper); border: 1px solid var(--ink); }
.pill.yes { background: var(--infl); border-color: var(--infl); color: var(--card); }
.pill.no { background: var(--money); border-color: var(--money); color: var(--card); }
.yesno { position: relative; display: block; height: 10px; border-radius: 3px; background: var(--money-soft); overflow: hidden; }
.yesno span { display: block; height: 100%; background: var(--infl); }
.yesno::after { content: ""; position: absolute; left: 50%; top: -2px; bottom: -2px; border-left: 2px solid var(--ink); }
.cantons { display: grid; grid-template-columns: repeat(auto-fill, minmax(62px, 1fr)); gap: 4px; }
.ct { display: grid; border: 1px solid var(--rule); border-radius: var(--radius-s); padding: 5px 6px; background: var(--card); font-size: var(--fs-sm); line-height: 1.25; }
.ct b { font-size: var(--fs-sm); }
.sheet-panel h4 { margin: 14px 0 4px; font-size: 1rem; }
.legend.wrap-l { flex-wrap: wrap; row-gap: 4px; }
.legend b { color: var(--ink); }
.legend .vacant { border: 1px dashed var(--muted); }

/* Parlement : hémicycles et photos */
svg.hemi { width: 100%; height: auto; display: block; margin: 0 0 10px; }
svg.hemi .seat { cursor: pointer; }
svg.hemi .seat:hover { stroke: var(--ink); stroke-width: 1.2; }
svg.hemi .seat.dim { opacity: .18; }
.nowrap { white-space: nowrap; }
.mini-bar { display: inline-block; width: 60px; height: 8px; border-radius: 2px; background: var(--money-soft); vertical-align: middle; overflow: hidden; margin-right: 6px; }
.mini-bar span { display: block; height: 100%; background: var(--infl); }
.who { display: flex; align-items: center; gap: 10px; }
.avatar { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; object-position: top; flex: none; background: var(--paper); }
.elu-head { display: flex; gap: 16px; align-items: flex-start; }
.portrait { margin: 8px 0 0; flex: none; text-align: center; }
.portrait img { width: 84px; height: 84px; border-radius: 50%; object-fit: cover; object-position: top; display: block; background: var(--card); }
.portrait figcaption { font-size: var(--fs-label); color: var(--muted); margin-top: 3px; }

/* Débats */
.charte { background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius-s); padding: 10px 14px; margin: 0 0 18px; max-width: 70ch; }
.charte summary { cursor: pointer; font-weight: 700; }
.charte ul { margin: 10px 0 4px; padding-left: 18px; color: var(--muted); }
.hypo { display: grid; grid-template-columns: auto 1fr; gap: 14px; background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius-s); padding: 14px; margin: 0 0 10px; }
.votebox { display: grid; justify-items: center; align-content: start; gap: 2px; min-width: 40px; }
.vbtn { font: inherit; font-size: 1rem; width: 40px; height: 36px; border-radius: var(--radius-s); border: 1px solid var(--rule); background: var(--paper); color: var(--muted); cursor: pointer; }
.vbtn:hover { border-color: var(--ink); color: var(--ink); }
.vbtn.up[aria-pressed="true"] { background: var(--infl); border-color: var(--infl); color: var(--card); }
.vbtn.down[aria-pressed="true"] { background: var(--money); border-color: var(--money); color: var(--card); }
.vbtn:disabled { opacity: .5; cursor: wait; }
.votebox .score { font-size: var(--fs-h4); }
.hypo-body { min-width: 0; }
.hypo-body h3 { margin: 0 0 2px; }
.hypo .meta { color: var(--muted); font-size: var(--fs-sm); margin: 0 0 8px; }
.vmsg { color: var(--money); }
.texte { white-space: pre-line; overflow-wrap: anywhere; margin: 0 0 10px; }
.chips.chips { margin: 0 0 10px; }
.chip.ref { font-size: var(--fs-sm); padding: 3px 10px; text-align: left; }
.chip.ref small { color: var(--muted); font-weight: 700; text-transform: uppercase; font-size: var(--fs-label); letter-spacing: .04em; }
.chip .x { all: unset; cursor: pointer; margin-left: 4px; font-weight: 700; padding: 0 4px; }
.coms { margin-top: 8px; }
.fiche-debats .hypo { background: var(--paper); }
.form { display: grid; gap: 12px; margin: 10px 0; }
.form label { display: grid; gap: 4px; font-weight: 500; font-size: var(--fs-sm); }
.form input, .form textarea { font: inherit; padding: 9px 12px; border: 1px solid var(--rule); border-radius: var(--radius-s); background: var(--card); color: var(--ink); width: 100%; }
.form fieldset { border: 1px solid var(--rule); border-radius: var(--radius-s); padding: 10px 12px; margin: 0; display: grid; gap: 8px; }
.form legend { font-weight: 500; font-size: var(--fs-sm); padding: 0 4px; }
.form .btn { justify-self: start; }
.form-msg { margin: 0; color: var(--muted); min-height: 1.2em; }
.ref-res { display: grid; gap: 4px; }
.ref-hit { all: unset; cursor: pointer; padding: 6px 10px; border-radius: var(--radius-s); background: var(--card); border: 1px solid var(--rule); }
.ref-hit:hover, .ref-hit:focus-visible { border-color: var(--ink); }
.ref-hit small { color: var(--muted); font-weight: 700; margin-right: 4px; }
.ts-box { position: fixed; right: 16px; bottom: calc(env(safe-area-inset-bottom, 0px) + 16px); z-index: 40; }

/* Jouer et partager */
.promo { display: block; margin: 0 0 28px; padding: 14px 16px; border-radius: var(--radius-l); background: var(--infl-soft); color: var(--ink); text-decoration: none; border: 1px solid transparent; }
.promo:hover { border-color: var(--infl); }
.promo span { color: var(--ink); font-weight: 700; white-space: nowrap; }
.chip.on { background: var(--ink); color: var(--paper); border-color: var(--ink); }
a.chip { text-decoration: none; }
.game-card { display: grid; gap: 8px; align-content: start; color: inherit; text-decoration: none; }
.game-card:hover { border-color: var(--ink); }
.game-card .btn { justify-self: start; }
.quiz { max-width: 720px; }
.quiz h3 { font-size: var(--fs-h3); line-height: 1.3; }
.answers { display: flex; flex-wrap: wrap; gap: 10px; margin: 14px 0; align-items: center; }
.answers.col { display: grid; }
.answers.col .btn { text-align: left; }
.btn.yes { background: var(--yes); border-color: var(--yes); color: var(--card); }
.btn.no { background: var(--no); border-color: var(--no); color: var(--card); }
.btn.right { background: var(--yes); border-color: var(--yes); color: var(--card); }
.btn.wrong { background: var(--no); border-color: var(--no); color: var(--card); }
.btn:disabled { cursor: default; }
.share { margin-top: 12px; }
.progress { height: 6px; border-radius: 3px; background: var(--paper); overflow: hidden; }
.progress span { display: block; height: 100%; background: var(--infl); }
.grille { font-size: 2rem; letter-spacing: .1em; margin: 0 0 8px; }
.big { font-size: var(--fs-big); font-weight: 800; letter-spacing: -.045em; line-height: 1; margin: 6px 0; font-variant-numeric: proportional-nums; }
.pm { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.pm-item { background: var(--paper); border-radius: var(--radius-s); padding: 14px; }
.pm-item h3 { font-size: 1rem; }
.elu-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); gap: 12px; }
.elu-card-head { all: unset; cursor: pointer; display: flex; gap: 12px; align-items: center; }
.elu-card-head img { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; object-position: top; }
.elu-card-head:hover strong { text-decoration: underline; }
.kpis.small { gap: 14px; margin: 12px 0 4px; }
.kpis.small .kpi b { font-size: var(--fs-h4); }
@media (max-width: 640px) { .pm { grid-template-columns: 1fr; } }

/* À la une, traductions, listes longues */
.une { margin: 0 0 20px; }
.une-card { display: grid; gap: 6px; align-content: start; color: inherit; text-decoration: none; }
.une-card:hover { border-top-width: 3px; padding-top: 14px; }
.une-card h3 { font-size: var(--fs-h4); line-height: 1.25; margin: 0; letter-spacing: -.01em; }
.une-card .big { margin: 2px 0; }
.coa { display: inline-block; vertical-align: -.2em; margin-right: .3em; object-fit: contain; }
.card .elu-card-head img.coa, .elu-card-head img.coa, .who img.coa, .portrait img.coa { width: auto; height: 1.1em; min-width: 0; border-radius: 0; object-position: center; flex: none; }
.summary .coa, .filters .coa { vertical-align: middle; margin-right: .5em; }
.ct .coa { margin-right: 3px; vertical-align: -2px; }
.eyebrow-s { margin: 0 0 8px; font-size: var(--fs-label); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ink); display: flex; align-items: center; gap: 8px; }
.eyebrow-s::before { content: ""; display: inline-block; width: 10px; height: 10px; background: var(--money); flex: none; }
.go, a.link { color: var(--ink); font-weight: 700; margin-top: 6px; align-self: start; justify-self: start; text-decoration: none; border-bottom: 2px solid var(--money); }
.go:hover, a.link:hover { border-bottom-width: 3px; text-decoration: none; }
.podium { margin: 4px 0 0; padding: 0; list-style: none; counter-reset: r; }
.podium li { counter-increment: r; display: grid; grid-template-columns: 2ch 1fr auto; gap: 10px; align-items: baseline; padding: 6px 0; border-bottom: 1px solid var(--rule); }
.podium li::before { content: counter(r); font-weight: 800; color: var(--money); }
.podium li b { font-size: 1.25rem; font-weight: 800; letter-spacing: -.03em; }
.de-hint { display: block; font-size: var(--fs-label); font-weight: 400; color: var(--muted); font-style: italic; }
.ctx { display: block; font-size: var(--fs-label); color: var(--muted); font-weight: 400; margin-top: 2px; }
.abs-bar { display: flex; width: 90px; height: 7px; margin: 5px 0 0 auto; border-radius: 2px; background: var(--paper); overflow: hidden; }
.abs-bar .ne { background: var(--money); }
.abs-bar .ex { background: var(--excuse); }
@media (max-width: 640px) {
  #t-abs .avatar { display: none; }
  #t-abs th, #t-abs td { padding: 8px 5px; font-size: var(--fs-sm); }
  #t-abs .abs-bar { width: 56px; }
  #t-abs .ctx { font-size: var(--fs-label); }
  #t-abs th { white-space: normal; }
}
#t-abs caption { caption-side: bottom; text-align: left; padding: 8px 12px; }
details.more > summary { cursor: pointer; color: var(--ink); font-weight: 700; font-size: var(--fs-sm); padding: 10px 0; }
details.more[open] > summary { color: var(--muted); }

/* Réseaux */
.net-layout { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 14px; align-items: start; }
.net-wrap { position: relative; background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius-l); overflow: hidden; }
.net-tools { position: absolute; top: 8px; right: 8px; display: flex; gap: 4px; z-index: 1; }
.net-tools .btn { padding: 4px 10px; font-size: 1rem; background: var(--card); }
svg.net { width: 100%; height: 70vh; min-height: 420px; display: block; touch-action: none; cursor: grab; user-select: none; }
svg.net:active { cursor: grabbing; }
svg.net line { stroke-linecap: round; vector-effect: non-scaling-stroke; transition: opacity .15s; }
svg.net .l-paid { stroke: var(--money); stroke-width: 1.6; opacity: .65; }
svg.net .l-free { stroke: var(--muted); stroke-width: .8; opacity: .3; }
svg.net .l-badge { stroke: var(--infl); stroke-width: 1.5; stroke-dasharray: 4 3; }
svg.net line.hl { opacity: 1; stroke-width: 2.2; }
svg.net .node { cursor: pointer; transition: opacity .15s; }
svg.net .node circle { stroke: var(--card); stroke-width: 1.2; vector-effect: non-scaling-stroke; }
svg.net .node.org circle { fill: var(--card); stroke: var(--muted); }
svg.net .node.center circle { stroke: var(--ink); stroke-width: 3; }
svg.net .node:hover circle, svg.net .node:focus-visible circle, svg.net .node.hl circle { stroke: var(--ink); stroke-width: 2; }
svg.net text { display: none; font-size: calc(9px / var(--k)); fill: var(--ink); text-anchor: middle; pointer-events: none; paint-order: stroke; stroke: var(--card); stroke-width: calc(3px / var(--k)); }
svg.net .node.org text { font-weight: 700; }
svg.net .lvl1 text, svg.net[data-z="2"] .lvl2 text, svg.net[data-z="3"] text, svg.net .node.hl text { display: block; }
svg.net.sel .dim { opacity: .07; }
svg.net.sel .dim text { display: none; }
.net-side { background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius-l); padding: 12px 14px; max-height: 70vh; overflow-y: auto; }
.net-side h4 { margin: 4px 0 2px; }
.net-side .list li { padding: 6px 0; }
.net-side button.link { text-align: left; }
label.check { display: inline-flex; align-items: center; gap: 6px; font-size: 1rem; }
.legend .dash { background: none; border-top: 2px dashed var(--infl); height: 0; margin-bottom: 3px; }
.legend .org-dot { background: var(--card); border: 1px solid var(--muted); border-radius: 50%; }
.net-card { margin-top: 12px; }
@media (max-width: 800px) { .net-layout { grid-template-columns: 1fr; } svg.net { height: 60vh; min-height: 340px; } .net-side { max-height: none; } }

/* Nouveautés */
.week { border-top: 2px solid var(--ink); padding: 14px 0 24px; }
.week h3 { font-size: var(--fs-h4); }
.week ul { margin: 0; padding-left: 18px; }
.week li { margin: 4px 0; }

/* Fiche détail */
.sheet { position: fixed; inset: 0; z-index: 30; }
.sheet-back { position: absolute; inset: 0; background: rgba(10, 15, 20, .45); }
.sheet-panel {
  position: absolute; right: 0; top: 0; bottom: 0; width: min(640px, 100%); overflow-y: auto;
  background: var(--card); padding: calc(env(safe-area-inset-top, 0px) + 20px) 22px calc(env(safe-area-inset-bottom, 0px) + 28px);
  box-shadow: -8px 0 30px rgba(0, 0, 0, .18);
}
.sheet-panel h2 { margin: 8px 0 4px; padding-right: 40px; }
.close { position: absolute; top: calc(env(safe-area-inset-top, 0px) + 10px); right: 12px; font-family: inherit; font-size: 2rem; font-weight: 700; line-height: 1; min-width: 44px; min-height: 44px; border: 0; background: none; color: var(--ink); cursor: pointer; padding: 6px 10px; }
.kpis { display: flex; flex-wrap: wrap; gap: 18px; margin: 16px 0 22px; }
.kpi b { display: block; font-size: 1.6rem; font-weight: 800; letter-spacing: -.04em; line-height: 1.1; }
.kpi span { color: var(--muted); font-size: var(--fs-sm); }
.sheet-panel section { margin: 0 0 24px; }
.sheet-nav { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 16px; margin: -8px 0 20px; padding: 8px 0; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--rule); font-size: 1rem; }
.sheet-nav a { color: var(--ink); font-weight: 700; text-decoration: none; border-bottom: 2px solid transparent; }
.sheet-nav a:hover { border-bottom-color: var(--money); }
.sheet-nav .share { margin: 0 0 0 auto; padding: 5px 12px; font-size: var(--fs-sm); }
.sheet-panel section > h3 { font-size: var(--fs-label); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ink); border-top: 1px solid var(--ink); padding-top: 8px; margin: 0 0 10px; }
.sheet-panel h2 { letter-spacing: -.03em; }
.fiche-debats .hypo { background: var(--paper); }
.list { list-style: none; margin: 0; padding: 0; }
.list li { padding: 9px 0; border-bottom: 1px solid var(--rule); display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; }
.list li .sub { grid-column: 1 / -1; color: var(--muted); font-size: var(--fs-sm); }
button.link { font: inherit; font-weight: 600; background: none; border: 0; padding: 0; cursor: pointer; text-align: left; }
button.link:focus-visible { outline: 3px solid var(--focus); }

.foot { color: var(--muted); font-size: var(--fs-sm); padding-top: 32px; padding-bottom: 40px; border-top: 1px solid var(--rule); margin-top: 56px; }
.foot p { max-width: 90ch; }
.warn { color: var(--money); font-weight: 500; }

@media (max-width: 640px) {
  .top-inner { gap: 10px; }
  .tabs a.sec { display: none; }
  .hero { margin-bottom: 14px; }
  .lede { display: none; }
  .brand { font-size: 1rem; }
  .eyebrow { margin-top: 28px; }
  th, td { padding: 8px 9px; }
  .hide-s { display: none; }
}
@media (prefers-reduced-motion: no-preference) {
  .sheet-panel { animation: slide .18s ease-out; }
  @keyframes slide { from { transform: translateX(24px); opacity: .6; } }
}

/* Dossiers (sujets qui fâchent) : en fin de fichier pour passer après .hero, .lede et .une */
.dos-hero { max-width: 22ch; }
.dos-hero a { color: inherit; text-decoration: none; }
.dos-hero a:hover { text-decoration: underline; text-decoration-color: var(--money); text-decoration-thickness: 4px; }
.dos-lede { font-size: var(--fs-h4); max-width: 62ch; margin: 0 0 22px; }
.dos-lede .go { display: inline-block; margin-left: 4px; }
.dos-grid { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); margin: 0 0 32px; }

#tab-dossier .card { margin: 0 0 20px; }
#tab-dossier .answers { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 0 0 28px; }
.dos-votes { display: grid; gap: 10px; }
@media (max-width: 640px) {
  .dos-lede { font-size: 1rem; }
  .dos-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .dos-grid .big { font-size: 1.6rem; }
}
.sheet-panel p.hint { color: var(--muted); font-size: var(--fs-sm); margin: 0 0 10px; }
a.btn, a.chip, a.card { text-decoration: none; }  /* encadré = action : pas de soulignement en plus */
/* Actualité en tête d'un dossier (date, fait sourcé, conseil pratique) */
.actu { margin: 0 0 14px; padding: 8px 0 8px 14px; border-left: 4px solid var(--money); font-size: var(--fs-sm); max-width: 70ch; }
.actu span { color: var(--muted); }
.dos-hero .money { color: var(--money); }
/* Hémicycles des dossiers et commissions, unités des tuiles, chiffres de crédibilité */
.hemis-duo { display: grid; grid-template-columns: 2fr 1fr; gap: 12px 24px; align-items: end; margin: 6px 0 8px; }
.hemis-duo.solo { grid-template-columns: minmax(0, 480px); }
.hemis-duo .hint { margin-top: 0; }
svg.units { width: 100%; height: auto; display: block; margin: 8px 0 0; }
.units-lbl { color: var(--muted); font-size: var(--fs-label); }
.credo { font-size: var(--fs-sm); color: var(--muted); margin: -8px 0 22px; }
.credo b { color: var(--ink); }
.who > span { display: inline; }
@media (max-width: 640px) { .hemis-duo { grid-template-columns: 1fr; } }
.card p.hint + p.note { font-size: var(--fs-sm); margin: -4px 0 10px; }

/* Bandeau en tête des dossiers et commissions (pleine largeur, sans débordement horizontal) */
.dos-band { background: var(--band); color: #fff; box-shadow: 0 0 0 100vmax var(--band); clip-path: inset(0 -100vmax); padding: 4px 0 22px; margin: 28px 0 0; }
.dos-band .eyebrow { color: #fff; margin-top: 18px; }
.dos-band .eyebrow::before { background: #fff; }
.dos-band .hero { color: #fff; }
.dos-band .dos-lede, .dos-band .actu { color: #fff; }
.dos-band .actu { border-left-color: #fff; }
.dos-band .actu span { color: rgba(255, 255, 255, .85); }
.dos-band a { color: #fff; text-decoration-color: rgba(255, 255, 255, .7); }
.dos-band .btn.ghost { color: #fff; border-color: #fff; }
.dos-band .btn.ghost:hover { background: rgba(255, 255, 255, .12); }
.dos-band a.link, .dos-band .go { color: #fff; border-bottom-color: #fff; }
.dos-band .answers { margin-bottom: 0; }
/* Onglets du dossier, collés sous l'en-tête */
.dos-tabs { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 57px); z-index: 5; display: flex; gap: 22px; overflow-x: auto; scrollbar-width: none; margin: 0 0 20px; padding: 10px 0 0; background: var(--paper); border-bottom: 1px solid var(--ink); box-shadow: 0 0 0 100vmax var(--paper); clip-path: inset(0 -100vmax); }
.dos-tabs a { flex: none; font-weight: 700; color: var(--muted); text-decoration: none; padding: 2px 0 8px; border-bottom: 3px solid transparent; }
.dos-tabs a:hover, .dos-tabs a.on { color: var(--ink); }
.dos-tabs a.on { border-bottom-color: var(--money); }
#tab-dossier section[id] { scroll-margin-top: 120px; }
/* Recherche par NPA */
.npa-pick input { font: inherit; font-size: 1.05rem; font-weight: 700; padding: 10px 14px; border: 2px solid var(--ink); background: var(--card); color: var(--ink); width: min(100%, 300px); }
.conf-filters .or { color: var(--muted); font-size: var(--fs-sm); }
.npa-res { flex-basis: 100%; margin: 0; }
.npa-res:empty { display: none; }
.npa-res .chip small { color: var(--muted); font-weight: 700; margin-left: 2px; }
.npa-res .chip { background: var(--card); color: var(--ink); font-size: var(--fs-sm); font-weight: 600; padding: 6px 12px; }
