/* Single blog posts (single.php, inc/single-post.php). White page, the
   site's column (90% of the window, at most 1170px), title and date,
   the featured image across the column, then the article with Latest
   news beside it. On phones the list follows the article. */

body.single-post,
.single-post .site-content { background: #fff; }

.rhsa-post {
	--rhsa-container: 1170px;
	box-sizing: border-box;
	width: min(var(--rhsa-container), 90%);
	margin: 0 auto;
	padding: 56px 0 64px;
}

.rhsa-post__head { max-width: 820px; margin-bottom: 28px; }
.single-post .rhsa-post__title {
	font-family: var(--rhsa-cond);
	font-weight: 700;
	font-size: 44px;
	line-height: 50px;
	text-transform: uppercase;
	text-wrap: balance;
	color: var(--rhsa-ink);
	margin: 0 0 12px;
}
.rhsa-post__date { display: block; font-size: 14px; color: var(--rhsa-body); }

.rhsa-post__photo { margin: 0; }
.rhsa-post__photo img { display: block; width: 100%; height: auto; border-radius: 6px; }

.rhsa-post__body {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 300px;
	gap: 64px;
	align-items: start;
	margin-top: 44px;
}

/* Blocks marked full or wide width stay in the article column. */
.rhsa-post__article .entry-content > :is(.alignfull, .alignwide) {
	width: auto;
	max-width: 100%;
	margin-left: 0;
	margin-right: 0;
}
.rhsa-post__article .entry-content { padding-bottom: 0; }

/* The article's text follows the site's type scale (typography.css).
   Running text stops at 720px, about 75 characters a line, as on pages
   (layout.css); images and embeds keep the full article column. The cap
   measures the text alone, so a paragraph that pads its own sides keeps
   its length. A section heading gets the same space above it wherever
   it falls (none at the very top). */
.rhsa-post__article .entry-content :is(p.wp-block-paragraph, .wp-block-list, blockquote) { box-sizing: content-box; max-width: 720px; }
.single-post .rhsa-post__article .entry-content > h2 { margin-top: 64px; margin-bottom: 20px; }
.single-post .rhsa-post__article .entry-content > h2:first-child { margin-top: 0; }
.single-post .rhsa-post__article .entry-content > :is(h3, h4) { margin-top: 40px; margin-bottom: 12px; }
.rhsa-post__article .post-navigation {
	margin-top: 48px;
	padding: 34px 20px;
	border-top: 1px solid #e1e8ed;
}
.post-navigation .nav-links { display: flex; }
.post-navigation :is(.nav-previous, .nav-next) { flex: 0 0 50%; min-width: 0; color: var(--rhsa-red); }
.post-navigation .nav-next { text-align: right; }
.post-navigation .nav-previous { border-right: 1px solid #e1e8ed; }
.post-navigation a {
	display: inline-block;
	max-width: 80%;
	margin-top: 2px;
	color: #3a3a3a;
	font-size: 16px;
	font-weight: 500;
	line-height: 16px;
}
.post-navigation a:hover { color: var(--rhsa-red); }
.post-navigation .nav-previous a { margin-left: 2px; padding-right: 20px; }
.post-navigation .nav-next a { padding-left: 20px; }
.rhsa-post-nav__dir svg { width: 14px; height: 14px; fill: currentColor; vertical-align: -0.125em; }
.rhsa-post-nav__dir { display: block; font-size: 0.85em; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; }
.rhsa-post-nav__title {
	display: block;
	margin-top: 8px;
	overflow: hidden;
	font-weight: 400;
	line-height: 1.65;
	white-space: nowrap;
	text-overflow: ellipsis;
}

.rhsa-post__news {
	position: sticky;
	top: calc(var(--rhsa-sticky-top, 0px) + 24px);
	border-left: 3px solid var(--rhsa-red);
	padding-left: 24px;
}
.single-post .rhsa-post__news h2 {
	font-family: var(--rhsa-cond);
	font-weight: 700;
	font-size: 22px;
	line-height: 30px;
	margin: 0 0 6px;
}
.rhsa-post__news ul { list-style: none; margin: 0; padding: 0; }
.rhsa-post__news li { padding: 12px 0; margin: 0; }
.rhsa-post__news li + li { border-top: 1px solid var(--rhsa-line); }
.rhsa-post__news li a {
	display: block;
	font-family: var(--rhsa-cond);
	font-weight: 700;
	font-size: 18px;
	line-height: 1.25;
	color: var(--rhsa-ink);
	text-decoration: none;
	margin-bottom: 4px;
}
.rhsa-post__news li a:hover { color: var(--rhsa-red); text-decoration: underline; }
.rhsa-post__news time { font-size: 14px; color: var(--rhsa-body); }
.rhsa-post__all-news {
	display: inline-block;
	margin-top: 12px;
	font-weight: 700;
	font-size: 15px;
	color: var(--rhsa-red);
	text-decoration: none;
}
.rhsa-post__all-news:hover { text-decoration: underline; }

@media (max-width: 921px) {
	.rhsa-post__body { grid-template-columns: minmax(0, 1fr); gap: 48px; }
	.rhsa-post__news { position: static; }
}
@media (max-width: 600px) {
	.rhsa-post { padding: 40px 0 48px; }
	.single-post .rhsa-post__title { font-size: 32px; line-height: 38px; }
	.rhsa-post__body { margin-top: 32px; }
	.single-post .rhsa-post__article .entry-content > h2 { margin-top: 40px; }
	.single-post .rhsa-post__article .entry-content > :is(h3, h4) { margin-top: 32px; }
}
/* Phones: just the two directions, side by side. */
@media (max-width: 544px) {
	.post-navigation .nav-links { padding: 0 20px; }
	.post-navigation :is(.nav-previous, .nav-next) { text-align: center; }
	.post-navigation a { max-width: none; padding: 0 !important; font-size: 17px; line-height: 17px; }
	.post-navigation .rhsa-post-nav__title { display: none; }
}
