/* ==========================================================================
   Home Stewards: single blog post styles
   Loaded only on single posts by inc/hs-blog-enhancements.php
   Scope: body.hs-blog .et-l--post (the post's own Divi layout)
   Contrast (WCAG AA, checked): text #472d25 on #fff 12.6:1, on #f6f2ec 11.3:1;
   teal #026072 on #fff 7.2:1, on #f6f2ec 6.5:1; #fff on #026072 7.2:1
   ========================================================================== */

.hs-blog {
	--hs-text: #472d25;
	--hs-text-soft: #5c463e;
	--hs-accent: #026072;
	--hs-accent-dark: #014553;
	--hs-surface: #f6f2ec;
	--hs-border: #e5ddd2;
	--hs-radius: 10px;
	--hs-measure: 760px;
}

/* ---- Hero (Theme Builder post title over featured image) ---------------
   Dark scrim so the white title and date meta stay legible on any photo. */
.hs-blog .et_pb_fullwidth_post_title_0_tb_body::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 1;
	pointer-events: none;
	background: linear-gradient(180deg, rgba(20, 14, 12, 0.35) 0%, rgba(20, 14, 12, 0.55) 55%, rgba(20, 14, 12, 0.7) 100%);
}

.hs-blog .et_pb_fullwidth_post_title_0_tb_body .et_pb_title_container {
	position: relative;
	z-index: 2;
}

.hs-blog .et_pb_fullwidth_post_title_0_tb_body .et_pb_title_meta_container,
.hs-blog .et_pb_fullwidth_post_title_0_tb_body .et_pb_title_meta_container a {
	color: #fff !important;
	font-weight: 600;
	text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
}

/* ---- Reading column ---------------------------------------------------- */
.hs-blog .et-l--post .et_pb_row {
	width: 90%;
	max-width: var(--hs-measure);
}

.hs-blog .et-l--post .et_pb_text_inner {
	color: var(--hs-text);
	font-size: 18px;
	line-height: 1.75;
	font-weight: 400;
}

.hs-blog .et-l--post .et_pb_text_inner p {
	padding-bottom: 0;
	margin: 0 0 1.25em;
}

/* Stray block-editor comments leave empty paragraphs behind */
.hs-blog .et-l--post .et_pb_text_inner p:empty {
	display: none;
}

/* First paragraph reads as a lede */
.hs-blog .et-l--post .et_pb_text_0 .et_pb_text_inner > p:first-of-type {
	font-size: 20px;
	line-height: 1.65;
}

/* ---- Headings ---------------------------------------------------------- */
.hs-blog .et-l--post .et_pb_text_inner h2 {
	color: var(--hs-text);
	font-size: 30px;
	line-height: 1.25;
	font-weight: 600;
	margin: 1.9em 0 0.6em;
	padding: 0;
	text-align: left;
	scroll-margin-top: 120px; /* clears the fixed Divi header on jump links */
}

.hs-blog .et-l--post .et_pb_text_inner h2::before {
	content: "";
	display: block;
	width: 48px;
	height: 3px;
	margin-bottom: 14px;
	border-radius: 2px;
	background: var(--hs-accent);
}

.hs-blog .et-l--post .et_pb_text_inner h3 {
	color: var(--hs-text);
	font-size: 22px;
	line-height: 1.35;
	font-weight: 600;
	margin: 1.6em 0 0.5em;
	padding: 0;
	scroll-margin-top: 120px;
}

.hs-blog .et-l--post .et_pb_text_inner h2 b,
.hs-blog .et-l--post .et_pb_text_inner h2 strong {
	font-weight: inherit;
}

/* ---- Links ------------------------------------------------------------- */
.hs-blog .et-l--post .et_pb_text_inner a {
	color: var(--hs-accent);
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 3px;
	transition: color 0.15s ease;
}

.hs-blog .et-l--post .et_pb_text_inner a:hover,
.hs-blog .et-l--post .et_pb_text_inner a:focus {
	color: var(--hs-accent-dark);
	text-decoration-thickness: 2px;
}

/* ---- Lists ------------------------------------------------------------- */
.hs-blog .et-l--post .et_pb_text_inner ul,
.hs-blog .et-l--post .et_pb_text_inner ol {
	margin: 0 0 1.4em;
	padding: 0 0 0 1.4em;
	font-size: inherit;
	line-height: 1.7;
}

.hs-blog .et-l--post .et_pb_text_inner li {
	font-size: inherit;
}

.hs-blog .et-l--post .et_pb_text_inner ul {
	list-style: none;
	padding-left: 0;
}

.hs-blog .et-l--post .et_pb_text_inner ul > li {
	position: relative;
	padding-left: 1.6em;
	margin: 0 0 0.55em;
}

.hs-blog .et-l--post .et_pb_text_inner ul > li::before {
	content: "";
	position: absolute;
	left: 0.25em;
	top: 0.68em;
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: var(--hs-accent);
}

.hs-blog .et-l--post .et_pb_text_inner ol > li {
	margin: 0 0 0.55em;
	padding-left: 0.3em;
}

.hs-blog .et-l--post .et_pb_text_inner ol > li::marker {
	color: var(--hs-accent);
	font-weight: 700;
}

/* Paragraphs nested in list items (block editor paste) caused the big gaps */
.hs-blog .et-l--post .et_pb_text_inner li > p {
	margin: 0;
	padding: 0;
}

/* ---- Tables ------------------------------------------------------------ */
.hs-blog .et-l--post .et_pb_text_inner table {
	width: 100%;
	margin: 0.5em 0 1.8em;
	border: 1px solid var(--hs-border);
	border-collapse: separate;
	border-spacing: 0;
	border-radius: var(--hs-radius);
	overflow: hidden;
	font-size: 16px;
	line-height: 1.55;
}

.hs-blog .et-l--post .et_pb_text_inner th {
	background: var(--hs-accent);
	color: #fff;
	text-align: left;
	font-weight: 600;
	padding: 12px 16px;
	border: 0;
}

.hs-blog .et-l--post .et_pb_text_inner th strong {
	color: #fff;
}

.hs-blog .et-l--post .et_pb_text_inner td {
	padding: 12px 16px;
	border: 0;
	border-top: 1px solid var(--hs-border);
	color: var(--hs-text);
	vertical-align: top;
}

.hs-blog .et-l--post .et_pb_text_inner tbody tr:nth-child(even) td {
	background: var(--hs-surface);
}

.hs-blog .et-l--post .et_pb_text_inner td:first-child {
	font-weight: 600;
}

@media (max-width: 640px) {
	.hs-blog .et-l--post .et_pb_text_inner table {
		display: block;
		overflow-x: auto;
		-webkit-overflow-scrolling: touch;
	}
	.hs-blog .et-l--post .et_pb_text_inner th,
	.hs-blog .et-l--post .et_pb_text_inner td {
		min-width: 150px;
	}
}

/* ---- Quotes, images, rules -------------------------------------------- */
.hs-blog .et-l--post .et_pb_text_inner blockquote {
	margin: 1.6em 0;
	padding: 18px 22px;
	border-left: 4px solid var(--hs-accent);
	background: var(--hs-surface);
	border-radius: 0 var(--hs-radius) var(--hs-radius) 0;
	color: var(--hs-text);
	font-size: 19px;
}

.hs-blog .et-l--post .et_pb_text_inner blockquote p:last-child {
	margin-bottom: 0;
}

.hs-blog .et-l--post .et_pb_text_inner img {
	border-radius: var(--hs-radius);
	height: auto;
}

.hs-blog .et-l--post .et_pb_text_inner figcaption {
	color: var(--hs-text-soft);
	font-size: 14px;
	margin-top: 8px;
	text-align: center;
}

.hs-blog .et-l--post .et_pb_text_inner hr {
	border: 0;
	border-top: 1px solid var(--hs-border);
	margin: 2.4em 0;
}

/* ---- Table of contents ------------------------------------------------- */
.hs-blog .hs-toc {
	margin: 1.8em 0 2.2em;
	padding: 22px 26px 18px;
	background: var(--hs-surface);
	border: 1px solid var(--hs-border);
	border-left: 4px solid var(--hs-accent);
	border-radius: var(--hs-radius);
}

.hs-blog .et-l--post .et_pb_text_inner .hs-toc__title {
	margin: 0 0 10px;
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--hs-accent);
}

.hs-blog .et-l--post .et_pb_text_inner .hs-toc__list {
	margin: 0;
	padding-left: 1.3em;
	font-size: 16px;
	line-height: 1.5;
	columns: 2 260px;
	column-gap: 32px;
}

.hs-blog .et-l--post .et_pb_text_inner .hs-toc__list li {
	margin: 0 0 8px;
	break-inside: avoid;
}

.hs-blog .et-l--post .et_pb_text_inner .hs-toc__list a {
	color: var(--hs-text);
	text-decoration: none;
}

.hs-blog .et-l--post .et_pb_text_inner .hs-toc__list a:hover,
.hs-blog .et-l--post .et_pb_text_inner .hs-toc__list a:focus {
	color: var(--hs-accent);
	text-decoration: underline;
}

/* ---- FAQ accordion ----------------------------------------------------- */
.hs-blog .hs-faq {
	margin: 2.4em 0 1em;
}

.hs-blog .et-l--post .et_pb_text_inner .hs-faq__title {
	margin-top: 0;
	scroll-margin-top: 120px;
}

.hs-blog .hs-faq__list {
	border: 1px solid var(--hs-border);
	border-radius: var(--hs-radius);
	overflow: hidden;
	background: #fff;
}

.hs-blog .hs-faq__item {
	border-top: 1px solid var(--hs-border);
	scroll-margin-top: 120px;
}

.hs-blog .hs-faq__item:first-child {
	border-top: 0;
}

.hs-blog .hs-faq__q {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	padding: 18px 22px;
	cursor: pointer;
	list-style: none;
	background: #fff;
	transition: background-color 0.15s ease;
}

.hs-blog .hs-faq__q::-webkit-details-marker {
	display: none;
}

.hs-blog .hs-faq__q:hover {
	background: var(--hs-surface);
}

.hs-blog .hs-faq__q:focus-visible {
	outline: 3px solid var(--hs-accent);
	outline-offset: -3px;
}

.hs-blog .et-l--post .et_pb_text_inner .hs-faq__q-text {
	margin: 0;
	padding: 0;
	font-size: 19px;
	line-height: 1.4;
	font-weight: 600;
	color: var(--hs-text);
}

/* Plus / minus icon */
.hs-blog .hs-faq__icon {
	position: relative;
	flex: 0 0 28px;
	width: 28px;
	height: 28px;
	border-radius: 50%;
	border: 2px solid var(--hs-accent);
	transition: background-color 0.15s ease, transform 0.2s ease;
}

.hs-blog .hs-faq__icon::before,
.hs-blog .hs-faq__icon::after {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: 12px;
	height: 2px;
	margin: -1px 0 0 -6px;
	background: var(--hs-accent);
	border-radius: 1px;
	transition: transform 0.2s ease, background-color 0.15s ease;
}

.hs-blog .hs-faq__icon::after {
	transform: rotate(90deg);
}

.hs-blog .hs-faq__item[open] > .hs-faq__q {
	background: var(--hs-surface);
}

.hs-blog .hs-faq__item[open] .hs-faq__icon {
	background: var(--hs-accent);
}

.hs-blog .hs-faq__item[open] .hs-faq__icon::before,
.hs-blog .hs-faq__item[open] .hs-faq__icon::after {
	background: #fff;
}

.hs-blog .hs-faq__item[open] .hs-faq__icon::after {
	transform: rotate(0deg);
}

.hs-blog .hs-faq__a {
	padding: 4px 22px 20px;
	background: var(--hs-surface);
	color: var(--hs-text);
	font-size: 17px;
	line-height: 1.7;
}

.hs-blog .et-l--post .et_pb_text_inner .hs-faq__a p:last-child,
.hs-blog .et-l--post .et_pb_text_inner .hs-faq__a ul:last-child,
.hs-blog .et-l--post .et_pb_text_inner .hs-faq__a ol:last-child {
	margin-bottom: 0;
}

@media (prefers-reduced-motion: reduce) {
	.hs-blog .hs-faq__q,
	.hs-blog .hs-faq__icon,
	.hs-blog .hs-faq__icon::before,
	.hs-blog .hs-faq__icon::after {
		transition: none;
	}
}

/* ---- Mobile ------------------------------------------------------------ */
@media (max-width: 767px) {
	.hs-blog .et-l--post .et_pb_text_inner {
		font-size: 17px;
	}
	.hs-blog .et-l--post .et_pb_text_0 .et_pb_text_inner > p:first-of-type {
		font-size: 18px;
	}
	.hs-blog .et-l--post .et_pb_text_inner h2 {
		font-size: 25px;
	}
	.hs-blog .et-l--post .et_pb_text_inner h3 {
		font-size: 20px;
	}
	.hs-blog .hs-toc {
		padding: 18px 18px 12px;
	}
	.hs-blog .hs-faq__q {
		padding: 16px 16px;
	}
	.hs-blog .et-l--post .et_pb_text_inner .hs-faq__q-text {
		font-size: 17px;
	}
	.hs-blog .hs-faq__a {
		padding: 2px 16px 18px;
	}
}

/* ---- Comments removed ---------------------------------------------------
   PHP strips the Divi comments module; these catch any cached output and
   collapse the now-empty Theme Builder section so no blank gap is left. */
.hs-blog .et_pb_comments_module,
.hs-blog #comment-wrap {
	display: none !important;
}

.hs-blog .et-l--body .et_pb_section:not(:has(.et_pb_module)) {
	display: none;
}
