/* ════════════════════════════════════════════════════════════════════
   topbar.css — barre persistante unifiée de Cizi.fr  (VERSION CONSOLIDÉE)
   ────────────────────────────────────────────────────────────────────
   Refonte "franc" du 2026-06-14 : un seul bloc par sélecteur, valeurs
   finales identiques au rendu précédent (calculées depuis la cascade des
   ~30 patchs empilés). Aucune intention visuelle changée.

   topbar-layout-v3-marker — 20260705 · consolidation n°2 : UNE SEULE LIGNE.
   Layout : [burger][logo /catégorie /section▾][🔍] ─ [HH:MM] ─ [mini-player][zoom][⛶]
   · La ligne 2 fixe (top:40px) est supprimée : ses choix (Accueil, Films,
     Séries — Sono retiré) deviennent un SECOND fil d'Ariane "/Section" à la
     suite de la catégorie, MÊME LOGIQUE que /Catégorie : bouton + dropdown
     (classes .topbar-cat / .topbar-dropdown réutilisées, cf.
     section-dropdown-marker). Vision browse uniquement.
   · La loupe a un emplacement FIXE en fin de groupe gauche : la préférence
     Recherche centre/droite est morte (cizi-menu.js v4.4). Compat PHP
     transitoire conservée plus bas (bloc topbar-layout-v2) tant
     qu'entete.php n'a pas suivi.
   · Loupe + onglets ne s'effacent plus en plein écran QUE si l'horloge y est
     réellement affichée (bloc fs-hide-when-clock) — l'ancien masquage FS
     inconditionnel (dont le patch fs-search-class-fix) est SUPPRIMÉ.

   Conventions :
   - Les variables --cizi-*-outline portent le contour noir cartoon.
   - Les blocs "ÉTAT" (body[data-*], :fullscreen, .is-*) pilotent le
     comportement (FS vidéo/musique, iframe Vision, auto-hide) : NE PAS
     toucher sans tester les 6 scénarios (cf. checklist en pied de fichier).
   ════════════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Baloo+2:wght@700;800&display=swap');

:root {
  /* Police cartoon des catégories/labels. Un seul point de changement :
     remplacer cette valeur (+ l'@import ci-dessus) pour changer partout. */
  --cizi-font-cartoon: 'Baloo 2', system-ui, sans-serif;
  --cizi-text-outline:
    -1px -1px 0 #000,  1px -1px 0 #000,
    -1px  1px 0 #000,  1px  1px 0 #000,
     0    0   4px rgba(0, 0, 0, 0.75);
  --cizi-img-outline:
    drop-shadow( 1px  1px 0 rgba(0, 0, 0, 0.95))
    drop-shadow(-1px -1px 0 rgba(0, 0, 0, 0.95))
    drop-shadow(-1px  1px 0 rgba(0, 0, 0, 0.95))
    drop-shadow( 1px -1px 0 rgba(0, 0, 0, 0.95))
    drop-shadow( 0    0   3px rgba(0, 0, 0, 0.7));
  /* Rattrapage optique vertical du label catégorie vs logo.
     0 par défaut avec Baloo 2 ; ajuster de -1 à -3px si besoin de remonter,
     ou +1/+2px pour descendre le label. */
  --cizi-cat-fine-tune: 0px;
}

/* ════════════════════════ STRUCTURE GÉNÉRALE ════════════════════════ */

/* Topbar : flex, transparente, contour géré par les enfants. Hissée au
   sommet du stacking (INT_MAX-7) pour passer au-dessus de toute vignette
   Vision. isolation + translateZ = stacking context racine garanti. */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 48px;
  display: flex;
  align-items: center;
  gap: 0;
  padding: 0 28px 0 16px;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-bottom: none;
  font-family: monospace;
  color: rgba(240, 235, 220, 0.85);
  z-index: 2147483640;
  isolation: isolate;
  transform: translateZ(0);
}

/* Compense la hauteur de la topbar fixe (sauf Vision/Sono en iframe, voir ÉTATS). */
body { padding-top: var(--topbar-h, 56px); }

/* ════════════════════════ ZONE GAUCHE ════════════════════════ */

.topbar-left {
  display: flex;
  align-items: flex-end;   /* bas du logo = bas des labels */
  gap: 4px;
  min-width: 0;
  padding-bottom: 0;
}

/* [1] Burger (réglages — cf. cizi-menu.js). Historique : topbar-layout-v2. */
.topbar-burger {
  background: none;
  border: 0;
  cursor: pointer;
  color: #fff;
  padding: 4px 6px;
  margin: 0;
  display: inline-flex;
  align-items: center;
  align-self: center;
  line-height: 0;
  opacity: .9;
}
.topbar-burger:hover { opacity: 1; }

.topbar-logo {
  display: flex;
  align-items: center;
  height: 32px;
  flex-shrink: 0;
  transition: filter 0.2s, transform 0.2s;
}
.topbar-logo img {
  height: 100%;
  width: auto;
  display: block;
  flex-shrink: 0;
}
.topbar-logo:hover {
  filter: drop-shadow(0 0 6px rgba(240, 235, 220, 0.6));
  transform: scale(1.05);
}

/* Ancien séparateur <span>/</span> : retiré du flux (le "/" est désormais
   un ::before du label catégorie). Tout son style était mort. */
.topbar-sep { display: none; }

/* Bouton catégorie (label + icône). Le "/" est injecté en ::before. */
.topbar-cat {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 0 8px 0 0;
  border: none;
  border-radius: 8px;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  color: rgba(240, 235, 220, 1);
  font-family: var(--cizi-font-cartoon);
  font-weight: normal;
  font-size: 30px;
  letter-spacing: 0.02em;
  line-height: 1;
  cursor: pointer;
  text-shadow: var(--cizi-text-outline);
  transform: translateY(var(--cizi-cat-fine-tune));
  transition: background 0.2s;
}
.topbar-cat:hover   { background: rgba(0, 0, 0, 0.25); }
.topbar-cat.is-open { background: rgba(0, 0, 0, 0.35); }

.topbar-cat::before {
  content: '/';
  margin-right: 3px;
  font-family: var(--cizi-font-cartoon);
  font-weight: normal;
  font-size: 30px;
  color: rgba(240, 235, 220, 1);
  text-shadow: var(--cizi-text-outline);
}

.topbar-cat-label {
  font-family: var(--cizi-font-cartoon);
  font-size: 30px;
  color: rgba(240, 235, 220, 1);
  white-space: nowrap;
  overflow: visible;
  text-overflow: clip;
  text-shadow: var(--cizi-text-outline);
}

/* Icône de catégorie (homogène PHP/Vision). 32px = hauteur du logo Cizi,
   recentrée sur la ligne (la zone gauche est en flex-end). */
.topbar-cat-icon {
  height: 32px;
  width: auto;
  margin-left: 6px;
  display: inline-block;
  vertical-align: middle;
  align-self: center;
  position: relative;
  top: 2px;
  border-radius: 4px;
  flex-shrink: 0;
  filter: var(--cizi-img-outline);
}

/* Flèche ▾ retirée (display:none). Tout son style était mort. */
.topbar-cat-arrow { display: none; }

/* section-dropdown-marker — SECOND FIL D'ARIANE "/Section" (Accueil, Films,
   Séries) : le bouton réutilise .topbar-cat en entier ("/" en ::before,
   police cartoon, hover, is-open) et son dropdown réutilise .topbar-dropdown.
   Ce modificateur ne porte que les micro-ajustements propres au segment. */
.topbar-cat--section { margin-left: 2px; }

/* Boutons ronds loupe + plein écran. */
.topbar-search-btn,
.topbar-fullscreen {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  color: rgba(240, 235, 220, 1);
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.topbar-search-btn { margin-left: 18px; }
.topbar-search-btn:hover,
.topbar-fullscreen:hover {
  background: rgba(0, 0, 0, 0.25);
  color: rgba(255, 255, 255, 1);
}
.topbar-search-btn svg,
.topbar-fullscreen svg {
  width: 22px;
  height: 22px;
  filter: var(--cizi-img-outline);
}

/* topbar-layout-v3-marker — [4] loupe en FIN DE GROUPE GAUCHE : recentrée
   verticalement, resserrée (le 18px historique visait la zone droite),
   incompressible. */
.topbar-left .topbar-search-btn {
  margin-left: 8px;
  align-self: center;
  flex-shrink: 0;
}

/* Sous-label Vision (ex "/ Films") — rendu par le React, stylé ici. */
.topbar-sublabel {
  font-family: var(--cizi-font-cartoon);
  font-size: 24px;
  color: rgba(240, 235, 220, 1);
  letter-spacing: 0.06em;
  padding: 0 6px;
  line-height: 1;
  text-shadow: var(--cizi-text-outline);
}

/* ════════════════════════ ZONE CENTRE : HORLOGE ════════════════════════ */

/* Conteneur invisible occupant toute la barre : l'horloge est calée au
   STRICT centre de l'écran (topbar-layout-v2, conservé en v3 — le centre ne
   contient plus QUE l'horloge côté Vision). */
.topbar-center {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}
.topbar-clock {
  display: inline-block;
  pointer-events: auto;
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  font-family: monospace;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.1em;
  font-variant-numeric: tabular-nums;
  color: rgba(240, 235, 220, 1);
  text-shadow: var(--cizi-text-outline);
  transition: opacity 120ms ease;
}
.topbar-clock.is-hidden { visibility: hidden; opacity: 0; }

/* topbar-layout-v2 : bloc compat PHP SUPPRIMÉ le 20260711 (entete.php est passé au layout v3, loupe en zone gauche). */

/* ════════════════════════ ZONE DROITE ════════════════════════ */

.topbar-right {
  margin-left: auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  min-width: 0;
}
.topbar-modules {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 32px;
}

/* ════════════════════════ DROPDOWN CATÉGORIES ════════════════════════ */

.topbar-dropdown {
  position: fixed;
  top: 58px;
  left: 16px;
  z-index: 11;
  min-width: 320px;
  padding: 10px;
  background: rgba(20, 20, 20, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(240, 235, 220, 0.25);
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  display: flex;
  flex-direction: column;
  gap: 4px;
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition: opacity 0.15s, transform 0.15s;
}
.topbar-dropdown.is-open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.topbar-dropdown-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px 14px;
  color: rgba(240, 235, 220, 1);
  text-decoration: none;
  font-family: monospace;
  font-size: 13px;
  letter-spacing: 0.06em;
  border-radius: 10px;
  transition: background 0.15s, color 0.15s;
}
.topbar-dropdown-item:hover {
  background: rgba(240, 235, 220, 0.12);
  color: rgba(240, 235, 220, 1);
}
.topbar-dropdown-item:hover .topbar-dropdown-icon {
  filter: var(--cizi-img-outline) brightness(1.15);
}
/* Icône dropdown agrandie (64px), forcée à gauche (order:-1). */
.topbar-dropdown-icon {
  width: 64px;
  height: 64px;
  order: -1;
  object-fit: contain;
  flex-shrink: 0;
  border-radius: 10px;
  filter: var(--cizi-img-outline);
  transition: filter 0.15s;
}
.topbar-dropdown-label {
  flex: 1;
  font-family: var(--cizi-font-cartoon);
  font-size: 30px;
  letter-spacing: 0.02em;
  text-shadow: var(--cizi-text-outline);
}
/* Catégorie courante : encadrée (box-shadow inset = pas de shift), pas grisée. */
.topbar-dropdown-item.is-current {
  color: rgba(240, 235, 220, 1);
  pointer-events: none;
  background: rgba(240, 235, 220, 0.06);
  box-shadow: inset 0 0 0 2px rgba(240, 235, 220, 1);
}
.topbar-dropdown-item.is-current::before { content: none; }
.topbar-dropdown-item.is-current .topbar-dropdown-icon { opacity: 1; }

/* Sous-menu Vision (Films / Séries) dans le dropdown. */
.topbar-dropdown-vision-wrap { display: flex; flex-direction: column; gap: 2px; }
.topbar-dropdown-vision-row  { display: flex; align-items: center; gap: 4px; }
.topbar-dropdown-vision-row .topbar-dropdown-item--main { flex: 1; }
.topbar-dropdown-sub-toggle {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: none;
  border-radius: 6px;
  color: rgba(240, 235, 220, 0.6);
  font-size: 14px;
  cursor: pointer;
  transition: background 0.15s, transform 0.15s, color 0.15s;
}
.topbar-dropdown-sub-toggle:hover {
  background: rgba(240, 235, 220, 0.12);
  color: rgba(240, 235, 220, 1);
}
.topbar-dropdown-sub-toggle.is-open {
  transform: rotate(90deg);
  color: rgba(240, 235, 220, 1);
}
.topbar-dropdown-submenu {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-left: 16px;
  margin-left: 4px;
  border-left: 1px solid rgba(240, 235, 220, 0.15);
}
.topbar-dropdown-item--sub {
  font-size: 24px;
  opacity: 0.85;
  padding: 8px 12px;
}
.topbar-dropdown-item--sub:hover { opacity: 1; }

/* ════════════════════════ OVERLAY RECHERCHE ════════════════════════ */

.topbar-search-overlay {
  position: fixed;
  inset: 0;
  z-index: 12;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 80px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}
.topbar-search-overlay.is-open { opacity: 1; pointer-events: auto; }
.topbar-search-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.topbar-search-panel {
  position: relative;
  width: min(720px, 92vw);
  padding: 18px;
  background: rgba(20, 20, 20, 0.95);
  border: 1px solid rgba(240, 235, 220, 0.2);
  border-radius: 16px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5);
  transform: translateY(-8px);
  transition: transform 0.2s;
}
.topbar-search-overlay.is-open .topbar-search-panel { transform: translateY(0); }
.topbar-search-panel .search-wrap { margin: 0; padding: 0; }

/* topbar-layout-v3-marker — l'ancienne barre fixe .topbar-tabs (top:40px,
   ligne 2) et ses items .topbar-tab sont SUPPRIMÉS : topbar.tsx ne les rend
   plus, le dropdown de section réutilise .topbar-dropdown-item. */

/* ════════════════════════ MINI-LECTEUR AUDIO (topbar-right) ════════════════════════ */

/* --- Pastille piste (ancien format .cizi-mini-track) --- */
.cizi-mini-track {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  max-width: min(60vw, 480px);
  height: 32px;
  padding: 0 12px;
  border-radius: 16px;
  font-family: monospace;
  font-size: 13px;
  color: rgba(240, 235, 220, 0.85);
  text-decoration: none;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(240, 235, 220, 0.1);
  cursor: pointer;
  overflow: hidden;
  transition: background 150ms ease, border-color 150ms ease, color 150ms ease;
}
.cizi-mini-track[hidden] { display: none !important; }
.cizi-mini-track:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(240, 235, 220, 0.25);
  color: rgba(240, 235, 220, 1);
}
.cizi-mini-icon { display: inline-flex; align-items: center; flex-shrink: 0; opacity: 0.85; }
.cizi-mini-icon svg { width: 16px; height: 16px; }
.cizi-mini-title, .cizi-mini-artist {
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0;
}
.cizi-mini-title  { flex: 0 1 auto; font-weight: 600; }
.cizi-mini-artist { flex: 0 1 auto; opacity: 0.7; }
.cizi-mini-sep    { opacity: 0.4; flex-shrink: 0; }

/* --- Bouton-icône GIF (toggle BottomPlayer) --- */
.cizi-mini-toggle {
  width: 36px;
  height: 36px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 150ms ease, background 150ms ease;
}
.cizi-mini-toggle[hidden] { display: none !important; }
.cizi-mini-toggle:hover  { transform: scale(1.1); background: rgba(255, 255, 255, 0.08); }
.cizi-mini-toggle:active { transform: scale(0.95); }
.cizi-mini-toggle img { width: 28px; height: 28px; display: block; object-fit: contain; }

/* --- Barre 4 boutons + zone tray (.cizi-mini-bar) --- */
.cizi-mini-bar {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-right: 4px;
  transition: opacity 0.3s ease;
}
.cizi-mini-bar[hidden] { display: none !important; }

/* Zone tray (titre + play/pause) : visible seulement si trayMode actif (voir ÉTATS). */
.cizi-mini-bar .cizi-tray-zone {
  display: none;
  align-items: center;
  gap: 6px;
  margin-right: 8px;
}
/* Boutons play/pause et titre : visibles seulement en mode étendu. */
.cizi-mini-bar .cizi-mini-pp,
.cizi-mini-bar .cizi-mini-title { display: none; }
.cizi-mini-bar.is-extended .cizi-mini-pp    { display: inline-flex; }
.cizi-mini-bar.is-extended .cizi-mini-title { display: inline-block; }
.cizi-mini-bar .cizi-mini-pp {
  width: 32px;
  height: 32px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  align-items: center;
  justify-content: center;
  color: rgba(240, 235, 220, 0.85);
  cursor: pointer;
  transition: background 150ms ease, color 150ms ease, transform 150ms ease;
}
.cizi-mini-bar .cizi-mini-pp:hover  { background: rgba(255, 255, 255, 0.08); color: rgba(240, 235, 220, 1); transform: scale(1.05); }
.cizi-mini-bar .cizi-mini-pp:active { transform: scale(0.95); }
.cizi-mini-bar .cizi-mini-pp svg    { width: 18px; height: 18px; display: block; }
.cizi-mini-bar .cizi-mini-title {
  max-width: 200px;
  padding: 0 6px;
  font-family: monospace;
  font-size: 13px;
  color: rgba(240, 235, 220, 0.85);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  cursor: pointer;
  transition: color 150ms ease;
}
.cizi-mini-bar .cizi-mini-title:hover { color: rgba(240, 235, 220, 1); }

/* Les 4 boutons d'action (.cizi-act). */
.cizi-mini-bar .cizi-act {
  width: 32px;
  height: 32px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: rgba(240, 235, 220, 0.65);
  cursor: pointer;
  transition: background 0.18s ease, color 0.18s ease, transform 0.12s ease;
}
.cizi-mini-bar .cizi-act:hover         { background: rgba(255, 255, 255, 0.08); color: rgba(240, 235, 220, 1); transform: scale(1.05); }
.cizi-mini-bar .cizi-act:active        { transform: scale(0.95); }
.cizi-mini-bar .cizi-act svg           { width: 18px; height: 18px; display: block; }
.cizi-mini-bar .cizi-act.is-active     { color: rgba(240, 235, 220, 1); }
.cizi-mini-bar .cizi-act-cast.is-active{ color: #60a5fa; } /* bleu Cast */

/* ════════════════════════════════════════════════════════════════════
   ÉTATS / COMPORTEMENT — ne pas refactorer sans tester la checklist.
   ════════════════════════════════════════════════════════════════════ */

/* --- Vision/Sono montés en iframe : le body ne réserve plus la topbar,
       et le <main> PHP est masqué (l'iframe occupe l'écran). --- */
body[data-categorie="vision"],
body[data-categorie="sono"] {
  padding-top: 0 !important;
  overflow: hidden;
}
body[data-categorie="vision"] main,
body[data-categorie="sono"] main {
  display: none !important;
}

/* --- FS vidéo Vision : topbar masquée, padding body annulé. Les onglets
       (désormais DANS la topbar) suivent d'office. --- */
body[data-vision-fs="true"] .topbar {
  opacity: 0 !important;
  pointer-events: none !important;
  transition: opacity 300ms ease !important;
}
body[data-vision-fs="true"] { padding-top: 0 !important; }

/* --- FS musique Vision --- */
body[data-music-fs="true"] { padding-top: 0 !important; }
/* Topbar hissée au-dessus de l'overlay FS Vision (sinon la mini-bar visible
   resterait cachée derrière). */
body[data-music-fs="true"] .topbar { z-index: 100 !important; }
/* Mini-bar EXTRAITE du stacking topbar (position:fixed) pour rester visible
   et cliquable malgré .topbar opacity géré côté React. Décalée à gauche du
   bouton [  ] de Vision (right:72px).
   NB : NEUTRALISÉE par le bloc fs-sync-topbar plus bas (conservée en trace,
   cf. avertissement de tête de section). */
body[data-music-fs="true"] .cizi-mini-bar {
  position: fixed !important;
  top: 6px !important;
  right: 72px !important;
  z-index: 2147483641 !important;
  display: inline-flex !important;
  opacity: 1 !important;
  pointer-events: auto !important;
  transition: opacity 0.3s ease !important;
}
/* Auto-hide souple en FS musique : la mini-bar disparaît quand les contrôles
   sont masqués (timer 10s côté Vision), réveillable au mouvement. */
body[data-music-fs="true"][data-music-controls-hidden="true"] .cizi-mini-bar {
  opacity: 0 !important;
  pointer-events: none !important;
  transition: opacity 0.4s ease !important;
}

/* --- Auto-hide générique de la mini-bar (hors FS) --- */
body[data-music-controls-hidden="true"] .cizi-mini-bar {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
/* Zone tray affichée si trayMode signalé. */
body[data-tray-active="true"] .cizi-mini-bar .cizi-tray-zone { display: inline-flex; }

/* --- fs-hide-when-clock-marker — 20260705 ---
   La loupe ne s'efface en plein écran QUE si l'horloge y est réellement
   affichée (préférence data-cz-clock ≠ "off", posée sur <html> par
   cizi-menu.js ; "auto" = visible en FS, "always" = visible partout, donc
   dans les deux cas elle occupe le centre en FS → on dégage).
   Horloge sur "Masquée" : le centre est vide, la loupe RESTE.
   Le fil d'Ariane /Catégorie/Section n'est PAS concerné : il vit à gauche,
   comme la catégorie qui n'a jamais été masquée en FS.
   Remplace les masquages FS inconditionnels historiques
   (#topbar-search-btn / #topbar-tabs / patch fs-search-class-fix), tous
   SUPPRIMÉS de ce fichier.
   Filet : attribut absent (script pas encore chargé) ⇒ :not() matche ⇒
   comportement historique (masqué) le temps d'un instant, sans flash gênant. */
html:not([data-cz-clock="off"]) body[data-music-fs="true"]  .topbar-search-btn,
html:not([data-cz-clock="off"]) body[data-vision-fs="true"] .topbar-search-btn,
html:fullscreen:not([data-cz-clock="off"]) .topbar-search-btn {
  display: none !important;
}

/* --- Horloge : visible uniquement en plein écran sur PC (sinon .is-hidden
       gère la visibilité). Taille + contour renforcés en FS. --- */
@media (min-width: 721px) {
  :fullscreen .topbar-clock,
  :-webkit-full-screen .topbar-clock {
    display: block !important;
    font-size: 36px !important;
    background: transparent;
    padding: 0;
    text-shadow:
      -2px -2px 0 #000,  2px -2px 0 #000,
      -2px  2px 0 #000,  2px  2px 0 #000,
      0 0 8px rgba(0, 0, 0, 0.8);
  }
}

/* ════════════════════════ RESPONSIVE MOBILE (≤720px) ════════════════════════ */

@media (max-width: 720px) {
  .topbar { padding: 0 16px 0 10px; gap: 6px; }
  .topbar-left { gap: 3px; min-width: 0; padding-bottom: 0; }
  .topbar-logo { height: 32px; }

  .topbar-cat { font-size: 22px; padding-right: 6px; }
  .topbar-cat::before { font-size: 22px; }
  .topbar-cat-label {
    font-size: 22px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 50vw;
  }
  /* Catégorie = icône seule sur mobile : on masque le label SI une icône est
     présente (sinon on garderait un "/" tout seul, ex. Accueil). */
  .topbar-cat:has(.topbar-cat-icon) .topbar-cat-label { display: none !important; }
  .topbar-cat-icon { height: 32px; }

  /* section-dropdown-marker — le segment /Section suit la catégorie mobile
     (22px via .topbar-cat) ; son label s'ellipse plus court, et il garde son
     TEXTE même en mode data-cz-cat=logo (pas d'icône ⇒ filet :has inopérant). */
  .topbar-cat--section .topbar-cat-label { max-width: 26vw; }
  .topbar-left .topbar-search-btn { margin-left: 2px; }

  .topbar-sublabel {
    font-size: 18px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 80px;
  }

  .topbar-search-btn { margin-left: 0; }
  .topbar-clock { font-size: 15px; }

  .topbar-dropdown { min-width: 240px; }
  .topbar-dropdown-label { font-size: 22px; }
  .topbar-dropdown-item--sub { font-size: 18px; }

  .cizi-mini-track { max-width: 55vw; padding: 0 10px; }
  .cizi-mini-artist, .cizi-mini-sep { display: none; }
  .cizi-mini-bar.is-extended .cizi-mini-title { display: none; }
}

@media (max-width: 480px) {
  /* Très petit écran : on cache la zone modules pour respirer. */
  .topbar-modules { display: none; }
}

/* unified-shell-marker — 20260703
   TRANCHÉ : sur les pages Vision/Sono, le shell NE DESSINE PLUS sa topbar.
   La topbar React de Vision (iframe full-window) est la SEULE interface :
   plus de doublons, plus d'interception de clics, plus de hacks pointer-events.
   Inerte côté Vision (son body n'a jamais data-categorie).
   (.topbar-tabs : sélecteur défensif conservé pour le shell PHP.) */
body[data-categorie="vision"] .topbar,
body[data-categorie="sono"] .topbar,
body[data-categorie="vision"] .topbar-tabs,
body[data-categorie="sono"] .topbar-tabs,
body[data-categorie="vision"] #topbar-dropdown,
body[data-categorie="sono"] #topbar-dropdown,
body[data-categorie="vision"] #topbar-search-overlay,
body[data-categorie="sono"] #topbar-search-overlay {
  display: none !important;
}

/* fs-sync-topbar-marker — 20260704
   FS musique : TOUTE la topbar suit la visibilité des commandes du lecteur
   (attribut data-music-controls-hidden posé par music-player.tsx, timer
   d'inactivité côté Vision, réveil au mouvement). L'extraction fixe de la
   mini-bar (règle historique de la section ÉTATS, top:6px/right:72px) est
   neutralisée : c'est elle qui superposait cast et zoom ; la mini-bar reste
   désormais à sa place dans la barre, qui apparaît/disparaît d'un seul bloc. */
body[data-music-fs="true"] .cizi-mini-bar {
  position: static !important;
  top: auto !important;
  right: auto !important;
  z-index: auto !important;
}
body[data-music-fs="true"] .topbar { transition: opacity .3s ease; }
body[data-music-fs="true"][data-music-controls-hidden="true"] .topbar {
  opacity: 0 !important;
  pointer-events: none !important;
}

/* video-hide-topbar-marker — 20260704 : vidéo en plein cadre → topbar Cizi
   masquée en permanence (le lecteur vidéo a sa propre barre intégrée).
   Classe posée par topbar.tsx selon le store media-player. Les onglets étant
   dans la topbar depuis le layout v3, le sélecteur .topbar-tabs a giclé. */
.topbar.cz-video-hide {
  display: none !important;
}

/* ════════════════════════════════════════════════════════════════════
   CHECKLIST DE NON-RÉGRESSION (à re-vérifier après déploiement) :
   1. PC large : [burger][logo][/Catégorie][/Section ▾][🔍] à gauche,
      ⛶ collé au bord droit, PLUS de ligne 2 sous la barre.
   2. Mobile : icône catégorie seule (label masqué), segment /Section en 22px
      ellipsé court, pas de "/" orphelin sur Accueil.
   3. Dropdowns : catégories (icône 64px, courante encadrée) ET section
      (Accueil/Films/Séries texte, courante encadrée), alignés sous leur
      bouton, un seul ouvert à la fois.
   4. Section (Vision browse only, PAS sur /sono ni settings/login) :
      libellé courant sur le bouton, PLUS de Sono dans les choix.
   5. FS vidéo (data-vision-fs) : topbar entière disparaît.
   6. FS musique (data-music-fs) : barre entière suit l'auto-hide 10s
      (fs-sync), horloge FS visible/grosse sur PC si pref auto/toujours.
   7. fs-hide-when-clock : horloge "Masquée" → la loupe RESTE en FS ;
      horloge "Auto" ou "Toujours" → elle s'efface en FS (centre occupé).
      Le fil d'Ariane, lui, reste dans tous les cas.
   8. Pages PHP : loupe toujours au centre (compat v2) tant qu'entete.php
      n'est pas passé au layout v3 — cliquable, recentrée si horloge masquée.
   ════════════════════════════════════════════════════════════════════ */

/* dropdown-above-content-marker — 20260705 : les dropdowns de la barre
   (catégories ET section) passaient SOUS le contenu de page (héros du hub,
   titres avec bouton play…) : leur z-index 11 historique datait d'avant la
   surenchère de stacking de Vision. Hissés juste au-dessus de la topbar
   (2147483640), comme le panneau du burger (INT_MAX). L'overlay recherche
   suit, même famille de calques. */
.topbar-dropdown { z-index: 2147483641; }
.topbar-search-overlay { z-index: 2147483641; }

/* topbar-align-tune-marker — 20260705 : resserrage + alignement du groupe
   gauche. · Burger épaissi façon cartoon (stroke CSS > attribut SVG) avec le
   contour noir du logo. · La zone gauche passe de flex-end (bas du logo = bas
   des labels, obsolète) à un CENTRAGE vertical de tous les segments ; le
   rattrapage optique du texte reste --cizi-cat-fine-tune dans :root.
   · Espaces internes du fil d'Ariane purgés : marges du "/" (::before) et de
   l'icône supprimées, le gap flex (6px) suffit ; padding du bouton resserré.
   S'applique aussi aux pages PHP (mêmes classes). */
.topbar-burger {
  color: rgba(240, 235, 220, 1);
  opacity: 1;
  padding: 4px;
}
.topbar-burger svg {
  width: 26px;
  height: 26px;
  stroke-width: 3.6;
  filter: var(--cizi-img-outline);
}
.topbar-left { align-items: center; gap: 3px; }
.topbar-cat { padding: 0 6px 0 2px; margin-left: -2px; }
.topbar-cat::before { margin-right: 0; }
.topbar-cat-icon { top: 0; margin-left: 0; }
.topbar-cat--section { margin-left: -2px; }
