:root {
  --ink: #061b3e;
  --muted: #506173;
  --line: #aab2bd;
  --paper: #fbf7f0;
  --paper-soft: #fbf7f0;
  --blue: #001f4c;
  --red: #d12630;
  --green: #0b8c53;
  --lime: #86bd19;
  --gold: #e5b51b;
  --orange: #e96122;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(255,255,255,.78), transparent 28rem),
    linear-gradient(135deg, #eee7dc 0%, #fbf8f2 48%, #e9dfd2 100%);
  font-family: Georgia, "Times New Roman", serif;
}

a {
  color: #0f4f86;
  text-underline-offset: 2px;
}

.page-shell {
  width: min(1120px, calc(100% - 32px));
  margin: 16px auto;
}

.site-frame {
  position: relative;
  overflow: hidden;
  border: 2px solid #78899c;
  border-radius: 8px;
  background: var(--paper);
  box-shadow: 0 14px 34px rgba(18, 28, 46, .15);
}

.site-frame::before {
  content: "";
  position: absolute;
  inset: 6px;
  z-index: 5;
  pointer-events: none;
  border: 1px solid #c8c0b4;
  border-radius: 6px;
}

.masthead {
  position: relative;
  z-index: 1;
  min-height: 96px;
  padding: 14px 28px 12px;
  display: grid;
  grid-template-columns: 190px 1fr 190px;
  align-items: center;
  border-bottom: 1px solid var(--line);
}

.brand-link {
  justify-self: start;
  display: inline-flex;
}

.brand-link,
.title-block {
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  width: 74px;
  height: auto;
}

.title-block {
  justify-self: center;
  text-align: center;
}

.site-title {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: .22em;
  font-size: clamp(1.35rem, 2.1vw, 2.05rem);
  font-weight: 400;
}

.tricolor-rule {
  display: flex;
  justify-content: center;
  gap: 46px;
  margin-top: 10px;
}

.tricolor-rule span {
  width: 58px;
  height: 3px;
  background: var(--blue);
}

.tricolor-rule span:last-child {
  background: var(--red);
}

.initiative {
  justify-self: end;
  margin: 0;
  text-align: right;
  text-transform: uppercase;
  font-size: .78rem;
  font-weight: 700;
  white-space: nowrap;
}

.menu-button {
  display: none;
}

.primary-nav {
  --indicator-left: 0px;
  --indicator-width: 0px;
  position: relative;
  z-index: 1;
  height: 40px;
  display: flex;
  justify-content: center;
  gap: 64px;
  align-items: center;
  border-bottom: 1px solid var(--line);
  text-transform: uppercase;
  font-size: .78rem;
  font-weight: 700;
}

.primary-nav::after {
  content: "";
  position: absolute;
  bottom: 6px;
  left: var(--indicator-left);
  width: var(--indicator-width);
  height: 3px;
  background: var(--ink);
  opacity: 0;
  transition: left .22s ease, width .22s ease, opacity .16s ease;
}

.primary-nav.nav-ready::after {
  opacity: 1;
}

.primary-nav a {
  position: relative;
  height: 100%;
  display: inline-flex;
  align-items: center;
  color: var(--ink);
  text-decoration: none;
}

.primary-nav .active {
  border-bottom: 0;
}

.primary-nav .active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 6px;
  height: 3px;
  background: var(--ink);
}

.primary-nav.nav-ready .active::after {
  display: none;
}

.hero {
  position: relative;
  z-index: 1;
  min-height: 275px;
  display: block;
  padding: 36px 34px 26px;
  background: var(--paper);
}

.palais,
.laurel {
  position: absolute;
  z-index: 0;
  max-width: 100%;
  opacity: 1;
}

.palais {
  left: 34px;
  top: 34px;
  bottom: auto;
  width: 250px;
}

.hero > .palais {
  top: 34px;
  bottom: auto;
}

.laurel {
  right: 48px;
  top: 34px;
  width: 180px;
}

.hero-copy {
  position: relative;
  z-index: 1;
  text-align: center;
}

h1 {
  margin: 0 auto;
  max-width: 760px;
  font-size: clamp(2.35rem, 3.2vw, 3.15rem);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: 0;
}

h1 span {
  display: block;
  white-space: nowrap;
}

.ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin: 20px auto 14px;
}

.ornament::before,
.ornament::after {
  content: "";
  width: 72px;
  height: 1px;
  background: #557085;
}

.ornament span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ink);
  box-shadow: 13px 0 0 -2px var(--ink), -13px 0 0 -2px var(--ink);
}

.hero-copy p {
  max-width: 620px;
  margin: 0 auto;
  font-family: Arial, Helvetica, sans-serif;
  font-size: .92rem;
  line-height: 1.5;
  font-weight: 600;
}

.content-hero {
  position: relative;
  z-index: 1;
  min-height: 235px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 34px 34px 28px;
  background: var(--paper);
}

.content-hero .hero-copy {
  margin-top: 38px;
}

.content-hero .hero-copy p {
  max-width: 610px;
}

.about-hero .hero-copy p {
  max-width: 850px;
  line-height: 1.48;
  text-align: justify;
}

.about-hero .hero-copy p + p {
  margin-top: 10px;
}

.ranking {
  position: relative;
  z-index: 1;
  padding: 0 34px 14px;
}

.section-heading {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 18px;
  margin-bottom: 14px;
}

.section-heading::after {
  content: "";
  height: 1px;
  background: var(--line);
}

.section-heading h2,
.info-grid h2 {
  margin: 0;
  text-transform: uppercase;
  font-size: 1.08rem;
  font-weight: 400;
  letter-spacing: .045em;
}

.section-heading span {
  order: 3;
  font-family: Arial, Helvetica, sans-serif;
  color: var(--muted);
  font-size: .78rem;
}

.ranking-table {
  border: 1px solid #c1c6cb;
  border-radius: 8px;
  overflow: hidden;
  background: rgba(255,255,255,.32);
}

/* Masquer les lignes de données tant que les résultats ne sont pas chargés */
.ranking-table.sn-loading [data-audit-url] {
  display: none;
}

.table-row {
  display: grid;
  grid-template-columns: 70px 2.35fr 1.45fr 2.2fr 118px 102px 115px 132px;
  align-items: center;
  min-height: 48px;
  border-bottom: 1px solid #d2d4d5;
  text-align: center;
}

.table-row:last-child {
  border-bottom: 0;
}

.table-row > * {
  min-width: 0;
  padding: 0 14px;
  border-right: 1px solid #d2d4d5;
  font-size: .88rem;
}

.table-row > *:last-child {
  border-right: 0;
  display: flex;
  justify-content: center;
}

.table-head {
  min-height: 34px;
  color: #fff;
  background: #001d45;
  text-transform: uppercase;
  font-size: .78rem;
  font-weight: 400;
  letter-spacing: .04em;
}

.table-head span {
  text-align: center;
}

.rank {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  font-weight: 700;
}

.candidate {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  text-align: left;
}

.party-link {
  color: inherit;
  font-weight: inherit;
  text-decoration: none;
}

.candidate img,
.candidate-card img {
  width: 38px;
  height: 38px;
  flex: none;
  object-fit: cover;
  border-radius: 50%;
}

.score {
  display: block;
  text-align: center;
  font-size: 2rem;
  line-height: 1;
  font-weight: 700;
  text-decoration: none;
}

.score:hover,
.score:focus-visible {
  text-decoration: underline;
}

.reseau a {
  text-decoration: none;
}

.reseau a:hover,
.reseau a:focus-visible {
  text-decoration: underline;
}

.score-excellent { color: var(--green); }
.score-good { color: var(--lime); }
.score-average { color: var(--gold); }
.score-low { color: var(--orange); }
.score-very-low { color: var(--red); }
.score-pending { color: var(--muted); }

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 86px;
  min-height: 24px;
  padding: 4px 9px;
  border-radius: 3px;
  color: #fff;
  font-family: Arial, Helvetica, sans-serif;
  font-size: .68rem;
  font-style: normal;
  font-weight: 800;
  text-transform: uppercase;
}

.excellent { background: var(--green); }
.good { background: var(--lime); color: #06200e; }
.average { background: #f3b10d; color: #2b1e00; }
.low { background: var(--orange); }
.very-low { background: var(--red); }
.pending { background: #6d7885; }

.mobile-list {
  display: none;
}

.note {
  margin: 12px 48px 0;
  font-family: Arial, Helvetica, sans-serif;
  font-size: .72rem;
  color: var(--muted);
}

/* Statut et date d'analyse : masqués quand vides, pas d'espace résiduel */
.sn-status,
.sn-last-run {
  font-family: Arial, Helvetica, sans-serif;
  font-size: .82rem;
  color: var(--muted);
  margin: 0 0 8px;
}

.sn-status:empty,
.sn-last-run:empty {
  display: none;
  margin: 0;
}

.info-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.15fr .95fr;
  margin: 2px 34px 18px;
  border: 1px solid #c4c6c5;
  border-radius: 8px;
  overflow: hidden;
}

.method-card,
.privacy-card {
  padding: 18px 20px;
}

.method-card {
  border-right: 1px solid #c4c6c5;
}

.card-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 6px;
}

.icon-column {
  width: 31px;
  height: 31px;
  border: 3px solid var(--blue);
  border-top-width: 7px;
  position: relative;
}

.icon-column::before,
.icon-column::after {
  content: "";
  position: absolute;
  inset: 5px auto 4px 7px;
  width: 3px;
  background: var(--blue);
  box-shadow: 8px 0 0 var(--blue);
}

.shield {
  display: inline-flex;
  width: 35px;
  height: 42px;
  flex: none;
  border-radius: 18px 18px 22px 22px;
  background: #0a2a61;
  position: relative;
}

.shield::after {
  content: "✓";
  color: #fff;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 1.35rem;
  font-weight: 800;
  margin: auto;
}

.method-card > p,
.privacy-card > p,
.pillars p,
.info-grid a,
.privacy-card li,
.mobile-privacy p {
  font-family: Arial, Helvetica, sans-serif;
}

.method-card > p,
.privacy-card > p {
  margin: 0 0 16px 42px;
  font-size: .82rem;
  font-weight: 700;
}

.method-card > p.method-copy {
  font-weight: 400;
}

.pillars {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin: 0 0 18px;
}

.pillars div {
  min-width: 0;
}

.pillar-icon {
  display: block;
  width: 28px;
  height: 28px;
  margin-bottom: 7px;
  fill: none;
  stroke: #1c466e;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.pillars strong {
  display: block;
  font-size: .82rem;
}

.pillars p,
.privacy-card li,
.info-grid a {
  font-size: .76rem;
  line-height: 1.45;
}

.privacy-card ul {
  margin: 8px 0 10px 18px;
  padding: 0;
  list-style: "✓  ";
}

.privacy-card li::marker {
  color: #0c8a54;
  font-weight: 700;
}

.method-button,
.mobile-privacy {
  display: none;
}

.methodology-page {
  position: relative;
  z-index: 1;
  padding: 0 34px 28px;
}

.placeholder-panel {
  margin-bottom: 18px;
  padding: 22px 26px;
  border: 1px solid #c4c6c5;
  border-radius: 8px;
  background: rgba(255,255,255,.3);
}

.placeholder-panel h2 {
  margin: 0 0 10px;
  text-transform: uppercase;
  font-size: 1.2rem;
}

.placeholder-panel p,
.methodology-pillars p,
.back-link {
  font-family: Arial, Helvetica, sans-serif;
}

.placeholder-panel p {
  max-width: 840px;
  margin: 0 0 10px;
  font-size: .94rem;
  line-height: 1.6;
  font-weight: 600;
}

.placeholder-panel p:last-child {
  margin-bottom: 0;
}

.about-panel p {
  font-weight: 400;
}

.placeholder-panel hr {
  margin: 22px 0;
  border: 0;
  border-top: 1px solid #c4c6c5;
}

.methodology-pillars {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 20px;
}

.about-pillars {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.methodology-pillars article {
  padding: 18px 16px;
  border: 1px solid #c4c6c5;
  border-radius: 8px;
  background: rgba(255,255,255,.25);
}

.methodology-pillars h3 {
  margin: 0 0 8px;
  font-size: .98rem;
  line-height: 1.15;
}

.methodology-pillars p {
  margin: 0;
  font-size: .78rem;
  line-height: 1.48;
}

.methodology-content {
  margin: 0 0 22px;
  padding: 28px 34px;
  border: 1px solid #c4c6c5;
  border-radius: 8px;
  background: rgba(255,255,255,.28);
}

.methodology-content h2 {
  margin: 30px 0 12px;
  color: var(--ink);
  font-size: 1.28rem;
  font-weight: 400;
  line-height: 1.2;
}

.methodology-content h2:first-child {
  margin-top: 0;
}

.methodology-content p,
.methodology-content li,
.weighting-row p,
.weighting-row span,
.weighting-row strong {
  font-family: Arial, Helvetica, sans-serif;
}

.methodology-content p {
  margin: 0 0 13px;
  color: #142a4f;
  font-size: .96rem;
  line-height: 1.68;
}

.methodology-content ul {
  margin: 0 0 18px 22px;
  padding: 0;
}

.methodology-content li {
  margin-bottom: 7px;
  color: #142a4f;
  font-size: .94rem;
  line-height: 1.55;
}

.weighting-table {
  display: grid;
  margin: 18px 0 22px;
  border: 1px solid #b8c0c8;
  border-radius: 8px;
  overflow: hidden;
  background: rgba(255,255,255,.42);
}

.weighting-row {
  display: grid;
  grid-template-columns: minmax(160px, .9fr) 120px minmax(260px, 2.4fr);
  border-top: 1px solid #cfd3d7;
}

.weighting-row:first-child {
  border-top: 0;
}

.weighting-row > * {
  margin: 0;
  padding: 13px 14px;
  border-left: 1px solid #cfd3d7;
  color: #142a4f;
  font-size: .88rem;
  line-height: 1.5;
}

.weighting-row > *:first-child {
  border-left: 0;
}

.weighting-head {
  color: #fff;
  background: var(--blue);
}

.weighting-head span {
  color: #fff;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.weighting-row strong {
  font-weight: 800;
}

.weighting-row > span {
  font-weight: 800;
  text-align: center;
}

.back-link {
  display: inline-flex;
  margin-top: 2px;
  font-size: .88rem;
  font-weight: 700;
}

.footer {
  position: relative;
  z-index: 1;
  min-height: 92px;
  display: grid;
  grid-template-columns: 1fr 1.15fr 1fr;
  align-items: center;
  border-top: 2px solid #78899c;
  padding: 14px 52px;
}

.footer > * {
  min-height: 66px;
  display: flex;
  align-items: center;
}

.footer-brand {
  gap: 18px;
}

.footer-brand img {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: 50%;
}

.footer-brand p,
.contact a {
  margin: 0;
  font-size: .9rem;
}

blockquote {
  margin: 0;
  flex-direction: column;
  justify-content: center;
  gap: 7px;
  text-align: center;
  border-left: 1px solid #d3d0c8;
  border-right: 1px solid #d3d0c8;
  font-size: 1.05rem;
  font-style: italic;
  font-weight: 700;
}

cite {
  display: block;
  max-width: 260px;
  margin-top: 0;
  font-size: .82rem;
  font-style: normal;
  font-weight: 400;
  line-height: 1.25;
}

.contact {
  flex-direction: column;
  justify-content: center;
  gap: 10px;
  text-transform: uppercase;
}

.contact a {
  text-transform: none;
}

.contact-link {
  display: inline-flex;
  align-items: center;
  gap: 9px;
}

.contact-link svg {
  width: 18px;
  height: 14px;
  fill: none;
  stroke: var(--ink);
  stroke-width: 1.8;
}

@media (max-width: 760px) {
  body {
    background: #f3eee6;
  }

  .page-shell {
    width: min(340px, calc(100% - 20px));
    margin: 12px auto;
  }

  .site-frame {
    border: 7px solid #001f4c;
    border-radius: 30px;
    box-shadow: 0 10px 28px rgba(17, 24, 39, .18);
  }

  .site-frame::before {
    display: none;
  }

  .masthead {
    min-height: 74px;
    grid-template-columns: 48px 1fr 36px;
    padding: 10px 18px 8px;
  }

  .brand-mark {
    width: 44px;
  }

  .site-title {
    font-size: .92rem;
    letter-spacing: .16em;
    white-space: nowrap;
  }

  .tricolor-rule {
    gap: 34px;
    margin-top: 7px;
  }

  .tricolor-rule span {
    width: 38px;
    height: 2px;
  }

  .initiative,
  .palais,
  .laurel,
  .note,
  .footer blockquote {
    display: none;
  }

  /* ── Tableau responsive : transformation en cartes ── */
  .ranking-table {
    border: none;
    background: transparent;
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  /* Masquer l'en-tête du tableau sur mobile */
  /* !important nécessaire : .ranking-table .table-row { display: grid } vient après
     et a la même spécificité — sans !important il écrase le display:none */
  .ranking-table .table-head {
    display: none !important;
  }

  /* Chaque ligne devient une carte */
  .ranking-table .table-row {
    display: grid;
    grid-template-columns: 32px 44px 1fr auto;
    grid-template-rows: auto auto auto;
    column-gap: 10px;
    row-gap: 0;
    align-items: start;
    padding: 10px 12px;
    border: 1px solid #d2d4d5;
    border-radius: 8px;
    background: rgba(255,255,255,.45);
    min-height: auto;
    border-bottom: 1px solid #d2d4d5;
  }

  /* Rang : colonne 1, couvre les 2 premières lignes */
  .ranking-table .table-row .rank {
    grid-column: 1;
    grid-row: 1 / 3;
    font-size: 1.25rem;
    padding: 0;
    border-right: none;
    align-self: center;
    justify-content: center;
  }

  /* Photo candidat : colonne 2, couvre les 2 premières lignes */
  .ranking-table .table-row .candidate {
    grid-column: 2;
    grid-row: 1 / 3;
    padding: 0;
    border-right: none;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    font-size: .62rem;
    text-align: center;
    line-height: 1.2;
    font-weight: 700;
    align-self: center;
  }

  .ranking-table .table-row .candidate img {
    width: 38px;
    height: 38px;
  }

  /* Nom du parti : colonne 3, ligne 1 */
  .ranking-table .table-row .party-link {
    grid-column: 3;
    grid-row: 1 / 3;
    padding: 0;
    border-right: none;
    font-size: .78rem;
    font-weight: 700;
    line-height: 1.2;
    align-self: center;
    color: #0f4f86;
    text-decoration: underline;
  }

  /* Lien site officiel : colonne 3, ligne 2 */
  .ranking-table .table-row > a:nth-child(4) {
    display: none;
  }

  /* Note / score : colonne 4, ligne 1 */
  .ranking-table .table-row .score {
    grid-column: 4;
    grid-row: 1;
    padding: 0;
    border-right: none;
    font-size: 1.8rem;
    text-align: center;
    align-self: end;
    line-height: 1;
  }

  /* Badge appréciation : colonne 4, ligne 2 */
  .ranking-table .table-row > span:last-child {
    grid-column: 4;
    grid-row: 2;
    padding: 0;
    border-right: none;
    justify-content: center;
    align-self: start;
    margin-top: 8px;
  }

  /* Indicateurs complémentaires : ligne explicite en bas de la carte */
  .ranking-table .table-row .paiement,
  .ranking-table .table-row .reseau {
    grid-row: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 10px;
    padding: 6px 8px;
    border: 1px solid #d2d4d5;
    border-radius: 6px;
    background: rgba(255,255,255,.45);
    font-size: .9rem;
    line-height: 1;
  }

  .ranking-table .table-row .paiement {
    grid-column: 1 / 5;
    width: 43%;
    justify-self: start;
  }

  .ranking-table .table-row .reseau {
    grid-column: 1 / 5;
    width: 56%;
    justify-self: end;
  }

  .ranking-table .table-row .paiement::before,
  .ranking-table .table-row .reseau::before {
    color: #001d45;
    font-family: Arial, Helvetica, sans-serif;
    font-size: .68rem;
    font-weight: 700;
    text-transform: uppercase;
  }

  .ranking-table .table-row .paiement::before {
    content: "Paiement";
  }

  .ranking-table .table-row .reseau::before {
    content: "Réseaux sociaux";
  }

  .ranking-table .table-row > *:last-child {
    border-right: 0;
  }

  .ranking-table .table-row > * {
    border-right: none;
  }

  /* ── info-grid : empilé en colonne sur mobile ── */
  .info-grid {
    display: flex;
    flex-direction: column;
    margin: 2px 14px 14px;
  }

  .method-card {
    border-right: none;
    border-bottom: 1px solid #c4c6c5;
  }

  .pillars {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .method-card > p,
  .privacy-card > p {
    margin-left: 0;
  }

  .menu-button {
    display: inline-flex;
    width: 30px;
    height: 30px;
    padding: 0;
    border: 0;
    background: transparent;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
  }

  .menu-button span {
    height: 3px;
    width: 28px;
    background: var(--blue);
    transition: transform .18s ease, opacity .18s ease;
  }

  .site-frame.nav-open .menu-button span:first-child {
    transform: translateY(8px) rotate(45deg);
  }

  .site-frame.nav-open .menu-button span:nth-child(2) {
    opacity: 0;
  }

  .site-frame.nav-open .menu-button span:last-child {
    transform: translateY(-8px) rotate(-45deg);
  }

  .primary-nav {
    display: none;
    height: auto;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 18px 12px;
    border-bottom: 1px solid var(--line);
    background: var(--paper);
    font-size: .78rem;
  }

  .site-frame.nav-open .primary-nav {
    display: flex;
  }

  .primary-nav::after,
  .primary-nav .active::after {
    display: none;
  }

  .primary-nav a {
    min-height: 42px;
    height: auto;
    justify-content: center;
    border-top: 1px solid rgba(120, 137, 156, .35);
  }

  .primary-nav a:first-child {
    border-top: 0;
  }

  .hero {
    min-height: auto;
    display: block;
    padding: 20px 22px 20px;
  }

  .content-hero {
    min-height: auto;
    padding: 24px 22px 22px;
  }

  .content-hero .hero-copy {
    margin-top: 0;
  }

  h1 {
    max-width: 280px;
    font-size: 1.63rem;
    line-height: 1.12;
  }

  h1 span {
    white-space: normal;
  }

  .ornament {
    display: none;
  }

  .hero-copy p {
    max-width: 270px;
    margin-top: 18px;
    font-size: .82rem;
    line-height: 1.48;
  }

  .ranking {
    padding: 0 14px 10px;
  }

  .methodology-page {
    padding: 0 14px 18px;
  }

  .section-heading {
    display: block;
    margin-bottom: 10px;
  }

  .section-heading h2 {
    font-size: .9rem;
    line-height: 1.3;
  }

  .section-heading span {
    display: block;
    margin-top: 4px;
    font-size: .72rem;
  }

  .mobile-list {
    display: grid;
    gap: 7px;
  }

  .candidate-card {
    min-height: 66px;
    display: grid;
    grid-template-columns: 24px 42px minmax(0, 1fr) 50px;
    grid-template-rows: 1fr auto;
    column-gap: 8px;
    align-items: center;
    padding: 7px 8px;
    border: 1px solid #d2d4d5;
    border-radius: 6px;
    background: rgba(255,255,255,.35);
  }

  .candidate-card .rank {
    grid-row: 1 / 3;
    font-size: 1.15rem;
  }

  .candidate-card img {
    grid-row: 1 / 3;
    width: 40px;
    height: 40px;
  }

  .candidate-card h3,
  .candidate-card p {
    margin: 0;
  }

  .candidate-card h3 {
    font-size: .93rem;
    line-height: 1.15;
  }

  .candidate-card p,
  .candidate-card a {
    font-family: Arial, Helvetica, sans-serif;
    font-size: .62rem;
    line-height: 1.25;
  }

  .candidate-card .score {
    grid-column: 4;
    font-size: 1.72rem;
    align-self: end;
  }

  .candidate-card .badge {
    grid-column: 4;
    min-width: 48px;
    min-height: 18px;
    padding: 3px 5px;
    font-size: .48rem;
    justify-self: end;
    align-self: start;
  }

  .placeholder-panel {
    padding: 16px 14px;
  }

  .placeholder-panel h2 {
    font-size: 1rem;
  }

  .placeholder-panel p {
    font-size: .82rem;
    line-height: 1.5;
  }

  .methodology-content {
    padding: 18px 14px;
  }

  .methodology-content h2 {
    margin-top: 24px;
    font-size: 1.05rem;
  }

  .methodology-content p,
  .methodology-content li {
    font-size: .84rem;
    line-height: 1.55;
  }

  .weighting-table {
    display: grid;
    gap: 10px;
    border: 0;
    border-radius: 0;
    overflow: visible;
    background: transparent;
  }

  .weighting-row {
    min-width: 0;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px 12px;
    border: 1px solid #cfd3d7;
    border-radius: 8px;
    padding: 14px;
    background: rgba(255,255,255,.44);
  }

  .weighting-head {
    display: none;
  }

  .weighting-row > * {
    border-left: 0;
    padding: 0;
    font-size: .82rem;
  }

  .weighting-row strong {
    grid-column: 1;
    align-self: center;
    font-size: .92rem;
    line-height: 1.25;
  }

  .weighting-row > span {
    grid-column: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    align-self: center;
    justify-self: end;
    min-width: 62px;
    min-height: 32px;
    padding: 5px 8px;
    border: 1px solid rgba(0, 31, 76, .18);
    border-radius: 999px;
    color: #fff;
    background: var(--blue);
    font-size: .82rem;
    line-height: 1;
    text-align: center;
    white-space: nowrap;
  }

  .weighting-row > span::before {
    content: attr(data-label);
    font-size: .58rem;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
    opacity: .82;
  }

  .weighting-row p {
    grid-column: 1 / -1;
    padding-top: 8px;
    border-top: 1px solid #d8d9da;
    font-size: .84rem;
    line-height: 1.55;
  }

  .methodology-pillars {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .methodology-pillars article {
    padding: 14px;
  }

  .method-button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 2px 14px 10px;
    padding: 11px 16px;
    border-radius: 5px;
    color: #fff;
    background: #001f4c;
    font-family: Arial, Helvetica, sans-serif;
    font-weight: 800;
    text-decoration: none;
  }

  .mobile-privacy {
    display: grid;
    grid-template-columns: 34px 1fr 12px;
    align-items: center;
    gap: 8px;
    margin: 0 14px 18px;
    padding: 10px 10px;
    border: 1px solid #cdd0d2;
    border-radius: 6px;
  }

  .shield.small {
    width: 27px;
    height: 31px;
    background: transparent;
    border: 2px solid #45627c;
  }

  .shield.small::after {
    color: #45627c;
    font-size: 1rem;
  }

  .mobile-privacy p {
    margin: 0;
    font-size: .68rem;
    font-weight: 700;
    line-height: 1.35;
  }

  .footer {
    display: block;
    min-height: auto;
    padding: 12px 18px 16px;
    border-top: 1px solid #bbc1c8;
    text-align: center;
  }

  .footer > * {
    min-height: auto;
  }

  .footer-brand {
    display: block;
  }

  .footer-brand img {
    width: 42px;
    height: 42px;
    margin: 0 auto 5px;
  }

  .footer-brand p {
    font-size: .7rem;
    line-height: 1.35;
  }

  .contact {
    margin-top: 12px;
    gap: 4px;
  }

  .contact strong {
    display: none;
  }

  .contact a {
    font-size: .75rem;
  }
}

@media (min-width: 761px) and (max-width: 1050px) {
  .table-row {
    grid-template-columns: 50px 2.1fr 1.5fr 1.6fr 96px 100px 100px 126px;
  }

  .hero {
    grid-template-columns: 190px 1fr 150px;
  }

  .primary-nav {
    gap: 34px;
  }

  .pillars {
    grid-template-columns: repeat(2, 1fr);
  }

  /* info-grid en colonne sur tablette étroite */
  .info-grid {
    grid-template-columns: 1fr;
  }

  .method-card {
    border-right: none;
    border-bottom: 1px solid #c4c6c5;
  }
}

/* ────────────────────────────────────────────────────
   ACCESSIBILITÉ — améliorations globales
   ──────────────────────────────────────────────────── */

/* Lien d'évitement (skip-to-content) */
.skip-link {
  position: absolute;
  top: -100%;
  left: 0;
  z-index: 9999;
  padding: 8px 14px;
  background: #001f4c;
  color: #fff;
  font-family: Arial, Helvetica, sans-serif;
  font-size: .88rem;
  font-weight: 700;
  text-decoration: none;
  border-radius: 0 0 6px 0;
}

.skip-link:focus {
  top: 0;
}

/* Focus visible sur tous les éléments interactifs */
a:focus-visible,
button:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid #0f4f86;
  outline-offset: 3px;
  border-radius: 2px;
}

/* Zones de clic minimales (WCAG 2.5.5) */
.primary-nav a {
  padding-inline: 8px;
}

.menu-button {
  cursor: pointer;
}

/* Contraste note de bas de tableau */
.note {
  color: #4a5968;
}

/* Focus visible dans le tableau desktop */
@media (min-width: 761px) {
  .ranking-table [role="row"]:focus-within {
    outline: 2px solid #0f4f86;
    outline-offset: -2px;
    border-radius: 4px;
  }
}

/* Réduction des animations si préférence utilisateur */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}

/* Correction overflow horizontal sur petits écrans */
@media (max-width: 760px) {
  html, body {
    overflow-x: hidden;
  }
}
