:root {
	--font-heading: 'Playfair Display', serif;
	--font-body: 'Open Sans', sans-serif;
	--cream: #f6f2e9;
	--beige: #e9e4d8;
	--gold: #e9a825;
	--dark: #5a5a5a;
	--light: #ffffff;
	--border: #ded7c9;
	--book-1-theme: #e79d19;
	--book-2-theme: #357cbd;
	--book-3-theme: #44bbf6;
	--book-4-theme: #4f723c;
}

* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

html {
	scroll-behavior: smooth;
	scroll-padding-top: 75px;
}

body {
	font-family: var(--font-body);
	color: var(--light);
	background: var(--cream);
	min-height: 100vh;
	min-height: 100dvh;
}

body a {
	color: var(--gold);
}

/* Navigation */

header {
	position: sticky;
	top: 0;
	z-index: 1000;
	background: var(--light);
	backdrop-filter: blur(12px);
	border-bottom: 6px solid var(--border);
}

nav {
	max-width: 1400px;
	height: 72px;
	margin: auto;
	padding: 0 30px;
	display: flex;
	align-items: center;
	justify-content: space-between;
}

.logo {
	font-size: 24px;
	font-weight: 700;
	color: var(--gold);
	letter-spacing: 1px;
	text-decoration: none;
}

.logo:hover {
	color: color-mix(in srgb, var(--gold), black 20%);
}

.nav-links {
	display: flex;
	list-style: none;
	gap: 22px;
	text-shadow: 0 1px 0 #aaaaaa;
}

.nav-links a {
	color: var(--gold);
	text-decoration: none;
	font-size: 14px;
	transition: color .3s;
}

.nav-links a:hover {
	color: color-mix(in srgb, var(--gold), black 20%);
}

.menu-toggle {
	display: none;
	background: none;
	border: none;
	font-size: 28px;
	color: var(--dark);
	cursor: pointer;
}

.btt-btn {
	display: none;
	position: fixed;
	bottom: 28px;
	right: 28px;
	z-index: 1000;
	color: var(--gold);
	background-color: rgb(0 0 0 / 0.25);
	height: 48px;
	width: 48px;
	border-radius: 0.5rem;
	font-size: 48px;
	font-family: var(--font-heading);
}

.btt-btn.show {
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
}

/* Book sections */

.book-section {
	min-height: 72vh;
	display: flex;
	flex-direction: row;
	align-items: center;
	justify-content: center;
	background-repeat: no-repeat;
	background-position: center;
	background-size: cover;
	position: relative;
	color: white;
	padding: 1.4rem;
}

.eyebrow {
	text-transform: uppercase;
	letter-spacing: 4px;
	font-size: 16px;
	margin-bottom: 0.5rem;
	margin-top: 1.5rem;
}

.book-section h1 {
	font-family: var(--font-heading);
	font-size: clamp(48px, 48px, 24px);
	line-height: 1.1;
	font-weight: normal;
	margin-bottom: 25px;
}

.book-section h2 {
	font-size: 16px;
	font-weight: 700;
}

.book-section p {
	font-size: 100%;
	line-height: 1.6;
}

.book-description {
	position: relative;
	padding-right: 5rem;
	max-width: 58ch;
}

.book-description ul {
	list-style-type: none;
	font-size: 14px;
	margin-top: 1.4em;
	margin-left: 1em;
}

.book-description li {
	margin-bottom: 0.4em;
}

.book-buttons {
	margin-top: 1.4rem;
	display: flex;
	flex-direction: row;
	align-items: center;
	justify-content: center;
	gap: 1.5rem;
}

.btn {
	display: inline-block;
	padding: 12px 24px;
	border-radius: 0.6em;
	text-decoration: none;
	font-size: 14px;
	letter-spacing: 1px;
	transition: .3s;
	color: var(--light);
}

.btn-1 {
	background: var(--book-1-theme);
}

.btn-1:hover {
	background: color-mix(in srgb, var(--book-1-theme), black 20%);
}

.btn-2 {
	background: var(--book-2-theme);
}

.btn-2:hover {
	background: color-mix(in srgb, var(--book-2-theme), black 20%);
}

.btn-3 {
	background: var(--book-3-theme);
}

.btn-3:hover {
	background: color-mix(in srgb, var(--book-3-theme), black 20%);
}

.btn-4 {
	background: var(--book-4-theme);
}

.btn-4:hover {
	background: color-mix(in srgb, var(--book-4-theme), black 20%);
}

/* Individual book backgrounds */

#book1 {
	background-color: color-mix(in srgb, var(--book-1-theme), white 40%);
	background-image: url('book1-background.jpg');
}

#book2 {
	background-color: color-mix(in srgb, var(--book-2-theme), white 40%);
	background-image: url('book2-background.jpg');
}

#book3 {
	background-color: color-mix(in srgb, var(--book-3-theme), white 40%);
	background-image: url('book3-background.jpg');
}

#book4 {
	background-color: color-mix(in srgb, var(--book-4-theme), white 70%);
	background-image: url('book4-background.jpg');
}

/* Commentary */

.commentary {
	color: var(--dark);
	background: var(--light);
	padding: 60px 25px;
	text-align: justify;
}

.commentary-inner {
	max-width: 96ch;
	margin-left: auto;
	margin-right: auto;
}

.commentary h2 {
	font-size: 36px;
	font-weight: normal;
	margin-bottom: 25px;
	text-transform: uppercase;
	text-align: right;
}

.commentary p {
	line-height: 1.8;
	font-size: 16px;
	font-style: italic;
}

.commentary .credit {
	margin: 1rem 2rem;
	text-align: left;
}

/* About the author */

.bio {
	color: var(--dark);
	background: var(--beige);
	padding: 60px 25px;
	text-align: justify;
}

.bio-inner {
	max-width: 96ch;
	margin-left: auto;
	margin-right: auto;
}

.bio h2 {
	font-size: 36px;
	font-weight: normal;
	margin-bottom: 25px;
	text-transform: uppercase;
	text-align: left;
}

.bio p {
	line-height: 1.8;
	font-size: 16px;
}

.bio-picture {
	/*float: left;*/
	margin-right: 1em;
	max-width: 150px;
	max-height: 150px;
}

/* Footer */

footer {
	position: sticky;
	top: 100vh;
	top: 100dvh;
	background: var(--dark);
	color: var(--light);
	text-align: center;
	padding: 24px;
	font-size: 12px;
	line-height: 2;
	border-top: 6px solid var(--border);
}

/* Util */

.flex-h {
	display: flex;
	flex-direction: row;
}

.flex-v {
	display: flex;
	flex-direction: column;
}

.title {
	font-size: 48px;
	padding-top: 1em;
	text-align: center;
}

.error {
	text-align: center;
	color: var(--dark);
	margin: 4em auto;
}

.error h1 {
	font-weight: 800;
	font-size: 3.5rem;
}

.error .desc {
	font-size: 1em;
}

.error .links {
	margin-top: 1em;
	line-height: 2;
}

.error .links a {
	color: color-mix(in srgb, var(--gold), black 50%);
}

/* Blog */

.blog-entry {
	max-width: 124ch;
	margin-left: auto;
	margin-right: auto;
	padding-left: 1em;
	padding-right: 1em;
	padding-bottom: 1.6em;
	margin-bottom: 1.6em;
	color: var(--dark);
	border-bottom: 1px solid var(--border);
}

.blog-entry h1 {
	color: var(--gold);
	font-size: 32px;
	font-weight: 600;
	margin-bottom: 0.6rem;
}

.blog-entry h1:hover {
	color: color-mix(in srgb, var(--gold), black 20%);
}

.blog-entry h2 {
	font-size: 12px;
	font-weight: 400;
	font-style: italic;
	margin-bottom: 1rem;
}

.blog-entry h3 {
	font-size: 14px;
	font-weight: 400;
	margin-bottom: 0.6rem;
}

.blog-body {
	font-size: 14px;
	text-align: justify;
	line-height: 1.7;
}

.blog-body p {
	margin-bottom: 1em;
}

.blog-body p:first-of-type:first-letter {
	font-weight: bold;
}

.blog-body ol {
	margin-left: 2.8em;
	margin-bottom: 1em;
}

/* Mobile navigation */

@media (max-width: 850px) {
	.menu-toggle {
		display: block;
	}

	.nav-links {
		display: none;
		position: absolute;
		top: 75px;
		left: 0;
		width: 100%;
		flex-direction: column;
		gap: 0;
		background: var(--cream);
		padding: 10px 25px 20px;
		box-shadow: 0 8px 12px rgba(0,0,0,.1);
	}

	.nav-links.active {
		display: flex;
	}

	.nav-links a {
		display: block;
		padding: 14px 5px;
	}
	
	.nav-links li:hover {
		background-color: color-mix(in srgb, var(--cream), black 10%);
	}

	.book-section {
		min-height: 100vh;
		padding: 65px 8%;
		background-position: center;
		flex-direction: column-reverse;
	}
	
	.book-description {
		padding-left: 0;
		padding-right: 0;
	}
	
	.book-buttons {
		flex-direction: column;
	}
}

@media (max-width: 480px) {
	nav {
		padding: 0 20px;
	}

	.logo {
		font-size: 20px;
	}

	.book-section {
		min-height: 100vh;
	}

	.book-section h1 {
		font-size: 42px;
	}
	
	.book-description {
		/*width: 100%;*/
		padding-left: 0;
		padding-right: 0;
	}

	.intro, .author, .contact {
		padding: 75px 22px;
	}

	.intro h2, .author h2, .contact h2 {
		font-size: 32px;
	}
}