/**
 * Nexza Post Body widget, plus the
 * Nexza block patterns writers use inside posts.
 */

.nx-pbody {
	display: grid;
	grid-template-columns: 260px minmax(0, 1fr);
	gap: clamp(32px, 5vw, 80px);
	align-items: start;
}

/* Side column */
.nx-pside {
	position: sticky;
	top: 110px;
	display: flex;
	flex-direction: column;
	gap: 28px;
	min-width: 0;
}

.nx-toc {
	display: flex;
	flex-direction: column;
	gap: 2px;
	margin-top: 18px;
	border-left: 1px solid var(--nx-line-2);
}

.nx-toc a {
	margin-left: -1px;
	padding: 8px 0 8px 16px;
	border-left: 2px solid transparent;
	font-size: 15px;
	line-height: 1.35;
	color: var(--nx-muted-dark);
	transition: color .3s, border-color .3s;
}

.nx-toc a:hover,
.nx-toc a:focus-visible,
.nx-toc a.is-on {
	border-left-color: var(--nx-copper);
	color: var(--nx-sand);
}

.nx-sidecard {
	padding: 22px;
	border: 1px solid var(--nx-line-2);
	border-radius: 18px;
	background: var(--nx-card);
}

.nx-sidecard h2 {
	margin: 0 0 8px;
	font-size: 18px;
	letter-spacing: -.01em;
	line-height: 1.25;
	color: var(--nx-sand);
}

.nx-sidecard p {
	margin: 0 0 18px;
	font-size: 14px;
	color: var(--nx-muted-dark);
}

.nx-sidecard .nx-btn {
	height: 48px;
	padding-left: 20px;
	font-size: 13px;
}

.nx-sidecard .nx-btn .nx-ar {
	width: 34px;
	height: 34px;
}

.nx-share {
	display: flex;
	gap: 10px;
	margin-top: 18px;
}

.nx-share a {
	display: grid;
	place-items: center;
	width: 44px;
	height: 44px;
	border: 1px solid var(--nx-line-2);
	border-radius: 50%;
	font-size: 12px;
	font-weight: 700;
	color: var(--nx-sand);
	transition: background-color .3s, border-color .3s, color .3s;
}

.nx-share a:hover,
.nx-share a:focus-visible {
	background: var(--nx-copper);
	border-color: var(--nx-copper);
	color: var(--nx-ink);
}

/* Article text */
.nx-prose {
	max-width: 760px;
	min-width: 0;
	font-size: 19px;
	line-height: 1.75;
	color: var(--nx-muted-dark);
}

.nx-prose > :first-child {
	margin-top: 0;
}

.nx-prose p {
	margin: 0 0 1.2em;
}

.nx-prose h2 {
	margin: 48px 0 18px;
	font-size: clamp(26px, 2.6vw, 38px);
	letter-spacing: -.025em;
	line-height: 1.1;
	color: var(--nx-sand);
	scroll-margin-top: 110px;
}

.nx-prose h3 {
	margin: 36px 0 14px;
	font-size: clamp(21px, 1.8vw, 26px);
	letter-spacing: -.02em;
	line-height: 1.2;
	color: var(--nx-sand);
}

.nx-prose a:not(.nx-svccard):not(.wp-element-button) {
	color: var(--nx-sand);
	text-decoration: underline;
	text-decoration-color: var(--nx-copper);
	text-underline-offset: 4px;
}

.nx-prose a:not(.nx-svccard):not(.wp-element-button):hover {
	color: var(--nx-ember);
}

.nx-prose ul,
.nx-prose ol {
	margin: 0 0 1.4em;
	padding-left: 1.3em;
}

.nx-prose li {
	margin-bottom: .4em;
}

.nx-prose li::marker {
	color: var(--nx-copper);
}

.nx-prose strong {
	color: var(--nx-sand);
}

.nx-prose img,
.nx-prose figure img {
	height: auto;
	border-radius: var(--nx-radius-card);
}

.nx-prose figure {
	margin: 36px 0;
}

.nx-prose figcaption {
	margin-top: 10px;
	font-size: 14px;
	color: var(--nx-taupe);
}

/* Pattern: Key takeaways */
.nx-prose .nx-takeaways {
	margin: 0 0 40px;
	padding: 26px 28px;
	border: 1px solid var(--nx-line-2);
	border-left: 3px solid var(--nx-copper);
	border-radius: 14px;
	background: var(--nx-card);
}

.nx-prose .nx-takeaways h3 {
	margin: 0 0 14px;
	font-size: 14px;
	letter-spacing: .12em;
	text-transform: uppercase;
	color: var(--nx-copper);
}

.nx-prose .nx-takeaways ul {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin: 0;
	padding-left: 20px;
	font-size: 17px;
	line-height: 1.55;
	color: var(--nx-sand);
}

/* Pattern: Call-to-action box */
.nx-prose .nx-inlinecta {
	margin: 44px 0;
	padding: clamp(24px, 3vw, 36px);
	border: 1px solid rgba(255, 90, 31, .45);
	border-radius: 22px;
	background: linear-gradient(135deg, rgba(255, 90, 31, .16), rgba(255, 90, 31, .04));
}

.nx-prose .nx-inlinecta h3 {
	margin: 0 0 10px;
	font-size: clamp(22px, 2vw, 30px);
	letter-spacing: -.02em;
	line-height: 1.15;
}

.nx-prose .nx-inlinecta p {
	font-size: 16px;
}

.nx-prose .wp-block-button__link {
	display: inline-flex;
	align-items: center;
	height: 56px;
	padding: 0 26px;
	border-radius: var(--nx-radius-pill);
	background: var(--nx-copper);
	font-size: 14px;
	font-weight: 700;
	letter-spacing: .08em;
	text-transform: uppercase;
	text-decoration: none;
	color: var(--nx-ink);
	transition: background-color .3s;
}

.nx-prose .wp-block-button__link:hover {
	background: var(--nx-ember);
}

/* Pattern: Pull quote (and plain quotes) */
.nx-prose blockquote {
	margin: 36px 0;
	padding-left: 24px;
	border-left: 3px solid var(--nx-copper);
	font-size: var(--nx-mid);
	letter-spacing: -.02em;
	line-height: 1.2;
	color: var(--nx-sand);
}

.nx-prose blockquote p {
	margin: 0;
}

.nx-prose blockquote cite {
	display: block;
	margin-top: 14px;
	font-size: 15px;
	font-style: normal;
	color: var(--nx-taupe);
}

/* Pattern: FAQ (details blocks) */
.nx-prose details {
	border-bottom: 1px solid var(--nx-line-2);
}

.nx-prose details:first-of-type {
	border-top: 1px solid var(--nx-line-2);
}

.nx-prose summary {
	padding: 20px 0;
	list-style: none;
	cursor: pointer;
	font-weight: 600;
	color: var(--nx-sand);
}

.nx-prose summary::-webkit-details-marker {
	display: none;
}

.nx-prose summary::after {
	content: "+";
	float: right;
	color: var(--nx-copper);
	transition: transform .3s;
}

.nx-prose details[open] summary::after {
	transform: rotate(45deg);
}

/* Author box */
.nx-author {
	display: grid;
	grid-template-columns: 88px 1fr;
	gap: 22px;
	align-items: start;
	margin-top: 48px;
	padding: 32px 0;
	border-top: 1px solid var(--nx-line-2);
	border-bottom: 1px solid var(--nx-line-2);
}

.nx-author-photo {
	width: 88px;
	height: 88px;
	border: 1px solid var(--nx-line-2);
	border-radius: 50%;
}

.nx-author h2 {
	margin: 0;
	font-size: 20px;
	letter-spacing: -.02em;
	color: var(--nx-sand);
}

.nx-author-role {
	margin: 4px 0 10px;
	font-size: 14px;
	color: var(--nx-taupe);
}

.nx-author p {
	margin: 0;
	font-size: 16px;
}

/* Related service */
.nx-svccard {
	display: grid;
	grid-template-columns: 1fr auto;
	gap: 20px;
	align-items: center;
	margin-top: 32px;
	padding: 24px;
	border: 1px solid var(--nx-line-2);
	border-radius: 18px;
	color: inherit;
	transition: border-color .3s;
}

.nx-svccard:hover,
.nx-svccard:focus-visible {
	border-color: var(--nx-copper);
}

.nx-svccard small {
	display: block;
	margin-bottom: 6px;
	font-size: 12px;
	letter-spacing: .12em;
	text-transform: uppercase;
	color: var(--nx-copper);
}

.nx-svccard b {
	font-size: 20px;
	letter-spacing: -.02em;
	color: var(--nx-sand);
}

.nx-svccard-text {
	display: block;
	margin-top: 6px;
	font-size: 15px;
	line-height: 1.5;
}

@media (max-width: 860px) {
	.nx-pbody {
		grid-template-columns: 1fr;
	}

	/* Contents above the article; the card and share links after it. */
	.nx-pside {
		position: static;
		display: contents;
	}

	.nx-pside > div:first-child {
		order: -1;
	}

	.nx-sidecard,
	.nx-pside > div:last-child:not(:first-child) {
		order: 2;
	}

	.nx-prose {
		font-size: 17px;
	}

	.nx-author {
		grid-template-columns: 64px 1fr;
		gap: 16px;
	}

	.nx-author-photo {
		width: 64px;
		height: 64px;
	}
}
