/* 15/10 (patron : « la fenêtre des lives est moche, austère, pas design ») — refonte : noir profond, or Sight, l'œil du logo.
   Chargée par live.py (css_lien) sur /live, /live/<id>, le bandeau des lives du fil et du profil. Les règles de base restent dans live.js. */
.lvx [hidden], .lvx-w [hidden] { display: none !important; }
.lvi { flex: none; vertical-align: -3px; }
/* pictogrammes de la charte (icones.py) : même rendu que charte.css, au cas où elle n'est pas chargée sur la page */
svg.ic.lvi { fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; overflow: visible; }
svg.ic.lvi .a { stroke: var(--ic-or, #d4a63a); } svg.ic.lvi .af { fill: var(--ic-or, #d4a63a); stroke: none; }

/* ---------- pastille « en direct » ---------- */
.lvx-pulse { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #ff3b5c; margin-right: 7px; vertical-align: 1px;
  box-shadow: 0 0 0 0 rgba(255, 59, 92, .7); animation: lvxPulse 1.6s infinite; }
@keyframes lvxPulse { 0% { box-shadow: 0 0 0 0 rgba(255, 59, 92, .65); } 70% { box-shadow: 0 0 0 9px rgba(255, 59, 92, 0); } 100% { box-shadow: 0 0 0 0 rgba(255, 59, 92, 0); } }
.lv-tag { display: inline-flex !important; align-items: center; gap: 5px; font: 700 11.5px/1 system-ui, sans-serif !important; letter-spacing: .06em; padding: 5px 9px !important; border-radius: 999px !important; }
.lv-tag.direct { background: linear-gradient(90deg, #ff3b5c, #ff6a3d) !important; color: #fff !important; animation: none !important; box-shadow: 0 4px 14px rgba(255, 59, 92, .35); }
.lv-tag.direct .lvx-pulse { background: #fff; width: 6px; height: 6px; margin-right: 2px; }
.lv-tag.prog { background: rgba(247, 201, 72, .14) !important; color: var(--gold) !important; border: 1px solid rgba(247, 201, 72, .35); }
.lv-tag.fini { background: rgba(138, 149, 168, .14) !important; color: var(--muted) !important; }

/* ---------- héros ---------- */
.lvx { display: flex; flex-direction: column; gap: 18px; }
.lvx-hero { position: relative; overflow: hidden; display: grid; grid-template-columns: 1.1fr .9fr; gap: 24px; align-items: center; padding: 34px 34px 30px;
  border-radius: 22px; border: 1px solid rgba(247, 201, 72, .22);
  background: radial-gradient(120% 140% at 0% 0%, rgba(247, 201, 72, .16), transparent 55%), radial-gradient(90% 120% at 100% 100%, rgba(255, 59, 92, .14), transparent 60%), linear-gradient(160deg, #0b1020, #03060d 70%);
  box-shadow: 0 20px 60px rgba(0, 0, 0, .45), inset 0 1px 0 rgba(255, 255, 255, .04); animation: lvxIn .5s ease-out both; }
.lvx-hero::after { content: ""; position: absolute; inset: 0; pointer-events: none; background-image: linear-gradient(rgba(255, 255, 255, .025) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .025) 1px, transparent 1px);
  background-size: 34px 34px; mask-image: linear-gradient(90deg, #000, transparent 75%); -webkit-mask-image: linear-gradient(90deg, #000, transparent 75%); }
@keyframes lvxIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.lvx-hero-tx { position: relative; z-index: 1; }
.lvx-kick { display: inline-flex; align-items: center; font: 800 12px system-ui, sans-serif; letter-spacing: .18em; color: #ff8396; background: rgba(255, 59, 92, .1);
  border: 1px solid rgba(255, 59, 92, .3); padding: 6px 12px; border-radius: 999px; }
.lvx-hero h1 { margin: 14px 0 8px; font-size: clamp(26px, 3.2vw, 40px); line-height: 1.08; letter-spacing: -.02em;
  background: linear-gradient(180deg, #fff, #d9dfeb); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lvx-hero p { margin: 0 0 20px; color: #aab4c6; font-size: 16px; }
.lvx-cta { display: flex; flex-wrap: wrap; gap: 10px; }
.lvx-big { min-height: 46px !important; padding: 10px 20px !important; font-size: 15px !important; border-radius: 12px !important; transition: transform .15s, box-shadow .15s; }
.lvx-big:hover { transform: translateY(-1px); text-decoration: none; }
.lvx-big.pri { box-shadow: 0 8px 24px rgba(247, 201, 72, .28); }
.lvx-chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 20px 0 0; padding: 0; color: #8a95a8; font-size: 13px; }
.lvx-chips li { display: inline-flex; align-items: center; gap: 6px; }
.lvx-chips .lvi { color: var(--gold2); }

/* écran décoratif */
.lvx-hero-art { position: relative; z-index: 1; display: flex; justify-content: center; }
.lvx-screen { position: relative; width: min(100%, 420px); aspect-ratio: 16 / 10; border-radius: 16px; overflow: hidden; border: 1px solid #222c44;
  background: radial-gradient(80% 90% at 70% 20%, rgba(47, 127, 216, .18), transparent 60%), linear-gradient(180deg, #0a1122, #050912);
  box-shadow: 0 30px 70px rgba(0, 0, 0, .6), 0 0 0 6px rgba(255, 255, 255, .02); transform: perspective(900px) rotateY(-8deg) rotateX(3deg); animation: lvxFlot 6s ease-in-out infinite; }
@keyframes lvxFlot { 50% { transform: perspective(900px) rotateY(-6deg) rotateX(2deg) translateY(-6px); } }
.lvx-screen > .lv-tag { position: absolute; left: 12px; top: 12px; z-index: 2; }
.lvx-chart { position: absolute; left: 8%; right: 30%; top: 22%; bottom: 14%; display: flex; align-items: stretch; gap: 7%; }
.lvx-chart i { position: relative; flex: 1; }
.lvx-chart i::before { content: ""; position: absolute; left: 0; right: 0; top: var(--y); height: var(--h); border-radius: 3px; background: linear-gradient(180deg, #2be3a9, #17a57a); }
.lvx-chart i::after { content: ""; position: absolute; left: 50%; width: 2px; margin-left: -1px; top: calc(var(--y) - 6%); height: calc(var(--h) + 12%); background: #2be3a9; opacity: .55; }
.lvx-chart i.r::before { background: linear-gradient(180deg, #ff6b81, #d9435c); }
.lvx-chart i.r::after { background: #ff6b81; }
.lvx-eye { position: absolute; right: 12px; bottom: 12px; width: 74px; height: 74px; border-radius: 50%; overflow: hidden; border: 2px solid #d4a63a; box-shadow: 0 0 24px rgba(247, 201, 72, .35); background: #000; }
.lvx-eye img { width: 100%; height: 100%; object-fit: cover; }
.lvx-bulles { position: absolute; right: 12px; top: 14px; width: 26%; display: flex; flex-direction: column; gap: 6px; }
.lvx-bulles i { height: 9px; border-radius: 6px; background: rgba(255, 255, 255, .1); }
.lvx-bulles i:nth-child(1) { width: 90%; } .lvx-bulles i:nth-child(2) { width: 70%; background: rgba(247, 201, 72, .3); } .lvx-bulles i:nth-child(3) { width: 82%; }

/* ---------- sections + grilles de vignettes ---------- */
.lvx > .card { margin: 0 !important; }
.lvx-sec { border-radius: 20px !important; padding: 18px 20px 20px !important; }
.lvx-sec-hd { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin: 2px 2px 10px; }
.lvx-sec-hd h2, .lvx-st-hd h2 { display: inline-flex; align-items: center; gap: 8px; margin: 0; font-size: 19px; }
.lvx-st-hd h2 .lvi { color: var(--gold2); }
.lvx-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.lvx-grid-s { grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); }
.lvx-vide { grid-column: 1 / -1; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; padding: 30px 18px; border-radius: 16px;
  border: 1px dashed rgba(247, 201, 72, .3); background: linear-gradient(180deg, rgba(247, 201, 72, .05), transparent); }
.lvx-vide > .lvi { color: #ff6a7f; width: 34px; height: 34px; }
.lvx-vide b { font-size: 16px; }
.lvx-vide .btn { margin-top: 6px; }

/* vignette 16:9 (aussi dans le bandeau du fil / du profil : .lv-strip) */
.lv-card.lvx-card { position: relative; display: flex !important; flex-direction: column; justify-content: flex-end; gap: 0 !important; padding: 0 !important;
  aspect-ratio: 16 / 9; min-height: 0; border-radius: 14px !important; overflow: hidden; border: 1px solid #222c44 !important; color: #fff !important; text-decoration: none;
  background: linear-gradient(160deg, #101a33, #060a14) !important; transition: transform .18s ease, box-shadow .18s ease, border-color .18s; }
.lv-strip .lv-card.lvx-card { width: 260px; }
.lvx-grid .lv-card.lvx-card { width: auto; }
.lv-card.lvx-card:hover { transform: translateY(-3px); box-shadow: 0 14px 34px rgba(0, 0, 0, .5); border-color: rgba(247, 201, 72, .5) !important; }
.lv-card.lvx-card.direct { border-color: rgba(255, 59, 92, .55) !important; background: radial-gradient(90% 90% at 80% 10%, rgba(255, 59, 92, .28), transparent 60%), linear-gradient(160deg, #1a0f1c, #070a14) !important; }
.lv-card.lvx-card.prog { background: radial-gradient(90% 90% at 80% 10%, rgba(247, 201, 72, .2), transparent 60%), linear-gradient(160deg, #141a2c, #070a14) !important; }
.lvx-poster { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.lvx-poster { padding-bottom: 22%; }
.lvx-poster-ic { display: grid; place-items: center; width: 50px; height: 50px; border-radius: 50%; color: rgba(247, 201, 72, .85); background: rgba(0, 0, 0, .35);
  border: 1px solid rgba(247, 201, 72, .35); position: relative; z-index: 1; transition: transform .18s; }
.lv-card.direct .lvx-poster-ic { color: #ff8396; border-color: rgba(255, 59, 92, .45); }
.lv-card.lvx-card:hover .lvx-poster-ic { transform: scale(1.08); }
.lvx-bars { position: absolute; left: 0; right: 0; bottom: 0; height: 62%; display: flex; align-items: flex-end; gap: 6%; padding: 0 6%; opacity: .16; }
.lvx-bars i { flex: 1; background: linear-gradient(180deg, #f7c948, transparent); border-radius: 2px 2px 0 0; }
.lvx-bars i:nth-child(1) { height: 35%; } .lvx-bars i:nth-child(2) { height: 55%; } .lvx-bars i:nth-child(3) { height: 42%; } .lvx-bars i:nth-child(4) { height: 70%; }
.lvx-bars i:nth-child(5) { height: 58%; } .lvx-bars i:nth-child(6) { height: 82%; } .lvx-bars i:nth-child(7) { height: 66%; }
.lv-card.direct .lvx-bars { opacity: .22; }
.lvx-top { position: absolute; left: 10px; right: 10px; top: 10px; display: flex; justify-content: space-between; gap: 6px; z-index: 2; }
.lvx-vus { display: inline-flex; align-items: center; gap: 5px; font: 700 12px system-ui, sans-serif; color: #fff; background: rgba(0, 0, 0, .55); padding: 4px 8px; border-radius: 999px; backdrop-filter: blur(4px); }
.lvx-sym { position: absolute; right: 10px; top: 40px; z-index: 2; font: 700 11px ui-monospace, Consolas, monospace; color: var(--gold); background: rgba(0, 0, 0, .55); border: 1px solid rgba(247, 201, 72, .35); padding: 3px 7px; border-radius: 6px; }
.lvx-info { position: relative; z-index: 2; display: flex; align-items: center; gap: 9px; padding: 22px 12px 10px; background: linear-gradient(180deg, transparent, rgba(0, 0, 0, .85)); }
.lvx-info > .av { width: 32px; height: 32px; font-size: 14px; flex: none; border-radius: 50%; border: 1.5px solid rgba(247, 201, 72, .7); }
.lvx-info-tx { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.lvx-info b { font-size: 14.5px; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.lvx-info .mut { font-size: 12.5px; color: #b9c2d3 !important; }
/* 18/10 : qui anime — Visionnaire (membre) ou SIGHT Visionnaire (IA) */
.lvx-info > .lvx-av { width: 32px; height: 32px; flex: none; border-radius: 50%/44%; object-fit: cover; object-position: 50% 22%; border: 1.5px solid rgba(247, 201, 72, .8); }
.lvx-role { font-weight: 700; color: #f7c948; letter-spacing: .01em; }
.lvx-role.ia { color: #8fd3ff; }

/* ---------- studio ---------- */
.lvx-studio, .lvx-prog { border-radius: 20px !important; padding: 20px !important; scroll-margin-top: 80px; }
.lvx-st-hd { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.lvx-st-hd .lv-etat { font-size: 13px; }
.lvx-studio.lvx-endirect { border-color: rgba(255, 59, 92, .55) !important; box-shadow: 0 0 0 1px rgba(255, 59, 92, .25), 0 18px 50px rgba(255, 59, 92, .12); }
.lvx-studio.lvx-endirect .lv-etat { color: #ff8396 !important; font-weight: 700; }
.lvx-st-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 18px; align-items: start; }
.lvx-studio .lv-scene { display: block !important; margin: 0 !important; }
.lvx-studio .lv-vids, .lvx-w .lv-vids { aspect-ratio: 16 / 9; min-height: 0 !important; border-radius: 16px !important; border: 1px solid #1e2840 !important;
  background: radial-gradient(70% 80% at 50% 40%, rgba(247, 201, 72, .07), transparent 60%), #02050c !important; }
.lvx-stage-vide { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; padding: 20px; }
.lvx-stage-vide b { font-size: 16px; }
.lvx-ring { width: 86px; height: 86px; border-radius: 50%; overflow: hidden; border: 2px solid #d4a63a; box-shadow: 0 0 0 8px rgba(247, 201, 72, .07), 0 0 40px rgba(247, 201, 72, .25); animation: lvxRing 3s ease-in-out infinite; margin-bottom: 6px; background: #000; }
.lvx-ring img { width: 100%; height: 100%; object-fit: cover; display: block; }
@keyframes lvxRing { 50% { box-shadow: 0 0 0 14px rgba(247, 201, 72, .03), 0 0 54px rgba(247, 201, 72, .35); } }
.lvx-st-side { display: flex; flex-direction: column; gap: 14px; }
.lvx-st-side .lv-form { display: flex; flex-direction: column; gap: 12px; }
.lvx-st-side .lv-form label, .lvx-prog .frm label { display: flex; flex-direction: column; gap: 5px; font-size: 13px; color: var(--muted); margin: 0; }
.lvx-src { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.lvx-tg { position: relative; cursor: pointer; }
.lvx-tg input { position: absolute; opacity: 0; pointer-events: none; }
.lvx-tg span { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 64px; padding: 8px 4px; border-radius: 12px; font-size: 12.5px; font-weight: 600;
  color: var(--muted); background: #0a1020; border: 1px solid var(--line2); transition: all .15s; text-align: center; }
.lvx-tg span .lvi { width: 20px; height: 20px; }
.lvx-tg input:checked + span { color: var(--gold); border-color: rgba(247, 201, 72, .6); background: rgba(247, 201, 72, .08); box-shadow: inset 0 0 0 1px rgba(247, 201, 72, .2); }
.lvx-tg input:focus-visible + span { outline: 2px solid var(--gold); outline-offset: 2px; }
.lvx-tg input:disabled + span { opacity: .55; cursor: default; }
.lvx-dev { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.lvx-act { display: flex; flex-wrap: wrap; gap: 8px; margin: 2px 0 0; }
.lvx-act .btn { flex: 1 1 auto; min-height: 44px; }
.lvx-go:not(:disabled) { box-shadow: 0 8px 22px rgba(247, 201, 72, .3); }
.lvx-act .btn:disabled { opacity: .45; cursor: not-allowed; }
.lvx-st-side .lv-chat { min-height: 320px !important; max-height: 60vh !important; border-radius: 14px !important; }
.lv-chat .h { display: flex; align-items: center; gap: 6px; }

/* programmer */
.lvx-prog-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 22px; align-items: start; }
.lvx-prog .frm { display: flex; flex-direction: column; gap: 12px; }
.lvx-prog .frm .btn.pri { align-self: flex-start; min-height: 44px; }
.lvx-mes h3 { margin: 0 0 10px; font-size: 15px; color: var(--muted); font-weight: 600; }

/* ---------- page d'un live (spectateur, annonce, terminé) ---------- */
.lvx-w { border-radius: 20px !important; padding: 20px !important; }
.lvx-w-hd { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 14px; }
.lvx-w-hd > .av { width: 56px; height: 56px; font-size: 22px; border-radius: 50%; border: 2px solid rgba(247, 201, 72, .6); flex: none; }
.lvx-w-tx { min-width: 0; }
.lvx-w-l1 { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.lvx-w-l1 .lvx-sym { position: static; }
.lvx-w-hd h1 { margin: 8px 0 4px; font-size: clamp(20px, 2.4vw, 28px); line-height: 1.15; }
.lvx-w-hd .who { color: var(--gold); font-weight: 600; }
.lvx-w-hd p { margin: 6px 0 0; }
.lvx-w-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 12px; }
.lvx-w-bar .sp { flex: 1; }
.lvx-w-bar .lvx-vus:empty { display: none; }
.lvx-w-bar .lvx-vus { background: rgba(255, 59, 92, .12); color: #ff8396; border: 1px solid rgba(255, 59, 92, .3); }
.lvx-w .lv-scene { grid-template-columns: minmax(0, 1fr) 330px !important; gap: 14px !important; margin-top: 0 !important; }
.lvx-w-vide { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; padding: 34px 16px; border-radius: 16px; border: 1px solid #1e2840;
  background: radial-gradient(70% 90% at 50% 30%, rgba(247, 201, 72, .08), transparent 60%), #03060d; }
.lvx-w-vide b { font-size: 17px; }
.lvx-w-prog .lv-cpt { font-size: clamp(20px, 3.4vw, 34px) !important; letter-spacing: .04em; margin: 2px 0 4px !important; text-shadow: 0 0 30px rgba(247, 201, 72, .3); }
.lvx-w-vide .row-btn { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 6px; }

/* ---------- thème clair ---------- */
:root[data-theme=light] .lvx-hero { background: radial-gradient(120% 140% at 0% 0%, rgba(212, 166, 58, .2), transparent 55%), radial-gradient(90% 120% at 100% 100%, rgba(255, 59, 92, .1), transparent 60%), linear-gradient(160deg, #ffffff, #eef2f8 70%);
  border-color: rgba(138, 98, 0, .25); box-shadow: 0 18px 50px rgba(15, 23, 42, .1); }
:root[data-theme=light] .lvx-hero::after { background-image: linear-gradient(rgba(15, 23, 42, .04) 1px, transparent 1px), linear-gradient(90deg, rgba(15, 23, 42, .04) 1px, transparent 1px); }
:root[data-theme=light] .lvx-hero h1 { background: none; color: #0f172a; }
:root[data-theme=light] .lvx-hero p, :root[data-theme=light] .lvx-chips { color: #4a5466; }
:root[data-theme=light] .lv-card.lvx-card { background: linear-gradient(160deg, #18213a, #0a0f1d) !important; color: #fff !important; border-color: #2a3550 !important; }
:root[data-theme=light] .lv-card.lvx-card.direct { background: radial-gradient(90% 90% at 80% 10%, rgba(255, 59, 92, .3), transparent 60%), linear-gradient(160deg, #241425, #0a0f1d) !important; }
:root[data-theme=light] .lv-card.lvx-card.prog { background: radial-gradient(90% 90% at 80% 10%, rgba(247, 201, 72, .22), transparent 60%), linear-gradient(160deg, #1b2236, #0a0f1d) !important; }
:root[data-theme=light] .lv-card.lvx-card .lvx-info b { color: #fff !important; }
:root[data-theme=light] .lv-card.lvx-card .lv-tag.prog { color: #f7c948 !important; }
:root[data-theme=light] .lv-card.lvx-card .lvx-sym { color: #f7c948; }
:root[data-theme=light] .lvx-tg span { background: #fff; }
:root[data-theme=light] .lvx-tg input:checked + span { background: #fff8e6; }
:root[data-theme=light] .lvx-vide { background: linear-gradient(180deg, #fff8e6, transparent); border-color: rgba(138, 98, 0, .3); }
:root[data-theme=light] .lvx-w-vide { background: radial-gradient(70% 90% at 50% 30%, rgba(212, 166, 58, .12), transparent 60%), #f8fafc; border-color: #d6dce6; }
:root[data-theme=light] .lvx-studio .lv-vids, :root[data-theme=light] .lvx-w .lv-vids { border-color: #d6dce6 !important; }

/* ---------- mobile ---------- */
@media (max-width: 900px) {
  .lvx-hero { grid-template-columns: 1fr; padding: 24px 18px; }
  .lvx-hero-art { display: none; }
  .lvx-st-grid, .lvx-prog-grid { grid-template-columns: 1fr; }
  .lvx-w .lv-scene { grid-template-columns: 1fr !important; }
}
@media (max-width: 520px) {
  .lvx-studio, .lvx-prog, .lvx-w { padding: 16px !important; }
  .lvx-cta .btn { flex: 1 1 100%; }
  .lvx-grid { grid-template-columns: 1fr; }
  .lv-strip .lv-card.lvx-card { width: 230px; }
}
@media (prefers-reduced-motion: reduce) { .lvx-pulse, .lvx-screen, .lvx-ring, .lvx-hero { animation: none !important; } }
