/* ==========================================================================
   Blog: posts page, single article, archives, search
   
   ========================================================================== */

.post-feature {
	position: relative;
	display: grid;
	margin-bottom: clamp(36px, 5vw, 56px);
	border-radius: var(--radius-lg);
	background: var(--paper);
	box-shadow: var(--shadow-sm);
	overflow: hidden;
}

@media (min-width: 900px) {
	.post-feature {
		grid-template-columns: 1.2fr 1fr;
	}
}

.post-feature__media {
	display: block;
	min-height: 300px;
	overflow: hidden;
}

.post-feature__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 1.2s var(--ease);
}

.post-feature:hover .post-feature__media img {
	transform: scale(1.05);
}

.post-feature__body {
	align-self: center;
	padding: clamp(26px, 4vw, 48px);
}

.post-feature__title {
	font-size: clamp(1.7rem, 1.3rem + 1.4vw, 2.5rem);
}

.post-feature__title a {
	text-decoration: none;
}

/* ---------- Single article ---------- */

.article-hero {
	padding-block: clamp(56px, 8vw, 100px) 32px;
	background:
		radial-gradient(50% 80% at 100% 0%, rgba(159, 217, 79, 0.16), transparent 70%),
		var(--sand);
}

.article-hero .breadcrumbs li,
.article-hero .breadcrumbs a {
	color: var(--muted);
}

.article-hero .breadcrumbs [aria-current] {
	color: var(--moss);
}

.article-hero__title {
	font-size: clamp(2.2rem, 1.5rem + 3vw, 3.8rem);
	font-weight: 300;
	letter-spacing: -0.02em;
}

.article-hero__lead {
	font-size: var(--fs-lg);
	color: var(--muted);
}

.article-thumb {
	max-width: 1120px;
	margin-top: -8px;
}

.article-thumb img {
	width: 100%;
	max-height: 600px;
	object-fit: cover;
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow);
}

.article-layout {
	display: grid;
	gap: 48px;
	max-width: 1120px;
	padding-block: 48px var(--section);
}

@media (min-width: 1040px) {
	.article-layout {
		grid-template-columns: minmax(0, 1fr) 300px;
		gap: 64px;
		align-items: start;
	}
	.article-aside {
		position: sticky;
		top: 150px;
	}
}

.article-share {
	display: flex;
	align-items: center;
	gap: 10px;
	margin-top: 40px;
	padding-top: 24px;
	border-top: 1px solid var(--line);
}

.article-share span {
	font-size: 0.8rem;
	font-weight: 800;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--muted);
}

.article-share a {
	display: grid;
	place-items: center;
	width: 42px;
	height: 42px;
	border-radius: 50%;
	background: var(--sand);
	color: var(--ink);
	transition: background-color 0.3s, color 0.3s;
}

.article-share a:hover {
	background: var(--ink);
	color: #fff;
}

.article-tags {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 20px;
}

.article-tags a {
	padding: 5px 12px;
	border-radius: var(--pill);
	background: var(--sand);
	font-size: 0.82rem;
	font-weight: 700;
	text-decoration: none;
}

.book-card--mini p {
	color: var(--muted);
}

.post-nav {
	padding-bottom: var(--section);
}

.post-nav .nav-links {
	display: grid;
	gap: 16px;
	justify-content: stretch;
}

@media (min-width: 700px) {
	.post-nav .nav-links {
		grid-template-columns: 1fr 1fr;
	}
}

.post-nav a {
	display: grid;
	gap: 4px;
	height: 100%;
	padding: 20px 22px;
	border: 1.5px solid var(--line);
	border-radius: var(--radius);
	text-decoration: none;
	transition: border-color 0.3s;
}

.post-nav a:hover {
	border-color: var(--ink);
}

.post-nav .nav-next a {
	text-align: right;
}

.post-nav small {
	font-size: 0.75rem;
	font-weight: 800;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--moss);
}

.post-nav span {
	font-family: var(--serif);
	font-size: 1.15rem;
	color: var(--ink);
}

/* ---------- Comments ---------- */

.comments {
	padding-bottom: var(--section);
}

.comment-list {
	margin: 0 0 40px;
	padding: 0;
	list-style: none;
}

.comment-list .comment {
	padding: 20px 0;
	border-bottom: 1px solid var(--line);
}

.comment-list .children {
	list-style: none;
	padding-left: 28px;
}

.comment-author img {
	float: left;
	margin-right: 12px;
	border-radius: 50%;
}

.comment-metadata {
	font-size: 0.8rem;
	color: var(--muted);
}

.comment-form {
	display: grid;
	gap: 14px;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
	width: 100%;
	padding: 12px 16px;
	border: 1.5px solid var(--line);
	border-radius: 14px;
	background: var(--paper);
}

.comment-form label {
	display: block;
	margin-bottom: 4px;
	font-size: 0.86rem;
	font-weight: 700;
}

/* ---------- Reading progress (pages/blog.js) ---------- */

.reading-progress {
	position: fixed;
	left: 0;
	right: 0;
	top: 0;
	z-index: 200;
	height: 3px;
	background: linear-gradient(90deg, var(--coral-deep), var(--saffron));
	transform: scaleX(0);
	transform-origin: left;
}

.admin-bar .reading-progress {
	top: 32px;
}

@media (max-width: 782px) {
	.admin-bar .reading-progress {
		top: 46px;
	}
}
