/* ── Article layout ──────────────────────────────────────────────────────────
   Long-form reading pages. Loaded after pico.min.css and site.css.
   Keeps the product chrome; replaces the landing-page rhythm with an
   editorial column that happens to sit on containd.app.
   ────────────────────────────────────────────────────────────────────────── */

:root {
	/* Dark entry theme. Every value here is measured: see
	   references/dark-theme.md for the contrast ratio each one carries and the
	   script that produced it. The corporate palette stays the source; these
	   are the roles it takes on a dark page.

	   #2a5b84 is NOT usable as text here (2.55:1 on #0e1428); the metallic
	   blue role goes to #7fb0d6, and links go to the orange. */
	--article-measure: 33rem;
	--article-wide: 40rem;
	--article-ink: #e6e7e3;
	--article-ink-soft: #9aa3b8;
	--article-rule: rgba(230, 231, 227, 0.14);
	--article-paper: #0e1428;
	--article-surface: #161f38;
	--article-accent: #ff832e;
	--article-accent-hi: #ffa74f;
	--article-link: #ffa74f;
	--article-metal: #7fb0d6;
	--article-ink-strong: #f2f3ef;
	--article-btn-ink: #14203a;
	--article-rail-width: 13.5rem;
}

body.article-page {
	background: var(--article-paper);
	color: var(--article-ink);
	font-family: "Source Sans 3", system-ui, sans-serif;
	/* pico's root scales 16px → 21px with viewport, so pin reading text in px */
	font-size: clamp(16.5px, 0.55vw + 13.6px, 18.5px);
	line-height: 1.72;
	-webkit-font-smoothing: antialiased;
}

body.article-page h1,
body.article-page h2,
body.article-page h3 {
	font-family: Quicksand, system-ui, sans-serif;
	letter-spacing: -0.021em;
	color: var(--article-ink);
	font-weight: 700;
}

/* pico renders every <article> as a grey card: background, 20px padding, radius
   and shadow. On a reading page that paints a slab behind the text and, inside
   the grid, quietly narrows the column by 40px. Reset it before anything else.
   This was present in the deployed article.css but missing from the template
   this stylesheet was derived from. */

body.article-page article {
	background: transparent;
	padding: 0;
	margin: 0;
	border-radius: 0;
	box-shadow: none;
}

/* Progress rail ------------------------------------------------------------ */

.article-progress {
	position: fixed;
	inset: 0 auto auto 0;
	height: 3px;
	width: 0;
	background: var(--article-accent);
	z-index: 60;
	transition: width 90ms linear;
}

/* Masthead ---------------------------------------------------------------- */

.article-head {
	max-width: var(--article-measure);
	margin: 0 auto;
	padding: 3.4rem 1.25rem 0;
}

.article-kicker {
	display: flex;
	align-items: center;
	gap: 0.6rem;
	margin: 0 0 1.05rem;
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.11em;
	text-transform: uppercase;
	color: var(--article-metal);
}

.article-kicker::before {
	content: "";
	width: 1.6rem;
	height: 2px;
	background: var(--article-accent);
	flex: none;
}

.article-head h1 {
	margin: 0 0 1rem;
	font-size: clamp(31px, 2.6vw + 20px, 53px);
	line-height: 1.1;
}

.article-deck {
	margin: 0 0 1.6rem;
	font-size: clamp(17.5px, 0.75vw + 14px, 21px);
	line-height: 1.55;
	color: var(--article-ink-soft);
	max-width: 34rem;
}

.article-byline {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.5rem 0.85rem;
	margin: 0;
	padding: 0.9rem 0 1.5rem;
	border-bottom: 1px solid var(--article-rule);
	font-size: 0.86rem;
	color: var(--article-ink-soft);
}

.article-byline .dot {
	width: 3px;
	height: 3px;
	border-radius: 50%;
	background: currentColor;
	opacity: 0.55;
}

/* Body -------------------------------------------------------------------- */

.article-body {
	max-width: var(--article-measure);
	margin: 0 auto;
	padding: 0 1.25rem 3rem;
}

.article-body > * {
	margin-block: 0;
}

.article-body > * + * {
	margin-top: 1.15rem;
}

.article-body > p:first-of-type {
	margin-top: 2rem;
	font-size: 1.055em;
	line-height: 1.66;
	color: var(--article-ink);
}

.article-body h2 {
	margin-top: 2.6rem;
	margin-bottom: 0.25rem;
	font-size: clamp(22px, 0.9vw + 15px, 27px);
	line-height: 1.24;
}

.article-body h2 + p {
	margin-top: 0.55rem;
}

.article-body h3 {
	margin-top: 1.9rem;
	font-size: 1.12rem;
	letter-spacing: -0.01em;
}

.article-body a {
	color: var(--article-metal);
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 0.18em;
	text-decoration-color: rgba(255, 167, 79, 0.4);
}

.article-body a:hover,
.article-body a:focus-visible {
	color: var(--article-accent-hi);
	text-decoration-color: currentColor;
}

.article-body strong {
	font-weight: 700;
	color: var(--article-ink-strong);
}

.article-body ul,
.article-body ol {
	padding-left: 1.15rem;
}

.article-body li + li {
	margin-top: 0.45rem;
}

.article-body li::marker {
	color: var(--article-accent);
}

.article-body code {
	font-size: 0.9em;
	background: rgba(230, 231, 227, 0.08);
	border-radius: 4px;
	padding: 0.1em 0.34em;
}

/* Pull quote -------------------------------------------------------------- */

.article-body blockquote {
	margin: 2.1rem 0;
	padding: 0 0 0 1.15rem;
	border-left: 3px solid var(--article-accent);
	font-family: Quicksand, system-ui, sans-serif;
	font-size: 1.22rem;
	line-height: 1.45;
	font-weight: 600;
	color: var(--article-ink-strong);
}

.article-body blockquote p {
	margin: 0;
	font-size: inherit;
	line-height: inherit;
}

.article-body blockquote footer {
	margin-top: 0.6rem;
	font-family: "Source Sans 3", system-ui, sans-serif;
	font-size: 0.85rem;
	font-weight: 400;
	color: var(--article-ink-soft);
}

/* Figures ------------------------------------------------------------------
   Pick the tier from the asset's aspect ratio, not by taste:

     ratio >= 1.4   landscape   -> .article-figure--wide    ~1.3x the text column
     ratio 1.0-1.4  landscape   -> .article-figure          the text column
     ratio < 1.0    tall        -> .article-figure--portrait  capped by HEIGHT

   Vertical assets are sized by height, with width left auto. Constraining a
   9:16 screenshot to a pixel width is what turns a phone screen into a
   1000px tower in the middle of a paragraph. `tools/check_figures.py` verifies
   the tier matches the file's real dimensions.
   ------------------------------------------------------------------------- */

.article-figure {
	margin: 2.1rem 0;
}

.article-figure img,
.article-figure .article-video {
	display: block;
	width: 100%;
	height: auto;
	border-radius: 10px;
	border: 1px solid var(--article-rule);
	background: var(--article-surface);
}

.article-figure--wide {
	width: var(--article-wide);
	max-width: calc(100vw - 2.5rem);
	margin-left: 50%;
	transform: translateX(-50%);
}

/* Inside the two-column layout the breakout has a hard boundary: the gutter.
   Centered on a 660px column, an 800px figure extends 70px each side while the
   gutter is only 48px, so it ran 22-32px under the rail and the rail's links
   were unclickable where a figure crossed them. Constraining the width to the
   column plus both gutters keeps the breakout look and stops it at the rail. */
.entry-layout .article-figure--wide {
	width: min(var(--article-wide), calc(100% + 2 * clamp(1.5rem, 3vw, 3rem)));
}

/* Tall screenshots: the height decides, the width follows. */
.article-figure--portrait {
	text-align: center;
}

.article-figure--portrait img {
	width: auto;
	max-width: min(100%, 20rem);
	max-height: clamp(320px, 50vh, 600px);
	margin-inline: auto;
}

/* A tall figure that the reviewer framed on purpose. A wide-tier crop whose
   ratio lands just above 1.40 renders around 570px tall, which is 63% of a
   900px viewport and past the 55% budget. Re-cropping it throws away framing
   that was a deliberate choice, so this variant keeps the width and caps the
   height, centering what fits.

   Opt in per figure with `article-figure--capped`. Do not apply it in place of
   choosing a better crop: it trades a little edge for the reader's viewport, so
   it belongs on the rare figure where the framing is the point. */
.article-figure--capped img {
	/* The base rule is width:100%; height:auto. With only a max-height on top,
	   the browser keeps the full 800px width and lets the height overflow the
	   cap, so the cap never applies. Width has to become auto for the height
	   limit to actually scale the image down, and the result is centered in the
	   column instead of filling it. */
	width: auto;
	height: auto;
	max-width: 100%;
	max-height: min(52vh, 470px);
	margin-inline: auto;
	border-radius: 10px;
}
.article-figure--capped { text-align: center; }

/* Small inline graphics (icons, thumbnails, single UI crops). */
.article-figure--narrow {
	max-width: 18rem;
	margin-inline: auto;
}

.article-figure--narrow img {
	width: 100%;
	margin-inline: auto;
}

.article-figure figcaption {
	margin-top: 0.65rem;
	font-size: 0.83rem;
	line-height: 1.5;
	color: var(--article-ink-soft);
}

.article-figure--narrow figcaption,
.article-figure--portrait figcaption {
	max-width: 27rem;
	margin-inline: auto;
	text-align: left;
}

@media (max-width: 720px) {
	.article-figure--portrait img {
		max-width: min(100%, 82vw);
		max-height: 62vh;
	}
}

/* Video embed ------------------------------------------------------------- */

.article-video {
	position: relative;
	max-width: 100%;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	background: var(--article-surface);
	padding: 0;
}

.article-video .home-hero-video-facade {
	display: block;
	width: 100%;
	height: 100%;
}

.article-video .home-hero-video-facade img,
.article-video iframe {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	border: 0;
}

.article-video .home-hero-video-label {
	position: absolute;
	inset: auto 0 0;
	padding: 2rem 0.9rem 0.75rem;
	background: linear-gradient(transparent, rgba(10, 14, 30, 0.8));
	color: #f2f3ef;
	font-size: 0.85rem;
	font-weight: 600;
}

/* CTA block --------------------------------------------------------------- */

.article-cta {
	margin: 2.8rem 0;
	padding: 1.4rem 1.5rem;
	border: 1px solid var(--article-rule);
	border-radius: 12px;
	background: var(--article-surface);
	box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25);
}

.article-cta h3 {
	margin: 0 0 0.4rem;
	font-size: 1.15rem;
}

.article-cta p {
	margin: 0;
	font-size: 0.95rem;
	color: var(--article-ink-soft);
}

.article-cta .store-download-badges {
	margin-top: 1rem;
	gap: 0.75rem;
}

.article-cta .store-download-badges img {
	height: 42px;
	width: auto;
}

/* Author note ------------------------------------------------------------- */

.article-author {
	display: flex;
	gap: 0.95rem;
	align-items: flex-start;
	max-width: var(--article-measure);
	margin: 3rem auto 0;
	padding: 1.4rem 1.25rem;
	border-top: 1px solid var(--article-rule);
	font-size: 0.92rem;
	color: var(--article-ink-soft);
}

.article-author img {
	width: 44px;
	height: 44px;
	border-radius: 50%;
	flex: none;
	object-fit: contain;
	background: var(--article-surface);
	padding: 6px;
}

.article-author p {
	margin: 0;
}

.article-author strong {
	color: var(--article-ink);
}

/* Tail sections reuse the site's article conventions ---------------------- */

.article-tail {
	max-width: var(--article-wide);
	margin: 3rem auto 0;
	padding: 0 1.25rem 3rem;
}

@media (max-width: 720px) {
	.article-head {
		padding-top: 2.4rem;
	}

	.article-body > p:first-of-type {
		font-size: 1.03em;
	}

	.article-figure--wide {
		width: 100%;
		margin-left: 0;
		transform: none;
	}
}


/* ══════════════════════════════════════════════════════════════════════════
   Build-in-public entry surface
   Everything below is specific to dated entries: the dark chrome re-skin, the
   date rail, the archive hub, and the containd.app CTA. Nothing above this
   line is a fork of article.css; it is the same layout with the dark role
   tokens substituted at the top of the file.
   ══════════════════════════════════════════════════════════════════════════ */

body.article-page.entry-page {
	background: var(--article-paper);
	/* A one-pixel warm bloom at the top stops the dark field reading as a hole.
	   It is decoration on a color already at 14.7:1, not a texture behind text. */
	background-image: radial-gradient(72rem 28rem at 50% -12rem,
		rgba(255, 131, 46, 0.09), transparent 70%);
	background-repeat: no-repeat;
}

/* Headline type on dark needs slightly more weight to hold at the same size:
   light ink on a dark field optically thins. 700 -> 700, but the tracking
   opens a hair because Quicksand at 700 on #0e1428 closes up. */
body.article-page.entry-page h1,
body.article-page.entry-page h2,
body.article-page.entry-page h3 {
	color: var(--article-ink-strong);
	letter-spacing: -0.014em;
}

body.article-page.entry-page .article-kicker { color: var(--article-metal); }

body.article-page.entry-page .article-deck { color: var(--article-ink-soft); }

body.article-page.entry-page .article-byline {
	color: var(--article-ink-soft);
	border-bottom-color: var(--article-rule);
}

body.article-page.entry-page .article-body > p:first-of-type { color: var(--article-ink); }

body.article-page.entry-page .article-author {
	border-top-color: var(--article-rule);
	color: var(--article-ink-soft);
}
body.article-page.entry-page .article-author strong { color: var(--article-ink); }
body.article-page.entry-page .article-author img {
	background: #e6e7e3;
	padding: 4px;
}

body.article-page.entry-page .article-cta {
	background: var(--article-surface);
	border-color: var(--article-rule);
	box-shadow: none;
}
body.article-page.entry-page .article-cta p { color: var(--article-ink-soft); }

/* The CTA button. White on #ff832e is 2.46:1 and fails; the ink is #14203a
   (6.58:1 on the orange). */
.entry-cta-button {
	display: inline-block;
	margin-top: 0.35rem;
	padding: 0.62rem 1.15rem;
	border-radius: 999px;
	background: var(--article-accent);
	color: var(--article-btn-ink) !important;
	font-weight: 700;
	font-size: 0.98rem;
	text-decoration: none !important;
	transition: background-color 140ms ease-out, transform 140ms ease-out;
}
.entry-cta-button:hover,
.entry-cta-button:focus-visible {
	background: var(--article-accent-hi);
	color: var(--article-btn-ink) !important;
	transform: translateY(-1px);
}
@media (prefers-reduced-motion: reduce) {
	.entry-cta-button { transition: none; }
	.entry-cta-button:hover { transform: none; }
}

/* Video facade ------------------------------------------------------------
   A local poster with a play button. The YouTube iframe is only created on
   click, so the page loads no third-party player or cookie up front. */
.video-facade {
	position: relative;
	display: block;
	width: 100%;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	border-radius: 10px;
	border: 1px solid var(--article-rule);
	background: var(--article-surface);
	cursor: pointer;
}
.video-facade img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}
.video-facade .video-play {
	position: absolute;
	inset: 50% auto auto 50%;
	transform: translate(-50%, -50%);
	width: 4.4rem;
	height: 4.4rem;
	padding: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	border: 0;
	border-radius: 50%;
	background: var(--article-accent);
	color: var(--article-btn-ink);
	cursor: pointer;
	box-shadow: 0 6px 24px rgba(0, 0, 0, 0.35);
	transition: transform 120ms ease-out, background-color 120ms ease-out;
}
.video-facade .video-play svg {
	width: 1.9rem;
	height: 1.9rem;
	fill: currentColor;
	margin-left: 0.18rem; /* optically centre the triangle */
}
.video-facade:hover .video-play,
.video-facade .video-play:focus-visible {
	background: var(--article-accent-hi);
	transform: translate(-50%, -50%) scale(1.06);
}
/* Top-right: the site cookie notice is fixed to the bottom of the viewport at
   z-index 80 and covers a bottom-anchored badge on first load. */
.video-facade .video-meta {
	position: absolute;
	right: 0.75rem;
	top: 0.75rem;
	padding: 0.25rem 0.6rem;
	border-radius: 999px;
	background: rgba(14, 20, 40, 0.85);
	color: var(--article-ink);
	font-size: 0.78rem;
	letter-spacing: 0.01em;
}
.video-facade .video-embed,
.video-facade iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
}

/* ── The layout with a rail ────────────────────────────────────────────────
   The rail is a sibling of <article>, not a child, and the grid lives on the
   page wrapper. A fixed rail positioned by viewport math is what produced a
   small box floating over the top-left corner: it was placed relative to the
   window rather than to the article it belongs to.

   Layout intent:
     >= 1200px  sidebar, sticky, in its own grid column
     980-1200   sidebar in flow above the article (still a list, no overlap)
     < 980px    a menu: collapsed <details>, one column, no scrollbars
   ------------------------------------------------------------------------ */

.entry-layout {
	display: grid;
	/* Rail column + gutter + the article's own 660px box. The article box is
	   --article-measure (33rem = 660px at the 20px root), so the grid max is
	   computed rather than guessed: a fixed 1024px silently squeezed the text
	   column to 563px and every line got shorter than the light pages. */
	grid-template-columns: var(--article-rail-width) minmax(0, var(--article-measure));
	gap: clamp(1.5rem, 3vw, 3rem);
	/* rail + gutter (3rem at the cap) + article box + the grid's own inline
	   padding (2 * clamp max 2rem). One rem short here is 20px of text column. */
	max-width: calc(var(--article-rail-width) + var(--article-measure) + 3rem + 4rem);
	box-sizing: content-box;
	margin-inline: auto;
	padding-inline: clamp(0.9rem, 2vw, 2rem);
	align-items: start;
}

.entry-rail {
	position: sticky;
	top: 5.5rem;
	align-self: start;
	grid-column: 1;
	/* No height cap and no overflow: the whole list is short, and a scrollbar
	   inside a 13rem column is noise. If the archive ever outgrows a viewport,
	   that is the signal to move to the hub page, not to scroll a rail. */
	max-height: none;
	overflow: visible;
	font-size: 0.84rem;
	/* Above the article's figures. The width rule above should mean nothing ever
	   reaches this column, but a future wide element (an embed, a pasted
	   screenshot) must not be able to cover the archive and take its links with
	   it. Sticky already creates a stacking context; this makes the order
	   explicit rather than accidental. */
	z-index: 20;
	/* The rail must not be a "square window": a border and a background make
	   it read as a panel. It is a list in the margin, so it has neither. */
	background: none;
	border: 0;
	padding: 0;
}

.entry-rail-details > summary {
	list-style: none;
	cursor: default;
	margin-bottom: 0.7rem;
	font-size: 0.7rem;
	font-weight: 700;
	letter-spacing: 0.11em;
	text-transform: uppercase;
	color: var(--article-ink-soft);
}
.entry-rail-details > summary::-webkit-details-marker { display: none; }

.entry-rail nav { margin-bottom: 0.9rem; }

/* Year over month, as two lines. The year is the group, the month is the step
   inside it, so they are not the same weight or size. Without the block display
   on the year they collide into "2026October". */
.entry-rail h3 {
	margin: 1rem 0 0.4rem;
	font-size: 0.7rem;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--article-metal);
	line-height: 1.25;
}
.entry-rail h3 span {
	display: block;
	margin-bottom: 0.1rem;
	font-size: 0.62rem;
	font-weight: 600;
	color: var(--article-ink-soft);
	letter-spacing: 0.14em;
}

/* pico pulls a nav's first and last list out into the gutter:
     nav ul:first-of-type { margin-left: calc(var(--pico-nav-element-spacing-horizontal) * -1) }
     nav ul:last-of-type  { margin-right: ... }
   That is -10px on each side. On a 270px rail it is a 20px overflow, which is
   why the panel grew a scrollbar and read as a "square window".

   The fix needs pico's own pseudo-class specificity, which is why a plain
   `.entry-rail ul { margin: 0 }` lost: :first-of-type outranks it. These two
   selectors match the rule that actually applies. */
.entry-rail nav ul:first-of-type,
.entry-rail nav ul:last-of-type {
	margin-inline: 0;
	padding: 0;
}
.entry-rail ul,
.entry-rail ol,
.entry-rail li {
	margin: 0;
	padding: 0;
	list-style: none;
}

/* And `nav li :where(a,[role=link])` hangs the anchor itself by
   --pico-nav-link-spacing: another 10px each side. Matching that shape
   (`... li :where(a)`) is what beats it; a plain `.entry-rail a` loses. */
/* The pico reset above sets margins to zero, and an earlier draft of it dropped
   `display: grid` on the anchor as collateral. Without the grid the date and the
   title stack on top of each other, and because both inherit the same 16.8px
   Source Sans they read as one run-on string: "29 OctI built...". The layout is
   two columns, so the display has to be stated here, next to the margins that
   keep pico from pulling the row into the gutter. */
.entry-rail nav li :where(a, [role="link"]),
.entry-rail nav a,
.entry-rail a {
	display: grid;
	grid-template-columns: 2.9rem minmax(0, 1fr);
	gap: 0.45rem;
	align-items: baseline;
	margin: 0;
	padding: 0.3rem 0.4rem 0.3rem 0.45rem;
}
.entry-rail a[aria-current="page"] {
	padding-inline: 0.45rem 0.4rem;
}

/* "All entries" is a sentence in a footer note under the list, not a dated row.
   It has to come after `.entry-rail a`, which sets the two-column grid: the
   markup shipped without any rule of its own, so the link inherited the grid
   and rendered 270px wide with "All" and "entries" on separate lines. Every
   element added to the rail inherits that grid unless it resets the display. */
.entry-rail .entry-rail-more {
	margin: 1rem 0 0;
	padding: 0.8rem 0 0;
	border-top: 1px solid var(--article-rule);
}
.entry-rail .entry-rail-more a {
	display: inline;
	margin: 0;
	padding: 0;
	grid-template-columns: none;
	color: var(--article-metal);
	font-size: 0.8rem;
	line-height: 1.5;
	text-decoration: underline;
	text-underline-offset: 0.18em;
}
.entry-rail .entry-rail-more a:hover,
.entry-rail .entry-rail-more a:focus-visible { color: var(--article-accent-hi); }

/* Date and title are different things, so they do not share a type style. The
   date is a small tabular kicker; the title is the reading text. Before this,
   both were inherited at the same size and family and the row looked like one
   broken sentence. */
.entry-rail a time {
	font-size: 0.68rem;
	font-weight: 600;
	font-variant-numeric: tabular-nums;
	letter-spacing: 0.02em;
	text-transform: uppercase;
	color: var(--article-ink-soft);
	white-space: nowrap;
}
.entry-rail a span {
	font-size: 0.82rem;
	line-height: 1.35;
	color: var(--article-ink);
}

/* Below the sidebar breakpoint the rail stops being a column and becomes a
   disclosure above the article: still a list, no overlap, and the article takes
   the full width. This is the "phone mode means a menu, not a sidebar" rule.

   The breakpoint is 1200px because 270 (rail) + 48 (gutter) + 660 (article) +
   the page padding is about 1030px; below that the three cannot coexist and a
   sticky rail would start covering text. */
@media (max-width: 1199px) {
	.entry-layout {
		grid-template-columns: minmax(0, 1fr);
		max-width: calc(var(--article-measure) + 4rem);
		box-sizing: border-box;
	}
	.entry-layout > article,
	.entry-layout > main { grid-column: 1; }

	.entry-rail {
		position: static;
		grid-column: 1;
		margin-bottom: 0.75rem;
		padding-bottom: 0.75rem;
		border-bottom: 1px solid var(--article-rule);
	}
	.entry-rail-details > summary { cursor: pointer; }
}

/* Phone: a menu. The list is collapsed by default so the article starts at the
   top of the screen instead of after an archive. */
@media (max-width: 620px) {
	.entry-rail { font-size: 0.82rem; }
	.entry-rail a { grid-template-columns: 2.9rem minmax(0, 1fr); }
	.entry-rail nav { margin-bottom: 0.5rem; }
}

/* ── Dark chrome ──────────────────────────────────────────────────────────
   #site-header and .site-footer come from site.css with the light palette and
   are injected at runtime. Forking site.css or editing the shared partials
   would repaint every light page on the site, so the re-skin is scoped to
   .entry-page. If the header renders white, the body is missing the class.
   ------------------------------------------------------------------------ */

.entry-page #site-header {
	background: rgba(14, 20, 40, 0.86);
	backdrop-filter: saturate(1.05) blur(10px);
	border-bottom: 1px solid rgba(230, 231, 227, 0.1);
}
.entry-page #site-header .brand { color: var(--article-ink); }
/* The mark is mid-grey artwork (mean visible luminance 98.8) and turns to mud
   on a dark bar. A light chip, not filter: invert(), which would turn the
   orange inside blue. */
.entry-page #site-header .brand img {
	background: #e6e7e3;
	border-radius: 6px;
	padding: 3px;
	box-sizing: content-box;
}
.entry-page #site-header nav.site-nav > a,
.entry-page #site-header .nav-dd > summary,
.entry-page #site-header .site-header-language summary {
	color: var(--article-ink);
}
.entry-page #site-header nav.site-nav > a:hover,
.entry-page #site-header .nav-dd > summary:hover,
.entry-page #site-header .site-header-language summary:hover {
	background: rgba(230, 231, 227, 0.08);
}
.entry-page #site-header .nav-dd .nav-panel,
.entry-page #site-header .site-header-language ul,
.entry-page #site-header .site-mobile-menu[open] .site-mobile-panel {
	background: var(--article-surface);
	border-color: rgba(230, 231, 227, 0.16);
	color: var(--article-ink);
	box-shadow: 0 12px 28px rgba(0, 0, 0, 0.5);
}
.entry-page #site-header .nav-dd .nav-panel a,
.entry-page #site-header .site-header-language a,
.entry-page #site-header .site-mobile-links a {
	color: var(--article-ink);
}
.entry-page #site-header .nav-dd .nav-panel a:hover,
.entry-page #site-header .site-header-language a:hover,
.entry-page #site-header .site-header-language a[aria-current="page"],
.entry-page #site-header .site-mobile-links a:hover {
	background: rgba(255, 131, 46, 0.16);
}
.entry-page #site-header .site-mobile-menu summary {
	background: var(--article-surface);
	border-color: rgba(230, 231, 227, 0.2);
	color: var(--article-ink);
}

.entry-page footer.site-footer {
	background: #0a0f1d;
	color: #c9cee0;
}
.entry-page footer.site-footer h3 { color: var(--article-ink); }
.entry-page footer.site-footer a { color: #c9cee0; }
.entry-page footer.site-footer a:hover { color: var(--article-accent-hi); }
.entry-page footer.site-footer .site-footer-copy {
	color: var(--article-ink-soft);
	border-top-color: rgba(230, 231, 227, 0.14);
}
.entry-page footer.site-footer .site-footer-social img {
	/* Same problem as the brand mark: dark SVG glyphs on a near-black footer. */
	filter: invert(1) brightness(1.6);
	opacity: 0.85;
}

/* The cookie notice is a light panel injected at runtime, pinned bottom. */
.entry-page .site-cookie-notice {
	background: rgba(22, 31, 56, 0.98);
	border-color: rgba(230, 231, 227, 0.16);
	box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55);
}
.entry-page .site-cookie-notice p { color: var(--article-ink); }
.entry-page .site-cookie-notice a { color: var(--article-link); }

/* Related chips at the tail, which site.css paints white. */
.entry-page #related-pages { border-top-color: var(--article-rule); }
.entry-page #related-pages a {
	background: var(--article-surface);
	border-color: rgba(230, 231, 227, 0.18);
	color: var(--article-ink);
}
.entry-page #related-pages a:hover,
.entry-page #related-pages a:focus-visible {
	background: rgba(255, 131, 46, 0.14);
	border-color: rgba(255, 131, 46, 0.5);
	color: var(--article-accent-hi);
}

/* ── Archive hub ─────────────────────────────────────────────────────────── */

.entry-archive-head {
	max-width: var(--article-measure);
	margin: 0 auto;
	padding: 3.2rem 1.25rem 0.5rem;
}
.entry-archive-head h1 {
	font-size: clamp(30px, 2.4vw + 20px, 48px);
	line-height: 1.12;
	margin: 0 0 0.9rem;
}
.entry-archive-head .article-deck { margin-bottom: 0; }

.entry-archive {
	max-width: var(--article-measure);
	margin: 0 auto;
	padding: 1rem 1.25rem 3rem;
}

.entry-archive .archive-year { margin-top: 2.4rem; }
.entry-archive .archive-year h2 {
	margin: 0 0 0.5rem;
	font-size: 0.78rem;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--article-metal);
}
.entry-archive ul { list-style: none; margin: 0; padding: 0; }

.entry-archive .archive-month h3 {
	margin: 1.5rem 0 0.35rem;
	padding-bottom: 0.4rem;
	border-bottom: 1px solid var(--article-rule);
	font-size: 0.74rem;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--article-ink-soft);
}

.entry-archive .archive-entry {
	margin: 0;
	padding: 0.85rem 0;
	border-bottom: 1px solid rgba(230, 231, 227, 0.07);
}
.entry-archive .archive-entry time {
	display: block;
	font-size: 0.74rem;
	font-variant-numeric: tabular-nums;
	color: var(--article-ink-soft);
	margin-bottom: 0.15rem;
}
.entry-archive .archive-entry h4 {
	margin: 0 0 0.2rem;
	font-family: Quicksand, system-ui, sans-serif;
	font-size: 1.06rem;
	font-weight: 700;
	letter-spacing: -0.01em;
}
.entry-archive .archive-entry h4 a {
	color: var(--article-ink);
	text-decoration: none;
}
.entry-archive .archive-entry h4 a:hover { color: var(--article-accent-hi); }
.entry-archive .archive-entry p {
	margin: 0;
	font-size: 0.9rem;
	line-height: 1.5;
	color: var(--article-ink-soft);
}

/* ── Print ────────────────────────────────────────────────────────────────
   A dark page printed on paper is a black rectangle. */
@media print {
	body.article-page.entry-page,
	body.article-page.entry-page .article-body,
	body.article-page.entry-page .article-head {
		background: #fff !important;
		background-image: none !important;
		color: #111 !important;
	}
	body.article-page.entry-page h1,
	body.article-page.entry-page h2,
	body.article-page.entry-page h3,
	body.article-page.entry-page strong,
	body.article-page.entry-page .article-body a {
		color: #111 !important;
	}
	.entry-rail,
	.entry-page #site-header,
	.entry-page footer.site-footer,
	.entry-page .site-cookie-notice,
	.article-progress,
	.entry-cta-button {
		display: none !important;
	}
}

/* ── Video placeholder ────────────────────────────────────────────────────
   A page whose video is not on YouTube yet. This is the correct state, not a
   problem to engineer around: this agent never encodes, hosts or re-renders
   video. The poster says what the video is; the note says it is not up yet.

   The `video-placeholder` marker is what check_no_local_video.py looks for to
   tell "waiting on publication" apart from "shipping a self-hosted player".
   Keep the marker on the wrapper if you restyle this. */
/* Hero sits at the text column, exactly like the SEO pages. Without this the
   placeholder filled the grid cell on a wide viewport and read as a billboard
   rather than as the video anchor. */
.article-hero-video {
	max-width: var(--article-measure);
	margin: 1.9rem auto 0;
	padding: 0;
}
.article-hero-video figcaption {
	margin-top: 0.65rem;
	font-size: 0.83rem;
	line-height: 1.5;
	color: var(--article-ink-soft);
}

.video-placeholder {
	position: relative;
	display: block;
	width: 100%;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	border-radius: 10px;
	border: 1px solid var(--article-rule);
	background: var(--article-surface);
}
.video-placeholder img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	/* Held back so the overlay note reads, and so the still is not mistaken for
	   a playable poster. */
	opacity: 0.55;
	filter: saturate(0.85);
}
.video-placeholder-note {
	position: absolute;
	inset: auto 0 0;
	margin: 0;
	padding: 2.2rem 1rem 0.85rem;
	background: linear-gradient(transparent, rgba(10, 14, 30, 0.92));
	color: var(--article-ink);
	font-size: 0.86rem;
	font-weight: 600;
	letter-spacing: 0.01em;
}
