/**
 * VGHQ — layout and design.
 *
 * Loads after the child style.css so site overrides stay possible.
 *
 * Contents
 *   1.  Tokens
 *   2.  Base
 *   3.  Primitives (eyebrow, chip, button, meta, section header)
 *   4.  Header and nav
 *   5.  Shell and layout
 *   6.  Cards
 *   7.  Rail and widgets
 *   8.  Loader and pagination
 *   9.  Archive header and author card
 *   10. Single post
 *   11. Comments
 *   12. Search overlay
 *   13. Footer
 *   14. Responsive
 *   15. Motion and print
 */

/* ============================================================ 1. Tokens == */

:root {
	--vg-bg: #0a0d13;
	--vg-panel: #10141d;
	--vg-panel-2: #161c28;
	--vg-line: #1e2634;
	--vg-line-2: #2b3547;
	--vg-text: #e9edf5;
	--vg-dim: #97a3ba;
	--vg-mute: #66728a;
	--vg-hot: #ff3d71;

	/* --vg-accent and friends are injected inline from the Customizer. */
	--vg-accent: #00e7b4;
	--vg-accent-soft: rgba(0, 231, 180, 0.14);
	--vg-accent-line: rgba(0, 231, 180, 0.38);
	--vg-accent-glow: rgba(0, 231, 180, 0.22);

	--vg-display: "Space Grotesk", "Inter", system-ui, -apple-system, sans-serif;
	--vg-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
	--vg-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

	--vg-shell: 1320px;
	--vg-gap: 28px;
	--vg-radius: 10px;
	--vg-radius-sm: 5px;
	--vg-ease: cubic-bezier(0.2, 0.7, 0.3, 1);
}

/* Light scheme keeps every token name identical — only the values move. */
.vg-scheme-light {
	--vg-bg: #f7f8fa;
	--vg-panel: #ffffff;
	--vg-panel-2: #f0f2f6;
	--vg-line: #e2e6ee;
	--vg-line-2: #cdd4e0;
	--vg-text: #10141d;
	--vg-dim: #4d5768;
	--vg-mute: #77839a;
}

/* ============================================================== 2. Base == */

body.vghq {
	background: var(--vg-bg);
	color: var(--vg-text);
	font-family: var(--vg-body);
	font-size: 16px;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
}

body.vghq a {
	color: inherit;
	text-decoration: none;
}

body.vghq h1,
body.vghq h2,
body.vghq h3,
body.vghq h4 {
	font-family: var(--vg-display);
	font-weight: 700;
	letter-spacing: -0.02em;
	line-height: 1.15;
	color: var(--vg-text);
}

body.vghq img {
	max-width: 100%;
	height: auto;
}

body.vghq :focus-visible {
	outline: 2px solid var(--vg-accent);
	outline-offset: 3px;
	border-radius: 2px;
}

body.vg-locked {
	overflow: hidden;
}

/*
 * Everything below sets an explicit `display`, which beats the plain
 * `[hidden]` rule GeneratePress inherits from normalize. Without this a JS
 * `el.hidden = true` is silently ignored: the search overlay stays laid over
 * the page swallowing clicks, and the loader button and fallback pagination
 * never go away.
 */
body.vghq [hidden] {
	display: none !important;
}

/*
 * An AdSense unit that fails to fill still holds the height it reserved, which
 * reads as a dead band under the header. Google stamps the slot with
 * data-ad-status="unfilled" when that happens, so this collapses only the
 * genuinely empty ones and never touches a unit that filled.
 */
body.vghq ins.adsbygoogle[data-ad-status="unfilled"] {
	display: none !important;
}

/* Our templates manage their own width — stand GeneratePress's container down. */
body.vg-tpl #page,
body.vg-tpl #page.grid-container,
body.vg-tpl #content {
	max-width: none;
	width: 100%;
	margin: 0;
	padding: 0;
	background: none;
	border: 0;
	box-shadow: none;
	display: block;
}

body.vg-tpl .site-main,
body.vg-tpl .content-area {
	width: 100%;
	margin: 0;
	padding: 0;
}

/* ======================================================== 3. Primitives == */

.vg-eyebrow {
	display: inline-block;
	font-family: var(--vg-mono);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--vg-mute);
}

.vg-chip {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 4px 9px;
	border: 1px solid var(--vg-accent-line);
	border-radius: var(--vg-radius-sm);
	background: var(--vg-accent-soft);
	color: var(--vg-accent);
	font-family: var(--vg-mono);
	font-size: 10.5px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	line-height: 1.4;
	transition: background 0.15s var(--vg-ease), border-color 0.15s var(--vg-ease);
}

.vg-chip:hover {
	background: var(--vg-accent);
	border-color: var(--vg-accent);
	color: var(--vg-bg);
}

.vg-chip__count {
	color: inherit;
	opacity: 0.55;
	font-size: 10px;
}

.vg-chiprow {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
}

.vg-chiprow--sections {
	padding: 18px 0;
	margin-bottom: 8px;
	border-top: 1px solid var(--vg-line);
	border-bottom: 1px solid var(--vg-line);
}

.vg-chiprow--sections .vg-eyebrow {
	margin-right: 4px;
}

.vg-chiprow--tags {
	margin: 40px 0 0;
}

.vg-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 11px 20px;
	border: 1px solid var(--vg-accent);
	border-radius: var(--vg-radius-sm);
	background: var(--vg-accent);
	color: #05070b;
	font-family: var(--vg-mono);
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	cursor: pointer;
	transition: filter 0.15s var(--vg-ease), box-shadow 0.15s var(--vg-ease);
}

.vg-btn:hover {
	filter: brightness(1.1);
	box-shadow: 0 0 0 4px var(--vg-accent-glow);
}

.vg-meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 7px;
	font-family: var(--vg-mono);
	font-size: 11.5px;
	letter-spacing: 0.03em;
	color: var(--vg-mute);
}

.vg-meta a {
	color: var(--vg-dim);
	transition: color 0.15s var(--vg-ease);
}

.vg-meta a:hover {
	color: var(--vg-accent);
}

.vg-meta__sep {
	opacity: 0.45;
}

.vg-meta__author {
	font-weight: 700;
}

.vg-sechead {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 16px;
	margin: 0 0 22px;
	padding-bottom: 12px;
	border-bottom: 1px solid var(--vg-line);
	position: relative;
}

/* The short accent rule that sits on the section divider. */
.vg-sechead::after {
	content: "";
	position: absolute;
	left: 0;
	bottom: -1px;
	width: 56px;
	height: 2px;
	background: var(--vg-accent);
}

.vg-sechead__title {
	display: flex;
	align-items: center;
	gap: 9px;
	margin: 0;
	font-size: 19px;
	letter-spacing: 0.01em;
	text-transform: uppercase;
}

.vg-sechead__icon {
	color: var(--vg-accent);
}

.vg-sechead__more {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	font-family: var(--vg-mono);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--vg-dim);
	white-space: nowrap;
	transition: color 0.15s var(--vg-ease);
}

.vg-sechead__more:hover {
	color: var(--vg-accent);
}

.vg-sechead--rail .vg-sechead__title {
	font-size: 14px;
}

.vg-empty {
	display: grid;
	justify-items: center;
	gap: 14px;
	padding: 72px 24px;
	border: 1px dashed var(--vg-line-2);
	border-radius: var(--vg-radius);
	color: var(--vg-dim);
	text-align: center;
}

.vg-empty svg {
	color: var(--vg-accent);
}

/* ======================================================= 4. Header & nav == */

body.vghq .site-header {
	background: var(--vg-panel);
	border-bottom: 1px solid var(--vg-line);
}

body.vg-sticky .site-header {
	position: sticky;
	top: 0;
	z-index: 120;
	transition: box-shadow 0.2s var(--vg-ease), background 0.2s var(--vg-ease);
}

body.vg-sticky.vg-scrolled .site-header {
	background: rgba(16, 20, 29, 0.92);
	backdrop-filter: blur(12px);
	box-shadow: 0 8px 28px rgba(0, 0, 0, 0.4);
}

.vg-scheme-light.vg-sticky.vg-scrolled .site-header {
	background: rgba(255, 255, 255, 0.9);
	box-shadow: 0 8px 28px rgba(16, 20, 29, 0.09);
}

body.vghq .site-logo img,
body.vghq .site-title {
	font-family: var(--vg-display);
	font-weight: 700;
	letter-spacing: -0.03em;
}

body.vghq .main-navigation .menu-bar-items {
	display: flex;
	align-items: center;
	gap: 8px;
	padding-left: 10px;
}

.vg-navbtn {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	padding: 8px 10px;
	border: 1px solid transparent;
	border-radius: var(--vg-radius-sm);
	background: none;
	color: var(--vg-dim);
	font-family: var(--vg-mono);
	font-size: 11.5px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	cursor: pointer;
	transition: color 0.15s var(--vg-ease), border-color 0.15s var(--vg-ease), background 0.15s var(--vg-ease);
}

.vg-navbtn:hover {
	color: var(--vg-text);
	border-color: var(--vg-line-2);
}

.vg-navbtn--cta {
	border-color: var(--vg-accent-line);
	background: var(--vg-accent-soft);
	color: var(--vg-accent);
}

.vg-navbtn--cta:hover {
	background: var(--vg-accent);
	border-color: var(--vg-accent);
	color: #05070b;
}

/* --- GeneratePress navigation, dressed for the dark theme --- */

/*
 * GP paints the nav from its own Customizer colours (white out of the box).
 * Ours is part of the header bar, so it stays transparent there and only
 * carries a background when GP is set to a separate nav row.
 */
body.vghq .main-navigation {
	background: var(--vg-panel);
	border-bottom: 1px solid var(--vg-line);
}

body.vghq .site-header .main-navigation,
body.vghq .main-navigation.has-branding {
	background: transparent;
	border-bottom: 0;
}

body.vghq .main-navigation .inside-navigation,
body.vghq .main-navigation .main-nav > ul {
	background: transparent;
}

body.vghq .main-navigation .main-nav ul li a {
	font-family: var(--vg-mono);
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--vg-dim);
	background: transparent;
	transition: color 0.15s var(--vg-ease);
}

body.vghq .main-navigation .main-nav ul li:hover > a,
body.vghq .main-navigation .main-nav ul li:focus-within > a,
body.vghq .main-navigation .main-nav ul li.current-menu-item > a {
	color: var(--vg-text);
	background: transparent;
}

body.vghq .main-navigation .main-nav > ul > li.current-menu-item > a {
	box-shadow: inset 0 -2px 0 var(--vg-accent);
}

/* Dropdowns get the panel treatment rather than GP's white sheet. */
body.vghq .main-navigation ul ul {
	width: 232px;
	padding: 6px;
	background: var(--vg-panel-2);
	border: 1px solid var(--vg-line-2);
	border-radius: var(--vg-radius-sm);
	box-shadow: 0 20px 44px rgba(0, 0, 0, 0.45);
}

body.vghq .main-navigation ul ul li a {
	padding: 9px 11px;
	border-radius: var(--vg-radius-sm);
	line-height: 1.4;
	letter-spacing: 0.06em;
}

body.vghq .main-navigation ul ul li:hover > a,
body.vghq .main-navigation ul ul li:focus-within > a,
body.vghq .main-navigation ul ul li.current-menu-item > a {
	background: var(--vg-accent-soft);
	color: var(--vg-accent);
	box-shadow: none;
}

body.vghq .main-navigation .dropdown-menu-toggle {
	color: inherit;
}

/* Mobile toggle and the panel it opens. */
body.vghq .main-navigation .menu-toggle {
	background: transparent;
	color: var(--vg-dim);
	font-family: var(--vg-mono);
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
}

body.vghq .main-navigation .menu-toggle:hover,
body.vghq .main-navigation .menu-toggle:focus,
body.vghq .main-navigation.toggled .menu-toggle {
	background: transparent;
	color: var(--vg-text);
}

body.vghq .main-navigation.toggled .main-nav > ul {
	background: var(--vg-panel);
	border-top: 1px solid var(--vg-line);
}

body.vghq .main-navigation.toggled .main-nav ul ul {
	width: auto;
	border: 0;
	background: transparent;
	box-shadow: none;
}

/* GP's optional nav search field. */
body.vghq .navigation-search input[type="search"] {
	background: var(--vg-panel-2);
	color: var(--vg-text);
}

/* ==================================================== 5. Shell & layout == */

.vg-shell {
	width: 100%;
	max-width: var(--vg-shell);
	margin-inline: auto;
	padding-inline: 24px;
}

.vg-homewrap,
.vg-archivewrap {
	padding-block: 32px 72px;
}

.vg-layout {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 320px;
	gap: 52px;
	align-items: start;
}

.vg-layout--full {
	grid-template-columns: minmax(0, 1fr);
}

.vg-layout__main {
	min-width: 0;
}

.vg-grid {
	display: grid;
	gap: var(--vg-gap);
	grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}

.vg-grid--related {
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}

/* --- hero --- */

.vg-hero {
	display: grid;
	grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
	gap: var(--vg-gap);
	margin-bottom: 34px;
}

.vg-hero__stack {
	display: grid;
	gap: 14px;
	align-content: start;
}

/* ============================================================= 6. Cards == */

.vg-card {
	position: relative;
	min-width: 0;
}

.vg-card__media {
	display: block;
	position: relative;
	overflow: hidden;
	border-radius: var(--vg-radius-sm);
	background: var(--vg-panel-2);
	aspect-ratio: 16 / 9;
}

.vg-card__media img,
.vg-thumb__img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform 0.5s var(--vg-ease), opacity 0.3s var(--vg-ease);
}

.vg-card:hover .vg-card__media img {
	transform: scale(1.04);
}

.vg-thumb__ph {
	display: grid;
	place-items: center;
	width: 100%;
	height: 100%;
	background:
		linear-gradient(135deg,
			hsl(var(--vg-ph-hue, 200) 48% 20%),
			hsl(calc(var(--vg-ph-hue, 200) + 45) 60% 11%));
}

.vg-thumb__ph span {
	font-family: var(--vg-mono);
	font-size: 15px;
	font-weight: 700;
	letter-spacing: 0.24em;
	text-transform: uppercase;
	color: rgba(255, 255, 255, 0.34);
}

.vg-card__body {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 9px;
	padding-top: 14px;
}

.vg-card__title {
	margin: 0;
	font-size: 17px;
	line-height: 1.28;
}

.vg-card__title a {
	background-image: linear-gradient(var(--vg-accent), var(--vg-accent));
	background-size: 0 1px;
	background-repeat: no-repeat;
	background-position: 0 100%;
	transition: background-size 0.3s var(--vg-ease), color 0.15s var(--vg-ease);
}

.vg-card:hover .vg-card__title a {
	background-size: 100% 1px;
}

/* --- lead --- */

.vg-card--lead {
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	min-height: 460px;
	height: 100%;
	border-radius: var(--vg-radius);
	overflow: hidden;
	background: var(--vg-panel-2);
}

.vg-card--lead .vg-card__media {
	position: absolute;
	inset: 0;
	border-radius: 0;
	aspect-ratio: auto;
}

.vg-card--lead .vg-card__scrim {
	position: absolute;
	inset: 0;
	background: linear-gradient(
		to top,
		rgba(5, 7, 11, 0.96) 0%,
		rgba(5, 7, 11, 0.78) 34%,
		rgba(5, 7, 11, 0.22) 68%,
		rgba(5, 7, 11, 0.05) 100%
	);
}

.vg-card--lead .vg-card__body {
	position: relative;
	z-index: 2;
	padding: 30px;
	gap: 12px;
}

.vg-card--lead .vg-card__title {
	font-size: clamp(26px, 3.1vw, 40px);
	line-height: 1.08;
	color: #fff;
}

.vg-card--lead .vg-meta {
	color: rgba(255, 255, 255, 0.62);
}

.vg-card--lead .vg-meta a {
	color: rgba(255, 255, 255, 0.78);
}

/* Corner bracket — a small nod to a HUD frame. */
.vg-card--lead::after {
	content: "";
	position: absolute;
	top: 16px;
	right: 16px;
	width: 26px;
	height: 26px;
	border-top: 2px solid var(--vg-accent);
	border-right: 2px solid var(--vg-accent);
	opacity: 0.75;
	z-index: 2;
	pointer-events: none;
}

/* --- feature (wide archive lead) --- */

.vg-card--feature {
	display: grid;
	grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
	gap: 30px;
	align-items: center;
	padding: 22px;
	border: 1px solid var(--vg-line);
	border-radius: var(--vg-radius);
	background: var(--vg-panel);
	margin-bottom: 40px;
}

.vg-card--feature .vg-card__media {
	border-radius: var(--vg-radius-sm);
}

.vg-card--feature .vg-card__body {
	padding-top: 0;
	gap: 13px;
}

.vg-card--feature .vg-card__title {
	font-size: clamp(21px, 2.2vw, 30px);
}

/* --- standard (grid) --- */

.vg-card--standard {
	display: flex;
	flex-direction: column;
	transition: transform 0.25s var(--vg-ease);
}

.vg-card--standard:hover {
	transform: translateY(-3px);
}

/* Newly appended cards fade in rather than snapping. The --new rules need the
   doubled class so they outrank the plain variant rule above. */
.vg-card--standard,
.vg-card--compact {
	transition: opacity 0.35s var(--vg-ease), transform 0.35s var(--vg-ease);
}

.vg-card.vg-card--new {
	opacity: 0;
	transform: translateY(10px);
}

/* --- compact (hero stack, rails) --- */

.vg-card--compact {
	display: grid;
	grid-template-columns: 118px minmax(0, 1fr);
	gap: 14px;
	align-items: start;
	padding-bottom: 14px;
	border-bottom: 1px solid var(--vg-line);
}

.vg-hero__stack .vg-card--compact:last-child {
	border-bottom: 0;
	padding-bottom: 0;
}

.vg-card--compact .vg-card__body {
	padding-top: 0;
	gap: 6px;
}

.vg-card--compact .vg-card__title {
	font-size: 15px;
	line-height: 1.3;
}

.vg-card--compact .vg-chip {
	font-size: 9.5px;
	padding: 2px 7px;
}

/* --- rank (trending list) --- */

.vg-ranklist {
	display: grid;
	gap: 0;
	margin: 0;
	padding: 0;
	list-style: none;
	counter-reset: vg-rank;
}

.vg-card--rank {
	display: grid;
	grid-template-columns: 44px minmax(0, 1fr);
	gap: 12px;
	align-items: start;
	padding: 15px 0;
	border-bottom: 1px solid var(--vg-line);
}

.vg-card--rank:last-child {
	border-bottom: 0;
}

.vg-card__rank {
	font-family: var(--vg-mono);
	font-size: 21px;
	font-weight: 700;
	line-height: 1;
	color: transparent;
	-webkit-text-stroke: 1px var(--vg-line-2);
	transition: -webkit-text-stroke-color 0.2s var(--vg-ease), color 0.2s var(--vg-ease);
}

.vg-card--rank:hover .vg-card__rank {
	color: var(--vg-accent);
	-webkit-text-stroke-color: var(--vg-accent);
}

.vg-card--rank .vg-card__body {
	padding-top: 0;
	gap: 5px;
}

.vg-card--rank .vg-card__title {
	font-size: 14.5px;
	line-height: 1.32;
}

/* --- headline (text only) --- */

.vg-card--headline .vg-card__body {
	padding-top: 0;
}

/* ==================================================== 7. Rail & widgets == */

.vg-rail {
	position: sticky;
	top: 92px;
	display: grid;
	gap: 30px;
	align-self: start;
}

body:not(.vg-sticky) .vg-rail {
	top: 28px;
}

.vg-widget {
	padding: 20px;
	border: 1px solid var(--vg-line);
	border-radius: var(--vg-radius);
	background: var(--vg-panel);
}

.vg-widget .vg-sechead {
	margin-bottom: 6px;
}

.vg-widget ul {
	margin: 0;
	padding: 0;
	list-style: none;
}

/* =============================================== 8. Loader & pagination == */

.vg-loader {
	display: grid;
	justify-items: center;
	gap: 12px;
	padding: 44px 0 8px;
	min-height: 60px;
}

.vg-loader__btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 13px 26px;
	border: 1px solid var(--vg-line-2);
	border-radius: var(--vg-radius-sm);
	background: var(--vg-panel);
	color: var(--vg-text);
	font-family: var(--vg-mono);
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	cursor: pointer;
	transition: border-color 0.15s var(--vg-ease), color 0.15s var(--vg-ease), box-shadow 0.15s var(--vg-ease);
}

.vg-loader__btn:hover:not(:disabled) {
	border-color: var(--vg-accent);
	color: var(--vg-accent);
	box-shadow: 0 0 0 4px var(--vg-accent-glow);
}

.vg-loader__btn:disabled {
	opacity: 0.55;
	cursor: default;
}

.vg-loader__msg {
	margin: 0;
	font-family: var(--vg-mono);
	font-size: 11.5px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--vg-mute);
}

/* Animated rule while a page is in flight. */
.vg-loader.is-busy .vg-loader__msg::after {
	content: "";
	display: block;
	width: 120px;
	height: 2px;
	margin: 10px auto 0;
	background: linear-gradient(90deg, transparent, var(--vg-accent), transparent);
	background-size: 200% 100%;
	animation: vg-scan 1.1s linear infinite;
}

@keyframes vg-scan {
	from { background-position: 200% 0; }
	to { background-position: -200% 0; }
}

/*
 * The paginated links are printed for crawlers and for readers with no JS.
 * The `vg-js` class lands on <html> before first paint, so nobody running JS
 * ever sees them flash in under the infinite feed; `is-shown` puts them back
 * if a request fails and the loader gives up.
 */
.vg-js .vg-pagination--fallback {
	display: none;
}

.vg-js .vg-pagination--fallback.is-shown {
	display: flex;
}

.vg-pagination {
	display: flex;
	justify-content: center;
	gap: 8px;
	padding: 36px 0 0;
	font-family: var(--vg-mono);
	font-size: 12px;
}

.vg-pagination .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 38px;
	height: 38px;
	padding: 0 12px;
	border: 1px solid var(--vg-line);
	border-radius: var(--vg-radius-sm);
	color: var(--vg-dim);
	transition: border-color 0.15s var(--vg-ease), color 0.15s var(--vg-ease);
}

.vg-pagination .page-numbers:hover,
.vg-pagination .page-numbers.current {
	border-color: var(--vg-accent);
	color: var(--vg-accent);
}

/* ======================================= 9. Archive header & author card == */

.vg-archhead {
	display: grid;
	justify-items: start;
	gap: 10px;
	padding: 26px 0 30px;
	margin-bottom: 34px;
	border-bottom: 1px solid var(--vg-line);
	position: relative;
}

.vg-archhead::after {
	content: "";
	position: absolute;
	left: 0;
	bottom: -1px;
	width: 72px;
	height: 2px;
	background: var(--vg-accent);
}

.vg-archhead__title {
	margin: 0;
	font-size: clamp(30px, 4.4vw, 50px);
	text-transform: uppercase;
	letter-spacing: -0.025em;
}

.vg-archhead__sub {
	margin: 0;
	max-width: 68ch;
	color: var(--vg-dim);
	font-size: 16px;
}

.vg-archhead__count {
	font-family: var(--vg-mono);
	font-size: 11.5px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--vg-accent);
}

.vg-archhead--author {
	border-bottom: 0;
	padding-bottom: 0;
}

.vg-archhead--author::after {
	display: none;
}

/* --- author card --- */

.vg-authorcard {
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	gap: 22px;
	align-items: start;
}

.vg-authorcard--hero {
	width: 100%;
	padding: 30px;
	border: 1px solid var(--vg-line);
	border-radius: var(--vg-radius);
	background: var(--vg-panel);
	margin-bottom: 34px;
	position: relative;
	overflow: hidden;
}

/* Faint accent wash behind the author hero. */
.vg-authorcard--hero::before {
	content: "";
	position: absolute;
	inset: 0 0 auto 0;
	height: 3px;
	background: linear-gradient(90deg, var(--vg-accent), transparent);
}

.vg-authorcard--box {
	margin-top: 48px;
	padding: 26px;
	border: 1px solid var(--vg-line);
	border-radius: var(--vg-radius);
	background: var(--vg-panel);
}

.vg-authorcard__img,
.vg-authorcard img {
	border-radius: 50%;
	display: block;
	border: 2px solid var(--vg-line-2);
}

.vg-authorcard__body {
	display: grid;
	justify-items: start;
	gap: 9px;
}

.vg-authorcard__name {
	margin: 0;
	font-size: 24px;
}

.vg-authorcard--hero .vg-authorcard__name {
	font-size: clamp(28px, 3.6vw, 42px);
	text-transform: uppercase;
}

.vg-authorcard__bio {
	margin: 0;
	max-width: 70ch;
	color: var(--vg-dim);
	font-size: 15px;
	line-height: 1.6;
}

.vg-authorcard__foot {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 18px;
	font-family: var(--vg-mono);
	font-size: 11.5px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.vg-authorcard__count {
	color: var(--vg-accent);
}

.vg-authorcard__link {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	color: var(--vg-dim);
	transition: color 0.15s var(--vg-ease);
}

.vg-authorcard__link:hover {
	color: var(--vg-accent);
}

/* ======================================================= 10. Single post == */

.vg-progress {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	height: 3px;
	z-index: 200;
	background: transparent;
	pointer-events: none;
}

.vg-progress span {
	display: block;
	height: 100%;
	width: 100%;
	transform: scaleX(0);
	transform-origin: 0 50%;
	background: linear-gradient(90deg, var(--vg-accent), var(--vg-hot));
}

.vg-single__head {
	padding-block: 40px 26px;
	max-width: 900px;
}

.vg-crumbs {
	display: flex;
	align-items: center;
	gap: 7px;
	margin-bottom: 16px;
	font-family: var(--vg-mono);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--vg-mute);
}

.vg-crumbs a {
	color: var(--vg-mute);
	transition: color 0.15s var(--vg-ease);
}

.vg-crumbs a:hover {
	color: var(--vg-accent);
}

.vg-crumbs a:last-child {
	color: var(--vg-accent);
}

.vg-single__title {
	margin: 0 0 16px;
	font-size: clamp(30px, 4.6vw, 54px);
	line-height: 1.06;
	letter-spacing: -0.03em;
}

.vg-single__stand {
	margin: 0 0 26px;
	max-width: 66ch;
	color: var(--vg-dim);
	font-size: clamp(17px, 1.5vw, 20px);
	line-height: 1.5;
}

.vg-byline {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 18px;
	padding-top: 20px;
	border-top: 1px solid var(--vg-line);
}

.vg-byline__who {
	display: flex;
	align-items: center;
	gap: 13px;
}

.vg-byline__avatar img {
	border-radius: 50%;
	display: block;
	border: 2px solid var(--vg-line-2);
}

.vg-byline__text {
	display: grid;
	gap: 3px;
}

.vg-byline__name {
	font-family: var(--vg-display);
	font-size: 15px;
	font-weight: 700;
	transition: color 0.15s var(--vg-ease);
}

.vg-byline__name:hover {
	color: var(--vg-accent);
}

.vg-single__media {
	margin: 0 auto 40px;
}

.vg-single__media img {
	width: 100%;
	border-radius: var(--vg-radius);
	display: block;
}

.vg-single__media figcaption {
	margin-top: 10px;
	font-family: var(--vg-mono);
	font-size: 11.5px;
	color: var(--vg-mute);
	text-align: center;
}

.vg-single__body {
	display: grid;
	grid-template-columns: 56px minmax(0, 1fr) 320px;
	gap: 40px;
	align-items: start;
	padding-bottom: 72px;
}

.vg-single__sharerail {
	position: sticky;
	top: 110px;
}

.vg-single__content {
	min-width: 0;
}

/* --- share --- */

.vg-share {
	display: flex;
	align-items: center;
	gap: 8px;
}

.vg-share__label {
	font-family: var(--vg-mono);
	font-size: 10.5px;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--vg-mute);
}

.vg-share__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	padding: 0;
	border: 1px solid var(--vg-line);
	border-radius: var(--vg-radius-sm);
	background: var(--vg-panel);
	color: var(--vg-dim);
	cursor: pointer;
	transition: color 0.15s var(--vg-ease), border-color 0.15s var(--vg-ease), transform 0.15s var(--vg-ease);
}

.vg-share__btn:hover {
	color: var(--vg-accent);
	border-color: var(--vg-accent);
	transform: translateY(-2px);
}

.vg-share__btn.is-copied {
	color: var(--vg-accent);
	border-color: var(--vg-accent);
	background: var(--vg-accent-soft);
}

.vg-share--rail {
	flex-direction: column;
	gap: 9px;
}

.vg-share--rail .vg-share__label {
	writing-mode: vertical-rl;
	margin-bottom: 6px;
}

.vg-share--foot {
	margin-top: 34px;
	padding-top: 24px;
	border-top: 1px solid var(--vg-line);
}

/* --- prose --- */

.vg-prose {
	font-size: 17.5px;
	line-height: 1.72;
	color: var(--vg-text);
}

/*
 * Block rhythm is owned by the owl rule below, so the browser defaults get
 * zeroed first and margins never double up. Keep this reset at one class plus
 * one universal: the `.vg-prose p { margin: 0 }` it replaces was one point more
 * specific than the owl, so it won, and every paragraph gap collapsed.
 */
.vg-prose > * {
	margin-top: 0;
	margin-bottom: 0;
}

.vg-prose > * + * {
	margin-top: 1.3em;
}

.vg-prose a {
	color: var(--vg-accent);
	box-shadow: inset 0 -1px 0 var(--vg-accent-line);
	transition: box-shadow 0.15s var(--vg-ease);
}

.vg-prose a:hover {
	box-shadow: inset 0 -2px 0 var(--vg-accent);
}

.vg-prose h2,
.vg-prose h3,
.vg-prose h4 {
	margin-top: 1.9em;
	margin-bottom: 0.55em;
	scroll-margin-top: 100px;
}

.vg-prose h2 {
	font-size: clamp(22px, 2.3vw, 29px);
	padding-top: 0.5em;
	border-top: 1px solid var(--vg-line);
}

.vg-prose h3 {
	font-size: clamp(19px, 1.9vw, 23px);
}

.vg-prose img,
.vg-prose figure img {
	border-radius: var(--vg-radius-sm);
}

.vg-prose figcaption {
	margin-top: 9px;
	font-family: var(--vg-mono);
	font-size: 11.5px;
	color: var(--vg-mute);
}

.vg-prose ul,
.vg-prose ol {
	padding-left: 1.3em;
}

.vg-prose li + li {
	margin-top: 0.5em;
}

.vg-prose li::marker {
	color: var(--vg-accent);
}

.vg-prose blockquote {
	margin: 1.8em 0;
	padding: 4px 0 4px 24px;
	border-left: 2px solid var(--vg-accent);
	font-family: var(--vg-display);
	font-size: 1.16em;
	line-height: 1.44;
	color: var(--vg-text);
}

.vg-prose blockquote p {
	margin: 0;
}

.vg-prose code {
	font-family: var(--vg-mono);
	font-size: 0.87em;
	padding: 2px 6px;
	border: 1px solid var(--vg-line);
	border-radius: 4px;
	background: var(--vg-panel-2);
	color: var(--vg-accent);
}

.vg-prose pre {
	padding: 20px;
	border: 1px solid var(--vg-line);
	border-radius: var(--vg-radius-sm);
	background: var(--vg-panel);
	overflow-x: auto;
	font-size: 14px;
	line-height: 1.6;
}

.vg-prose pre code {
	padding: 0;
	border: 0;
	background: none;
	color: inherit;
}

.vg-prose table {
	width: 100%;
	border-collapse: collapse;
	font-size: 15px;
	display: block;
	overflow-x: auto;
}

.vg-prose th,
.vg-prose td {
	padding: 11px 14px;
	border: 1px solid var(--vg-line);
	text-align: left;
}

.vg-prose th {
	background: var(--vg-panel-2);
	font-family: var(--vg-mono);
	font-size: 11.5px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--vg-dim);
}

.vg-prose hr {
	border: 0;
	border-top: 1px solid var(--vg-line);
	margin: 2.4em 0;
}

/* --- post nav --- */

.vg-postnav {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: 16px;
	margin-top: 48px;
}

.vg-postnav__link {
	display: grid;
	gap: 8px;
	padding: 20px;
	border: 1px solid var(--vg-line);
	border-radius: var(--vg-radius);
	background: var(--vg-panel);
	transition: border-color 0.15s var(--vg-ease), transform 0.15s var(--vg-ease);
}

.vg-postnav__link:hover {
	border-color: var(--vg-accent-line);
	transform: translateY(-2px);
}

.vg-postnav__link--next {
	text-align: right;
}

.vg-postnav__title {
	font-family: var(--vg-display);
	font-size: 16px;
	font-weight: 700;
	line-height: 1.3;
}

.vg-related {
	padding-bottom: 72px;
}

.vg-pagelinks {
	margin-top: 28px;
	font-family: var(--vg-mono);
	font-size: 12px;
}

/* ========================================================== 11. Comments == */

body.vghq .comments-area {
	margin-top: 56px;
	padding-top: 32px;
	border-top: 1px solid var(--vg-line);
}

body.vghq .comments-title,
body.vghq .comment-reply-title {
	font-family: var(--vg-display);
	font-size: 20px;
	text-transform: uppercase;
}

body.vghq .comment-body {
	padding: 18px 0;
	border-bottom: 1px solid var(--vg-line);
}

body.vghq .comment-list {
	list-style: none;
	padding: 0;
}

body.vghq input[type="text"],
body.vghq input[type="email"],
body.vghq input[type="url"],
body.vghq input[type="search"],
body.vghq textarea {
	width: 100%;
	padding: 12px 14px;
	border: 1px solid var(--vg-line);
	border-radius: var(--vg-radius-sm);
	background: var(--vg-panel);
	color: var(--vg-text);
	font-family: var(--vg-body);
	font-size: 15px;
}

body.vghq input:focus,
body.vghq textarea:focus {
	border-color: var(--vg-accent);
	outline: none;
	box-shadow: 0 0 0 3px var(--vg-accent-glow);
}

body.vghq input[type="submit"],
body.vghq .button {
	padding: 12px 22px;
	border: 1px solid var(--vg-accent);
	border-radius: var(--vg-radius-sm);
	background: var(--vg-accent);
	color: #05070b;
	font-family: var(--vg-mono);
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	cursor: pointer;
}

/* =================================================== 12. Search overlay == */

.vg-overlay {
	position: fixed;
	inset: 0;
	z-index: 300;
	display: grid;
	place-items: start center;
	padding: 12vh 24px 24px;
	background: rgba(5, 7, 11, 0.86);
	backdrop-filter: blur(10px);
	opacity: 0;
	transition: opacity 0.18s var(--vg-ease);
}

.vg-scheme-light .vg-overlay {
	background: rgba(247, 248, 250, 0.92);
}

.vg-overlay.is-open {
	opacity: 1;
}

.vg-overlay__inner {
	position: relative;
	width: 100%;
	max-width: 680px;
	display: grid;
	gap: 18px;
	padding: 32px;
	border: 1px solid var(--vg-line-2);
	border-radius: var(--vg-radius);
	background: var(--vg-panel);
	box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5);
	transform: translateY(-10px);
	transition: transform 0.2s var(--vg-ease);
}

.vg-overlay.is-open .vg-overlay__inner {
	transform: none;
}

.vg-overlay .search-form,
.vg-overlay form {
	display: flex;
	gap: 10px;
}

.vg-overlay input[type="search"] {
	font-size: 18px;
	padding: 15px 16px;
}

.vg-overlay__terms {
	display: grid;
	gap: 10px;
	padding-top: 6px;
	border-top: 1px solid var(--vg-line);
}

.vg-overlay__close {
	position: absolute;
	top: 14px;
	right: 14px;
	width: 36px;
	height: 36px;
	display: grid;
	place-items: center;
	border: 1px solid var(--vg-line);
	border-radius: var(--vg-radius-sm);
	background: none;
	color: var(--vg-dim);
	cursor: pointer;
	transition: color 0.15s var(--vg-ease), border-color 0.15s var(--vg-ease);
}

.vg-overlay__close:hover {
	color: var(--vg-accent);
	border-color: var(--vg-accent);
}

/* ============================================================ 13. Footer == */

.vg-footer {
	border-top: 1px solid var(--vg-line);
	background: var(--vg-panel);
	padding-block: 56px;
}

.vg-footer__inner {
	display: grid;
	grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
	gap: 48px;
	align-items: start;
}

.vg-footer__logo {
	font-family: var(--vg-display);
	font-size: 26px;
	font-weight: 700;
	letter-spacing: -0.03em;
	text-transform: uppercase;
}

.vg-footer__blurb {
	margin: 12px 0 20px;
	max-width: 52ch;
	color: var(--vg-dim);
	font-size: 15px;
}

.vg-footer__cols {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
	gap: 32px;
}

.vg-footer__col ul {
	margin: 12px 0 0;
	padding: 0;
	list-style: none;
	display: grid;
	gap: 9px;
}

.vg-footer__col a {
	color: var(--vg-dim);
	font-size: 14.5px;
	transition: color 0.15s var(--vg-ease);
}

.vg-footer__col a:hover {
	color: var(--vg-accent);
}

.vg-social {
	display: flex;
	flex-wrap: wrap;
	gap: 9px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.vg-social a {
	display: grid;
	place-items: center;
	width: 38px;
	height: 38px;
	border: 1px solid var(--vg-line);
	border-radius: var(--vg-radius-sm);
	color: var(--vg-dim);
	transition: color 0.15s var(--vg-ease), border-color 0.15s var(--vg-ease), transform 0.15s var(--vg-ease);
}

.vg-social a:hover {
	color: var(--vg-accent);
	border-color: var(--vg-accent);
	transform: translateY(-2px);
}

/*
 * GeneratePress paints its own footer regions from its Customizer colours, so
 * out of the box the widget area is a white sheet with pale grey links sitting
 * under our dark brand block. Same story as the nav: it has to be overridden
 * here, because generate_option_defaults only reaches sites with no saved GP
 * settings.
 */
body.vghq .site-footer,
body.vghq .footer-widgets,
body.vghq .footer-widgets-container,
body.vghq .footer-bar {
	background: var(--vg-bg);
	color: var(--vg-dim);
}

body.vghq .footer-widgets {
	border-top: 1px solid var(--vg-line);
}

body.vghq .footer-widgets .widget-title,
body.vghq .footer-widgets .widget h2 {
	font-family: var(--vg-mono);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--vg-mute);
}

body.vghq .footer-widgets a,
body.vghq .footer-bar a,
body.vghq .site-info a {
	color: var(--vg-dim);
	transition: color 0.15s var(--vg-ease);
}

body.vghq .footer-widgets a:hover,
body.vghq .footer-bar a:hover,
body.vghq .site-info a:hover {
	color: var(--vg-accent);
}

body.vghq .site-info {
	background: var(--vg-bg);
	border-top: 1px solid var(--vg-line);
	font-family: var(--vg-mono);
	font-size: 11.5px;
	letter-spacing: 0.06em;
	color: var(--vg-mute);
}

/* ======================================================== 14. Responsive == */

@media (max-width: 1200px) {
	.vg-single__body {
		grid-template-columns: 56px minmax(0, 1fr);
		gap: 32px;
	}

	.vg-single__body .vg-rail {
		grid-column: 1 / -1;
		position: static;
	}
}

@media (max-width: 1024px) {
	.vg-layout {
		grid-template-columns: minmax(0, 1fr);
		gap: 48px;
	}

	.vg-rail {
		position: static;
	}

	.vg-hero {
		grid-template-columns: minmax(0, 1fr);
	}

	.vg-card--lead {
		min-height: 380px;
	}

	.vg-hero__stack {
		grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
		display: grid;
	}
}

@media (max-width: 782px) {
	.vg-shell {
		padding-inline: 18px;
	}

	.vg-single__body {
		grid-template-columns: minmax(0, 1fr);
	}

	/* The vertical rail becomes a normal row on small screens. */
	.vg-single__sharerail {
		position: static;
	}

	.vg-share--rail {
		flex-direction: row;
	}

	.vg-share--rail .vg-share__label {
		writing-mode: horizontal-tb;
		margin-bottom: 0;
	}

	.vg-card--feature {
		grid-template-columns: minmax(0, 1fr);
		gap: 18px;
	}

	.vg-authorcard {
		grid-template-columns: minmax(0, 1fr);
		gap: 16px;
	}

	.vg-footer__inner {
		grid-template-columns: minmax(0, 1fr);
		gap: 34px;
	}
}

@media (max-width: 560px) {
	.vg-grid {
		grid-template-columns: minmax(0, 1fr);
	}

	.vg-card--compact {
		grid-template-columns: 96px minmax(0, 1fr);
	}

	.vg-card--lead .vg-card__body {
		padding: 20px;
	}

	.vg-homewrap,
	.vg-archivewrap {
		padding-block: 22px 52px;
	}
}

/* ==================================================== 15. Motion & print == */

@media (prefers-reduced-motion: reduce) {
	.vg-loader.is-busy .vg-loader__msg::after {
		animation: none;
	}

	body.vghq *,
	body.vghq *::before,
	body.vghq *::after {
		transition-duration: 0.01ms !important;
	}

	.vg-card:hover .vg-card__media img,
	.vg-card--standard:hover {
		transform: none;
	}
}

@media print {
	.vg-rail,
	.vg-share,
	.vg-loader,
	.vg-progress,
	.vg-postnav,
	.vg-related,
	.vg-footer {
		display: none !important;
	}

	.vg-single__body {
		grid-template-columns: 1fr;
	}
}
