html {
  overflow-y: scroll;
}

/* Hide scrollbar for Chrome, Safari and Opera */
html::-webkit-scrollbar {
  display: none;
}

/* Hide scrollbar for IE, Edge and Firefox */
html {
  -ms-overflow-style: none; /* IE and Edge */
  scrollbar-width: none; /* Firefox */
}

body {
  font-family: "Georgia", serif;
  background-color: #f8e6b0;
  color: #3a2e1f;
  margin: 0;
  padding: 0;
  text-align: center;
  position: relative;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  background-image: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTI4IiBoZWlnaHQ9IjEyOCIgdmlld0JveD0iMCAwIDEyOCAxMjgiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGZpbHRlciBpZD0iYSI+PGZlVHVyYnVsZW5jZSB0eXBlPSJmcmFjdGFsTm9pc2UiIGJhc2VGcmVxdWVuY3k9IjEuNSIgbnVtT2N0YXZlcz0iMyIvPjwvZmlsdGVyPjxyZWN0IHdpZHRoPSIxMjgiIGhlaWdodD0iMTI4IiBmaWx0ZXI9InVybCgjYSkiLz48L3N2Zz4=");
  opacity: 0.5;
  mix-blend-mode: multiply;
  z-index: 0;
}

.container {
  max-width: 1100px;
  margin: 40px auto;
  padding: 20px;
  position: relative;
  background-color: #fdf6d8;
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
  z-index: 1;
}

@media (max-width: 768px) {
  .container {
    margin: 0 auto;
    border-radius: 0;
  }
}

.poet-image {
  width: 200px;
  height: 200px;
  object-fit: cover;
  border-radius: 50%;
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.25);
  border: 2px solid #f8e6b0;
}

.poet-name {
  margin-top: 20px;
  font-size: 2.2em;
  color: #4b3b27;
  text-shadow: 1px 1px 0 #f1d8a6;
}

.poem-header {
  margin-top: 20px;
  color: #4b3b27;
  text-shadow: 1px 1px 0 #f1d8a6;
  padding-bottom: 24px;
}

.title {
  margin-top: 20px;
  font-size: 1.8em;
  color: #2e2417;
  text-shadow: 1px 1px 0 #f1d8a6;
}

.chapter {
  margin-top: 25px;
  text-align: left;
}

.chapter-title {
  width: 100%;
  background-color: #f4e4b1;
  border: none;
  outline: none;
  text-align: left;
  padding: 15px;
  font-size: 1.15em;
  font-weight: bold;
  cursor: pointer;
  border-radius: 8px;
  transition:
    background-color 0.3s,
    transform 0.1s;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
  color: #2e2417;
}

.chapter-title:hover {
  background-color: #f1dca3;
  transform: translateY(-1px);
}

.chapter-content {
  padding: 0 25px;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  background-color: #f9efcb;
  border-radius: 0 0 8px 8px;
  box-shadow: inset 0 1px 4px rgba(0, 0, 0, 0.1);
  font-family: Times New Roman;
  font-style: italic;
  transition:
    max-height 0.4s ease,
    opacity 0.3s ease,
    padding 0.4s ease;
}

.chapter-content.open {
  max-height: none;
  opacity: 1;
  padding: 15px 25px;
  overflow-x: auto;
}

.poem-text {
  width: fit-content;
  min-width: 100%;
}

.poem-stanza {
  margin-bottom: 20px;
}

.poem-line {
  line-height: 1.7;
  color: #2e261a;
  font-size: 1.25em;
  white-space: nowrap;
  overflow-x: auto;
}

.poem {
  margin-bottom: 20px;
}

.poem h3 {
  margin-bottom: 8px;
  color: #3c2e1f;
  text-decoration: underline;
  text-decoration-color: #d8b871;
}

.poem p {
  margin: 0;
  line-height: 1.7;
  color: #2e261a;
  font-size: 1.05em;
  white-space: pre;
  overflow-x: auto;
}

/* Mobile-specific adjustments for better readability */
@media (max-width: 768px) {
  .chapter-content {
    padding: 15px;
  }

  .poem p {
    font-size: 1em;
  }

  /* Add subtle hint that content is scrollable */
  .poem-text {
    padding-bottom: 10px;
  }

  /* Mobile-specific font size adjustments */
  .poet-name {
    font-size: 1.8em; /* Adjust as needed */
  }

  .poem-header {
    font-size: 1.2em; /* Adjust as needed */
  }

  .title {
    font-size: 1.4em; /* Adjust as needed */
  }

  .chapter-title {
    font-size: 1em; /* Adjust as needed */
    padding: 12px;
  }

  .poem-line {
    font-size: 0.7em; /* Adjust as needed */
  }
}
