*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0 1rem 4rem;
  background-color: #e4edf7;
  background-image: linear-gradient(180deg, #17365d 0, #17365d 15rem, #e4edf7 15rem);
  color: #1b2733;
  font-family: "Source Serif 4", Georgia, "Times New Roman", serif;
  font-size: 1.05rem;
  line-height: 1.6;
}

header {
  max-width: 74rem;
  margin: 0 auto;
  padding: 3.5rem 0 2.5rem;
  color: #eaf3fd;
}

h1 {
  margin: 0 0 0.5rem;
  font-family: "Fraunces", Georgia, serif;
  font-size: clamp(2.4rem, 6vw, 3.6rem);
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.1;
}

.tagline {
  max-width: 38rem;
  margin: 0;
  color: #b8d0ec;
  font-style: italic;
}

main {
  max-width: 74rem;
  margin: 0 auto;
}

.table-wrap {
  overflow-x: auto;
  background-color: #f6faff;
  border: 1px solid #a8bdd6;
  border-top: 6px solid #2f6fb3;
  border-radius: 4px;
  box-shadow: 0 10px 24px rgba(23, 54, 93, 0.25);
}

table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

th {
  padding: 1rem 1.25rem;
  background-color: #d8e6f6;
  border-bottom: 2px solid #2f6fb3;
  color: #17365d;
  font-family: "Fraunces", Georgia, serif;
  font-size: 1.05rem;
  font-weight: 600;
}

td {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid #cbdaec;
  vertical-align: middle;
}

tbody tr:last-child td {
  border-bottom: none;
}

td:first-child {
  font-weight: 600;
}

/* Row backgrounds: attribute selectors with linear-gradient */
tr[class="read"] {
  background-image: linear-gradient(90deg, #f6faff, #e6f1e9);
}

tr[class="to-read"] {
  background-image: linear-gradient(90deg, #f6faff, #e6eef9);
}

tr[class="in-progress"] {
  background-image: linear-gradient(90deg, #f6faff, #faf1d3);
}

/* Every span is inline-block */
span {
  display: inline-block;
}

/* Status pills */
span[class="status"],
span[class^="rate"] {
  height: 1.9rem;
  width: 6.8rem;
  padding: 0.15rem 0.4rem;
}

span[class="status"] {
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.3rem;
  text-align: center;
  border-radius: 999px;
}

tr[class="to-read"] span[class="status"] {
  border: 2px solid #92b3d6;
  background-image: linear-gradient(180deg, #eef4fb, #d9e6f5);
  color: #2f5379;
}

tr[class="read"] span[class="status"] {
  border: 2px solid #86b79b;
  background-image: linear-gradient(180deg, #eaf5ed, #d3e8da);
  color: #2c5a43;
}

tr[class="in-progress"] span[class="status"] {
  border: 2px solid #d9bb6c;
  background-image: linear-gradient(180deg, #fdf5da, #f6e5ac);
  color: #6b5314;
}

/* Rating dots */
span[class^="rate"] {
  width: 5rem;
  text-align: left;
}

span[class^="rate"] > span {
  height: 1.1rem;
  width: 1.1rem;
  margin: 0.1rem 0.15rem;
  border: 2px solid #2f6fb3;
  border-radius: 50%;
  background-color: #f6faff;
}

/* Rating fill: lit-up dots (one / two / three) */
span[class*="one"] > span:first-child {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="one"] > span:first-of-type {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="one"] > span:nth-child(1) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="one"] > span:nth-of-type(1) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="one"] > :first-child {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="one"] span:first-child {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="one"] span:first-of-type {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="one"] span:nth-child(1) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="one"] span:nth-of-type(1) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="one"] :first-child {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="two"] > span:nth-child(-n+2) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="two"] > span:nth-of-type(-n+2) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="two"] > :nth-child(-n+2) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="two"] span:nth-child(-n+2) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="two"] span:nth-of-type(-n+2) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="two"] :nth-child(-n+2) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="three"] > span {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="three"] > * {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class*="three"] span {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="one"] > span:first-child {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="one"] > span:first-of-type {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="one"] > span:nth-child(1) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="one"] > span:nth-of-type(1) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="one"] > :first-child {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="one"] span:first-child {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="one"] span:first-of-type {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="one"] span:nth-child(1) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="one"] span:nth-of-type(1) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="one"] :first-child {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="two"] > span:nth-child(-n+2) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="two"] > span:nth-of-type(-n+2) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="two"] > :nth-child(-n+2) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="two"] span:nth-child(-n+2) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="two"] span:nth-of-type(-n+2) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="two"] :nth-child(-n+2) {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="three"] > span {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="three"] > * {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

span[class~="three"] span {
  background-image: linear-gradient(135deg, #7db8f2, #2f6fb3);
}

@media (max-width: 600px) {
  th,
  td {
    padding: 0.75rem;
  }
}

/* Pitch column and reflection */
td[class="pitch"] {
  min-width: 22rem;
  font-size: 0.98rem;
  line-height: 1.55;
}

.reflection {
  margin-top: 2.5rem;
  padding: 2rem 2.25rem;
  background-color: #f6faff;
  border: 1px solid #a8bdd6;
  border-left: 6px solid #2f6fb3;
  border-radius: 4px;
}

.reflection h2 {
  margin: 0 0 1rem;
  color: #17365d;
  font-family: "Fraunces", Georgia, serif;
  font-size: 1.8rem;
}

.reflection-body::after {
  content: "";
  display: block;
  clear: both;
}

.reflection-text p {
  margin: 0 0 1rem;
  text-align: justify;
  hyphens: auto;
}

.reflection-quote {
  position: relative;
  float: right;
  width: 21rem;
  margin: 0.25rem 0 1rem 2.5rem;
  padding: 3.25rem 1.75rem 1.5rem;
  background-image: linear-gradient(160deg, #eaf2fb, #d6e5f6);
  border-radius: 6px;
  color: #17365d;
  text-align: center;
}

.reflection-quote::before {
  content: "\201C";
  position: absolute;
  top: 0.4rem;
  left: 50%;
  transform: translateX(-50%);
  color: #7db8f2;
  font-family: "Fraunces", Georgia, serif;
  font-size: 5rem;
  font-weight: 700;
  line-height: 1;
}

.quote-text {
  font-size: 1.15rem;
  font-style: italic;
  line-height: 1.55;
}

.reflection-quote footer {
  margin-top: 1.1rem;
  padding-top: 0.9rem;
  border-top: 1px solid #a8bdd6;
  color: #2f6fb3;
  font-size: 0.95rem;
  font-weight: 600;
}

.reflection-quote cite {
  font-style: italic;
}

@media (max-width: 760px) {
  .reflection-quote {
    float: none;
    width: auto;
    margin: 0 0 1.5rem;
  }
}

.reflection-text p:last-child {
  margin-bottom: 0;
}

.score {
  margin-left: 0.4rem;
  color: #17365d;
  font-size: 0.9rem;
  font-weight: 600;
  white-space: nowrap;
}

/* Book Profile details inside the title cell */
.profile {
  margin: 0.5rem 0 0;
  padding: 0;
  list-style: none;
  color: #3c4b5c;
  font-size: 0.88rem;
  font-weight: 400;
  line-height: 1.5;
}

.profile b {
  color: #17365d;
  font-weight: 600;
}

/* Favorite quotes */
.quotes {
  margin-top: 2.5rem;
}

.quotes h2 {
  margin: 0 0 1.25rem;
  color: #17365d;
  font-family: "Fraunces", Georgia, serif;
  font-size: 1.8rem;
}

.quote-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem;
}

.fav-quote {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  margin: 0;
  padding: 1.6rem 1.75rem 1.4rem;
  background-color: #f6faff;
  border: 1px solid #a8bdd6;
  border-top: 5px solid #2f6fb3;
  border-radius: 4px;
}

.fav-text {
  color: #1b2733;
  font-size: 1.08rem;
  font-style: italic;
  line-height: 1.65;
}

.fav-quote footer {
  margin-top: 1.1rem;
  padding-top: 0.8rem;
  border-top: 1px solid #cbdaec;
  color: #2f6fb3;
  font-size: 0.95rem;
  font-weight: 600;
}

.fav-quote cite {
  font-style: italic;
}


@media (max-width: 760px) {
  .quote-grid {
    grid-template-columns: 1fr;
  }
}