/*
 * Blog article text: what the block editor produces (headings, lists, tables, images, buttons, FAQ blocks and
 * the Blog block patterns), in the site's design. Loads on the blog's pages only.
 *
 * Every rule is written for ".blog-content" (the article's wrapper on the page). In the editor
 * (inc/blog.php) ".blog-content" is replaced by "body", which WordPress turns into the editor's own
 * wrapper, so writing looks like the finished page. Keep rules free of child selectors (">") for that reason.
 * Colours: teal #2CA9A6, deep teal #1F7E7B, tint #EAF7F6, charcoal #333333, muted #555555, border #E2E8F0.
 */

.blog-content {
	color: #333333;
	font-size: 17px;
	line-height: 1.75;
	overflow-wrap: break-word;
}

.blog-content p,
.blog-content ul,
.blog-content ol,
.blog-content figure,
.blog-content blockquote,
.blog-content details,
.blog-content .wp-block-buttons,
.blog-content .wp-block-columns,
.blog-content .wp-block-group,
.blog-content .wp-block-table {
	margin-top: 0;
	margin-bottom: 1.25em;
}

.blog-content h2 {
	margin: 2.2em 0 0.6em;
	font-size: 1.75rem;
	line-height: 1.25;
	font-weight: 800;
	letter-spacing: -0.01em;
	color: #333333;
}

.blog-content h3 {
	margin: 1.8em 0 0.5em;
	font-size: 1.3rem;
	line-height: 1.3;
	font-weight: 700;
	color: #333333;
}

.blog-content h4 {
	margin: 1.6em 0 0.4em;
	font-size: 1.1rem;
	line-height: 1.35;
	font-weight: 700;
	color: #333333;
}

.blog-content a {
	color: #1f7e7b;
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 3px;
}

.blog-content a:hover {
	color: #17605e;
}

.blog-content strong {
	font-weight: 700;
	color: #262626;
}

/* Lists */
.blog-content ul,
.blog-content ol {
	padding-left: 1.4em;
}

.blog-content ul {
	list-style: disc;
}

.blog-content ol {
	list-style: decimal;
}

.blog-content li {
	margin-bottom: 0.45em;
	padding-left: 0.2em;
}

.blog-content li::marker {
	color: #2ca9a6;
	font-weight: 700;
}

/* Quotes */
.blog-content blockquote {
	padding: 1.1em 1.4em;
	border-left: 4px solid #2ca9a6;
	border-radius: 0 1rem 1rem 0;
	background: #eaf7f6;
	color: #333333;
}

.blog-content blockquote p:last-child {
	margin-bottom: 0;
}

.blog-content cite {
	font-size: 14px;
	color: #555555;
}

/* Images */
.blog-content img {
	max-width: 100%;
	height: auto;
	border-radius: 1rem;
}

.blog-content figcaption {
	margin-top: 0.6em;
	font-size: 14px;
	line-height: 1.5;
	color: #555555;
	text-align: center;
}

.blog-content hr {
	margin: 2.5em 0;
	border: 0;
	border-top: 1px solid #e2e8f0;
}

/* Tables: scroll sideways on a phone instead of squeezing */
.blog-content .wp-block-table {
	overflow-x: auto;
}

.blog-content table {
	width: 100%;
	border: 1px solid #e2e8f0;
	border-collapse: separate;
	border-spacing: 0;
	border-radius: 1rem;
	overflow: hidden;
	font-size: 15.5px;
	line-height: 1.5;
}

.blog-content .wp-block-table th,
.blog-content .wp-block-table td,
.blog-content table th,
.blog-content table td {
	padding: 0.8em 1em;
	border: 0;
	border-top: 1px solid #e2e8f0;
	text-align: left;
}

.blog-content table thead th {
	border-top: 0;
	background: #eaf7f6;
	color: #1f7e7b;
	font-weight: 700;
}

.blog-content table tbody tr:nth-child(even) td {
	background: #fafcfc;
}

.blog-content .wp-block-table thead {
	border-bottom: 0;
}

/* Buttons */
.blog-content .wp-block-buttons {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
}

.blog-content .wp-block-button__link {
	display: inline-block;
	padding: 0.8em 1.5em;
	border-radius: 0.75rem;
	background: #1f7e7b;
	color: #ffffff;
	font-size: 16px;
	font-weight: 700;
	line-height: 1.3;
	text-decoration: none;
}

.blog-content .wp-block-button__link:hover {
	background: #17605e;
	color: #ffffff;
}

.blog-content .is-style-outline .wp-block-button__link {
	border: 2px solid #2ca9a6;
	background: transparent;
	color: #1f7e7b;
}

.blog-content .is-style-outline .wp-block-button__link:hover {
	background: #eaf7f6;
	color: #17605e;
}

/* Columns stack on phones */
.blog-content .wp-block-columns {
	display: flex;
	flex-wrap: wrap;
	gap: 1.5rem;
}

.blog-content .wp-block-column {
	flex: 1 1 15rem;
	min-width: 0;
}

/* FAQ / "Details" blocks: a bordered box that opens and closes */
.blog-content details {
	padding: 0 1.2em;
	border: 1px solid #e2e8f0;
	border-radius: 1rem;
	background: #ffffff;
}

.blog-content summary {
	position: relative;
	padding: 1em 1.6em 1em 0;
	font-weight: 700;
	cursor: pointer;
	list-style: none;
}

.blog-content summary::-webkit-details-marker {
	display: none;
}

.blog-content summary::after {
	content: "+";
	position: absolute;
	right: 0;
	top: 50%;
	transform: translateY(-50%);
	color: #2ca9a6;
	font-size: 1.4em;
	font-weight: 700;
}

.blog-content details[open] summary {
	margin-bottom: 0.9em;
	border-bottom: 1px solid #e2e8f0;
}

.blog-content details[open] summary::after {
	content: "\2013";
}

.blog-content details p:last-child {
	margin-bottom: 1em;
}

/* Boxes from the "Blog" block patterns */
.blog-content .ls-takeaways {
	padding: 1.4em 1.6em;
	border: 1px solid rgba(44, 169, 166, 0.35);
	border-radius: 1.25rem;
	background: #eaf7f6;
}

.blog-content .ls-takeaways h3 {
	margin-top: 0;
	color: #1f7e7b;
}

.blog-content .ls-takeaways ul {
	margin-bottom: 0;
}

.blog-content .ls-callout {
	padding: 1.1em 1.4em;
	border-left: 4px solid #2ca9a6;
	border-radius: 0 1rem 1rem 0;
	background: #f6fafa;
}

.blog-content .ls-warning {
	padding: 1.1em 1.4em;
	border: 1px solid #f3d58a;
	border-left: 4px solid #e0a82e;
	border-radius: 0 1rem 1rem 0;
	background: #fff8e6;
}

.blog-content .ls-callout p:last-child,
.blog-content .ls-warning p:last-child {
	margin-bottom: 0;
}

.blog-content .ls-cta {
	padding: 1.75em 2em;
	border-radius: 1.5rem;
	background: linear-gradient(90deg, #2ca9a6, #1f7e7b);
	color: #ffffff;
}

.blog-content .ls-cta h3,
.blog-content .ls-cta p {
	margin-top: 0;
	color: #ffffff;
}

.blog-content .ls-cta a:not(.wp-block-button__link) {
	color: #ffffff;
	text-decoration-color: rgba(255, 255, 255, 0.6);
	font-weight: 600;
}

.blog-content .ls-cta a:not(.wp-block-button__link):hover {
	color: #eaf7f6;
}

.blog-content .ls-cta .wp-block-button__link {
	background: #ffffff;
	color: #1f7e7b;
}

.blog-content .ls-cta .wp-block-button__link:hover {
	background: #eaf7f6;
}

.blog-content .ls-cta .wp-block-buttons {
	margin-bottom: 0;
}

/* "In this article" list, placed inside the text after the first paragraph */
.blog-content .ls-toc {
	margin: 1.75em 0;
	padding: 1.2em 1.5em;
	border: 1px solid #e2e8f0;
	border-radius: 1.25rem;
	background: #f7f9f9;
}

.blog-content .ls-toc-inline {
	display: block;
}

@media (min-width: 1024px) {
	.single .blog-content .ls-toc-inline {
		display: none;
	}
}

.blog-content .ls-toc-title {
	margin: 0 0 0.6em;
	font-size: 13px;
	font-weight: 800;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: #1f7e7b;
}

.blog-content .ls-toc ol {
	margin: 0;
	padding: 0;
	list-style: none;
}

.blog-content .ls-toc li {
	margin: 0 0 0.45em;
	padding: 0;
}

.blog-content .ls-toc li:last-child {
	margin-bottom: 0;
}

.blog-content .ls-toc a {
	color: #333333;
	font-size: 15.5px;
	font-weight: 500;
	text-decoration: none;
}

.blog-content .ls-toc a:hover {
	color: #1f7e7b;
	text-decoration: underline;
}

/* Code */
.blog-content code {
	padding: 0.1em 0.35em;
	border-radius: 0.35rem;
	background: #f4f4f4;
	font-size: 0.9em;
}

/* Page numbers under the article list (assets of the list pages, not article text) */
.blog-pagination .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 2.75rem;
	height: 2.75rem;
	padding: 0 0.9rem;
	border: 1px solid #e2e8f0;
	border-radius: 0.75rem;
	background: #ffffff;
	color: #333333;
	font-size: 15px;
	font-weight: 600;
	text-decoration: none;
}

.blog-pagination a.page-numbers:hover {
	border-color: #2ca9a6;
	color: #1f7e7b;
}

.blog-pagination .page-numbers.current {
	border-color: #1f7e7b;
	background: #1f7e7b;
	color: #ffffff;
}

.blog-pagination .page-numbers.dots {
	border-color: transparent;
	background: transparent;
}
