/* Posts and archives use the same reading palette. */
.zb-article-page, .zb-archive-page {
	--zb-reading-paper: #fbf2e2;
	--zb-reading-ink: #292018;
	--zb-reading-size: 19px;
	--zb-reading-link: #87420d;
	--zb-reading-line: #d7ac6d;
	--zb-reading-inset: #f6e8cf;
	--zb-reading-width: 1180px;
	color: var(--zb-reading-ink);
	background: var(--zb-reading-paper);
}
:is(.zb-article-page, .zb-archive-page) .zb-wrap {
	width: min(var(--zb-reading-width), calc(100% - clamp(30px, 5.7vw, 80px)));
}
.zb-article-page :where(h2,h3,h4,h5,h6), .zb-archive-page :where(h1,h2,h3,h4,h5,h6) { color: var(--zb-reading-ink); }
:is(.zb-article-page, .zb-archive-page) a { color: var(--zb-reading-link); }
:is(.zb-article-page, .zb-archive-page) a:hover { color: #502a0e; }

.zb-archive-page {
	background: linear-gradient(180deg, #c58e4124, transparent 160px), var(--zb-reading-paper);
}
.zb-archive-page .zb-interior-title::after {
	content: "";
	display: block;
	width: 66px;
	height: 3px;
	margin-top: 14px;
	background: #be741b;
}
.zb-archive-description {
	max-width: 72ch;
	margin-top: 22px;
}
.zb-archive-description + .zb-grid-archive {
	padding-top: 22px;
	border-top: 1px solid var(--zb-reading-line);
}
.zb-archive-page .zb-card-archive {
	border-color: var(--zb-reading-line);
	background: var(--zb-reading-inset);
	color: var(--zb-reading-ink);
}
.zb-archive-page .zb-card-inner { color: inherit; }
.zb-archive-page .nav-links { gap: 8px; }
.zb-archive-page .page-numbers {
	min-width: 36px;
	text-align: center;
	border-color: var(--zb-reading-line);
}
.zb-archive-page .page-numbers.current {
	background: #754016;
	border-color: #754016;
	color: #fff4dd;
}

.zb-reading-hero {
	position: relative;
	isolation: isolate;
	background: radial-gradient(ellipse at 80% 46%, #50321c, #160e09 69%);
	color: #fff1d4;
}
.zb-reading-hero-with-image .zb-reading-cover-image {
	position: absolute;
	z-index: -3;
	inset: 0;
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: 58% 51%;
}
.zb-reading-hero-approved {
	background: #160d08;
}
.zb-reading-hero-approved.zb-reading-hero-with-image .zb-reading-cover-image {
	inset-inline: auto max(0px, calc((100% - 1330px) / 2));
	width: min(57%, 645px);
	object-fit: contain;
	object-position: right bottom;
	mask-image: linear-gradient(90deg, transparent, #000 4%, #000 83%, transparent);
}
.zb-reading-hero-approved .zb-reading-hero-inner h1 {
	max-width: min(17ch, 51%);
	overflow-wrap: anywhere;
}
.zb-reading-hero::before, .zb-reading-hero::after {
	content: "";
	position: absolute;
	inset: 0;
	pointer-events: none;
}
.zb-reading-hero::before {
	z-index: -2;
	background: linear-gradient(90deg, #120b07ec 3%, #160c08b7 49%, #10090526 83%);
}
.zb-reading-hero::after {
	z-index: -1;
	top: auto;
	height: clamp(48px, 7vw, 98px);
	background: linear-gradient(180deg, transparent, var(--zb-reading-paper));
}
.zb-reading-hero-inner {
	display: flex;
	min-height: clamp(260px, 28vw, 403px);
	flex-direction: column;
	align-items: flex-start;
	justify-content: center;
	padding-block: 24px clamp(58px, 8vw, 94px);
}
.zb-reading-hero h1 {
	max-width: 17ch;
	color: #fff1d4;
	font-size: clamp(32px, 5.2vw, 67px);
	line-height: 1;
	letter-spacing: -.035em;
	text-shadow: 0 2px 15px #110905a0;
}
.zb-reading-hero h1::after {
	content: "";
	display: block;
	width: 66px;
	height: 3px;
	margin-top: 18px;
	background: #e39a2e;
}
.zb-reading-hero .zb-reading-breadcrumb {
	display: flex;
	flex-wrap: wrap;
	gap: .5em;
	margin-bottom: 16px;
}
.zb-reading-hero a, .zb-reading-hero a:hover { color: #fff0d3; }
.zb-reading-meta { font-size: .86rem; margin: 10px 0 0; color: #f3dfbe; }

.zb-reading-layout {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	align-items: start;
	gap: clamp(24px, 4vw, 50px);
	padding-block: 5px 27px;
}
.zb-reading-layout:not(.zb-reading-with-sidebar), .zb-reading-bottom {
	max-width: 890px;
}
.zb-reading-with-sidebar {
	grid-template-columns: minmax(0, 1fr) minmax(210px, 26%);
}
.zb-reading-paper { min-width: 0; }
.zb-reading-entry {
	font: var(--zb-reading-size)/1.63 Georgia, "Times New Roman", serif;
}
.zb-reading-entry h2, .zb-reading-entry h3 { scroll-margin-top: 38px; }
.zb-reading-entry h2 {
	margin-top: 1.14em;
	font-size: clamp(25px, 3vw, 39px);
	line-height: 1.08;
	letter-spacing: -.025em;
}
.zb-reading-entry h3 {
	font-size: clamp(22px, 2.5vw, 29px);
	line-height: 1.12;
}
.zb-reading-entry h2::after {
	content: "";
	display: block;
	width: 56px;
	height: 2px;
	margin-top: .28em;
	background: #ce811d;
}
.zb-reading-entry .is-style-zb-brass-note h2::after { display: none; }
.zb-reading-entry :where(h2,h3) + p { margin-top: .45em; }
.zb-reading-entry .is-style-zb-brass-note :where(h2,h3) { margin-block: 0; font-size: 1.16em; }
.zb-reading-entry .is-style-zb-brass-note > p { margin-block: .23em 0; }
.zb-reading-entry figure { margin-inline: 0; }
.zb-reading-entry :where(figure img, .wp-caption img) { display: block; border-radius: 4px; }
.zb-reading-entry :where(figcaption, .wp-caption-text) {
	margin: 6px 0 0;
	color: #654d39;
	font-size: .85em;
}
.zb-reading-entry blockquote {
	margin-inline: 0;
	padding: .6em 1em;
	background: var(--zb-reading-inset);
	border-inline-start: 3px solid #c47a25;
}
.zb-reading-entry blockquote p { margin-block: 0; }
.zb-reading-entry :where(pre,code) { background: #3a201113; }
.zb-reading-entry :where(th,td) { border-color: var(--zb-reading-line); }
.zb-reading-entry th { background: var(--zb-reading-inset); }
.zb-reading-entry .zb-reading-toc, .zb-reading-entry :where(#ez-toc-container, #toc_container, .lwptoc_i, .wp-block-table-of-contents) {
	padding: 12px 18px;
	border: 1px solid var(--zb-reading-line);
	border-radius: 5px;
	background: var(--zb-reading-inset);
	color: var(--zb-reading-ink);
}
.zb-reading-toc > strong { display: block; font-size: 1.12em; }
.zb-reading-toc ol { margin: .1em 0; padding-inline-start: 1.25em; }
.zb-reading-toc li::marker { color: #8a430b; }
.zb-reading-toc .zb-toc-subitem { margin-inline-start: 1em; }
.zb-reading-layout .zb-post-tags a { border-color: var(--zb-reading-line); }

.zb-reading-sidebar {
	position: static;
	align-self: start;
	align-content: start;
	align-items: start;
}
.zb-reading-sidebar :is(.widget, .zb-rubrics) {
	margin: 0;
	background: var(--zb-reading-inset);
	border: 1px solid #ebd6b1;
	border-radius: 6px;
	color: var(--zb-reading-ink);
}
.zb-reading-sidebar .widget { padding: 14px 17px; }
.zb-reading-sidebar .zb-rubric-link { color: var(--zb-reading-ink); }
.zb-reading-sidebar .zb-rubric-link:hover { color: var(--zb-reading-link); }
.zb-reading-sidebar .zb-rubric-link .zb-icon { color: var(--zb-reading-link); }
.zb-reading-sidebar .zb-panel-title { font-size: clamp(20px, 2.1vw, 26px); }
.zb-reading-sidebar .widget ul { padding-inline-start: 1.4em; margin-block: .45em 0; }
.zb-reading-sidebar .widget .zb-search input { color: var(--zb-reading-ink); }
.zb-reading-sidebar .widget .zb-search input::placeholder { color: #6b5541; }
.zb-reading-sidebar .widget > :last-child { margin-block-end: 0; }

.zb-article-actions {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-start;
	gap: 12px 19px;
	margin-top: 22px;
	padding-block: 14px;
	border-top: 1px solid var(--zb-reading-line);
}
.zb-article-share {
	display: flex;
	flex: 1 1 300px;
	align-items: center;
	flex-wrap: wrap;
	gap: 7px;
}
.zb-article-share strong { font-size: .88rem; }
.zb-article-actions .zb-article-action {
	display: inline-flex;
	align-items: center;
	gap: .4em;
	min-height: 38px;
	padding: 5px 10px;
	border: 1px solid var(--zb-reading-line);
	border-radius: 6px;
	background: var(--zb-reading-inset);
	color: #622f10;
	font-size: .87rem;
	text-decoration: none;
}
.zb-article-actions .zb-article-action:hover { background: #f9dba9; color: #502a0e; }
.zb-article-action:disabled { cursor: wait; }
.zb-article-action .zb-icon { width: 1.15em; height: 1.15em; color: currentColor; }
.zb-article-action[aria-pressed="true"] { background: #f7d6a4; border-color: #a65c22; }
.zb-article-action[aria-pressed="true"] .zb-icon { fill: currentColor; }
.zb-like-count { font-variant-numeric: tabular-nums; }
.zb-article-action-status { font-size: .8rem; color: var(--zb-reading-ink); }
.zb-article-share .zb-article-action-status { flex-basis: 100%; }
.zb-article-action-status:not(:empty) { margin-top: 4px; }
.zb-article-action-status:empty { height: 0; margin: 0; }

.zb-reading-related { padding: 24px 0 17px; border-top: 1px solid var(--zb-reading-line); }
.zb-reading-related h2 { margin-bottom: 12px; font-size: clamp(24px, 3vw, 37px); }
.zb-grid-related { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--zb-gap); }
.zb-card-related { background: var(--zb-reading-inset); border-color: var(--zb-reading-line); }
.zb-article-page .zb-card-related .zb-card-inner { color: var(--zb-reading-ink); }
.zb-card-related .zb-card-title { color: var(--zb-reading-ink); }

.zb-reading-bottom { padding-bottom: clamp(28px, 5vw, 58px); }
.zb-reading-comments .zb-comments {
	border-top: 1px solid var(--zb-reading-line);
	padding-top: 17px;
}
.zb-reading-comments .zb-comment-list .comment-body { border-color: var(--zb-reading-line); }
.zb-reading-comments .comment-form input:not([type=checkbox]):not([type=submit]),
.zb-reading-comments .comment-form textarea {
	background: #fff8ec;
	color: var(--zb-reading-ink);
	border-color: var(--zb-reading-line);
}

@media (max-width: 820px) {
	.zb-reading-with-sidebar { grid-template-columns: 1fr; }
	.zb-reading-sidebar:not(.zb-hide-small) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
	.zb-reading-sidebar:not(.zb-hide-small) { grid-template-columns: 1fr; }
	.zb-reading-entry { font-size: clamp(17px, 4.6vw, var(--zb-reading-size)); }
	.zb-reading-hero h1 { max-width: 19ch; }
	.zb-reading-hero-approved .zb-reading-hero-inner h1 { max-width: min(19ch, 62%); }
	.zb-reading-hero-approved.zb-reading-hero-with-image .zb-reading-cover-image {
		width: 68%;
		object-position: right center;
	}
	.zb-reading-hero-inner { min-height: 252px; padding-block: 21px 54px; }
	.zb-reading-hero::before { background: linear-gradient(90deg, #140b07ef, #1a0e09b5 67%, #10080566); }
	.zb-grid-related { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
