/* BPM R121 — homepage only, desktop & mobile. Radio/menu/news/Wall are NOT replaced. */
body.bpm-r121-on { --r121-bg:#050d1d; --r121-panel:#09182e; --r121-line:rgba(74,157,249,.27); --r121-blue:#1598ff; }
body.bpm-r121-on .bpm-sticky-shell { background:rgba(4,14,30,.96); }
body.bpm-r121-on .site-nav { background:#071326!important; border-bottom-color:var(--r121-line)!important; min-height:70px; height:auto; padding:10px clamp(16px,2.4vw,42px); gap:18px; }
body.bpm-r121-on .site-nav .logo-img { max-height:54px; object-fit:contain; }
body.bpm-r121-on .site-nav .nlink.active { border-radius:999px; background:linear-gradient(130deg,#0876e8,#1546be); color:#fff; box-shadow:0 0 20px rgba(6,150,255,.28); }
body.bpm-r121-on .radio-bar#radioBar { width:calc(100% - 52px)!important; background:linear-gradient(115deg,#07182c,#0b1b31)!important; border:1px solid rgba(31,146,245,.42)!important; border-radius:15px; height:65px; margin:5px clamp(12px,1.5vw,26px) 9px; padding:7px 14px; box-shadow:0 14px 35px rgba(0,0,0,.27); }
body.bpm-r121-on #radioBar .rb-badge { color:#fff; border-radius:999px; background:linear-gradient(125deg,#0b93ff,#0c58d6); padding:5px 9px; }
body.bpm-r121-on #radioBar .rb-play-btn { border-radius:50%; box-shadow:0 0 0 2px rgba(41,172,255,.4),0 0 18px rgba(18,142,255,.28); }
body.bpm-r121-on .bpm-r121-home { width:min(1430px,calc(100% - 40px)); margin:22px auto 32px; color:#f5f9ff; font-family:inherit; box-sizing:border-box; }
body.bpm-r121-on .bpm-r121-home * { box-sizing:border-box; }
.bpm-r121-home a { text-decoration:none; }
.bpm-r121-quicklinks { display:flex; align-items:center; gap:9px; flex-wrap:wrap; margin:0 0 18px; }
.bpm-r121-quicklinks a { padding:10px 16px; display:inline-flex; align-items:center; gap:8px; color:#ceddf4; border:1px solid transparent; border-radius:999px; white-space:nowrap; font-size:13px; font-weight:700; }
.bpm-r121-quicklinks .is-current { background:linear-gradient(125deg,#087deb,#1853c7); border-color:rgba(38,167,255,.9); color:white; box-shadow:0 0 20px rgba(10,119,255,.34); }
.bpm-r121-quicklinks a:hover:not(.is-current) { border-color:var(--r121-line); background:rgba(26,72,125,.25); }
.bpm-r121-feature { height:clamp(390px,34vw,510px); border:1px solid rgba(25,137,243,.3); position:relative; border-radius:26px; overflow:hidden; isolation:isolate; background:radial-gradient(circle at 65% 30%,#1a4979,#091526 55%,#061021 100%); box-shadow:0 23px 52px rgba(0,0,0,.35); }
.bpm-r121-slides,.bpm-r121-slide,.bpm-r121-hero-image,.bpm-r121-hero-shade { position:absolute; inset:0; width:100%; height:100%; }
.bpm-r121-slide { opacity:0; visibility:hidden; pointer-events:none; transition:opacity .38s ease,visibility .38s; }
.bpm-r121-slide.is-active { opacity:1; visibility:visible; pointer-events:auto; }
.bpm-r121-hero-image { object-fit:cover; object-position:66% 40%; filter:saturate(.95); transform:scale(1.02); }
.bpm-r121-img-error .bpm-r121-hero-image { display:none; }
.bpm-r121-hero-shade { background:linear-gradient(90deg,rgba(2,9,21,.97) 0%,rgba(3,11,28,.88) 22%,rgba(4,13,27,.49) 62%,rgba(3,8,18,.18) 100%),linear-gradient(0deg,rgba(3,10,22,.8),transparent 50%); }
.bpm-r121-feature-content { position:absolute; left:clamp(22px,4vw,70px); bottom:clamp(36px,5vw,72px); z-index:2; max-width:min(670px,80%); }
.bpm-r121-eyebrow { display:inline-flex; gap:8px; align-items:center; padding:8px 14px; font-size:12px; text-transform:uppercase; letter-spacing:.1em; font-weight:800; border-radius:999px; color:#eaf8ff; background:rgba(16,100,208,.84); }
.bpm-r121-feature-content h1,.bpm-r121-feature-empty h1 { font-size:clamp(38px,5.7vw,79px); color:white; letter-spacing:-.04em; line-height:1.04; margin:19px 0 12px; font-weight:900; text-shadow:0 5px 20px rgba(0,0,0,.35); font-family:inherit; }
.bpm-r121-feature-content p,.bpm-r121-feature-empty p { font-size:clamp(14px,1.3vw,18px); color:#e0e9fb; margin:0 0 23px; line-height:1.45; }
.bpm-r121-actions { display:flex; gap:11px; align-items:center; flex-wrap:wrap; }
.bpm-r121-btn { color:#fff!important; font:inherit; font-size:14px; font-weight:800; text-decoration:none!important; display:inline-flex; justify-content:center; align-items:center; gap:9px; min-height:48px; padding:10px 20px; border-radius:999px; border:1px solid rgba(255,255,255,.54); cursor:pointer; background:rgba(8,21,38,.58); }
.bpm-r121-btn.primary { background:linear-gradient(125deg,#159efa,#065ce1); border-color:#229fff; box-shadow:0 0 24px rgba(25,145,255,.28); }
.bpm-r121-btn:focus-visible,.bpm-r121-quicklinks a:focus-visible,.bpm-r121-artist:focus-visible { outline:3px solid #87d7ff; outline-offset:3px; }
.bpm-r121-feature-controls { position:absolute; left:50%; bottom:13px; transform:translateX(-50%); display:flex; gap:15px; align-items:center; z-index:5; background:rgba(6,16,32,.48); border-radius:99px; padding:5px 9px; }
.bpm-r121-feature-controls > button { width:28px;height:28px; border:0; background:none; color:#d9e8f9; cursor:pointer; border-radius:50%; }
.bpm-r121-dots { display:flex; align-items:center; gap:6px; }
.bpm-r121-dots button { width:9px; height:9px; border-radius:999px; padding:0; background:#65809e; border:0; cursor:pointer; }
.bpm-r121-dots button.is-active { background:#1db1ff; box-shadow:0 0 12px rgba(29,177,255,.7); width:18px; }
.bpm-r121-feature-empty { padding:clamp(30px,6vw,80px); max-width:670px; }
.bpm-r121-discover { margin:31px 0 0; }
.bpm-r121-section-title { display:flex; justify-content:space-between; align-items:flex-end; gap:15px; margin:0 0 16px; }
.bpm-r121-kicker { text-transform:uppercase; letter-spacing:.12em; font-weight:800; color:#51bfff; font-size:11px; }
.bpm-r121-section-title h2 { margin:4px 0 2px; color:#fff; font-family:inherit; font-size:clamp(25px,2.6vw,37px); letter-spacing:-.025em; line-height:1.1; }
.bpm-r121-section-title p { margin:0; color:#9db6d5; font-size:14px; }
.bpm-r121-section-title>a { display:inline-flex; align-items:center; gap:7px; flex-shrink:0; color:#36b6ff; font-weight:700; font-size:13px; }
.bpm-r121-artists { display:grid; grid-auto-flow:column; grid-auto-columns:minmax(180px,1fr); grid-template-columns:repeat(5,minmax(180px,1fr)); gap:15px; overflow-x:auto; padding:2px 2px 12px; scroll-snap-type:x proximity; scrollbar-width:thin; scrollbar-color:#275c8c transparent; }
.bpm-r121-artist { scroll-snap-align:start; border:1px solid rgba(80,156,244,.25); background:#0c1b2e; color:#fff!important; border-radius:19px; overflow:hidden; position:relative; min-width:0; display:flex; flex-direction:column; box-shadow:0 10px 22px rgba(0,0,0,.18); }
.bpm-r121-artist-image { height:205px; display:grid; place-items:center; overflow:hidden; background:radial-gradient(circle,#174b7e,#08182a 72%); }
.bpm-r121-artist-image img { width:100%; height:100%; object-fit:cover; transition:transform .4s ease; }
.bpm-r121-artist:hover .bpm-r121-artist-image img { transform:scale(1.055); }
.bpm-r121-photo-fallback { font-size:55px; color:#299cef; }
.bpm-r121-photo-fallback[hidden] { display:none; }
.bpm-r121-artist-info { display:flex; flex-direction:column; gap:5px; padding:12px 14px 17px; background:linear-gradient(0deg,#081424,#0c1b30); min-height:84px; }
.bpm-r121-artist-info strong { color:white; font-size:16px; font-weight:800; line-height:1.15; }
.bpm-r121-artist-info small { font-size:12px; color:#b4cce6; line-height:1.25; }
.bpm-r121-artist-arrow { position:absolute; top:12px; right:12px; display:grid; place-items:center; border-radius:50%; width:31px; height:31px; color:#f4fbff; border:1px solid rgba(114,212,255,.58); background:rgba(7,19,36,.78); }
.bpm-r121-empty-artists { grid-column:1/-1; padding:25px 18px; color:#9fc3e9; border:1px solid var(--r121-line); border-radius:17px; }
/* Anciennes bandes promotionnelles doublonnees, uniquement sur la page refaite. */
body.bpm-r121-on .bpm205-marketing .bpm205-hero,
body.bpm-r121-on .bpm205-marketing .bpm205-stats,
body.bpm-r121-on .bpm205-marketing #artistes,
body.bpm-r121-on .bpm183-radio-hero,
body.bpm-r121-on .bpm-r18-pulse { display:none!important; }
/* Le contenu editorial, Wall, articles, actualites et modules sous-jacents restent visibles. */
body.bpm-r121-on .bpm205-marketing { margin-top:0; }
@media(max-width:1100px) {
  body.bpm-r121-on .bpm-r121-home { width:calc(100% - 24px); }
  .bpm-r121-artists { grid-template-columns:none; grid-auto-columns:190px; }
}
@media(max-width:700px) {
  body.bpm-r121-on .site-nav { min-height:58px; height:58px; padding:7px 13px; gap:10px; }
  body.bpm-r121-on .site-nav .logo-img { max-height:42px; }
  body.bpm-r121-on #radioBar.radio-bar { width:calc(100% - 20px)!important; height:58px; border-radius:14px; margin:5px 10px 7px; padding:6px 9px; gap:7px; }
  body.bpm-r121-on #radioBar .rb-badge { font-size:9px; padding:4px 6px; }
  body.bpm-r121-on .bpm-r121-home { width:calc(100% - 20px); margin:8px auto 21px; }
  .bpm-r121-quicklinks { overflow-x:auto; flex-wrap:nowrap; scrollbar-width:none; padding:3px 1px 6px; gap:4px; margin-bottom:9px; }
  .bpm-r121-quicklinks::-webkit-scrollbar { display:none; }
  .bpm-r121-quicklinks a { font-size:12px; padding:8px 10px; gap:6px; }
  .bpm-r121-feature { height:350px; border-radius:19px; }
  .bpm-r121-hero-image { object-position:58% center; }
  .bpm-r121-hero-shade { background:linear-gradient(0deg,#020915 0%,rgba(2,8,18,.88) 18%,rgba(4,12,26,.24) 75%),linear-gradient(90deg,rgba(3,11,23,.5),transparent 80%); }
  .bpm-r121-feature-content { left:19px; bottom:40px; max-width:calc(100% - 34px); }
  .bpm-r121-feature-content h1,.bpm-r121-feature-empty h1 { font-size:clamp(33px,10.5vw,54px); margin:9px 0 8px; line-height:1; }
  .bpm-r121-feature-content p,.bpm-r121-feature-empty p { font-size:13px; margin-bottom:14px; }
  .bpm-r121-eyebrow { font-size:10px; padding:6px 10px; }
  .bpm-r121-actions { gap:8px; }
  .bpm-r121-btn { min-height:41px; font-size:12px; padding:9px 12px; }
  .bpm-r121-feature-controls { bottom:6px; }
  .bpm-r121-discover { margin-top:22px; }
  .bpm-r121-section-title { align-items:center; }
  .bpm-r121-section-title h2 { font-size:25px; }
  .bpm-r121-section-title p { font-size:12px; }
  .bpm-r121-section-title>a { font-size:12px; }
  .bpm-r121-artists { grid-auto-columns:150px; gap:10px; }
  .bpm-r121-artist-image { height:166px; }
  .bpm-r121-artist-info { min-height:75px; padding:10px; }
  .bpm-r121-artist-info strong { font-size:14px; }
  .bpm-r121-artist-info small { font-size:11px; }
  .bpm-r121-artist { border-radius:13px; }
  /* Laisser les hauteurs de lecteur et dock a leurs modules existants. */
}
@media(max-width:390px) {
  .bpm-r121-quicklinks a { font-size:11px; padding:8px 9px; }
  .bpm-r121-btn.ghost { font-size:11px; }
  .bpm-r121-artists { grid-auto-columns:138px; }
}
@media(prefers-reduced-motion:reduce) {
  .bpm-r121-slide,.bpm-r121-artist-image img { transition:none!important; }
}

.bpm-r121-artist-image img[hidden]{display:none!important}


/* BPM R122 — Ordre des actualités et correction du panneau étroit du lecteur.
 * Ciblage exclusivement sur l'accueil R121.  Aucun changement des fichiers AutoDJ ou du Wall.
 */
body.bpm-r121-on .bpm-r121-home > .bpm-r122-news-top,
body.bpm-r121-on .bpm-r121-home > .bpm-r80-editorial {
  width:100%;
  min-width:0;
  max-width:100%;
  margin:0 0 18px;
}
body.bpm-r121-on .bpm-r122-feature-after-news {
  width:100%;
  max-width:100%;
  min-width:0;
  margin:0 0 20px;
  box-sizing:border-box;
}
body.bpm-r121-on .bpm-r122-feature-after-news * { box-sizing:border-box; }
body.bpm-r121-on #bpmR121Home { max-width:100%; min-width:0; }
body.bpm-r121-on .bpm-r121-artists { min-width:0; max-width:100%; }

/* Bug confirmé : le panneau se retrouvait coincé dans l'état is-collapsed
 * (largeur 82px), avec « LECTEUR MUSICAL BPM » lettre par lettre.
 * On préserve le JS, la file d'attente, les réglages et l'audio d'origine. */
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open {
  left:10px!important;
  right:auto!important;
  width:min(520px,calc(100vw - 20px))!important;
  max-width:calc(100vw - 20px)!important;
}
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-panel {
  left:0!important;
  right:0!important;
  width:100%!important;
  min-width:0!important;
  box-sizing:border-box!important;
  overflow-x:hidden!important;
  overflow-y:auto!important;
  max-height:min(70dvh,690px)!important;
}
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-panel-head > div,
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-search,
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-panel-grid > div { min-width:0; }
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-panel-head strong {
  overflow-wrap:normal;
  word-break:normal;
}
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-panel-grid {
  grid-template-columns:minmax(0,1fr)!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  max-height:min(45dvh,410px)!important;
}
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-results,
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-queue {
  max-height:180px!important;
}
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-main {
  display:grid!important;
  grid-template-columns:50px minmax(0,1fr) 46px 38px!important;
  width:100%!important;
  max-width:none!important;
  margin:0!important;
  padding:9px!important;
  height:70px!important;
  gap:8px!important;
}
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-cover { width:50px!important;height:50px!important; }
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-meta { display:block!important;min-width:0!important; }
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-controls { display:flex!important;gap:0!important; }
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-search-btn { display:inline-flex!important;width:38px!important;padding:0!important; }
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-controls > :not(#bpmGpPlay),
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-progress,
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-time,
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-volume,
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-collapse { display:none!important; }
body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-play { display:inline-flex!important;width:42px!important;height:42px!important; }

@media(max-width:700px) {
  body.bpm-r121-on .bpm-r122-feature-after-news { height:350px; margin-bottom:15px; }
  body.bpm-r121-on .bpm-r121-home > .bpm-r122-news-top { margin-bottom:14px; }
  body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open {
    left:8px!important;
    right:8px!important;
    width:auto!important;
    max-width:none!important;
    /* Remain ABOVE BPM mobile dock (fixed bottom navigation). */
    bottom:calc(76px + env(safe-area-inset-bottom))!important;
  }
  body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-main {
    grid-template-columns:44px minmax(0,1fr) 44px 38px!important;
  }
  body.bpm-r121-on .bpm-global-player.is-collapsed.panel-open .bpm-gp-cover { width:44px!important;height:44px!important; }
}
