/* ==========================================================================
   NOVA — thème sombre moderne
   ========================================================================== */
:root {
  --bg: #07070c;
  --bg2: #0d0d15;
  --surface: #14141f;
  --surface2: #1d1d2c;
  --sheet: #0f0f18;
  --line: rgba(255, 255, 255, .08);
  --line2: rgba(255, 255, 255, .14);
  --text: #f5f5fa;
  --muted: #a3a3b8;
  --dim: #6c6c82;
  --accent: #8b6cff;
  --accent2: #ff4d8d;
  --gold: #ffc94d;
  --ok: #3ddc97;
  --danger: #ff5a6a;
  --grad: linear-gradient(135deg, #8b6cff 0%, #c25cff 45%, #ff4d8d 100%);
  --pad: clamp(16px, 4vw, 60px);
  --card-w: clamp(116px, 12.5vw, 196px);
  --wide-w: clamp(230px, 23vw, 340px);
  --top-h: 68px;
  --radius: 14px;
  --shadow: 0 18px 50px -12px rgba(0, 0, 0, .7);
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --safe-b: env(safe-area-inset-bottom, 0px);
  color-scheme: dark;
}
:root[data-theme="dark"] { color-scheme: dark; }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--text); font-family: var(--font);
  font-size: 15px; line-height: 1.45; -webkit-font-smoothing: antialiased;
  overflow-x: hidden; min-height: 100vh; -webkit-tap-highlight-color: transparent;
}
body.modal-open, body.playing { overflow: hidden; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
input, select, textarea { font: inherit; color: inherit; }
img { display: block; }
svg { width: 1em; height: 1em; fill: currentColor; flex: none; }
h1, h2, h3, h4 { margin: 0; letter-spacing: -.02em; }
code { background: rgba(255, 255, 255, .08); padding: 2px 6px; border-radius: 6px; font-size: .9em; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 8px; }
::selection { background: rgba(139, 108, 255, .45); }

/* ---------- Logo ---------- */
.logo { display: inline-flex; align-items: center; gap: 10px; }
.logo-mark {
  width: 28px; height: 28px; border-radius: 9px; background: var(--grad); position: relative;
  box-shadow: 0 6px 20px -4px rgba(194, 92, 255, .6);
}
.logo-mark::after {
  content: ''; position: absolute; inset: 0; margin: auto; width: 10px; height: 12px;
  background: #fff; clip-path: polygon(0 0, 100% 50%, 0 100%); transform: translateX(1px);
}
.logo-text {
  font-weight: 900; font-size: 21px; letter-spacing: .16em;
  background: linear-gradient(90deg, #fff 30%, #d6c9ff); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.logo.big .logo-mark { width: 44px; height: 44px; border-radius: 13px; }
.logo.big .logo-mark::after { width: 15px; height: 18px; }
.logo.big .logo-text { font-size: 32px; }

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 42px; padding: 0 18px; border-radius: 10px; font-weight: 700; font-size: 14.5px;
  white-space: nowrap; transition: transform .15s, background .2s, opacity .2s; user-select: none;
}
.btn svg { width: 21px; height: 21px; }
.btn:active { transform: scale(.97); }
.btn-primary { background: #fff; color: #0a0a10; }
.btn-primary:hover { background: #e4e4ee; }
.btn-glass { background: rgba(255, 255, 255, .14); color: #fff; backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.btn-glass:hover { background: rgba(255, 255, 255, .22); }
.btn-glass.on svg { color: var(--ok); }
.btn-ghost { border: 1px solid var(--line2); color: var(--text); }
.btn-ghost:hover { background: rgba(255, 255, 255, .06); }
.btn-ghost.danger { color: var(--danger); border-color: rgba(255, 90, 106, .35); }
.btn-lg { height: 50px; padding: 0 24px; font-size: 16px; border-radius: 12px; }
.btn-sm { height: 34px; padding: 0 14px; font-size: 13px; }
.btn-block { width: 100%; }
.icon-btn {
  width: 40px; height: 40px; border-radius: 50%; display: inline-grid; place-items: center;
  background: rgba(255, 255, 255, .08); transition: background .2s; flex: none;
}
.icon-btn svg { width: 20px; height: 20px; }
.icon-btn:hover { background: rgba(255, 255, 255, .16); }
.link { color: var(--accent); font-weight: 600; }
.link:hover { text-decoration: underline; }
.row-btns { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

/* ---------- Barre du haut ---------- */
.topbar {
  position: fixed; inset: 0 0 auto 0; height: var(--top-h); z-index: 40;
  display: flex; align-items: center; gap: 28px; padding: 0 var(--pad);
  background: linear-gradient(to bottom, rgba(7, 7, 12, .85), rgba(7, 7, 12, 0));
  transition: background .3s, box-shadow .3s;
}
.topbar.solid {
  background: rgba(9, 9, 15, .82); backdrop-filter: blur(18px) saturate(1.4); -webkit-backdrop-filter: blur(18px) saturate(1.4);
  box-shadow: 0 1px 0 var(--line);
}
.topnav { display: flex; gap: 4px; }
.topnav a { padding: 8px 14px; border-radius: 999px; color: var(--muted); font-weight: 600; font-size: 14.5px; transition: color .2s, background .2s; }
.topnav a:hover { color: #fff; }
.topnav a.on { color: #fff; background: rgba(255, 255, 255, .1); }
.top-actions { margin-left: auto; display: flex; align-items: center; gap: 12px; position: relative; }
.search-pill {
  display: flex; align-items: center; gap: 10px; height: 40px; padding: 0 12px 0 14px; min-width: 240px;
  border-radius: 999px; background: rgba(255, 255, 255, .08); border: 1px solid var(--line); color: var(--muted);
  font-size: 14px; transition: background .2s, border-color .2s;
}
.search-pill:hover { background: rgba(255, 255, 255, .12); border-color: var(--line2); }
.search-pill svg { width: 18px; height: 18px; }
.search-pill kbd { margin-left: auto; font: 600 11px var(--font); padding: 2px 7px; border-radius: 6px; border: 1px solid var(--line2); color: var(--dim); }
.avatar-btn {
  width: 38px; height: 38px; border-radius: 11px; background: var(--c, var(--accent)); font-weight: 800; color: #fff;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .2); background-image: linear-gradient(135deg, rgba(255, 255, 255, .25), transparent);
}
.sync { width: 18px; height: 18px; border-radius: 50%; border: 2px solid transparent; display: none; }
.sync.on { display: block; border-color: var(--accent) transparent var(--accent) transparent; animation: spin 1s linear infinite; }

.dropdown {
  position: absolute; right: 0; top: 52px; width: 270px; padding: 8px; border-radius: 16px;
  background: rgba(21, 21, 32, .97); border: 1px solid var(--line2); box-shadow: var(--shadow);
  opacity: 0; transform: translateY(-6px) scale(.98); pointer-events: none; transition: .18s; backdrop-filter: blur(20px);
}
.dropdown.open { opacity: 1; transform: none; pointer-events: auto; }
.dropdown > a, .dropdown > button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border-radius: 10px; font-weight: 600; font-size: 14px; text-align: left; }
.dropdown > a:hover, .dropdown > button:hover { background: rgba(255, 255, 255, .07); }
.dropdown > .on { color: #fff; background: rgba(139, 108, 255, .16); }
.dropdown svg { width: 18px; height: 18px; }
.dropdown hr { border: 0; border-top: 1px solid var(--line); margin: 6px 4px; }

/* ---------- Navigation mobile ---------- */
.bottomnav { display: none; }

/* ---------- Hero ---------- */
.hero { position: relative; height: min(86vh, 860px); min-height: 520px; overflow: hidden; }
.hero-slide { position: absolute; inset: 0; opacity: 0; transition: opacity .9s ease; pointer-events: none; }
.hero-slide.on { opacity: 1; pointer-events: auto; }
.hero-bg { position: absolute; inset: 0; background: radial-gradient(120% 90% at 70% 20%, hsl(var(--h) 55% 28%), hsl(calc(var(--h) + 40) 60% 8%) 70%); }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; }
.hero-slide.on .hero-bg img { animation: kenburns 14s ease-out both; }
.hero-slide.is-poster .hero-bg img { filter: blur(34px) saturate(1.4) brightness(.6); transform: scale(1.25); animation: none; }
.hero-shade {
  position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(7, 7, 12, .96) 0%, rgba(7, 7, 12, .72) 32%, rgba(7, 7, 12, .1) 68%),
    linear-gradient(0deg, var(--bg) 0%, rgba(7, 7, 12, .5) 22%, transparent 45%),
    linear-gradient(180deg, rgba(7, 7, 12, .6) 0%, transparent 18%);
}
.hero-content { position: absolute; left: var(--pad); bottom: max(18%, 150px); max-width: min(620px, 88vw); z-index: 2; }
.hero-slide.on .hero-content > * { animation: fadeUp .7s both; }
.hero-slide.on .hero-content > :nth-child(2) { animation-delay: .06s; }
.hero-slide.on .hero-content > :nth-child(3) { animation-delay: .12s; }
.hero-slide.on .hero-content > :nth-child(4) { animation-delay: .18s; }
.hero-slide.on .hero-content > :nth-child(5) { animation-delay: .24s; }
.hero-kicker { font-size: 12px; font-weight: 800; letter-spacing: .2em; margin-bottom: 14px; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-title { font-size: clamp(34px, 5.6vw, 76px); line-height: .98; font-weight: 900; letter-spacing: -.035em; text-wrap: balance; text-shadow: 0 4px 30px rgba(0, 0, 0, .5); }
.hero-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 16px 0 12px; color: #d9d9e6; font-weight: 600; font-size: 14.5px; }
.hero-meta span + span::before { content: '•'; margin-right: 14px; color: var(--dim); }
.hero-plot { color: #c9c9d8; font-size: 16px; line-height: 1.55; margin: 0 0 24px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; max-width: 560px; min-height: 0; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-art { position: absolute; right: calc(var(--pad) + 4vw); top: 50%; transform: translateY(-46%) rotate(2deg); width: clamp(200px, 21vw, 330px); z-index: 1; }
.hero-art img { width: 100%; aspect-ratio: 2/3; object-fit: cover; border-radius: 18px; box-shadow: 0 40px 80px -20px rgba(0, 0, 0, .9), 0 0 0 1px rgba(255, 255, 255, .1); }
.hero-slide.on .hero-art { animation: floatIn 1s both; }
.hero-dots { position: absolute; right: var(--pad); bottom: max(18%, 150px); display: flex; gap: 8px; z-index: 3; }
.hero-dots button { width: 8px; height: 8px; border-radius: 99px; background: rgba(255, 255, 255, .35); transition: width .3s, background .3s; }
.hero-dots button.on { width: 28px; background: #fff; }

/* ---------- Rangées ---------- */
.rows { position: relative; z-index: 2; margin-top: -11vh; padding-bottom: 40px; }
.hero + .browse-bar { margin-top: -11vh; position: relative; z-index: 3; }
.browse-bar + .rows { margin-top: 0; }
.view > .rows:first-child { margin-top: 0; padding-top: calc(var(--top-h) + 20px); }
.row { margin: 6px 0 22px; }
.row-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; padding: 0 var(--pad); margin-bottom: 4px; }
.row-head h2 { font-size: clamp(17px, 1.6vw, 22px); font-weight: 800; display: flex; align-items: baseline; gap: 10px; min-width: 0; }
.row-head h2 small { font-size: 13px; color: var(--muted); font-weight: 600; }
.row-more { display: inline-flex; align-items: center; gap: 2px; color: var(--muted); font-size: 13.5px; font-weight: 600; white-space: nowrap; transition: color .2s; }
.row-more:hover { color: #fff; }
.row-more svg { width: 18px; height: 18px; }
.row-wrap { position: relative; }
.row-track {
  display: flex; gap: 12px; overflow-x: auto; overflow-y: hidden; padding: 10px var(--pad) 18px;
  scroll-snap-type: x mandatory; scroll-padding: 0 var(--pad); scrollbar-width: none; overscroll-behavior-x: contain;
}
.row-track::-webkit-scrollbar { display: none; }
.row-track > * { scroll-snap-align: start; }
.row-arrow {
  position: absolute; top: 10px; bottom: 18px; width: var(--pad); min-width: 44px; z-index: 5;
  display: grid; place-items: center; opacity: 0; transition: opacity .25s; color: #fff;
}
.row-arrow svg { width: 34px; height: 34px; filter: drop-shadow(0 2px 6px rgba(0, 0, 0, .8)); transition: transform .2s; }
.row-arrow:hover svg { transform: scale(1.25); }
.row-arrow.l { left: 0; background: linear-gradient(90deg, rgba(7, 7, 12, .9), transparent); }
.row-arrow.r { right: 0; background: linear-gradient(270deg, rgba(7, 7, 12, .9), transparent); }
@media (hover: hover) {
  .row-wrap:hover .row-arrow { opacity: 1; }
  .row-wrap.at-start .row-arrow.l, .row-wrap.at-end .row-arrow.r { opacity: 0 !important; pointer-events: none; }
}
@media (hover: none) { .row-arrow { display: none; } }

/* ---------- Cartes ---------- */
.card { flex: none; width: var(--card-w); text-align: left; position: relative; border-radius: 12px; }
.card-img {
  position: relative; aspect-ratio: 2/3; border-radius: 12px; overflow: hidden; background: var(--surface);
  box-shadow: 0 0 0 1px var(--line); transition: transform .3s cubic-bezier(.2, .8, .2, 1), box-shadow .3s;
}
.card-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.card-fallback {
  position: absolute; inset: 0; display: flex; align-items: flex-end; padding: 12px;
  background: linear-gradient(160deg, hsl(var(--h) 55% 38%) 0%, hsl(calc(var(--h) + 45) 60% 16%) 75%);
}
.card-fallback::before { content: ''; position: absolute; inset: 0; background: radial-gradient(80% 60% at 80% 10%, rgba(255, 255, 255, .22), transparent 60%); }
.card-fallback span { position: relative; font-weight: 800; font-size: 15px; line-height: 1.15; letter-spacing: -.01em; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; text-shadow: 0 2px 10px rgba(0, 0, 0, .4); }
.card-wide .card-fallback span { font-size: 18px; }
.card-rating {
  position: absolute; top: 8px; left: 8px; display: inline-flex; align-items: center; gap: 3px; padding: 3px 7px;
  border-radius: 7px; font-size: 11.5px; font-weight: 800; background: rgba(0, 0, 0, .62); backdrop-filter: blur(6px); color: #fff;
}
.card-rating svg { width: 11px; height: 11px; color: var(--gold); }
.card-progress { position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: rgba(255, 255, 255, .22); }
.card-progress i { display: block; height: 100%; background: var(--grad); border-radius: 0 4px 4px 0; }
.card-meta { padding: 8px 2px 0; }
.card-title { font-size: 13.5px; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card-sub { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 1px; }
.card-wide { width: var(--wide-w); }
.card-wide .card-img { aspect-ratio: 16/9; }
.card-playicon {
  position: absolute; inset: 0; margin: auto; width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(0, 0, 0, .5); backdrop-filter: blur(8px); border: 2px solid rgba(255, 255, 255, .8); opacity: .0; transform: scale(.85); transition: .25s;
}
.card-playicon svg { width: 24px; height: 24px; margin-left: 3px; }
@media (hover: hover) {
  .card:hover .card-img { transform: translateY(-4px) scale(1.035); box-shadow: 0 0 0 2px rgba(255, 255, 255, .85), var(--shadow); }
  .card:hover .card-playicon { opacity: 1; transform: none; }
}
@media (hover: none) { .card-playicon { opacity: .9; transform: scale(.8); } .card:active .card-img { transform: scale(.97); } }
.card.skel .card-img, .ep.skel, .skel-text {
  background: linear-gradient(100deg, var(--surface) 30%, var(--surface2) 50%, var(--surface) 70%); background-size: 300% 100%; animation: shimmer 1.4s infinite linear;
}
.skel-text { height: 64px; border-radius: 10px; }

/* Tuiles plateformes (logos officiels) */
.pf-tile {
  flex: none; width: clamp(150px, 16vw, 240px); aspect-ratio: 16/9; border-radius: 14px; position: relative; overflow: hidden;
  display: grid; place-items: center; background: var(--pb);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .1), 0 10px 30px -14px rgba(0, 0, 0, .8);
  transition: transform .25s, box-shadow .25s;
}
.pf-tile::after { content: ''; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(90% 70% at 30% 0%, rgba(255, 255, 255, .16), transparent 60%), linear-gradient(0deg, rgba(0, 0, 0, .25), transparent 40%); }
.pf-tile:hover { transform: translateY(-4px) scale(1.03); box-shadow: 0 0 0 2px rgba(255, 255, 255, .9), var(--shadow); }
.pf-count { position: absolute; left: 0; right: 0; bottom: 7px; text-align: center; font-size: 11px; color: rgba(255, 255, 255, .7); font-weight: 600; z-index: 1; }
.pf-logo { display: inline-flex; align-items: center; justify-content: center; color: var(--pc); line-height: 1; white-space: nowrap; position: relative; z-index: 1; }
.pf-img { display: block; height: 100%; width: auto; max-width: 100%; object-fit: contain; user-select: none; }
.pf-white .pf-img { filter: brightness(0) invert(1); }
.pf-svg { fill: currentColor; height: 100%; width: auto; }
.pf-word { font-weight: 900; letter-spacing: -.03em; color: var(--pc); font-size: 1em; }
/* tailles : tuile, petit (titres de rangées / puces), grand (page plateforme) */
.pf-tile .pf-logo { height: 30%; max-width: 72%; margin-top: -6%; }
.pf-tile .pf-word { font-size: clamp(22px, 2.3vw, 32px); }
.pf-tile .pf-k-paramount, .pf-tile .pf-k-crunchyroll, .pf-tile .pf-k-arte { height: 48%; }
.pf-tile .pf-k-netflix { height: 26%; }
.pf-tile .pf-k-disney { height: 44%; }
.pf-sm.pf-k-disney { height: 1.5em; }
.pf-xl.pf-k-disney { height: clamp(50px, 6vw, 80px); }
.pf-sm { height: 1.05em; }
.pf-sm.pf-k-paramount, .pf-sm.pf-k-crunchyroll, .pf-sm.pf-k-arte { height: 1.5em; }
.pf-sm .pf-word { font-size: 1em; }
.pf-xl { height: clamp(34px, 4.5vw, 56px); }
.pf-xl.pf-k-paramount, .pf-xl.pf-k-crunchyroll, .pf-xl.pf-k-arte { height: clamp(50px, 6vw, 80px); }
.pf-xl .pf-word { font-size: clamp(32px, 4.5vw, 54px); }
.row-pf-title { display: inline-flex; align-items: center; gap: 12px; }
.row-pf-title .pf-sm { height: .95em; }
.h1-logo { display: flex; align-items: center; min-height: 56px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* Tops (avec gros numéros) */
.row-top .row-track { gap: 18px; }
.top-card { flex: none; display: flex; align-items: flex-end; width: calc(var(--card-w) * 1.5); position: relative; text-align: left; }
.top-num {
  flex: none; width: 40%; margin-right: -4%; font-size: calc(var(--card-w) * .98); line-height: .78; font-weight: 900; letter-spacing: -.06em;
  color: #0d0d14; -webkit-text-stroke: 3px rgba(255, 255, 255, .7); paint-order: stroke fill; text-shadow: 0 6px 24px rgba(0, 0, 0, .6); text-align: right; position: relative; z-index: 0; user-select: none;
  font-family: var(--font); transform: translateY(4%);
}
.top-card .card-img { flex: none; width: var(--card-w); position: relative; z-index: 1; }
.top-card.two { width: calc(var(--card-w) * 1.78); }
.top-card.two .top-num { width: 48%; font-size: calc(var(--card-w) * .82); letter-spacing: -.1em; }
.top-card:hover .card-img { transform: translateY(-4px) scale(1.035); box-shadow: 0 0 0 2px rgba(255, 255, 255, .85), var(--shadow); }
.top-card:hover .top-num { -webkit-text-stroke-color: #fff; }
.tops-page { margin: 0 calc(-1 * var(--pad)) 10px; }

/* Bandes-annonces */
.trailer-bg { position: absolute; inset: 0; overflow: hidden; container-type: size; opacity: 0; transition: opacity 1.2s ease; pointer-events: none; z-index: 0; }
.trailer-bg.on { opacity: 1; }
.trailer-bg iframe {
  position: absolute; top: 50%; left: 50%; border: 0; pointer-events: none;
  width: max(100cqw, 177.78cqh); height: max(100cqh, 56.25cqw); transform: translate(-50%, -50%) scale(1.18);
}
.trailer-bg.with-controls { pointer-events: auto; position: relative; aspect-ratio: 16/9; }
.trailer-bg.with-controls iframe { transform: translate(-50%, -50%); pointer-events: auto; width: 100%; height: 100%; }
.hero-bg, .d-bg { isolation: isolate; }
.trailer-playing .hero-art, .trailer-playing .hero-plot { opacity: 0; transition: opacity .8s; }
.hero-slide.is-poster.trailer-playing .hero-bg img { opacity: 0; }
.trailer-sound, .hero-sound {
  position: absolute; z-index: 6; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(0, 0, 0, .45); border: 1.5px solid rgba(255, 255, 255, .7); color: #fff; backdrop-filter: blur(6px);
}
.trailer-sound svg, .hero-sound svg { width: 22px; height: 22px; }
.trailer-sound { right: 24px; top: 70px; }
.hero-sound { right: var(--pad); bottom: calc(max(18%, 150px) + 30px); }
.trailer-sound[hidden], .hero-sound[hidden] { display: none; }

/* Chaînes */
.ch-card {
  display: flex; align-items: center; gap: 12px; padding: 10px 10px 10px 10px; border-radius: 14px;
  background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); cursor: pointer; transition: background .2s, transform .2s; min-width: 0;
}
.ch-card:hover { background: var(--surface2); }
.ch-card:active { transform: scale(.985); }
.ch-card.compact { flex: none; width: 260px; }
.ch-logo {
  position: relative; width: 64px; height: 48px; flex: none; border-radius: 10px; overflow: hidden; display: grid; place-items: center;
  background: linear-gradient(135deg, hsl(var(--h) 45% 30%), hsl(calc(var(--h) + 40) 50% 15%));
}
.ch-logo b { font-size: 15px; font-weight: 900; letter-spacing: .02em; text-transform: uppercase; }
.ch-logo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 6px; background: #1b1b28; }
.ch-info { min-width: 0; flex: 1; }
.ch-name { font-weight: 700; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ch-num { color: var(--dim); font-weight: 700; margin-right: 8px; font-size: 12.5px; }
.ch-now { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 3px; min-height: 17px; display: flex; align-items: center; gap: 8px; }
.ch-prog { width: 34px; height: 3px; background: rgba(255, 255, 255, .15); border-radius: 3px; flex: none; overflow: hidden; }
.ch-prog i { display: block; height: 100%; background: var(--grad); }
.ch-fav { width: 36px; height: 36px; display: grid; place-items: center; color: var(--dim); border-radius: 50%; flex: none; transition: color .2s, transform .2s; }
.ch-fav svg { width: 20px; height: 20px; }
.ch-fav:hover { color: #fff; }
.ch-fav.on { color: var(--gold); }
.ch-fav.on svg { animation: pop .35s; }
.ch-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 10px; }

/* ---------- Pages ---------- */
.page { padding: calc(var(--top-h) + 24px) var(--pad) 48px; min-height: 80vh; animation: fadeIn .35s both; }
.page-head { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; }
.page-head h1 { font-size: clamp(26px, 3.6vw, 40px); font-weight: 900; }
.page-sub { color: var(--muted); font-size: 14px; margin-top: 2px; }
.browse-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding: 0 var(--pad); margin-bottom: 10px; }
.browse-bar h1 { font-size: clamp(28px, 3.6vw, 42px); font-weight: 900; margin-right: 8px; }
.toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 0 0 22px; }
.seg { display: inline-flex; padding: 4px; border-radius: 999px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); overflow-x: auto; scrollbar-width: none; max-width: 100%; }
.seg::-webkit-scrollbar { display: none; }
.seg > * { padding: 8px 16px; border-radius: 999px; font-weight: 650; font-size: 14px; color: var(--muted); white-space: nowrap; transition: .2s; }
.seg > *:hover { color: #fff; }
.seg > .on { background: #fff; color: #0a0a10; }
.seg small { opacity: .6; font-weight: 700; margin-left: 2px; }
.seg-full { display: flex; width: 100%; }
.seg-full > * { flex: 1; text-align: center; padding: 10px 8px; }
.filter-input { display: flex; align-items: center; gap: 8px; height: 42px; padding: 0 14px; border-radius: 999px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); flex: 1; min-width: 180px; max-width: 360px; }
.filter-input svg { width: 18px; height: 18px; color: var(--muted); }
.filter-input input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; height: 100%; }
.select { position: relative; display: inline-flex; }
.select select, .select-row select {
  appearance: none; -webkit-appearance: none; height: 42px; padding: 0 38px 0 16px; border-radius: 999px; max-width: 280px;
  background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23a3a3b8'%3E%3Cpath d='M7.4 8.6 12 13.2l4.6-4.6L18 10l-6 6-6-6z'/%3E%3C/svg%3E") no-repeat right 12px center / 18px;
  border: 1px solid var(--line2); font-weight: 600; font-size: 14px; cursor: pointer; color: var(--text);
}
select option { background: #15151f; color: #fff; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(clamp(110px, 13vw, 175px), 1fr)); gap: 22px 14px; }
.grid .card { width: auto; }
.grid-sm { grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 16px 12px; }
.sentinel { height: 1px; }
.empty-state { text-align: center; padding: 120px 20px 60px; max-width: 520px; margin: 0 auto; }
.empty-state.small { padding: 50px 20px; }
.empty-state h2 { font-size: 24px; margin-bottom: 8px; }
.empty-state h3 { font-size: 19px; margin-bottom: 6px; }
.empty-state p { color: var(--muted); margin: 0 0 22px; }
.empty-state .row-btns { justify-content: center; }
.empty-ico { width: 66px; height: 66px; border-radius: 50%; margin: 0 auto 18px; display: grid; place-items: center; font-size: 30px; font-weight: 900; background: rgba(139, 108, 255, .14); color: var(--accent); }
.empty-ico svg { width: 30px; height: 30px; }
.notice { background: rgba(255, 255, 255, .05); border-left: 3px solid var(--accent); padding: 12px 14px; border-radius: 10px; font-size: 13.5px; color: #d3d3e0; margin: 14px 0; }
.notice.warn { border-left-color: #ffa94d; }
.hint { color: var(--muted); font-size: 13px; line-height: 1.6; margin: 10px 0 0; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { padding: 8px 15px; border-radius: 999px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line2); font-weight: 600; font-size: 13.5px; transition: .2s; white-space: nowrap; }
.chip:hover { background: var(--surface2); }
.chip.on { background: #fff; color: #0a0a10; box-shadow: none; }
.chip-pf { display: inline-flex; align-items: center; height: 42px; padding: 0 18px; background: var(--pb); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14); font-size: 17px; }
.chip-pf:hover { background: var(--pb); box-shadow: inset 0 0 0 1.5px #fff; }

/* Recherche : onglets + meilleur résultat */
.search-tabs { margin-bottom: 20px; }
.search-tabs button { cursor: pointer; }
.top-result {
  position: relative; display: flex; align-items: center; gap: 22px; width: 100%; padding: 20px; border-radius: 20px; overflow: hidden; text-align: left;
  margin-bottom: 30px; box-shadow: 0 0 0 1px var(--line2); min-height: 220px;
}
.tr-bg { position: absolute; inset: 0; background: linear-gradient(135deg, hsl(var(--h) 45% 25%), hsl(calc(var(--h) + 40) 50% 8%)); }
.tr-bg img { width: 100%; height: 100%; object-fit: cover; filter: blur(2px) brightness(.45); transform: scale(1.05); }
.tr-bg::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(7, 7, 12, .92), rgba(7, 7, 12, .4)); }
.tr-poster { position: relative; flex: none; width: clamp(96px, 12vw, 150px); aspect-ratio: 2/3; border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); }
.tr-poster img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.tr-info { position: relative; display: flex; flex-direction: column; gap: 8px; min-width: 0; align-items: flex-start; }
.tr-kicker { font-size: 12px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.tr-title { font-size: clamp(24px, 3.4vw, 38px); font-weight: 900; letter-spacing: -.03em; line-height: 1.05; }
.tr-meta { display: flex; flex-wrap: wrap; gap: 4px 12px; color: #d4d4e2; font-size: 13.5px; font-weight: 600; }
.tr-plot { color: #c4c4d2; font-size: 14px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; max-width: 640px; }
.top-result:hover { box-shadow: 0 0 0 2px #fff; }

/* Fiche : versions, favoris */
.d-versions { margin: 0 0 24px; }
.d-versions h4 { font-size: 12.5px; color: var(--dim); text-transform: uppercase; letter-spacing: .08em; margin-bottom: 10px; }
.btn-ico { width: 50px; padding: 0; }
.btn .heart-on, .btn-glass.on .heart-on { color: #ff4d6d; }
.pl-menu-note { color: var(--muted); font-size: 12px; margin: 8px 0 0; }

/* Recherche */
.search-big {
  position: sticky; top: calc(var(--top-h) + 6px); z-index: 10; display: flex; align-items: center; gap: 12px; height: 62px; padding: 0 10px 0 20px;
  border-radius: 18px; background: rgba(24, 24, 36, .92); backdrop-filter: blur(18px); box-shadow: inset 0 0 0 1px var(--line2), var(--shadow); margin-bottom: 26px;
}
.search-big:focus-within { box-shadow: inset 0 0 0 2px var(--accent), var(--shadow); }
.search-big > svg { width: 24px; height: 24px; color: var(--muted); }
.search-big input { flex: 1; min-width: 0; height: 100%; background: none; border: 0; outline: 0; font-size: 19px; font-weight: 500; }
.search-big input::-webkit-search-cancel-button { display: none; }
.search-sec { margin-bottom: 34px; }
.search-sec h3 { font-size: 19px; margin-bottom: 14px; display: flex; align-items: baseline; gap: 8px; }
.search-sec h3 small { color: var(--muted); font-size: 13px; }
.sec-head { display: flex; justify-content: space-between; align-items: baseline; }

/* Ma liste / historique */
.hist-list { display: flex; flex-direction: column; margin-bottom: 20px; }
.hist-item { display: flex; align-items: center; gap: 10px; border-bottom: 1px solid var(--line); }
.hist-main { flex: 1; display: flex; align-items: center; gap: 14px; padding: 12px 0; text-align: left; min-width: 0; }
.hist-img { width: 96px; aspect-ratio: 16/10; border-radius: 9px; overflow: hidden; flex: none; position: relative; background: linear-gradient(135deg, hsl(var(--h) 45% 32%), hsl(calc(var(--h) + 40) 50% 14%)); }
.hist-img img { width: 100%; height: 100%; object-fit: cover; }
.hist-txt { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.hist-txt b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hist-txt small { color: var(--muted); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hist-bar { height: 3px; width: 140px; max-width: 100%; background: rgba(255, 255, 255, .14); border-radius: 3px; overflow: hidden; margin-top: 3px; }
.hist-bar i { display: block; height: 100%; background: var(--grad); }

/* ---------- TV en direct ---------- */
.live { display: grid; grid-template-columns: 270px 1fr; gap: 28px; padding: calc(var(--top-h) + 20px) var(--pad) 40px; animation: fadeIn .35s both; }
.live-cats { position: sticky; top: calc(var(--top-h) + 20px); max-height: calc(100vh - var(--top-h) - 40px); overflow-y: auto; padding-right: 6px; scrollbar-width: thin; scrollbar-color: var(--surface2) transparent; }
.live-cats-title { font-size: 12px; font-weight: 800; letter-spacing: .14em; color: var(--dim); text-transform: uppercase; padding: 4px 14px 10px; }
.live-cats a { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 10px; color: var(--muted); font-weight: 600; font-size: 14px; position: relative; transition: .15s; }
.live-cats a span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.live-cats a small { color: var(--dim); font-size: 12px; font-weight: 700; }
.live-cats a:hover { color: #fff; background: rgba(255, 255, 255, .04); }
.live-cats a.on { color: #fff; background: var(--surface2); }
.live-cats a.on::before { content: ''; position: absolute; left: 0; top: 10px; bottom: 10px; width: 3px; border-radius: 3px; background: var(--grad); }
.live-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 14px; margin-bottom: 18px; }
.live-head h1 { font-size: clamp(26px, 3.4vw, 38px); font-weight: 900; }

/* ---------- Fiche détail ---------- */
.modal { position: fixed; inset: 0; z-index: 60; overflow-y: auto; overscroll-behavior: contain; display: none; }
.modal.open { display: block; }
.sheet-back { position: fixed; inset: 0; background: rgba(0, 0, 0, .72); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); animation: fadeIn .25s both; }
.sheet {
  position: relative; max-width: 1000px; margin: 36px auto; background: var(--sheet); border-radius: 22px; overflow: hidden;
  box-shadow: 0 40px 120px -20px rgba(0, 0, 0, .9), 0 0 0 1px var(--line); animation: sheetIn .38s cubic-bezier(.2, .8, .2, 1) both;
}
.sheet-close { position: absolute; top: 16px; right: 16px; z-index: 5; background: rgba(10, 10, 16, .7); backdrop-filter: blur(10px); }
.d-hero { position: relative; min-height: 440px; aspect-ratio: 16/8.5; display: flex; align-items: flex-end; }
.d-bg { position: absolute; inset: 0; overflow: hidden; background: radial-gradient(120% 100% at 70% 0%, hsl(var(--h) 50% 30%), hsl(calc(var(--h) + 40) 50% 8%) 75%); }
.d-bg img { width: 100%; height: 100%; object-fit: cover; object-position: center 25%; }
.d-bg iframe { width: 100%; height: 100%; border: 0; }
.d-hero.is-poster .d-bg img { filter: blur(30px) saturate(1.3) brightness(.55); transform: scale(1.2); }
.d-shade { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(0deg, var(--sheet) 0%, rgba(15, 15, 24, .75) 35%, rgba(15, 15, 24, .1) 70%), linear-gradient(90deg, rgba(15, 15, 24, .6), transparent 60%); }
.d-hero-in { position: relative; display: flex; align-items: flex-end; gap: 26px; padding: 28px 32px 8px; width: 100%; }
.d-poster { position: relative; width: 160px; aspect-ratio: 2/3; border-radius: 14px; overflow: hidden; flex: none; box-shadow: 0 24px 50px -10px rgba(0, 0, 0, .8), 0 0 0 1px rgba(255, 255, 255, .12); }
.d-poster img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.d-head { min-width: 0; flex: 1; }
.d-title { font-size: clamp(28px, 4.2vw, 48px); font-weight: 900; line-height: 1.02; letter-spacing: -.035em; text-wrap: balance; }
.d-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin: 14px 0 18px; color: #d4d4e2; font-weight: 600; font-size: 14px; }
.d-score { display: inline-flex; align-items: center; gap: 4px; color: var(--gold); font-weight: 800; }
.pill { padding: 2px 8px; border-radius: 6px; border: 1px solid var(--line2); font-size: 12px; }
.d-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.d-progress { height: 4px; border-radius: 4px; background: rgba(255, 255, 255, .15); margin-top: 16px; max-width: 360px; overflow: hidden; }
.d-progress i { display: block; height: 100%; background: var(--grad); }
.trailer-on { aspect-ratio: auto; flex-direction: column; align-items: stretch; min-height: 0; }
.trailer-on .d-bg { position: relative; aspect-ratio: 16/9; }
.trailer-on .d-shade { display: none; }
.trailer-on .d-poster { display: none; }
.d-body { padding: 18px 32px 36px; }
.d-plot { font-size: 16px; line-height: 1.65; color: #d6d6e3; max-width: 72ch; margin: 0 0 20px; }
.d-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px 26px; margin: 0 0 28px; }
.d-facts dt { color: var(--dim); font-size: 12.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 3px; }
.d-facts dd { margin: 0; color: #dcdce8; font-size: 14px; }
.d-facts a { color: var(--accent); }
.d-eps { margin-bottom: 32px; }
.eps-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 14px; margin-bottom: 14px; }
.eps-head h3, .d-similar h3 { font-size: 21px; font-weight: 800; }
.d-similar h3 { margin-bottom: 16px; }
.seasons { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; max-width: 100%; }
.ep-list { display: flex; flex-direction: column; gap: 4px; }
.ep { display: grid; grid-template-columns: 30px 180px 1fr; gap: 18px; align-items: center; padding: 12px; border-radius: 14px; text-align: left; transition: background .2s; }
.ep.skel { height: 120px; display: block; margin-bottom: 6px; }
.ep:hover { background: var(--surface); }
.ep-num { font-size: 22px; font-weight: 800; color: var(--dim); text-align: center; }
.ep-thumb { position: relative; aspect-ratio: 16/9; border-radius: 10px; overflow: hidden; background: linear-gradient(135deg, hsl(var(--h) 45% 32%), hsl(calc(var(--h) + 40) 50% 14%)); }
.ep-thumb img { width: 100%; height: 100%; object-fit: cover; }
.ep-play { position: absolute; inset: 0; margin: auto; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: rgba(0, 0, 0, .55); border: 2px solid #fff; opacity: 0; transition: .2s; }
.ep-play svg { width: 18px; height: 18px; margin-left: 2px; }
.ep:hover .ep-play { opacity: 1; }
.ep-info { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.ep-title { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; }
.ep-title b { font-size: 15px; }
.ep-title small { color: var(--muted); white-space: nowrap; }
.ep-plot { color: var(--muted); font-size: 13.5px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* ---------- Lecteur ---------- */
.player { position: fixed; inset: 0; z-index: 100; background: #000; display: none; user-select: none; -webkit-user-select: none; }
.player.open { display: block; animation: fadeIn .25s both; }
.player video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #000; }
.player.ui-hidden { cursor: none; }
.pl-ui {
  position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: space-between; pointer-events: none;
  background: linear-gradient(180deg, rgba(0, 0, 0, .75) 0%, transparent 22%, transparent 62%, rgba(0, 0, 0, .85) 100%);
  transition: opacity .35s;
}
.pl-ui > *, .pl-center > * { pointer-events: auto; }
.pl-center { pointer-events: none !important; }
.ui-hidden .pl-ui { opacity: 0; }
.ui-hidden .pl-ui * { pointer-events: none !important; }
.pl-top { display: flex; align-items: center; gap: 14px; padding: max(16px, env(safe-area-inset-top)) max(20px, env(safe-area-inset-right)) 0 max(20px, env(safe-area-inset-left)); }
.pl-titles { min-width: 0; flex: 1; }
.pl-title { font-size: 19px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pl-sub { font-size: 13.5px; color: #c8c8d6; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pl-live-badge { display: none; align-items: center; gap: 7px; font-size: 11.5px; font-weight: 800; letter-spacing: .1em; padding: 5px 10px; border-radius: 6px; background: rgba(255, 60, 80, .9); }
.pl-live-badge::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: #fff; animation: pulse 1.4s infinite; }
.is-live .pl-live-badge { display: inline-flex; }
.pl-btn { width: 46px; height: 46px; border-radius: 50%; display: inline-grid; place-items: center; color: #fff; transition: background .2s, transform .15s; flex: none; }
.pl-btn svg { width: 26px; height: 26px; }
.pl-btn:hover { background: rgba(255, 255, 255, .12); }
.pl-btn:active { transform: scale(.92); }
.pl-center { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: clamp(24px, 8vw, 70px); }
.pl-center .pl-btn { width: 60px; height: 60px; background: rgba(0, 0, 0, .35); backdrop-filter: blur(8px); }
.pl-center .pl-btn svg { width: 32px; height: 32px; }
.pl-center .pl-big { width: 82px; height: 82px; background: rgba(255, 255, 255, .16); }
.pl-center .pl-big svg { width: 42px; height: 42px; }
@media (hover: hover) and (pointer: fine) {
  .pl-center { opacity: 0; transition: opacity .2s; }
  .paused .pl-center { opacity: 1; }
  .paused .pl-center .pl-btn:not(.pl-big) { display: none; }
}
.pl-bottom { padding: 0 max(20px, env(safe-area-inset-right)) max(14px, var(--safe-b)) max(20px, env(safe-area-inset-left)); }
.pl-progress { position: relative; height: 22px; display: flex; align-items: center; cursor: pointer; touch-action: none; margin-bottom: 2px; }
.pl-progress::before { content: ''; position: absolute; left: 0; right: 0; height: 5px; border-radius: 5px; background: rgba(255, 255, 255, .22); transition: height .15s; }
.pl-buf, .pl-fill { position: absolute; left: 0; height: 5px; border-radius: 5px; transition: height .15s; }
.pl-buf { background: rgba(255, 255, 255, .35); }
.pl-fill { background: var(--grad); }
.pl-thumb { position: absolute; width: 16px; height: 16px; border-radius: 50%; background: #fff; transform: translateX(-50%) scale(.0); transition: transform .15s; box-shadow: 0 0 0 4px rgba(139, 108, 255, .35); }
.pl-progress:hover::before, .pl-progress:hover .pl-buf, .pl-progress:hover .pl-fill { height: 8px; }
.pl-progress:hover .pl-thumb, .pl-progress:active .pl-thumb { transform: translateX(-50%) scale(1); }
.pl-hover { position: absolute; bottom: 26px; transform: translateX(-50%); padding: 4px 8px; border-radius: 6px; background: rgba(0, 0, 0, .85); font-size: 12.5px; font-weight: 700; opacity: 0; transition: opacity .15s; pointer-events: none; font-variant-numeric: tabular-nums; }
.pl-progress:hover .pl-hover { opacity: 1; }
.pl-row { display: flex; align-items: center; gap: 4px; }
.pl-spacer { flex: 1; }
.pl-time { font-size: 13.5px; font-weight: 600; font-variant-numeric: tabular-nums; margin-left: 8px; color: #e4e4ee; white-space: nowrap; }
.pl-vol { width: 90px; accent-color: #fff; }
.pl-next-btn { display: none; width: auto; border-radius: 999px; padding: 0 14px 0 10px; gap: 6px; font-weight: 700; font-size: 14px; grid-auto-flow: column; }
.has-next .pl-next-btn { display: inline-grid; }
.pl-only-live { display: none !important; }
.is-live .pl-only-live { display: inline-grid !important; }
.is-live .pl-only-vod { display: none !important; }
.pl-spinner { position: absolute; inset: 0; display: none; place-items: center; pointer-events: none; z-index: 1; }
.loading .pl-spinner { display: grid; }
.loading .pl-center .pl-big { opacity: 0; }
.spinner { width: 58px; height: 58px; border-radius: 50%; border: 4px solid rgba(255, 255, 255, .15); border-top-color: var(--accent); border-right-color: var(--accent2); animation: spin .8s linear infinite; }
.pl-flash { position: absolute; inset: 0; margin: auto; width: 96px; height: 96px; border-radius: 50%; display: grid; place-items: center; background: rgba(0, 0, 0, .45); opacity: 0; pointer-events: none; z-index: 2; }
.pl-flash svg { width: 44px; height: 44px; }
.pl-flash span { font-weight: 800; font-size: 16px; }
.pl-flash.show { animation: flash .6s ease-out; }
.pl-gesture { position: absolute; top: 18%; bottom: 22%; width: 34%; }
.pl-g-left { left: 0; } .pl-g-right { right: 0; }
.pl-epg { max-width: 560px; margin-bottom: 14px; }
.pl-epg:empty { display: none; }
.pl-epg-now { display: flex; flex-direction: column; gap: 2px; }
.pl-epg-now b { font-size: 17px; }
.pl-epg-time { font-size: 12.5px; color: #c4c4d4; font-weight: 600; }
.pl-epg-bar { height: 3px; border-radius: 3px; background: rgba(255, 255, 255, .2); margin: 8px 0; overflow: hidden; max-width: 320px; }
.pl-epg-bar i { display: block; height: 100%; background: var(--grad); }
.pl-epg-next { font-size: 13px; color: #b9b9c9; }
.pl-menu {
  position: absolute; right: 20px; bottom: 86px; width: min(360px, calc(100vw - 40px)); max-height: 60vh; overflow-y: auto; padding: 16px; border-radius: 18px;
  background: rgba(18, 18, 28, .95); backdrop-filter: blur(20px); box-shadow: var(--shadow), 0 0 0 1px var(--line2);
  opacity: 0; transform: translateY(10px); pointer-events: none; transition: .2s; z-index: 4;
}
.menu-open:not(.channels-open) .pl-menu { opacity: 1; transform: none; pointer-events: auto; }
.pl-menu-sec + .pl-menu-sec { margin-top: 14px; }
.pl-menu h4 { font-size: 12px; text-transform: uppercase; letter-spacing: .12em; color: var(--dim); margin-bottom: 8px; }
.pl-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.pl-chips button, .pl-chip-link { padding: 7px 12px; border-radius: 999px; background: rgba(255, 255, 255, .08); font-size: 13.5px; font-weight: 600; }
.pl-chips button.on { background: #fff; color: #000; }
.pl-channels {
  position: absolute; top: 0; right: 0; bottom: 0; width: min(360px, 88vw); background: rgba(10, 10, 16, .96); backdrop-filter: blur(20px);
  transform: translateX(100%); transition: transform .3s cubic-bezier(.2, .8, .2, 1); z-index: 5; display: flex; flex-direction: column;
  padding-top: env(safe-area-inset-top);
}
.channels-open .pl-channels { transform: none; }
.pl-ch-head { padding: 16px; }
.pl-ch-head input { width: 100%; height: 42px; border-radius: 999px; border: 1px solid var(--line2); background: var(--surface); padding: 0 16px; outline: 0; }
.pl-ch-list { flex: 1; overflow-y: auto; padding: 0 8px 20px; }
.pl-ch { display: flex; align-items: center; gap: 12px; width: 100%; padding: 8px; border-radius: 10px; text-align: left; }
.pl-ch:hover { background: rgba(255, 255, 255, .06); }
.pl-ch.on { background: rgba(139, 108, 255, .2); }
.pl-ch-logo { position: relative; width: 48px; height: 34px; border-radius: 7px; background: var(--surface2); display: grid; place-items: center; overflow: hidden; flex: none; }
.pl-ch-logo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 4px; background: var(--surface2); }
.pl-ch-logo b { font-size: 11px; text-transform: uppercase; }
.pl-ch-name { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pl-nextcard {
  position: absolute; right: 24px; bottom: 100px; width: min(340px, calc(100vw - 48px)); padding: 18px; border-radius: 18px; z-index: 4;
  background: rgba(18, 18, 28, .96); box-shadow: var(--shadow), 0 0 0 1px var(--line2); opacity: 0; transform: translateY(14px); pointer-events: none; transition: .3s;
}
.pl-nextcard.show { opacity: 1; transform: none; pointer-events: auto; }
.pl-nc-label { font-size: 12px; text-transform: uppercase; letter-spacing: .12em; color: var(--dim); font-weight: 800; }
.pl-nc-title { font-size: 16px; font-weight: 700; margin: 4px 0 14px; }
.pl-nc-actions { display: flex; gap: 8px; }
.pl-error { position: absolute; inset: 0; display: none; place-items: center; z-index: 6; background: rgba(0, 0, 0, .7); padding: 20px; }
.has-error .pl-error { display: grid; }
.has-error .pl-center { display: none; }
.pl-error-box { max-width: 460px; text-align: center; }
.pl-error-ico { width: 60px; height: 60px; border-radius: 50%; margin: 0 auto 14px; display: grid; place-items: center; font-size: 28px; font-weight: 900; background: rgba(255, 90, 106, .16); color: var(--danger); }
.pl-error h3 { font-size: 22px; margin-bottom: 8px; }
.pl-error p { color: #c8c8d6; margin: 0 0 20px; line-height: 1.55; }
.pl-error small { color: var(--muted); }
.pl-error-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }

/* ---------- Setup / profils ---------- */
body.bare .topbar, body.bare .bottomnav { display: none !important; }
.setup { min-height: 100vh; display: grid; place-items: center; padding: 40px 16px; position: relative; overflow: hidden; }
.setup-glow { position: fixed; inset: -20%; pointer-events: none; background:
  radial-gradient(40% 40% at 25% 30%, rgba(139, 108, 255, .35), transparent 70%),
  radial-gradient(35% 35% at 75% 70%, rgba(255, 77, 141, .25), transparent 70%),
  radial-gradient(30% 30% at 80% 15%, rgba(60, 160, 255, .18), transparent 70%);
  animation: drift 18s ease-in-out infinite alternate; filter: blur(20px); }
.setup-card {
  position: relative; width: 100%; max-width: 500px; padding: 34px 30px 26px; border-radius: 26px;
  background: rgba(16, 16, 26, .78); backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
  box-shadow: 0 0 0 1px var(--line2), 0 50px 100px -30px rgba(0, 0, 0, .9); animation: sheetIn .5s both;
}
.setup-card > .logo { margin-bottom: 22px; }
.setup-card h1 { font-size: 28px; font-weight: 900; }
.setup-sub { color: var(--muted); margin: 6px 0 22px; }
.setup-card .seg { margin-bottom: 20px; }
.setup .btn-primary { background: var(--grad); color: #fff; box-shadow: 0 12px 30px -10px rgba(194, 92, 255, .7); }
.setup .btn-primary:hover { filter: brightness(1.08); }
.setup-alt { text-align: center; margin-top: 16px; }
.legal { color: var(--dim); font-size: 11.5px; text-align: center; margin: 16px 0 0; line-height: 1.5; }
.field { display: block; margin-bottom: 14px; }
.field > span { display: block; font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 6px; }
.field input {
  width: 100%; height: 48px; padding: 0 14px; border-radius: 12px; background: rgba(5, 5, 10, .6); border: 1px solid var(--line2);
  outline: 0; transition: border-color .2s, box-shadow .2s; font-size: 15px;
}
.field input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(139, 108, 255, .2); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.drop { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 28px 16px; border: 2px dashed var(--line2); border-radius: 16px; cursor: pointer; text-align: center; margin-bottom: 14px; transition: .2s; }
.drop:hover, .drop.over { border-color: var(--accent); background: rgba(139, 108, 255, .08); }
.drop-ico { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: rgba(139, 108, 255, .16); color: var(--accent); }
.drop-ico svg { width: 22px; height: 22px; }
.drop small { color: var(--muted); }
.adv { margin: 4px 0 16px; }
.adv summary { cursor: pointer; color: var(--muted); font-size: 13.5px; font-weight: 600; margin-bottom: 12px; }
.form-err { display: none; background: rgba(255, 90, 106, .12); color: #ffb3bb; border: 1px solid rgba(255, 90, 106, .3); padding: 10px 14px; border-radius: 12px; font-size: 14px; margin-bottom: 14px; }
.form-err.show { display: block; animation: shake .4s; }
[hidden] { display: none !important; }

.profiles { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 36px; padding: 40px 16px; animation: fadeIn .4s both; }
.profiles h1 { font-size: clamp(30px, 5vw, 52px); font-weight: 900; text-align: center; }
.prof-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: clamp(16px, 3vw, 32px); }
.prof { display: flex; flex-direction: column; align-items: center; gap: 12px; color: var(--muted); transition: color .2s; }
.prof:hover { color: #fff; }
.prof-av {
  width: clamp(92px, 12vw, 136px); aspect-ratio: 1; border-radius: 22px; display: grid; place-items: center; position: relative;
  font-size: clamp(36px, 5vw, 56px); font-weight: 900; color: #fff;
  background: radial-gradient(100% 100% at 20% 0%, rgba(255, 255, 255, .35), transparent 55%), var(--c);
  transition: transform .2s, box-shadow .2s; box-shadow: 0 20px 40px -14px color-mix(in srgb, var(--c) 70%, transparent);
}
.prof:hover .prof-av { transform: translateY(-4px); box-shadow: 0 0 0 3px #fff, 0 20px 40px -14px color-mix(in srgb, var(--c) 70%, transparent); }
.prof-av.add { background: transparent; border: 2px dashed var(--line2); box-shadow: none; color: var(--muted); }
.prof-av.add svg { width: 42px; height: 42px; }
.prof-av.big { width: 120px; font-size: 52px; margin: 0 auto 20px; }
.prof-av.sm { width: 40px; border-radius: 11px; font-size: 18px; }
.prof-av.xs { width: 26px; border-radius: 8px; font-size: 13px; box-shadow: none; }
.prof-edit { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(0, 0, 0, .5); border-radius: inherit; }
.prof-edit svg { width: 34px; height: 34px; }
.prof-name { font-weight: 700; font-size: 16px; display: flex; flex-direction: column; align-items: center; }
.prof-name small { font-size: 11px; color: var(--gold); font-weight: 700; }
.prof-form { width: 100%; max-width: 420px; }
.prof-line { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.prof-line b { margin-right: auto; }
.colors { display: flex; gap: 12px; margin: 6px 0 14px; }
.color { width: 34px; height: 34px; border-radius: 50%; background: var(--c); transition: transform .2s; }
.color.on { box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px #fff; }
.switch-row, .select-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.switch-row > span, .select-row > span { display: flex; flex-direction: column; gap: 2px; }
.switch-row small, .select-row small { color: var(--muted); font-size: 13px; }
.switch-row input { position: absolute; opacity: 0; pointer-events: none; }
.switch { width: 48px; height: 28px; border-radius: 99px; background: var(--surface2); position: relative; flex: none; transition: background .2s; box-shadow: inset 0 0 0 1px var(--line2); }
.switch::after { content: ''; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; transition: transform .2s; }
.switch-row input:checked + .switch { background: var(--accent); }
.switch-row input:checked + .switch::after { transform: translateX(20px); }
.switch-row input:focus-visible + .switch { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Réglages */
.settings .set-card { max-width: 860px; background: var(--surface); border-radius: 20px; padding: 22px 24px; margin-bottom: 16px; box-shadow: inset 0 0 0 1px var(--line); }
.set-card h2 { font-size: 18px; font-weight: 800; margin-bottom: 14px; }
.set-card .switch-row:last-child, .set-card .select-row:last-child { border-bottom: 0; }
.pl-list { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.pl-item { display: flex; align-items: center; gap: 6px; padding: 6px; border-radius: 14px; background: var(--bg2); box-shadow: inset 0 0 0 1px var(--line); }
.pl-item.on { box-shadow: inset 0 0 0 1.5px var(--accent); }
.pl-pick { flex: 1; display: flex; align-items: center; gap: 12px; text-align: left; padding: 6px 8px; min-width: 0; }
.pl-pick > span:last-child { display: flex; flex-direction: column; min-width: 0; }
.pl-pick small { color: var(--muted); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.radio { width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--line2); flex: none; }
.pl-item.on .radio { border: 6px solid var(--accent); }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.stats > div { background: var(--bg2); border-radius: 14px; padding: 14px 16px; box-shadow: inset 0 0 0 1px var(--line); }
.stats small { display: block; color: var(--muted); font-size: 12.5px; }
.stats b { font-size: 18px; }
.ok { color: var(--ok); } .ko { color: var(--danger); }

/* ---------- Loader / toast ---------- */
.loader { position: fixed; inset: 0; z-index: 200; display: none; place-items: center; background: radial-gradient(60% 50% at 50% 40%, #16122a, var(--bg)); }
.loader.show { display: grid; animation: fadeIn .2s both; }
.loader-box { display: flex; flex-direction: column; align-items: center; gap: 22px; }
.loader .logo { animation: breathe 2s ease-in-out infinite; }
.loader-bar { width: 260px; height: 4px; border-radius: 4px; background: rgba(255, 255, 255, .1); overflow: hidden; }
.loader-bar i { display: block; width: 0; height: 100%; background: var(--grad); transition: width .4s ease; }
.loader-msg { color: var(--muted); font-size: 14px; font-weight: 500; }
.toast {
  position: fixed; left: 50%; bottom: calc(24px + var(--safe-b)); z-index: 300; transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  display: flex; align-items: center; gap: 14px; max-width: min(560px, calc(100vw - 32px)); padding: 12px 18px; border-radius: 14px;
  background: rgba(30, 30, 46, .96); backdrop-filter: blur(16px); box-shadow: var(--shadow), 0 0 0 1px var(--line2); font-weight: 600; font-size: 14px; transition: .3s cubic-bezier(.2, .8, .2, 1);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.toast.error { box-shadow: var(--shadow), 0 0 0 1px rgba(255, 90, 106, .5); }
.toast button { color: var(--accent); font-weight: 800; white-space: nowrap; }
body.playing .toast { bottom: 110px; }

/* ---------- Mobile ---------- */
@media (max-width: 1000px) {
  .search-pill { min-width: 0; }
  .search-pill span, .search-pill kbd { display: none; }
  .topnav a { padding: 8px 10px; }
}
@media (max-width: 760px) {
  :root { --top-h: 58px; --card-w: 31vw; --wide-w: 72vw; }
  body { padding-bottom: calc(64px + var(--safe-b)); }
  .topbar { gap: 12px; padding-top: env(safe-area-inset-top); height: calc(var(--top-h) + env(safe-area-inset-top)); }
  .topnav { display: none; }
  .logo-text { font-size: 18px; }
  .search-pill { width: 40px; height: 40px; padding: 0; justify-content: center; border-radius: 50%; }
  .search-pill svg { width: 20px; height: 20px; }
  .bottomnav {
    display: flex; position: fixed; inset: auto 0 0 0; z-index: 45; height: calc(64px + var(--safe-b)); padding-bottom: var(--safe-b);
    background: rgba(9, 9, 15, .92); backdrop-filter: blur(20px) saturate(1.4); -webkit-backdrop-filter: blur(20px) saturate(1.4); border-top: 1px solid var(--line);
  }
  .bottomnav a { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: var(--dim); font-size: 10.5px; font-weight: 700; position: relative; }
  .bottomnav svg { width: 24px; height: 24px; transition: transform .2s; }
  .bottomnav a.on { color: #fff; }
  .bottomnav a.on svg { transform: translateY(-1px); color: var(--accent); filter: drop-shadow(0 0 10px rgba(139, 108, 255, .6)); }
  .toast { bottom: calc(80px + var(--safe-b)); }

  .hero { height: 74vh; min-height: 470px; }
  .hero-content { left: 16px; right: 16px; bottom: 120px; max-width: none; text-align: center; }
  .hero-kicker { margin-bottom: 8px; }
  .hero-meta { justify-content: center; font-size: 13px; margin: 10px 0 8px; }
  .hero-plot { font-size: 14px; -webkit-line-clamp: 2; margin-bottom: 18px; }
  .hero-actions { justify-content: center; }
  .hero-actions .btn-lg { height: 46px; padding: 0 20px; font-size: 15px; flex: 1; max-width: 200px; }
  .hero-shade { background: linear-gradient(0deg, var(--bg) 0%, rgba(7, 7, 12, .75) 35%, rgba(7, 7, 12, .15) 65%, rgba(7, 7, 12, .55) 100%); }
  .hero-slide.is-poster .hero-art { display: block; right: 0; left: 0; margin: auto; top: 13%; transform: none; width: 44vw; max-width: 220px; }
  .hero-slide.is-poster .hero-content { bottom: 92px; }
  .hero-slide.is-poster .hero-plot { display: none; }
  .hero-slide.is-poster .hero-title { font-size: 28px; }
  .hero-dots { left: 0; right: 0; justify-content: center; bottom: 76px; }
  .rows { margin-top: -50px; }
  .hero + .browse-bar { margin-top: -40px; }
  .row { margin-bottom: 14px; }
  .row-track { gap: 9px; padding-bottom: 12px; }
  .card-title { font-size: 12.5px; }
  .card-meta { padding-top: 6px; }
  .card:not(.card-wide) .card-sub { display: none; }
  .card-rating { font-size: 10.5px; padding: 2px 5px; top: 5px; left: 5px; }
  .grid { grid-template-columns: repeat(3, 1fr); gap: 16px 9px; }
  .grid-sm { grid-template-columns: repeat(3, 1fr); }
  .pf-tile { width: 42vw; }
  .page { padding-top: calc(var(--top-h) + 16px); }
  .toolbar .filter-input { max-width: none; flex-basis: 100%; }
  .browse-bar .select select { max-width: 52vw; }

  .live { grid-template-columns: 1fr; gap: 12px; padding-top: calc(var(--top-h) + 8px); }
  .live-cats {
    position: sticky; top: var(--top-h); z-index: 20; max-height: none; display: flex; gap: 6px; overflow-x: auto; overflow-y: hidden;
    margin: 0 calc(-1 * var(--pad)); padding: 10px var(--pad); background: rgba(7, 7, 12, .92); backdrop-filter: blur(16px); scrollbar-width: none;
  }
  .live-cats::-webkit-scrollbar { display: none; }
  .live-cats-title { display: none; }
  .live-cats a { flex: none; padding: 8px 14px; border-radius: 999px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
  .live-cats a.on { background: #fff; color: #0a0a10; }
  .live-cats a.on small { color: #555; }
  .live-cats a.on::before { display: none; }
  .ch-grid { grid-template-columns: 1fr; gap: 8px; }
  .ch-card.compact { width: 78vw; }

  .sheet { margin: 0; border-radius: 0; min-height: 100vh; animation: sheetUp .35s cubic-bezier(.2, .8, .2, 1) both; }
  .sheet-close { top: calc(12px + env(safe-area-inset-top)); right: 12px; }
  .d-hero { aspect-ratio: auto; min-height: 0; flex-direction: column; align-items: stretch; }
  .d-bg { position: relative; aspect-ratio: 16/10; inset: auto; }
  .d-hero:not(.trailer-on) .d-bg::after { content: ''; position: absolute; inset: 0; background: linear-gradient(0deg, var(--sheet), transparent 55%); }
  .d-shade { display: none; }
  .d-hero-in { margin-top: -90px; padding: 0 16px; gap: 14px; }
  .trailer-on .d-hero-in { margin-top: 12px; }
  .d-poster { width: 104px; border-radius: 10px; box-shadow: 0 10px 24px -10px rgba(0, 0, 0, .8), 0 0 0 1px rgba(255, 255, 255, .12); }
  .d-title { font-size: 26px; }
  .d-meta { font-size: 13px; margin: 10px 0 0; }
  .d-actions { position: relative; margin: 0; }
  .d-head .d-actions, .d-head .d-progress { display: none; }
  .d-body { padding: 16px; }
  .d-progress { max-width: none; }
  .ep { grid-template-columns: 128px 1fr; gap: 12px; padding: 8px 0; }
  .ep-num { display: none; }
  .ep-plot { -webkit-line-clamp: 2; font-size: 12.5px; }
  .ep-title { flex-direction: column; gap: 0; }
  .field-row { grid-template-columns: 1fr; gap: 0; }
  .setup-card { padding: 28px 20px 22px; }

  .pl-vol { display: none; }
  .pl-time { font-size: 12.5px; }
  .pl-row .pl-btn { width: 42px; height: 42px; }
  .pl-row .pl-btn svg { width: 24px; height: 24px; }
  .pl-next-btn span { display: none; }
  .pl-next-btn { padding: 0 !important; width: 42px !important; }
  .pl-pip { display: inline-grid; }
  .pl-title { font-size: 16px; }
  .pl-menu { right: 10px; left: 10px; width: auto; bottom: 70px; }
  .pl-nextcard { right: 12px; left: 12px; width: auto; bottom: 80px; }
}
/* actions de la fiche : sous l'en-tête sur mobile */
.d-mobile-actions { display: none; }
@media (max-width: 760px) { .d-mobile-actions { display: flex; flex-direction: column; gap: 10px; padding: 16px 16px 0; } .d-mobile-actions .btn { width: 100%; } .d-mobile-actions .d-actions-row { display: flex; gap: 10px; } .d-mobile-actions .d-actions-row .btn { flex: 1; padding: 0 10px; font-size: 14px; } }

@media (orientation: landscape) and (max-height: 500px) {
  .hero { height: 100vh; }
  .hero-slide.is-poster .hero-art { display: none; }
}

/* ---------- Animations ---------- */
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes fadeIn { from { opacity: 0; } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(18px); } }
@keyframes sheetIn { from { opacity: 0; transform: translateY(30px) scale(.98); } }
@keyframes sheetUp { from { transform: translateY(40px); opacity: 0; } }
@keyframes floatIn { from { opacity: 0; transform: translateY(-40%) rotate(6deg) scale(.92); } }
@keyframes kenburns { from { transform: scale(1.12); } to { transform: scale(1.0); } }
@keyframes shimmer { from { background-position: 100% 0; } to { background-position: -100% 0; } }
@keyframes pulse { 50% { opacity: .3; } }
@keyframes pop { 50% { transform: scale(1.35); } }
@keyframes flash { 0% { opacity: .9; transform: scale(.8); } 100% { opacity: 0; transform: scale(1.25); } }
@keyframes breathe { 50% { opacity: .65; transform: scale(.97); } }
@keyframes shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }
@keyframes drift { to { transform: translate(5%, -4%) rotate(8deg); } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

/* ---------- Ajouts mobile (v1.1) ---------- */
@media (max-width: 760px) {
  .top-result { min-height: 0; padding: 14px; gap: 14px; border-radius: 16px; }
  .tr-plot { display: none; }
  .tr-title { font-size: 22px; }
  .hero-sound { right: 16px; bottom: auto; top: calc(var(--top-h) + env(safe-area-inset-top) + 14px); }
  .trailer-sound { top: calc(14px + env(safe-area-inset-top)); right: 64px; }
  .pf-tile { width: 40vw; }
  .top-card { width: calc(var(--card-w) * 1.38); }
  .top-num { -webkit-text-stroke-width: 2px; }
  .chip-pf { height: 38px; padding: 0 14px; }
  .row-top .row-head h2 small { display: none; }
  .row-head h2 { font-size: 17px; }
  .top-card { width: calc(var(--card-w) * 1.42); }
  .top-card.two { width: calc(var(--card-w) * 1.66); }
}

.dd-ver { padding: 8px 12px 4px; font-size: 11.5px; color: var(--dim); }

/* ==========================================================================
   v2 — éléments communs
   ========================================================================== */
.mchips, .hero-card, .d-icons, .d-tabs, .season-select, .ep-n { display: none; }
.tab-hidden { }
::cue { background: rgba(0, 0, 0, .72); color: #fff; font-family: var(--font); font-weight: 600; line-height: 1.35; }
.catsheet {
  position: fixed; inset: 0; z-index: 80; display: none; overflow-y: auto; overscroll-behavior: contain;
  background: rgba(8, 8, 12, .86); backdrop-filter: blur(22px) saturate(1.2); -webkit-backdrop-filter: blur(22px) saturate(1.2);
  padding: calc(env(safe-area-inset-top) + 70px) 20px calc(140px + var(--safe-b));
}
.catsheet.open { display: block; animation: fadeIn .25s both; }
.cs-list { display: flex; flex-direction: column; align-items: center; gap: 4px; max-width: 520px; margin: 0 auto; }
.cs-list h3 { font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--dim); margin: 22px 0 8px; }
.cs-list a { display: flex; align-items: center; justify-content: center; min-height: 46px; padding: 6px 16px; font-size: 19px; font-weight: 600; color: #cfcfdb; text-align: center; border-radius: 10px; }
.cs-list a:hover, .cs-list a:active { color: #fff; background: rgba(255, 255, 255, .06); }
.cs-list .pf-logo { height: 26px; }
.cs-list .pf-sm.pf-k-paramount, .cs-list .pf-sm.pf-k-crunchyroll, .cs-list .pf-sm.pf-k-arte, .cs-list .pf-sm.pf-k-disney { height: 36px; }
.cs-close {
  position: fixed; left: 50%; bottom: calc(28px + var(--safe-b)); transform: translateX(-50%); width: 58px; height: 58px; border-radius: 50%;
  background: #fff; color: #000; display: grid; place-items: center; box-shadow: 0 10px 30px rgba(0, 0, 0, .6);
}
.cs-close svg { width: 28px; height: 28px; }
.d-tabs { gap: 22px; border-top: 1px solid var(--line); margin: 6px 0 16px; }
.d-tabs button { padding: 12px 0 10px; font-weight: 800; font-size: 15px; color: var(--muted); border-top: 3px solid transparent; margin-top: -1px; }
.d-tabs button.on { color: #fff; border-top-color: var(--accent2); }

/* ==========================================================================
   v2 — TÉLÉPHONE : style appli de streaming (bord à bord, noir profond)
   ========================================================================== */
@media (max-width: 760px) {
  :root { --bg: #000; --sheet: #000; --pad: 12px; --card-w: 29vw; --wide-w: 62vw; --top-h: 52px; }
  body { background: #000; }

  /* -- barre du haut + puces -- */
  .topbar { flex-wrap: wrap; align-content: flex-start; height: auto; min-height: calc(var(--top-h) + env(safe-area-inset-top)); padding: env(safe-area-inset-top) 12px 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, .85), rgba(0, 0, 0, 0)); transition: background .3s, transform .3s; }
  .topbar.solid { background: rgba(0, 0, 0, .82); backdrop-filter: blur(20px) saturate(1.5); -webkit-backdrop-filter: blur(20px) saturate(1.5); box-shadow: none; }
  .topbar > .logo { height: var(--top-h); }
  .logo-mark { width: 26px; height: 26px; border-radius: 8px; }
  .logo-text { font-size: 19px; letter-spacing: .14em; }
  .top-actions { height: var(--top-h); gap: 6px; }
  .search-pill { background: none; border: 0; width: 40px; }
  .search-pill svg { width: 24px; height: 24px; color: #fff; }
  .avatar-btn { width: 32px; height: 32px; border-radius: 8px; font-size: 14px; }
  body[data-page="home"] .mchips, body[data-page="films"] .mchips, body[data-page="series"] .mchips {
    display: flex; width: 100%; gap: 8px; padding: 2px 0 10px; overflow-x: auto; scrollbar-width: none;
  }
  .mchips::-webkit-scrollbar { display: none; }
  .mchips a, .mchips button {
    flex: none; display: inline-flex; align-items: center; gap: 4px; height: 32px; padding: 0 14px; border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, .45); color: #fff; font-size: 14px; font-weight: 600; background: rgba(0, 0, 0, .2);
  }
  .mchips svg { width: 18px; height: 18px; }
  .mchips a.on { background: rgba(255, 255, 255, .92); color: #000; border-color: transparent; }
  body[data-page="films"] .mchips a[data-nav="series"], body[data-page="series"] .mchips a[data-nav="films"] { display: none; }
  .mchips { max-height: 50px; transition: max-height .25s, opacity .2s, padding .25s; }
  body.chips-hidden .mchips { max-height: 0 !important; opacity: 0; padding-top: 0 !important; padding-bottom: 0 !important; overflow: hidden; }

  /* -- barre du bas -- */
  .bottomnav { height: calc(58px + var(--safe-b)); background: rgba(0, 0, 0, .9); border-top: 0; }
  .bottomnav a { font-size: 10.5px; font-weight: 600; color: #8c8c96; gap: 4px; }
  .bottomnav a.on { color: #fff; }
  .bottomnav a.on svg { color: #fff; filter: none; transform: none; }
  body { padding-bottom: calc(58px + var(--safe-b)); }
  .toast { bottom: calc(72px + var(--safe-b)); border-radius: 10px; }

  /* -- grande affiche d'accueil (comme les applis) -- */
  .hero { height: auto; min-height: 0; padding: calc(env(safe-area-inset-top) + 132px) 0 8px; overflow: visible; }
  .ep-n { display: inline; }
  body[data-page="other"] .hero, body[data-page="tv"] .hero { padding-top: calc(env(safe-area-inset-top) + 62px); }
  .hero-slide { position: absolute; inset: 0; }
  .hero-slide.on { position: relative; }
  .hero-bg { position: absolute; inset: -40px 0 auto; height: 115%; overflow: hidden; }
  .hero-bg img { filter: blur(48px) saturate(1.6) brightness(.65); transform: scale(1.4); animation: none !important; }
  .hero-slide.is-poster .hero-bg img { filter: blur(48px) saturate(1.6) brightness(.65); }
  .hero-bg .trailer-bg, .hero-content, .hero-art, .hero-sound { display: none !important; }
  .hero-shade { background: linear-gradient(180deg, rgba(0, 0, 0, .2) 0%, rgba(0, 0, 0, .1) 40%, #000 92%); }
  .hero-card {
    display: block; position: relative; z-index: 2; margin: 0 auto; width: calc(100% - 32px); max-width: 420px; aspect-ratio: 2/2.9; max-height: 66vh;
    border-radius: 12px; overflow: hidden; box-shadow: 0 20px 50px -10px rgba(0, 0, 0, .8), 0 0 0 1px rgba(255, 255, 255, .14);
  }
  .hc-img { position: absolute; inset: 0; background: linear-gradient(160deg, hsl(var(--h) 55% 38%), hsl(calc(var(--h) + 45) 60% 14%)); }
  .hc-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
  .hc-shade { position: absolute; inset: 0; background: linear-gradient(0deg, rgba(0, 0, 0, .92) 0%, rgba(0, 0, 0, .45) 28%, transparent 52%); }
  .hc-body { position: absolute; left: 0; right: 0; bottom: 0; padding: 0 14px 14px; text-align: center; }
  .hc-title { font-size: 26px; font-weight: 900; letter-spacing: -.03em; line-height: 1.05; text-shadow: 0 2px 16px rgba(0, 0, 0, .7); margin-bottom: 8px; }
  .hc-tags { display: flex; justify-content: center; flex-wrap: wrap; gap: 4px 0; font-size: 13px; color: #e8e8ee; margin-bottom: 12px; }
  .hc-tags span + span::before { content: '•'; margin: 0 7px; color: #9a9aa6; }
  .hc-actions { display: flex; gap: 10px; }
  .hc-actions .btn { flex: 1; height: 40px; border-radius: 5px; font-size: 15px; padding: 0 8px; }
  .hc-list { background: rgba(60, 60, 64, .82); color: #fff; backdrop-filter: blur(10px); }
  .hc-list.on svg { color: #fff; }
  .hero-dots { position: relative; z-index: 2; inset: auto; justify-content: center; margin: 12px 0 0; }
  .hero-dots button { width: 6px; height: 6px; }
  .hero-dots button.on { width: 18px; }
  .rows, .hero + .browse-bar { margin-top: 6px; }
  .browse-bar { padding: 0 12px; margin: 4px 0 2px; }
  .browse-bar h1 { display: none; }

  /* -- rangées compactes, sans titres sous les affiches -- */
  .row { margin: 0 0 16px; }
  .row-head { padding: 0 12px; margin-bottom: 0; }
  .row-head h2 { font-size: 17px; font-weight: 800; letter-spacing: -.01em; }
  .row-more { font-size: 0; }
  .row-more svg { width: 22px; height: 22px; color: #fff; }
  .row-track { gap: 7px; padding: 8px 12px 6px; scroll-padding: 0 12px; }
  .card-img { border-radius: 5px; box-shadow: none; }
  .card:not(.card-wide) .card-meta { display: none; }
  .card-rating { display: none; }
  .card-fallback span { font-size: 13px; }
  .card-wide .card-meta { padding-top: 6px; }
  .card-wide .card-title { font-size: 13px; }
  .card-wide .card-sub { display: block; font-size: 11.5px; }
  .card-playicon { width: 42px; height: 42px; opacity: .95; transform: none; }
  .card-progress { height: 3px; }
  .card-progress i { background: #e50914; }
  .top-card { width: calc(var(--card-w) * 1.45); }
  .top-card.two { width: calc(var(--card-w) * 1.7); }
  .row-top .row-track { gap: 10px; }
  .pf-tile { width: 38vw; border-radius: 8px; }
  .pf-count { display: none; }
  .ch-card.compact { width: 72vw; }

  /* -- pages -- */
  .page { padding: calc(var(--top-h) + env(safe-area-inset-top) + 10px) 12px 30px; }
  .page-head h1 { font-size: 24px; }
  .grid { gap: 12px 7px; }
  .grid .card-meta { display: none; }
  .search-big { top: calc(var(--top-h) + env(safe-area-inset-top)); height: 48px; border-radius: 6px; background: #2a2a2e; box-shadow: none; padding: 0 6px 0 12px; }
  .search-big input { font-size: 16px; }
  .search-big:focus-within { box-shadow: none; }
  .live { padding-top: calc(var(--top-h) + env(safe-area-inset-top)); }
  .live-cats { top: calc(var(--top-h) + env(safe-area-inset-top)); background: #000; }
  .ch-card { border-radius: 8px; background: #141416; }

  /* -- fiche détail plein écran -- */
  .sheet { background: #000; }
  .sheet-back { background: #000; }
  .sheet-close { top: calc(10px + env(safe-area-inset-top)); right: 10px; width: 34px; height: 34px; background: rgba(30, 30, 30, .85); }
  .sheet-close svg { width: 20px; height: 20px; }
  .d-hero { display: block; padding-top: env(safe-area-inset-top); background: #000; }
  .d-bg { position: relative; inset: auto; aspect-ratio: 16/9; width: 100%; }
  .d-hero:not(.trailer-on) .d-bg::after { display: none; }
  .d-hero.is-poster .d-bg img { filter: blur(26px) brightness(.55); transform: scale(1.3); }
  .trailer-sound { top: auto; bottom: 10px; right: 10px; width: 34px; height: 34px; }
  .trailer-sound svg { width: 18px; height: 18px; }
  .d-hero-in { margin: 0; padding: 12px 12px 0; }
  .d-poster { display: none; }
  .d-title { font-size: 23px; font-weight: 800; }
  .d-meta { margin: 6px 0 0; font-size: 13px; gap: 4px 10px; color: #b5b5bf; }
  .pill { font-size: 11px; padding: 1px 5px; border-radius: 3px; }
  .d-mobile-actions { padding: 12px 12px 0; gap: 8px; }
  .d-mobile-actions > .btn, .d-mobile-actions .d-actions-row .btn { height: 42px; border-radius: 5px; font-size: 15px; }
  .d-mobile-actions .d-actions-row .btn { background: #262628; }
  .d-mobile-actions [data-act="watch"], .d-mobile-actions [data-act="fav"] { display: none; }
  .d-mobile-actions .d-actions-row:empty { display: none; }
  .d-progress { height: 3px; margin-top: 4px; }
  .d-progress i { background: #e50914; }
  .d-icons { display: flex; justify-content: flex-start; gap: 34px; padding: 18px 26px 2px; }
  .di { display: flex; flex-direction: column; align-items: center; gap: 6px; color: #d0d0d8; font-size: 11.5px; font-weight: 600; min-width: 56px; }
  .di svg { width: 26px; height: 26px; color: #fff; }
  .di.on .heart-on { color: #ff4d6d; }
  .d-body { padding: 12px; }
  .d-plot { font-size: 14px; line-height: 1.5; color: #e2e2ea; margin-bottom: 10px; }
  .d-facts { display: block; margin-bottom: 14px; }
  .d-facts > div { display: flex; gap: 6px; font-size: 12.5px; margin-bottom: 3px; }
  .d-facts dt { font-size: 12.5px; text-transform: none; letter-spacing: 0; color: #8f8f9a; font-weight: 500; margin: 0; }
  .d-facts dt::after { content: ' :'; }
  .d-facts dd { font-size: 12.5px; color: #bfbfca; }
  .d-versions h4 { margin-bottom: 8px; }
  .d-tabs { display: flex; }
  .tab-hidden { display: none !important; }
  .eps-head { margin-bottom: 6px; }
  .eps-head h3, .eps-head .seasons { display: none; }
  .season-select { display: inline-flex; }
  .season-select select {
    appearance: none; -webkit-appearance: none; background: #262628 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23fff'%3E%3Cpath d='M7.4 8.6 12 13.2l4.6-4.6L18 10l-6 6-6-6z'/%3E%3C/svg%3E") no-repeat right 8px center / 20px;
    color: #fff; border: 0; border-radius: 5px; height: 38px; padding: 0 36px 0 14px; font-weight: 700; font-size: 15px;
  }
  .ep { grid-template-columns: 124px 1fr; grid-template-areas: "thumb title" "plot plot"; gap: 8px 12px; padding: 10px 0 14px; border-radius: 0; }
  .ep:hover { background: none; }
  .ep-thumb { grid-area: thumb; border-radius: 4px; }
  .ep-play { opacity: 1; width: 32px; height: 32px; background: rgba(0, 0, 0, .45); }
  .ep-info { display: contents; }
  .ep-title { grid-area: title; align-self: center; flex-direction: column; align-items: flex-start; gap: 2px; }
  .ep-title b { font-size: 14px; font-weight: 600; }
  .ep-title small { font-size: 12px; }
  .ep-plot { grid-area: plot; -webkit-line-clamp: 3; font-size: 12.5px; color: #a8a8b4; }
  .d-similar h3 { display: none; }
  .grid-sm { grid-template-columns: repeat(3, 1fr); gap: 7px; }
  .grid-sm .card-meta { display: none; }

  /* -- lecteur -- */
  .pl-top { padding-top: max(12px, env(safe-area-inset-top)); }
  .pl-progress::before, .pl-buf, .pl-fill { height: 4px; }
  .pl-fill { background: #e50914; }
  .pl-thumb { transform: translateX(-50%) scale(.8); background: #e50914; box-shadow: none; }
}

/* Page plateforme */
.pf-bar { gap: 22px; }
.pf-bar .h1-logo { margin: 0; }
.pf-bar .seg small { opacity: .6; margin-left: 4px; }
@media (max-width: 760px) {
  .pf-bar { flex-direction: column; align-items: flex-start; gap: 10px; }
  .pf-bar .h1-logo { display: flex; min-height: 40px; }
  .pf-bar .pf-xl { height: 34px; }
  .pf-bar .pf-xl.pf-k-paramount, .pf-bar .pf-xl.pf-k-crunchyroll, .pf-bar .pf-xl.pf-k-arte, .pf-bar .pf-xl.pf-k-disney { height: 48px; }
  .pf-bar .seg { max-width: 100%; }
}

/* ==========================================================================
   v2.2 — fluidité et animations
   ========================================================================== */
.card-img img, .hc-img img, .d-bg > img, .ep-thumb img, .hero-bg > img, .tr-poster img, .tr-bg img, .d-poster img, .ch-logo img, .hist-img img {
  opacity: 0; transition: opacity .45s ease;
}
.card-img img.ld, .hc-img img.ld, .d-bg > img.ld, .ep-thumb img.ld, .hero-bg > img.ld, .tr-poster img.ld, .tr-bg img.ld, .d-poster img.ld, .ch-logo img.ld, .hist-img img.ld { opacity: 1; }
.tr-bg img.ld { opacity: 1; }
.card-fallback { transition: opacity .3s; }
.card-img:has(img.ld) .card-fallback { opacity: 0; }
/* rangées qui arrivent en douceur */
.rows > .row, .tops-slot > .row, #pf-themes > .row, #pf-popular > .row { animation: rowIn .55s cubic-bezier(.2, .8, .2, 1) both; }
.rows > .row:nth-child(2) { animation-delay: .05s; } .rows > .row:nth-child(3) { animation-delay: .1s; }
.rows > .row:nth-child(4) { animation-delay: .15s; } .rows > .row:nth-child(5) { animation-delay: .2s; }
@keyframes rowIn { from { opacity: 0; transform: translateY(14px); } }
/* appui sur une affiche */
.card, .top-card, .pf-tile, .ch-card, .ep, .btn, .di, .chip { -webkit-tap-highlight-color: transparent; }
.card:active .card-img, .top-card:active .card-img { transform: scale(.955); transition-duration: .12s; }
.pf-tile:active { transform: scale(.96); }
.btn:active, .di:active { transform: scale(.94); }
/* fiche : fermeture animée */
.modal.closing { display: block; pointer-events: none; }
.modal.closing .sheet { animation: sheetOut .24s ease-in both; }
.modal.closing .sheet-back { animation: fadeOut .24s ease-in both; }
@keyframes sheetOut { to { opacity: 0; transform: translateY(24px) scale(.985); } }
@keyframes fadeOut { to { opacity: 0; } }
/* barre du bas : petit rebond de l'icône active */
.bottomnav a.on svg { animation: navPop .35s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes navPop { 40% { transform: scale(1.18); } }
/* grande affiche : léger zoom d'entrée */
.hero-slide.on .hero-card { animation: cardIn .7s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes cardIn { from { opacity: 0; transform: scale(.94) translateY(10px); } }
/* transitions entre pages (View Transitions) */
::view-transition-old(root) { animation: .18s ease-out both fadeOut; }
::view-transition-new(root) { animation: .28s cubic-bezier(.2, .8, .2, 1) both pageIn; }
@keyframes pageIn { from { opacity: 0; transform: translateY(8px); } }
/* rendu plus léger des rangées hors écran */
.rows > .row { content-visibility: auto; contain-intrinsic-size: auto 300px; }
.eps-retry { text-align: center; padding: 20px 0; color: var(--muted); }
.eps-retry p { margin: 0 0 12px; }
@media (max-width: 760px) {
  .sheet { animation: sheetUpApp .38s cubic-bezier(.16, 1, .3, 1) both; }
  @keyframes sheetUpApp { from { transform: translateY(100%); } }
  .modal.closing .sheet { animation: sheetDownApp .26s cubic-bezier(.4, 0, 1, 1) both; }
  @keyframes sheetDownApp { to { transform: translateY(100%); } }
}
@media (prefers-reduced-motion: reduce) { .rows > .row { animation: none; } }

.setup-restore { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); text-align: center; display: flex; flex-direction: column; gap: 8px; }
.setup-restore span { font-weight: 700; }
.setup-restore small { color: var(--muted); font-size: 12px; }
.diag { background: #0b0b10; border: 1px solid var(--line); border-radius: 10px; padding: 10px; font-size: 11.5px; white-space: pre-wrap; word-break: break-word; color: #ffb3bb; max-height: 240px; overflow: auto; }

.pl-err-detail { margin: -6px 0 16px; font-size: 12px; color: var(--muted); text-align: left; }
.pl-err-detail summary { cursor: pointer; text-align: center; }
.pl-err-detail code { display: block; margin-top: 8px; padding: 8px 10px; border-radius: 8px; background: rgba(255, 255, 255, .06); color: #ffb3bb; white-space: pre-wrap; word-break: break-word; font-size: 11px; }


/* ===== v3.4 : barre du bas « liquid glass », menu Catégories, tops ===== */
.cs-top { position: sticky; top: calc(env(safe-area-inset-top) - 58px); z-index: 2; max-width: 520px; margin: -12px auto 8px; padding: 6px 0 10px; }
.cs-search { display: flex; align-items: center; gap: 10px; height: 44px; padding: 0 14px; border-radius: 14px; background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .12); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); }
.cs-search svg { width: 18px; height: 18px; color: var(--dim); flex: none; }
.cs-search input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; color: #fff; font-size: 16px; }
.cs-list a { gap: 10px; }
.cs-list a small { font-size: 12px; font-weight: 600; color: var(--dim); background: rgba(255, 255, 255, .08); padding: 2px 7px; border-radius: 999px; }
.cs-list a[hidden], .cs-list h3[hidden] { display: none; }
.hero-card { cursor: pointer; }
.tops-slot.loading .top-card.skel { flex: none; width: 120px; aspect-ratio: 2 / 3; border-radius: 8px; background: linear-gradient(100deg, rgba(255,255,255,.05) 30%, rgba(255,255,255,.11) 50%, rgba(255,255,255,.05) 70%); background-size: 300% 100%; animation: skel 1.4s infinite linear; }
@keyframes skel { from { background-position: 100% 0; } to { background-position: -100% 0; } }

@media (max-width: 760px) {
  body:not([data-root="1"]) .mchips { display: none !important; }
  body { padding-bottom: calc(76px + var(--safe-b)); }
  .toast { bottom: calc(80px + var(--safe-b)); }
  .bottomnav {
    --i: 0;
    inset: auto 12px max(6px, calc(var(--safe-b) - 22px)) 12px; height: 62px; padding: 6px; border-radius: 32px; border: 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, .16), rgba(255, 255, 255, .06)) , rgba(22, 22, 28, .38);
    backdrop-filter: blur(26px) saturate(190%) brightness(1.08); -webkit-backdrop-filter: blur(26px) saturate(190%) brightness(1.08);
    box-shadow: 0 14px 34px rgba(0, 0, 0, .5), inset 0 1px 0 rgba(255, 255, 255, .35), inset 0 -1px 0 rgba(255, 255, 255, .08), inset 0 0 0 1px rgba(255, 255, 255, .12);
    overflow: hidden;
  }
  /* reflet du verre */
  .bottomnav::before { content: ''; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
    background: radial-gradient(120% 90% at 50% -30%, rgba(255, 255, 255, .22), transparent 60%); }
  /* pastille de verre qui glisse sous l'onglet actif */
  .bottomnav::after { content: ''; position: absolute; top: 5px; bottom: 5px; left: calc(6px + var(--i) * (100% - 12px) / 4); width: calc((100% - 12px) / 4);
    border-radius: 26px; background: rgba(255, 255, 255, .16); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .3), inset 0 0 0 1px rgba(255, 255, 255, .1);
    transition: left .38s cubic-bezier(.3, 1.4, .5, 1), opacity .2s; pointer-events: none; }
  .bottomnav.no-pill::after { opacity: 0; }
  .bottomnav a { z-index: 1; border-radius: 26px; color: rgba(255, 255, 255, .62); font-size: 10.5px; font-weight: 600; gap: 3px; -webkit-tap-highlight-color: transparent; transition: color .25s, transform .15s; }
  .bottomnav a:active { transform: scale(.92); }
  .bottomnav a.on { color: #fff; }
  .bottomnav svg { width: 23px; height: 23px; }
  .bottomnav a.on svg { color: #fff; filter: drop-shadow(0 0 8px rgba(255, 255, 255, .35)); transform: none; }
  body.modal-open .bottomnav { opacity: 0; pointer-events: none; }
}

/* lecteur ouvert : pas de geste de navigation ni de rebond horizontal */
body:has(#player.open), #player { overscroll-behavior: none; }

/* titre du lecteur : sous la zone floutée par iOS en haut de l'écran, bien lisible */
.pl-top { padding-top: calc(env(safe-area-inset-top) + 14px) !important; }
.pl-title { color: #fff; text-shadow: 0 1px 8px rgba(0, 0, 0, .8); }
.pl-sub { text-shadow: 0 1px 6px rgba(0, 0, 0, .8); }

/* aperçu au-dessus de la barre de lecture (image de la scène + temps) */
.pl-prev { position: absolute; bottom: 30px; left: 0; transform: translateX(-50%) translateY(6px); display: flex; flex-direction: column; align-items: center; gap: 6px;
  pointer-events: none; opacity: 0; transition: opacity .15s, transform .15s; z-index: 3; }
.pl-prev.on { opacity: 1; transform: translateX(-50%) translateY(0); }
.pl-prev img { display: none; width: 192px; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 10px; background: #111;
  border: 2px solid rgba(255, 255, 255, .9); box-shadow: 0 10px 30px rgba(0, 0, 0, .6); }
.pl-prev.has-img img { display: block; }
.pl-prev span { padding: 4px 9px; border-radius: 6px; background: rgba(0, 0, 0, .85); font-size: 13px; font-weight: 800; font-variant-numeric: tabular-nums; }
.pl-progress:has(.pl-prev.on) .pl-hover { opacity: 0 !important; }
@media (max-width: 760px) { .pl-prev img { width: 168px; } .pl-prev { bottom: 34px; } }
