/* ============================================================
   POLITUBE — Vidéos
   App de flux vidéo type streaming : rail latéral, carrousel
   « en direct », grille riche, code couleur politique.
   Palette sombre, accent cyan, positionnement coloré.
   ============================================================ */


body.poly {
  background: var(--yt-bg);
  color: var(--yt-text);
  font-family: var(--font-grotesk);
  min-height: 100vh;
}

body.poly ::selection { background: var(--yt-brand); color: #05252a; }
body.poly a { color: inherit; }

/* ---------- Barre supérieure ---------- */

.poly-top {
  position: sticky;
  top: 0;
  z-index: 40;
  height: var(--yt-top-h);
  display: grid;
  grid-template-columns: var(--yt-rail-w) minmax(0, 1fr) auto;
  align-items: center;
  gap: 1.4rem;
  padding: .65rem 1.6rem .65rem 1.9rem;
  background: rgba(9, 12, 19, .92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--yt-line);
}

.poly-brand {
  display: flex;
  align-items: center;
  gap: .55rem;
  font-weight: 700;
  letter-spacing: .34em;
  font-size: 1.02rem;
  color: var(--yt-brand);
  text-transform: uppercase;
}

.poly-brand .dot {
  width: 11px; height: 11px;
  border-radius: 50%;
  background: var(--yt-brand);
  box-shadow: 0 0 12px rgba(55, 196, 214, .8);
}

.poly-top-center {
  display: flex;
  align-items: center;
  gap: 1.4rem;
  min-width: 0;
}

.poly-discovery {
  flex: 1;
  min-width: 0;
  max-width: 620px;
}

.poly-switch {
  display: inline-flex;
  gap: .3rem;
  padding: .28rem;
  background: rgba(255, 255, 255, .04);
  border: 1px solid var(--yt-line);
  border-radius: 999px;
  flex-shrink: 0;
}

.poly-switch a {
  padding: .5rem 1.15rem;
  border-radius: 999px;
  font-size: .84rem;
  font-weight: 600;
  color: var(--yt-muted);
  transition: color .2s, background .2s;
  white-space: nowrap;
}

.poly-switch a.active {
  color: var(--yt-text);
  background: rgba(55, 196, 214, .16);
  box-shadow: inset 0 0 0 1px rgba(55, 196, 214, .5);
}

.poly-search {
  position: relative;
  flex: 1;
  min-width: 0;
  max-width: none;
}

.poly-search input {
  width: 100%;
  height: 44px;
  border-radius: 999px;
  border: 1px solid var(--yt-line-strong);
  background: rgba(255, 255, 255, .03);
  color: var(--yt-text);
  font: inherit;
  font-size: .92rem;
  padding: 0 3rem 0 1.3rem;
  transition: border-color .2s, background .2s;
}

.poly-search input:focus {
  outline: none;
  border-color: rgba(55, 196, 214, .6);
  background: rgba(255, 255, 255, .05);
}

.poly-search input::placeholder { color: var(--yt-faint); }

.poly-search .go {
  position: absolute;
  right: 4px; top: 4px;
  width: 52px; height: 36px;
  border: none;
  border-radius: 999px;
  background: rgba(255, 255, 255, .06);
  color: var(--yt-muted);
  display: grid;
  place-items: center;
}

.poly-search .go:hover { background: rgba(55, 196, 214, .18); color: var(--yt-brand-soft); }

.poly-position-filter {
  display: grid;
  gap: .28rem;
  margin-top: .45rem;
}

.poly-position-options {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .35rem;
}

.poly-position-choice,
.poly-position-all {
  min-height: 28px;
  border: 1px solid var(--yt-line-strong);
  background: rgba(255, 255, 255, .035);
  color: var(--yt-muted);
  font: 600 .75rem var(--font-grotesk);
  letter-spacing: .02em;
  transition: border-color .18s, background .18s, color .18s, box-shadow .18s;
}

.poly-position-choice {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .42rem;
  border-radius: 7px;
}

.poly-position-choice .swatch {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
}

.poly-position-choice.gauche { color: #f17a8a; }
.poly-position-choice.centre { color: var(--pos-centre); }
.poly-position-choice.droite { color: #79aee9; }
.poly-position-choice:hover { background: rgba(255,255,255,.075); color: var(--yt-text); }
.poly-position-choice.gauche.on { border-color: var(--pos-gauche); background: rgba(232,73,95,.2); color: #fff; box-shadow: inset 0 0 0 1px rgba(232,73,95,.28); }
.poly-position-choice.centre.on { border-color: var(--pos-centre); background: rgba(244,241,232,.18); color: #fff; box-shadow: inset 0 0 0 1px rgba(244,241,232,.28); }
.poly-position-choice.droite.on { border-color: var(--pos-droite); background: rgba(74,144,226,.2); color: #dcecff; box-shadow: inset 0 0 0 1px rgba(74,144,226,.28); }
.poly-position-filter button:disabled { cursor: not-allowed; opacity: .48; filter: saturate(.45); }
/* Le filtre peut suivre le repère éditorial provisoire de l’Hémicycle sans
   présenter ce repère comme une publication V2. */
.poly-position-filter.is-unpublished { margin-top: .32rem; }
.poly-position-context {
  color: var(--yt-faint);
  font: 500 .68rem/1.35 var(--font-grotesk);
  letter-spacing: .01em;
  max-width: 30rem;
}
.poly-position-filter.is-provisional .poly-position-context { color: rgba(113, 220, 235, .72); }

.poly-position-all {
  width: 100%;
  min-height: 25px;
  border-radius: 6px;
}
.poly-position-all:hover { color: var(--yt-text); background: rgba(255,255,255,.075); }
.poly-position-all.on { border-color: rgba(55,196,214,.7); background: rgba(55,196,214,.16); color: var(--yt-brand-soft); }

.poly-top-right {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.poly-create {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  height: 40px;
  padding: 0 1.15rem;
  border-radius: 999px;
  border: 1px solid var(--yt-line-strong);
  background: rgba(255, 255, 255, .03);
  color: var(--yt-text);
  font-weight: 600;
  font-size: .86rem;
  transition: background .2s, border-color .2s;
}

.poly-create:hover { background: rgba(255, 255, 255, .07); border-color: var(--yt-brand); }
.poly-create svg { width: 16px; height: 16px; }

.poly-bell {
  position: relative;
  width: 42px; height: 42px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, .03);
  border: 1px solid var(--yt-line);
  color: var(--yt-muted);
}
.poly-bell:hover { color: var(--yt-text); }
.poly-bell .badge {
  position: absolute;
  top: -3px; right: -3px;
  min-width: 18px; height: 18px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--pos-gauche);
  color: #fff;
  font-size: .66rem;
  font-weight: 700;
  display: grid; place-items: center;
  border: 2px solid var(--yt-bg);
}

.poly-avatar {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  padding: .3rem .5rem .3rem .3rem;
  border-radius: 999px;
  border: 1px solid var(--yt-line);
  background: rgba(255, 255, 255, .03);
}
.poly-avatar .pic {
  width: 32px; height: 32px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: linear-gradient(135deg, var(--yt-brand), #2b6fb0);
  color: #04252b;
  font-weight: 700;
  font-size: .78rem;
}
.poly-avatar .chev { color: var(--yt-muted); }

/* ---------- Structure ---------- */

.poly-body {
  display: grid;
  grid-template-columns: var(--yt-rail-w) minmax(0, 1fr);
}

/* ---------- Rail latéral ---------- */

.poly-rail {
  position: sticky;
  top: var(--yt-top-h);
  align-self: start;
  height: calc(100vh - var(--yt-top-h));
  overflow-y: auto;
  padding: 1.1rem .8rem 1.6rem;
  border-right: 1px solid var(--yt-line);
  background: var(--yt-rail);
  scrollbar-width: thin;
}

.poly-rail::-webkit-scrollbar { width: 8px; }
.poly-rail::-webkit-scrollbar-thumb { background: rgba(255,255,255,.08); border-radius: 8px; }

.rail-link {
  display: flex;
  align-items: center;
  gap: .95rem;
  padding: .62rem .8rem;
  border-radius: 10px;
  color: var(--yt-muted);
  font-size: .9rem;
  font-weight: 500;
  transition: background .18s, color .18s;
}

.rail-link svg { width: 20px; height: 20px; flex-shrink: 0; }
.rail-link:hover { background: rgba(255, 255, 255, .05); color: var(--yt-text); }
.rail-link.active { background: rgba(55, 196, 214, .12); color: var(--yt-text); font-weight: 600; }
.rail-link.active svg { color: var(--yt-brand); }

.rail-sep { height: 1px; background: var(--yt-line); margin: .8rem .4rem; }

.rail-box {
  margin: 1rem .3rem 0;
  padding: .95rem 1rem;
  border: 1px solid var(--yt-line);
  border-radius: 12px;
  background: rgba(255, 255, 255, .02);
}

.rail-box .big {
  font-size: .96rem;
  font-weight: 600;
  color: var(--yt-text);
}
.rail-box .big b { color: var(--yt-brand-soft); }

.rail-box ul { list-style: none; margin-top: .6rem; display: grid; gap: .32rem; }
.rail-box li {
  font-size: .78rem;
  color: var(--yt-muted);
  display: flex; align-items: center; gap: .5rem;
}
.rail-box li::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%;
  background: var(--dotc, var(--yt-faint));
}
.rail-box li.n::before { background: var(--pos-gauche); }
.rail-box li.p::before { background: var(--fam-politique); }
.rail-box li.m::before { background: var(--pos-droite); }

.rail-sources {
  margin: .8rem .3rem 0;
  padding: .9rem 1rem;
  border: 1px solid var(--yt-line);
  border-radius: 12px;
  background: rgba(55, 196, 214, .05);
  display: block;
}
.rail-sources .t {
  display: flex; align-items: center; gap: .5rem;
  font-size: .84rem; font-weight: 600; color: var(--yt-text);
}
.rail-sources .t svg { width: 16px; height: 16px; color: var(--yt-brand); }
.rail-sources p { font-size: .76rem; color: var(--yt-muted); margin-top: .4rem; line-height: 1.5; }
.rail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: .35rem .75rem;
  padding: .2rem 1rem .8rem;
}
.rail-meta a {
  color: var(--yt-faint);
  font-size: .7rem;
  text-decoration: none;
}
.rail-meta a:hover,
.rail-meta a:focus-visible { color: var(--yt-brand-soft); }

.rail-foot {
  margin: 1.4rem .7rem 0;
  font-size: .72rem;
  color: var(--yt-faint);
  line-height: 1.7;
}
.rail-foot b { color: var(--yt-brand); letter-spacing: .28em; font-weight: 700; display: block; margin-bottom: .3rem; }

/* ---------- Contenu principal ---------- */

.poly-main {
  padding: 1.5rem clamp(1rem, 2.6vw, 2.2rem) 4rem;
  min-width: 0;
}

.vox-feed-nav { margin: 0 0 1.25rem; display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
.vox-feed-tabs { display: inline-flex; gap: 4px; padding: 4px; background: rgba(255,255,255,.035); border: 1px solid var(--yt-line); border-radius: 14px; }
.vox-feed-tabs button { min-height: 38px; padding: 0 15px; color: var(--yt-muted); background: transparent; border: 1px solid transparent; border-radius: 10px; cursor: pointer; font: 650 .76rem/1 var(--font-grotesk); }
.vox-feed-tabs button:hover { color: var(--yt-text); background: rgba(255,255,255,.05); }
.vox-feed-tabs button.on { color: #06151b; background: var(--yt-brand); border-color: var(--yt-brand); box-shadow: 0 8px 24px rgba(55,196,214,.16); }
.vox-feed-tabs button span { margin-left: 5px; padding: 2px 5px; color: currentColor; border: 1px solid currentColor; border-radius: 999px; font-size: .5rem; letter-spacing: .06em; text-transform: uppercase; opacity: .72; }
#vox-feed-context { margin: 0; max-width: 52ch; color: var(--yt-faint); font-size: .7rem; line-height: 1.45; }
.vox-dashboard { margin: 0 0 1.35rem; padding: 18px 20px; display: grid; grid-template-columns: minmax(250px,1.35fr) minmax(280px,1fr) auto; align-items: center; gap: 20px; overflow: hidden; background: linear-gradient(115deg, rgba(55,196,214,.11), rgba(255,255,255,.025) 48%, rgba(232,73,95,.055)); border: 1px solid rgba(55,196,214,.28); border-radius: 18px; }
.vox-dashboard__eyebrow { color: var(--yt-brand); font-size: .56rem; font-weight: 760; letter-spacing: .15em; text-transform: uppercase; }
.vox-dashboard h2 { margin: 5px 0 4px; color: var(--yt-text); font-size: 1rem; }
.vox-dashboard p { margin: 0; color: var(--yt-muted); font-size: .7rem; line-height: 1.45; }
.vox-dashboard dl { margin: 0; display: grid; grid-template-columns: repeat(3,1fr); border: 1px solid rgba(255,255,255,.08); border-radius: 12px; }
.vox-dashboard dl div { padding: 9px 12px; border-left: 1px solid rgba(255,255,255,.08); }
.vox-dashboard dl div:first-child { border-left: 0; }
.vox-dashboard dt { color: var(--yt-faint); font-size: .5rem; letter-spacing: .06em; text-transform: uppercase; }
.vox-dashboard dd { margin: 4px 0 0; color: var(--yt-text); font-size: 1rem; font-weight: 760; }
.vox-dashboard > a { color: var(--yt-brand-soft); font-size: .66rem; font-weight: 650; text-decoration: none; white-space: nowrap; }
.vox-dashboard > a:hover { text-decoration: underline; text-underline-offset: 3px; }
.vox-empty { grid-column: 1 / -1; min-height: 260px; display: grid; place-items: center; padding: 38px 20px; border: 1px dashed var(--yt-line-strong); border-radius: 18px; text-align: center; }
.vox-empty > div { max-width: 480px; }
.vox-empty b { display: block; margin-bottom: 8px; color: var(--yt-text); font-size: 1.05rem; }
.vox-empty p { margin: 0 0 18px; color: var(--yt-muted); font-size: .78rem; line-height: 1.55; }
.vox-empty a, .vox-empty button { display: inline-grid; place-items: center; min-height: 40px; padding: 0 16px; color: #06151b; background: var(--yt-brand); border: 0; border-radius: 10px; cursor: pointer; font: 700 .72rem var(--font-grotesk); text-decoration: none; }

/* Le statut de qualité du flux appartient au parcours de lecture : il ne doit
   jamais être un calque fixe qui masque une carte, le lecteur ou le bas de
   page sur mobile. Les trois états (réel, observation, indisponible) sont
   alimentés par polyyoutube.js, sans contenu de démonstration. */
.poly-data-status {
  position: static;
  margin: 0 0 1.1rem;
  padding: .65rem .8rem;
  border: 1px solid var(--yt-line);
  border-radius: 10px;
  background: rgba(255,255,255,.025);
  color: var(--yt-muted);
  font-size: .76rem;
  line-height: 1.45;
  text-align: left;
}
.poly-data-status.data-banner-public {
  color: #9fd9e2;
  border-color: rgba(55,196,214,.28);
  background: rgba(55,196,214,.07);
}
.poly-data-status.data-banner-observation {
  color: #ead59a;
  border-color: rgba(230,178,60,.3);
  background: rgba(230,178,60,.07);
}
.poly-data-status a { color: var(--yt-brand); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }

.section-title {
  display: flex;
  align-items: center;
  gap: .7rem;
  font-size: .78rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--yt-muted);
  font-weight: 700;
  margin-bottom: 1rem;
}
.section-title .live-dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--pos-gauche);
  box-shadow: 0 0 0 0 rgba(232, 73, 95, .6);
  animation: pulse-live 1.8s infinite;
}
@keyframes pulse-live {
  0% { box-shadow: 0 0 0 0 rgba(232, 73, 95, .55); }
  70% { box-shadow: 0 0 0 7px rgba(232, 73, 95, 0); }
  100% { box-shadow: 0 0 0 0 rgba(232, 73, 95, 0); }
}
.section-title .spacer { flex: 1; }
.feed-coverage {
  letter-spacing: normal; text-transform: none; color: var(--yt-brand);
  font-size: .72rem; font-weight: 600;
}
.section-title .nav-arrow {
  width: 30px; height: 30px;
  border-radius: 50%;
  border: 1px solid var(--yt-line);
  background: rgba(255,255,255,.03);
  color: var(--yt-muted);
  display: grid; place-items: center;
}
.section-title .nav-arrow:hover { color: var(--yt-text); border-color: var(--yt-brand); }

/* carrousel live */
.live-strip {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(255px, 1fr);
  gap: 1.1rem;
  overflow-x: auto;
  padding-bottom: .7rem;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, .14) transparent;
}
.live-strip::-webkit-scrollbar { height: 6px; }
.live-strip::-webkit-scrollbar-track { background: transparent; }
.live-strip::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .12); border-radius: 8px; }
.live-strip::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, .22); }

.live-card { scroll-snap-align: start; cursor: pointer; }
.live-card:focus-visible { outline: none; }
.live-card:focus-visible .live-thumb { box-shadow: 0 0 0 3px var(--yt-brand); }

.live-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--yt-radius);
  overflow: hidden;
  background: #0d1420;
  border: 1px solid var(--yt-line);
}
.live-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.live-card:hover .live-thumb img { transform: scale(1.05); }

/* thumbnail auto-généré */
.poly-thumb-bg {
  position: absolute; inset: 0;
  display: grid; place-items: center;
  overflow: hidden;
}
.poly-thumb-word {
  font-family: var(--font-grotesk);
  font-weight: 700;
  font-size: clamp(1.1rem, 2.4vw, 1.7rem);
  letter-spacing: .22em;
  color: rgba(255, 255, 255, .13);
  text-transform: uppercase;
  user-select: none;
}
.poly-thumb-play {
  position: absolute;
  width: 46px; height: 46px;
  border-radius: 50%;
  background: rgba(10, 14, 22, .55);
  border: 1.5px solid rgba(255, 255, 255, .5);
  color: #fff;
  display: grid; place-items: center;
  font-size: .8rem;
  padding-left: 3px;
  opacity: 0;
  transition: opacity .25s, transform .25s;
  transform: scale(.85);
}
.vcard:hover .poly-thumb-play,
.live-card:hover .poly-thumb-play { opacity: 1; transform: scale(1); }
.live-thumb::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(6,9,15,.55));
}

.badge-live {
  position: absolute; top: .6rem; left: .6rem; z-index: 2;
  display: inline-flex; align-items: center; gap: .35rem;
  background: var(--pos-gauche);
  color: #fff;
  font-size: .64rem; font-weight: 700; letter-spacing: .1em;
  padding: .28rem .55rem; border-radius: 6px;
  text-transform: uppercase;
}
.badge-viewers {
  position: absolute; top: .6rem; right: .6rem; z-index: 2;
  display: inline-flex; align-items: center; gap: .3rem;
  background: rgba(6, 9, 15, .82);
  color: #fff;
  font-size: .68rem; font-weight: 600;
  padding: .24rem .5rem; border-radius: 6px;
}
.badge-viewers svg { width: 12px; height: 12px; }

.live-copy { padding: .7rem .1rem 0; }
.live-copy h3 {
  font-size: .92rem; font-weight: 600; line-height: 1.3;
  display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden;
}
.live-chan {
  display: flex; align-items: center; gap: .5rem;
  margin-top: .5rem;
  font-size: .8rem; color: var(--yt-muted);
}

/* avatar de chaîne */
.chan-pic {
  width: 26px; height: 26px; border-radius: 50%; flex-shrink: 0;
  display: grid; place-items: center;
  font-size: .64rem; font-weight: 700; color: #fff;
  background: #26324a;
  overflow: hidden;
}
.chan-pic img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- Barre de filtres ---------- */

.filter-bar {
  display: flex;
  align-items: center;
  gap: .5rem;
  flex-wrap: wrap;
  margin: 1.8rem 0 1.3rem;
  padding-bottom: .2rem;
}

.chip {
  height: 34px;
  padding: 0 .95rem;
  border-radius: 999px;
  border: 1px solid var(--yt-line-strong);
  background: rgba(255, 255, 255, .04);
  color: var(--yt-text);
  font-size: .82rem;
  font-weight: 500;
  display: inline-flex; align-items: center; gap: .4rem;
  transition: background .18s, border-color .18s, color .18s;
  white-space: nowrap;
}
.chip:hover { background: rgba(255, 255, 255, .09); }
.chip.on { background: var(--yt-text); color: #0a0e16; border-color: var(--yt-text); font-weight: 600; }
.chip.on.tout { background: var(--yt-brand); border-color: var(--yt-brand); color: #04252b; }

.chip .swatch { width: 8px; height: 8px; border-radius: 50%; }
.chip.pos-gauche .swatch { background: var(--pos-gauche); }
.chip.pos-centre .swatch { background: var(--pos-centre); }
.chip.pos-droite .swatch { background: var(--pos-droite); }
.chip.pos-gauche.on { background: var(--pos-gauche); border-color: var(--pos-gauche); color: #fff; }
.chip.pos-centre.on { background: var(--pos-centre); border-color: var(--pos-centre); color: #241a02; }
.chip.pos-droite.on { background: var(--pos-droite); border-color: var(--pos-droite); color: #fff; }
.chip.pos-gauche.on .swatch,
.chip.pos-centre.on .swatch,
.chip.pos-droite.on .swatch { background: currentColor; }

.filter-sep { width: 1px; height: 22px; background: var(--yt-line-strong); margin: 0 .3rem; }
.filter-spacer { flex: 1; min-width: 20px; }
.poly-result-count { color: var(--yt-brand); font-size: .76rem; font-weight: 600; white-space: nowrap; }

.sort-btn {
  display: inline-flex; align-items: center; gap: .4rem;
  height: 34px; padding: 0 .9rem;
  border-radius: 8px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--yt-muted);
  font-size: .82rem; font-weight: 500;
}
.sort-btn:hover { color: var(--yt-text); background: rgba(255,255,255,.05); }
.sort-btn svg { width: 15px; height: 15px; }

.view-toggle { display: inline-flex; gap: .2rem; }
.view-toggle button {
  width: 34px; height: 34px;
  border-radius: 8px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--yt-faint);
  display: grid; place-items: center;
}
.view-toggle button.on { color: var(--yt-text); background: rgba(255,255,255,.07); }
.view-toggle svg { width: 16px; height: 16px; }

/* ---------- Grille de vidéos ---------- */

.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(272px, 1fr));
  gap: 1.5rem 1.2rem;
}

.poly-load-more {
  display: block;
  margin: 1.5rem auto 4rem;
  padding: .8rem 1.3rem;
  border: 1px solid rgba(113,220,235,.35);
  border-radius: 999px;
  color: var(--yt-brand);
  background: rgba(20,35,48,.72);
  font: 600 .82rem/1 "Space Grotesk", sans-serif;
  cursor: pointer;
}
.poly-load-more:hover { color: #fff; border-color: var(--yt-brand); }
.poly-load-more[hidden] { display: none; }

.vcard { cursor: pointer; position: relative; }
.vcard:focus-visible { outline: none; }
.vcard:focus-visible .vthumb { box-shadow: 0 0 0 3px var(--yt-brand); }

.vthumb {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--yt-radius);
  overflow: hidden;
  background: #0d1420;
  border: 1px solid var(--yt-line);
}
.vthumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.vcard:hover .vthumb img { transform: scale(1.05); }
.vduration {
  position: absolute; bottom: .5rem; right: .5rem;
  background: rgba(6, 9, 15, .86);
  color: #fff; font-size: .72rem; font-weight: 600;
  padding: .16rem .4rem; border-radius: 5px;
}

/* Vidéo apparue en temps réel (bandeau SSE → insertion sans reload) */
.vbadge-new {
  position: absolute; top: .5rem; left: .5rem;
  background: var(--yt-brand, #12b3c6); color: #04121a;
  font-size: .68rem; font-weight: 700; letter-spacing: .02em; text-transform: uppercase;
  padding: .18rem .46rem; border-radius: 5px;
  box-shadow: 0 2px 8px rgba(4, 18, 26, .4);
}
.vcard--new .vthumb { box-shadow: 0 0 0 2px var(--yt-brand, #12b3c6); }
.vcard--new { animation: vcard-rt-in .5s ease both; }
@keyframes vcard-rt-in {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) { .vcard--new { animation: none; } }

.vbody { padding: .75rem .15rem 0; display: flex; gap: .7rem; }
.vbody .chan-pic { width: 34px; height: 34px; margin-top: .1rem; }
.vmeta { min-width: 0; flex: 1; }
.vtitle {
  font-size: .95rem; font-weight: 600; line-height: 1.32;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.vchan {
  display: flex; align-items: center; gap: .35rem;
  margin-top: .4rem; font-size: .82rem; color: var(--yt-muted);
}
.vchan .verified { width: 13px; height: 13px; color: var(--yt-brand); flex-shrink: 0; }
.vsub { margin-top: .15rem; font-size: .8rem; color: var(--yt-faint); }

.vtags { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .55rem; }

.tag-pos, .tag-cat {
  font-size: .68rem; font-weight: 600;
  padding: .2rem .5rem; border-radius: 6px;
  letter-spacing: .02em;
}
.tag-pos.gauche { color: var(--pos-gauche); background: rgba(232, 73, 95, .13); box-shadow: inset 0 0 0 1px rgba(232, 73, 95, .35); }
.tag-pos.centre { color: var(--pos-centre); background: rgba(244, 241, 232, .09); box-shadow: inset 0 0 0 1px rgba(244, 241, 232, .32); }
.tag-pos.droite { color: var(--pos-droite); background: rgba(74, 144, 226, .14); box-shadow: inset 0 0 0 1px rgba(74, 144, 226, .38); }
.tag-pos.indep  { color: var(--pos-indep); background: rgba(154, 166, 184, .12); box-shadow: inset 0 0 0 1px rgba(154, 166, 184, .3); }
.tag-pos.unpublished { color: #9fd9e2; background: rgba(55, 196, 214, .1); box-shadow: inset 0 0 0 1px rgba(55, 196, 214, .28); }
.tag-cat { color: var(--yt-muted); background: rgba(255,255,255,.05); box-shadow: inset 0 0 0 1px var(--yt-line-strong); }

/* carte étendue (sélectionnée) */
.vcard.expanded .vthumb { box-shadow: 0 0 0 2px var(--yt-brand); }
.vextra {
  display: none;
  margin: .7rem .15rem 0;
  padding-top: .7rem;
  border-top: 1px solid var(--yt-line);
  gap: 1.1rem;
  font-size: .78rem;
  color: var(--yt-muted);
}
.vcard.expanded .vextra { display: flex; }
.vextra .x { display: inline-flex; align-items: center; gap: .35rem; }
.vextra .x:hover { color: var(--yt-text); }
.vextra svg { width: 14px; height: 14px; }
.vextra .x.src { color: var(--yt-brand-soft); }

/* liste (toggle) */
.video-grid.list { grid-template-columns: 1fr; gap: 1rem; }
.video-grid.list .vcard { display: grid; grid-template-columns: 300px 1fr; gap: 1rem; }
.video-grid.list .vbody { padding-top: 0; }

/* ---------- Responsive ---------- */

@media (max-width: 1180px) {
  :root { --yt-rail-w: 72px; }
  .poly-rail .rail-link span,
  .poly-rail .rail-box,
  .poly-rail .rail-sources,
  .poly-rail .rail-foot { display: none; }
  .poly-rail .rail-link { justify-content: center; padding: .7rem; }
  .poly-brand span { display: none; }
}

/* bouton hamburger (mobile) — injecté par account.js */
.poly-menu { display: none; width: 40px; height: 40px; flex: none; border-radius: 11px; border: 1px solid var(--yt-line-strong); background: rgba(255, 255, 255, .04); color: var(--yt-text); place-items: center; cursor: pointer; }
.poly-menu svg { width: 20px; height: 20px; }
.poly-scrim { position: fixed; inset: 0; z-index: 190; background: rgba(4, 7, 12, .6); backdrop-filter: blur(2px); opacity: 0; pointer-events: none; transition: opacity .28s ease; }
body.rail-open .poly-scrim { opacity: 1; pointer-events: auto; }

@media (max-width: 860px) {
  .poly-top {
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr) auto;
    grid-template-areas:
      "menu search account"
      "positions positions positions";
    align-items: center;
    gap: .45rem .55rem;
    height: auto;
    min-height: 60px;
    padding: .5rem .8rem .55rem;
  }
  .poly-menu { display: inline-grid; grid-area: menu; }
  .poly-brand { display: none; }
  .poly-switch { display: none; }
  .poly-top-center,
  .poly-discovery { display: contents; }
  .poly-search { grid-area: search; max-width: none; }
  .poly-position-filter { grid-area: positions; margin-top: 0; }
  .poly-position-context { display: none; }
  .poly-top-right { grid-area: account; }
  .poly-body { grid-template-columns: 1fr; }
  /* le rail devient un tiroir latéral */
  .poly-rail {
    position: fixed; top: 0; bottom: 0; left: 0; z-index: 200; width: min(300px, 86vw); height: auto;
    display: flex; flex-direction: column; align-items: stretch;
    transform: translateX(-100%); transition: transform .28s cubic-bezier(.22, .61, .36, 1);
    background: var(--yt-rail); border-right: 1px solid var(--yt-line-strong); box-shadow: 24px 0 60px rgba(0, 0, 0, .5);
    padding: 70px .7rem 1.4rem; overflow-y: auto;
  }
  body.rail-open .poly-rail { transform: none; }
  body.rail-open { overflow: hidden; }
  /* tiroir : libellés complets réaffichés */
  .poly-rail .rail-link span { display: inline; }
  .poly-rail .rail-box, .poly-rail .rail-sources, .poly-rail .rail-foot { display: block; }
  .poly-rail .rail-link { justify-content: flex-start; padding: .72rem 1.1rem; }
  .vox-dashboard { grid-template-columns: 1fr; }
  .vox-dashboard > a { white-space: normal; }
}

@media (max-width: 720px) {
  .video-grid { grid-template-columns: 1fr 1fr; gap: 1rem .8rem; }
  .video-grid.list .vcard { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .poly-create, .poly-bell { display: none; }
}

@media (max-width: 460px) {
  .video-grid { grid-template-columns: 1fr; }
  .vox-feed-nav { align-items: stretch; }
  .vox-feed-tabs { width: 100%; display: grid; grid-template-columns: 1fr 1fr; }
  .vox-feed-tabs button:first-child { grid-column: 1 / -1; }
  .vox-feed-tabs button { padding: 0 8px; }
  .vox-dashboard dl { grid-template-columns: 1fr; }
  .vox-dashboard dl div, .vox-dashboard dl div:first-child { border-left: 0; border-top: 1px solid rgba(255,255,255,.08); }
  .vox-dashboard dl div:first-child { border-top: 0; }
}

/* ============================================================
   ANNUAIRES (newseurs / politiques / médias) — DA app + logos
   ============================================================ */

.dir-head { margin: .4rem 0 1.3rem; }
.dir-head .kicker { font-size:.72rem; letter-spacing:.26em; text-transform:uppercase; color:var(--yt-muted); font-weight:700; }
.dir-head h1 { font-size:clamp(1.7rem,3.4vw,2.6rem); font-weight:700; margin:.35rem 0 .5rem; }
.dir-head h1 em { font-style:normal; }
.fam-newseur-accent { color:var(--fam-newseur); }
.fam-politique-accent { color:var(--fam-politique); }
.fam-media-accent { color:var(--fam-media); }
.pos-gauche-accent { color:var(--pos-gauche); }
.pos-droite-accent { color:var(--pos-droite); }
.dir-filters .chip.tout.on { pointer-events:none; }
.dir-head p { max-width:64ch; color:var(--yt-muted); line-height:1.6; font-size:.95rem; }

/* barre de filtres positionnement (chips) */
.dir-filters { display:flex; align-items:center; gap:.5rem; flex-wrap:wrap; margin:1.1rem 0 1.4rem; }
.dir-filters .count { margin-left:auto; color:var(--yt-faint); font-size:.82rem; }
.sr-select { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); }
.dir-status { max-width:72ch; margin:-.55rem 0 1.25rem; color:#9ccad3; font-size:.82rem; line-height:1.55; }
.dir-filters .chip:disabled { cursor:not-allowed; opacity:.52; filter:saturate(.55); }

.chan-grid {
  display:grid;
  grid-template-columns:repeat(auto-fill, minmax(300px, 1fr));
  gap:1.1rem;
}

.chan-card {
  background:var(--yt-card);
  border:1px solid var(--yt-line);
  border-radius:16px;
  padding:1.1rem 1.15rem 1rem;
  display:flex; flex-direction:column; gap:.7rem;
  transition:transform .2s, border-color .2s, background .2s;
  cursor:pointer;
}
.chan-card:hover { transform:translateY(-3px); background:var(--yt-card-2); border-color:var(--yt-line-strong); }

.chan-head { display:flex; align-items:center; gap:.8rem; }
.chan-logo {
  width:52px; height:52px; border-radius:50%; flex-shrink:0;
  overflow:hidden; display:grid; place-items:center;
  background:#1a2233; box-shadow:0 0 0 2px var(--ring, rgba(255,255,255,.12));
  position:relative;
}
.fam-newseur .chan-logo { --ring:var(--fam-newseur); }
.fam-politique .chan-logo { --ring:var(--fam-politique); }
.fam-media .chan-logo { --ring:var(--fam-media); }
.chan-logo img { width:100%; height:100%; object-fit:cover; }
.chan-logo.is-fallback::after {
  content:attr(data-ini);
  font:700 1.05rem var(--font-grotesk); color:#fff;
  background:linear-gradient(135deg, var(--ring), rgba(0,0,0,.25));
  position:absolute; inset:0; display:grid; place-items:center;
}
.chan-id { min-width:0; }
.chan-id h3 { font-size:1rem; font-weight:600; line-height:1.25; display:flex; align-items:center; gap:.3rem; }
.chan-verified { width:14px; height:14px; color:var(--yt-brand); flex-shrink:0; }
.chan-sub { font-size:.82rem; color:var(--yt-faint); margin-top:.15rem; }

.chan-badges { display:flex; gap:.4rem; flex-wrap:wrap; }
.chan-tagline { font-size:.88rem; color:var(--yt-muted); line-height:1.5; }
.chan-tags { display:flex; gap:.35rem; flex-wrap:wrap; }
.chan-tags span {
  font-size:.68rem; color:var(--yt-faint); background:rgba(255,255,255,.04);
  border:1px solid var(--yt-line); border-radius:6px; padding:.16rem .5rem;
}
.chan-actions { display:flex; gap:.6rem; margin-top:auto; padding-top:.3rem; }
.chan-yt {
  flex:1; text-align:center; font-size:.82rem; font-weight:600;
  padding:.6rem; border-radius:10px; color:#04252b;
  background:var(--ringbtn, var(--yt-brand));
}
.fam-newseur .chan-yt { background:var(--fam-newseur); color:#2a0a06; }
.fam-politique .chan-yt { background:var(--fam-politique); color:#160f2b; }
.fam-media .chan-yt { background:var(--fam-media); color:#04252b; }
.chan-yt:hover { filter:brightness(1.1); }
.chan-fiche {
  padding:.6rem 1rem; border-radius:10px; font-size:.82rem; font-weight:600;
  background:transparent; color:var(--yt-text); border:1px solid var(--yt-line-strong);
}
.chan-fiche:hover { background:rgba(255,255,255,.06); }

@media (max-width:520px){ .chan-grid{ grid-template-columns:1fr; } }

body.poly.dir { --yt-top-h: 66px; }

/* ---------- Fiche (modale) sur les annuaires — DA app ---------- */
.modal.modal-m {
  background: linear-gradient(165deg, #141b29, #0d131e);
  border: 1px solid var(--yt-line-strong);
  border-left: 3px solid var(--acc, var(--fam-media));
  border-radius: 18px;
  padding: 1.7rem 1.8rem 1.6rem;
  box-shadow: 0 30px 80px rgba(0,0,0,.6);
  color: var(--yt-text);
  font-family: var(--font-grotesk);
  scrollbar-width: thin;
}
.modal.modal-m.modal-n { --acc: var(--fam-newseur); }
.modal.modal-m.modal-p { --acc: var(--fam-politique); }
.modal.modal-m::-webkit-scrollbar { width: 7px; }
.modal.modal-m::-webkit-scrollbar-thumb { background: rgba(255,255,255,.14); border-radius: 8px; }
.modal-m .close { color: var(--yt-muted); }
.modal-m .close:hover { color: #fff; }

.media-modal-kicker { font-size: .7rem; letter-spacing: .22em; text-transform: uppercase; color: var(--acc); font-weight: 700; }
.modal-m #modal-title { font-size: 1.7rem; font-weight: 700; margin: .5rem 0 .25rem; line-height: 1.1; }
.modal-m .tagline { color: var(--acc); font-size: .95rem; font-weight: 600; }
.media-modal-meta { display: flex; gap: 2rem; margin: 1.3rem 0; padding: 1rem 0; border-top: 1px solid var(--yt-line); border-bottom: 1px solid var(--yt-line); }
.media-modal-meta div { display: grid; gap: .2rem; }
.media-modal-meta span { font-size: .64rem; letter-spacing: .12em; text-transform: uppercase; color: var(--yt-faint); }
.media-modal-meta b { font-size: 1.15rem; color: #fff; }
.modal-m .media-tags { display: flex; flex-wrap: wrap; gap: .4rem; margin: .4rem 0 1rem; }
.modal-m .media-tags span { font-size: .68rem; color: var(--yt-muted); background: rgba(255,255,255,.05); border: 1px solid var(--yt-line); border-radius: 6px; padding: .2rem .55rem; }
.modal-m h4 { font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; color: var(--acc); margin: 1.2rem 0 .4rem; }
.modal-m p { color: var(--yt-muted); line-height: 1.6; font-size: .92rem; }
.media-modal-actions { display: flex; gap: .7rem; margin-top: 1.6rem; flex-wrap: wrap; }
.media-primary { padding: .75rem 1.4rem; border-radius: 10px; font-weight: 600; font-size: .88rem; background: var(--acc); color: #06121a; }
.media-primary:hover { filter: brightness(1.1); }
.media-source { padding: .75rem 1.2rem; border-radius: 10px; font-weight: 600; font-size: .88rem; border: 1px solid var(--yt-line-strong); color: var(--yt-text); }
.media-source:hover { background: rgba(255,255,255,.06); }

/* ============================================================
   VRAIES MINIATURES + LECTEUR INTÉGRÉ (Vidéos)
   ============================================================ */
.poly-thumb-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .45s cubic-bezier(.2,.7,.2,1); }
.vcard:hover .poly-thumb-img, .live-card:hover .poly-thumb-img { transform: scale(1.045); }

/* bouton lecture au survol */
.poly-play {
  position: absolute; inset: 0; display: grid; place-items: center; z-index: 2;
  opacity: 0; transition: opacity .25s ease;
  background: radial-gradient(60% 60% at 50% 50%, rgba(6,9,14,.35), transparent 75%);
}
.poly-play svg { width: 30px; height: 30px; color: #fff; padding: 14px; border-radius: 50%;
  background: rgba(10,14,22,.62); box-shadow: 0 6px 22px rgba(0,0,0,.5), inset 0 0 0 1px rgba(255,255,255,.18);
  backdrop-filter: blur(4px); transform: scale(.82); transition: transform .28s cubic-bezier(.2,.9,.3,1.3); box-sizing: content-box; }
.is-playable { cursor: pointer; }
.is-playable:hover .poly-play { opacity: 1; }
.is-playable:hover .poly-play svg { transform: scale(1); }

.chan-pic.has-img { background: none !important; }
.chan-pic.has-img img { width: 100%; height: 100%; object-fit: cover; }
.section-title.is-featured .live-dot { background: var(--yt-brand); box-shadow: 0 0 10px rgba(55,196,214,.7); }

/* squelettes de chargement */
.vcard-skel .sk-thumb { aspect-ratio: 16/9; border-radius: 12px; }
.live-skel { flex: 0 0 300px; }
.live-skel .sk-thumb { aspect-ratio: 16/9; border-radius: 12px; }
.sk-thumb, .sk-line { background: linear-gradient(90deg, rgba(255,255,255,.03) 25%, rgba(255,255,255,.07) 50%, rgba(255,255,255,.03) 75%); background-size: 200% 100%; animation: skShimmer 1.3s infinite; }
.sk-line { height: 12px; border-radius: 6px; margin-top: 12px; }
.sk-line.short { width: 55%; margin-top: 8px; }
@keyframes skShimmer { to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .sk-thumb, .sk-line { animation: none; } }
