html,
body {
    background-color: #ffffff; /* #FFFCD7; */
    color: #000000; /* #A01F13; */
    font-family: "Open Sans", Helvetica, Arial, sans-serif;
    font-size: 1em;
    line-height: 1.5em;
    letter-spacing: 0.01mm;
    margin: 0;
    max-width: 100vw;
    padding: 0;
    width: 100%;
    height: 100%;
}

html {
    overflow-y: scroll;
}
input[type="submit"] {
    color: #fff;
    text-decoration: none;
    background: #60a3bc;
    padding: 6px;
    border-radius: 45px 45px;
    display: inline-block;
    border: none;
}
input[type="submit"]:hover {
    text-shadow: 0px 0px 6px rgba(255, 255, 255, 1);
    -webkit-box-shadow: 0px 5px 40px -10px rgba(0, 0, 0, 0.57);
    -moz-box-shadow: 0px 5px 40px -10px rgba(0, 0, 0, 0.57);
    box-shadow: 0px 5px 40px -10px rgba(0, 0, 0, 0.57);
    transition: all 0.4s ease 0s;
}
/* links */
a:link {
    color: currentColor;
    text-decoration: none;
}
a:visited {
    color: currentColor;
}
a:hover {
    color: currentColor;
    text-decoration: underline;
}
a:active {
    color: currentColor;
}
.no-hover:hover {
    text-decoration: none;
}

/* text selection
::-moz-selection {
	background-color: #0a0a0a;
	color: #ffffff;
}

::selection {
	background-color: #0a0a0a;
	color: #ffffff;
}*/

.no-select {
    user-select: none;
}

/* animations */
.fadein {
    animation: fadein 1s;
}

@-moz-keyframes fadein {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@-webkit-keyframes fadein {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes fadein {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.fadeinup {
    animation: fadeInUp 1s both ease;
}

@-moz-keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translate3d(0, 40px, 0);
    }

    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

@-webkit-keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translate3d(0, 40px, 0);
    }

    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translate3d(0, 50px, 0);
    }

    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

/* ==================================================
container */
.container {
    max-width: 100%;
    min-height: 75vh;
    position: relative;
}

@media screen and (orientation: landscape) {
    .container {
        min-height: 75vh;
        padding: 10vh 5vw;
    }
}

@media screen and (orientation: portrait) {
    .container {
        min-height: 75vh;
        padding: 10vh 5vw;
    }
}
/*.content h1 {
	margin-top:40px;
}*/

ul {
    list-style-type: "\2022";
    margin: 0;
    padding-left: 10px;
}

/* ==================================================
library */
.library .latest {
    white-space: nowrap;
    width: 100%;
}

.library .latest::-webkit-scrollbar {
    height: 3px;
}

.library .latest::-webkit-scrollbar-track {
    background-color: #cccccc;
}

.library .latest::-webkit-scrollbar-thumb {
    background-color: #333333;
}

.library .latest a {
    display: inline-block;
    margin: 0;
    padding: 10px;
}

.library .latest a:hover {
    background-color: transparent;
}

.bookshelves {
    margin: 0 auto;
    padding: 0;
    width: 100%;
}

.bookshelves ul {
    column-count: 3;
    column-gap: 0px;
    cursor: default;
    width: 100%;
    /*height: 620px;*/
}
.bookshelves > ul li::before {
    color: #a01f13;
    display: inline-block;
    width: 1em;
    margin-left: -1em;
}
/*.bookshelves ul li {
	color: #808080;
	display: inline-block;
	margin-bottom: 0px;
	padding-right: 10%;
	width: 90%;
}*/

.page_content .bookshelves h2 {
    border-bottom: 0px none #ffffff;
}
/*.library .bookshelves h2:hover,
.library .bookshelves ul li:hover {
	-moz-transition: all 0.2s ease-in-out;
	-o-transition: all 0.2s ease-in-out;
	-webkit-transition: all 0.2s ease-in-out;
	color: #000000;
	cursor: pointer;
	text-decoration: underline;
	transition: all 0.2s ease-in-out;
}
*/
.page_content.library .lib {
    margin-bottom: 50px;
}

/*@media only screen and (max-width: 1200px),
only screen and (max-device-width: 1200px) {
	.library .bookshelves ul {
		-moz-column-count: 2;
		-moz-column-gap: 0px;
		-webkit-column-count: 2;
		-webkit-column-gap: 0px;
		column-count: 2;
		column-gap: 0px;
	}
}

@media only screen and (max-width: 1000px),
only screen and (max-device-width: 1000px) {
	.library .bookshelves ul {
		-moz-column-count: 1;
		-moz-column-gap: 0px;
		-webkit-column-count: 1;
		-webkit-column-gap: 0px;
		column-count: 1;
		column-gap: 0px;
	}

	.library .bookshelves ul li {
		padding-right: 0;
		width: 100%;
	}
}
*/
/* ==================================================
book */
.book-container {
    align-items: center;
    justify-content: center;
    margin: 50px;
    max-width: 1000px;
}

@media only screen and (min-width: 1001px) {
    .book-container {
        display: flex;
    }
}

.book.page_content {
    background-color: #f5f5f5;
    box-shadow: none;
    padding: 50px;
    transition:
        box-shadow 0.2s ease-in-out,
        background-color 0.5s ease-in-out;
}

.book.page_content:hover {
    background-color: #ffffff;
    box-shadow: 0 25px 75px rgba(0, 0, 0, 0.1);
    transition:
        box-shadow 0.2s ease-in-out,
        background-color 0.5s ease-in-out;
}

.book .cover img {
    box-shadow: 0px 20px 50px rgba(0, 0, 0, 0.1);
    max-height: 200px;
    max-width: 150px;
    vertical-align: top;
}

.book .details .id {
    font-family: Consolas, Courier, monospace;
}

.book .bib_rec ul {
    list-style: square inside;
}

@media only screen and (min-width: 1001px) {
    .book .download {
        width: 75px;
    }
    .book .download {
        line-height: 25px;
        width: 130px;
    }
    .book .download a li {
        display: block;
    }
    .book .download ul {
        list-style: square inside;
    }

    .book .share {
        line-height: 25px;
        width: 20px;
        word-wrap: break-word;
    }

    .book .share a {
        display: block;
        margin: 10px 0;
    }
}

@media only screen and (max-width: 1000px) {
    .book .section {
        display: block;
        text-align: center;
    }

    .book h1 {
        text-align: center;
    }

    .book .download a {
        display: inline-block;
        text-align: center;
        width: 20%;
        max-width: 75px;
    }

    .book .share a {
        display: inline-block;
        margin: 5px;
    }
}

.share-icon img {
    height: 20px;
    width: 20px;
}

/*@media only screen and (max-width: 1200px),
only screen and (max-device-width: 1200px) {
	.about {
		-moz-column-count: 1;
		-moz-column-gap: 0px;
		-webkit-column-count: 1;
		-webkit-column-gap: 0px;
		column-count: 1;
		column-gap: 0px;
	}

	.about p {
		width: 100%;
		padding-right: 0;
	}

	.about p.quote {
		width: 95%;
	}
}*/
.page_content {
    margin-top: 40px;
    padding-bottom: 30px;
}

.page_content figure {
    /*border: 3px solid #ddd;*/
    border-radius: 5px;
    padding: 10px;
    max-width: 100%;
    height: auto;
    float: right;
    text-align: center;
}
.page_content figure img {
    width: 100%;
    vertical-align: baseline;
}
/*.thumbnail a {
	text-align:center;
}*/
.box_shadow {
    margin-top: 1em;
    margin-bottom: 1em;
    padding: 1ex 1em;
}
/*.page_content .page_heading {
	font-size: 30px;
	font-weight: bold;
	color:#A01F13;
}*/
.page_content h1::before {
    display: block;
    content: "";
    visibility: hidden;
    pointer-events: none;
}
.page_content h1 {
    font-size: 1.875em;
    font-weight: bold;
    margin-top: 2em;
    width: 100%;
    line-height: 1em;
}
.page_content .header h1 {
    margin-top: 3.5em;
}
.page_content h2::before {
    display: block;
    content: "";
    visibility: hidden;
    pointer-events: none;
}
.page_content h2 {
    font-size: 1.5em;
    font-weight: bold;
    margin-top: 15px;
    margin-bottom: 15px;
    width: 100%;
}

.page_content h3::before {
    display: block;
    content: "";
    margin-top: -120px;
    height: 120px;
    visibility: hidden;
    pointer-events: none;
}
.page_content > ul li::before {
    color: #a01f13;
    display: inline-block;
    width: 1em;
    /*margin-left: -1em;*/
    /*font-size: small;*/
}
@media only screen and (min-width: 750px) {
    .page_content > ul li::before {
        font-size: small;
    }
    /* .bookshelves > ul li::before {
		font-size: small;
	} */
}

.page_content ul li {
    /* list-style: none; */
    padding: 5px;
}

/*.page_content ul {
	list-style: square;
}*/

.page_content p {
    /*color: #999999;*/
    margin-top: 10px;
    margin-bottom: 10px;
    padding-top: 10px;
    padding-bottom: 10px;
}
.page_content a:link {
    color: #003366;
    text-decoration: underline;
}

.page_content a:visited {
    color: #3e444d;
}
.page_content a:hover {
    color: currentColor;
    /*background:#E7E292;*/
    text-decoration: underline;
    /*background: #BDAE92;*/
}
.page_content a:active {
    color: brown;
}

.page-body {
    padding-top: 1px;
}

.anchor a {
    top: -80px;
}
.contents {
    background-color: #f9f9f9;
    border: 1px solid #a2a9b1;
    padding: 5px;
    display: inline-block;
}

.contents ol .inner_1 {
    list-style-type: lower-roman;
}
.contents ol .inner_2 {
    list-style-type: lower-alpha;
}
pre {
    border: 1px dashed #2f6fab;
    background-color: #f9f9f9;
    padding: 1em;
}
table {
    border-collapse: collapse;
}
table,
th,
td {
    background-color: #f8f9fa;
    color: #222;
    margin: 1em 0;
    border: 1px solid #a2a9b1;
}
/*table > * > tr > th{
border: 1px solid #a2a9b1;
text-align:center;
}*/

.search_category li {
    display: inline-block;
}
.search_category a {
    font-weight: bold;
}

ul.icon-list {
    list-style-type: none;
}

ul.icon-list li {
    display: inline-block;
    padding: 30px;
    font-size: 1.3em;
}

/* ==================================================
footer */
.footer {
    position: inherit;
    left: 0;
    right: 0;
    bottom: -32px;
    text-align: center;
    font-size: 0.9em;
    width: 100%;
}

.footer ul li {
    display: inline-block;
    padding: 10px;
}
.footer img {
    vertical-align: baseline;
}
.cover_title h5 {
    white-space: break-spaces;
    overflow: hidden;
    height: 5em;
    text-decoration: none;
    text-align: center;
    position: absolute;
    width: 100px;
    background-color: #d9eaef;
}
.cover_title h5:hover {
    overflow-y: visible;
    height: auto;
}
.cover_image img {
    height: 150px;
    width: 100px;
    margin-left: auto;
    margin-right: auto;
    display: block;
}
.cover_image {
    height: 250px;
    width: 100px;
}
/*.cover_image h5 {
	white-space: break-spaces;
	overflow-y: auto;
	height: 100px;
}*/

/*=====CLASS RULES IMPLEMENTED in pg-desktop-one.css========*/
ul.results li::before {
    content: unset;
}
@media only screen and (max-width: 750px) {
    container {
        left: 0;
        padding: 10% 10vw;
        position: relative;
        right: 0;
        width: 80vw;
    }
    /*.content {
		margin-top: 180px;
	}*/
    .page_content {
        margin-top: 60px;
        height: auto;
    }
    .page_content h1 {
        font-size: 1.125em;
        text-align: center;
    }
    .page_content h2 {
        font-size: 1em;
        text-align: center;
    }
    body {
        font-size: 1em;
    }

    .bookshelves ul {
        column-count: 1;
        column-gap: 0px;
        cursor: default;
        width: 100%;
        height: unset;

        /*.page_content img{
		width: 50%;
		height: 50%;
	}*/
    }
    .cover_title h5 {
        overflow-y: scroll;
        height: 100px;
    }
}

/*New Cover_image rules only applicable to test_index for latest covers from gutenberg1*/
.library .latest a {
    vertical-align: top;
}
.library .latest a:link {
    text-decoration: none;
}
.library .latest a:hover h5 {
    overflow-y: visible;
    height: auto;
}
/*Old Cover image rules orginally declated in CoverPages.py on autocat3. Keep them so it doesn't break anything if it is used somewhere else on autocat3.*/
.cover-thumb {
    display: inline-block;
    background-position: center;
    background-repeat: no-repeat;
}
.cover-thumb-small {
    width: 100px;
    height: 150px;
}
.cover-thumb-medium {
    width: 210px;
    height: 310px;
}

.box_announce {
    padding: 0em 1em;
}

/* Different HTML for mobile and Desktop display */

#standard {
    display: block;
}
#mobile {
    display: none;
}
@media screen and /*(orientation: portrait) */(max-width : 1024px) {
    #standard {
        display: none;
    }
    #mobile {
        display: block !important;
    }
}

/* Put theme-specific colors here to make it easy to switch between themes */
/* ORIGINAL THEME */
/*
library .latest h1 {
	color: #A01F13;
	border-bottom: 2px solid #A01F13;
}
.box_shadow {
	background-color: #F5ECDB;
	border: 1px solid #eddab7;
}
.box_announce {
	background-color: #f2dede;
	border: 1px solid #ebccd1;
}
.page_content h1 {
	color: #A01F13;
}
.page_content h2 {
	color: #A01F13;
}
*/

/* BLUE THEME */

.library .latest h1 {
    color: #a01f13;
    border-bottom: 2px solid #a01f13;
}
.box_shadow {
    background-color: #d9eaef;
    border: 1px solid #b2c3c4;
}
.box_announce {
    background-color: #f2dede;
    border: 1px solid #ebccd1;
}
.page_content h1 {
    color: #aa873b;
}
.page_content h2 {
    color: #9b8053;
}
.page_content h2.subtitle {
    color: #9b8053;
}
.page_content a:hover {
    background: #c7dde3;
}
.footer {
    background-color: #f0efea;
}
.footer a:link,
.footer a:visited,
.footer a:hover,
.footer a:active {
    color: #006479;
}

/* Hide the extended text by default */
.toggle-content {
    display: none;
}

.readmore {
    cursor: pointer;
}

/* Styling specific to the "Read More" text not the dots */
#read_more {
    text-decoration: underline;
    color: #003366;
}

/* Hide the 'Show Less' label by default */
.showless {
    display: none;
    cursor: pointer;
    text-decoration: underline;
    color: #003366;
}

/* When checkbox is checked, show the text and the 'Show Less' label */
#toggle:checked ~ .toggle-content {
    display: inline;
}

#toggle:checked ~ .showless {
    display: inline;
}

/* When checkbox is checked, hide 'Read More' */
#toggle:checked ~ .readmore {
    display: none;
}

/* Hide the summary on small screens for now 
@media screen and (max-width: 550px) {
    .summary-text-container {
        display: none;
    }
} */

/* Attempt to "fix" the mobile page */
@media (max-width: 768px) {
    h1 {
        padding-bottom: 8px;
    }

    .page-body {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    #cover-social-wrapper {
        display: flex;
        flex-direction: column;
        align-items: center;
        width: 100%;
    }

    #tabs-wrapper {
        margin: 50px 0 0 0;
    }

    #tabs {
        margin-left: 0;
    }

    .summary-text-container {
        text-align: center;
    }

    table.bibrec td {
        word-wrap: break-word;
        word-break: break-word;
    }
}

/* CUSTOM CSS FOR STYLE UPGRADE OF BIBREC.html */
/* Styling for the "read online" link */
.read_html {
    display: inline-block;
    padding: 8px 40px; /* Fallback for browsers that don't support clamp() */
    padding: 8px clamp(8px, 7vw, 50px);
    background-color: #c7dde3;
    color: black !important;
    border-radius: 8px;
    text-decoration: none !important;
    transition: all 0.3s ease;
    font-size: 16px;
    font-weight: bold;
    border: 1px solid #d6d3d1;
    max-width: 100%;
    box-sizing: border-box;
    white-space: nowrap;
}

.read_html:hover {
    background-color: #e6e6e6;
    transform: translateY(-1px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.15);
}

/* Increase font size for similar books links */
.similar-books-link {
    font-size: 1.1em;
    font-weight: 500;
    transition: font-size 0.2s ease;
}

.similar-books-link:hover {
    font-size: 1.15em;
}

/* Custom styles for tables and headers */
#download_options_table,
#about_book_table {
    background-color: white;
    border-collapse: collapse;
    border: none;
}

#download_options_table th,
#download_options_table td,
#about_book_table th,
#about_book_table td {
    border-color: #d6d3d1;
    padding: 8px 6px;
}

#download_options_table th,
#about_book_table th {
    background-color: #e7e5e4;
}

#download_options_table td,
#about_book_table td {
    background-color: #fafafa;
}

/* Headers styling */
#book_title {
    color: black;
    border-bottom: 1px solid black;
    padding-bottom: 0.75rem;
    margin: 2rem 0 2.25rem;
    font-size: 2rem;
    line-height: 1.2;
}

.header.middle_section_header,
#about_book_header,
#download_options_header {
    color: black;
    margin-top: 3.25rem;
    font-size: 1.5rem;
}

/* Page layout */
.page_content {
    margin-top: 36px;
    padding-bottom: 24px;
}

#content .breadcrumbs {
    margin-top: 0;
}

.breadcrumbs li a:link {
    color: black;
    text-decoration: none;
}

/* Responsive book title for small screens */
@media screen and (max-width: 768px) {
    #book_title {
        font-size: 1.5rem;
    }

    .breadcrumbs ul {
        line-height: 1;
    }

    #qr {
        display: none;
    }
}


/* Custom CSS for bibrec */
.bibrec_page div .page_content {
    margin-top: 60px;
}

@media screen and (max-width: 1025px) {
    .bibrec_page div .page_content {
        margin-top: 130px;
    }
}

/* Custom CSS for results page of quick searches */
.search_results_page div .header {
    padding-top: 5px;
}

@media screen and (max-width: 1025px) {
    .search_results_page div .header {
        padding-top: 75px;
    }
}

@media screen and (max-width: 750px) {
    .search_results_page div .header {
        padding-top: 140px;
    }
}
