/*
Theme Name: Rekha
Theme URI: https://rekhasvg.com/
Author: Anil Mathew
Description: The site for the Rekha image tracer. Direction "Drafting": cool paper, ink, one instrument blue, drawings on sheets.
Version: 1.0.0
Requires at least: 6.4
Requires PHP: 8.0
License: GPL-2.0-or-later
Text Domain: rekha
*/

/* Type: one family. Instrument Sans carries a width axis, so headlines
   are set narrow and heavy and text at its normal width. */
@font-face {
	font-family: "Instrument Sans";
	src: url("assets/fonts/instrument-sans-latin-wdth-normal.woff2") format("woff2");
	font-weight: 400 700;
	font-stretch: 75% 100%;
	font-display: swap;
}
@font-face {
	font-family: "JetBrains Mono";
	src: url("assets/fonts/jetbrains-mono-latin-wght-normal.woff2") format("woff2");
	font-weight: 400 600;
	font-display: swap;
}

:root {
	--paper: #EEF1F6;
	--sheet: #FFFFFF;
	--ink: #0B1220;
	--graphite: #4B5563;
	--rule: #D5DAE3;
	--rule-strong: #B9C1D0;
	--blue: #014AED;
	--blue-deep: #0139B8;
	--blue-soft: #E3EBFF;
	--teal: #07D2C1;
	--grid: rgba(1, 74, 237, 0.07);
	--font: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
	--mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
	--radius: 6px;
	--wrap: 1180px;
	--gutter: clamp(20px, 4vw, 40px);
	--band: clamp(64px, 9vw, 120px);
	--t: 160ms ease-out;
	--shadow: 0 1px 0 var(--rule), 0 30px 70px -40px rgba(1, 30, 100, 0.45);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 24px; }
body {
	margin: 0;
	background: var(--paper);
	color: var(--ink);
	font-family: var(--font);
	font-size: 17px;
	line-height: 1.6;
	font-stretch: 100%;
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; height: auto; display: block; }
h1, h2, h3, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 2px; }
::selection { background: var(--blue); color: #fff; }

h1, h2 { font-stretch: 80%; font-weight: 650; letter-spacing: -0.015em; text-wrap: balance; }
h1 { font-size: clamp(2.6rem, 6.4vw, 5.25rem); line-height: 0.98; }
h2 { font-size: clamp(1.75rem, 3.4vw, 2.75rem); line-height: 1.06; }
h3 { font-size: 1.18rem; line-height: 1.3; font-weight: 600; }
p { text-wrap: pretty; }
code { font-family: var(--mono); font-size: 0.86em; background: var(--blue-soft); padding: 0.12em 0.36em; border-radius: 3px; }

.wrap { width: 100%; max-width: calc(var(--wrap) + var(--gutter) * 2); margin-inline: auto; padding-inline: var(--gutter); }
.narrow { max-width: calc(760px + var(--gutter) * 2); }
.narrow-wide { max-width: calc(900px + var(--gutter) * 2); }
.screen-reader-text, .skip:not(:focus) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip:focus { position: fixed; top: 12px; left: 12px; z-index: 10; background: var(--ink); color: #fff; padding: 10px 14px; border-radius: var(--radius); }

.lede { font-size: clamp(1.1rem, 1.6vw, 1.32rem); line-height: 1.5; color: var(--graphite); max-width: 60ch; }
.aside { color: var(--graphite); font-size: 0.94rem; border-left: 2px solid var(--blue); padding-left: 14px; }
.link { color: var(--blue); font-weight: 600; text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 4px; text-decoration-color: rgba(1, 74, 237, 0.35); transition: text-decoration-color var(--t); }
.link:hover { text-decoration-color: var(--blue); }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: 0 18px; border-radius: var(--radius); border: 1px solid var(--rule-strong); background: var(--sheet); color: var(--ink); font-weight: 600; font-size: 0.97rem; text-decoration: none; white-space: nowrap; transition: border-color var(--t), background var(--t), color var(--t), transform var(--t); }
.btn:hover { border-color: var(--ink); }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-deep); border-color: var(--blue-deep); }
.btn-large { min-height: 52px; padding: 0 24px; font-size: 1.04rem; }
.btn-small { min-height: 34px; padding: 0 12px; font-size: 0.88rem; }
.btn-light { background: #fff; border-color: #fff; color: var(--ink); }
.btn-light:hover { background: var(--blue-soft); border-color: var(--blue-soft); }
.btn-ghost { background: transparent; border-color: rgba(255, 255, 255, 0.35); color: #fff; }
.btn-ghost:hover { border-color: #fff; }
.btn[aria-pressed="true"] { background: var(--blue-soft); border-color: var(--blue); color: var(--blue-deep); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* Header */
.top { border-bottom: 1px solid var(--rule); background: var(--paper); }
.top-row { display: flex; align-items: center; gap: 28px; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; font-size: 1.28rem; font-stretch: 85%; letter-spacing: -0.01em; }
.nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.nav a:not(.btn) { padding: 8px 12px; border-radius: var(--radius); text-decoration: none; color: var(--graphite); font-size: 0.97rem; font-weight: 500; transition: color var(--t), background var(--t); }
.nav a:not(.btn):hover { color: var(--ink); background: rgba(11, 18, 32, 0.05); }
.nav a[aria-current="page"] { color: var(--ink); box-shadow: inset 0 -2px 0 var(--blue); border-radius: 0; }
.nav-cta { margin-left: 12px; }
.menu-toggle { display: none; margin-left: auto; min-height: 40px; padding: 0 14px; border: 1px solid var(--rule-strong); border-radius: var(--radius); background: var(--sheet); font-weight: 600; }

/* Hero: the headline beside a drawing sheet on gridded paper. */
.hero { position: relative; padding-block: clamp(48px, 7vw, 96px) clamp(56px, 8vw, 104px); background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px); background-size: 28px 28px; background-position: center top; border-bottom: 1px solid var(--rule); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: clamp(32px, 6vw, 80px); align-items: center; }
.hero-copy > * + * { margin-top: 24px; }
.hero-copy .actions { margin-top: 32px; }
.hero-note { color: var(--graphite); font-size: 0.94rem; }
.hero-inner h1 { font-size: clamp(2.4rem, 5.2vw, 4.2rem); }
.hero-inner .crumbs { margin-bottom: 4px; }

.sheet { background: var(--sheet); border: 1px solid var(--rule); border-radius: var(--radius); box-shadow: var(--shadow); }
.hero-sheet { padding: 34px 34px 0 34px; }
.sheet-frame { position: relative; }
.hero-sheet figcaption { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 0 18px; font-size: 0.88rem; color: var(--graphite); line-height: 1.4; }
.hero-sheet figcaption span { max-width: 44ch; }
.dim { position: absolute; font-size: 0.74rem; color: var(--blue); font-weight: 600; letter-spacing: 0.02em; white-space: nowrap; }
.dim-x { left: 0; right: 0; top: -24px; text-align: center; }
.dim-x::before, .dim-x::after { content: ""; position: absolute; top: 50%; width: calc(50% - 34px); height: 1px; background: var(--blue); opacity: 0.45; }
.dim-x::before { left: 0; }
.dim-x::after { right: 0; }
.dim-y { top: 50%; left: -24px; transform: translate(-50%, -50%) rotate(-90deg); }
.hero-outline { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; clip-path: inset(0 0 0 var(--cut, 50%)); }
.hero-outline[hidden] { display: none; }

/* The wipe: source under trace, a range input moving the cut. */
.wipe { position: relative; aspect-ratio: 1; overflow: hidden; border-radius: 3px; background: #fff; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.wipe img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; pointer-events: none; }
.wipe-pixelated .wipe-source { image-rendering: pixelated; }
.wipe-trace { clip-path: inset(0 0 0 var(--cut)); background: #fff; }
.wipe-line { position: absolute; top: 0; bottom: 0; left: var(--cut); width: 2px; margin-left: -1px; background: var(--blue); pointer-events: none; }
.wipe-line::after { content: ""; position: absolute; top: 50%; left: 50%; width: 34px; height: 34px; margin: -17px 0 0 -17px; border-radius: 50%; background: var(--blue) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 7 4 12l5 5M15 7l5 5-5 5'/%3E%3C/svg%3E") center / 18px no-repeat; box-shadow: 0 2px 10px rgba(1, 30, 100, 0.35); }
.wipe-tag { position: absolute; bottom: 10px; padding: 3px 9px; border-radius: 3px; background: rgba(11, 18, 32, 0.82); color: #fff; font-size: 0.74rem; font-weight: 600; pointer-events: none; }
.wipe-tag-a { left: 10px; }
.wipe-tag-b { right: 10px; }
.wipe-range { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; }
.wipe:has(.wipe-range:focus-visible) { outline: 2px solid var(--blue); outline-offset: 3px; }

/* Bands */
.band { padding-block: var(--band); }
.band-sheet { background: var(--sheet); border-block: 1px solid var(--rule); }
.band-sheet + .band-sheet { border-top: 0; }
.band-ink { background: var(--ink); color: #fff; }
.section-head { max-width: 62ch; margin-bottom: clamp(32px, 5vw, 56px); }
.section-head p { margin-top: 16px; color: var(--graphite); font-size: 1.08rem; }
.section-head-row { display: flex; align-items: baseline; justify-content: space-between; gap: 20px; max-width: none; }
.section-more { margin-top: clamp(28px, 4vw, 44px); }

.split { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: clamp(32px, 6vw, 88px); align-items: center; }
.split-top { align-items: start; }
.split-copy > * + * { margin-top: 18px; }
.split-copy p { color: var(--graphite); }
.split-copy p:has(.link) { color: inherit; }

/* Figures table with size bars */
.figures { width: 100%; border-collapse: collapse; font-size: 0.98rem; font-variant-numeric: tabular-nums; }
.figures th, .figures td { padding: 15px 20px; text-align: left; border-bottom: 1px solid var(--rule); vertical-align: middle; }
.figures thead th { font-size: 0.84rem; font-weight: 600; color: var(--graphite); }
.figures tbody tr:last-child > * { border-bottom: 0; }
.figures tbody th { font-weight: 600; }
.figures .is-rekha > * { background: var(--blue-soft); }
.figures .is-rekha th { color: var(--blue-deep); }
.bar { display: inline-block; vertical-align: middle; width: calc(var(--w) * 0.9); max-width: 110px; height: 8px; margin-right: 10px; background: var(--rule-strong); border-radius: 1px; }
.is-rekha .bar { background: var(--blue); }
.figures td:nth-child(3) { width: 44%; white-space: nowrap; }
.figures-text td:nth-child(3) { width: auto; white-space: normal; }
.figures-text th[scope="row"] { width: 22%; color: var(--graphite); font-weight: 600; }

/* Features */
.features { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(36px, 5vw, 64px) clamp(32px, 6vw, 88px); }
.feature h3 { margin-top: 22px; font-size: 1.35rem; font-stretch: 88%; }
.feature p { margin-top: 10px; color: var(--graphite); max-width: 52ch; }
.diagram { width: 100%; max-width: 380px; background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); }
.diagram text { font-family: var(--font); font-size: 9px; fill: var(--graphite); }
.diagram .diagram-strong { font-size: 10px; font-weight: 700; fill: var(--ink); }
.feature-row { display: grid; grid-template-columns: minmax(0, 380px) minmax(0, 1fr); gap: clamp(28px, 6vw, 80px); align-items: center; padding-block: clamp(32px, 5vw, 56px); border-bottom: 1px solid var(--rule); }
.feature-row:first-child { padding-top: 0; }
.feature-row:last-child { border-bottom: 0; padding-bottom: 0; }
.feature-row h2 { font-size: clamp(1.5rem, 2.6vw, 2.1rem); }
.feature-row p { margin-top: 14px; max-width: 62ch; color: var(--graphite); }
.feature-row .aside { color: var(--ink); }

.details { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 clamp(32px, 6vw, 88px); }
.details > div { padding-block: 22px; border-top: 1px solid var(--rule-strong); }
.details dt { font-weight: 600; font-size: 1.08rem; }
.details dd { margin-top: 6px; color: var(--graphite); }
.details-one { grid-template-columns: 1fr; }

/* Examples and gallery */
.examples { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2.4vw, 28px); }
.example { padding: 14px 14px 0; }
.example figcaption { display: flex; flex-direction: column; padding: 14px 4px 16px; line-height: 1.35; }
.example figcaption span { color: var(--graphite); font-size: 0.9rem; font-variant-numeric: tabular-nums; }
.gallery-item { display: grid; grid-template-columns: minmax(0, 520px) minmax(0, 1fr); gap: clamp(28px, 6vw, 80px); align-items: center; padding-block: clamp(36px, 5vw, 64px); border-bottom: 1px solid var(--rule); }
.gallery-item:first-child { padding-top: 0; }
.gallery-item:last-child { border-bottom: 0; padding-bottom: 0; }
.gallery-item .sheet { padding: 14px; background: var(--paper); box-shadow: none; }
.gallery-item h2 { font-size: clamp(1.5rem, 2.6vw, 2.1rem); }
.gallery-item p { margin-top: 12px; color: var(--graphite); max-width: 50ch; }
.stats { display: flex; flex-wrap: wrap; gap: 0 32px; margin-block: 24px; border-top: 1px solid var(--rule-strong); }
.stats > div { padding-top: 12px; }
.stats dt { font-size: 0.82rem; color: var(--graphite); }
.stats dd { font-size: 1.3rem; font-weight: 600; font-stretch: 85%; font-variant-numeric: tabular-nums; }

.compare { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(28px, 6vw, 80px); align-items: center; padding-block: clamp(32px, 5vw, 52px); border-bottom: 1px solid var(--rule); }
.compare:first-child { padding-top: 0; }
.compare:last-child { border-bottom: 0; padding-bottom: 0; }
.compare h2 { font-size: clamp(1.5rem, 2.6vw, 2.1rem); }
.compare-what { margin-top: 6px; font-weight: 600; }
.compare p + p { margin-top: 12px; color: var(--graphite); }

/* Steps: a real sequence, so numbered. */
.steps { counter-reset: step; display: grid; gap: 0; }
.steps li { counter-increment: step; position: relative; padding: 22px 0 22px 64px; border-top: 1px solid var(--rule-strong); }
.steps li:last-child { border-bottom: 1px solid var(--rule-strong); }
.steps li::before { content: counter(step); position: absolute; left: 0; top: 18px; width: 40px; height: 40px; display: grid; place-items: center; border: 1.5px solid var(--blue); border-radius: 50%; color: var(--blue); font-weight: 700; font-stretch: 85%; }
.steps p { margin-top: 6px; color: var(--graphite); }

.ways { display: grid; gap: 12px; }
.ways li { padding-left: 20px; position: relative; color: var(--graphite); }
.ways li::before { content: ""; position: absolute; left: 0; top: 0.66em; width: 9px; height: 1.5px; background: var(--blue); }
.ways strong { color: var(--ink); }

/* Code */
.code { position: relative; background: var(--ink); color: #DCE4F5; border-radius: var(--radius); overflow: hidden; }
.code pre { margin: 0; padding: 46px 22px 22px; overflow-x: auto; font-family: var(--mono); font-size: 0.83rem; line-height: 1.7; tab-size: 2; }
.code code { background: none; padding: 0; font-size: inherit; color: inherit; }
.code-label { position: absolute; top: 13px; left: 22px; font-size: 0.78rem; color: #8FA0C4; font-weight: 600; }
.code-copy { position: absolute; top: 8px; right: 10px; min-height: 28px; padding: 0 10px; border: 1px solid rgba(255, 255, 255, 0.2); border-radius: 4px; background: transparent; color: #DCE4F5; font-size: 0.78rem; font-weight: 600; transition: border-color var(--t), background var(--t); }
.code-copy:hover { border-color: #fff; }

/* Jobs: links to the conversion pages */
.jobs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--rule-strong); }
.job { display: grid; grid-template-columns: 11em 1fr; gap: 20px; align-items: baseline; padding: 22px 16px 22px 0; border-bottom: 1px solid var(--rule-strong); text-decoration: none; transition: background var(--t), padding var(--t); }
.job:nth-child(odd) { margin-right: clamp(16px, 3vw, 44px); }
.job:nth-child(even) { margin-left: clamp(16px, 3vw, 44px); }
.job strong { font-size: 1.3rem; font-stretch: 85%; font-weight: 650; color: var(--blue); }
.job span { color: var(--graphite); font-size: 0.95rem; }
.job:hover { background: var(--blue-soft); padding-left: 14px; }

/* FAQ */
.faq details { border-top: 1px solid var(--rule-strong); }
.faq details:last-child { border-bottom: 1px solid var(--rule-strong); }
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 20px 0; font-weight: 600; font-size: 1.1rem; cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: none; width: 12px; height: 12px; border-right: 2px solid var(--blue); border-bottom: 2px solid var(--blue); transform: rotate(45deg) translate(-3px, -3px); transition: transform var(--t); }
.faq details[open] summary::after { transform: rotate(-135deg) translate(-3px, -3px); }
.faq p { padding: 0 44px 22px 0; color: var(--graphite); }

/* Closing call to action */
.closing { display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.closing p { margin-top: 12px; color: #B4C0DA; max-width: 52ch; }

/* Pricing */
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2.4vw, 28px); align-items: stretch; }
.plan { display: flex; flex-direction: column; padding: 28px; border: 1px solid var(--rule-strong); border-radius: var(--radius); background: var(--paper); }
.plan-featured { background: var(--sheet); border: 2px solid var(--blue); padding: 27px; box-shadow: var(--shadow); }
.plan h2 { font-size: 1.2rem; font-stretch: 100%; letter-spacing: 0; font-weight: 600; }
.plan-price { margin-top: 14px; font-size: 2.5rem; line-height: 1; font-weight: 650; font-stretch: 80%; letter-spacing: -0.015em; }
.plan-sub { margin-top: 8px; color: var(--graphite); font-size: 0.94rem; }
.plan ul { margin: 24px 0 28px; display: grid; gap: 10px; flex: 1; align-content: start; }
.plan li { position: relative; padding-left: 26px; }
.plan li::before { content: ""; position: absolute; left: 2px; top: 0.42em; width: 13px; height: 7px; border-left: 2px solid var(--blue); border-bottom: 2px solid var(--blue); transform: rotate(-45deg); }
.plans-note { margin-top: 32px; max-width: 70ch; }

/* Inner page head */
.page-head { padding-block: clamp(40px, 6vw, 80px) clamp(40px, 6vw, 72px); }
.page-head h1 { font-size: clamp(2.3rem, 5.4vw, 4.4rem); max-width: 18ch; }
.page-head .lede { margin-top: 22px; }
.page-head .actions { margin-top: 28px; }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; font-size: 0.88rem; color: var(--graphite); }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--blue); text-decoration: underline; }
.crumbs [aria-current] { color: var(--ink); font-weight: 600; }

/* Developers */
.dev { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: clamp(32px, 6vw, 80px); align-items: start; }
.dev-nav { position: sticky; top: 24px; display: grid; gap: 2px; border-left: 1px solid var(--rule-strong); }
.dev-nav a { padding: 7px 0 7px 16px; margin-left: -1px; border-left: 2px solid transparent; text-decoration: none; color: var(--graphite); font-size: 0.95rem; font-weight: 500; }
.dev-nav a:hover { color: var(--blue); border-left-color: var(--blue); }
.dev-body > section + section { margin-top: clamp(48px, 7vw, 80px); padding-top: clamp(48px, 7vw, 80px); border-top: 1px solid var(--rule); }
.dev-body h2 { font-size: clamp(1.6rem, 2.8vw, 2.2rem); }
.dev-body p, .dev-body .details { margin-top: 18px; max-width: 70ch; }
.dev-body .code { margin-top: 20px; }
.dev-body a:not(.btn) { color: var(--blue); text-underline-offset: 3px; }

/* Blog */
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 36px; }
.filters a { padding: 6px 14px; border: 1px solid var(--rule-strong); border-radius: 999px; text-decoration: none; font-size: 0.92rem; font-weight: 500; transition: border-color var(--t); }
.filters a:hover { border-color: var(--ink); }
.filters a[aria-current] { background: var(--ink); border-color: var(--ink); color: #fff; }
.posts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(28px, 4vw, 48px) clamp(24px, 3vw, 40px); }
.card { display: flex; flex-direction: column; }
.card-image { display: block; margin-bottom: 18px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--rule); transition: border-color var(--t); }
.card-image:hover { border-color: var(--blue); }
.card-drawing .diagram { max-width: none; border: 0; border-radius: 0; background: var(--paper); }
.band:not(.band-sheet) .card-drawing .diagram { background: var(--sheet); }
.card-meta { font-size: 0.84rem; color: var(--graphite); }
.card h3 { margin-top: 8px; font-size: 1.4rem; font-stretch: 85%; line-height: 1.16; font-weight: 650; letter-spacing: -0.01em; }
.card h3 a { text-decoration: none; }
.card h3 a:hover { color: var(--blue); }
.card p:last-child { margin-top: 10px; color: var(--graphite); font-size: 0.97rem; }
.pager { margin-top: 48px; }
.pager .nav-links { display: flex; gap: 8px; align-items: center; }
.pager .page-numbers { display: grid; place-items: center; min-width: 40px; min-height: 40px; padding: 0 12px; border: 1px solid var(--rule-strong); border-radius: var(--radius); text-decoration: none; font-weight: 600; }
.pager .current { background: var(--ink); border-color: var(--ink); color: #fff; }

.post-head h1 { font-size: clamp(2.1rem, 4.6vw, 3.6rem); max-width: 22ch; line-height: 1.02; }
.post-meta { margin-top: 20px; font-size: 0.92rem; color: var(--graphite); }
.post-grid { display: grid; grid-template-columns: 240px minmax(0, 720px); gap: clamp(32px, 6vw, 80px); justify-content: center; align-items: start; }
.post-grid > .prose:only-child { grid-column: 1 / -1; max-width: 720px; margin-inline: auto; }
.toc { position: sticky; top: 24px; font-size: 0.93rem; }
.toc h2 { font-size: 0.84rem; font-stretch: 100%; letter-spacing: 0; font-weight: 600; color: var(--graphite); margin-bottom: 12px; }
.toc ol { display: grid; gap: 2px; border-left: 1px solid var(--rule-strong); }
.toc a { display: block; padding: 6px 0 6px 16px; margin-left: -1px; border-left: 2px solid transparent; text-decoration: none; color: var(--graphite); line-height: 1.35; }
.toc a:hover { color: var(--blue); border-left-color: var(--blue); }

/* Prose: posts and pages written in the editor */
.prose { font-size: 1.09rem; line-height: 1.72; }
.prose > * + * { margin-top: 1.25em; }
.prose h2 { margin-top: 2em; font-size: clamp(1.55rem, 2.6vw, 2rem); line-height: 1.12; }
.prose h3 { margin-top: 1.7em; font-size: 1.28rem; }
.prose h2 + *, .prose h3 + * { margin-top: 0.7em; }
.prose a { color: var(--blue); text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose ul { list-style: none; }
.prose ul > li { position: relative; }
.prose ul > li::before { content: ""; position: absolute; left: -1.2em; top: 0.76em; width: 9px; height: 1.5px; background: var(--blue); }
.prose ol { list-style: decimal; }
.prose ol > li::marker { color: var(--blue); font-weight: 700; }
.prose li + li { margin-top: 0.5em; }
.prose blockquote { margin-inline: 0; padding-left: 20px; border-left: 2px solid var(--blue); color: var(--graphite); }
.prose img { border-radius: var(--radius); }
.prose figcaption { margin-top: 8px; font-size: 0.88rem; color: var(--graphite); text-align: left; }
.prose pre { background: var(--ink); color: #DCE4F5; padding: 20px; border-radius: var(--radius); overflow-x: auto; font-family: var(--mono); font-size: 0.84rem; line-height: 1.7; }
.prose pre code { background: none; padding: 0; color: inherit; }
.prose table { width: 100%; border-collapse: collapse; font-size: 0.96rem; line-height: 1.45; }
.prose .wp-block-table { overflow-x: auto; }
.prose th, .prose td { padding: 12px 14px; border: 0; border-bottom: 1px solid var(--rule); text-align: left; vertical-align: top; }
.prose thead th { border-bottom: 2px solid var(--ink); font-weight: 600; }
.prose .wp-block-details { border-top: 1px solid var(--rule-strong); padding-block: 14px; margin-top: 0; }
.prose .wp-block-details summary { font-weight: 600; cursor: pointer; }
.prose .wp-block-details + :not(.wp-block-details) { margin-top: 2em; }
.post-cta { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; margin-top: 3em; padding: 24px 26px; background: var(--blue-soft); border-radius: var(--radius); }
.post-cta div { display: grid; gap: 4px; }
.post-cta strong { font-size: 1.2rem; font-stretch: 88%; }
.post-cta span { color: var(--graphite); font-size: 0.97rem; line-height: 1.45; }
.post-cta .btn { color: #fff; text-decoration: none; }

/* Footer */
.foot { padding-block: clamp(48px, 7vw, 80px) 28px; border-top: 1px solid var(--rule); font-size: 0.95rem; }
.band-ink + .foot, main:has(> .band-ink:last-child) + .foot { border-top: 0; }
.foot-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) repeat(4, minmax(0, 1fr)); gap: 40px 32px; }
.foot-brand p { margin-top: 14px; color: var(--graphite); max-width: 30ch; }
.foot h2 { font-size: 0.84rem; font-stretch: 100%; letter-spacing: 0; font-weight: 600; color: var(--graphite); margin-bottom: 14px; }
.foot ul { display: grid; gap: 9px; }
.foot li a { text-decoration: none; }
.foot li a:hover { color: var(--blue); text-decoration: underline; text-underline-offset: 3px; }
.foot-base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 32px; margin-top: 56px; padding-top: 22px; border-top: 1px solid var(--rule); color: var(--graphite); font-size: 0.86rem; }

/* The one orchestrated moment: the hero's cut sweeps in once. */
@media (prefers-reduced-motion: no-preference) {
	.hero-copy > *, .hero-sheet { animation: rise 520ms cubic-bezier(0.2, 0.7, 0.2, 1) both; }
	.hero-copy > :nth-child(2) { animation-delay: 60ms; }
	.hero-copy > :nth-child(3) { animation-delay: 120ms; }
	.hero-copy > :nth-child(4) { animation-delay: 180ms; }
	.hero-sheet { animation-delay: 140ms; }
}
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	* { transition-duration: 0ms !important; animation: none !important; }
}

@media (max-width: 1020px) {
	.nav a:not(.btn) { padding-inline: 9px; }
	.foot-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
	.foot-brand { grid-column: 1 / -1; }
	.post-grid { grid-template-columns: minmax(0, 720px); }
	.toc { position: static; padding: 20px 22px; background: var(--paper); border-radius: var(--radius); }
}
@media (max-width: 900px) {
	.menu-toggle { display: inline-flex; align-items: center; }
	.nav { display: none; position: absolute; left: 0; right: 0; top: 68px; z-index: 5; flex-direction: column; align-items: stretch; gap: 0; padding: 8px var(--gutter) 20px; background: var(--paper); border-bottom: 1px solid var(--rule); box-shadow: 0 24px 40px -24px rgba(1, 30, 100, 0.3); }
	.top { position: relative; }
	.nav.is-open { display: flex; }
	.nav a:not(.btn) { padding: 14px 0; border-bottom: 1px solid var(--rule); border-radius: 0; font-size: 1.05rem; }
	.nav a[aria-current="page"] { box-shadow: none; color: var(--blue); }
	.nav-cta { margin: 16px 0 0; }
	.hero-grid, .split, .feature-row, .gallery-item, .compare, .dev { grid-template-columns: minmax(0, 1fr); }
	.hero-sheet { max-width: 560px; }
	.features, .details, .jobs { grid-template-columns: minmax(0, 1fr); }
	.job:nth-child(odd), .job:nth-child(even) { margin-inline: 0; }
	.examples, .plans, .posts { grid-template-columns: minmax(0, 1fr); }
	.examples, .plans { max-width: 520px; }
	.dev-nav { position: static; display: flex; flex-wrap: wrap; gap: 4px 18px; border-left: 0; }
	.dev-nav a { padding: 4px 0; border-left: 0; margin: 0; }
	.gallery-item .sheet { max-width: 520px; }
}
@media (max-width: 560px) {
	body { font-size: 16px; }
	.hero-sheet { padding: 30px 20px 0 30px; }
	.hero-sheet figcaption { flex-direction: column; align-items: flex-start; }
	.figures th, .figures td { padding: 12px 10px; }
	.bar { display: none; }
	.figures td:nth-child(3) { width: auto; }
	.job { grid-template-columns: 1fr; gap: 4px; }
	.foot-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.faq p { padding-right: 0; }
	.actions .btn-large { flex: 1 1 100%; }
	.steps li { padding-left: 54px; }
}
