/* ---------- GLOBAL ---------- */

body {
  margin: 0;
  font-family: sans-serif;
  background: #f9f9f9;
  overflow: hidden; /* empêche le scroll global */
}



/* en dessous de  550px de large 
---------- PARTIE HAUTE : IMAGES FIXES ---------- */

.header-fixed {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 40vh;
  z-index: 10;
  background: #fff;
  /* overflow: hidden; */ /* supprimer cette ligne */
  overflow-y: auto;       /* ajouter cette ligne */
}

.header-images {
  margin: 0;
  padding: 0;
}


.header-images img {
  width: 100%;
  height: auto;
  display: block;
  max-width: 100%;
  object-fit: contain;
}


/* ---------- PARTIE BASSE : LECTEURS DÉFILABLES ---------- */

.audio-zone {
  position: absolute;
  top: 40vh;
  left: 0;
  height: 50vh;
  width: 100vw;
  overflow-y: auto;
  padding: 20px;
  box-sizing: border-box;
}

.content {
  max-width: 1000px;
  margin: 0 auto;
  box-sizing: border-box;
}

/* ---------- LECTEURS ---------- */

.player {
  background: #fff;
  border: 1px solid #ccc;
  padding: 1em;
  margin-bottom: 2em;
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  width: 100%;
}

audio {
  width: 97%;
  height: 50px;
  display: block;
  margin-bottom: 8px;
}

audio::-webkit-media-controls-panel {
  height: 50px;
  transform: scale(1.4);
  transform-origin: left center;
}

/* ---------- BOUTONS ---------- */

.controls button {
  font-size: 1.1em;
  padding: 10px 16px;
  min-width: 100px;
  border-radius: 6px;
  border: 1px solid #888;
  background-color: #f0f0f0;
  cursor: pointer;
  transition: background-color 0.2s;
  margin-right: 0.5em;
  margin-top: 5px;
}

.controls button:hover {
  background-color: #e0e0e0;
}

.loop-button.active {
    background-color: #c5f7c5; /* vert clair */
    border-color: #68c468;
    color: #000;
}


/* ---------- BARRE DE PROGRESSION ---------- */

.progress-bar {
  position: relative;
  height: 8px;
  background: #eee;
  margin: 10px 0;
  cursor: pointer;
  border-radius: 4px;
}

.progress {
  height: 100%;
  background: #3b82f6;
  width: 0%;
  border-radius: 4px;
}

.ab-marker {
  position: absolute;
  top: -4px;
  width: 2px;
  height: 16px;
  background: red;
}

.ab-marker.a {
  background: green;
}

.ab-marker.b {
  background: red;
}

/* ---------- INFOS TEMPS ET VITESSE ---------- */

.info-line {
  font-size: 0.9em;
  color: #333;
  display: flex;
  justify-content: space-between;
}

.speed-val {
  position: relative;
  top: -2px;
}
.rangeVitesse {
  display: block;
  width: 95%;
  box-sizing: border-box;
}
.labVitesse {
	margin-top : 5px;
}
/* ---------- LAYOUT RESPONSIVE ---------- */

.layout {
  display: flex;
  flex-direction: column;
  height: 100dvh;
}

@media (min-width: 550px) {
  .layout {
    flex-direction: row;
  }

  .header-fixed {
    position: relative; /* enlever fixed pour l'affichage colonne */
    top: 0;
    width: 50vw;
    height: 100vh;
    z-index: 1;
    /* overflow: hidden; */ /* supprimer cette ligne */
    overflow-y: auto;       /* ajouter cette ligne */
  }

  .audio-zone {
    position: relative;
    top: 0;
    width: 50vw;
    height: 100vh;
    overflow-y: auto;
    padding: 20px;
  }
}