/* Reset + base styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
body {
  font-family: "Montserrat", sans-serif;
  background-color: #f5f5f5;
  color: #222;
  transition: background-color 0.3s, color 0.3s;
}
a {
  text-decoration: none;
  color: inherit;
}
h1 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  margin-top: 1rem;
  font-weight: 600;
}
h2 {
  margin-bottom: 0.7rem;
  font-size: 1.3rem;
  font-weight: 600;
}

p {
  margin-top: 0.7rem;
  margin-bottom: 0.7rem;
}

/* Header */
.app-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0rem 1.2rem;
  background-color: #008080;
  color: white;
}
.logo-title {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* Toggle switch */
.switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 26px;
}
.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}
.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: 0.4s;
  border-radius: 26px;
}
.slider:before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  left: 4px;
  bottom: 3px;
  background-color: white;
  transition: 0.4s;
  border-radius: 50%;
}
input:checked + .slider {
  background-color: #00cfff;
}
input:checked + .slider:before {
  transform: translateX(24px);
}

/* Layout */
.main-content {
  padding: 1rem;
}
.reading-nav {
  display: flex;
  justify-content: space-between;
}
.nav-btn,
.calendar-btn {
  background-color: #008080;
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  transition: background-color 0.3s;
}
.nav-btn:hover,
.calendar-btn:hover {
  background-color: #006666;
  color: white;
}

#floatingButton {
  box-shadow: 0px 4px 5px rgba(0, 0, 0, 0.2);
}

.reading-section {
  margin-top: 0.7rem;
  padding: 1rem;
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  transition: background-color 0.3s;
}

.audio-section {
  margin-top: 1rem;
  padding: 1rem;
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  transition: background-color 0.3s;
}

/* Dark Mode */
body.dark-mode {
  background-color: #1e1e1e;
  color: #f5f5f5;
}
body.dark-mode .app-header {
  background-color: #121212;
}
body.dark-mode .reading-section,
body.dark-mode .audio-section {
  background-color: #2a2a2a;
}
body.dark-mode .nav-btn,
body.dark-mode .calendar-btn {
  background-color: #333;
}
body.dark-mode .nav-btn:hover,
body.dark-mode .calendar-btn:hover {
  background-color: #444;
}
body.dark-mode .modal-content {
  background-color: #2a2a2a;
}

body.dark-mode .calendar-nav {
  color: #f5f5f5;
}
body.dark-mode .track-item:hover {
  background: #f0f0f0;
  color: #222;
}
body.dark-mode .tt-menu {
  color: #222;
}




<!-- new .main-layout {
  display: flex;
  height: 100vh;
}
.reading-panel {
  padding: 20px;
  overflow-y: scroll;
  background: white;
  height: 75vh;
}
.audio-panel {
  padding: 20px;
  background: #ffffff;
  /* border-left: 1px solid #ddd; */
  height: 75vh;
}

.chapter-text {
  font-size: 1rem;
  line-height: 1.5rem;
  display: inline-flexbox;
}
.logo {
  width: 60px;
  height: 50px;
  border-radius: 50%;
}
.logo-container {
  height: 70px;
  width: 70px;
  background-color: #ffffff;
  border-radius: 60px;
  margin: auto;
}
.logo2 {
  width: 150px;
  height: 150px;
}
.image-container {
  background-color: #f0f0f0;
  border-radius: 40px;
  border: #006666 solid 2px;
  margin: 5px auto;
  width: fit-content;
}
.chapter-title {
  font-size: 1rem;
  font-weight: 900;
  margin-bottom: 0.5rem;
  margin-top: 0.5rem;
}

@media screen and (max-width: 450px) {
  .reading-panel {
    height: 50vh;
  }
  .audio-panel {
    height: fit-content;
    padding: 0px;
  }
  h1 {
    font-size: 1.3rem;
  }
  .nav-btn,
  .calendar-btn {
    padding: 0.2rem 0.5rem;
    font-size: 0.9rem;
  }
  .image-container {
    display: none;
  }
  .modal-content{
    width: 80%;
    margin: auto;
  }
  .audio-section {
    margin-top: 1rem;
    padding: 0rem;
  }
}

.reading-progress-container {
  position: sticky;
  top: 0;
  width: 100%;
  height: 3px;
  background: #ddd;
  z-index: 10;
  margin-top: 0.5rem;
  border-radius: 1px;
}

.reading-progress-bar {
  height: 3px;
  width: 0;
  background: #02a1a1;
  transition: width 0.25s;
  border-radius: 1px;
}

.calendar-modal-content {
  border-radius: 20px;
  box-shadow: 0px 4px 20px rgba(0, 0, 0, 0.1);
  background-color: #ffffff;
}

.calendar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.calendar-nav {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 5px;
}

.calendar-day-name {
  font-weight: bold;
  text-align: center;
  font-size: 0.9rem;
}

.calendar-day {
  text-align: center;
  padding: 10px;
  border-radius: 10px;
  cursor: pointer;
  transition: background-color 0.3s;
  font-size: 1rem;
}

.calendar-day:hover {
  background-color: #006666;
  color: white;
}

.calendar-day.empty {
  visibility: hidden;
}

.progress-bar {
  width: 100%;
  height: 8px;
  appearance: none;
  background: #ddd;
  border-radius: 5px;
  overflow: hidden;
  transition: background 0.3s ease;
}

.progress-bar::-webkit-slider-thumb {
  appearance: none;
  width: 16px;
  height: 16px;
  background: #02a1a1;
  border-radius: 50%;
  cursor: pointer;
  transition: background 0.3s ease;
  margin-top: -4px; /* Center thumb */
}

.progress-bar::-moz-range-thumb {
  width: 16px;
  height: 16px;
  background: #02a1a1;
  border-radius: 50%;
  cursor: pointer;
}
footer {
  text-align: center;
  padding: 0.7rem;
  background-color: #008080;
  color: white;
  position: relative;
}

/* Audio Player Styles 🎧 */
.player-ui {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  background: #f9f9f9;
  border-radius: 1rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.track-title {
  font-size: 1.2rem;
  color: #02a1a1;
  font-weight: 550;
  margin-bottom: 0%;
}

.spinner {
  width: 30px;
  height: 30px;
  border: 4px solid #ddd;
  border-top: 4px solid #02a1a1;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.progress-container {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
}

.time-label {
  font-size: 0.9rem;
  color: #555;
  width: 40px;
  text-align: center;
}

.progress-bar {
  flex-grow: 1;
  appearance: none;
  height: 6px;
  border-radius: 5px;
  background: #ddd;
  outline: none;
  cursor: pointer;
}

.progress-bar::-webkit-slider-thumb {
  appearance: none;
  width: 14px;
  height: 14px;
  background: #02a1a1;
  border-radius: 50%;
  cursor: pointer;
}

.custom-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.control-btn {
  background: #02a1a1;
  color: #fff;
  border: none;
  padding: 0.3rem; /* Increase padding slightly */
  font-size: 0.7rem;
  border-radius: 50%;
  cursor: pointer;
  transition: background 0.3s;
  display: flex;
  justify-content: center; /* Center horizontally */
  align-items: center; /* Center vertically */
  width: 30px; /* Set a fixed width and height */
  height: 30px; /* Set a fixed height */
}

/* If you want the icon to fill the button without clipping */
.control-btn i {
  font-size: 0.7rem; /* Adjust icon size */
}

.control-btn:hover {
  background: #028888;
}

.playlist-ui {
  margin-top: 1rem;
  width: 100%;
}

.track-item {
  padding: 0.5rem;
  border-bottom: 1px solid #eee;
  cursor: pointer;
  transition: background 0.3s;
}

.track-item:hover {
  background: #f0f0f0;
  color: #02a1a1;
}

.active-track {
  background: #02a1a1;
  color: white;
  font-weight: bold;
}

.form-control{
  box-shadow: none !important;
}
.form-control:focus{
  box-shadow: none !important;
  border-color: #02a1a1 !important;
}

label{
  font-weight: 500;
  margin-bottom: 0% !important;
}


.tt-menu {
  background-color: #fff;
  border: 1px solid #ddd;
  border-radius: 4px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  max-height: 200px;
  overflow-y: auto;
  z-index: 1000;
}

.tt-suggestion {
  padding: 10px;
  cursor: pointer;
}

.tt-suggestion:hover {
  background-color: #f8f9fa;
}

.tt-suggestion.tt-cursor {
  background-color: #02a1a1;
  color: #fff;
}

/* scroll bar */
/* ───────── Custom Scroll‑bar (WebKit – Chrome / Edge / Safari) ───────── */
.playlist,
.reading-panel,
body {                 /*  add any other scrollable area selectors */
  /* Firefox first – one line covers all descendants */
  scrollbar-width: thin;                            /* “auto” or “thin” */
  scrollbar-color: #02a1a1 #f0f4f8;                 /* thumb track       */
}
body.dark-mode .playlist,
body.dark-mode .reading-panel,
body.dark-mode {
  scrollbar-color: #02a1a1 #222;                    /* dark‑mode track   */
}

/* Chrome / Edge / Safari */
.playlist::-webkit-scrollbar,
.reading-panel::-webkit-scrollbar {
  width: 8px;
}
.playlist::-webkit-scrollbar-track,
.reading-panel::-webkit-scrollbar-track {
  background: #f0f4f8;
  border-radius: 4px;
}
body.dark-mode .playlist::-webkit-scrollbar-track,
body.dark-mode .reading-panel::-webkit-scrollbar-track {
  background: #222;
}
.playlist::-webkit-scrollbar-thumb,
.reading-panel::-webkit-scrollbar-thumb {
  background: #02a1a1;
  border-radius: 4px;
  transition: background 0.2s;
}
.playlist::-webkit-scrollbar-thumb:hover,
.reading-panel::-webkit-scrollbar-thumb:hover {
  background: #028b8b;
}
