/* --- ACHTERGROND --- */
body, html {
  margin: 0;
  padding: 0;
  height: 100vh;
  font-family: "Montserrat", sans-serif;
  overflow-x: hidden;
}

.bg-fixed {
  position: fixed;
  top: 0;
  left: 30rem;
  width: 100vw;
  height: 100vh;
  z-index: -2;
  /* Achtergrondpositie op 90% houdt de toren rechts */
  background: url("afbeelding/vuurtoren2.webp") no-repeat 90% center; 
  background-size: cover;
  filter: blur(2px);
  transform: scale(1.1);
}

.bg-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  background: linear-gradient(
    to right, 
    rgb(216, 235, 244) 0%, 
    rgb(216, 235, 244) 40%, 
    rgba(216, 235, 244, 0.4) 100%
  );
}

/* --- LAYOUT POSITIONERING --- */
.wrapper {
  display: flex;
  align-items: center;
  min-height: 100vh;
  /* Gebruik van vw voor de exacte 'Foto 2' positie */
  padding-left: 28vw; 
  padding-right: 20vw;
  box-sizing: border-box;
}

.container {
  max-width: 600px; /* Max-width in px is veiliger voor leesbaarheid van tekst */
  width: 100%;
  text-align: left;
}

/* --- TYPOGRAFIE --- */
h1 {
  color: #003366;
  font-size: 3em; /* Schaalt mee met de hoogte van het scherm */
  margin: 0;
  font-weight: 400;
}

.separator {
  display: flex;
  align-items: center;
  color: #003366;
  margin: 1vh 0 4vh 0;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 2px;
}

/* Lijn aan de linkerkant */
.separator::before {
  content: "";
  flex: 1;
  border-bottom: 1px solid rgba(0, 51, 102, 0.2);
  margin-right: 2vw;
}

.separator::after {
  content: "";
  flex: 1;
  border-bottom: 1px solid rgba(0, 51, 102, 0.2);
  margin-left: 2vw;
}

/* --- TITELS VOOR AUDIO FRAGMENTEN --- */
.audio-title {
  color: #003366;
  font-size: 1.1rem;
  margin-bottom: -20px; /* Trekt de titel dichter naar de player */
  font-weight: 600;
}

.profile-img {
  width: 5vw; /* Schaalt mee met breedte */
  min-width: 150px; /* Voorkomt dat hij te klein wordt op kleine laptops */
  height: auto;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 3vh;
  border: 4px solid #003366;
}

p {
  line-height: 1.8;
  font-size: 1.1rem;
  color: #003366;
  margin-bottom: 2vh;
}

/* --- AUDIO PLAYER (STYLING ONGEWIJZIGD) --- */
.custom-audio-player {
  display: flex;
  align-items: center;
  background-color: #f1f5f8;
  border: 1px solid #d1d9e0;
  border-radius: 10px;
  padding: 10px 20px;
  margin: 30px 0;
  max-width: 550px;
  gap: 15px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.player-btn {
  background: none;
  border: none;
  color: #555;
  font-size: 18px;
  cursor: pointer;
  width: 30px;
  display: flex;
  justify-content: center;
}

.time-text {
  font-size: 12px;
  color: #666;
  min-width: 40px;
}

.slider {
  -webkit-appearance: none;
  appearance: none;
  height: 5px;
  border-radius: 3px;
  background: #ccc;
  outline: none;
}

.slider.progress {
  flex-grow: 1; 
}

.slider.volume { width: 80px; }

.volume-controls {
  display: flex;
  align-items: center; /* Zorgt voor verticale uitlijning van icoon en slider */
  justify-content: center;
  gap: 8px;
  flex-shrink: 0; /* Voorkomt dat deze sectie te veel in elkaar drukt */
  height: 100%;   /* Neemt de volledige hoogte van de player balk */
}

.slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 14px;
  height: 14px;
  background: #fff;
  border: 2px solid #003366;
  border-radius: 50%;
}

.muteBtn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  transition: opacity 0.2s;
}

.muteBtn:hover {
  opacity: 0.7;
}

/* --- KNOP --- */
.download-btn {
  display: inline-block;
  padding: 1.5vh 3vw;
  background-color: #003366;
  color: white;
  text-decoration: none;
  border-radius: 6px;
  font-weight: 700;
  transition: background 0.3s;
}

.download-btn:hover {
  background-color: #002244;
}

/* --- MOBIEL --- */
@media (max-width: 768px) {

  h1 {
    font-size: clamp(1.8rem, 10vw, 2.5rem); /* Iets agressiever schalen op mobiel */
    padding: 0 10px; /* Geeft de letters wat ademruimte bij de randen */
  }

  .bg-fixed {
    left: 0; /* CRUCIAAL: Reset de verschuiving op mobiel */
    width: 100vw;
    background-position: center center; /* Vuurtoren centraal voor mobiel */
    opacity: 0.4; /* Maakt achtergrond rustiger achter tekst */
  }

  .bg-overlay {
    background: rgba(215, 235, 245, 0.85);
  }

  .wrapper {
    padding: 5vh 5vw;
    justify-content: center;
    padding-left: 5vw; /* Reset de 28vw padding voor mobiel */
  }

  .container {
    text-align: center;
    margin-left: 0;
    max-width: 100%;
  }

  .separator::before {
    content: "";
    flex: 1;
    border-bottom: 1px solid rgba(0, 51, 102, 0.2);
    margin-right: 2vw;
  }

  .profile-img {
    margin: 0 auto 3vh auto;
  }

  .custom-audio-player {
    max-width: 100vw;
  }

  .volume-controls {
    display: none;
  }

  .download-btn {
    display: block; /* Knop neemt volledige breedte van container in op mobiel */
    width: 90%;    /* Iets smaller dan het scherm voor ademruimte */
    margin: 20px auto;
    padding: 15px 20px; /* Vaste padding op mobiel voor betere klikbaarheid */
    font-size: 1.1rem;
  }
}