/*
 * SANA blog: one card design for the homepage "Sana Latest Posts" widget and
 * the Kadence blog archive (/blog/, categories), plus the single-post reading
 * layout. Palette B (Wild Water). Typography follows CLAUDE.md: Barlow
 * Condensed headings, Manrope body. Square photo corners like the activity
 * cards; no motion (hover changes colour only, instantly).
 */
:root {
	--sana-b-ink: #0B262B;
	--sana-b-river: #123F46;
	--sana-b-teal-text: #216D77;
	--sana-b-glacier: #82C6C9;
	--sana-b-amber: #E3A64C;
	--sana-b-mist: #F2EDE2;
	--sana-b-shade: #E9E2D3;
	--sana-b-line: #D8CFBD;
	--sana-b-muted: #587378;
	--sana-b-head: "Barlow Condensed", sans-serif;
	--sana-b-body: "Manrope", sans-serif;
}

/* ------------------------------------------------------------------ cards */
.sana-posts {
	display: grid;
	grid-template-columns: repeat(var(--sana-posts-count, 3), minmax(0, 1fr));
	gap: 2rem;
	width: 100%;
}

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

@media (max-width: 767px) {
	.sana-posts {
		grid-template-columns: 1fr;
		gap: 2.5rem;
	}
}

.sana-post-card,
.post-archive .loop-entry {
	position: relative;
	display: flex;
	flex-direction: column;
	margin: 0;
	background: #fff;
	border: 1px solid var(--sana-b-line);
	border-radius: 0;
	box-shadow: none;
	overflow: hidden;
}

.sana-post-card__media,
.post-archive .loop-entry .post-thumbnail {
	display: block;
	flex-shrink: 0;
	height: auto;
	position: relative;
	aspect-ratio: 3 / 2;
	margin: 0;
	padding: 0;
	overflow: hidden;
	background: var(--sana-b-river);
}

.sana-post-card__image,
.post-archive .loop-entry .post-thumbnail img {
	display: block;
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: cover;
}

.post-archive .loop-entry .post-thumbnail-inner {
	position: static;
	padding: 0;
}

.sana-post-card__body,
.post-archive .loop-entry .entry-content-wrap {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	gap: 0.75rem;
	padding: 1.75rem 1.75rem 2rem;
}

@media (max-width: 767px) {
	.sana-post-card__body,
	.post-archive .loop-entry .entry-content-wrap {
		padding: 1.5rem 1.25rem 1.75rem;
	}
}

/* Eyebrow: category and date. */
.sana-post-card__meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.25rem 0.75rem;
	margin: 0;
	color: var(--sana-b-muted);
	font-family: var(--sana-b-body);
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	line-height: 1.4;
	text-transform: uppercase;
}

.sana-post-card__category,
.post-archive .loop-entry .entry-taxonomies,
.post-archive .loop-entry .entry-taxonomies a,
.single-post .entry-hero .entry-taxonomies a {
	color: var(--sana-b-teal-text);
	font-family: var(--sana-b-body);
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-decoration: none;
	text-transform: uppercase;
}

.post-archive .loop-entry .entry-taxonomies {
	margin: 0;
}

.post-archive .loop-entry .entry-header {
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
	margin: 0;
}

.sana-post-card__title,
.post-archive .loop-entry .entry-title {
	margin: 0;
	color: var(--sana-b-river);
	font-family: var(--sana-b-head);
	font-size: 1.875rem;
	font-weight: 600;
	letter-spacing: 0;
	line-height: 1.1;
}

@media (max-width: 767px) {
	.sana-post-card__title,
	.post-archive .loop-entry .entry-title {
		font-size: 1.75rem;
	}
}

.sana-post-card__link,
.post-archive .loop-entry .entry-title a {
	color: inherit;
	text-decoration: none;
}

/* The whole card is the link target (title link stretched over the card). */
.sana-post-card__link::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 1;
}

.sana-post-card__excerpt,
.post-archive .loop-entry .entry-summary,
.post-archive .loop-entry .entry-summary p {
	margin: 0;
	color: var(--sana-b-ink);
	font-family: var(--sana-b-body);
	font-size: 1rem;
	line-height: 1.6;
	opacity: 0.85;
}

.sana-post-card__more,
.post-archive .loop-entry .post-more-link {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	margin-top: auto;
	padding-top: 0.5rem;
	color: var(--sana-b-teal-text);
	font-family: var(--sana-b-body);
	font-size: 0.9375rem;
	font-weight: 700;
	letter-spacing: 0;
	text-decoration: none;
	text-transform: none;
	border: 0;
	background: none;
}

.sana-post-card__more::after {
	content: "\2192";
	font-weight: 700;
}

.post-archive .loop-entry .entry-footer {
	margin-top: auto;
	padding: 0;
}

.post-archive .loop-entry .more-link-wrap {
	margin: 0;
}

/* Hover and keyboard focus: colour only, no movement. */
.sana-post-card:hover .sana-post-card__title,
.sana-post-card:focus-within .sana-post-card__title,
.post-archive .loop-entry:hover .entry-title a {
	color: var(--sana-b-teal-text);
}

.sana-post-card:hover .sana-post-card__more,
.post-archive .loop-entry .post-more-link:hover {
	text-decoration: underline;
	text-underline-offset: 0.2em;
}

.sana-post-card:focus-within {
	outline: 3px solid var(--sana-b-amber);
	outline-offset: 3px;
}

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

.sana-post-card:active,
.post-archive .loop-entry:active {
	background: var(--sana-b-mist);
}

/* ------------------------------------------------------- archive (/blog/) */
.blog .content-area,
.archive.category .content-area {
	margin-top: 4rem;
	margin-bottom: 6rem;
}

@media (max-width: 767px) {
	.blog .content-area,
	.archive.category .content-area {
		margin-top: 2.5rem;
		margin-bottom: 4rem;
	}
}

.post-archive.grid-cols {
	gap: 2rem;
}

.post-archive-hero-section .entry-hero-container-inner,
.blog .entry-hero .entry-hero-container-inner {
	background: var(--sana-b-river);
}

.post-archive-hero-section .hero-container,
.blog .entry-hero .hero-container {
	min-height: 18rem;
	padding-top: 4rem;
	padding-bottom: 3.5rem;
}

.post-archive-hero-section .page-title,
.post-archive-hero-section .archive-title,
.blog .entry-hero h1 {
	margin: 0;
	color: var(--sana-b-mist);
	font-family: var(--sana-b-head);
	font-size: 4.25rem;
	font-weight: 700;
	line-height: 1.02;
}

.post-archive-hero-section .archive-description,
.post-archive-hero-section .archive-description p {
	max-width: 40rem;
	margin-top: 1rem;
	color: var(--sana-b-mist);
	opacity: 0.85;
	font-size: 1.125rem;
}

@media (max-width: 1024px) {
	.post-archive-hero-section .page-title,
	.post-archive-hero-section .archive-title,
	.blog .entry-hero h1 {
		font-size: 3.5rem;
	}
}

@media (max-width: 767px) {
	.post-archive-hero-section .hero-container,
	.blog .entry-hero .hero-container {
		min-height: 12rem;
		padding-top: 3rem;
		padding-bottom: 2.5rem;
	}

	.post-archive-hero-section .page-title,
	.post-archive-hero-section .archive-title,
	.blog .entry-hero h1 {
		font-size: 2.75rem;
	}
}

/* Pagination */
.post-archive ~ .pagination .page-numbers,
.blog .pagination .page-numbers {
	min-width: 44px;
	min-height: 44px;
	border-radius: 10px;
	font-family: var(--sana-b-body);
	font-weight: 700;
}

.blog .pagination .page-numbers.current {
	background: var(--sana-b-river);
	border-color: var(--sana-b-river);
	color: var(--sana-b-mist);
}

/* ------------------------------------------------------------ single post */
.single-post .entry-hero.post-hero-section .entry-header {
	max-width: 52rem;
	margin: 0 auto;
}

.single-post .entry-hero .entry-title {
	color: var(--sana-b-mist);
	font-family: var(--sana-b-head);
	font-size: 4.25rem;
	font-weight: 700;
	letter-spacing: 0;
	line-height: 1.02;
	text-wrap: balance;
}

.single-post .entry-hero .entry-taxonomies a {
	color: var(--sana-b-glacier);
}

.single-post .entry-hero .entry-meta,
.single-post .entry-hero .entry-meta a,
.single-post .entry-hero .entry-meta time {
	color: var(--sana-b-mist);
	font-family: var(--sana-b-body);
	font-size: 0.9375rem;
	opacity: 0.9;
}

@media (max-width: 1024px) {
	.single-post .entry-hero .entry-title {
		font-size: 3.5rem;
	}
}

@media (max-width: 767px) {
	.single-post .entry-hero .entry-title {
		font-size: 2.5rem;
	}
}

.single-post .content-area {
	margin-top: 4rem;
	margin-bottom: 5rem;
}

@media (max-width: 767px) {
	.single-post .content-area {
		margin-top: 2.5rem;
		margin-bottom: 3.5rem;
	}
}

.single-post .entry-content {
	color: var(--sana-b-ink);
	font-family: var(--sana-b-body);
	font-size: 1.125rem;
	line-height: 1.75;
}

@media (max-width: 767px) {
	.single-post .entry-content {
		font-size: 1.0625rem;
		line-height: 1.7;
	}
}

.single-post .entry-content > * + * {
	margin-top: 1.25em;
}

.single-post .entry-content h2 {
	margin-top: 2.25em;
	margin-bottom: 0;
	color: var(--sana-b-river);
	font-family: var(--sana-b-head);
	font-size: 2.5rem;
	font-weight: 700;
	line-height: 1.05;
	text-wrap: balance;
}

.single-post .entry-content h3 {
	margin-top: 1.75em;
	margin-bottom: 0;
	color: var(--sana-b-river);
	font-family: var(--sana-b-head);
	font-size: 1.75rem;
	font-weight: 600;
	line-height: 1.15;
}

.single-post .entry-content h2 + *,
.single-post .entry-content h3 + * {
	margin-top: 0.6em;
}

@media (max-width: 767px) {
	.single-post .entry-content h2 {
		font-size: 2rem;
	}

	.single-post .entry-content h3 {
		font-size: 1.5rem;
	}
}

.single-post .entry-content strong {
	color: var(--sana-b-river);
	font-weight: 700;
}

.single-post .entry-content a {
	color: var(--sana-b-teal-text);
	font-weight: 600;
	text-decoration: underline;
	text-underline-offset: 0.2em;
}

.single-post .entry-content ul,
.single-post .entry-content ol {
	padding-left: 1.25em;
}

.single-post .entry-content li + li {
	margin-top: 0.5em;
}

.single-post .entry-content li::marker {
	color: var(--sana-b-teal-text);
}

.single-post .entry-content hr {
	height: 1px;
	margin: 3rem 0;
	border: 0;
	background: var(--sana-b-line);
}

.single-post .entry-content .sana-post-figure {
	margin: 2.5rem 0;
}

.single-post .entry-content .sana-post-figure img,
.single-post .entry-content img {
	display: block;
	width: 100%;
	height: auto;
	border-radius: 0;
}

/* Previous / next and related posts */
.single-post .post-navigation {
	margin-top: 4rem;
	padding-top: 2rem;
	border-top: 1px solid var(--sana-b-line);
	font-family: var(--sana-b-body);
}

.single-post .post-navigation .nav-links a {
	color: var(--sana-b-river);
	font-family: var(--sana-b-head);
	font-size: 1.375rem;
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
}

.single-post .post-navigation .post-navigation-sub {
	color: var(--sana-b-muted);
	font-family: var(--sana-b-body);
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
}

.single-post .entry-related {
	background: var(--sana-b-shade);
}

.single-post .entry-related-title {
	color: var(--sana-b-river);
	font-family: var(--sana-b-head);
	font-size: 2.5rem;
	font-weight: 700;
}

.single-post .entry-related .loop-entry {
	background: #fff;
	border: 1px solid var(--sana-b-line);
	border-radius: 0;
	box-shadow: none;
}

.single-post .entry-related .loop-entry .entry-title {
	color: var(--sana-b-river);
	font-family: var(--sana-b-head);
	font-size: 1.5rem;
	font-weight: 600;
	line-height: 1.15;
}

.single-post .entry-related .loop-entry .entry-title a {
	color: inherit;
	text-decoration: none;
}

.single-post .entry-related .entry-taxonomies a {
	color: var(--sana-b-teal-text);
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	text-decoration: none;
}

/* ------------------------------------------------- refinements (v1.4.1) */
/* One category only (posts also carry the old "Events"/"Featured" terms). */
.post-archive .loop-entry .entry-taxonomies .category-links a ~ a,
.single-post .entry-hero .entry-taxonomies .category-links a ~ a,
.single-post .entry-related .entry-taxonomies .category-links a ~ a {
	display: none;
}

.post-archive .loop-entry .entry-taxonomies .category-links,
.single-post .entry-hero .entry-taxonomies .category-links {
	font-size: 0;
}

.post-archive .loop-entry .entry-taxonomies .category-links a,
.single-post .entry-hero .entry-taxonomies .category-links a {
	font-size: 0.75rem;
}

.single-post .entry-hero .entry-header,
.single-post .entry-hero .entry-meta {
	justify-content: center;
	text-align: center;
}

/* Reading measure about 70 characters. */
.single-post .entry-content.single-content {
	max-width: 44rem;
	margin-left: auto;
	margin-right: auto;
}

.single-post .entry-content p,
.single-post .entry-content ul,
.single-post .entry-content ol {
	margin-bottom: 0;
}

.single-post .entry-content hr {
	margin: 2.75rem 0;
}

.single-post .entry-content hr + h2,
.single-post .entry-content hr + h3 {
	margin-top: 0;
}

.single-post .post-navigation {
	max-width: 44rem;
	margin-left: auto;
	margin-right: auto;
}
