:root {
    --bg-color: #edf1f4;
    --caret-color: #f44336; 
    --sub-color: #737373;
    --sub-alt-color: #ececec;
    --synop-column: #fff;
    --text-color: #000000;
    --nav-text-color: #fff;
    --error-color: #d70000;
   
    --nav-top-bg-color: #fff;
    --nav-bg-color: #fff;
    --book-synop-head: #44362e;
    --border-radius-sm: 0.375rem;
    --border-radius-lg: 0.975rem;
}

.dark-theme {
    --bg-color: #36393f; 
    --bg: rgba(47,49,54, 1);
    --bg-maintag: #2f3136;
    --text-color: #dcddde;
    --nav-text-color: #fff;

    --book-synop-head: #ff0000;
    --border-radius-sm: 0.375rem;
    --border-radius-lg: 0.625rem; 
}

html {
    scrollbar-color: #040a0f #202b38;
    scrollbar-color: var(--scrollbar-thumb) var(--bg-color);
    scrollbar-width: thin;
}

body {
    font-family: Roboto, Helvetica Neue, system-ui, -apple-system, BlinkMacSystemFont, Segoe UI, Oxygen, Ubuntu, "Roboto Mono", monospace;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    background: var(--bg-color);
    /* width: 100%; */
    /* height: 100%; */
}

/* @media screen and (min-width: 53rem) {
    body {
        padding-left: 0.5rem;
        padding-right: 0.5rem ;
    }
} */

h3, h4, h5, h6 {
    margin: 0;
    padding: 0;
}
h3 {
    font-size: 2rem;
    font-weight: 500;
}

p, ul, ol, li, table, th, td, div, nav, footer, form, button, input, textarea {
    margin: 0;
    padding: 0;
}

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

.foot-image {
    position: fixed;
    right: 0;
    bottom: 0;
}
.h3index {
    margin-top: 1.5rem;
}

ul.nodeco {
    list-style-type: none;
    padding: 0;
    margin: 0;
    line-height: 1.1rem;
}
main {
    display: grid;
    grid-template-columns: 1fr;
    background: var(--bg-color);
    min-height: 100vh;
    margin: 0;
}
@media screen and (min-width: 53rem) {
    main {
        grid-template-columns: 85% 15%;
        gap: 1rem;
        max-width: 68.75rem;
        margin: 0 auto;
        /* padding: 1rem; */
        min-height: 100vh;
        padding: 0;
    }
}
/* index page */
.indexmain {
    max-width: 100%;
    margin: 0 auto;
    background: var(--bg-color);
    border-radius: 10px;
    /* margin-right: 8px ; */
    /* margin-left: 8px; */
    /* box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2); */
}
/* fix for Trending h2 */
.indexmain h2 {
    padding-right: 0.5rem;
    padding-left: 0.5rem;
}
/* 71.25 */
@media screen and (min-width: 53rem) {
    .indexmain {
        max-width: 68.75rem;
        margin: 0 auto;
        padding: 1.25rem;
        padding-top: 0;
    }
    /* .indexmain img {
        border-radius: var(--border-radius-sm);
    } */
}
.headerlg {
    display: none;
}
@media screen and (min-width: 30rem) {
    .headerlg {
        max-width: 44rem;
        margin: auto;
        display: block;
        height: auto;
    }
}
.headersm {
    display: block;
}
@media screen and (min-width: 30rem) {
    .headersm {
        display: none;
    }
}

/* .navitembox {
    font-size: 1.4rem;
    margin-right: 1rem;
} */
.navitem {
    background-color: var(--button-bg);
    border-radius: var(--border-radius-lg);
    color: var(--sub-color);
    font-size: 1rem;
    font-weight: 500;
    transition: opacity 0.3s ease;
}

.navmenu a {
    color: var(--sub-color);
    font-size: 1rem;
    font-weight: 500;
}
 
.navwrap {
    background-color: #fff;
    color: var(--nav-text-color);
}

@media screen and (min-width: 26.25rem) {
    .navwrap {
        margin-bottom: 1.8rem;
        padding: 0;
    }
}

/* .topnav {
    padding: 0;
} */
.topitem {
    background-color: var(--nav-top-bg-color);
    /* padding: 0.35rem; */
}
/* .topitem p {
    text-decoration: none;
    color: var(--text-color);
} */
.topitem-logo a {
    text-decoration: none;
    font-family: "Poiret One", serif;
    font-weight: 400;
    color: var(--text-color);
    font-size: 1.7rem;
    margin-left: 2rem;
}

.rnav {
    position: relative;
    top: 0;
    left: 0;
    background: transparent;
    display: flex;
    align-items: center;
    max-width: 75rem;
    margin: auto;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--nav-text);
    /* padding: 0.35rem; */
}

.rnav a {
    color: var(--sub-color);
    text-decoration: none;
    font-size: 1rem;
    font-weight: 500;
    margin-right: 1.0625rem;
    transition: opacity 0.3s ease;
}

.rnav-logo {
    max-width: 6.75rem;
    margin-right: 0.3125rem;
    margin-top: 0.4375rem;
}

.rnav-link {
    padding-left: 1.125rem;
}

.mofont {
    font-size: 2.5rem;
    margin-left: -0.4375rem;
}

.navburg {
    position: absolute;
    font-size: 1.625rem;
    font-weight: 500;
    cursor: pointer; 
    right: 1rem; 
    top: -2.6rem;
    color: var(--text-color);
}

.sa-desknav {
    display: none;
}

@media screen and (min-width: 70rem) {
    .sa-desknav {
        display: flex;
        align-items: center;
        justify-content: center
    }
    .rnav-logo {
        max-width: 6.75rem;
        margin-right: 0.3125rem;
    }
}

.sa-mobinav {
    display: block;
}

@media screen and (min-width: 70rem) {
    .sa-mobinav {
        display: none;
    }
}

.sidenav {
    height: 100%;
    width: 0;
    position: fixed;
    z-index: 99;
    top: 0;
    right: 0;
    color: var(--text-color);
    background-color: var(--nav-bg-color);
    overflow-x: hidden;
    transition: 0.5s;
    padding-top: 3.75rem;
}

.sidenav a {
    text-decoration: none;
    color: var(--text-color);
    background-color: var(--nav-bg-color);
    display: block;
    transition: 0.3s;
}

.sidenav a:hover {
    color: #f1f1f1;
}

.sidenav .closebtn {
    position: absolute;
    top: 1.25rem;
    right: 1.625rem;
    font-size: 2rem;
}

@media screen and (max-height: 28.125rem) {
    .sidenav {
        padding-top: 0.9375rem;
    }
    .sidenav a {
        font-size: 1.75rem;
    }
}

.dark-light {
    position: relative;
    left: 1rem;
    top: -2.1rem;
    cursor: pointer !important;
    font-size: 1.2rem;
}

/* @media screen and (min-width: 48rem) {
    .dark-light {
        left: unset;
        right: 1rem;
        
    }
} */

.wrap404 {
    display: grid;
    place-items: center;
    height: 100vh;
}

.center404 {
    width: 50%;
    height: 50%;
}

.bgcustom {
    background-color: var(--bg-color);
}

.box {
    padding: 0.6rem;
    border: 0.0625rem solid var(--sub-color);
    /* border-radius: var(--border-radius-sm); */
    margin-bottom: 0.3rem;
    margin-top: 0.5rem;
}


/* start sections */
section {
    --min: 12ch;
    --gap: 0.7rem;
    display: grid;
    grid-gap: var(--gap);
    grid-template-columns: repeat(auto-fit, minmax(min(100%, var(--min)), 1fr));
    margin: 0.875rem 0;
    padding-right: 0.5rem;
    padding-left: 0.5rem;
}
@media (min-width: 51.5rem) {
    section {
        --min: 18ch;
        margin: 0.875rem 0.5rem;
        margin: 0;
        padding: 0;
    }
}
section > div {
    border-radius: 0.75rem;
    background-color: var(--section-bg);
    /* padding: 0.75rem; */
}
section > p {
    /* border-radius: 0.75rem; */
    margin: 0;
    /* padding: 4px; */
    /* border: 1px solid grey; */
    /* background-color: var(--nav-bg-color); */
    padding-bottom: 0.25rem;
}
section p a {
    text-decoration: none;
    color: black;
}
section p a img { 
    width: 100%;
    height: 80%;
    object-fit: cover;
    transition: opacity 0.3s ease;
    border-radius: var(--border-radius-lg);
    border: 12px solid white;
    
}
section p a:hover img {
    opacity: 0.6;
}

section .hov {
    /* text-align: center; */
    text-decoration: none;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 0.9rem;  
    font-weight: 600;
    line-height: 1rem;
}

.truncate {
    display: inline-block;
    width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    resize: none;
}
.orange {
    color: #ff7066;
}

/* start book synop */
.book-promo {
    color: var(--text-color);
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 1.25rem;
    padding: 0.375rem;
    border-radius: 0.625rem;
}
/* @media screen and (min-width: 29.75rem) {
    .book-promo {
        padding: 0;
    }
} */
.book-cover img {
    width: 100%;
    height: auto;
    object-fit: contain;
    border-radius: var(--border-radius-sm);

}
@media screen and (min-width: 26.25rem) {
    .book-cover img {
        width: 50%;
        height: auto;
    }
}
@media screen and (min-width: 47.75rem) {
    .book-cover img {
        max-height: 248px;
        width: auto;
    }
}
/* synopsys */
.left-column {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    color: var(--text-color);
    background-color: var(--synop-column);
    padding: 0.6rem;
    border-radius: var(--border-radius-sm);
}
/* .left-column > div {
    border: 2px solid #000;
    border-radius: var(--border-radius-sm);
} */

.grid-header {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    /* padding: 1rem; */
}
@media screen and (min-width: 53rem) {
    .grid-header {
        grid-template-columns: 25% 75%;
        gap: 1rem;
        max-width: 75rem;
        /* margin: 0 auto; */
        padding: 0;
    }
}
.ratings{
    display: flex;
    gap: 1rem;
    align-items: center;
}
.rating-box {
    padding: 0.5rem;
    background: var(--sub-alt-color);
    border-radius: var(--border-radius-sm);
    text-align: center;
    /* width: 100%; */
}
.genre {
    padding: 0.5rem;
    background: var(--sub-alt-color);
    border-radius: var(--border-radius-sm);
    width: 100%;
}
.where-to-watch {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}
/* .watch-platform img {
    width: 50px;
    height: auto;
} */
/* end claude */

div.book-synop-heading {
    background-color: var(--book-synop-head);
    color: var(--sub-alt-color);
    /* margin-bottom: -10px; */
}

div.book-synop {
    font-size: 1.2rem;
}
@media screen and (min-width: 26.25rem) {
    div.book-synop {
        font-size: 1rem;
    }
}

.book-details {
    text-align: left;
    width: 100%;
    color: var(--text-color);
    padding: 1.25rem;
    border-radius: 0.5rem;
}

.book-details h1 {
    font-size: 2.1rem;
    font-weight: 500;
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.625rem;
    margin-top: 0.625rem;
    margin-bottom: 0.875rem;
}
.tags h2 {
    color: var(--book-synop-head);
    width: 100%;
    padding: 0.5rem;
    border-radius: var(--border-radius-sm);
    /* font-size: 1rem; */
    font-weight: 500;
    border: 0.1rem solid #333;
}
.tags span {
    color: var(--book-synop-head);
    padding: 0.5rem;
    border-radius: var(--border-radius-sm);
    font-size: 1rem;
    font-weight: 400;
    border: 0.1rem solid #333;
}

.summary h2 {
    margin-top: 1.25rem;
    font-size: 1.125rem;
}

.summary p {
    font-size: 1.1875rem;
    margin: 0.625rem 0;
}

@media (min-width: 37.5rem) {
    .summary p {
        font-size: 1rem;
    }
}

.adgo {
    display: none;
}

@media (min-width: 59.375rem) {
    .adgo {
        display: block;
        /* min-width: 7.5rem;   */
    }
    .adgo img {
        /* height: 37.5rem; */
        min-width: 7.5rem;
    }
}

@media (max-width: 48rem) {
    .book-promo {
        flex-direction: column;
    }
    .book-details {
        max-width: 100%;
    }
}

/* Discover - Book subject list*/
.leftlist-column {
    display: flex;
    flex-direction: column;
    /* gap: 1rem; */
    color: var(--text-color);
    background-color: var(--bg-color);
    padding: 0.6rem;
    border-radius: var(--border-radius-sm);
}
.listcontainer {
    padding: 0.5rem;
    background-color: white;
    color: #000;
    line-height: 1.2;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    border: 0.0625rem solid #eee; /* 1px */
    border-radius: 1rem;
    margin-bottom: 0.3rem;
}
  
.booklist-card {
    display: flex;
    gap: 1rem;
    align-items: center;
}
  
.booklist-cover {
    width: 3.5rem; /* 56px */
    height: auto;
    border-radius: 0.25rem;
}
  
.booklist-info {
    flex: 1;
}
  
.booklist-title {
    font-size: 1rem; /* 16px */
    font-weight: 500;
    margin: 0;
    color: #000;
    text-decoration: none;
}
  
.booklist-meta {
    font-size: 0.875rem;
    color: #9ca3af;
    margin: 0.25rem 0;
}
  
.booklist-meta a {
    color: #9ca3af;
    text-decoration: none;
}
  
.booklist-stats {
    display: flex;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: #9ca3af;
}
  
.star {
    color: #eab308;
}
  
.want-to-read {
    background: #374151;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 0.25rem;
    border: none;
    font-size: 0.875rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

#load-more {
	text-align: center; /* Center the button /
	padding: 20px; / Add some padding */
}
.load-more-button {
	background-color: #4CAF50; /* Green */
	border: none;
	color: white;
	padding: 10px 20px;
	text-align: center;
	text-decoration: none;
	display: inline-block;
	font-size: 16px;
	margin: 4px 2px;
	cursor: pointer;
	border-radius: 5px;
}
/* end Discover */

h1 {
    font-size: 2.1rem;
    font-weight: 500;
    font-family: "Noto Serif", serif;
}

h2 {
    font-size: 1.3rem;
    font-weight: 600;
    /* padding: 1rem; */
}

h3 {
    font-size: 1.5rem;
}

h4 {
    font-size: 1.25rem;
}

h5 {
    font-size: 1rem;
}

h6 {
    font-size: 0.875rem;
}

ul, ol {
    margin: 0.9375rem 0;
    padding-left: 1.25rem;
}

li {
    margin-bottom: 0.625rem;
}

/* img {
    width: 100%;
    height: auto;
    border-radius: var(--border-radius-sm);
} */

form {
    margin: 1.25rem 0;
}

input, textarea, button {
    /* width: 100%; */
    padding: 0.625rem;
    /* margin-bottom: 0.625rem; */
    border: none;
    border-radius: 0.3125rem;
}

button {
    font-size: 1rem;
}

table {
    margin: 1.25rem 0;
}

th, td {
    padding: 0.625rem;
}

code {
    padding: 0.125rem 0.25rem;
    border-radius: 0.25rem;
    font-size: 0.9rem;
}

pre {
    padding: 0.625rem;
    border-radius: 0.3125rem;
}

footer {
    margin-top: 1rem;
    padding: 0.425rem;
    border-top: 0.0625rem solid #eee;
}