body {
  margin: 0;
  padding: 0;
  background-color: #f4f4f4;
  font-family: sans-serif;
  scroll-behavior: smooth;
}
.book-container {
  max-width: 90%;
  margin: 60px auto;
  padding: 20px;
}
.book-page {
  margin-bottom: 30px;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  padding:0px 300px 0px 300px;
}
.book-page img {
  width: 100%;
  display: block;
  height: auto;
  
}


.book-page {
  overflow: hidden;
}

.book-page img {
  transition: transform 0.4s ease;
  cursor: zoom-in;
}

@media (hover: hover) {
  .book-page img:hover {
    transform: scale(1.08);
  }
}

@media (max-width: 768px) {
  .book-container {
    max-width: 100%;
    padding: 10px;
  }

  .book-page {
    margin-bottom: 20px;
    border-radius: 8px;
  }

  .page-caption {
    font-size: 13px;
    padding: 8px;
  }

  .nav-arrow {
    padding: 10px 14px;
    font-size: 18px;
  }
}

.image-modal img {
  max-width: 100%;
  max-height: 100%;
  touch-action: none;   /* 🔥 important */
  transition: transform 0.1s ease;
  transform-origin: center center;
}


.image-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.9);
  z-index: 99999;
  justify-content: center;
  align-items: center;
}

.image-modal img {
  max-width: 95%;
  max-height: 95%;
  box-shadow: 0 0 20px rgba(255,255,255,0.3);
}

.image-close {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 32px;
  color: #fff;
  cursor: pointer;
}



.page-caption {
  text-align: center;
  font-size: 14px;
  color: #555;
  padding: 10px;
  background-color: #f9f9f9;
  border-top: 1px solid #ddd;
}
.nav-arrow {
  position: fixed;
  left: 20px;
  z-index: 1000;
  background: #333;
  color: #fff;
  padding: 12px 16px;
  border-radius: 50%;
  font-size: 20px;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}
.nav-arrow:hover {
  background: #000;
}
.nav-arrow.up {
  top: 20px;
}
.nav-arrow.down {
  bottom: 20px;
}
.page-indicator {
  position: fixed;
  top: 20px;
  right: 60px;
  background: #333;
  color: #fff;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 14px;
  z-index: 1000;
  opacity: 0.85;
}
.scroll-top {
  position: fixed;
  bottom: 80px;
  right: 20px;
  padding: 10px 16px;
  font-size: 16px;
  background: #444;
  color: white;
  border: none;
  border-radius: 50px;
  cursor: pointer;
  z-index: 1000;
  display: none;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}
.scroll-top:hover {
  background: #000;
}
.pagination-controls {
  text-align: center;
  margin: 30px auto;
}
.pagination-controls button {
  margin: 5px;
  padding: 8px 14px;
  background: #eee;
  border: 1px solid #ccc;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
}
.pagination-controls button.active {
  background: #333;
  color: #fff;
  font-weight: bold;
}
.pagination-controls button:disabled {
  background: #ccc;
  cursor: not-allowed;
  
  
}


.video-modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0; top: 0;
  width: 100%; height: 100%;
  background-color: rgba(0,0,0,0.8);
  justify-content: center;
  align-items: center;
}

.video-content {
  position: relative;
  width: 80%;
  max-width: 800px;
  background: #000;
}

.video-content iframe {
  width: 100%;
  height: 450px;
}

#closeModal {
  position: absolute;
  top: 5px; right: 10px;
  color: white;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
}


.video-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.9);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  flex-direction: column;
}

#videoIframe,
#videoTag {
  width: 80%;
  height: 80%;
  max-width: 960px;
  max-height: 540px;
  background: #000;
}

.close-btn {
  color: white;
  font-size: 28px;
  position: absolute;
  top: 20px;
  right: 30px;
  cursor: pointer;
  z-index: 10000;
}


.video-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.85);
  justify-content: center;
  align-items: center;
  z-index: 9999;
  flex-direction: column;
}

.video-modal iframe,
.video-modal video {
  width: 80%;
  max-width: 960px;
  height: 480px;
  background: #000;
  border: none;
}

.close-btn {
  color: white;
  font-size: 30px;
  font-weight: bold;
  position: absolute;
  top: 20px;
  right: 30px;
  cursor: pointer;
  z-index: 10000;
}

@media (max-width: 768px) {
  .book-page {
    padding: 0 !important;
    margin-bottom: 20px;
    border-radius: 0;
  }
}


