/*
 * Blog: index (home.php / category.php) and single posts (single-post.php).
 *
 * Built on the theme's own tokens (--primary, --accent, --tertiary, --bg-*) and
 * components (.inner_hero, .block-button, .cta_section). Motion is opt-in:
 * everything renders finished under prefers-reduced-motion, and reveal states
 * only apply once blog.js has added .blog-js to <html>.
 */

:root {
	--blog-ink: var(--text);
	--blog-muted: rgba(var(--text-rgb), .68);
	--blog-line: rgba(var(--primary-rgb), .14);
	--blog-tint: rgba(var(--bg-2-rgb), .3);
	--blog-tint-2: rgba(var(--primary-rgb), .06);
	--blog-radius: 1.25rem;
	--blog-ease: cubic-bezier(.22, 1, .36, 1);
	--blog-shadow: 0 1px 2px rgba(16, 52, 70, .06), 0 12px 32px -12px rgba(16, 52, 70, .18);
	--blog-shadow-lift: 0 2px 4px rgba(16, 52, 70, .06), 0 28px 56px -20px rgba(16, 52, 70, .32);
	--blog-gradient: linear-gradient(100deg, var(--primary) 0%, var(--tertiary) 55%, var(--accent) 100%);
}

/* The theme pads #primary for its default templates; these templates are full-bleed. */
body.blog #primary,
body.category #primary,
body.single-post #primary {
	padding: 0;
}

/* ---------- Shared: icons, chips, media placeholders ---------- */

.blog-icon {
	width: 1.1em;
	height: 1.1em;
	flex: none;
}

.post-chip {
	display: inline-flex;
	align-items: center;
	padding: .35rem .8rem;
	border-radius: 999px;
	background: rgba(var(--accent-rgb), .18);
	color: #2d5410;
	font-size: .6875rem;
	font-weight: 600;
	letter-spacing: .08em;
	text-transform: uppercase;
	line-height: 1.2;
}

.blog-media {
	position: relative;
	overflow: hidden;
	background: var(--blog-tint);
}

/* Absolutely placed so the image always fills its frame, whatever sizes the frame. */
.blog-media img,
.blog-hero__picture img {
	position: absolute;
	inset: 0;
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

/* Stand-in until a featured image is set: a slow-drifting brand gradient. */
.blog-media__placeholder {
	position: absolute;
	inset: 0;
	display: block;
	background:
		radial-gradient(60% 80% at 15% 20%, rgba(var(--accent-rgb), .55), transparent 60%),
		radial-gradient(55% 70% at 85% 80%, rgba(var(--secondary-rgb), .35), transparent 60%),
		radial-gradient(70% 90% at 70% 10%, rgba(var(--tertiary-rgb), .6), transparent 65%),
		linear-gradient(135deg, var(--primary), var(--tertiary));
	background-size: 160% 160%;
	animation: blog-drift 18s ease-in-out infinite alternate;
}

@keyframes blog-drift {
	from { background-position: 0% 0%; }
	to { background-position: 100% 100%; }
}

/* ---------- Hero (extends .inner_hero) ---------- */

.blog-hero .inner_herowrap,
.post-hero .inner_herowrap {
	overflow: hidden;
	isolation: isolate;
}

.blog-hero .inner_herowrap {
	height: 64vh;
	min-height: 30rem;
}

.post-hero .inner_herowrap {
	height: 72vh;
	min-height: 34rem;
}

.blog-hero__picture {
	overflow: hidden;
}

.blog-hero__picture .inner_hero__image,
.blog-hero__picture .blog-media__placeholder {
	transform-origin: 50% 30%;
	animation: blog-hero-settle 2.4s var(--blog-ease) both;
}

@keyframes blog-hero-settle {
	from { transform: scale(1.12); filter: saturate(.7); }
	to { transform: scale(1.02); filter: none; }
}

/* Scroll-linked drift on the hero image, where the browser supports it. */
@supports (animation-timeline: scroll()) {
	.blog-hero__picture,
	.post-hero .blog-hero__picture {
		animation: blog-hero-parallax linear both;
		animation-timeline: scroll(root block);
		animation-range: 0 100vh;
	}

	@keyframes blog-hero-parallax {
		to { transform: translateY(18%); }
	}
}

.blog-hero .inner_hero__overlay,
.post-hero .inner_hero__overlay {
	background:
		linear-gradient(0deg, rgba(8, 30, 42, .78) 0%, rgba(8, 30, 42, .35) 45%, transparent 75%),
		linear-gradient(180deg, rgba(0, 0, 0, .35), transparent 22%);
}

/* Soft colour fields drifting over the image, tinting it toward the palette. */
.blog-hero__aurora {
	position: absolute;
	inset: -20%;
	z-index: 2;
	pointer-events: none;
	mix-blend-mode: soft-light;
	filter: blur(60px);
}

.blog-hero__aurora span {
	position: absolute;
	width: 45%;
	aspect-ratio: 1;
	border-radius: 50%;
	opacity: .85;
	animation: blog-aurora 22s ease-in-out infinite alternate;
}

.blog-hero__aurora span:nth-child(1) { left: 5%; top: 10%; background: var(--tertiary); }
.blog-hero__aurora span:nth-child(2) { right: 0; top: 30%; background: var(--accent); animation-duration: 28s; animation-delay: -8s; }
.blog-hero__aurora span:nth-child(3) { left: 35%; bottom: 0; background: var(--secondary); opacity: .55; animation-duration: 32s; animation-delay: -15s; }

@keyframes blog-aurora {
	0% { transform: translate(0, 0) scale(1); }
	50% { transform: translate(12%, -8%) scale(1.15); }
	100% { transform: translate(-10%, 10%) scale(.9); }
}

.blog-hero__content,
.post-hero__content {
	bottom: 14%;
	gap: 1.25rem;
}

.blog-hero__eyebrow,
.post-crumbs {
	margin: 0;
	font-size: .75rem;
	font-weight: 600;
	letter-spacing: .22em;
	text-transform: uppercase;
	color: rgba(255, 255, 255, .85);
	animation: blog-fade-up .9s var(--blog-ease) .1s both;
}

.blog-hero__eyebrow a,
.post-crumbs a {
	color: inherit;
	text-decoration: none;
	transition: color .2s ease;
}

.blog-hero__eyebrow a:hover,
.post-crumbs a:hover {
	color: var(--accent);
}

.post-crumbs {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: .6rem;
	letter-spacing: .16em;
}

.post-crumbs span {
	opacity: .5;
}

/* Title words rise out of a mask, one after another. */
.blog-hero__title {
	font-size: clamp(2.5rem, 6vw, 4.5rem);
	font-weight: 600;
	line-height: 1.1;
}

.blog-hero__word {
	display: inline-block;
	overflow: hidden;
	padding: .05em .12em .12em;
	margin: -.05em -.02em -.12em;
	vertical-align: bottom;
}

.blog-hero__word > span {
	display: inline-block;
	animation: blog-word-rise 1.1s var(--blog-ease) both;
	animation-delay: calc(.2s + var(--i, 0) * .09s);
}

@keyframes blog-word-rise {
	from { transform: translateY(110%) rotate(4deg); }
	to { transform: none; }
}

.blog-hero__title::after,
.post-hero__title::after {
	content: "";
	display: block;
	width: 5rem;
	height: 4px;
	margin: 1.5rem auto 0;
	border-radius: 2px;
	background: var(--accent);
	transform-origin: left;
	animation: blog-bar 1s var(--blog-ease) .7s both;
}

@keyframes blog-bar {
	from { transform: scaleX(0); }
	to { transform: scaleX(1); }
}

.blog-hero__intro {
	max-width: 40rem;
	font-size: 1rem;
	line-height: 1.75;
	color: rgba(255, 255, 255, .9);
	animation: blog-fade-up 1s var(--blog-ease) .55s both;
}

.blog-hero__intro p {
	margin: 0;
}

.post-hero__title {
	max-width: 62rem;
	font-size: clamp(1.75rem, 3.6vw, 3.25rem);
	font-weight: 600;
	line-height: 1.2;
	text-wrap: balance;
	animation: blog-fade-up 1.1s var(--blog-ease) .2s both;
}

.post-hero__meta {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: .5rem 1.75rem;
	font-size: .8125rem;
	color: rgba(255, 255, 255, .88);
	animation: blog-fade-up 1s var(--blog-ease) .45s both;
}

.post-hero__meta span {
	display: inline-flex;
	align-items: center;
	gap: .5rem;
}

@keyframes blog-fade-up {
	from { opacity: 0; transform: translateY(1.25rem); }
	to { opacity: 1; transform: none; }
}

/* ---------- Reveal on scroll ---------- */

.blog-js [data-reveal] {
	opacity: 0;
	transform: translateY(1.75rem);
	transition:
		opacity .9s var(--blog-ease) calc(var(--i, 0) * 90ms),
		transform .9s var(--blog-ease) calc(var(--i, 0) * 90ms);
}

.blog-js [data-reveal].is-in {
	opacity: 1;
	transform: none;
}

/* ---------- Index: toolbar + filter ---------- */

.blog-index {
	position: relative;
	padding: 5rem 0 7rem;
	background:
		radial-gradient(50rem 30rem at 100% 0%, rgba(var(--bg-3-rgb), .35), transparent 70%),
		radial-gradient(40rem 30rem at 0% 40%, rgba(var(--bg-2-rgb), .25), transparent 70%),
		var(--bg-1);
}

/* .full_container is a flex row; plain block flow keeps wide children (the filter rail) from stretching it. */
.blog-index__container {
	display: block;
	max-width: 1360px;
	padding: 0 2rem;
}

.blog-toolbar {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: 1.5rem 2rem;
	margin-bottom: 3rem;
}

.blog-toolbar__title {
	position: relative;
	margin: 0;
	font-size: clamp(1.75rem, 3vw, 2.5rem);
	font-weight: 600;
	line-height: 1.2;
}

.blog-toolbar__title::after {
	content: "";
	display: block;
	width: 4rem;
	height: 4px;
	margin-top: 1rem;
	border-radius: 2px;
	background: var(--accent);
}

.blog-filter {
	position: relative;
	min-width: 0;
	max-width: 100%;
	margin-left: auto;
	display: flex;
	flex-wrap: wrap;
	gap: .375rem;
	padding: .375rem;
	border-radius: 999px;
	background: #fff;
	box-shadow: var(--blog-shadow);
}

.blog-filter__chip {
	position: relative;
	z-index: 1;
	display: inline-flex;
	align-items: center;
	gap: .5rem;
	padding: .7rem 1.15rem;
	border-radius: 999px;
	font-size: .75rem;
	font-weight: 600;
	color: var(--blog-ink);
	text-decoration: none;
	white-space: nowrap;
	transition: color .35s var(--blog-ease);
}

.blog-filter__chip:hover {
	color: var(--primary);
}

.blog-filter__chip[aria-current="page"] {
	color: #fff;
}

.blog-filter__chip:focus-visible {
	outline: 2px solid var(--primary);
	outline-offset: 2px;
}

.blog-filter__count {
	display: inline-grid;
	place-items: center;
	min-width: 1.4rem;
	height: 1.4rem;
	padding: 0 .3rem;
	border-radius: 999px;
	background: rgba(var(--primary-rgb), .1);
	font-size: .625rem;
	transition: background .35s var(--blog-ease);
}

.blog-filter__chip[aria-current="page"] .blog-filter__count {
	background: rgba(255, 255, 255, .22);
}

/* Without JS the active chip carries its own fill. */
.blog-filter__chip[aria-current="page"] {
	background: var(--primary);
}

/* With JS a single pill slides between chips instead. */
.blog-js .blog-filter.has-indicator .blog-filter__chip[aria-current="page"] {
	background: transparent;
}

.blog-filter__indicator {
	position: absolute;
	top: 0;
	left: 0;
	z-index: 0;
	display: none;
	border-radius: 999px;
	background: var(--blog-gradient);
	background-size: 200% 100%;
	box-shadow: 0 6px 18px -6px rgba(var(--primary-rgb), .6);
	transition:
		transform .55s var(--blog-ease),
		width .55s var(--blog-ease),
		height .55s var(--blog-ease);
}

.blog-filter.has-indicator .blog-filter__indicator {
	display: block;
}

/* ---------- Index: card grid ---------- */

.blog-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 2rem;
}

.blog-grid__empty {
	margin: 2rem 0 0;
	text-align: center;
	color: var(--blog-muted);
}

.post-card {
	--mx: 50%;
	--my: 50%;
	position: relative;
	display: flex;
	flex-direction: column;
	border-radius: var(--blog-radius);
	background: #fff;
	box-shadow: var(--blog-shadow);
	overflow: hidden;
	isolation: isolate;
	transition:
		transform .6s var(--blog-ease),
		box-shadow .6s var(--blog-ease),
		opacity .9s var(--blog-ease) calc(var(--i, 0) * 90ms);
}

/* Cursor-following light, plus a gradient hairline that wakes up on hover. */
.post-card::before,
.post-card::after {
	content: "";
	position: absolute;
	inset: 0;
	border-radius: inherit;
	pointer-events: none;
	opacity: 0;
	transition: opacity .5s var(--blog-ease);
}

.post-card::before {
	z-index: 2;
	background: radial-gradient(28rem circle at var(--mx) var(--my), rgba(var(--accent-rgb), .14), transparent 45%);
}

.post-card::after {
	z-index: 3;
	padding: 1.5px;
	background: radial-gradient(22rem circle at var(--mx) var(--my), var(--accent), rgba(var(--tertiary-rgb), .6) 40%, transparent 70%);
	-webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
	-webkit-mask-composite: xor;
	mask-composite: exclude;
}

.post-card:hover,
.post-card:focus-within {
	transform: translateY(-6px);
	box-shadow: var(--blog-shadow-lift);
}

.post-card:hover::before,
.post-card:hover::after,
.post-card:focus-within::after {
	opacity: 1;
}

.post-card__media {
	aspect-ratio: 3 / 2;
}

.post-card__media img,
.post-card__media .blog-media__placeholder {
	transition: transform 1.2s var(--blog-ease);
}

.post-card:hover .post-card__media img,
.post-card:hover .post-card__media .blog-media__placeholder {
	transform: scale(1.06);
}

.post-card__body {
	position: relative;
	z-index: 1;
	display: flex;
	flex: 1;
	flex-direction: column;
	gap: 1rem;
	padding: 1.75rem 1.75rem 1.5rem;
}

.post-card__meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: .5rem 1rem;
}

.post-card__time {
	display: inline-flex;
	align-items: center;
	gap: .4rem;
	font-size: .75rem;
	color: var(--blog-muted);
}

.post-card__title {
	margin: 0;
	font-size: 1.1875rem;
	font-weight: 600;
	line-height: 1.4;
	text-wrap: balance;
}

.post-card__link {
	color: var(--blog-ink);
	text-decoration: none;
	background: linear-gradient(var(--accent), var(--accent)) 0 100% / 0 2px no-repeat;
	transition: background-size .5s var(--blog-ease), color .3s ease;
}

/* The whole card is the hit area. */
.post-card__link::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 4;
}

.post-card:hover .post-card__link {
	color: var(--primary);
	background-size: 100% 2px;
}

.post-card__link:focus-visible {
	outline: none;
}

.post-card:has(.post-card__link:focus-visible) {
	outline: 3px solid var(--primary);
	outline-offset: 3px;
}

.post-card__excerpt {
	margin: 0;
	font-size: .875rem;
	line-height: 1.75;
	color: var(--blog-muted);
}

.post-card__footer {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	margin-top: auto;
	padding-top: 1.25rem;
	border-top: 1px solid var(--blog-line);
	font-size: .75rem;
	color: var(--blog-muted);
}

.post-card__more {
	display: inline-flex;
	align-items: center;
	gap: .4rem;
	font-weight: 600;
	color: var(--primary);
}

.post-card__more .blog-icon {
	transition: transform .5s var(--blog-ease);
}

.post-card:hover .post-card__more .blog-icon {
	transform: translateX(5px);
}

/* Featured: first post spans the row, image beside text. */
.post-card--featured {
	grid-column: 1 / -1;
	display: grid;
	grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
}

.post-card--featured .post-card__media {
	aspect-ratio: auto;
	min-height: 26rem;
}

.post-card--featured .post-card__body {
	justify-content: center;
	padding: 3.5rem;
	gap: 1.25rem;
}

.post-card--featured .post-card__title {
	font-size: clamp(1.5rem, 2.4vw, 2.125rem);
	line-height: 1.3;
}

.post-card--featured .post-card__excerpt {
	font-size: .9375rem;
}

.post-card--featured .post-card__media::after {
	content: "Featured";
	position: absolute;
	top: 1.25rem;
	left: 1.25rem;
	padding: .45rem .9rem;
	border-radius: 999px;
	background: rgba(255, 255, 255, .92);
	-webkit-backdrop-filter: blur(8px);
	backdrop-filter: blur(8px);
	color: var(--primary);
	font-size: .6875rem;
	font-weight: 700;
	letter-spacing: .12em;
	text-transform: uppercase;
}

/* While a topic filter is applied, the featured card falls back into the grid. */
.blog-grid.is-filtered .post-card--featured {
	grid-column: auto;
	display: flex;
}

.blog-grid.is-filtered .post-card--featured .post-card__media {
	aspect-ratio: 3 / 2;
	min-height: 0;
}

.blog-grid.is-filtered .post-card--featured .post-card__body {
	padding: 1.75rem 1.75rem 1.5rem;
}

.blog-grid.is-filtered .post-card--featured .post-card__title {
	font-size: 1.1875rem;
}

.blog-grid.is-filtered .post-card--featured .post-card__media::after {
	content: none;
}

.post-card[hidden] {
	display: none !important;
}

/* View Transitions: cards morph to their new grid positions when filtering. */
::view-transition-group(*) {
	animation-duration: .6s;
	animation-timing-function: var(--blog-ease);
}

::view-transition-old(root),
::view-transition-new(root) {
	animation: none;
}

/* Pagination */
.blog-pagination {
	margin-top: 4rem;
}

.blog-pagination .nav-links {
	display: flex;
	justify-content: center;
	gap: .5rem;
}

.blog-pagination .page-numbers {
	display: grid;
	place-items: center;
	min-width: 2.75rem;
	height: 2.75rem;
	border-radius: 999px;
	background: #fff;
	box-shadow: var(--blog-shadow);
	font-size: .8125rem;
	font-weight: 600;
	text-decoration: none;
	transition: background .3s ease, color .3s ease;
}

.blog-pagination .page-numbers.current,
.blog-pagination a.page-numbers:hover {
	background: var(--primary);
	color: #fff;
}

/* ---------- Single: reading progress ---------- */

.post-progress {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 120;
	height: 4px;
	pointer-events: none;
}

.post-progress__bar {
	display: block;
	height: 100%;
	background: var(--blog-gradient);
	transform: scaleX(var(--progress, 0));
	transform-origin: left;
	box-shadow: 0 0 12px rgba(var(--accent-rgb), .7);
}

/* Native scroll-driven version: tracks the article itself, no JS involved. */
@supports (animation-timeline: view()) {
	body.single-post {
		timeline-scope: --post-article;
	}

	.post-article {
		view-timeline: --post-article block;
	}

	.post-progress__bar {
		animation: blog-progress linear both;
		animation-timeline: --post-article;
		animation-range: contain 0% contain 100%;
	}

	@keyframes blog-progress {
		from { transform: scaleX(0); }
		to { transform: scaleX(1); }
	}
}

/* ---------- Single: layout ---------- */

.post-layout {
	display: grid;
	grid-template-columns: minmax(14rem, 17rem) minmax(0, 46rem);
	justify-content: center;
	gap: 5rem;
	max-width: 1360px;
	margin: 0 auto;
	padding: 5.5rem 2rem 6rem;
}

.post-aside__sticky {
	position: sticky;
	top: 2rem;
	display: flex;
	flex-direction: column;
	gap: 2.5rem;
	transition: top .35s var(--blog-ease);
}

/* The theme's header slides back in on scroll-up; make room for it then. */
body:has(#masthead.scrolling-up) .post-aside__sticky {
	top: 8.5rem;
}

/* ---------- Single: table of contents ---------- */

.post-toc {
	position: relative;
}

.post-toc__title,
.post-share__title {
	margin: 0 0 1rem;
	font-size: .6875rem;
	font-weight: 700;
	letter-spacing: .18em;
	text-transform: uppercase;
	color: var(--primary);
}

.post-toc__list {
	position: relative;
	margin: 0;
	padding: 0;
	list-style: none;
	border-left: 2px solid var(--blog-line);
}

.post-toc__link {
	display: block;
	padding: .55rem 0 .55rem 1.1rem;
	font-size: .75rem;
	line-height: 1.5;
	color: var(--blog-muted);
	text-decoration: none;
	transition: color .3s ease, transform .4s var(--blog-ease);
}

.post-toc__link:hover {
	color: var(--blog-ink);
}

.post-toc__link[aria-current="true"] {
	color: var(--primary);
	font-weight: 600;
	transform: translateX(3px);
}

.post-toc__indicator {
	position: absolute;
	top: 0;
	left: 0;
	width: 2px;
	height: 0;
	border-radius: 2px;
	background: linear-gradient(var(--tertiary), var(--accent));
	box-shadow: 0 0 10px rgba(var(--accent-rgb), .8);
	opacity: 0;
	transition:
		transform .5s var(--blog-ease),
		height .5s var(--blog-ease),
		opacity .3s ease;
}

.post-toc.has-active .post-toc__indicator {
	opacity: 1;
}

.post-toc-mobile {
	display: none;
}

/* ---------- Single: share ---------- */

.post-share__buttons {
	display: flex;
	flex-wrap: wrap;
	gap: .5rem;
}

.post-share__btn {
	display: grid;
	place-items: center;
	width: 2.75rem;
	height: 2.75rem;
	padding: 0;
	border: 1px solid var(--blog-line);
	border-radius: 50%;
	background: #fff;
	color: var(--primary);
	cursor: pointer;
	transition:
		background .3s ease,
		color .3s ease,
		border-color .3s ease,
		transform .4s var(--blog-ease);
}

.post-share__btn[hidden] {
	display: none;
}

.post-share__btn:hover,
.post-share__btn:focus-visible {
	background: var(--primary);
	border-color: var(--primary);
	color: #fff;
	transform: translateY(-3px);
}

.post-toast {
	position: fixed;
	left: 50%;
	bottom: 2rem;
	z-index: 130;
	padding: .9rem 1.4rem;
	border-radius: 999px;
	background: var(--primary);
	color: #fff;
	font-size: .8125rem;
	font-weight: 600;
	box-shadow: var(--blog-shadow-lift);
	opacity: 0;
	transform: translate(-50%, 1rem);
	pointer-events: none;
	transition: opacity .35s ease, transform .5s var(--blog-ease);
}

.post-toast.is-visible {
	opacity: 1;
	transform: translate(-50%, 0);
}

/* ---------- Single: article typography ---------- */

.post-content {
	font-size: 1rem;
	line-height: 1.9;
	color: var(--blog-ink);
}

.post-content > * {
	margin-top: 0;
	margin-bottom: 1.5rem;
}

.post-content p {
	margin-top: 0;
}

.post-content a:not(.block-button__button) {
	color: var(--primary);
	font-weight: 500;
	text-decoration: none;
	background-image: linear-gradient(rgba(var(--accent-rgb), .45), rgba(var(--accent-rgb), .45));
	background-position: 0 100%;
	background-size: 100% 2px;
	background-repeat: no-repeat;
	transition: background-size .35s var(--blog-ease), color .2s ease;
}

.post-content a:not(.block-button__button):hover {
	background-size: 100% 100%;
	color: var(--text);
}

.post-content h2 {
	scroll-margin-top: 9rem;
	margin: 4rem 0 1.5rem;
	font-size: clamp(1.375rem, 2.2vw, 1.875rem);
	font-weight: 600;
	line-height: 1.35;
	text-wrap: balance;
}

.post-content h2::after {
	content: "";
	display: block;
	width: 3.5rem;
	height: 4px;
	margin-top: 1rem;
	border-radius: 2px;
	background: var(--accent);
	transform-origin: left;
	transition: transform 1s var(--blog-ease) .25s;
}

.blog-js .post-content h2[data-reveal]:not(.is-in)::after {
	transform: scaleX(0);
}

.post-content h3 {
	margin: 2.5rem 0 1rem;
	font-size: 1.125rem;
	font-weight: 600;
	line-height: 1.45;
	color: var(--primary);
}

.post-content ul:not(.taoo-checklist) {
	padding-left: 0;
	list-style: none;
}

.post-content ul:not(.taoo-checklist) li {
	position: relative;
	padding-left: 1.75rem;
	margin-bottom: .6rem;
}

.post-content ul:not(.taoo-checklist) li::before {
	content: "";
	position: absolute;
	top: .75em;
	left: .25rem;
	width: .55rem;
	height: .55rem;
	border-radius: 50%;
	background: var(--accent);
	box-shadow: 0 0 0 3px rgba(var(--accent-rgb), .22);
}

/* The short answer that opens every post. */
.post-content .taoo-answer {
	position: relative;
	margin-bottom: 2.5rem;
	padding: 2.25rem 2.25rem 2.25rem 2.5rem;
	border-radius: var(--blog-radius);
	background:
		linear-gradient(#fff, #fff) padding-box,
		var(--blog-gradient) border-box;
	border: 2px solid transparent;
	box-shadow: var(--blog-shadow);
	font-size: 1.0625rem;
	line-height: 1.85;
}

.post-content .taoo-answer::before {
	content: "The short answer";
	display: inline-block;
	margin-bottom: .85rem;
	padding: .35rem .8rem;
	border-radius: 999px;
	background: rgba(var(--primary-rgb), .1);
	color: var(--primary);
	font-size: .6875rem;
	font-weight: 700;
	letter-spacing: .14em;
	text-transform: uppercase;
	display: table;
}

/* Fact strip */
.post-content .taoo-facts {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 1rem;
	margin: 2.5rem 0 3rem;
}

.post-content .taoo-fact {
	display: flex;
	flex-direction: column;
	gap: .5rem;
	padding: 1.5rem 1.25rem;
	border-radius: 1rem;
	background: var(--blog-tint);
	transition: transform .5s var(--blog-ease), background .4s ease;
}

.post-content .taoo-fact:hover {
	transform: translateY(-4px);
	background: rgba(var(--bg-3-rgb), .55);
}

.post-content .taoo-fact strong {
	font-size: clamp(.9375rem, 1.35vw, 1.125rem);
	font-weight: 700;
	line-height: 1.25;
	letter-spacing: 0;
	overflow-wrap: anywhere;
	background: var(--blog-gradient);
	background-size: 150% 100%;
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}

.post-content .taoo-fact span {
	font-size: .75rem;
	line-height: 1.6;
	color: var(--blog-muted);
}

/* Option cards: full-width rows (title beside body), or a 2-up grid with --two. */
.post-content .taoo-options {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 1rem;
	margin: 2rem 0 2.5rem;
}

.post-content .taoo-options:not(.taoo-options--two) .taoo-option {
	display: grid;
	grid-template-columns: minmax(0, 14rem) minmax(0, 1fr);
	gap: 2rem;
	align-items: start;
	padding: 1.75rem 2rem;
}

.post-content .taoo-options:not(.taoo-options--two) .taoo-option h3 {
	margin: 0;
}

.post-content .taoo-options--two {
	grid-template-columns: repeat(2, minmax(0, 1fr));
}

.post-content .taoo-option {
	position: relative;
	padding: 1.75rem 1.5rem 1.5rem;
	border: 1px solid var(--blog-line);
	border-radius: 1rem;
	background: #fff;
	box-shadow: var(--blog-shadow);
	overflow: hidden;
	transition: transform .5s var(--blog-ease), box-shadow .5s var(--blog-ease);
}

.post-content .taoo-option::before {
	content: "";
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 4px;
	background: var(--blog-gradient);
	transform: scaleX(.18);
	transform-origin: left;
	transition: transform .7s var(--blog-ease);
}

.post-content .taoo-option:hover {
	transform: translateY(-4px);
	box-shadow: var(--blog-shadow-lift);
}

.post-content .taoo-option:hover::before {
	transform: scaleX(1);
}

.post-content .taoo-option h3 {
	margin: 0 0 .75rem;
	font-size: 1rem;
}

.post-content .taoo-option p,
.post-content .taoo-option ul {
	margin: 0;
	font-size: .875rem;
	line-height: 1.75;
}

.post-content .taoo-option li {
	margin-bottom: .5rem;
}

/* Checklist */
.post-content .taoo-checklist {
	display: grid;
	gap: .75rem;
	margin: 1.5rem 0 2rem;
	padding: 0;
	list-style: none;
}

.post-content .taoo-checklist li {
	position: relative;
	padding: 1rem 1.25rem 1rem 3.5rem;
	border-radius: .875rem;
	background: var(--blog-tint);
	line-height: 1.65;
	transition: background .3s ease, transform .5s var(--blog-ease);
}

.post-content .taoo-checklist li:hover {
	background: rgba(var(--bg-3-rgb), .5);
	transform: translateX(4px);
}

.post-content .taoo-checklist li::before {
	content: "";
	position: absolute;
	top: 1.05rem;
	left: 1.15rem;
	width: 1.5rem;
	height: 1.5rem;
	border-radius: 50%;
	background:
		url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4L18 8.5'/%3E%3C/svg%3E") center / 70% no-repeat,
		var(--primary);
}

.blog-js .post-content .taoo-checklist[data-reveal] {
	opacity: 1;
	transform: none;
}

.blog-js .post-content .taoo-checklist li {
	opacity: 0;
	transform: translateX(-1rem);
	transition:
		opacity .7s var(--blog-ease) calc(var(--i, 0) * 80ms),
		transform .7s var(--blog-ease) calc(var(--i, 0) * 80ms),
		background .3s ease;
}

.blog-js .post-content .taoo-checklist.is-in li {
	opacity: 1;
	transform: none;
}

/* Children of revealed groups stagger in. */
.blog-js .post-content .taoo-facts[data-reveal],
.blog-js .post-content .taoo-options[data-reveal] {
	opacity: 1;
	transform: none;
}

.blog-js .post-content .taoo-fact,
.blog-js .post-content .taoo-option {
	opacity: 0;
	transform: translateY(1.5rem);
	transition:
		opacity .8s var(--blog-ease) calc(var(--i, 0) * 110ms),
		transform .8s var(--blog-ease) calc(var(--i, 0) * 110ms),
		box-shadow .5s var(--blog-ease),
		background .4s ease;
}

.blog-js .post-content .is-in > .taoo-fact,
.blog-js .post-content .is-in > .taoo-option {
	opacity: 1;
	transform: none;
}

.blog-js .post-content .is-in > .taoo-fact:hover,
.blog-js .post-content .is-in > .taoo-option:hover {
	transform: translateY(-4px);
	transition-delay: 0s;
}

/* ---------- Single: FAQ accordion ---------- */

.post-content .post-faq {
	margin: 4.5rem 0 3rem;
	padding: 3rem 2.5rem 2rem;
	border-radius: calc(var(--blog-radius) + .25rem);
	background: var(--blog-tint);
}

.post-content .post-faq > h2 {
	margin-top: 0;
}

.post-faq__list {
	display: grid;
	gap: .75rem;
}

.post-faq__item {
	border-radius: 1rem;
	background: #fff;
	box-shadow: 0 1px 2px rgba(16, 52, 70, .05);
	transition: box-shadow .4s var(--blog-ease);
}

.post-faq__item[open] {
	box-shadow: var(--blog-shadow);
}

.post-faq__q {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1.25rem;
	padding: 1.25rem 1.5rem;
	cursor: pointer;
	list-style: none;
}

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

.post-faq__q:focus-visible {
	outline: 2px solid var(--primary);
	outline-offset: 2px;
	border-radius: 1rem;
}

.post-content .post-faq__q-text {
	margin: 0;
	font-size: .9375rem;
	line-height: 1.5;
	color: var(--blog-ink);
	transition: color .3s ease;
}

.post-faq__item[open] .post-faq__q-text,
.post-faq__q:hover .post-faq__q-text {
	color: var(--primary);
}

/* Plus that turns into a minus. */
.post-faq__icon {
	position: relative;
	flex: none;
	width: 2rem;
	height: 2rem;
	border-radius: 50%;
	background: rgba(var(--primary-rgb), .08);
	transition: background .35s ease, transform .5s var(--blog-ease);
}

.post-faq__icon::before,
.post-faq__icon::after {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: .75rem;
	height: 2px;
	margin: -1px 0 0 -.375rem;
	border-radius: 1px;
	background: var(--primary);
	transition: transform .5s var(--blog-ease), background .35s ease;
}

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

[open] > summary .post-faq__icon {
	background: var(--accent);
	transform: rotate(180deg);
}

[open] > summary .post-faq__icon::before,
[open] > summary .post-faq__icon::after {
	background: var(--text);
}

[open] > summary .post-faq__icon::after {
	transform: rotate(0deg);
}

.post-faq__a-inner {
	padding: 0 1.5rem 1.4rem;
	font-size: .875rem;
	line-height: 1.85;
	color: var(--blog-muted);
}

.post-faq__a-inner > :last-child {
	margin-bottom: 0;
}

/* ---------- Single: closing CTA ---------- */

.post-content .post-cta {
	position: relative;
	margin: 4rem 0 0;
	padding: 3.25rem 3rem;
	border-radius: calc(var(--blog-radius) + .25rem);
	background: linear-gradient(to right, rgba(var(--tertiary-rgb), .6) 0, var(--bg-3) 100%);
	overflow: hidden;
	isolation: isolate;
}

/* A slow light sweep across the card. */
.post-content .post-cta::before {
	content: "";
	position: absolute;
	inset: -50%;
	z-index: -1;
	background: conic-gradient(from 0deg, transparent 0 70%, rgba(255, 255, 255, .55) 80%, transparent 90%);
	animation: blog-sweep 9s linear infinite;
}

@keyframes blog-sweep {
	to { transform: rotate(1turn); }
}

.post-content .post-cta h2 {
	margin-top: 0;
	font-size: clamp(1.5rem, 2.6vw, 2.125rem);
}

.post-content .post-cta h2::after {
	background: var(--primary);
}

.post-content .post-cta p {
	max-width: 36rem;
}

.post-content .post-cta a:not(.block-button__button) {
	color: var(--text);
}

.post-cta__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 1rem 2rem;
	margin-top: 2rem;
}

.post-content .post-cta .block-button__button {
	font-weight: 700;
}

.post-content .post-cta .post-cta__phone {
	display: inline-flex;
	align-items: center;
	gap: .6rem;
	background: none;
	font-weight: 700;
	color: var(--text);
}

.post-cta__phone .blog-icon {
	width: 2.5rem;
	height: 2.5rem;
	padding: .6rem;
	border-radius: 50%;
	background: #fff;
	color: var(--primary);
	transition: transform .5s var(--blog-ease);
}

.post-cta__phone:hover .blog-icon {
	transform: rotate(-12deg) scale(1.08);
}

/* ---------- Single: author ---------- */

.post-author {
	display: grid;
	grid-template-columns: 7.5rem minmax(0, 1fr);
	gap: 2rem;
	align-items: center;
	margin-top: 4rem;
	padding: 2.25rem;
	border: 1px solid var(--blog-line);
	border-radius: var(--blog-radius);
	background: #fff;
}

.post-author__photo {
	position: relative;
	width: 7.5rem;
	aspect-ratio: 1;
	border-radius: 50%;
	padding: 4px;
	background: var(--blog-gradient);
}

.post-author__image {
	display: block;
	width: 100%;
	height: 100%;
	border: 3px solid #fff;
	border-radius: 50%;
	object-fit: cover;
	object-position: 50% 15%;
}

.post-author__eyebrow {
	margin: 0 0 .25rem;
	font-size: .6875rem;
	font-weight: 700;
	letter-spacing: .16em;
	text-transform: uppercase;
	color: var(--tertiary);
}

.post-author__name {
	margin: 0 0 .75rem;
	font-size: 1.125rem;
	font-weight: 600;
}

.post-author__bio {
	margin: 0 0 1rem;
	font-size: .8125rem;
	line-height: 1.8;
	color: var(--blog-muted);
}

.post-author__link,
.post-related__all {
	display: inline-flex;
	align-items: center;
	gap: .5rem;
	font-size: .8125rem;
	font-weight: 700;
	color: var(--primary);
	text-decoration: none;
}

.post-author__link .blog-icon,
.post-related__all .blog-icon {
	transition: transform .5s var(--blog-ease);
}

.post-author__link:hover .blog-icon,
.post-related__all:hover .blog-icon {
	transform: translateX(5px);
}

/* ---------- Single: related ---------- */

.post-related {
	padding: 6rem 0 7rem;
	background:
		radial-gradient(45rem 25rem at 0% 0%, rgba(var(--bg-3-rgb), .35), transparent 70%),
		var(--blog-tint);
}

.post-related__container {
	display: block;
	max-width: 1360px;
	padding: 0 2rem;
}

.post-related__head {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: 1rem;
	margin-bottom: 2.5rem;
}

.post-related__title {
	margin: 0;
	font-size: clamp(1.75rem, 3vw, 2.5rem);
	font-weight: 600;
}

.post-related__title::after {
	content: "";
	display: block;
	width: 4rem;
	height: 4px;
	margin-top: 1rem;
	border-radius: 2px;
	background: var(--accent);
}

/* ---------- Responsive ---------- */

@media (max-width: 1100px) {
	.post-layout {
		grid-template-columns: minmax(0, 46rem);
		gap: 0;
		padding-top: 3.5rem;
	}

	.post-aside {
		order: 2;
		margin-top: 3rem;
	}

	.post-aside__sticky {
		position: static;
	}

	.post-toc {
		display: none;
	}

	.post-toc-mobile {
		display: block;
		margin-bottom: 2.5rem;
		border: 1px solid var(--blog-line);
		border-radius: 1rem;
		background: #fff;
	}

	.post-toc-mobile summary {
		display: flex;
		align-items: center;
		justify-content: space-between;
		padding: 1.1rem 1.25rem;
		font-size: .75rem;
		font-weight: 700;
		letter-spacing: .14em;
		text-transform: uppercase;
		color: var(--primary);
		cursor: pointer;
		list-style: none;
	}

	.post-toc-mobile summary::-webkit-details-marker {
		display: none;
	}

	.post-toc-mobile ol {
		margin: 0;
		padding: 0 1.25rem 1.25rem 2.5rem;
		font-size: .8125rem;
		line-height: 1.6;
	}

	.post-toc-mobile li {
		margin-bottom: .6rem;
	}

	.post-toc-mobile a {
		color: var(--blog-ink);
		text-decoration: none;
	}
}

@media (max-width: 1024px) {
	.blog-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.post-card--featured {
		grid-template-columns: 1fr;
	}

	.post-card--featured .post-card__media {
		aspect-ratio: 16 / 9;
		min-height: 0;
	}

	.post-card--featured .post-card__body {
		padding: 2.25rem;
	}
}

@media (max-width: 767px) {
	/* A definite height: the theme positions the hero text absolutely against it. */
	.blog-hero .inner_herowrap,
	.post-hero .inner_herowrap {
		height: 72svh;
		min-height: 30rem;
		max-height: 40rem;
		margin-top: 6rem;
	}

	.post-hero__title {
		font-size: 1.625rem;
	}

	.blog-hero__content,
	.post-hero__content {
		bottom: 9%;
	}

	.blog-index {
		padding: 3.5rem 0 4.5rem;
	}

	.blog-index__container,
	.post-related__container {
		padding: 0 1rem;
	}

	.blog-toolbar {
		margin-bottom: 2rem;
	}

	/* Filter becomes a horizontally scrolling rail. */
	.blog-filter {
		flex-wrap: nowrap;
		max-width: 100%;
		overflow-x: auto;
		scrollbar-width: none;
		scroll-snap-type: x proximity;
	}

	.blog-filter::-webkit-scrollbar {
		display: none;
	}

	.blog-filter__chip {
		scroll-snap-align: start;
	}

	.blog-grid {
		grid-template-columns: 1fr;
		gap: 1.5rem;
	}

	.post-card__body,
	.post-card--featured .post-card__body {
		padding: 1.5rem;
	}

	.post-layout {
		padding: 2.5rem 1rem 4rem;
	}

	.post-content {
		font-size: .9375rem;
		line-height: 1.85;
	}

	.post-content h2 {
		margin-top: 3rem;
	}

	.post-content .taoo-answer {
		padding: 1.5rem;
		font-size: .9375rem;
	}

	.post-content .taoo-facts,
	.post-content .taoo-options--two {
		grid-template-columns: 1fr;
	}

	.post-content .taoo-options:not(.taoo-options--two) .taoo-option {
		grid-template-columns: 1fr;
		gap: .75rem;
		padding: 1.5rem;
	}

	.post-content .post-faq {
		margin-left: -1rem;
		margin-right: -1rem;
		padding: 2.25rem 1rem 1.25rem;
		border-radius: 0;
	}

	.post-faq__q {
		padding: 1.1rem 1.15rem;
	}

	.post-faq__a-inner {
		padding: 0 1.15rem 1.2rem;
	}

	.post-content .post-cta {
		padding: 2.25rem 1.5rem;
	}

	.post-author {
		grid-template-columns: 1fr;
		gap: 1.25rem;
		padding: 1.75rem 1.5rem;
		text-align: center;
	}

	.post-author__photo {
		margin: 0 auto;
	}

	.post-related {
		padding: 4rem 0 4.5rem;
	}
}

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
	.blog-js [data-reveal],
	.blog-js .post-content .taoo-fact,
	.blog-js .post-content .taoo-option,
	.blog-js .post-content .taoo-checklist li {
		opacity: 1 !important;
		transform: none !important;
	}

	.blog-hero__aurora span,
	.blog-media__placeholder,
	.blog-hero__picture,
	.blog-hero__picture .inner_hero__image,
	.blog-hero__picture .blog-media__placeholder,
	.blog-hero__word > span,
	.post-content .post-cta::before {
		animation: none !important;
		transform: none !important;
	}

	*,
	*::before,
	*::after {
		transition-duration: .01ms !important;
		animation-duration: .01ms !important;
	}

	/* The progress bar is information, not decoration: keep it. */
	.post-progress__bar {
		animation-duration: auto !important;
	}
}
