/* ==========================================================================
   InhubWeb — Main stylesheet
   Layout originally extracted from the <style> block in index.html, then
   extended to cover the rest of WordPress's standard views (single, page,
   archive, search, 404, comments).
   ========================================================================== */

/* Layout shell -------------------------------------------------------------*/
body { min-height: 100vh; display: flex; flex-direction: column; }

/* Header bar ---------------------------------------------------------------*/
.site-header.bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 32px;
	padding: 28px 56px;
	border-bottom: 1px solid var(--line);
}
.site-branding .brand-lockup {
	display: inline-flex;
	align-items: center;
	gap: 14px;
	color: inherit;
	text-decoration: none;
}
.site-branding .site-logo img { max-height: 56px; width: auto; height: auto; }

.wm.big { font-size: 28px; }
.mark.sm { width: 36px; height: 36px; font-size: 22px; }

nav.meta {
	display: flex;
	gap: 24px;
	font-family: var(--font-mono);
	font-size: 13px;
	color: var(--muted);
}
nav.meta span.tag { color: var(--ink); }
nav.meta .meta-menu {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	gap: 24px;
}
nav.meta .meta-menu a {
	color: var(--muted);
	text-decoration: none;
}
nav.meta .meta-menu a:hover { color: var(--ink); }

.primary-nav { font-family: var(--font-mono); font-size: 13px; }
.primary-menu {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	gap: 24px;
}
.primary-menu a {
	color: var(--ink);
	text-decoration: none;
	letter-spacing: 0.04em;
	text-transform: uppercase;
}
.primary-menu a:hover { color: var(--clay-2); }

/* Main content -------------------------------------------------------------*/
.site-main {
	flex: 1;
	padding: 80px 56px 56px;
	max-width: 1440px;
	width: 100%;
	margin: 0 auto;
}

.kicker {
	font-family: var(--font-mono);
	font-size: 13px;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--clay);
	margin-bottom: 24px;
}

h1.title {
	font-size: clamp(56px, 7vw, 104px);
	line-height: 0.95;
	letter-spacing: -0.04em;
	font-weight: 500;
	margin: 0 0 28px;
	max-width: 16ch;
}
h1.title em {
	font-style: normal;
	color: var(--muted);
}

p.lede {
	font-size: 20px;
	line-height: 1.5;
	max-width: 56ch;
	color: var(--ink);
	opacity: 0.78;
	margin: 0 0 64px;
}

/* Card grid (hub) ----------------------------------------------------------*/
.grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 24px;
}

a.card {
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	padding: 32px;
	min-height: 420px;
	background: #fff;
	border: 1px solid var(--line);
	text-decoration: none;
	color: var(--ink);
	transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
	position: relative;
	overflow: hidden;
}
a.card:hover,
a.card:focus-visible {
	border-color: var(--ink);
	box-shadow: 0 30px 60px -30px rgba(11, 59, 92, 0.25);
	transform: translateY(-2px);
}
a.card:focus-visible {
	outline: 2px solid var(--clay);
	outline-offset: 2px;
}

a.card .num {
	font-family: var(--font-mono);
	font-size: 13px;
	color: var(--muted);
}
a.card h3 {
	font-size: 36px;
	line-height: 1.05;
	letter-spacing: -0.03em;
	font-weight: 500;
	margin: 24px 0 12px;
}
a.card p {
	font-size: 15px;
	color: var(--ink);
	opacity: 0.7;
	margin: 0;
	line-height: 1.5;
}
a.card .preview {
	flex: 1;
	margin: 32px -32px -32px;
	border-top: 1px solid var(--line);
	display: grid;
	place-items: center;
	background: var(--paper);
	position: relative;
	overflow: hidden;
}
a.card .preview img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}
a.card .cta {
	position: absolute;
	top: 28px;
	right: 28px;
	font-family: var(--font-mono);
	font-size: 12px;
	color: var(--ink);
	opacity: 0;
	transform: translateX(-6px);
	transition: opacity .2s, transform .2s;
}
a.card:hover .cta,
a.card:focus-visible .cta {
	opacity: 1;
	transform: translateX(0);
}

/* Card previews ------------------------------------------------------------*/
.pv-id {
	display: flex;
	align-items: center;
	gap: 14px;
}
.pv-id .swatch { width: 38px; height: 56px; }

.pv-deck {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 6px;
	padding: 22px;
	width: 100%;
	height: 100%;
}
.pv-deck .s {
	background: #fff;
	border: 1px solid var(--line);
	aspect-ratio: 16/9;
	padding: 8px;
	font-size: 7px;
	line-height: 1.2;
}
.pv-deck .s.dark {
	background: var(--ink);
	color: var(--paper);
	border-color: var(--ink);
}
.pv-deck .s.clay {
	background: var(--clay);
	color: var(--paper);
	border-color: var(--clay);
}

.pv-site {
	width: 100%;
	height: 100%;
	padding: 18px;
	display: flex;
	flex-direction: column;
	gap: 8px;
}
.pv-site .nav {
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-family: var(--font-mono);
	font-size: 9px;
}
.pv-site .hero {
	flex: 1;
	background: #fff;
	border: 1px solid var(--line);
	padding: 12px;
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
}
.pv-site .hero h4 {
	margin: 0;
	font-size: 14px;
	letter-spacing: -0.03em;
	font-weight: 500;
}
.pv-site .row {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 4px;
}
.pv-site .row > div {
	aspect-ratio: 1;
	background: var(--paper-2);
	border: 1px solid var(--line);
}
.pv-site .row > div:nth-child(2) { background: var(--ink); }

/* Footer -------------------------------------------------------------------*/
.site-footer {
	padding: 32px 56px;
	border-top: 1px solid var(--line);
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 24px;
	flex-wrap: wrap;
	font-family: var(--font-mono);
	font-size: 12px;
	color: var(--muted);
}
.site-footer .legal {
	display: flex;
	gap: 18px;
}
.footer-menu {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	gap: 18px;
}
.footer-menu a {
	color: var(--muted);
	text-decoration: none;
}
.footer-menu a:hover { color: var(--ink); }

/* ==========================================================================
   Singular & archive views
   ========================================================================== */
.site-main.single,
.site-main.page,
.site-main.archive,
.site-main.search,
.site-main.blog,
.site-main.error-404 {
	max-width: 1024px;
}

.entry-header,
.archive-header {
	margin: 0 0 48px;
}
.entry-title,
.archive-title {
	font-size: clamp(40px, 5vw, 72px);
	line-height: 1;
	letter-spacing: -0.03em;
	font-weight: 500;
	margin: 16px 0 0;
}
.archive-description {
	margin: 16px 0 0;
	color: var(--muted);
	max-width: 60ch;
}

.entry-thumbnail {
	margin: 0 0 32px;
	border: 1px solid var(--line);
	background: var(--paper-2);
	overflow: hidden;
}
.entry-thumbnail img {
	display: block;
	width: 100%;
	height: auto;
}

.entry-content {
	font-size: 18px;
	line-height: 1.65;
	max-width: 70ch;
}
.entry-content p { margin: 0 0 1.4em; }
.entry-content h2 {
	font-size: 32px;
	letter-spacing: -0.02em;
	margin: 2em 0 0.6em;
}
.entry-content h3 {
	font-size: 24px;
	letter-spacing: -0.02em;
	margin: 1.8em 0 0.5em;
}
.entry-content a {
	color: var(--ink);
	text-decoration: underline;
	text-decoration-color: var(--clay);
	text-underline-offset: 3px;
}
.entry-content a:hover { color: var(--clay-2); }
.entry-content blockquote {
	border-left: 3px solid var(--clay);
	margin: 1.4em 0;
	padding: 0.5em 0 0.5em 24px;
	color: var(--ink-2);
	font-size: 22px;
	line-height: 1.45;
}
.entry-content pre,
.entry-content code {
	font-family: var(--font-mono);
}
.entry-content pre {
	background: var(--paper-2);
	border: 1px solid var(--line);
	padding: 20px;
	overflow-x: auto;
	font-size: 14px;
}
.entry-content code {
	background: var(--paper-2);
	padding: 2px 6px;
	font-size: 0.9em;
}

.entry-footer {
	margin: 48px 0 0;
	padding: 24px 0 0;
	border-top: 1px solid var(--line);
	font-family: var(--font-mono);
	font-size: 13px;
	color: var(--muted);
}
.entry-footer .tags {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}
.entry-footer .tags li a {
	border: 1px solid var(--line);
	padding: 4px 10px;
	color: var(--muted);
	text-decoration: none;
}
.entry-footer .tags li a:hover {
	border-color: var(--ink);
	color: var(--ink);
}

/* Post list (archive / blog) ----------------------------------------------*/
.post-list {
	display: grid;
	grid-template-columns: 1fr;
	gap: 24px;
}
.post-card {
	display: grid;
	grid-template-columns: 1fr 240px;
	gap: 32px;
	padding: 32px;
	background: #fff;
	border: 1px solid var(--line);
	align-items: center;
}
.post-card:hover { border-color: var(--ink); }
.post-card .entry-title {
	font-size: 28px;
	margin: 8px 0 12px;
	letter-spacing: -0.02em;
}
.post-card .entry-title a {
	color: inherit;
	text-decoration: none;
}
.post-card .entry-title a:hover { color: var(--clay-2); }
.post-card .entry-summary { color: var(--muted); }
.post-card-thumb { display: block; }
.post-card-thumb img {
	width: 100%;
	height: auto;
	display: block;
}
.post-card.search-result { grid-template-columns: 1fr; }

/* Pagination & post nav ---------------------------------------------------*/
.pagination,
.posts-navigation,
.post-navigation {
	margin: 64px 0 0;
	padding: 24px 0 0;
	border-top: 1px solid var(--line);
	font-family: var(--font-mono);
	font-size: 14px;
}
.pagination .nav-links,
.post-navigation .nav-links {
	display: flex;
	justify-content: space-between;
	gap: 24px;
}
.pagination a,
.pagination span,
.post-navigation a {
	color: var(--ink);
	text-decoration: none;
	padding: 8px 14px;
	border: 1px solid var(--line);
}
.pagination a:hover,
.post-navigation a:hover {
	border-color: var(--ink);
}
.pagination .current {
	background: var(--ink);
	color: var(--paper);
	border-color: var(--ink);
}

/* Comments ----------------------------------------------------------------*/
.comments-area {
	margin: 80px 0 0;
	padding: 40px 0 0;
	border-top: 1px solid var(--line);
	max-width: 70ch;
}
.comments-title {
	font-size: 28px;
	letter-spacing: -0.02em;
	margin: 0 0 24px;
}
.comment-list {
	list-style: none;
	margin: 0 0 32px;
	padding: 0;
}
.comment-list .children {
	list-style: none;
	margin: 16px 0 0 24px;
	padding: 16px 0 0;
	border-left: 1px solid var(--line);
	padding-left: 24px;
}
.comment-body {
	margin: 0 0 24px;
	padding: 24px;
	background: #fff;
	border: 1px solid var(--line);
}
.comment-meta {
	font-family: var(--font-mono);
	font-size: 12px;
	color: var(--muted);
	margin-bottom: 12px;
}
.comment-meta a { color: var(--muted); text-decoration: none; }
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
	width: 100%;
	border: 1px solid var(--line);
	padding: 12px 14px;
	background: #fff;
	font: inherit;
	color: inherit;
}
.comment-form textarea { min-height: 140px; }
.comment-form .submit,
.search-submit {
	font-family: var(--font-mono);
	background: var(--ink);
	color: var(--paper);
	border: 1px solid var(--ink);
	padding: 12px 18px;
	cursor: pointer;
}
.comment-form .submit:hover,
.search-submit:hover {
	background: var(--ink-2);
}

/* Search form -------------------------------------------------------------*/
.search-form {
	display: flex;
	gap: 0;
	max-width: 480px;
	margin: 24px 0;
}
.search-field {
	flex: 1;
	padding: 12px 14px;
	border: 1px solid var(--line);
	background: #fff;
	font: inherit;
}

/* Responsive --------------------------------------------------------------*/
@media (max-width: 1024px) {
	.grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
	.site-header.bar { padding: 20px 24px; flex-wrap: wrap; gap: 16px; }
	.site-main { padding: 56px 24px 40px; }
	.site-footer { padding: 24px; }
	.grid { grid-template-columns: 1fr; gap: 16px; }
	a.card { min-height: 360px; padding: 24px; }
	a.card .preview { margin: 24px -24px -24px; }
	a.card h3 { font-size: 28px; }
	p.lede { font-size: 17px; margin-bottom: 40px; }
	.post-card { grid-template-columns: 1fr; }
	.site-footer { flex-direction: column; align-items: flex-start; }
}

/* Print -------------------------------------------------------------------*/
@media print {
	.site-header,
	.site-footer,
	.cta { display: none !important; }
	body { background: #fff; }
	a.card { border-color: #000; box-shadow: none; transform: none; }
}

/* Motion reduction --------------------------------------------------------*/
@media (prefers-reduced-motion: reduce) {
	a.card,
	a.card .cta {
		transition: none;
	}
	a.card:hover { transform: none; }
}
