#currentTime{
    font-family: "Montserrat", sans-serif;
}

.player-container button{
    font-family: "Montserrat", sans-serif;
}

#chap {
  position: fixed;
  left: 0;
  top: 0;
  width: 300px;
  height: 100%;
  background-color: #f5f5f5;
  color: black;
  box-shadow: -2px 0 5px rgba(0,0,0,0.5);
  z-index: 1003;
  transform: translateX(-100%);
  transition: transform 0.3s ease-in-out;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

#chap.open {
  transform: translateX(0);
}

#chap h2 {
  margin-top: 0;
  padding: 16px;
}

#chapClose {
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  position: absolute;
  top: 10px;
  right: 10px;
}

#chapOverlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1000;
  display: none;
}


#navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: #333;
  color: white;
  display: flex;
  justify-content: space-between;
  padding: 10px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
  transition: top 0.3s;
  z-index: 1002;
}

#navbar.hidden {
  top: -60px; /* Adjust based on navbar height */
}

#brand {
    flex: 1;
    display: flex;
    align-items: center;
    min-width: 0; /* Important for truncation to work properly */
}

#brand-logo {
  height: 24px;
  margin-right: 10px;
}

#brand-name {
    font-size: 18px;
    font-weight: bold;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%; /* Ensures it doesn't exceed the available space */
}

#nav-items {
    display: flex;
    align-items: center;
    margin-left: auto; /* Pushes nav items to the right */
}

.nav-item {
  cursor: pointer;
  padding: 0 10px;
  color: #f5f5f5;
}

.nav-item:hover {
  color: #ddd;
}

body {
    font-family: Arial, sans-serif;
    background-color: #f4f4f4;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    margin: 0;
}

.player-container {
    width: 300px;
    background: #fff;
    padding: 20px;
    box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    text-align: center;
}
@media (prefers-color-scheme: dark) {
  body {
    background-color: #3C3D37 !important; /* Dark mode background */
  }
}

#cover {
    width: 100%;
    border-radius: 10px;
    margin-bottom: 20px;
}

.controls {
    display: flex;
    justify-content: space-around;
    margin-bottom: 10px;
}

button:not(.sample-ctrls) {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
}

.seekbar {
    width: 100%;
    margin-top: 10px;
}

#seekSlider {
    width: 100%;
}

#end-of-sample-popup {
    z-index: 9999;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    text-align: center;
    padding: 20px;
    display: none;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
}

#end-of-sample-popup.visible {
    display: block;
    opacity: 1;
}

p, button {
    font-family: "Montserrat", sans-serif;
}

#end-of-sample-popup button {
    margin: 10px;
    padding: 10px 20px;
    background: #007bff;
    color: white;
    border: none;
    cursor: pointer;
    border-radius: 5px;
}

#end-of-sample-popup button:hover {
    background: #0056b3;
}

#popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9998;
    display: none; /* Initially hidden */
}

#end-of-sample-popup button#close-popup {
    position: absolute;
    top: 10px;
    right: 10px;
    background: transparent;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
}
