/* NeutroPDF – thème « trou noir ». Deux thèmes : sombre (ciel étoilé) et clair (trou noir qui avale des PDF).
   Le thème est posé sur <html data-theme="…"> par theme.js. */

:root,
[data-theme="sombre"] {
  --fond: #0B1020;
  --fond-degrade: radial-gradient(ellipse at 50% -10%, #1B2547 0%, #0B1020 55%, #070A16 100%);
  --fond-carte: rgba(19, 26, 46, .74);
  --fond-champ: rgba(11, 16, 32, .8);
  --bord: rgba(110, 130, 190, .25);
  --bord-fort: rgba(110, 130, 190, .45);
  --texte: #F1F5F9;
  --texte-doux: #A3AEC6;
  --accent: #F59E0B;
  --accent-titre: #F59E0B;
  --accent-texte: #FCD34D;
  --accent-sombre: #B45309;
  --teinte-accent: rgba(245, 158, 11, .1);
  --erreur: #F87171;
  --succes: #4ADE80;
  --piste: rgba(255, 255, 255, .08);
  --ombre: 0 24px 60px rgba(0, 0, 0, .45);
  /* Trou noir */
  --disque-arriere: #B45309;
  --disque-avant: #F59E0B;
  --anneau: #FCD34D;
  --flux: #FFF3C4;
  --rayon: 14px;
  --bouton-inactif: #283149;
  --bouton-inactif-texte: #A3AEC6;
  color-scheme: dark;
}

[data-theme="clair"] {
  --fond: #F8F4EC;
  --fond-degrade: radial-gradient(ellipse at 85% 10%, #FFE9C7 0%, rgba(255, 233, 199, 0) 45%),
                  linear-gradient(180deg, #FBF8F2 0%, #F3ECDE 100%);
  --fond-carte: rgba(255, 255, 255, .84);
  --fond-champ: #FFFFFF;
  --bord: rgba(15, 23, 42, .12);
  --bord-fort: rgba(15, 23, 42, .25);
  --texte: #0F172A;
  --texte-doux: #475569;
  --bouton-inactif: #E4DFD5;
  --bouton-inactif-texte: #57534E;
  --accent: #F59E0B;
  --accent-titre: #C2410C;
  --accent-texte: #B45309;
  --accent-sombre: #B45309;
  --teinte-accent: rgba(245, 158, 11, .12);
  --erreur: #DC2626;
  --succes: #16A34A;
  --piste: rgba(15, 23, 42, .08);
  --ombre: 0 24px 50px rgba(120, 72, 10, .12);
  --disque-arriere: #B45309;
  --disque-avant: #F59E0B;
  --anneau: #F59E0B;
  --flux: #FFF7E0;
  color-scheme: light;
}

* { box-sizing: border-box; }

/* L'attribut hidden doit toujours gagner, même sur un élément en display: grid ou flex. */
[hidden] { display: none !important; }

/* Le dégradé est sur <html> et non sur <body> : sinon il serait peint par-dessus le canvas du ciel. */
html {
  background-color: var(--fond);
  background-image: var(--fond-degrade);
  background-attachment: fixed;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--texte);
  line-height: 1.6;
  transition: color .3s;
}

#ciel {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}

a { color: var(--accent-texte); }

/* ---------------------------------------------------------------- En-tête */

.entete {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: 980px;
  margin: 0 auto;
  padding: 1.25rem 1.5rem;
}
.entete-droite { display: flex; align-items: center; gap: .75rem; }

.badge {
  font-size: .85rem;
  color: var(--accent-texte);
  border: 1px solid var(--accent-sombre);
  border-radius: 999px;
  padding: .3rem .8rem;
  background: var(--fond-carte);
}

/* Sélecteur de langue : menu déroulant compact (<details>), même rendu sur ordinateur et téléphone. */
.langues { position: relative; }
.langues summary {
  display: flex;
  align-items: center;
  gap: .35rem;
  height: 40px;
  padding: 0 .8rem;
  border: 1px solid var(--bord-fort);
  border-radius: 999px;
  background: var(--fond-carte);
  color: var(--texte);
  font-size: .85rem;
  font-weight: 650;
  cursor: pointer;
  list-style: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}
.langues summary::-webkit-details-marker { display: none; }
.langues summary:hover, .langues[open] summary { border-color: var(--accent); }
.langues summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.langues svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; flex: none; }
.langues .chevron { transition: transform .2s; opacity: .7; }
.langues[open] .chevron { transform: rotate(180deg); }
.langues ul {
  position: absolute;
  right: 0;
  top: calc(100% + .4rem);
  z-index: 20;
  min-width: 190px;
  margin: 0;
  padding: .35rem;
  list-style: none;
  border: 1px solid var(--bord-fort);
  border-radius: 14px;
  background: var(--fond);
  box-shadow: 0 12px 32px rgba(0, 0, 0, .35);
}
.langues li a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: .7rem .8rem; /* cible tactile confortable (≥ 44 px) */
  border-radius: 10px;
  color: var(--texte);
  text-decoration: none;
  font-size: .95rem;
}
.langues li a abbr { color: var(--texte-doux); font-size: .78rem; font-weight: 650; text-decoration: none; }
.langues li a:hover, .langues li a:focus-visible { background: var(--teinte-accent); outline: none; }
.langues li a[aria-current="page"] { color: var(--accent-texte); font-weight: 650; }
.langues li a[aria-current="page"] abbr { color: var(--accent-texte); }

.bascule-theme {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--bord-fort);
  background: var(--fond-carte);
  color: var(--texte);
  cursor: pointer;
  transition: transform .3s, border-color .2s;
}
.bascule-theme:hover { border-color: var(--accent); transform: rotate(20deg); }
.bascule-theme:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.bascule-theme svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.bascule-theme .icone-lune { fill: currentColor; stroke: none; }
[data-theme="sombre"] .icone-lune,
[data-theme="clair"] .icone-soleil { display: none; }

/* ---------------------------------------------------------------- Trou noir (logo, zone, bouton) */

.trou .disque { fill: none; stroke-linecap: round; }
.trou .disque-arriere { stroke: var(--disque-arriere); }
.trou .disque-avant { stroke: var(--disque-avant); }
.trou .anneau { fill: none; stroke: var(--anneau); transform-box: fill-box; transform-origin: center; }
.trou .horizon { fill: #000; }
.trou .flux {
  fill: none;
  stroke: var(--flux);
  stroke-linecap: round;
  stroke-dasharray: 1.5 7;
  opacity: 0;
  transition: opacity .3s;
}
/* Le haut du disque tourne de gauche à droite, le bas revient de droite à gauche. */
@keyframes flux-avance { to { stroke-dashoffset: -34; } }
@keyframes flux-recule { to { stroke-dashoffset: 34; } }
@keyframes anneau-pulse { 50% { transform: scale(1.12); opacity: .75; } }

.trou-actif .flux, .trou-actif.flux { opacity: 1; }
.trou-actif .flux-arriere { animation: flux-avance 1.4s linear infinite; }
.trou-actif .flux-avant { animation: flux-recule 1.4s linear infinite; }
.trou-actif .anneau { animation: anneau-pulse 1.6s ease-in-out infinite; }

/* Logo */
.marque { display: inline-flex; text-decoration: none; border-radius: 8px; }
.marque:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.logo { overflow: visible; transition: filter .4s; }
.logo-texte { font: 650 26px system-ui, sans-serif; fill: var(--texte); }
.logo-pdf { font: 650 26px system-ui, sans-serif; fill: var(--accent-titre); }
.logo .disque-arriere { stroke-width: 3; }
.logo .disque-avant { stroke-width: 3.5; }
.logo .anneau { stroke-width: 1.5; }
.logo .flux { stroke-width: 1.6; }
.logo-gauche, .logo-droite { transition: transform .6s cubic-bezier(.34, 1.56, .64, 1); }
.marque:hover .logo-gauche, .marque:focus-visible .logo-gauche { transform: translateX(4px); }
.marque:hover .logo-droite, .marque:focus-visible .logo-droite { transform: translateX(-4px); }
.marque:hover .logo, .marque:focus-visible .logo { filter: drop-shadow(0 0 8px rgba(245, 158, 11, .55)); }
.marque:hover .flux, .marque:focus-visible .flux { opacity: 1; }
.marque:hover .flux-arriere, .marque:focus-visible .flux-arriere { animation: flux-avance 1.1s linear infinite; }
.marque:hover .flux-avant, .marque:focus-visible .flux-avant { animation: flux-recule 1.1s linear infinite; }
.marque:hover .anneau, .marque:focus-visible .anneau { animation: anneau-pulse 1.6s ease-in-out infinite; }

/* ---------------------------------------------------------------- Mise en page */

main { max-width: 980px; margin: 0 auto; padding: 0 1.5rem 3rem; }

.hero { text-align: center; padding: 2.5rem 0 2rem; }
.hero h1 { font-size: clamp(1.8rem, 4vw, 2.7rem); line-height: 1.15; margin: 0 0 1rem; letter-spacing: -.01em; }
.hero h1 span { display: block; color: var(--accent-titre); }
.hero p { color: var(--texte-doux); max-width: 640px; margin: 0 auto; }

.outil {
  background: var(--fond-carte);
  border: 1px solid var(--bord);
  border-radius: var(--rayon);
  box-shadow: var(--ombre);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 1.5rem;
  display: grid;
  gap: 1.4rem;
  max-width: 760px;
  margin: 0 auto;
}

/* ---------------------------------------------------------------- Zone de dépôt */

.zone {
  display: grid;
  place-items: center;
  gap: .2rem;
  text-align: center;
  padding: 1.8rem 1rem 2rem;
  border: 2px dashed var(--bord-fort);
  border-radius: var(--rayon);
  cursor: pointer;
  position: relative;
  transition: border-color .2s, background .2s;
}
.zone:hover, .zone.survol { border-color: var(--accent); background: var(--teinte-accent); }
.zone:focus-within { outline: 2px solid var(--accent); outline-offset: 2px; }
.zone strong { font-size: 1.15rem; }
.zone span { color: var(--texte-doux); }
.zone input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }

.trou-zone { overflow: visible; margin-bottom: .4rem; transition: transform .4s cubic-bezier(.34, 1.56, .64, 1); }
.trou-zone .disque-arriere { stroke-width: 4; }
.trou-zone .disque-avant { stroke-width: 5; }
.trou-zone .anneau { stroke-width: 2; }
.trou-zone .flux { stroke-width: 2.2; }
.zone:hover .trou-zone .flux, .zone.survol .trou-zone .flux { opacity: 1; }
.zone:hover .trou-zone .flux-arriere { animation: flux-avance 1.4s linear infinite; }
.zone:hover .trou-zone .flux-avant { animation: flux-recule 1.4s linear infinite; }
.zone.survol .trou-zone { transform: scale(1.18); }
.zone.survol .trou-zone .flux-arriere { animation: flux-avance .45s linear infinite; }
.zone.survol .trou-zone .flux-avant { animation: flux-recule .45s linear infinite; }
.zone.survol .trou-zone .anneau { animation: anneau-pulse .8s ease-in-out infinite; }
/* Le fichier vient d'être « avalé ». */
@keyframes avale { 0% { transform: scale(1); } 35% { transform: scale(1.3); } 100% { transform: scale(1); } }
.zone.avale .trou-zone { animation: avale .7s cubic-bezier(.34, 1.56, .64, 1); }

/* Scène 3D du trou de ver (affichée à la place de la zone de dépôt pendant la compression). */
.scene-trou-de-ver {
  position: relative;
  height: 280px;
  border-radius: var(--rayon);
  overflow: hidden;
  background: #000;
  box-shadow: inset 0 0 0 1px rgba(245, 158, 11, .25);
  animation: apparition .4s ease-out;
}
.tdv-canvas { display: block; width: 100%; height: 100%; }
[data-theme="clair"] .scene-trou-de-ver {
  background: radial-gradient(ellipse at 50% 50%, #FFE7C2 0%, #FBF3E6 55%, #F6EEDF 100%);
  box-shadow: inset 0 0 0 1px rgba(180, 83, 9, .2);
}
[data-theme="clair"] .tdv-etiquette {
  background: rgba(255, 255, 255, .92);
  border-color: rgba(180, 83, 9, .45);
  color: #9A3412;
  box-shadow: 0 4px 14px rgba(120, 72, 10, .15);
}
/* Pendant et après la compression, la scène prend toute la zone de dépôt
   (un clic dessus permet toujours de choisir un autre fichier). */
.zone.avec-scene { padding: 0; border-style: solid; border-color: transparent; background: none; display: block; }
.zone.avec-scene > :not(.scene-trou-de-ver):not(input) { display: none; }
.zone.avec-scene .scene-trou-de-ver { width: 100%; }
.tdv-etiquette {
  position: absolute;
  transform: translate(-50%, 0);
  padding: .15rem .6rem;
  border-radius: 999px;
  background: rgba(4, 6, 13, .7);
  border: 1px solid rgba(252, 211, 77, .45);
  color: #FCD34D;
  font-size: .9rem;
  font-weight: 650;
  white-space: nowrap;
  pointer-events: none;
}

/* ---------------------------------------------------------------- Réglages */

.reglages { border: 0; margin: 0; padding: 0; display: grid; gap: .9rem; min-width: 0; }
.reglages legend { font-weight: 650; margin-bottom: .6rem; padding: 0; }

.niveaux { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .6rem; }
.niveau {
  position: relative;
  display: grid;
  align-content: start;
  gap: .25rem;
  padding: .85rem .9rem;
  border: 1px solid var(--bord-fort);
  border-radius: 12px;
  background: var(--fond-champ);
  cursor: pointer;
  transition: border-color .2s, background .2s, transform .2s, box-shadow .2s;
}
.niveau:hover { border-color: var(--accent); transform: translateY(-2px); }
.niveau input { position: absolute; opacity: 0; pointer-events: none; }
.niveau:has(input:checked) {
  border-color: var(--accent);
  background: var(--teinte-accent);
  box-shadow: 0 0 0 1px var(--accent), 0 8px 24px rgba(245, 158, 11, .18);
}
.niveau:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.niveau-titre { font-weight: 650; }
.niveau-detail { font-size: .85rem; color: var(--texte-doux); line-height: 1.35; }

.jauge { display: flex; gap: 4px; margin-bottom: .2rem; height: 12px; align-items: center; }
.jauge i { display: block; width: 16px; height: 6px; border-radius: 3px; background: var(--piste); }
.jauge-1 i:nth-child(-n+1),
.jauge-2 i:nth-child(-n+2),
.jauge-3 i { background: var(--accent); }
.jauge-cible i {
  width: 12px; height: 12px; border-radius: 50%;
  background: radial-gradient(circle, var(--accent) 0 2px, transparent 2.5px);
  border: 2px solid var(--accent);
}

.choix-taille {
  display: grid;
  gap: .6rem;
  padding: .9rem;
  border: 1px dashed var(--accent-sombre);
  border-radius: 12px;
  animation: apparition .3s ease-out;
}
.choix-taille-titre { font-size: .95rem; color: var(--texte-doux); }
.choix { display: flex; flex-wrap: wrap; gap: .5rem; }
.choix > label {
  display: inline-flex; align-items: center; gap: .4rem;
  border: 1px solid var(--bord-fort);
  border-radius: 8px;
  padding: .4rem .75rem;
  background: var(--fond-champ);
  cursor: pointer;
}
.choix > label:has(input:checked) { border-color: var(--accent); background: var(--teinte-accent); }
.choix input[type="text"] {
  width: 4.5rem;
  background: var(--fond-champ);
  color: var(--texte);
  border: 1px solid var(--bord-fort);
  border-radius: 6px;
  padding: .2rem .4rem;
  font: inherit;
}
.case { display: flex; align-items: center; gap: .6rem; color: var(--texte-doux); cursor: pointer; }
input[type="radio"], input[type="checkbox"] { accent-color: var(--accent); }
/* Case « Noir et blanc » dessinée à la main : bien visible sur fond sombre, orange quand cochée. */
.case input[type="checkbox"] {
  appearance: none;
  flex: none;
  display: grid;
  place-content: center;
  width: 1.3rem;
  height: 1.3rem;
  margin: 0;
  border: 2px solid var(--texte-doux);
  border-radius: 5px;
  background: var(--fond-champ);
  cursor: pointer;
  transition: background .15s, border-color .15s;
}
.case input[type="checkbox"]::after {
  content: '';
  width: .36rem;
  height: .68rem;
  margin-top: -.15rem;
  border: solid #1C1003;
  border-width: 0 .17rem .17rem 0;
  transform: rotate(45deg) scale(0);
  transition: transform .15s;
}
.case input[type="checkbox"]:checked { background: var(--accent); border-color: var(--accent); }
.case input[type="checkbox"]:checked::after { transform: rotate(45deg) scale(1); }
.case input[type="checkbox"]:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.case:hover input[type="checkbox"]:not(:checked) { border-color: var(--accent); }

/* ---------------------------------------------------------------- Boutons */

.bouton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .6rem;
  text-align: center;
  text-decoration: none;
  font: inherit;
  font-weight: 650;
  color: #1C1003;
  background: linear-gradient(135deg, #FCD34D 0%, #F59E0B 55%, #EA8A06 100%);
  border: 0;
  border-radius: 10px;
  padding: .85rem 1.5rem;
  cursor: pointer;
  transition: transform .15s, box-shadow .25s, filter .2s;
}
.bouton:hover { filter: brightness(1.06); box-shadow: 0 0 0 4px rgba(245, 158, 11, .22), 0 10px 30px rgba(245, 158, 11, .35); }
.bouton:active { transform: translateY(1px); }
.bouton:focus-visible { outline: 2px solid var(--texte); outline-offset: 3px; }
/* Bouton désactivé (aucun fichier choisi) : gris franc, lisible, qui ne ressemble pas à un défaut. */
.bouton:disabled { background: var(--bouton-inactif); color: var(--bouton-inactif-texte); cursor: not-allowed; box-shadow: none; filter: none; }
.bouton:disabled .trou-mini { filter: grayscale(1); opacity: .55; }

.bouton-compresser { font-size: 1.08rem; padding: .95rem 1.5rem; }
.trou-mini { overflow: visible; flex: none; --disque-arriere: #7C2D12; --disque-avant: #9A3412; --anneau: #FFFBEB; --flux: #FFFFFF; }
.trou-mini .disque-arriere { stroke-width: 2.4; }
.trou-mini .disque-avant { stroke-width: 3; }
.trou-mini .anneau { stroke-width: 1.2; }
.trou-mini .flux { stroke-width: 1.4; }
.bouton-compresser:not(:disabled):hover .flux { opacity: 1; }
.bouton-compresser:not(:disabled):hover .flux-arriere { animation: flux-avance 1s linear infinite; }
.bouton-compresser:not(:disabled):hover .flux-avant { animation: flux-recule 1s linear infinite; }
.bouton-compresser:not(:disabled):hover .anneau { animation: anneau-pulse 1.4s ease-in-out infinite; }
/* Pendant la compression : le trou noir avale à toute vitesse. */
.bouton-compresser.occupe { opacity: 1; cursor: progress; }
.bouton-compresser.occupe .flux { opacity: 1; }
.bouton-compresser.occupe .flux-arriere { animation: flux-avance .4s linear infinite; }
.bouton-compresser.occupe .flux-avant { animation: flux-recule .4s linear infinite; }
.bouton-compresser.occupe .anneau { animation: anneau-pulse .7s ease-in-out infinite; }

.bouton-telecharger svg { fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
@keyframes rebond { 50% { transform: translateY(3px); } }
.bouton-telecharger:hover svg { animation: rebond .7s ease-in-out infinite; }

/* ---------------------------------------------------------------- Progression et résultat */

.barre { height: 10px; background: var(--piste); border-radius: 999px; overflow: hidden; }
#barre-remplie {
  height: 100%;
  width: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, #B45309, #F59E0B, #FCD34D, #F59E0B, #B45309);
  background-size: 200% 100%;
  animation: reflet 1.6s linear infinite;
  transition: width .2s;
}
@keyframes reflet { to { background-position: -200% 0; } }
#etat { color: var(--texte-doux); margin: .5rem 0 0; font-size: .95rem; }

@keyframes apparition { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.resultat {
  border: 1px solid var(--succes);
  border-radius: var(--rayon);
  padding: 1.1rem 1.25rem;
  display: grid;
  gap: .9rem;
  justify-items: start;
  animation: apparition .4s ease-out;
}
.resultat p { margin: 0; font-weight: 600; }
.comparaison {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: .45rem .8rem;
  width: 100%;
  font-size: .92rem;
  color: var(--texte-doux);
}
.comparaison .valeur { font-variant-numeric: tabular-nums; color: var(--texte); text-align: right; }
.piste { height: 10px; background: var(--piste); border-radius: 999px; overflow: hidden; }
.remplissage { height: 100%; width: 0; border-radius: 999px; transition: width 1s cubic-bezier(.22, 1, .36, 1); }
.remplissage.avant { background: var(--texte-doux); opacity: .55; }
.remplissage.apres { background: linear-gradient(90deg, #F59E0B, #FCD34D); }

.message { margin: 0; color: var(--erreur); }
.message.info { color: var(--accent-texte); }

/* ---------------------------------------------------------------- Atouts, FAQ, pied */

.atouts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin: 2.5rem 0;
}
.atouts article {
  background: var(--fond-carte);
  border: 1px solid var(--bord);
  border-radius: var(--rayon);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  padding: 1.25rem;
}
.atouts h2 { font-size: 1.1rem; margin: 0 0 .5rem; color: var(--accent-texte); }
.atouts p { margin: 0; color: var(--texte-doux); }

.faq {
  background: var(--fond-carte);
  border: 1px solid var(--bord);
  border-radius: var(--rayon);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  padding: .5rem 1.5rem 1rem;
}
.faq h2 { font-size: 1.4rem; }
.fil-ariane { display: flex; flex-wrap: wrap; justify-content: center; gap: .45rem; margin-bottom: .9rem; font-size: .88rem; color: var(--texte-doux); }
.fil-ariane a { color: var(--accent-texte); text-decoration: none; }
.fil-ariane a:hover { text-decoration: underline; }
.faq details { border-bottom: 1px solid var(--bord); padding: .9rem 0; }
.faq details:last-child { border-bottom: 0; }
.faq summary { cursor: pointer; font-weight: 600; }
.faq details p { color: var(--texte-doux); margin: .6rem 0 0; }

.pied {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .7rem 1.5rem;
  padding: 2rem 1rem;
  color: var(--texte-doux);
  font-size: .9rem;
  border-top: 1px solid var(--bord);
}

.pied > * { white-space: nowrap; }
@media (max-width: 480px) {
  .pied { flex-direction: column; align-items: center; }
}

.page-texte { max-width: 760px; margin: 0 auto; padding: 2rem 1.5rem 4rem; }
.page-texte h1 { font-size: 2rem; }
.page-texte h2 { font-size: 1.2rem; color: var(--accent-texte); margin-top: 2rem; }
.page-texte p, .page-texte li { color: var(--texte-doux); }
.a-remplir { background: rgba(248, 113, 113, .15); color: var(--erreur); padding: 0 .3rem; border-radius: 4px; }

/* ---------------------------------------------------------------- Éléments pilotés par le back-office */

.annonce-site {
  text-align: center;
  padding: .55rem 1rem;
  background: linear-gradient(90deg, #B45309, #F59E0B, #B45309);
  color: #1C1003;
  font-weight: 600;
  font-size: .92rem;
}
.maintenance-site {
  border: 1px solid var(--accent);
  border-radius: var(--rayon);
  background: var(--teinte-accent);
  padding: 1rem 1.2rem;
  text-align: center;
}
.maintenance-site p { margin: .3rem 0 0; color: var(--texte-doux); }

/* Bandeaux publicitaires verticaux (160 × 600), uniquement sur grand écran. */
.pub-laterale { display: none; }
@media (min-width: 1360px) {
  .pub-laterale {
    display: grid;
    gap: .3rem;
    position: fixed;
    top: 120px;
    width: 160px;
    text-decoration: none;
    z-index: 1;
  }
  .pub-gauche { left: calc(50% - 490px - 190px); }
  .pub-droite { right: calc(50% - 490px - 190px); }
  .pub-laterale span { font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--texte-doux); text-align: center; }
  .pub-laterale img { display: block; width: 160px; height: 600px; object-fit: cover; border-radius: 8px; border: 1px solid var(--bord); background: var(--fond-carte); }
}

/* Bandeau de consentement : les deux boutons ont le même poids (exigence CNIL). */
.bandeau-cookies {
  position: fixed;
  left: 50%;
  bottom: 1rem;
  transform: translateX(-50%);
  width: min(720px, calc(100% - 2rem));
  z-index: 20;
  display: flex;
  flex-wrap: wrap;
  gap: .8rem 1.2rem;
  align-items: center;
  padding: 1rem 1.2rem;
  border: 1px solid var(--bord-fort);
  border-radius: var(--rayon);
  background: var(--fond-carte);
  box-shadow: var(--ombre);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  animation: apparition .3s ease-out;
}
.bandeau-cookies p { flex: 1 1 320px; margin: 0; font-size: .9rem; color: var(--texte-doux); }
.bandeau-cookies div { display: flex; gap: .6rem; }
.bouton-cookies {
  font: inherit; font-weight: 650; cursor: pointer;
  padding: .55rem 1.2rem; border-radius: 8px;
  border: 1px solid var(--accent); background: var(--fond-champ); color: var(--texte);
}
.bouton-cookies:hover { background: var(--teinte-accent); }

/* ---------------------------------------------------------------- Pages dédiées (référencement) */

.article-seo {
  max-width: 760px;
  margin: 2.5rem auto;
  background: var(--fond-carte);
  border: 1px solid var(--bord);
  border-radius: var(--rayon);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  padding: .5rem 1.6rem 1.4rem;
}
.article-seo h2 { font-size: 1.2rem; color: var(--accent-texte); margin: 1.4rem 0 .5rem; }
.article-seo p, .article-seo li { color: var(--texte-doux); }
.article-seo strong { color: var(--texte); }
.article-seo ul { padding-left: 1.2rem; }

.guides { max-width: 760px; margin: 2rem auto 0; }
.guides h2 { font-size: 1.15rem; }
.guides ul { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: .5rem; }
.guides a {
  display: block;
  padding: .65rem .9rem;
  border: 1px solid var(--bord);
  border-radius: 10px;
  background: var(--fond-carte);
  text-decoration: none;
  color: var(--texte);
  transition: border-color .2s, transform .2s;
}
.guides a:hover { border-color: var(--accent); transform: translateY(-1px); }
.guides a::after { content: ' →'; color: var(--accent-texte); }

/* ---------------------------------------------------------------- Page annonceurs */

.page-annonceurs { max-width: 980px; margin: 0 auto; padding: 1.5rem 1.5rem 3rem; display: grid; gap: 1.5rem; }
.page-annonceurs .atouts { margin: 0; }
.texte-doux { color: var(--texte-doux); }

.navigateur {
  border: 1px solid var(--bord-fort);
  border-radius: var(--rayon);
  overflow: hidden;
  background: var(--fond-carte);
  box-shadow: var(--ombre);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.navigateur-barre {
  display: flex; align-items: center; gap: 6px;
  padding: .55rem .8rem;
  border-bottom: 1px solid var(--bord);
  font-size: .8rem; color: var(--texte-doux);
}
.navigateur-barre i { width: 10px; height: 10px; border-radius: 50%; background: var(--bord-fort); }
.navigateur-barre span {
  margin-left: .8rem; padding: .1rem .8rem; border-radius: 999px;
  background: var(--piste); flex: 0 1 260px;
}
.navigateur-page {
  display: grid;
  grid-template-columns: 1fr 3.4fr 1fr;
  gap: 1.2rem;
  padding: 1.2rem;
  align-items: start;
}
@keyframes clignote { 50% { border-color: var(--accent-texte); box-shadow: 0 0 0 4px rgba(245, 158, 11, .15); } }
.emplacement {
  aspect-ratio: 160 / 600;
  display: grid;
  place-content: center;
  gap: .4rem;
  text-align: center;
  padding: .6rem;
  border: 2px dashed var(--accent);
  border-radius: 10px;
  background: repeating-linear-gradient(-45deg, var(--teinte-accent) 0 10px, transparent 10px 20px);
  animation: clignote 2.4s ease-in-out infinite;
}
.emplacement strong { color: var(--accent-texte); font-size: 1rem; line-height: 1.2; }
.emplacement span { font-size: .82rem; color: var(--texte-doux); line-height: 1.3; }
.emplacement em { font-style: normal; font-weight: 650; font-variant-numeric: tabular-nums; }

.maquette-site { display: grid; gap: .7rem; justify-items: center; padding-top: .4rem; opacity: .8; }
.maquette-site div, .maquette-site i { background: var(--piste); border-radius: 6px; display: block; }
.maquette-logo { width: 22%; height: 14px; justify-self: start; }
.maquette-titre { width: 70%; height: 18px; }
.maquette-titre.court { width: 50%; margin-top: -.3rem; }
.maquette-outil { width: 86%; display: grid; gap: .6rem; padding: .8rem; border: 1px solid var(--bord); background: none !important; }
.maquette-zone { height: 90px; border: 2px dashed var(--bord-fort); background: none !important; }
.maquette-niveaux { display: grid !important; grid-template-columns: repeat(4, 1fr); gap: .4rem; background: none !important; }
.maquette-niveaux i { height: 34px; }
.maquette-bouton { height: 26px; background: var(--accent) !important; opacity: .7; }
.maquette-cartes { width: 100%; display: grid !important; grid-template-columns: repeat(3, 1fr); gap: .5rem; background: none !important; }
.maquette-cartes i { height: 60px; }
.maquette-faq { width: 100%; display: grid !important; gap: .55rem; padding: .8rem; border: 1px solid var(--bord); background: none !important; }
.maquette-faq i { height: 12px; width: 75%; }
.maquette-faq i:nth-child(2n) { width: 55%; }
.maquette-faq i:first-child { width: 35%; height: 16px; }
.maquette-legende { margin: .8rem 0 0; font-size: .9rem; color: var(--texte-doux); text-align: center; }

.contact-annonceurs {
  text-align: center;
  padding: 2rem 1.5rem;
  border: 1px solid var(--accent-sombre);
  border-radius: var(--rayon);
  background: var(--fond-carte);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.contact-annonceurs h2 { margin-top: 0; }
.contact-annonceurs p { color: var(--texte-doux); max-width: 560px; margin: 0 auto 1.2rem; }
.contact-annonceurs svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; }

@media (max-width: 640px) {
  .navigateur-page { grid-template-columns: 1fr 2.4fr 1fr; gap: .5rem; padding: .6rem; }
  .emplacement strong { font-size: .75rem; }
  .emplacement span { display: none; }
  .emplacement em { font-size: .7rem; }
}

@media (max-width: 560px) {
  .badge { display: none; }
  .outil { padding: 1.1rem; }
  .niveaux { grid-template-columns: 1fr 1fr; }
}

/* Respect du réglage « réduire les animations » du système. */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* Note sous les chiffres mesurés des pages dédiées. */
.note-mesure { font-size: .85rem; color: var(--texte-doux); font-style: italic; }

/* Page 404 */
.page-404 { text-align: center; padding-top: 4rem; }
.code-404 { font-size: 5rem; font-weight: 800; line-height: 1; margin: 0; color: var(--accent-titre); }
.page-404 .texte-doux { font-size: .92rem; margin: .4rem 0; }

/* En-tête sur une seule ligne sur téléphone : logo à gauche, langue + thème à droite. */
@media (max-width: 480px) {
  .entete { flex-wrap: nowrap; gap: .5rem; padding: 1rem 1rem .75rem; }
  .entete .logo { width: 150px; height: auto; }
  .entete-droite { gap: .5rem; flex: none; }
  .langues summary { padding: 0 .65rem; }
}

/* Téléphone : cartes de niveau plus compactes (« Taille maximale » sur une ligne). */
@media (max-width: 420px) {
  .niveau { padding: .75rem .7rem; }
  .niveau-titre { font-size: .98rem; white-space: nowrap; }
  .niveau-detail { font-size: .8rem; }
}
/* Écrans tactiles : zones à toucher d'au moins 44 px (questions de la FAQ, liens du pied de page). */
@media (pointer: coarse) {
  .faq summary { padding: .55rem 0; }
  .faq details { padding: .45rem 0; }
  .pied a { display: inline-block; padding: .6rem .4rem; }
  .fil-ariane a { display: inline-block; padding: .5rem 0; }
}
