/* ==========================================================================
   FunkyBreslev — Espace Pass Premium · design v4 (mobile-first).
   Bibliothèque en cartes + pochettes générées, lecteur plein écran (sheet),
   mini-player persistant. Autonome. FR + EN (i18n via <html lang>).
   ========================================================================== */

:root {
  --bg: #08080a; --panel: #131318; --panel2: #1b1b22; --elev: #202028;
  --ink: #f5f3ee; --muted: #9c988e; --gold: #e8a93b; --gold-ink: #0a0a0a;
  --line: rgba(245, 243, 238, .1); --line2: rgba(245, 243, 238, .16);
  --danger: #ff8f6b;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-drawer: cubic-bezier(0.32, 0.72, 0, 1);
  --mini-h: 68px;
  --safe-b: env(safe-area-inset-bottom, 0px);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 440 16px/1.55 'Plus Jakarta Sans', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  padding-bottom: calc(var(--mini-h) + var(--safe-b) + 14px);
  overflow-x: hidden;
}
/* Évite le flash du formulaire de connexion quand un membre déjà identifié
   recharge l’espace : le gate ne doit jamais lui parler de rejoindre le Pass. */
body.auth-pending #gate { visibility: hidden; opacity: 0; }
body.auth-pending #app { visibility: hidden; }
a { color: inherit; text-decoration: none; }
a[href], button, [role="button"] {
  -webkit-tap-highlight-color: rgba(232, 169, 59, .24);
  touch-action: manipulation;
}
img { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; color: inherit; }
.wrap { width: min(1080px, calc(100% - 32px)); margin: auto; }
.skip { position: absolute; left: -10000px; }
h1, h2, h3 { margin: 0; }

/* Titre DIN utilitaire */
.din { font-family: 'Plus Jakarta Sans', 'Arial Narrow', Impact, sans-serif; font-weight: 700; text-transform: uppercase; letter-spacing: .01em; }

/* ---- Boutons ---- */
.btn-gold {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 46px; padding: 11px 20px; border: 0; border-radius: 12px;
  background: var(--gold); color: var(--gold-ink); font-weight: 700; font-size: 15px;
  box-shadow: 0 8px 22px rgba(232, 169, 59, .22);
  transition: transform .14s var(--ease-out), box-shadow .14s var(--ease-out);
}
.btn-gold:hover { box-shadow: 0 12px 28px rgba(232, 169, 59, .32); }
.btn-gold:active { transform: scale(.97); }
.btn-gold svg { width: 16px; height: 16px; fill: currentColor; }
.btn-ghost {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  min-height: 42px; padding: 9px 15px; border: 1px solid var(--line2); border-radius: 12px;
  background: rgba(255,255,255,.03); color: var(--ink); font-size: 14px; font-weight: 600;
  transition: border-color .16s var(--ease-out), transform .12s var(--ease-out), background .16s var(--ease-out);
}
.btn-ghost:hover { border-color: var(--gold); }
.btn-ghost:active { transform: scale(.97); }
.btn-ghost svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.iconbtn {
  width: 42px; height: 42px; flex: 0 0 auto; border-radius: 50%; border: 1px solid var(--line2);
  background: rgba(255,255,255,.03); display: grid; place-items: center;
  transition: border-color .16s var(--ease-out), transform .12s var(--ease-out), color .16s var(--ease-out);
}
.iconbtn:hover { border-color: var(--gold); color: var(--gold); }
.iconbtn:active { transform: scale(.92); }
.iconbtn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.iconbtn.filled svg { fill: currentColor; stroke: none; }

/* ---- Barre supérieure (translucide) ---- */
.topbar {
  position: sticky; top: 0; z-index: 30;
  background: rgba(8, 8, 10, .72); backdrop-filter: blur(18px) saturate(160%);
  border-bottom: 1px solid var(--line);
}
.topbar-in { display: flex; align-items: center; gap: 12px; height: calc(60px + env(safe-area-inset-top, 0px)); min-height: 60px; padding-top: env(safe-area-inset-top, 0px); }
.topbar .brand img { height: 34px; width: auto; }
.topbar .spacer { flex: 1; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px;
  border: 1px solid var(--line2); border-radius: 99px; font-size: 12px; color: var(--muted);
  background: rgba(255,255,255,.03); white-space: nowrap;
}
.chip b { color: var(--ink); font-weight: 700; }
.menu-wrap { position: relative; }
/* Contrôles de session masqués tant que le membre n'est pas connecté (état gate) */
body:not(.authed) .menu-wrap, body:not(.authed) #expiryChip { display: none; }
body:not(.authed) .np,
body:not(.authed) .mini,
body:not(.authed) .sheet,
body:not(.authed) .scrim,
body:not(.authed) .addpop,
body:not(.authed) .toast { display: none !important; }
.menu-pop {
  position: absolute; right: 0; top: calc(100% + 8px); z-index: 40; min-width: 220px;
  background: var(--elev); border: 1px solid var(--line2); border-radius: 14px; padding: 6px;
  box-shadow: 0 24px 50px rgba(0,0,0,.6); transform-origin: top right;
  opacity: 0; transform: scale(.96) translateY(-6px); pointer-events: none;
  transition: opacity .16s var(--ease-out), transform .16s var(--ease-out);
}
.menu-pop.open { opacity: 1; transform: none; pointer-events: auto; }
/* Les entrées du menu ⋯ sont soit des <button> (actions), soit des <a> (langue,
   CGV, confidentialité — ajoutés le 2026-09-04 : l'espace est une zone payante,
   ces liens doivent être atteignables sans repasser par le site public). Même
   rendu dans les deux cas. */
.menu-pop button, .menu-pop a { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 11px 12px; border: 0; border-radius: 9px; background: transparent; color: var(--ink); font-size: 14px; font-weight: 500; text-decoration: none; }
.menu-pop button:hover, .menu-pop a:hover { background: rgba(255,255,255,.06); }
.menu-pop button:active, .menu-pop a:active { background: rgba(232,169,59,.14); transform: scale(.98); }
/* Icônes des entrées de menu (statiques + téléchargements injectés via JS) :
   les SVG injectés n'ont ni taille ni tracé — on les normalise ici. */
.menu-pop button svg, .menu-pop a svg { width: 16px; height: 16px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.menu-pop .sep { height: 1px; background: var(--line); margin: 5px 4px; }
.menu-pop .chip-m { display: none; }

/* ---- Écran de connexion ---- */
.gate {
  position: relative; min-height: calc(100svh - 60px);
  display: grid; place-items: center;
  padding: clamp(30px, 6vw, 72px) 0 64px;
  isolation: isolate; overflow: hidden;
}
.gate::before {
  content: ""; position: absolute; inset: -18% -10% auto; z-index: -2; height: 68%;
  background:
    radial-gradient(ellipse at 18% 28%, rgba(232,169,59,.2), transparent 34%),
    radial-gradient(ellipse at 78% 12%, rgba(255,124,76,.12), transparent 32%);
  filter: blur(10px); opacity: .82; pointer-events: none;
}
.gate::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(232,169,59,.12), transparent 42%),
    linear-gradient(180deg, transparent 0%, rgba(0,0,0,.32) 82%);
  opacity: .86;
}
.gate-stage {
  width: min(1120px, calc(100% - 36px));
  display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(360px, .82fr);
  gap: clamp(18px, 3vw, 28px); align-items: stretch;
}
.gate-visual,
.gate-panel {
  position: relative; overflow: hidden;
  border: 1px solid rgba(232,169,59,.2);
  box-shadow: 0 30px 90px rgba(0,0,0,.44);
}
.gate-visual {
  min-height: 560px; border-radius: 28px;
  padding: clamp(28px, 4vw, 48px);
  display: flex; flex-direction: column; justify-content: space-between; gap: 34px;
  background:
    linear-gradient(140deg, rgba(30,24,14,.72), rgba(12,12,16,.9) 48%, rgba(8,8,10,.96));
}
.gate-cover-wall { position: absolute; inset: -8%; opacity: .34; filter: saturate(.95) contrast(1.08); }
.gate-cover-wall img { width: 100%; height: 100%; object-fit: cover; }
.gate-cover-wall::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(8,8,10,.32), rgba(8,8,10,.88) 60%, rgba(8,8,10,.96));
}
.gate-disc {
  position: absolute; right: -104px; top: 62px; width: min(390px, 44vw);
  opacity: .56; transform: rotate(-12deg);
}
.gate-disc img {
  width: 100%; height: auto; border-radius: 50%;
  box-shadow: 0 28px 70px rgba(0,0,0,.56);
}
.gate-visual-copy,
.gate-proof { position: relative; z-index: 1; }
.gate-kicker {
  display: inline-flex; align-items: center; width: fit-content;
  min-height: 30px; padding: 6px 10px;
  border: 1px solid rgba(232,169,59,.28); border-radius: 8px;
  background: rgba(8,8,10,.38); color: var(--gold);
  font-size: 10px; font-weight: 850; letter-spacing: .14em; text-transform: uppercase;
}
.gate-visual-title {
  margin: 22px 0 16px; max-width: 8.5ch;
  font-family: 'Plus Jakarta Sans', Impact, sans-serif;
  font-size: clamp(60px, 9vw, 104px); line-height: .82;
  letter-spacing: 0; text-transform: uppercase; text-wrap: balance;
}
.gate-visual-copy p:not(.gate-visual-title) {
  max-width: 34rem; margin: 0;
  color: rgba(245,243,238,.78); font-size: clamp(15px, 1.7vw, 18px); line-height: 1.55;
}
.gate-proof {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px; margin: 0; padding: 0; list-style: none;
}
.gate-proof li {
  min-height: 116px; padding: 13px 13px 14px; border-radius: 8px;
  background: rgba(10,10,12,.54); border: 1px solid rgba(245,243,238,.1);
  backdrop-filter: blur(12px);
}
.gate-proof b { display: block; font-size: 12px; line-height: 1.2; margin-bottom: 8px; }
.gate-proof span { display: block; color: var(--muted); font-size: 11.5px; line-height: 1.38; }
.gate-panel {
  align-self: center; border-radius: 24px;
  padding: clamp(30px, 4vw, 44px);
  background:
    linear-gradient(180deg, rgba(255,255,255,.075), rgba(255,255,255,.026)),
    rgba(15,15,19,.86);
  backdrop-filter: blur(18px) saturate(135%);
}
.gate-panel::before {
  content:""; position:absolute; left: 28px; right: 28px; top: 0; height: 1px; z-index: 2;
  background: linear-gradient(90deg, transparent, rgba(232,169,59,.72), transparent);
}
.gate-panel::after {
  content: ""; position: absolute; inset: -4%;
  background:
    radial-gradient(90% 88% at 20% 50%, rgba(20,20,24,.9), rgba(20,20,24,.72) 42%, rgba(20,20,24,.24) 74%),
    linear-gradient(180deg, rgba(20,20,24,.86), rgba(20,20,24,.62) 44%, rgba(20,20,24,.88)),
    url('../img/mosaique-pochettes.webp?v=1') center 42% / cover no-repeat;
  opacity: .62; transform: translate3d(0,0,0) scale(1.02); pointer-events: none;
}
.gate-panel > * { position: relative; z-index: 1; }
.gate-panel > img { width: 154px; height: auto; margin: 0 0 28px; }
.gate-panel h1 {
  max-width: 8.5ch; margin: 4px 0 15px;
  font-family: 'Plus Jakarta Sans', Impact, sans-serif;
  font-size: clamp(42px, 5.6vw, 58px); line-height: .88;
  letter-spacing: 0; text-transform: uppercase;
}
.gate-lead { color: var(--muted); font-size: 14px; margin: 0 0 24px; line-height: 1.56; }
.gate-form { display: flex; flex-direction: column; gap: 10px; }
.sr-only { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
.gate-form input, .search input { width: 100%; padding: 14px 16px; border: 1px solid var(--line2); border-radius: 12px; background: #0e0e12; color: var(--ink); font: inherit; }
.gate-form input {
  min-height: 54px; background: rgba(4,4,6,.7);
  border-color: rgba(245,243,238,.16);
  box-shadow: 0 1px 0 rgba(255,255,255,.04) inset;
}
.gate-form input:focus, .search input:focus { outline: none; border-color: var(--gold); }
.gate-msg { min-height: 20px; font-size: 13px; margin: 14px 0 0; }
.gate-msg:empty { min-height: 0; margin: 0; }
.gate-msg.err { color: var(--danger); } .gate-msg.ok { color: var(--gold); }
/* Le message « lien envoyé » porte un lien vers la page de vente : souligné,
   car il hérite la couleur du message (or sur or serait invisible autrement). */
.gate-msg a { color: inherit; text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
.gate-assist {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 14px;
  margin-top: 18px; padding-top: 17px; border-top: 1px solid rgba(245,243,238,.1);
}
.gate-assist b { display: block; margin-bottom: 3px; color: var(--ink); font-size: 12.5px; line-height: 1.25; }
.gate-assist span { display: block; color: var(--muted); font-size: 12px; line-height: 1.38; }
.gate-assist a {
  display: inline-flex; align-items: center; justify-content: center; min-height: 38px;
  padding: 8px 12px; border-radius: 10px; border: 1px solid rgba(232,169,59,.28);
  color: var(--gold); font-size: 12px; font-weight: 750;
  transition: background .18s var(--ease-out), transform .12s var(--ease-out), border-color .18s var(--ease-out);
}
.gate-assist a:hover { background: rgba(232,169,59,.08); border-color: rgba(232,169,59,.46); }
.gate-assist a:active { transform: translateY(1px) scale(.98); }
.gate-routes {
  display: grid; gap: 0; margin-top: 14px; padding-top: 5px;
  border-top: 1px solid rgba(245,243,238,.08);
}
.gate-route {
  display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr) 16px; align-items: center; gap: 14px;
  min-height: 52px; padding: 10px 0; color: inherit;
  border-bottom: 1px solid rgba(245,243,238,.08);
}
.gate-route:last-child { border-bottom: 0; }
.gate-route span {
  color: var(--muted); font-size: 11px; font-weight: 760;
  letter-spacing: .08em; text-transform: uppercase; line-height: 1.25;
}
.gate-route b {
  color: var(--gold); font-size: 13px; font-weight: 760; line-height: 1.25;
  text-align: right;
}
.gate-route::after {
  content: "›"; color: rgba(232,169,59,.78); font-size: 18px; line-height: 1;
  justify-self: end;
  transform: translateY(-1px); transition: transform .16s var(--ease-out);
}
.gate-route:hover b { text-decoration: underline; text-underline-offset: 3px; }
.gate-route:hover::after { transform: translate(3px, -1px); }
.gate-route:active { background: rgba(232,169,59,.08); transform: translateY(1px) scale(.99); }
.gate-route:active::after { transform: translate(4px, -1px); }
@media (prefers-reduced-motion: no-preference) {
  .gate-disc img { animation: spin 28s linear infinite; }
  .gate-panel::after { animation: gateMosaicDrift 10s var(--ease-out) infinite alternate; }
}
@keyframes gateMosaicDrift {
  from { transform: translate3d(0, -2px, 0) scale(1.02); opacity: .56; }
  to { transform: translate3d(-16px, 8px, 0) scale(1.06); opacity: .68; }
}
@media (max-width: 900px) {
  .gate-stage { grid-template-columns: 1fr; max-width: 520px; }
  .gate-panel { order: -1; }
  .gate-visual { display: none; }
  .gate-disc { width: 250px; right: -76px; top: 20px; opacity: .44; }
  .gate-cover-wall { opacity: .26; }
  .gate-visual-title { max-width: 7ch; margin: 16px 0 10px; font-size: clamp(42px, 13vw, 66px); }
  .gate-visual-copy p:not(.gate-visual-title) { max-width: 22rem; font-size: 13px; }
  .gate-proof { display: none; }
}
@media (max-width: 520px) {
  .gate {
    min-height: calc(100svh - 60px);
    padding: 20px 0 30px;
    place-items: start center;
  }
  .gate-stage { width: min(100% - 36px, 430px); gap: 14px; }
  .gate-panel {
    width: 100%; min-height: calc(100svh - 114px);
    display: flex; flex-direction: column; justify-content: center;
    padding: clamp(28px, 8vw, 36px) 22px; border-radius: 20px;
  }
  .gate-panel::after { inset: -3%; opacity: .66; background-position: 56% 42%; }
  .gate-panel > img { display: none; }
  .gate-panel h1 { font-size: clamp(40px, 12vw, 50px); margin-top: 0; }
  .gate-lead { font-size: 13.5px; margin-bottom: 24px; }
  .gate-assist {
    grid-template-columns: 1fr; gap: 10px;
    margin-top: 20px; padding-top: 18px;
  }
  .gate-assist a { width: fit-content; min-height: 40px; }
  .gate-route {
    grid-template-columns: 1fr 22px; gap: 10px;
    min-height: 56px; padding: 12px 0;
  }
  .gate-route b { grid-column: 1; grid-row: 2; text-align: left; font-size: 13.5px; }
  .gate-route::after { grid-column: 2; grid-row: 1 / span 2; justify-self: end; align-self: center; }
}
@media (max-width: 360px) {
  .gate { padding-top: 14px; }
  .gate-stage { width: min(100% - 36px, 360px); }
  .gate-panel {
    min-height: auto;
    padding: 24px 21px 22px;
  }
  .gate-panel::after { inset: -3%; opacity: .62; background-position: 58% 42%; }
  .gate-panel h1 { font-size: 38px; margin-bottom: 12px; }
  .gate-lead { font-size: 12.8px; line-height: 1.48; margin-bottom: 20px; }
  .gate-form input { min-height: 52px; }
  .gate-form .btn-gold { min-height: 48px; }
  .gate-assist { margin-top: 16px; padding-top: 15px; gap: 8px; }
  .gate-assist b { font-size: 12px; }
  .gate-assist span { font-size: 11.5px; }
  .gate-assist a { min-height: 40px; padding-block: 7px; }
  .gate-routes { margin-top: 11px; }
  .gate-route { min-height: 50px; padding: 9px 0; }
  .gate-route span { font-size: 10px; }
  .gate-route b { font-size: 12.8px; }
}

/* ---- Sections ---- */
.app-main { padding: 22px 0 8px; }
.section { margin-bottom: 34px; }
.mobile-home-nav { display: none; }
.sec-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 14px; }
/* En-tête « Ta bibliothèque » : titre + segment. Sur mobile étroit, le segment
   passe proprement sous le titre (jamais de titre coupé sur 2 lignes). */
.sec-head.has-seg { flex-wrap: wrap; row-gap: 12px; }
.sec-head.has-seg h2 { white-space: nowrap; }
.library-tools { display: flex; align-items: center; justify-content: flex-end; flex: 1 1 520px; gap: 12px; min-width: 0; }
@media (max-width: 640px) {
  .wrap { display: flex; flex-direction: column; }
  /* Le conteneur de la barre supérieure partage la classe `.wrap` avec le
     contenu : il doit rester horizontal sur iPhone, sinon le menu tombe sous
     le logo et crée un faux grand espace au-dessus de l’accueil. */
  .topbar-in { flex-direction: row; }
  .mobile-home-nav { display: block; order: -1; margin-bottom: 24px; }
  .mobile-home-nav-head { margin: 0 2px 12px; }
  .mobile-home-nav-head h1 { font-family: 'Plus Jakarta Sans', Impact, sans-serif; font-size: clamp(28px, 9vw, 38px); line-height: .94; letter-spacing: -.02em; text-transform: uppercase; }
  .mobile-home-nav-head p { max-width: 32rem; margin: 8px 0 0; color: var(--muted); font-size: 13px; line-height: 1.45; }
  .mobile-home-actions { display: grid; gap: 8px; }
  .mobile-home-action {
    position: relative; display: flex; align-items: center; gap: 13px; width: 100%; min-height: 68px;
    padding: 11px 13px; border: 1px solid rgba(232,169,59,.28); border-radius: 0;
    background: linear-gradient(100deg, rgba(232,169,59,.16), rgba(255,255,255,.045) 54%, rgba(255,255,255,.018));
    color: var(--ink); text-align: left; overflow: hidden;
    transition: transform .18s var(--ease-out), border-color .18s var(--ease-out), background .18s var(--ease-out);
    animation: mobileHomeIn .46s var(--ease-out) both;
  }
  .mobile-home-action:nth-child(2) { animation-delay: 45ms; }
  .mobile-home-action:nth-child(3) { animation-delay: 90ms; }
  .mobile-home-action:nth-child(4) { animation-delay: 135ms; }
  .mobile-home-action::before { content: ''; position: absolute; inset: 0 auto 0 -42%; width: 34%; transform: skewX(-18deg); background: linear-gradient(90deg, transparent, rgba(255,255,255,.15), transparent); pointer-events: none; }
  .mobile-home-action:active { transform: translateX(3px); border-color: var(--gold); background: linear-gradient(100deg, rgba(232,169,59,.28), rgba(255,255,255,.07)); }
  .mobile-home-action:active::before { animation: mobileNavSweep .48s var(--ease-out) both; }
  .mobile-home-action-icon { display: grid; place-items: center; width: 42px; height: 42px; flex: 0 0 42px; border: 1px solid rgba(232,169,59,.45); background: rgba(8,8,10,.42); color: var(--gold); }
  .mobile-home-action-icon svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: square; stroke-linejoin: miter; }
  .mobile-home-action-copy { display: flex; min-width: 0; flex: 1; flex-direction: column; gap: 1px; }
  .mobile-home-action-copy strong { font-size: 15px; line-height: 1.2; }
  .mobile-home-action-copy small { color: var(--muted); font-size: 11px; line-height: 1.3; }
  .mobile-home-action-arrow { color: var(--gold); font-size: 22px; line-height: 1; transform: translateY(-1px); }
  @keyframes mobileNavSweep { from { transform: translateX(0) skewX(-18deg); } to { transform: translateX(420%) skewX(-18deg); } }
  @keyframes mobileHomeIn { from { opacity: 0; transform: translateY(9px); } to { opacity: 1; transform: none; } }
  .app-main { padding-top: 12px; }
  .member-access { order: initial; padding: 16px; border-radius: 0; gap: 14px; }
  .hero-sec { order: 0; }
  .member-access-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .member-access-actions > button { width: 100%; min-height: 58px; border-radius: 0; }
  .member-access-actions p { grid-column: 1 / -1; }
  .library-tools { flex-direction: column; align-items: stretch; flex-basis: 100%; }
  .library-tools .member-search { flex: 0 0 auto; width: 100%; max-width: none; }
  .sec-head.has-seg .seg { flex: 1 1 100%; width: 100%; }
}
.sec-head h2 { font-family: 'Plus Jakarta Sans', Impact, sans-serif; font-size: clamp(22px, 5vw, 28px); text-transform: uppercase; letter-spacing: -.005em; }
.eyebrow { display: block; color: var(--gold); font-size: 11px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; margin-bottom: 3px; }

/* ==== Pochettes (réelles + générées) ==================================== */
.cvr { position: relative; aspect-ratio: 1; border-radius: 14px; overflow: hidden; background: #17171b; box-shadow: 0 1px 0 rgba(255,255,255,.04) inset; }
.cvr img { width: 100%; height: 100%; object-fit: cover; }
/* Pochette générée : soleil synthwave (stries) + grille horizon + titre DIN */
.cvr.gen { background: linear-gradient(180deg, var(--b) 0%, #06060b 86%); }
.cvr.gen::before { /* soleil rayé */
  content: ""; position: absolute; left: 50%; top: 33%; width: 58%; aspect-ratio: 1; transform: translate(-50%, -50%);
  border-radius: 50%;
  background: linear-gradient(180deg, var(--sun) 0%, var(--a) 58%, var(--a) 100%);
  -webkit-mask-image: linear-gradient(#000, #000), repeating-linear-gradient(0deg, #000 0 2px, transparent 2px 6px);
  mask-image: linear-gradient(#000, #000), repeating-linear-gradient(0deg, #000 0 2px, transparent 2px 6px);
  -webkit-mask-size: 100% 48%, 100% 52%; mask-size: 100% 48%, 100% 52%;
  -webkit-mask-position: top, bottom; mask-position: top, bottom;
  -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
  box-shadow: 0 0 42px -6px var(--a);
}
.cvr.gen::after { /* grille horizon en perspective */
  content: ""; position: absolute; left: -30%; right: -30%; bottom: -2%; height: 46%;
  background:
    repeating-linear-gradient(to right, rgba(255,255,255,.22) 0 1px, transparent 1px 9%),
    repeating-linear-gradient(to bottom, rgba(255,255,255,.18) 0 1px, transparent 1px 22%);
  transform: perspective(240px) rotateX(66deg); transform-origin: bottom;
  mask-image: linear-gradient(to bottom, transparent, #000 55%);
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 55%);
}
.cvr.gen .cvr-t { position: absolute; left: 12px; right: 12px; bottom: 11px; z-index: 2; font-family: 'Plus Jakarta Sans', Impact, sans-serif; font-weight: 700; text-transform: uppercase; letter-spacing: -.01em; line-height: .9; color: #fff; text-shadow: 0 2px 16px rgba(0,0,0,.75); }
.cvr.gen .cvr-m { position: absolute; left: 12px; top: 10px; z-index: 2; font-size: 8px; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; color: rgba(255,255,255,.8); text-shadow: 0 1px 6px rgba(0,0,0,.5); }
.cvr .cvr-play { position: absolute; right: 10px; bottom: 10px; z-index: 3; width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--gold); color: var(--gold-ink); display: grid; place-items: center; box-shadow: 0 8px 20px rgba(0,0,0,.5); opacity: 0; transform: translateY(6px) scale(.9); transition: opacity .2s var(--ease-out), transform .2s var(--ease-out); }
.cvr .cvr-play svg { width: 19px; height: 19px; fill: currentColor; }
/* Bouton « + » (ajouter à une playlist) — coin haut-droit de la pochette. */
.cvr .cvr-add { position: absolute; top: 9px; right: 9px; z-index: 3; width: 30px; height: 30px; border-radius: 50%; border: 0; background: var(--gold); color: var(--gold-ink); display: grid; place-items: center; box-shadow: 0 4px 14px rgba(0,0,0,.45); opacity: 0; transform: translateY(-5px) scale(.9); transition: opacity .2s var(--ease-out), transform .14s var(--ease-out); }
.cvr .cvr-add svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.cvr .cvr-add:hover { transform: scale(1.08); }
.cvr .cvr-add:active { transform: scale(.86); }
/* Révélé au survol (desktop), comme le bouton lecture. */
@media (hover: hover) and (pointer: fine) {
  .tile:hover .cvr-add, .rel-card:hover .cvr-add, .hero-art:hover .cvr-add { opacity: 1; transform: none; }
}
/* Sur tactile (mobile-first), les actions de pochette sont toujours visibles :
   sans survol, le bouton lecture ET le « + » resteraient sinon invisibles. */
@media (hover: none) {
  .cvr .cvr-play, .cvr .cvr-add { opacity: 1; transform: none; }
  .cvr .cvr-play, .cvr .cvr-add { width: 44px; height: 44px; }
}

/* ==== Dernières sorties : rail horizontal ============================== */
.rail-wrap { position: relative; }
/* Voile de droite : signale sur mobile qu'il reste des cartes à faire défiler. */
.rail-wrap::after { content: ''; position: absolute; top: 0; right: -2px; bottom: 14px; width: 44px; pointer-events: none; opacity: 0; transition: opacity .2s var(--ease-out); background: linear-gradient(90deg, transparent, var(--bg)); }
.rail-wrap.scrollable::after { opacity: 1; }
/* Indice « glisser › » dans l'en-tête, affiché uniquement sur écran tactile/étroit. */
.rail-hint { display: none; }
@media (hover: none), (max-width: 640px) {
  .rail-hint { display: inline-flex; align-items: center; gap: 6px; flex: none; color: var(--muted); font-size: 10px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; white-space: nowrap; }
  .rail-hint::after { content: '›'; font-size: 15px; line-height: 1; transform: translateY(-1px); animation: railNudge 1.6s var(--ease-out) infinite; }
}
@keyframes railNudge { 0%,100% { transform: translate(0,-1px); } 50% { transform: translate(3px,-1px); } }
@media (prefers-reduced-motion: reduce) { .rail-hint::after { animation: none; } }
.rail { display: grid; grid-auto-flow: column; grid-auto-columns: 168px; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 2px 2px 12px; margin: 0 -2px; scrollbar-width: none; }
.rail::-webkit-scrollbar { display: none; }
.rel-card { scroll-snap-align: start; }
.rel-card .cvr { border-radius: 16px; }
.rel-card.feat { grid-column: span 1; }
.rel-meta { padding: 10px 2px 0; }
.rel-badge { font-size: 10px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.rel-badge.hot { color: var(--gold); }
.rel-title { font-family: 'Plus Jakarta Sans', Impact, sans-serif; font-size: 19px; text-transform: uppercase; letter-spacing: 0; line-height: 1; margin: 3px 0 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rel-sub { color: var(--muted); font-size: 11px; }

/* ==== Bibliothèque ===================================================== */
.seg {
  display: inline-flex; align-items: center; padding: 4px;
  border: 1px solid var(--line2); border-radius: 16px;
  background: linear-gradient(180deg, rgba(255,255,255,.055), rgba(255,255,255,.02));
  gap: 4px; box-shadow: 0 10px 28px rgba(0,0,0,.18);
}
.seg button {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  min-height: 36px; padding: 7px 12px; border: 0; border-radius: 12px;
  background: transparent; color: var(--muted); font-size: 12px; font-weight: 750;
  line-height: 1; white-space: nowrap;
  transition: color .15s var(--ease-out), background .15s var(--ease-out), transform .12s var(--ease-out);
}
.library-tools .seg button::before {
  display: inline-grid; place-items: center; width: 18px; height: 18px; flex: 0 0 auto;
  border-radius: 50%; border: 1px solid currentColor; font-size: 9px; font-weight: 850;
  opacity: .74;
}
.library-tools .seg button[data-view="recent"]::before { content: "N"; }
.library-tools .seg button[data-view="albums"]::before { content: "A"; }
.library-tools .seg button[data-view="singles"]::before { content: "S"; }
.library-tools .seg button[data-view="favorites"]::before { content: "C"; }
.library-tools .seg button[data-view="playlists"]::before { content: "P"; }
.seg button.active {
  background: var(--gold); color: var(--gold-ink);
  box-shadow: 0 8px 18px rgba(232,169,59,.18);
}
.seg button:active { transform: scale(.97); }
.seg.is-hidden { display: none; }
.member-search { flex: 1 1 260px; max-width: 360px; }
.member-search input { padding-left: 42px; border-radius: 99px; }
@media (max-width: 640px) {
  .library-tools .seg {
    display: grid; grid-template-columns: repeat(6, minmax(0, 1fr));
    overflow: visible; justify-content: stretch; border-radius: 16px; padding: 5px;
  }
  .library-tools .seg button {
    min-width: 0; min-height: 40px; padding-inline: 7px;
    white-space: normal; line-height: 1.08;
  }
  .library-tools .seg button:nth-child(-n+3) { grid-column: span 2; }
  .library-tools .seg button:nth-child(n+4) { grid-column: span 3; }
}

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 16px 14px; }
.tile { text-align: left; }
.tile-empty-hint { display: block; position: relative; z-index: 2; margin-top: 6px; color: var(--muted); font-size: 11px; line-height: 1.3; }
.search-empty { display: grid; gap: 12px; justify-items: start; }
.search-empty p { margin: 0; }
.tile .cvr { transition: transform .3s var(--ease-out); }
.tile:hover .cvr { transform: translateY(-3px); }
@media (hover: hover) and (pointer: fine) { .tile:hover .cvr-play { opacity: 1; transform: none; } }
.tile-t { font-weight: 600; font-size: 14px; margin: 9px 2px 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile-s { color: var(--muted); font-size: 12px; margin: 0 2px; }
.new-badge {
  display: inline-flex; align-items: center; min-height: 20px;
  margin: 5px 2px 2px; padding: 2px 8px; border-radius: 99px;
  background: rgba(232,169,59,.14); color: var(--gold);
  font-size: 10px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
}
.fav-cover::before {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: radial-gradient(circle at 52% 42%, rgba(232,169,59,.26), transparent 55%);
}
.fav-cover span { position: absolute; inset: 0; z-index: 2; display: grid; place-items: center; color: var(--gold); }
.fav-cover svg { width: 42%; height: 42%; fill: currentColor; stroke: currentColor; stroke-width: 1.6; }
.tile.newpl .cvr { display: grid; place-items: center; border: 1px dashed var(--line2); background: rgba(255,255,255,.02); }
.tile.newpl .cvr span { color: var(--muted); font-size: 30px; font-weight: 300; }

/* Squelette de chargement (avant l'arrivée du catalogue) */
.skel { position: relative; overflow: hidden; background: var(--panel2); border-radius: 12px; }
.skel::after { content: ''; position: absolute; inset: 0; transform: translateX(-100%); background: linear-gradient(90deg, transparent, rgba(255,255,255,.06), transparent); animation: skelShine 1.3s var(--ease-out) infinite; }
@keyframes skelShine { to { transform: translateX(100%); } }
.skel-cvr { aspect-ratio: 1; border-radius: 14px; }
.skel-line { height: 12px; margin-top: 10px; width: 78%; }
.skel-line.sm { width: 48%; height: 10px; margin-top: 7px; }

/* Panneau singles (scroll interne, pas de scroll de page infini) */
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.panel .search { padding: 12px; border-bottom: 1px solid var(--line); }
.tracklist { max-height: min(58vh, 560px); overflow-y: auto; overscroll-behavior: contain; }

/* Ligne de titre */
.trk { display: grid; grid-template-columns: 40px 1fr auto; align-items: center; gap: 10px; padding: 9px 12px; border-bottom: 1px solid var(--line); }
.trk:last-child { border-bottom: 0; }
.trk:hover { background: rgba(255,255,255,.03); }
.trk:active { background: rgba(232,169,59,.09); }
.trk.playing { background: rgba(232,169,59,.08); }
.trk-play { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line2); background: rgba(255,255,255,.03); display: grid; place-items: center; transition: transform .12s var(--ease-out); }
.trk-play:active { transform: scale(.9); }
.trk.playing .trk-play { background: var(--gold); color: var(--gold-ink); border-color: var(--gold); }
.trk-play svg { width: 14px; height: 14px; fill: currentColor; }
.trk-n { color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; text-align: center; }
.trk.playing .trk-n, .trk-num.playing { color: var(--gold); }
.trk-main { min-width: 0; cursor: pointer; }
.trk-t { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.trk-s { color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.trk-acts { display: flex; gap: 2px; align-items: center; }
.trk-ic { width: 36px; height: 36px; border-radius: 9px; border: 0; background: transparent; color: var(--muted); display: grid; place-items: center; transition: color .15s var(--ease-out); }
.trk-ic:hover { color: var(--gold); }
.trk-ic:active { color: var(--gold); background: rgba(232,169,59,.12); transform: scale(.92); }
.trk-ic svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.fav-btn svg, .fav-toggle svg { fill: none; stroke: currentColor; stroke-width: 1.8; }
.fav-btn.on, .fav-toggle.on { color: var(--gold); }
.fav-btn.on svg, .fav-toggle.on svg { fill: currentColor; stroke: currentColor; }
.empty { color: var(--muted); font-size: 13px; padding: 22px 14px; text-align: center; }
.resume-ribbon {
  display: flex; flex-wrap: wrap; align-items: stretch; gap: 10px;
  margin: -4px 0 18px;
}
.resume-ribbon button, .resume-new {
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 50px; padding: 10px 14px; border-radius: 14px;
  border: 1px solid rgba(232,169,59,.26);
  background: linear-gradient(180deg, rgba(232,169,59,.12), rgba(255,255,255,.025));
  color: var(--ink); box-shadow: 0 12px 32px rgba(0,0,0,.22);
}
.resume-ribbon button { text-align: left; cursor: pointer; }
.resume-ribbon button:active, .resume-new:active { transform: translateY(1px) scale(.98); background: rgba(232,169,59,.16); }
.resume-ribbon button svg { width: 17px; height: 17px; fill: currentColor; color: var(--gold); flex: 0 0 auto; }
.resume-ribbon b { display: block; font-size: 13px; line-height: 1.2; }
.resume-ribbon small { display: block; margin-top: 2px; color: var(--muted); font-size: 12px; line-height: 1.25; }
.resume-new { color: var(--gold); font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.search-results { display: grid; gap: 24px; }
.search-results h3 {
  margin: 0 0 12px; font-family: 'Plus Jakarta Sans', Impact, sans-serif;
  font-size: 20px; line-height: 1; text-transform: uppercase; letter-spacing: 0;
}

/* ==== Bottom sheet générique (album / playlist) ======================== */
.scrim { position: fixed; inset: 0; z-index: 60; background: rgba(0,0,0,.6); opacity: 0; pointer-events: none; transition: opacity .3s var(--ease-out); }
.scrim.show { opacity: 1; pointer-events: auto; }
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 61; max-height: 90vh;
  display: flex; flex-direction: column;
  background: var(--panel); border-top-left-radius: 22px; border-top-right-radius: 22px;
  border-top: 1px solid var(--line2);
  transform: translateY(100%); transition: transform .42s var(--ease-drawer);
  padding-bottom: var(--safe-b); will-change: transform;
}
.sheet.show { transform: translateY(0); }
.sheet-grab { padding: 10px 0 4px; display: grid; place-items: center; cursor: grab; touch-action: none; }
.sheet-grab i { width: 40px; height: 5px; border-radius: 99px; background: var(--line2); display: block; }
.sheet-hd { display: flex; gap: 16px; align-items: flex-end; padding: 8px 20px 18px; border-bottom: 1px solid var(--line); touch-action: none; }
.sheet-hd .cvr { width: 96px; height: 96px; flex: 0 0 auto; border-radius: 12px; }
.sheet-hd .cvr .cvr-t { font-size: 15px; }
.sheet-hd-meta { min-width: 0; flex: 1; }
.sheet-hd-meta h3 { font-family: 'Plus Jakarta Sans', Impact, sans-serif; font-size: clamp(24px, 6vw, 34px); text-transform: uppercase; line-height: .95; margin: 4px 0; }
.sheet-hd-acts { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.sheet .tracklist { flex: 1; max-height: none; }

/* On desktop la sheet devient une modale centrée */
@media (min-width: 760px) {
  .sheet { left: 50%; right: auto; bottom: auto; top: 50%; width: min(560px, 92vw); max-height: 84vh; border-radius: 22px; border: 1px solid var(--line2); transform: translate(-50%, -46%) scale(.96); opacity: 0; transition: transform .32s var(--ease-out), opacity .32s var(--ease-out); }
  .sheet.show { transform: translate(-50%, -50%); opacity: 1; }
  .sheet-grab { display: none; }
}

/* ==== Mini-player (fixe, translucide) =================================== */
.mini {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
  padding-bottom: var(--safe-b);
  background: rgba(20, 20, 26, .82); backdrop-filter: blur(20px) saturate(160%);
  border-top: 1px solid var(--line2);
  transform: translateY(120%); transition: transform .32s var(--ease-out);
}
.mini.show { transform: translateY(0); }
.mini-in { display: flex; align-items: center; gap: 12px; height: var(--mini-h); width: min(1080px, calc(100% - 24px)); margin: auto; }
.mini-tap { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 0; border: 0; background: transparent; text-align: left; padding: 0; border-radius: 12px; transition: background .14s var(--ease-out), transform .12s var(--ease-out); }
.mini-tap:active { background: rgba(232,169,59,.1); transform: scale(.99); }
.mini .cvr { width: 46px; height: 46px; flex: 0 0 auto; border-radius: 9px; }
.mini .cvr .cvr-t { font-size: 8px; left: 5px; right: 5px; bottom: 5px; }
.mini .cvr .cvr-m { display: none; }
.mini-info { min-width: 0; }
.mini-t { font-size: 13.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini-s { color: var(--muted); font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini-ctl { display: flex; align-items: center; gap: 4px; }
.mini-bar { position: absolute; left: 0; right: 0; top: 0; height: 2px; background: rgba(255,255,255,.1); }
.mini-bar i { display: block; height: 100%; width: 0; background: var(--gold); }
.pp { width: 42px; height: 42px; border-radius: 50%; border: 0; background: var(--gold); color: var(--gold-ink); display: grid; place-items: center; transition: transform .12s var(--ease-out); }
.pp:active { transform: scale(.92); }
.pp svg { width: 20px; height: 20px; fill: currentColor; }
.mini .ghostbtn { width: 40px; height: 40px; border: 0; background: transparent; color: var(--ink); display: grid; place-items: center; border-radius: 10px; transition: background .14s var(--ease-out), transform .12s var(--ease-out); }
.mini .ghostbtn:active { background: rgba(232,169,59,.12); transform: scale(.92); }
.mini .ghostbtn svg { width: 22px; height: 22px; fill: currentColor; }

/* ==== Now Playing plein écran (sheet) ================================== */
.np {
  position: fixed; inset: 0; z-index: 70; display: flex; flex-direction: column;
  background: var(--np-bg, #0c0c11);
  transform: translateY(100%); transition: transform .44s var(--ease-drawer);
  will-change: transform; padding-bottom: var(--safe-b);
}
.np.show { transform: translateY(0); }
.np::before { content: ""; position: absolute; inset: 0; z-index: 0; background: var(--np-glow, radial-gradient(circle at 50% 12%, rgba(232,169,59,.22), transparent 55%)); pointer-events: none; }
.np > * { position: relative; z-index: 1; }
/* header + pochette + titre = zone de drag généreuse (voir dragSheet dans le JS) */
.np-top { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; touch-action: none; cursor: grab; }
.np-art, .np-meta { touch-action: none; }
.np-grab { flex: 1; align-self: stretch; display: grid; place-items: center; touch-action: none; cursor: grab; }
.np-grab i { width: 46px; height: 5px; border-radius: 99px; background: rgba(255,255,255,.42); }
.np-top .iconbtn { border-color: transparent; background: rgba(255,255,255,.06); }
.np-body { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: 4px; padding: 8px 26px 18px; min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
.np-art { position: relative; width: min(58vh, 82vw, 420px); aspect-ratio: 1; }
.np-art .js-cover { position: absolute; inset: 0; }
.np-art .cvr { width: 100%; height: 100%; border-radius: 20px; box-shadow: 0 30px 70px rgba(0,0,0,.6); }
.np-art .cvr .cvr-t { font-size: clamp(22px, 6vw, 40px); }
.np-disc { position: absolute; top: 10%; right: -6%; width: 58%; aspect-ratio: 1; z-index: -1; transform: translateX(0); transition: transform .5s var(--ease-out); }
.np-disc img { width: 100%; height: 100%; border-radius: 50%; border: 5px solid #000; box-shadow: 0 20px 40px rgba(0,0,0,.55); }
.np.playing .np-disc { transform: translateX(30%); }
.np-disc.spin { animation: spin 11s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.np.playing .np-disc.spin { animation: spin 11s linear infinite; }
.np-meta { width: min(420px, 100%); margin-top: 22px; }
.np-title { font-family: 'Plus Jakarta Sans', Impact, sans-serif; font-size: clamp(26px, 7vw, 40px); text-transform: uppercase; line-height: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.np-sub { color: var(--muted); font-size: 14px; margin-top: 3px; }
.np-seek { display: flex; align-items: center; gap: 10px; width: min(420px, 100%); margin-top: 18px; }
.np-seek .t { font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; min-width: 34px; }
.seek { flex: 1; height: 6px; border-radius: 99px; background: rgba(255,255,255,.16); position: relative; cursor: pointer; touch-action: none; }
.seek i { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: var(--gold); border-radius: 99px; }
.seek::after { content: ""; position: absolute; inset: -8px 0; }
.np-controls { display: flex; align-items: center; justify-content: center; gap: 18px; width: min(420px, 100%); margin-top: 20px; }
.np-controls .ctl { width: 50px; height: 50px; border-radius: 50%; border: 0; background: transparent; color: var(--ink); display: grid; place-items: center; transition: transform .12s var(--ease-out), color .15s var(--ease-out); }
.np-controls .ctl:active { transform: scale(.9); }
.np-controls .ctl svg { width: 26px; height: 26px; fill: currentColor; }
.np-controls .ctl.small svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.np-controls .ctl.small.on { color: var(--gold); }
.np-controls .ctl.main { width: 72px; height: 72px; background: var(--gold); color: var(--gold-ink); box-shadow: 0 10px 30px rgba(232,169,59,.3); }
.np-controls .ctl.main svg { width: 32px; height: 32px; }
.np-extra { display: flex; align-items: center; justify-content: space-between; width: min(420px, 100%); margin-top: 20px; }
.np-queue-toggle { display: inline-flex; align-items: center; gap: 8px; border: 0; border-radius: 10px; background: transparent; color: var(--muted); font-size: 13px; font-weight: 600; transition: background .14s var(--ease-out), color .14s var(--ease-out), transform .12s var(--ease-out); }
.np-queue-toggle:active { background: rgba(232,169,59,.1); color: var(--ink); transform: scale(.97); }
.np-queue-toggle svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; }
/* file de lecture (panneau qui glisse depuis le bas de la sheet np) */
.np-queue { position: absolute; left: 0; right: 0; bottom: 0; z-index: 3; max-height: 62%; display: flex; flex-direction: column; background: var(--elev); border-top-left-radius: 20px; border-top-right-radius: 20px; border-top: 1px solid var(--line2); transform: translateY(101%); transition: transform .38s var(--ease-drawer); padding-bottom: var(--safe-b); }
.np-queue.show { transform: translateY(0); }
.np-queue-hd { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px 10px; }
.np-queue-hd .din { font-size: 18px; }
.q-list { overflow-y: auto; overscroll-behavior: contain; padding-bottom: 10px; }
.q-item { display: flex; align-items: center; gap: 10px; padding: 9px 20px; }
.q-item:hover { background: rgba(255,255,255,.04); }
.q-item:active { background: rgba(232,169,59,.1); }
.q-item.cur { background: rgba(232,169,59,.1); }
.q-jump { flex: 1; min-width: 0; display: flex; align-items: baseline; gap: 10px; border: 0; background: transparent; text-align: left; }
.q-jump .n { color: var(--muted); font-size: 11px; width: 18px; font-variant-numeric: tabular-nums; }
.q-item.cur .q-jump .n { color: var(--gold); }
.q-jump .t { font-size: 13.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.q-rm { width: 30px; height: 30px; border: 0; background: transparent; color: var(--muted); border-radius: 8px; display: grid; place-items: center; }
.q-rm:hover { color: var(--danger); }
.q-rm:active { background: rgba(255,143,107,.13); color: var(--danger); transform: scale(.92); }
.q-rm svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }

/* ==== États de chargement (buffering du lecteur + connexion) ==========
   Un seul langage : anneau conique effilé en gold, qui tourne vite (un
   spinner rapide se ressent comme un chargement plus court). `currentColor`
   suit le bouton — encre sombre sur pastille gold, gold sur fond sombre —
   donc un seul motif couvre tous les contrôles. Un contrôle en chargement
   n'affiche JAMAIS l'icône pause : tant qu'aucun son ne sort, on ne prétend
   pas « lecture en cours ». */
@keyframes fbspin { to { transform: rotate(360deg); } }
@keyframes fbpulse { 0%, 100% { opacity: .3; } 50% { opacity: 1; } }
@keyframes fbseek { to { transform: translateX(250%); } }

/* Anneau tournant injecté dans le bouton (masque radial = trait fin). */
.ctl.main, .mini .pp, .trk-play, .btn-gold { position: relative; }
.ctl.main.is-loading svg, .mini .pp.is-loading svg, .trk-play.is-loading svg { opacity: 0; }
.ctl.main.is-loading::after, .mini .pp.is-loading::after, .trk-play.is-loading::after {
  content: ""; position: absolute; inset: 0; margin: auto; border-radius: 50%;
  background: conic-gradient(from 0deg, transparent 0 8%, currentColor);
  -webkit-mask: radial-gradient(farthest-side, #0000 calc(100% - 2.5px), #000 0);
          mask: radial-gradient(farthest-side, #0000 calc(100% - 2.5px), #000 0);
  animation: fbspin .7s linear infinite;
}
.ctl.main.is-loading::after { width: 34px; height: 34px; }
.mini .pp.is-loading::after { width: 22px; height: 22px; }
.trk-play.is-loading::after {
  width: 18px; height: 18px;
  -webkit-mask: radial-gradient(farthest-side, #0000 calc(100% - 2px), #000 0);
          mask: radial-gradient(farthest-side, #0000 calc(100% - 2px), #000 0);
}

/* Barre de progression pendant le buffering : balayage indéterminé (la
   position réelle est inconnue tant que les métadonnées ne sont pas là). */
.np.is-loading .seek { overflow: hidden; }
.np.is-loading .seek i { opacity: 0; }
.np.is-loading .seek::before {
  content: ""; position: absolute; inset: 0; border-radius: 99px; z-index: 1;
  width: 40%; background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--gold) 60%, transparent), transparent);
  transform: translateX(-120%); animation: fbseek 1.15s var(--ease-out) infinite;
}
.np.is-loading .np-seek .js-cur { color: var(--muted); }

/* Spinner de connexion (échange du lien magique). */
.gate-msg.is-loading { color: var(--gold); display: flex; align-items: center; justify-content: center; gap: 9px; }
.gate-msg.is-loading::before {
  content: ""; flex: 0 0 auto; width: 15px; height: 15px; border-radius: 50%;
  background: conic-gradient(from 0deg, transparent 0 8%, var(--gold));
  -webkit-mask: radial-gradient(farthest-side, #0000 calc(100% - 2px), #000 0);
          mask: radial-gradient(farthest-side, #0000 calc(100% - 2px), #000 0);
  animation: fbspin .7s linear infinite;
}
#gate.is-working .gate-card > img { animation: fbpulse 1.7s ease-in-out infinite; }

/* Bouton « Recevoir mon lien » pendant l'envoi : le libellé cède la place
   à l'anneau, le bouton se verrouille (pas de double-envoi). */
.btn-gold.is-loading { color: transparent; pointer-events: none; }
.btn-gold.is-loading::after {
  content: ""; position: absolute; inset: 0; margin: auto; width: 18px; height: 18px; border-radius: 50%;
  background: conic-gradient(from 0deg, transparent 0 8%, var(--gold-ink));
  -webkit-mask: radial-gradient(farthest-side, #0000 calc(100% - 2px), #000 0);
          mask: radial-gradient(farthest-side, #0000 calc(100% - 2px), #000 0);
  animation: fbspin .7s linear infinite;
}

/* Mouvement réduit : l'anneau ne tourne pas mais pulse (un indicateur reste
   nécessaire), et le balayage de la barre devient une pulsation d'opacité. */
@media (prefers-reduced-motion: reduce) {
  .ctl.main.is-loading::after, .mini .pp.is-loading::after, .trk-play.is-loading::after,
  .gate-msg.is-loading::before, .btn-gold.is-loading::after {
    background: currentColor; -webkit-mask: none; mask: none; animation: fbpulse 1.1s ease-in-out infinite;
  }
  .gate-msg.is-loading::before { background: var(--gold); }
  .btn-gold.is-loading::after { background: var(--gold-ink); }
  .np.is-loading .seek::before { animation: fbpulse 1.1s ease-in-out infinite; transform: none; width: 100%; }
  #gate.is-working .gate-card > img { animation: fbpulse 1.7s ease-in-out infinite; }
}

/* ==== Menu "ajouter à la playlist" ===================================== */
.addpop { position: fixed; z-index: 80; min-width: 230px; max-height: 320px; overflow-y: auto; background: var(--elev); border: 1px solid var(--line2); border-radius: 14px; padding: 6px; box-shadow: 0 24px 50px rgba(0,0,0,.6); opacity: 0; transform: scale(.96); pointer-events: none; transition: opacity .16s var(--ease-out), transform .16s var(--ease-out); transform-origin: top right; }
.addpop.open { opacity: 1; transform: none; pointer-events: auto; }
.addpop .hd { padding: 8px 12px 4px; color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
.addpop button { display: block; width: 100%; text-align: left; padding: 10px 12px; border: 0; border-radius: 9px; background: transparent; color: var(--ink); font-size: 13.5px; }
.addpop button:hover { background: rgba(255,255,255,.06); }
.addpop button:active { background: rgba(232,169,59,.14); transform: scale(.98); }

/* ==== Toast ============================================================ */
.toast { position: fixed; left: 50%; bottom: calc(var(--mini-h) + var(--safe-b) + 18px); z-index: 90; transform: translate(-50%, 14px); background: var(--elev); color: var(--ink); border: 1px solid var(--line2); border-radius: 99px; padding: 11px 20px; font-size: 13px; font-weight: 600; box-shadow: 0 16px 36px rgba(0,0,0,.5); opacity: 0; pointer-events: none; transition: opacity .2s var(--ease-out), transform .2s var(--ease-out); }
.toast.show { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.toast.has-act { border-radius: 14px; padding: 12px 12px 12px 18px; display: flex; align-items: center; gap: 14px; max-width: min(92vw, 440px); text-align: left; }
.toast.has-act span { flex: 1; }
.toast-act { flex: none; border: 0; border-radius: 9px; background: var(--gold); color: var(--gold-ink); font: inherit; font-weight: 700; padding: 8px 14px; cursor: pointer; }
.toast-act:active { transform: scale(.96); }

/* Échec du chargement initial de la bibliothèque */
.load-error { display: grid; gap: 16px; justify-items: center; text-align: center; padding: 46px 18px; color: var(--muted); font-size: 14px; font-weight: 600; }

/* ==== Desktop ajustements ============================================== */
@media (min-width: 760px) {
  .app-main { padding-top: 28px; }
  .rail { grid-auto-columns: 190px; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 22px 18px; }
  .menu-pop .chip-m { display: none; }
}
@media (max-width: 520px) {
  .chip { display: none; }              /* l'échéance passe dans le menu ⋯ */
  .menu-pop .chip-m { display: block; padding: 9px 12px; color: var(--muted); font-size: 12px; }
  .menu-pop .chip-m b { color: var(--ink); }
  .rail { grid-auto-columns: 45vw; }
}

/* ==== Hero « Dernière sortie » ========================================= */
.hero-sec { margin-bottom: 40px; }
.hero {
  position: relative; overflow: hidden; border-radius: 24px;
  border: 1px solid var(--line2);
  background:
    radial-gradient(120% 140% at 88% -10%, color-mix(in srgb, var(--hero-accent, var(--gold)) 22%, transparent) 0%, transparent 52%),
    linear-gradient(150deg, var(--panel) 0%, #0b0b0f 96%);
  padding: 22px;
}
.hero-glow { position: absolute; inset: auto -20% -60% auto; width: 70%; aspect-ratio: 1; z-index: 0;
  background: radial-gradient(circle, color-mix(in srgb, var(--hero-accent, var(--gold)) 40%, transparent), transparent 62%);
  filter: blur(38px); opacity: .55; pointer-events: none; }
.hero-inner { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 20px; }
.hero-art { position: relative; width: min(72vw, 300px); align-self: center; cursor: pointer; }
.hero-cover { position: relative; z-index: 1; }
.hero-cover .cvr { border-radius: 18px; box-shadow: 0 26px 60px rgba(0,0,0,.55), 0 0 0 1px rgba(255,255,255,.05) inset; }
.hero-disc { position: absolute; top: 8%; right: -13%; width: 74%; aspect-ratio: 1; z-index: 0; }
.hero-disc img { width: 100%; height: 100%; border-radius: 50%; border: 5px solid #08080a; box-shadow: 0 20px 46px rgba(0,0,0,.55); animation: spin 22s linear infinite; }
.hero-play {
  position: absolute; right: 12px; bottom: 12px; z-index: 2; width: 60px; height: 60px; border-radius: 50%;
  border: 0; background: var(--gold); color: var(--gold-ink); display: grid; place-items: center;
  box-shadow: 0 12px 30px rgba(232,169,59,.42);
  transition: transform .18s var(--ease-out), box-shadow .18s var(--ease-out);
}
.hero-play svg { width: 26px; height: 26px; fill: currentColor; margin-left: 2px; }
.hero-art:hover .hero-play { transform: scale(1.06); box-shadow: 0 16px 38px rgba(232,169,59,.55); }
.hero-play:active { transform: scale(.94); }
.hero-meta { min-width: 0; }
.hero-eyebrow { display: inline-flex; align-items: center; gap: 7px; color: var(--gold); font-size: 11px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.hero-eyebrow i { width: 7px; height: 7px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 0 color-mix(in srgb, var(--gold) 70%, transparent); animation: heroPulse 2s var(--ease-out) infinite; }
@keyframes heroPulse { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--gold) 60%, transparent); } 70%,100% { box-shadow: 0 0 0 9px transparent; } }
.hero-title { font-family: 'Plus Jakarta Sans', Impact, sans-serif; font-size: clamp(34px, 11vw, 60px); text-transform: uppercase; letter-spacing: -.01em; line-height: .92; margin: 8px 0 6px; }
.hero-sub { color: var(--muted); font-size: 14px; }
.hero-acts { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.hero-acts .btn-gold { min-height: 50px; padding: 12px 26px; font-size: 16px; }
@media (min-width: 720px) {
  .hero { padding: 30px; }
  .hero-inner { flex-direction: row; align-items: center; gap: 40px; }
  .hero-art { width: min(34vw, 300px); flex: 0 0 auto; align-self: auto; }
  .hero-meta { flex: 1; }
}

/* ==== Accès Premium : les deux promesses clés en un regard ============ */
.member-access {
  display: grid; gap: 18px; align-items: center; margin-top: -2px;
  padding: 20px; border: 1px solid rgba(232,169,59,.26); border-radius: 16px;
  background: linear-gradient(110deg, rgba(232,169,59,.13), rgba(255,255,255,.025) 48%, transparent);
}
.member-access-copy { min-width: 0; }
.member-access h2 { margin: 5px 0 6px; font-family: 'Plus Jakarta Sans', Impact, sans-serif; font-size: clamp(27px, 7vw, 36px); line-height: .96; text-transform: uppercase; }
.member-access p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.48; }
.member-access-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 9px; }
.member-access-actions .btn-gold, .member-access-actions .btn-ghost { min-height: 46px; }
.member-access-actions p { flex-basis: 100%; font-size: 12px; }
.quick-resume[hidden] { display: none; }
@media (min-width: 760px) {
  .member-access { grid-template-columns: minmax(0, 1fr) auto; padding: 22px 24px; }
  .member-access-actions { justify-content: flex-end; max-width: 430px; }
  .member-access-actions p { text-align: right; }
}

.library-sort { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font-size: 12px; font-weight: 700; white-space: nowrap; }
.library-sort select { min-height: 36px; border: 1px solid var(--line2); border-radius: 9px; background: var(--panel2); color: var(--ink); font: inherit; padding: 0 8px; }
.ov-help { margin: 0 0 20px; padding: 0; list-style: none; display: grid; gap: 12px; color: var(--muted); font-size: 13px; line-height: 1.48; }
.ov-help li { position: relative; padding-left: 15px; }
.ov-help li::before { content: ""; position: absolute; left: 0; top: .55em; width: 5px; height: 5px; border-radius: 50%; background: var(--gold); }

/* ==== Rail « Fraîchement sorti » : cartes pochettes plus grandes ======== */
.rel-card { transition: transform .3s var(--ease-out); }
.rel-card .cvr { box-shadow: 0 10px 28px rgba(0,0,0,.42); }
@media (hover: hover) and (pointer: fine) {
  .rel-card:hover { transform: translateY(-4px); }
  .rel-card:hover .cvr-play { opacity: 1; transform: none; }
}
.rel-badge { display: inline-block; color: var(--gold); background: color-mix(in srgb, var(--gold) 14%, transparent); border-radius: 99px; padding: 2px 9px; }

/* ==== Singles en grille de pochettes ==================================== */
.singles-head { margin-bottom: 16px; }
.search { position: relative; width: min(360px, 100%); }
.search .search-ic { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; fill: none; stroke: var(--muted); stroke-width: 1.9; stroke-linecap: round; pointer-events: none; }
.singles-head .search input { padding-left: 42px; border-radius: 99px; }
.tile .cvr-play { transition: opacity .2s var(--ease-out), transform .2s var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .tile:hover .cvr-play { opacity: 1; transform: none; } }

/* Entrée en cascade des pochettes (grille + rail) */
@media (prefers-reduced-motion: no-preference) {
  .grid .tile, .rail .rel-card { animation: coverIn .42s var(--ease-out) both; }
  .grid .tile:nth-child(1),.rail .rel-card:nth-child(1) { animation-delay: 0ms; }
  .grid .tile:nth-child(2),.rail .rel-card:nth-child(2) { animation-delay: 40ms; }
  .grid .tile:nth-child(3),.rail .rel-card:nth-child(3) { animation-delay: 80ms; }
  .grid .tile:nth-child(4),.rail .rel-card:nth-child(4) { animation-delay: 120ms; }
  .grid .tile:nth-child(5),.rail .rel-card:nth-child(5) { animation-delay: 160ms; }
  .grid .tile:nth-child(6),.rail .rel-card:nth-child(6) { animation-delay: 200ms; }
  .grid .tile:nth-child(n+7) { animation-delay: 240ms; }
}
@keyframes coverIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* ==== Lecteur plein écran : présence renforcée ========================== */
.np-eyebrow { display: block; color: var(--gold); font-size: 11px; letter-spacing: .18em; margin-bottom: 6px; }
.np-panel { display: flex; flex-direction: column; align-items: center; width: min(440px, 100%); }
.np-panel > * { width: 100%; }
.np-meta { text-align: center; }
/* Desktop : lecteur en 2 colonnes (grande pochette à gauche, panneau à droite). */
@media (min-width: 900px) {
  .np-body { flex-direction: row; justify-content: center; align-items: center; gap: clamp(32px, 6vw, 80px); padding: 20px 40px; overflow: hidden; }
  .np-art { width: min(52vh, 460px); }
  .np-panel { align-items: flex-start; width: min(460px, 42vw); }
  .np-meta { text-align: left; margin-top: 0; }
  .np-controls { justify-content: flex-start; }
  .np-disc { top: 8%; right: -8%; }
  .np.playing .np-disc { transform: translateX(24%); }
}

/* ==== Réduction de mouvement =========================================== */
/* Accessibilité clavier : anneau de focus visible uniquement en navigation clavier
   (:focus-visible n'apparaît pas au tap/clic souris, donc n'altère pas l'UI tactile). */
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; border-radius: 4px; }

@media (prefers-reduced-motion: reduce) {
  .np-disc.spin, .np.playing .np-disc.spin { animation: none; }
  .hero-disc img { animation: none; }
  .hero-eyebrow i { animation: none; }
  .skel::after { animation: none; }
  .np-disc { transition: none; }
  * { scroll-behavior: auto; }
  .sheet, .np, .mini, .np-queue, .scrim { transition-duration: .001ms; }
  .mobile-home-action { animation: none; }
}


/* ==========================================================================
   Direction visuelle et accessibilité — passe agence 2026
   ========================================================================== */
body {
  background:
    radial-gradient(ellipse at 52% -12%, rgba(232,169,59,.11), transparent 28rem),
    radial-gradient(ellipse at 6% 38%, rgba(255,124,76,.055), transparent 30rem),
    var(--bg);
}
.topbar { background: rgba(8,8,11,.82); backdrop-filter: blur(18px) saturate(135%); }
.brand img { height: 52px; }
.iconbtn { min-width: 44px; min-height: 44px; }
.menu-pop { box-shadow: 0 22px 55px rgba(0,0,0,.52); }
.rel-card, .tile { position: relative; }
.card-hit { position: absolute; inset: 0; z-index: 1; width: 100%; border: 0; padding: 0; background: transparent; border-radius: 16px; cursor: pointer; transition: background .12s var(--ease-out), box-shadow .12s var(--ease-out); }
.card-hit:active { background: rgba(232,169,59,.14); box-shadow: inset 0 0 0 1px rgba(232,169,59,.34); }
.cvr-play, .cvr-add { z-index: 2; }
.card-hit:focus-visible { outline: 3px solid var(--gold); outline-offset: 4px; }
.trk-main { display:block; width:100%; min-width:0; padding:4px 0; border:0; border-radius:8px; background:transparent; color:inherit; text-align:left; cursor:pointer; transition:background .12s var(--ease-out), transform .12s var(--ease-out); }
.trk-main:active { background: rgba(232,169,59,.1); transform: translateY(1px); }
.trk-main span { display:block; }
.seek:focus-visible { outline: 2px solid var(--gold); outline-offset: 5px; }
.seek:focus-visible i::after { content:""; position:absolute; right:-6px; top:50%; width:12px; height:12px; border-radius:50%; background:var(--gold); transform:translateY(-50%); box-shadow:0 0 0 4px rgba(232,169,59,.2); }
.sheet, .np { box-shadow: 0 -28px 90px rgba(0,0,0,.52); }

@media (max-width: 520px) {
  .brand img { height: 46px; }
}

/* ==========================================================================
   Invitation à laisser un avis (bannière + modale). Présentée comme un
   service demandé — retirée définitivement une fois l'avis déposé.
   ========================================================================== */
.rev-banner {
  display: flex; flex-wrap: wrap; align-items: center; gap: 14px 18px;
  margin: 4px 0 22px; padding: 15px 17px;
  background: linear-gradient(180deg, rgba(232,169,59,.12), rgba(232,169,59,.05));
  border: 1px solid rgba(232,169,59,.32); border-radius: 14px;
}
.rev-banner-txt { flex: 1 1 260px; display: flex; flex-direction: column; gap: 3px; }
.rev-banner-txt strong { font-size: 14px; font-weight: 700; }
.rev-banner-txt span { font-size: 13px; color: var(--muted); line-height: 1.45; }
.rev-banner-acts { display: flex; align-items: center; gap: 6px; }
.rev-banner-acts .btn-gold { min-height: 40px; padding: 9px 18px; font-size: 14px; }
.rev-banner-later {
  border: 0; background: transparent; color: var(--muted);
  font: inherit; font-size: 13px; font-weight: 600; padding: 9px 12px; cursor: pointer;
}
.rev-banner-later:hover { color: var(--ink); }
.rev-banner-later:active { color: var(--ink); transform: scale(.97); }

.rev-modal {
  position: fixed; z-index: 62; left: 50%; top: 50%; transform: translate(-50%, -46%);
  width: min(94vw, 480px); max-height: 88vh; overflow-y: auto;
  background: var(--panel); border: 1px solid var(--line2); border-radius: 18px;
  padding: 26px 22px 22px; box-shadow: 0 30px 70px rgba(0,0,0,.6);
  opacity: 0; pointer-events: none; transition: opacity .22s var(--ease-out), transform .22s var(--ease-out);
}
.rev-modal.show { opacity: 1; pointer-events: auto; transform: translate(-50%, -50%); }
.rev-modal h3 { margin: 0 0 6px; font-family: 'Plus Jakarta Sans', Impact, sans-serif; font-weight: 700; font-size: 26px; letter-spacing: .01em; }
.rev-lead { margin: 0 0 16px; font-size: 13px; color: var(--muted); line-height: 1.5; }
.rev-x {
  position: absolute; top: 12px; right: 12px; width: 34px; height: 34px; border-radius: 50%;
  border: 1px solid var(--line); background: var(--panel2); color: var(--ink);
  display: grid; place-items: center; cursor: pointer;
}
.rev-x svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.rev-stars { display: flex; gap: 6px; margin-bottom: 14px; }
.rev-star {
  border: 0; background: transparent; cursor: pointer; padding: 2px;
  font-size: 32px; line-height: 1; color: var(--line2); transition: color .12s var(--ease-out), transform .12s var(--ease-out);
}
.rev-star:hover { transform: scale(1.08); }
.rev-star:active { transform: scale(.9); }
.rev-star.on { color: var(--gold); }
.rev-chips { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 14px; }
.rev-chip {
  border: 1px solid var(--line2); background: var(--panel2); color: var(--ink);
  font: inherit; font-size: 12.5px; font-weight: 500; line-height: 1.3;
  padding: 7px 11px; border-radius: 999px; cursor: pointer; text-align: left;
  transition: border-color .12s var(--ease-out), background .12s var(--ease-out);
}
.rev-chip:hover { border-color: var(--gold); }
.rev-chip:active { border-color: var(--gold); background: rgba(232,169,59,.18); transform: scale(.97); }
.rev-chip.on { border-color: var(--gold); background: rgba(232,169,59,.16); }
.rev-ta {
  width: 100%; min-height: 84px; resize: vertical; margin-bottom: 10px;
  background: var(--panel2); border: 1px solid var(--line2); border-radius: 11px;
  color: var(--ink); font: inherit; font-size: 14px; padding: 11px 13px;
}
.rev-in {
  width: 100%; margin-bottom: 14px;
  background: var(--panel2); border: 1px solid var(--line2); border-radius: 11px;
  color: var(--ink); font: inherit; font-size: 14px; padding: 11px 13px;
}
.rev-ta:focus, .rev-in:focus { outline: none; border-color: var(--gold); }
.rev-hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.rev-send { width: 100%; min-height: 48px; }
.rev-msg { margin: 10px 0 0; font-size: 13px; font-weight: 600; color: var(--gold); min-height: 1em; }

@media (prefers-reduced-motion: reduce) {
  .rev-modal { transition-duration: .001ms; }
}

.menu-pop #revMenuBtn svg { fill: currentColor; stroke: none; }

/* ==========================================================================
   Overlays génériques : accueil, installation, saisie, confirmation.
   Mobile-first : le socle décrit le téléphone (feuille centrée pleine largeur).
   ========================================================================== */
.ov-scrim { position: fixed; inset: 0; z-index: 94; background: rgba(0,0,0,.66); backdrop-filter: blur(2px); opacity: 0; pointer-events: none; transition: opacity .24s var(--ease-out); }
.ov-scrim.show { opacity: 1; pointer-events: auto; }
.ov-box {
  position: fixed; z-index: 95; left: 50%; top: 50%;
  width: min(94vw, 460px); max-height: 88vh; overflow-y: auto;
  transform: translate(-50%, -44%) scale(.98);
  background: var(--panel); border: 1px solid var(--line2); border-radius: 20px;
  padding: 24px 20px calc(20px + var(--safe-b)); box-shadow: 0 30px 70px rgba(0,0,0,.62);
  opacity: 0; pointer-events: none;
  transition: opacity .22s var(--ease-out), transform .28s var(--ease-drawer);
}
.ov-box.show { opacity: 1; pointer-events: auto; transform: translate(-50%, -50%) scale(1); }
.ov-h { margin: 0 0 8px; font-family: 'Plus Jakarta Sans', Impact, sans-serif; font-weight: 700; font-size: 27px; letter-spacing: .01em; }
.ov-lead { margin: 0 0 18px; font-size: 13.5px; color: var(--muted); line-height: 1.5; }
.ov-msg { margin: 4px 0 20px; font-size: 15px; line-height: 1.5; }
.ov-full { width: 100%; min-height: 50px; }
.ov-acts { display: flex; gap: 10px; justify-content: flex-end; }
.ov-acts .btn-gold, .ov-acts .btn-ghost { min-height: 46px; }
.ov-danger { background: var(--danger); box-shadow: 0 8px 22px rgba(255,143,107,.22); }
.ov-field {
  width: 100%; margin: 0 0 18px; background: var(--panel2); border: 1px solid var(--line2);
  border-radius: 12px; color: var(--ink); font: inherit; font-size: 16px; padding: 13px 14px;
}
.ov-field:focus { outline: none; border-color: var(--gold); }
/* Accueil : liste de repères */
.ov-tips { list-style: none; margin: 0 0 20px; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.ov-tips li { display: flex; gap: 13px; align-items: flex-start; }
.ov-tip-ic {
  flex: 0 0 40px; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center;
  font-size: 19px; background: linear-gradient(180deg, rgba(232,169,59,.16), rgba(232,169,59,.05));
  border: 1px solid rgba(232,169,59,.28); color: var(--gold);
}
.ov-tip-tx { display: flex; flex-direction: column; gap: 2px; }
.ov-tip-tx strong { font-size: 14.5px; font-weight: 700; }
.ov-tip-tx span { font-size: 13px; color: var(--muted); line-height: 1.45; }

/* Barre « Installer l'appli » (une fois, après l'accueil) */
.install-bar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px;
  margin: 4px 0 22px; padding: 14px 16px;
  background: linear-gradient(180deg, rgba(232,169,59,.12), rgba(232,169,59,.05));
  border: 1px solid rgba(232,169,59,.32); border-radius: 14px;
}
.install-ic img { display: block; border-radius: 10px; }
.install-tx { flex: 1 1 240px; display: flex; flex-direction: column; gap: 3px; }
.install-tx strong { font-size: 14px; font-weight: 700; }
.install-tx span { font-size: 12.5px; color: var(--muted); line-height: 1.45; }
.install-acts { display: flex; align-items: center; gap: 6px; }
.install-acts .btn-gold { min-height: 40px; padding: 9px 18px; font-size: 14px; }
.install-later { border: 0; background: transparent; color: var(--muted); font: inherit; font-size: 13px; font-weight: 600; padding: 9px 12px; cursor: pointer; }
.install-later:hover { color: var(--ink); }
.install-later:active { color: var(--ink); transform: scale(.97); }

/* Popover « Ajouter à… » → feuille par le bas sur mobile */
.addpop.as-sheet {
  top: auto !important; left: 0 !important; right: 0; bottom: 0;
  width: auto; min-width: 0; max-width: none; max-height: 72vh;
  border-radius: 18px 18px 0 0; transform: translateY(100%); transform-origin: bottom center;
  padding: 8px 10px calc(12px + var(--safe-b)); box-shadow: 0 -18px 50px rgba(0,0,0,.6);
}
.addpop.as-sheet.open { transform: translateY(0); }
.addpop.as-sheet::before { content: ""; display: block; width: 40px; height: 4px; border-radius: 3px; background: var(--line2); margin: 4px auto 8px; }
.addpop.as-sheet .hd { padding: 4px 12px 8px; font-size: 12px; }
.addpop.as-sheet button { padding: 15px 12px; font-size: 15px; border-radius: 11px; }

@media (min-width: 761px) {
  .ov-box { width: min(92vw, 460px); }
}
@media (prefers-reduced-motion: reduce) {
  .ov-scrim, .ov-box, .addpop.as-sheet { transition-duration: .001ms; }
}

/* ==========================================================================
   Passe UX 2026-09 — repli pochette robuste, libellés lecteur, scrub mini-player
   ========================================================================== */

/* Pochette réelle posée SUR le repli synthwave (.cvr.gen.has-img). Tant que
   l'image charge, on masque le motif/texte généré ; si elle casse, le JS retire
   `has-img` (écouteur `error` délégué, CSP-safe) et le repli réapparaît. */
.cvr.has-img::before, .cvr.has-img::after { content: none; }
.cvr.has-img > .cvr-m, .cvr.has-img > .cvr-t { display: none; }
.cvr.has-img > img { position: relative; z-index: 1; }

/* Lecteur plein écran : sur mobile, les 4 actions (File / Favori / Playlist /
   Télécharger) restent en icônes seules pour éviter l'effet tassé en bas. */
.np-queue-toggle { white-space: nowrap; }
@media (max-width: 640px) {
  .np-art { width: min(50svh, 78vw, 340px); flex: 0 0 auto; }
  .np-extra { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin-top: 16px; }
  .np-extra .np-queue-toggle {
    justify-self: center; justify-content: center; width: 46px; height: 46px; min-width: 46px; min-height: 46px; padding: 0;
    border-radius: 50%; background: rgba(255,255,255,.055);
  }
  .np-extra .np-queue-toggle span {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
  }
  .np-extra .np-queue-toggle svg { width: 22px; height: 22px; }
}
@media (max-height: 700px) and (max-width: 640px) {
  .np-top { padding-block: 10px; }
  .np-body { padding-top: 2px; }
  .np-art { width: min(43svh, 72vw, 300px); }
  .np-meta { margin-top: 14px; }
  .np-seek { margin-top: 12px; }
  .np-controls { margin-top: 14px; }
}

/* Cibles physiques cohérentes, même quand l’icône reste visuellement compacte. */
.trk-ic, .q-rm, .rev-x { min-width: 44px; min-height: 44px; }
.q-item { padding-block: 7px; }

/* ---- Barre de lecture desktop persistante (≥900px) ------------------------
   Sur ordinateur, le mini-player devient le VRAI lecteur : 3 zones — titre à
   gauche, transport + progression au centre, actions à droite. Plus besoin
   d'ouvrir le plein écran pour piloter : celui-ci n'est plus qu'une vue
   « agrandie » optionnelle (clic sur la pochette/titre). Sur mobile, la barre
   compacte d'origine est conservée (tap → plein écran). */
.mini-center, .mini-actions { display: none; }   /* mobile : masqués */
.mini-ic {
  width: 40px; height: 40px; flex: 0 0 auto; border: 0; background: transparent;
  color: var(--ink); border-radius: 50%; display: grid; place-items: center;
  transition: color .15s var(--ease-out), background .15s var(--ease-out);
}
.mini-ic:hover { color: var(--gold); background: rgba(255,255,255,.06); }
.mini-ic:active { transform: scale(.92); }
.mini-ic svg { width: 20px; height: 20px; }
.mini-ic.js-prev svg, .mini-ic.js-next svg { fill: currentColor; }
.mini-ic.js-dlcurrent svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
/* .mini-fav hérite de .fav-toggle : contour, rempli gold quand actif (.on). */

@media (min-width: 900px) {
  :root { --mini-h: 84px; }                       /* barre plus haute → padding bas du body + toast suivent la variable */
  .mini-in {
    display: grid; grid-template-columns: minmax(200px, 1fr) auto minmax(200px, 1fr);
    align-items: center; gap: 24px; width: min(1500px, calc(100% - 48px));
  }
.mini-tap { justify-self: start; max-width: 340px; }
  .mini .cvr { width: 52px; height: 52px; }
  .mini-center { display: flex; flex-direction: column; align-items: center; gap: 7px; width: min(560px, 44vw); justify-self: center; }
  .mini-transport { display: flex; align-items: center; gap: 14px; }
  .mini-transport .pp { width: 44px; height: 44px; }
  .mini-transport .pp svg { width: 20px; height: 20px; }
  .mini-seek { display: flex; align-items: center; gap: 10px; width: 100%; }
  .mini-seek .t { font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; min-width: 34px; }
  .mini-seek .seek { flex: 1; }
  .mini-actions { display: flex; align-items: center; gap: 4px; justify-self: end; }
  .mini-ctl { display: none; }                    /* commandes mobiles masquées sur desktop */
  .mini-bar { display: none; }                    /* progression fine remplacée par le vrai seek */
}
