/* =========================================================================
   BASIC-256 News index (home.php) and single post (single.php)
   Builds on landing.css (tokens, header/footer, buttons) and release-notes.css
   (the .b256-rn hero band and body wrapper).
   ========================================================================= */

/* ---- News index -------------------------------------------------------- */
.news-list {
	display: grid;
	gap: 20px;
	max-width: 62em;
}

.news-card {
	background: #fff;
	border: 1px solid var(--border);
	border-radius: 14px;
	padding: 26px 28px;
	transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.news-card:hover {
	border-color: #cbd5e1;
	transform: translateY(-2px);
	box-shadow: 0 10px 24px rgba(15, 23, 42, 0.07);
}

.news-card-meta {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-bottom: 10px;
	font-size: 13px;
	color: #64748b;
}

.news-cat {
	font-weight: 700;
	font-size: 11.5px;
	letter-spacing: .06em;
	text-transform: uppercase;
	color: var(--blue);
	background: rgba(37, 99, 235, 0.09);
	border-radius: 999px;
	padding: 3px 10px;
}

.news-card-title {
	font-size: 22px;
	font-weight: 800;
	letter-spacing: -0.01em;
	line-height: 1.25;
	margin: 0 0 10px;
}
.news-card-title a {
	color: var(--text);
	text-decoration: none;
	transition: color .15s ease;
}
.news-card-title a:hover { color: var(--blue); }

.news-card-excerpt {
	color: #475569;
	font-size: 15.5px;
	line-height: 1.65;
	margin: 0 0 14px;
	max-width: 54em;
}

.news-card-more {
	font-size: 14.5px;
	font-weight: 650;
	color: var(--blue);
	text-decoration: none;
}
.news-card-more:hover { text-decoration: underline; }

.news-empty {
	color: #475569;
	font-size: 16px;
}

/* Core's pagination markup, toned down to match. */
.b256-news .navigation.pagination {
	margin-top: 40px;
}
.b256-news .nav-links {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
	align-items: center;
}
.b256-news .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 38px;
	height: 38px;
	padding: 0 12px;
	border: 1px solid var(--border);
	border-radius: 9px;
	background: #fff;
	color: var(--text);
	font-size: 14.5px;
	text-decoration: none;
	transition: border-color .15s ease, color .15s ease;
}
.b256-news .page-numbers:hover { border-color: var(--blue-2); color: var(--blue); }
.b256-news .page-numbers.current {
	background: var(--blue);
	border-color: var(--blue);
	color: #fff;
	font-weight: 650;
}
.b256-news .screen-reader-text {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

/* ---- Single post ------------------------------------------------------- */
/* the_content() output, so these are bare element selectors scoped to the
   article rather than classes the editor would have to remember to apply. */
.b256-post-body {
	max-width: 46em;
	color: #334155;
	font-size: 16.5px;
	line-height: 1.75;
}

.b256-post-body h2 {
	font-size: 23px;
	font-weight: 800;
	letter-spacing: -0.01em;
	color: var(--text);
	margin: 40px 0 14px;
}
.b256-post-body h2:first-child { margin-top: 0; }

.b256-post-body h3 {
	font-size: 18.5px;
	font-weight: 700;
	color: var(--text);
	margin: 30px 0 10px;
}

.b256-post-body p { margin: 0 0 16px; }

.b256-post-body ul,
.b256-post-body ol {
	margin: 0 0 18px;
	padding-left: 22px;
}
.b256-post-body li { margin-bottom: 9px; }

.b256-post-body a {
	color: var(--blue);
	text-decoration: underline;
	text-underline-offset: 2px;
}
.b256-post-body a:hover { color: var(--blue-2); }

.b256-post-body strong { color: var(--text); font-weight: 700; }

.b256-post-body code {
	background: #e2e8f0;
	color: #0f172a;
	padding: 2px 6px;
	border-radius: 5px;
	font-size: 0.88em;
	font-family: "SFMono-Regular", Consolas, Menlo, monospace;
}

.b256-post-body kbd {
	background: #f8fafc;
	border: 1px solid #cbd5e1;
	border-bottom-width: 2px;
	border-radius: 5px;
	padding: 1px 6px;
	font-size: 0.85em;
	font-family: "SFMono-Regular", Consolas, Menlo, monospace;
	color: #0f172a;
}

.b256-post-body blockquote {
	margin: 0 0 18px;
	padding: 4px 0 4px 18px;
	border-left: 3px solid var(--blue-2);
	color: #475569;
}

/* ---- Prev / next ------------------------------------------------------- */
.post-nav {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 16px;
	margin-top: 52px;
	padding-top: 32px;
	border-top: 1px solid var(--border);
	max-width: 62em;
}

.post-nav-link {
	display: block;
	background: #fff;
	border: 1px solid var(--border);
	border-radius: 12px;
	padding: 18px 20px;
	text-decoration: none;
	transition: border-color .15s ease, transform .15s ease;
}
.post-nav-link:hover { border-color: var(--blue-2); transform: translateY(-2px); }

/* When only an older post exists, keep it in the right-hand column so the
   direction of travel still reads left-to-right. */
.post-nav-older { grid-column: 2; text-align: right; }

.post-nav-dir {
	display: block;
	font-size: 12.5px;
	font-weight: 700;
	letter-spacing: .05em;
	text-transform: uppercase;
	color: #64748b;
	margin-bottom: 6px;
}
.post-nav-title {
	display: block;
	font-size: 15.5px;
	font-weight: 650;
	color: var(--text);
	line-height: 1.4;
}

/* ---- Responsive -------------------------------------------------------- */
@media (max-width: 780px) {
	.news-card { padding: 22px 20px; }
	.news-card-title { font-size: 19.5px; }
	.post-nav { grid-template-columns: 1fr; }
	.post-nav-older { grid-column: 1; text-align: left; }
}
