/* jlmv.fr : feuille de style unique. Polices du système, aucune ressource extérieure. */

:root {
  --police: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --texte: #1d1d1f;
  --texte-2: #6e6e73;
  --texte-3: #86868b;
  --fond: #ffffff;
  --fond-2: #f5f5f7;
  --fond-verre: rgba(255, 255, 255, 0.86);
  --trait: #d2d2d7;
  --trait-2: #e5e5ea;
  --gris-controle: rgba(118, 118, 128, 0.12);
  --segment-actif: #ffffff;
  --accent: #4b32c3;
  --accent-survol: #3a2699;
  --sur-accent: #ffffff;
  --teinte: rgba(75, 50, 195, 0.08);
  --teinte-forte: rgba(75, 50, 195, 0.18);
  --vert: #1f7a35;
  --rouge: #c4302b;
  /* zones noires (bandeau, colonne vidéo) : identiques en mode clair et sombre */
  --noir: #000000;
  --noir-2: #1c1c1e;
  --noir-trait: #38383a;
  --clair: #f5f5f7;
  --clair-2: #a1a1a6;
  --accent-nuit: #a594f9;
  --mesure: 50rem;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --texte: #f5f5f7;
    --texte-2: #a1a1a6;
    --texte-3: #86868b;
    --fond: #111113;
    --fond-2: #1c1c1e;
    --fond-verre: rgba(17, 17, 19, 0.82);
    --trait: #38383a;
    --trait-2: #2c2c2e;
    --gris-controle: rgba(118, 118, 128, 0.24);
    --segment-actif: #636366;
    --accent: #a594f9;
    --accent-survol: #c4b8ff;
    --sur-accent: #1d1d1f;
    --teinte: rgba(165, 148, 249, 0.12);
    --teinte-forte: rgba(165, 148, 249, 0.28);
    --vert: #32d74b;
    --rouge: #ff6961;
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--police);
  font-size: 17px;
  line-height: 1.47;
  color: var(--texte);
  background: var(--fond);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: var(--accent); }
a:hover { color: var(--accent-survol); }
img, svg, canvas { display: block; }
button { font: inherit; }
h1, h2, h3 { text-wrap: balance; }

:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.sombre :focus-visible, .scene__colonne :focus-visible, .selection-outils :focus-visible { outline-color: var(--accent-nuit); }

.num { font-variant-numeric: tabular-nums; }
.insecable { white-space: nowrap; }

.visuellement-cache {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.evitement {
  position: absolute; left: 16px; top: -60px; z-index: 100;
  padding: 10px 16px; border-radius: 10px;
  background: var(--fond); color: var(--texte); font-weight: 600;
  text-decoration: none;
}
.evitement:focus { top: 12px; }

.conteneur { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* --- Zones noires -------------------------------------------------------- */

.sombre { background: var(--noir); color: var(--clair); }

.bandeau__ligne {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: 12px 32px;
  min-height: 56px; padding-top: 8px; padding-bottom: 8px;
}

/* Logo : « jlmv » avec guillemet, trait et tortue, puis le nom en dessous */
.logo {
  flex: none;
  display: inline-flex; flex-direction: column; align-items: center; gap: 5px;
  padding: 4px 0;
  color: var(--clair); text-decoration: none;
}
.logo:hover { color: var(--clair); }
.logo__marque { display: block; width: auto; height: 54px; }
.logo__nom { font-size: 11px; font-weight: 300; letter-spacing: 0.14em; line-height: 1.3; text-align: center; color: rgba(255, 255, 255, 0.9); white-space: nowrap; }
.bandeau--compact .navigation { order: 3; flex-basis: 100%; }

.navigation { display: flex; flex-wrap: wrap; gap: 8px 24px; font-size: 14px; }
.bandeau--compact .bandeau__ligne { gap: 12px 16px; }
.bandeau--compact .navigation { gap: 8px 16px; font-size: 13px; }
.navigation a { color: var(--clair-2); text-decoration: none; }
.navigation a:hover, .navigation a[aria-current] { color: var(--clair); }
.navigation a[aria-current] { font-weight: 600; }

.bouton-rond {
  margin-left: auto;
  width: 36px; height: 36px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255, 255, 255, 0.12); color: var(--clair);
}
.bouton-rond:hover { background: rgba(255, 255, 255, 0.2); color: var(--clair); }

.non-officiel { font-size: 12px; color: var(--clair-2); }
.recherche--bandeau ~ .non-officiel { margin-left: auto; }

/* --- Recherche ----------------------------------------------------------- */

.recherche { position: relative; display: flex; align-items: center; margin: 0; }
.recherche__icone { position: absolute; left: 20px; color: var(--clair-2); pointer-events: none; }
.recherche__champ {
  width: 100%;
  border: 1px solid var(--noir-trait); border-radius: 980px;
  background: var(--noir-2); color: var(--clair);
  font: inherit;
  -webkit-appearance: none; appearance: none;
}
.recherche__champ::placeholder { color: var(--clair-2); opacity: 1; }
.recherche__champ::-webkit-search-cancel-button { -webkit-appearance: none; }

.recherche--grande { margin-top: 40px; max-width: 720px; }
.recherche--grande .recherche__champ { min-height: 60px; padding: 0 140px 0 52px; font-size: 18px; }
.recherche--grande .bouton { position: absolute; right: 8px; min-height: 44px; padding: 0 22px; font-size: 16px; }

.recherche--bandeau { flex: 1 1 320px; max-width: 560px; }
.recherche--bandeau .recherche__icone { left: 14px; }
.recherche--bandeau .recherche__champ { min-height: 40px; padding: 0 16px 0 40px; font-size: 15px; }

.recherche--page { margin-top: 24px; max-width: 720px; }
.recherche--page .recherche__icone { color: var(--texte-2); }
.recherche--page .recherche__champ { min-height: 56px; padding: 0 140px 0 52px; font-size: 18px; background: var(--fond-2); border-color: var(--trait); color: var(--texte); }
.recherche--page .recherche__champ::placeholder { color: var(--texte-2); }
.recherche--page .bouton { position: absolute; right: 6px; }

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

.bouton {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 40px; padding: 0 18px;
  border: 0; border-radius: 980px;
  font-size: 15px; font-weight: 600; line-height: 1.2;
  text-decoration: none; cursor: pointer;
  white-space: nowrap;
}
.bouton--accent, .bouton--clair { background: var(--accent-nuit); color: #1d1d1f; }
.bouton--accent:hover, .bouton--clair:hover { background: #b9abff; color: #1d1d1f; }
.bouton--gris { background: rgba(255, 255, 255, 0.12); color: var(--clair); font-weight: 500; }
.bouton--gris:hover { background: rgba(255, 255, 255, 0.2); color: var(--clair); }
.bouton--accent-clair { background: var(--accent); color: var(--sur-accent); }
.bouton--accent-clair:hover { background: var(--accent-survol); color: var(--sur-accent); }
.bouton--gris-clair { background: var(--gris-controle); color: var(--texte); font-weight: 500; }
.bouton[disabled] { opacity: 0.4; cursor: default; }

.icone {
  flex: none;
  width: 32px; height: 32px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 0; border-radius: 8px; padding: 0;
  background: transparent; color: var(--accent);
  cursor: pointer;
}
.icone:hover { background: var(--teinte); }

.segmente { display: inline-flex; padding: 2px; border-radius: 9px; background: var(--gris-controle); }
.segmente a, .segmente button {
  display: inline-flex; align-items: center;
  min-height: 32px; padding: 0 14px;
  border: 0; border-radius: 7px; background: transparent;
  font-size: 14px; font-weight: 500; color: var(--texte);
  text-decoration: none; cursor: pointer; white-space: nowrap;
}
.segmente [aria-current="true"], .segmente [aria-pressed="true"] {
  background: var(--segment-actif);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

.chevron {
  flex: none;
  width: 8px; height: 8px;
  margin-right: 4px;
  border-top: 1.8px solid var(--texte-3); border-right: 1.8px solid var(--texte-3);
  transform: rotate(45deg);
}

.lecture-rond {
  width: 64px; height: 64px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255, 255, 255, 0.92); color: #1d1d1f;
}

.meta { margin: 0; font-size: 15px; color: var(--texte-2); }
.meta--sombre { font-size: 14px; color: var(--clair-2); }

/* --- Accueil ------------------------------------------------------------- */

.hero { padding-top: 72px; padding-bottom: 88px; }
.hero__titre {
  margin: 0; max-width: 900px;
  font-size: clamp(36px, 6vw, 60px); line-height: 1.05; letter-spacing: -0.03em; font-weight: 700;
}
.hero__sous-titre { margin: 20px 0 0; max-width: 680px; font-size: clamp(18px, 2.2vw, 21px); line-height: 1.4; color: var(--clair-2); }

.section { padding-top: 72px; }
.section--serree { padding-top: 40px; }
.section__tete { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.section__titre { margin: 0 0 24px; font-size: clamp(26px, 3.4vw, 32px); line-height: 1.1; letter-spacing: -0.025em; font-weight: 700; }
.section__tete .section__titre { margin: 0; }
.section__intro { margin: -8px 0 24px; font-size: 17px; color: var(--texte-2); max-width: 46rem; }

.vedette { display: flex; flex-wrap: wrap; align-items: center; gap: 32px; color: var(--texte); text-decoration: none; }
.vedette:hover { color: var(--texte); }
.vedette__image {
  position: relative; overflow: hidden;
  flex: 1 1 440px; min-width: 0;
  aspect-ratio: 16 / 9; border-radius: 18px;
  background: var(--noir-2);
  display: flex; align-items: center; justify-content: center;
  container-type: inline-size;
}
.vedette__image .lecture-rond { position: relative; z-index: 1; transition: transform 0.15s ease; }
.vedette:hover .vedette__image .lecture-rond { transform: scale(1.06); }
.vedette__texte { flex: 1 1 360px; min-width: 0; display: flex; flex-direction: column; }
.vedette__titre { margin-top: 8px; font-size: clamp(26px, 3.4vw, 34px); line-height: 1.1; letter-spacing: -0.025em; font-weight: 700; text-wrap: balance; }
.vedette__resume { margin-top: 12px; font-size: 17px; color: var(--texte-2); }
.lien-suite { margin-top: 16px; color: var(--accent); }
.lien-suite::after { content: " ›"; }
.vedette:hover .lien-suite { text-decoration: underline; }

.liste-groupee { list-style: none; margin: 0; padding: 0; background: var(--fond-2); border-radius: 12px; overflow: hidden; }
.liste-groupee > li + li { border-top: 1px solid var(--trait); }
.liste-groupee a { text-decoration: none; }
.liste-groupee a:hover { background: rgba(127, 127, 127, 0.07); }

.ligne-intervention {
  display: flex; flex-wrap: wrap; align-items: center; gap: 4px 24px;
  min-height: 60px; padding: 12px 20px;
  color: var(--texte);
}
.ligne-intervention:hover { color: var(--texte); }
.ligne-intervention__date { flex: 0 0 140px; font-size: 15px; color: var(--texte-2); }
.ligne-intervention__titre { flex: 999 1 300px; min-width: 0; font-size: 17px; font-weight: 600; }
.ligne-intervention__source { flex: 0 1 auto; font-size: 15px; color: var(--texte-2); }

.ligne-simple { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 10px 16px; color: var(--texte); font-size: 16px; }
.ligne-simple:hover { color: var(--texte); }
.ligne-simple > span:first-child { flex: 1; min-width: 0; }
.ligne-simple small { display: block; font-size: 13px; color: var(--texte-2); }

.grille-themes { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.theme {
  height: 100%;
  display: flex; flex-direction: column; justify-content: space-between; gap: 8px;
  padding: 20px; border-radius: 12px;
  background: var(--fond-2); color: var(--texte);
  font-size: 17px; font-weight: 600; text-decoration: none;
}
.theme:hover { color: var(--texte); background: var(--teinte); }
.theme__compte { font-size: 14px; font-weight: 400; color: var(--texte-2); }

.vide, .vide-texte { color: var(--texte-2); }
.vide { margin-top: 32px; font-size: 17px; }
.vide p { margin: 0 0 8px; }

/* --- Pages simples, recherche --------------------------------------------- */

.titre-page { margin: 48px 0 0; font-size: clamp(28px, 4vw, 40px); line-height: 1.1; letter-spacing: -0.025em; font-weight: 700; }
.sous-titre-page { margin: 8px 0 0; font-size: 17px; color: var(--texte-2); max-width: 46rem; }
.fil { margin: 32px 0 0; font-size: 14px; }
.fil a { text-decoration: none; }
.fil a::before { content: "‹ "; }
.fil + .titre-page { margin-top: 8px; }
.petit-titre { margin: 0 0 8px 16px; font-size: 13px; font-weight: 400; color: var(--texte-2); }

.texte-courant { max-width: calc(46rem + 48px); }
.texte-courant h2 { margin: 40px 0 8px; font-size: 22px; line-height: 1.2; letter-spacing: -0.015em; font-weight: 600; }
.texte-courant p, .texte-courant li { font-size: 17px; line-height: 1.6; }
.texte-courant p { margin: 0 0 12px; }
.texte-courant ol, .texte-courant ul { margin: 0 0 12px; padding-left: 1.4em; }
.texte-courant li + li { margin-top: 6px; }

.conseils { margin-top: 48px; max-width: 46rem; }
.conseils h2 { margin: 0 0 8px; font-size: 17px; font-weight: 600; }
.conseils ul { margin: 0; padding-left: 1.2em; color: var(--texte-2); line-height: 1.6; }

.filtres { margin: 28px 0 36px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.filtres__espace { flex: 1 1 24px; }
.filtre select {
  -webkit-appearance: none; appearance: none;
  min-height: 36px; padding: 0 34px 0 14px;
  border: 0; border-radius: 980px;
  background: var(--gris-controle) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 12 12' fill='none' stroke='%2386868b' stroke-width='1.8' stroke-linecap='round'%3E%3Cpath d='M2.5 4.5L6 8l3.5-3.5'/%3E%3C/svg%3E") no-repeat right 14px center;
  font: inherit; font-size: 14px; font-weight: 500; color: var(--texte);
  cursor: pointer;
}
.filtre--actif select { background-color: var(--teinte); color: var(--accent); font-weight: 600; }

.resultats { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 48px; }
.resultats__liste { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 40px; }
.resultats__programme { flex: 1 1 280px; min-width: 0; position: sticky; top: 24px; }
.resultat__titre { margin: 4px 0 12px; font-size: 22px; line-height: 1.25; letter-spacing: -0.015em; font-weight: 600; }
.resultat__titre a { color: var(--texte); text-decoration: none; }
.resultat__titre a:hover { color: var(--accent); }

.passage { display: flex; gap: 16px; padding: 14px 16px; color: var(--texte); }
.passage:hover { color: var(--texte); }
.passage__temps { flex: none; width: 52px; padding-top: 3px; font-size: 13px; color: var(--accent); }
.passage__texte { min-width: 0; font-size: 17px; line-height: 1.5; }
.passage--autre .passage__texte { color: var(--texte-2); }
.passage--autre strong { color: var(--texte); font-weight: 600; }
.passage__source { display: block; margin-bottom: 4px; font-size: 13px; color: var(--texte-2); }

mark { background: var(--teinte-forte); color: inherit; padding: 0 2px; border-radius: 3px; }

.extrait-programme {
  margin: 24px 0 0; max-width: 46rem;
  padding: 16px 20px;
  border-left: 3px solid var(--accent); border-radius: 0 12px 12px 0;
  background: var(--fond-2);
  font-size: 17px; line-height: 1.6;
}

.page-erreur .tortue--grande { margin-top: 64px; }
.page-erreur .bouton { margin-top: 16px; }

/* --- Pied de page --------------------------------------------------------- */

.pied { margin-top: 88px; border-top: 1px solid var(--trait-2); }
.pied__ligne {
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px;
  padding-top: 24px; padding-bottom: 40px;
  font-size: 13px; color: var(--texte-2);
}
.pied__marque { display: inline-flex; align-items: center; gap: 8px; color: var(--texte-2); font-weight: 600; text-decoration: none; }
.pied__marque:hover { color: var(--texte); }
.pied__marque .tortue { display: block; transition: transform 0.6s ease; }
.pied__marque:hover .tortue { transform: translateX(3px); }
.pied__texte { flex: 1 1 320px; margin: 0; }
.pied__liens { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.pied__liens a { color: var(--texte-2); }
.pied__liens a:hover { color: var(--texte); }

/* --- Fiche d'intervention ------------------------------------------------- */

.scene__colonne {
  background: var(--noir); color: var(--clair);
  padding: 0 16px 24px;
  display: flex; flex-direction: column; gap: 20px;
}
.scene__colonne > * { flex-shrink: 0; }
.scene__titre h1 { margin: 8px 0 0; font-size: clamp(26px, 2.4vw, 34px); line-height: 1.1; letter-spacing: -0.025em; font-weight: 700; }

.lecteur-place { position: relative; width: 100%; aspect-ratio: 16 / 9; }
.lecteur {
  position: absolute; inset: 0;
  border-radius: 18px; overflow: hidden;
  background: var(--noir-2);
  display: flex; align-items: center; justify-content: center;
  container-type: inline-size;
}
.lecteur iframe, .lecteur > div:not([class]) { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.lecteur__lancer {
  position: relative; z-index: 1;
  width: 100%; height: 100%; padding: 0; border: 0;
  background: transparent; color: #1d1d1f;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
}
.lecteur__lancer .lecture-rond { width: 68px; height: 68px; transition: transform 0.15s ease; }
.lecteur__lancer:hover .lecture-rond { transform: scale(1.06); }
.lecteur.actif .lecteur__lancer, .lecteur.actif .vignette { display: none; }

/* Vignette maison : média, date et frise du temps de parole, sans image extérieure */
.vignette {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: clamp(14px, 4.6cqw, 32px) clamp(16px, 5cqw, 36px) clamp(12px, 4cqw, 28px);
  color: var(--clair); text-align: left; pointer-events: none;
}
.vignette__haut { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.vignette__titres { display: flex; flex-direction: column; min-width: 0; }
.vignette__media { font-size: clamp(20px, 7cqw, 46px); font-weight: 700; line-height: 1; letter-spacing: -0.03em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vignette__sous { margin-top: 0.5em; font-size: clamp(12px, 2.6cqw, 17px); line-height: 1.25; color: var(--clair-2); }
.vignette__tortue { flex: none; width: clamp(18px, 5cqw, 32px); height: auto; opacity: 0.95; }
.vignette__bas { display: flex; flex-direction: column; gap: clamp(6px, 1.8cqw, 12px); }
.vignette__frise { display: block; height: clamp(5px, 1.5cqw, 9px); border-radius: 99px; overflow: hidden; }
.vignette__frise svg { display: block; width: 100%; height: 100%; }
.vignette__frise .vignette__piste { fill: rgba(255, 255, 255, 0.1); }
.vignette__frise .a { fill: rgba(255, 255, 255, 0.36); }
.vignette__frise .c { fill: var(--accent-nuit); }
.vignette__pied { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: clamp(11px, 2.2cqw, 14px); color: var(--clair-2); }
.vignette__pied > span:first-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vignette__puce { display: inline-block; width: 0.6em; height: 0.6em; margin-right: 0.5em; border-radius: 50%; background: var(--accent-nuit); vertical-align: 0.05em; }
@container (max-width: 300px) { .vignette__pied > span:first-child { display: none; } }
.lecteur__reduire {
  display: none;
  position: absolute; top: 6px; right: 6px; z-index: 2;
  width: 28px; height: 28px; border: 0; border-radius: 50%;
  background: rgba(0, 0, 0, 0.6); color: #fff;
  align-items: center; justify-content: center; cursor: pointer;
}
.lecteur.flottant {
  position: fixed; inset: auto 12px calc(12px + env(safe-area-inset-bottom)) auto; z-index: 50;
  width: min(56vw, 360px); height: auto; aspect-ratio: 16 / 9;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}
.lecteur.flottant .lecteur__reduire { display: flex; }

.chapitres { display: flex; gap: 4px; }
.chapitre {
  flex: 1 1 0; min-width: 28px;
  display: flex; flex-direction: column; gap: 6px;
  color: var(--clair-2); text-decoration: none;
}
.chapitre:hover, .chapitre[aria-current] { color: var(--clair); }
.chapitre__barre { display: block; height: 4px; border-radius: 2px; background: rgba(255, 255, 255, 0.24); overflow: hidden; }
.chapitre__avance { display: block; width: 0; height: 100%; background: var(--accent-nuit); }
.chapitre__titre { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chapitre[aria-current] .chapitre__titre { font-weight: 600; }
.chapitre__temps { font-size: 12px; color: var(--clair-2); }

.actions { display: flex; flex-wrap: wrap; gap: 8px; }

.programme__titre { margin: 0 0 8px 16px; font-size: 13px; font-weight: 400; color: var(--clair-2); }
.liste-sombre { list-style: none; margin: 0; padding: 0; background: var(--noir-2); border-radius: 12px; overflow: hidden; }
.liste-sombre li + li { border-top: 1px solid var(--noir-trait); }
.liste-sombre a { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 10px 16px; color: var(--clair); text-decoration: none; }
.liste-sombre a:hover { background: rgba(255, 255, 255, 0.06); color: var(--clair); }
.liste-sombre__texte { flex: 1; min-width: 0; font-size: 15px; }
.liste-sombre__temps { font-size: 13px; color: var(--clair-2); }
.liste-sombre .chevron { border-color: #86868b; }
.programme__note { margin: 8px 16px 0; font-size: 13px; color: var(--clair-2); }

.scene__source { margin: 0; font-size: 14px; }
.scene__note { display: block; margin-top: 4px; font-size: 12px; color: var(--clair-2); }
.scene__source a { color: var(--clair); }
.scene__source a:hover { color: var(--accent-nuit); }
.scene__mention { margin: auto 0 0; padding-top: 8px; font-size: 12px; color: var(--clair-2); }

.scene__texte { min-width: 0; padding: 0 16px; }

.barre-outils {
  position: sticky; top: 0; z-index: 5;
  margin: 0 -16px; padding: 10px 16px;
  background: var(--fond-verre);
  -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--trait-2);
}
.barre-outils__ligne { max-width: var(--mesure); margin: 0 auto; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 20px; }
.barre-outils__titre { display: flex; align-items: baseline; gap: 10px; margin-right: auto; }
.barre-outils__titre h2 { margin: 0; font-size: 20px; letter-spacing: -0.015em; font-weight: 600; }
.badge-relue { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; color: var(--vert); }
.badge-relue svg { display: inline-block; }
.barre-outils__etat { max-width: var(--mesure); margin: 6px auto 0; font-size: 13px; color: var(--texte-2); }
.barre-outils__etat:empty { display: none; }

.champ-local { position: relative; flex: 0 1 240px; }
.champ-local svg { position: absolute; left: 11px; top: 10px; color: var(--texte-2); pointer-events: none; }
.champ-local input {
  width: 100%; min-height: 36px; padding: 0 12px 0 34px;
  border: 0; border-radius: 10px;
  background: var(--gris-controle); color: var(--texte);
  font: inherit; font-size: 14px;
  -webkit-appearance: none; appearance: none;
}
.champ-local input::placeholder { color: var(--texte-2); opacity: 1; }

.transcription { max-width: var(--mesure); margin: 0 auto; padding: 32px 0 24px; }

.titre-chapitre {
  margin: 40px 0 8px 16px;
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px;
  font-size: 22px; line-height: 1.2; letter-spacing: -0.015em; font-weight: 600;
  scroll-margin-top: 80px;
}
.transcription > .titre-chapitre:first-child { margin-top: 0; }
.titre-chapitre .num { font-size: 14px; font-weight: 400; color: var(--texte-2); }

.para { display: flex; gap: 16px; padding: 12px 16px; border-radius: 14px; }
.para.actif { background: var(--teinte); }
.horodatage {
  flex: none; align-self: flex-start; width: 52px; padding: 3px 0 0;
  border: 0; background: none; text-align: left;
  font-size: 13px; color: var(--texte-2); cursor: pointer;
}
.horodatage:hover { color: var(--accent); text-decoration: underline; }
.prise--candidat .horodatage { padding-top: 5px; color: var(--accent); }
.para.actif .horodatage { font-weight: 600; color: var(--accent); }

.para__corps { flex: 1; min-width: 0; display: flex; align-items: flex-start; gap: 12px; }
.para__texte { flex: 1; min-width: 0; margin: 0; font-size: 16px; line-height: 1.5; color: var(--texte-2); }
.prise--candidat .para__texte { font-size: 19px; color: var(--texte); }
.locuteur { font-weight: 600; color: var(--texte); }

.ph { scroll-margin-top: 110px; border-radius: 3px; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
.ph.en-cours, .ph:target, .ph.cible { background: var(--teinte-forte); }
.scene.lecteur-actif .ph { cursor: pointer; }

.para__actions { flex: none; display: inline-flex; gap: 2px; opacity: 0; transition: opacity 0.15s ease; }
.para:hover .para__actions, .para:focus-within .para__actions, .para.actif .para__actions { opacity: 1; }

.pastilles { margin: 0 0 12px 84px; display: flex; flex-wrap: wrap; gap: 8px; }
.pastille {
  display: inline-flex; align-items: center; gap: 6px;
  min-height: 32px; padding: 0 12px; border-radius: 980px;
  background: var(--teinte); color: var(--accent);
  font-size: 14px; font-weight: 500; text-decoration: none;
}
.pastille svg { display: inline-block; flex: none; }
.pastille:hover { background: var(--teinte-forte); color: var(--accent); }

.scene.filtre-candidat .prise:not(.prise--candidat) { display: none; }
.masque { display: none !important; }
.vide-local { padding: 0 16px; color: var(--texte-2); }

.scene__texte .pied { margin-top: 40px; }
.scene__texte .pied__ligne { max-width: var(--mesure); margin: 0 auto; }

/* Outils de sélection, message bref */

.selection-outils {
  position: fixed; z-index: 60;
  display: flex; gap: 2px; padding: 4px;
  border-radius: 12px; background: var(--noir-2);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}
.selection-outils[hidden] { display: none; }
.selection-outils button {
  min-height: 36px; padding: 0 12px;
  border: 0; border-radius: 8px; background: transparent;
  color: var(--clair); font-size: 14px; font-weight: 500; cursor: pointer; white-space: nowrap;
}
.selection-outils button:hover { background: rgba(255, 255, 255, 0.12); }

.toast {
  position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom)); z-index: 70;
  transform: translateX(-50%);
  max-width: calc(100vw - 32px);
  padding: 10px 16px; border-radius: 12px;
  background: var(--noir-2); color: var(--clair);
  font-size: 14px; box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}
.toast[hidden] { display: none; }

/* Générateur de visuels */

.visuel {
  width: 100%; max-width: min(980px, calc(100vw - 32px)); max-height: calc(100dvh - 32px);
  padding: 0; border: 0; border-radius: 18px;
  background: var(--fond); color: var(--texte);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
}
.visuel::backdrop { background: rgba(0, 0, 0, 0.5); }
.visuel__cadre { display: flex; flex-direction: column; max-height: calc(100dvh - 32px); margin: 0; }
.visuel__tete { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 12px 12px 20px; border-bottom: 1px solid var(--trait-2); }
.visuel__tete h2 { margin: 0; font-size: 17px; font-weight: 600; }
.visuel__tete .icone { color: var(--texte-2); }
.visuel__corps { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 24px; padding: 20px; overflow: auto; }
.visuel__apercu { min-width: 0; display: flex; align-items: center; justify-content: center; padding: 16px; border-radius: 12px; background: var(--fond-2); }
.visuel__apercu canvas { max-width: 100%; max-height: min(62vh, 600px); width: auto; height: auto; border-radius: 4px; box-shadow: 0 2px 12px rgba(0, 0, 0, 0.18); }
.visuel fieldset { margin: 0 0 16px; padding: 0; border: 0; }
.visuel legend { margin-bottom: 6px; padding: 0; font-size: 13px; font-weight: 600; color: var(--texte-2); }
.choix { display: flex; align-items: center; gap: 10px; min-height: 40px; padding: 0 12px; border-radius: 10px; cursor: pointer; font-size: 15px; }
.choix:has(input:checked) { background: var(--teinte); }
.choix input { margin: 0; accent-color: var(--accent); }
.choix small { margin-left: 4px; font-size: 13px; color: var(--texte-2); }
.visuel__aide { margin: 0 0 12px; font-size: 13px; color: var(--texte-2); }
.visuel__alerte { margin: 0 0 12px; font-size: 14px; color: var(--rouge); }
.visuel__boutons .bouton { width: 100%; min-height: 44px; }

/* --- Grand écran : colonne vidéo fixe, transcription centrée dans la place restante --- */

@media (min-width: 1000px) {
  .scene { display: grid; grid-template-columns: clamp(420px, 38vw, 820px) minmax(0, 1fr); align-items: start; }
  .scene__colonne {
    position: sticky; top: 0;
    height: 100vh; height: 100dvh;
    overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: #48484a transparent;
    padding: 0 32px 24px; gap: 24px;
  }
  .scene__texte { padding: 0 40px; }
  .barre-outils { margin: 0 -40px; padding: 10px 40px; }
}

@media (min-width: 1600px) {
  :root { --mesure: 54rem; }
  .prise--candidat .para__texte { font-size: 20px; }
}

/* --- Petits écrans ------------------------------------------------------- */

@media (max-width: 640px) {
  .conteneur { padding: 0 16px; }
  .bandeau__ligne { gap: 8px 14px; padding-bottom: 12px; }
  .logo__marque { height: 46px; }
  .logo__nom { font-size: 10px; }
  .non-officiel { order: 1; margin-left: auto; }
  .recherche--bandeau ~ .non-officiel { margin-left: auto; }
  .bouton-rond { order: 2; margin-left: 0; }
  .bandeau--compact .bouton-rond { margin-left: auto; }
  .recherche--bandeau { order: 2; flex-basis: 100%; max-width: none; }
  .navigation { order: 3; flex-basis: 100%; gap: 8px 14px; font-size: 13px; }
  .chapitres { overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none; }
  .chapitres::-webkit-scrollbar { display: none; }
  .chapitre { min-width: 96px; scroll-snap-align: start; }
  .hero { padding-top: 48px; padding-bottom: 56px; }
  .section { padding-top: 56px; }
  .recherche--grande .recherche__champ, .recherche--page .recherche__champ { padding-right: 16px; }
  .recherche--grande .bouton, .recherche--page .bouton { display: none; }
  .ligne-intervention { padding: 12px 16px; }
  .ligne-intervention__date { flex-basis: 100%; font-size: 13px; }
  .ligne-intervention .chevron { display: none; }
  .para { gap: 12px; padding: 10px 12px; }
  .horodatage { width: 44px; }
  .prise--candidat .para__texte { font-size: 17px; }
  .para__texte { font-size: 15px; }
  .titre-chapitre { margin-left: 12px; font-size: 20px; }
  .pastilles { margin-left: 68px; }
  .visuel__corps { grid-template-columns: 1fr; padding: 16px; }
  .visuel__apercu canvas { max-height: 44vh; }
  .resultats { gap: 32px; }
  .resultats__programme { position: static; }
}

/* Écrans tactiles : les actions d'un paragraphe apparaissent quand on le touche */
@media (hover: none) {
  .para__actions { display: none; opacity: 1; }
  .para.ouvert .para__actions { display: inline-flex; }
  .para.ouvert .para__corps { flex-wrap: wrap; }
  .para.ouvert .para__actions { width: 100%; justify-content: flex-end; }
  .icone { width: 40px; height: 40px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

@media print {
  .scene__colonne, .barre-outils, .para__actions, .pastilles, .selection-outils, .toast, .pied, .sombre, .evitement { display: none !important; }
  .scene { display: block; }
  .para { padding: 4px 0; }
  .ph.en-cours, .para.actif { background: none; }
}
