.author-bio {
  position: relative;
  width: 100%;
  height: 300px; /* Adjust based on your preference */
  overflow: hidden;
  background: transparent;
  font-size: 3rem;
  line-height: 5rem;
  margin-top: 0;
  color: var(--header-color);
  /* text to be slightly drop-shadowed */
  text-shadow: 0 0 10px rgba(46, 43, 43, 0.2);
}

.author-bio::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: url('images/bookshelf.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: blur(8px);
  -webkit-filter: blur(8px);
  z-index: -1;
}

/* Flexbox Container for Books */
.books-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-around; /* Adjusts spacing around items */
  padding: 20px;
}

.section-title {
  /* should be on a line by itself */
  width: 100%;
  text-align: center;
  margin-bottom: 20px;
}

.book {
  flex: 1 1 300px; /* Allows books to grow and shrink but not smaller than 300px */
  margin: 10px;
  display: flex;
  flex-direction: column;
  align-items: center; /* Centers items horizontally in their flex container */
  border: 1px solid var(--section-border-color);
  border-radius: 8px;
  padding: 20px;
  /* Let's give it a drop shadow */
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  /* And a very subtle background gradient based on the background color */
  background: linear-gradient(
    to bottom,
    var(--gradient-start),
    var(--gradient-end)
  );
}

.book-cover {
  height: 250px;
  width: auto;
  /* max-width: 300px; Adjust based on your preference */
}

.description,
.reviews,
.cta-buttons {
  width: 100%; /* Ensures full width inside flex item */
  text-align: left;
}

.description,
.reviews {
  margin-bottom: 20px;
}

/* .cta-buttons should be a flexbox container with a small gap, automatically centered and wrapped depending on the width of the container */
.cta-buttons {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  /* fix to bottom of container */
  margin-top: auto;
}

/* Buttons should all be the same width. They should fit on one line if possible, but wrap if not */
.cta-buttons a {
  flex: 1 1 200px;
  text-align: center;
}

.button {
  display: inline-block;
  padding: 10px 20px;
  margin: 0 5px;
  color: #fff;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
}

.amazon {
  background-color: var(--cta-amazon-bg);
}
.gumroad {
  color: var(--cta-gumroad-fg);
  background-color: var(--cta-gumroad-bg);
}
.universal {
  background-color: var(--cta-universal-bg);
}

@media (max-width: 600px) {
  .book {
    margin: 10px;
    padding: 10px;
  }

  .cta-buttons a {
    display: block;
    margin-bottom: 10px;
  }
}

/* H3 and H4 are for book titles. They should be closer together. H4 should be smaller and in italics */

h3,
h4 {
  margin-top: 0;
  margin-bottom: 10px;
}

h4 {
  font-style: italic;
  font-size: 16px;
}

.reviews {
}

.review {
  font-style: italic;
  position: relative;
  padding: 20px;
  margin-bottom: 20px; /* Ensures space between reviews if they wrap */
  background-color: var(--background-color);
  color: var(--text-color);
  border-radius: 8px; /* Optional for rounded corners */
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); /* Optional for a subtle shadow */
}

.review::before {
  content: '“'; /* Large quotation mark */
  font-size: 4em;
  position: absolute;
  left: 10px;
  top: -10px;
  color: var(--highlight-color);
  font-family: 'Times New Roman', serif;
}

.review cite {
  display: block;
  text-align: right;
  font-style: normal;
  margin-top: 10px;
  font-weight: bold;
}

@media (max-width: 768px) {
  .review {
    flex-basis: 100%; /* Allows review to take full width on narrow screens */
    max-width: 100%; /* Ensures the review stretches to fill the container */
    margin-bottom: 20px; /* Keeps consistent spacing */
  }
}
