/*
Theme Name: Lightbridge
Theme URI: https://glitchcity.xyz
Author: Marz
Description: Lean Bridge-compatible theme for Glitch City. Renders the WPBakery/Qode shortcode vocabulary natively with a self-hosted design system — three-layer tokens, sophisticated components, self-hosted fonts — and no page-builder dependency. Districts restyle by overriding tokens only.
Version: 0.9.6
Requires at least: 6.0
Tested up to: 7.0
Requires PHP: 8.1
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Update URI: https://api.virtucom.net/theme/version?theme=lightbridge
Text Domain: lightbridge
*/

/* Fonts: self-hosted district packs in assets/fonts/<pack>.css (inc/fonts.php). Tokens below are the no-pack fallback. */

/* ===========================================================================
   LAYER 1 — PRIMITIVES (raw values, never referenced by components directly)
=========================================================================== */
:root {
	/* neutral ramp (HSL parts so districts can shift lightness/temperature) */
	--n-0: 0 0% 4%;
	--n-1: 0 0% 6.5%;
	--n-2: 0 0% 9%;
	--n-3: 0 0% 13%;
	--n-50: 0 0% 62%;
	--n-70: 0 0% 78%;
	--n-100: 0 0% 100%;

	/* accent as HSL parts — a district overrides just these three lines */
	--accent-h: 43;
	--accent-s: 74%;
	--accent-l: 54%;

	/* neon signal accents (shared Glitch City identity — tie to trace fx) */
	--neon-cyan: 183 100% 50%;
	--neon-magenta: 322 100% 50%;
	--neon-violet: 255 100% 69%;

	/* type families */
	--font-display: ui-sans-serif, system-ui, "Segoe UI", sans-serif;
	--font-body: ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
	--font-system: var(--font-display);
	--font-mono: ui-monospace, Consolas, monospace;

	/* fluid type scale (major-third-ish) */
	--step--1: clamp(0.82rem, 0.79rem + 0.14vw, 0.9rem);
	--step-0:  clamp(1rem, 0.96rem + 0.2vw, 1.08rem);
	--step-1:  clamp(1.2rem, 1.09rem + 0.5vw, 1.45rem);
	--step-2:  clamp(1.55rem, 1.3rem + 1.2vw, 2.1rem);
	--step-3:  clamp(2.1rem, 1.6rem + 2.4vw, 3.2rem);
	--step-4:  clamp(2.9rem, 1.9rem + 4.6vw, 5.4rem);

	/* spacing */
	--sp-2: 0.5rem;  --sp-3: 0.75rem; --sp-4: 1rem;  --sp-6: 1.5rem;
	--sp-8: 2rem;    --sp-10: 2.5rem; --sp-12: 3rem;
	--sp-section: clamp(3.5rem, 2.5rem + 5vw, 7.5rem);

	/* radius / blur */
	--r-sm: 10px; --r: 16px; --r-lg: 24px; --r-pill: 999px;
	--blur: 16px;

	/* layout */
	--grid: 1180px;
	--measure: 68ch;
	--gutter: clamp(1rem, 0.6rem + 2vw, 2rem);
}

/* ===========================================================================
   LAYER 2 — SEMANTIC (purpose aliases; components reference these)
=========================================================================== */
:root {
	--bg:            hsl(var(--n-0));
	--surface:       hsl(var(--n-1));
	--surface-2:     hsl(var(--n-2));
	--surface-3:     hsl(var(--n-3));
	--text:          hsl(var(--n-70));
	--text-dim:      hsl(var(--n-50));
	--heading:       hsl(var(--n-100));

	--accent:        hsl(var(--accent-h) var(--accent-s) var(--accent-l));
	--accent-bright: hsl(var(--accent-h) var(--accent-s) calc(var(--accent-l) + 16%));
	--accent-deep:   hsl(var(--accent-h) var(--accent-s) calc(var(--accent-l) - 20%));
	--accent-12:     hsl(var(--accent-h) var(--accent-s) var(--accent-l) / 0.12);
	--accent-24:     hsl(var(--accent-h) var(--accent-s) var(--accent-l) / 0.24);
	--accent-40:     hsl(var(--accent-h) var(--accent-s) var(--accent-l) / 0.40);

	--hairline:      hsl(var(--n-100) / 0.09);
	--hairline-2:    hsl(var(--n-100) / 0.16);

	--shadow-lift:   0 26px 70px -20px hsl(var(--n-0) / 0.9);
	--shadow-card:   0 2px 8px hsl(var(--n-0) / 0.4);

	--ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ===========================================================================
   BASE
=========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
	margin: 0;
	background: var(--bg);
	color: var(--text);
	font-family: var(--font-body);
	font-size: var(--step-0);
	line-height: 1.7;
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}

/* subtle page-level atmosphere (fixed, cheap, non-interactive) */
body::before {
	content: "";
	position: fixed;
	inset: 0;
	z-index: 0;
	pointer-events: none;
	background:
		radial-gradient(60% 50% at 50% -10%, var(--accent-12), transparent 70%),
		radial-gradient(40% 40% at 100% 0%, hsl(var(--neon-violet) / 0.06), transparent 70%);
}
.lb-header, .lb-main, .lb-footer { position: relative; z-index: 1; }

h1, h2, h3, h4 {
	font-family: var(--font-display);
	color: var(--heading);
	line-height: 1.08;
	letter-spacing: -0.02em;
	margin: 0 0 0.5em;
	font-weight: 600;
}
h1 { font-size: var(--step-4); }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-1); }

p { margin: 0 0 1em; max-width: var(--measure); }
.lb-align-center p, [class*="text-align:center"] p { margin-left: auto; margin-right: auto; }

a { color: var(--accent); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--accent-bright); }

img { max-width: 100%; height: auto; display: block; }

::selection { background: var(--accent); color: hsl(var(--n-0)); }

.screen-reader-text {
	position: absolute !important; width: 1px; height: 1px;
	overflow: hidden; clip: rect(1px,1px,1px,1px); white-space: nowrap;
}
.skip-link { position: absolute; left: -9999px; }
.skip-link:focus { left: 12px; top: 12px; z-index: 1000; background: var(--accent); color: #000; padding: 10px 16px; border-radius: var(--r-sm); }

:focus-visible { outline: 2px solid var(--accent-bright); outline-offset: 3px; }

/* ===========================================================================
   HEADER / NAV
=========================================================================== */
.lb-header {
	display: flex; align-items: center; justify-content: space-between;
	gap: var(--sp-6);
	min-height: 74px;
	padding: 0 clamp(18px, 4vw, 44px);
	position: sticky; top: 0;
	background: hsl(var(--n-0) / 0.72);
	backdrop-filter: blur(var(--blur)) saturate(1.3);
	-webkit-backdrop-filter: blur(var(--blur)) saturate(1.3);
	border-bottom: 1px solid var(--hairline);
}
.lb-branding { display: flex; align-items: center; gap: 12px; }
.lb-branding img { max-height: 42px; width: auto; }
.lb-site-title { margin: 0; font-family: var(--font-display); font-size: 1.15rem; font-weight: 600; letter-spacing: 0.28em; text-transform: uppercase; }
.lb-site-title a { color: var(--heading); }

.lb-nav ul { list-style: none; display: flex; gap: clamp(16px, 2.4vw, 34px); margin: 0; padding: 0; }
.lb-nav a { color: var(--text-dim); font-family: var(--font-display); font-size: 0.82rem; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; position: relative; padding: 6px 0; }
.lb-nav a::after { content: ""; position: absolute; left: 0; bottom: 0; height: 1px; width: 0; background: var(--accent); transition: width 0.28s var(--ease); }
.lb-nav a:hover { color: var(--heading); }
.lb-nav a:hover::after, .lb-nav .current-menu-item > a::after { width: 100%; }

.lb-nav-toggle { display: none; background: none; border: 1px solid var(--hairline-2); color: var(--heading); font-size: 18px; line-height: 1; padding: 9px 13px; border-radius: var(--r-sm); cursor: pointer; }

@media (max-width: 860px) {
	.lb-nav-toggle { display: block; }
	.lb-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--surface-2); padding: 18px clamp(18px,4vw,44px) 26px; border-bottom: 1px solid var(--hairline); }
	.lb-nav-open .lb-nav { display: block; }
	.lb-nav ul { flex-direction: column; gap: 16px; }
}

/* ===========================================================================
   ROWS / COLUMNS (vc_row / vc_column)
=========================================================================== */
.lb-row { position: relative; }
.lb-row-grid > .lb-row-inner { max-width: var(--grid); margin: 0 auto; padding-inline: var(--gutter); }
.lb-row-full > .lb-row-inner { max-width: none; }

.lb-row-parallax { background-size: cover; background-position: center; background-attachment: fixed; }
@media (max-width: 1024px) { .lb-row-parallax { background-attachment: scroll; } }

/* legibility scrim over photographic parallax rows */
.lb-row-parallax::before { content: ""; position: absolute; inset: 0; background: linear-gradient(hsl(var(--n-0) / 0.78), hsl(var(--n-0) / 0.66)); z-index: 0; }
.lb-row-parallax > .lb-row-inner { position: relative; z-index: 1; }

.lb-cols { display: grid; grid-template-columns: 1fr; gap: var(--gutter); align-items: stretch; }
@media (min-width: 768px) {
	.lb-cols { grid-template-columns: repeat(12, 1fr); }
	.lb-col, .lb-col-1-1 { grid-column: span 12; }
	.lb-col-1-2 { grid-column: span 6; }
	.lb-col-1-3 { grid-column: span 4; }
	.lb-col-2-3 { grid-column: span 8; }
	.lb-col-1-4 { grid-column: span 3; }
	.lb-col-3-4 { grid-column: span 9; }
	.lb-col-1-6 { grid-column: span 2; }
	.lb-col-5-6 { grid-column: span 10; }
	.lb-col-1-12 { grid-column: span 1; }
	.lb-col-5-12 { grid-column: span 5; }
	.lb-col-7-12 { grid-column: span 7; }
}
.lb-align-left { text-align: left; }
.lb-align-center { text-align: center; }
.lb-align-right { text-align: right; }

.lb-container { max-width: var(--grid); margin: 0 auto; padding: var(--sp-section) var(--gutter); }

/* ===========================================================================
   HERO (title band + first section)
=========================================================================== */
.lb-title-band {
	text-align: center;
	padding: clamp(64px, 12vw, 132px) var(--gutter) clamp(20px, 4vw, 44px);
	background: radial-gradient(120% 150% at 50% -20%, var(--accent-12) 0%, transparent 55%);
}
.lb-title-band h1 {
	margin: 0;
	font-size: var(--step-4);
	font-weight: 700;
	letter-spacing: -0.03em;
	background: linear-gradient(178deg, var(--heading) 12%, var(--accent-bright) 62%, var(--accent-deep));
	-webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ===========================================================================
   TYPOGRAPHIC COMPONENTS (shared; districts recolor via tokens)
   .v-* class names kept for content compatibility.
=========================================================================== */
.v-section-label, .lb-eyebrow {
	display: inline-flex; align-items: center; gap: 12px;
	font-family: var(--font-display); font-size: var(--step--1); font-weight: 600;
	letter-spacing: 0.32em; text-transform: uppercase; color: var(--accent);
	margin: 0 0 var(--sp-4);
}
.lb-align-center .v-section-label { justify-content: center; }
.v-section-label::before, .v-section-label::after { content: ""; width: 30px; height: 1px; background: linear-gradient(90deg, transparent, var(--accent-40)); }
.v-section-label::before { background: linear-gradient(90deg, var(--accent-40), transparent); }

.v-lead {
	font-family: var(--font-body); font-weight: 500; font-size: var(--step-1); line-height: 1.5; color: var(--text); max-width: 46ch; margin: 0 0 1.2em;
}
.lb-align-left .v-lead { margin-inline: 0; }

.v-body-text { color: var(--text); font-size: var(--step-0); line-height: 1.8; }

.v-quote {
	position: relative; font-family: var(--font-display); font-weight: 400; font-style: normal;
	font-size: var(--step-1); line-height: 1.4; color: var(--heading);
	padding: var(--sp-4) 0 var(--sp-4) var(--sp-6);
	border-left: 2px solid var(--accent); margin: 0;
}

/* ===========================================================================
   STAT CARDS  (counter column → card via :has)
=========================================================================== */
.lb-cols > .lb-col:has(.lb-counter) {
	background: linear-gradient(180deg, var(--surface), var(--surface-2));
	border: 1px solid var(--hairline);
	border-radius: var(--r-lg);
	padding: clamp(22px, 3vw, 34px) var(--sp-6);
	text-align: center;
	transition: border-color 0.35s var(--ease), transform 0.35s var(--ease);
}
.lb-cols > .lb-col:has(.lb-counter):hover { border-color: var(--accent-24); transform: translateY(-4px); }
.lb-counter { text-align: center; }
.lb-counter-num {
	font-family: var(--font-display); font-weight: 700; line-height: 1;
	letter-spacing: -0.03em;
	background: linear-gradient(180deg, var(--accent-bright), var(--accent-deep));
	-webkit-background-clip: text; background-clip: text; color: transparent;
}
.v-counter-label { color: var(--text-dim); font-family: var(--font-display); font-size: var(--step--1); font-weight: 500; letter-spacing: 0.16em; text-transform: uppercase; margin: 10px 0 0; }

/* ===========================================================================
   FEATURE / TIER CARDS  (icon_text)
=========================================================================== */
.lb-icon-text {
	height: 100%;
	padding: clamp(24px, 3vw, 36px);
	background: var(--surface);
	border: 1px solid var(--hairline);
	border-radius: var(--r-lg);
	text-align: left;
	position: relative; overflow: hidden;
	transition: transform 0.4s var(--ease), border-color 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.lb-icon-text::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 2px; background: linear-gradient(90deg, var(--accent), transparent 70%); opacity: 0.75; }
.lb-icon-text:hover { transform: translateY(-8px); border-color: var(--accent-24); box-shadow: var(--shadow-lift); }
.lb-icon-pos-left, .lb-icon-pos-top { display: block; }
.lb-icon {
	display: inline-grid; place-items: center;
	width: 58px; height: 58px; border-radius: 15px;
	background: var(--accent-12); color: var(--accent);
	margin-bottom: var(--sp-6);
	box-shadow: inset 0 0 0 1px var(--accent-24);
}
.lb-icon svg { width: 28px; height: 28px; }
.lb-icon-title { font-family: var(--font-display); font-size: var(--step-1); font-weight: 600; letter-spacing: -0.01em; text-transform: none; color: var(--heading); margin: 0 0 10px; }
.lb-icon-desc { color: var(--text-dim); font-size: var(--step-0); margin: 0; }

/* ===========================================================================
   BUTTONS
=========================================================================== */
.lb-btn, .qbutton {
	display: inline-flex; align-items: center; gap: 10px;
	padding: 15px 30px;
	font-family: var(--font-display); font-size: 0.86rem; font-weight: 600;
	letter-spacing: 0.1em; text-transform: uppercase;
	color: hsl(var(--n-0)); background: var(--accent);
	border: 1px solid var(--accent); border-radius: var(--r-pill);
	transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background 0.25s;
	box-shadow: 0 10px 30px -8px var(--accent-40);
}
.lb-btn:hover, .qbutton:hover { color: hsl(var(--n-0)); background: var(--accent-bright); transform: translateY(-2px); box-shadow: 0 16px 40px -10px var(--accent-40); }
.lb-btn-ghost { background: transparent; color: var(--accent); box-shadow: none; }
.lb-btn-ghost:hover { background: var(--accent-12); color: var(--accent-bright); }

/* ===========================================================================
   ACCORDION (qode_accordion → <details>)
=========================================================================== */
.qode_accordion_holder { max-width: 860px; margin: 0 auto; border-top: 1px solid var(--hairline); }
.qode_accordion_holder details { border-bottom: 1px solid var(--hairline); }
.qode_accordion_holder .accordion_title {
	cursor: pointer; list-style: none; position: relative;
	padding: var(--sp-6) 48px var(--sp-6) 4px;
	font-family: var(--font-display); font-size: var(--step-1); font-weight: 500;
	color: var(--heading); transition: color 0.25s;
}
.qode_accordion_holder .accordion_title:hover { color: var(--accent); }
.qode_accordion_holder .accordion_title::-webkit-details-marker { display: none; }
.qode_accordion_holder .accordion_title::after {
	content: ""; position: absolute; right: 6px; top: 50%; width: 12px; height: 12px;
	margin-top: -6px;
	background:
		linear-gradient(var(--accent), var(--accent)) center/12px 2px no-repeat,
		linear-gradient(var(--accent), var(--accent)) center/2px 12px no-repeat;
	transition: transform 0.3s var(--ease);
}
.qode_accordion_holder details[open] > .accordion_title::after { transform: rotate(135deg); }
.qode_accordion_holder .accordion_content { padding: 0 4px var(--sp-6); color: var(--text-dim); font-size: var(--step-0); }
.qode_accordion_holder .accordion_content > :last-child { margin-bottom: 0; }

/* large accordion: a section-scale door (e.g. the district paper) */
.qode_accordion_holder.lb-accordion-large { max-width: none; }
.lb-accordion-large > details > .accordion_title { font-size: var(--step-2); padding: var(--sp-7) 56px var(--sp-7) 0; }
.lb-accordion-large > details > .accordion_title::after { width: 18px; height: 18px; margin-top: -9px; right: 10px;
	background: linear-gradient(var(--accent), var(--accent)) center/18px 2px no-repeat, linear-gradient(var(--accent), var(--accent)) center/2px 18px no-repeat; }
.lb-accordion-large > details > .accordion_content { padding: 0 0 var(--sp-6); }


/* ===========================================================================
   IMAGES / BANNERS / DIVIDERS / SPACE
=========================================================================== */
figure.lb-image { margin: 0 0 1em; }
.lb-image-center { text-align: center; }
.lb-image-right { text-align: right; }
.lb-row-full figure.lb-image { margin: 0; line-height: 0; text-align: center; }
/* Image fit control ([vc_single_image fit="natural|grid|fill" max_height="70vh" width="50%"]).
   natural (default): never upscales past the file's own width, centered, optional max-height.
   grid: constrained to the content grid even inside a full-width row.
   fill: true full-bleed cover, the only mode that stretches; give it a max_height. */
figure.lb-image img { width: var(--img-w, auto); max-width: 100%; height: auto; margin-inline: auto; max-height: var(--img-max-h, none); object-fit: cover; }
.lb-fit-grid { max-width: var(--grid); margin-inline: auto; padding-inline: var(--gutter); }
.lb-fit-fill img { width: 100%; max-height: var(--img-max-h, none); object-fit: cover; }
.lb-fit-fill figure, .lb-row-full .lb-fit-fill { padding: 0; }

hr.lb-sep { border: 0; height: 1px; background: linear-gradient(90deg, transparent, var(--hairline-2), transparent); margin: var(--sp-8) auto; max-width: var(--grid); }
.lb-space { display: block; }

/* ===========================================================================
   YUM progressive disclosure
=========================================================================== */
.yum-full { display: none; }
/* the revealed copy sits on its own panel so it reads as "more of this", not more of the same */
.yum-open .yum-full, .yum-full.yum-open {
	display: block; margin-top: 14px; padding: 18px 22px; color: var(--text);
	background: var(--surface-2); border-left: 3px solid var(--accent); border-radius: 0 var(--r-sm) var(--r-sm) 0;
	box-shadow: inset 0 1px 0 hsl(var(--n-9) / .06);
}
.yum-trigger { color: var(--accent); cursor: pointer; font-weight: 600; white-space: nowrap; text-decoration: underline; text-underline-offset: 3px; }
.yum-trigger:hover { color: var(--accent-bright); }

/* ===========================================================================
   FOOTER
=========================================================================== */
.lb-footer { border-top: 1px solid var(--hairline); padding: var(--sp-section) var(--gutter); text-align: center; color: var(--text-dim); font-size: var(--step--1); }
.lb-footer p { margin: 0 auto; }

/* ===========================================================================
   BACK TO TOP (JS toggles .is-visible past 600px)
=========================================================================== */
.lb-to-top {
	position: fixed; right: clamp(16px, 3vw, 28px); bottom: clamp(16px, 3vw, 28px);
	z-index: 99998;
	width: 48px; height: 48px; display: grid; place-items: center;
	border-radius: var(--r-pill); cursor: pointer;
	color: var(--accent); background: hsl(var(--n-1) / 0.72);
	backdrop-filter: blur(var(--blur)); -webkit-backdrop-filter: blur(var(--blur));
	border: 1px solid var(--accent-24); box-shadow: var(--shadow-card);
	opacity: 0; transform: translateY(14px) scale(0.9); pointer-events: none;
	transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), background 0.25s, color 0.25s;
}
.lb-to-top.is-visible { opacity: 1; transform: none; pointer-events: auto; }
.lb-to-top:hover { background: var(--accent); color: hsl(var(--n-0)); transform: translateY(-3px); }
.lb-to-top svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }

/* ===========================================================================
   BOOK — [glitch_book] page-flip lore element (assets/js/book.js)
=========================================================================== */
.lb-book { max-width: var(--grid); margin: 0 auto; padding: var(--sp-6) var(--gutter); min-width: 0; }
.lb-book__head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px 24px; margin-bottom: var(--sp-4); }
.lb-book__name { font-family: var(--font-sign, var(--font-display)); font-size: var(--step-2); color: var(--accent); margin: 0; }
.lb-book__spine { font-family: var(--font-subsign, var(--font-display)); font-size: var(--step-0); color: var(--text-dim); margin: 0; }
.lb-book__toc { display: flex; flex-wrap: wrap; gap: 6px; margin-left: auto; }
.lb-book__toc-item { font: 600 0.78rem/1 var(--font-body); letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-dim); background: none; border: 1px solid var(--hairline-2); border-radius: var(--r-pill); padding: 7px 11px; cursor: pointer; }
.lb-book__toc-item:hover, .lb-book__toc-item.is-current { color: hsl(var(--n-0)); background: var(--accent); border-color: var(--accent); }
.lb-book__stage { position: relative; display: grid; grid-template-columns: 44px 1fr 44px; gap: 10px; align-items: center; }
.lb-book__spread { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 0; perspective: 2200px; background: var(--surface); border: 1px solid var(--hairline); border-radius: var(--r); box-shadow: var(--shadow-lift); min-height: 420px; overflow: hidden; }
.lb-book__spread::before { content: ""; position: absolute; inset: 0 auto 0 50%; width: 1px; background: linear-gradient(hsl(var(--n-0) / 0), hsl(var(--n-0) / .7), hsl(var(--n-0) / 0)); z-index: 3; pointer-events: none; }
.lb-book__spread > :not(.lb-book__page) { display: none; }   /* stray wpautop nodes must not take grid cells */
.lb-book__page { display: none; padding: clamp(22px, 3vw, 40px) clamp(20px, 3vw, 44px); background: linear-gradient(180deg, var(--surface), var(--surface-2)); backface-visibility: hidden; transform-origin: left center; outline: none; }
.lb-book:not(.is-ready) .lb-book__page { display: block; border-bottom: 1px solid var(--hairline); }   /* no-JS: pages flow */
.lb-book__page.is-on { display: block; }
.lb-book__page.is-left { transform-origin: right center; box-shadow: inset -30px 0 40px -30px hsl(var(--n-0) / .6); }
.lb-book__page.is-right { box-shadow: inset 30px 0 40px -30px hsl(var(--n-0) / .6); }
.lb-book__page--cover { text-align: center; }
.lb-book__page--cover .lb-book__title { margin-top: 16px; }
.lb-book__kicker { font: 600 var(--step--1)/1.2 var(--font-body); letter-spacing: 0.3em; text-transform: uppercase; color: var(--accent); margin: 0 0 8px; }
.lb-book__title { font-family: var(--font-display); font-size: var(--step-2); color: var(--heading); margin: 0 0 14px; }
.lb-book__img { width: 100%; height: auto; max-height: 40vh; object-fit: cover; border-radius: var(--r-sm); margin: 0 0 16px; }
.lb-book__body { color: var(--text); font-size: var(--step-0); line-height: 1.75; }
.lb-book__body p { max-width: none; }
.lb-book__body p:first-of-type::first-letter { font-family: var(--font-display); font-size: 2.6em; line-height: 0.9; float: left; padding: 6px 8px 0 0; color: var(--accent); }
/* the turning page lifts out of flow and flips over the already-revealed next spread */
.lb-book__meaning { margin: 22px 0 0; padding: 12px 14px; font-size: var(--step--1); line-height: 1.5; color: var(--text); background: hsl(var(--n-9) / .05); border-top: 1px solid var(--accent-24); border-radius: 0 0 var(--r-sm) var(--r-sm); }
.lb-book__meaning strong { display: block; font: 700 .68rem/1 var(--font-body); letter-spacing: .22em; text-transform: uppercase; color: var(--accent); margin-bottom: 6px; }
.lb-book--paper .lb-book__meaning { background: var(--paper-2); border-top-color: var(--ink); color: var(--ink); }
.lb-book--paper .lb-book__meaning strong { color: var(--ink-dim); }
.lb-book__page.is-turning-fwd, .lb-book__page.is-turning-back { display: block; position: absolute; top: 0; bottom: 0; width: 50%; z-index: 4; pointer-events: none; overflow: hidden; }
.lb-book__page.is-turning-fwd { left: 50%; transform-origin: left center; animation: lb-turn-fwd 0.62s cubic-bezier(.4,.1,.3,1) forwards; }
.lb-book__page.is-turning-back { left: 0; transform-origin: right center; animation: lb-turn-back 0.62s cubic-bezier(.4,.1,.3,1) forwards; }
@keyframes lb-turn-fwd { 0% { transform: rotateY(0); filter: brightness(1); } 100% { transform: rotateY(-178deg); filter: brightness(.55); } }
@keyframes lb-turn-back { 0% { transform: rotateY(0); filter: brightness(1); } 100% { transform: rotateY(178deg); filter: brightness(.55); } }
.lb-book__nav { width: 44px; height: 44px; border-radius: var(--r-pill); border: 1px solid var(--accent-24); background: hsl(var(--n-1) / .8); color: var(--accent); font-size: 26px; line-height: 1; cursor: pointer; transition: background .2s, color .2s; }
.lb-book__nav:hover:not(:disabled) { background: var(--accent); color: hsl(var(--n-0)); }
.lb-book__nav:disabled { opacity: .25; cursor: default; }
.lb-book__counter { text-align: center; font-family: var(--font-mono, monospace); font-size: var(--step--1); color: var(--text-dim); margin: 12px 0 0; }

/* --- paper: the newsprint edition ([glitch_book style="paper"]): cream stock, serif, column rules */
.lb-book--paper { --paper: #efe7d4; --paper-2: #e6dcc4; --ink: #17130e; --ink-dim: #4a4238; --rule: #17130e; }
.lb-book--paper .lb-book__head { display: block; text-align: center; color: var(--ink); background: var(--paper); border: 1px solid var(--paper-2); border-bottom: 0; border-radius: var(--r) var(--r) 0 0; padding: 22px 24px 14px; margin-bottom: 0; }
.lb-book--paper .lb-book__name { font-family: Georgia, "Times New Roman", serif; font-weight: 700; font-size: clamp(2rem, 5vw, 3.6rem); letter-spacing: .02em; text-transform: uppercase; color: var(--ink); line-height: 1; border-top: 3px double var(--rule); border-bottom: 1px solid var(--rule); padding: 12px 0 10px; }
.lb-book--paper .lb-book__spine { font: 600 .74rem/1 var(--font-body); letter-spacing: .18em; text-transform: uppercase; color: var(--ink-dim); margin: 10px 0 0; }
.lb-book--paper .lb-book__toc { justify-content: center; margin: 14px 0 0; }
.lb-book--paper .lb-book__toc-item { color: var(--ink-dim); border-color: var(--ink-dim); }
.lb-book--paper .lb-book__toc-item:hover, .lb-book--paper .lb-book__toc-item.is-current { color: var(--paper); background: var(--ink); border-color: var(--ink); }
.lb-book--paper .lb-book__spread { background: var(--paper); border-color: var(--paper-2); border-radius: 0 0 var(--r) var(--r); }
.lb-book--paper .lb-book__spread::before { background: var(--rule); opacity: .35; }
.lb-book--paper .lb-book__page { background: var(--paper); color: var(--ink); }
.lb-book--paper .lb-book__page.is-left, .lb-book--paper .lb-book__page.is-right { box-shadow: none; }
.lb-book--paper .lb-book__kicker { color: var(--ink-dim); }
.lb-book--paper .lb-book__title { font-family: Georgia, "Times New Roman", serif; font-weight: 700; color: var(--ink); letter-spacing: -.01em; }
.lb-book--paper .lb-book__img { border-radius: 0; border: 1px solid var(--ink); filter: saturate(.85) contrast(1.05); }
.lb-book--paper .lb-book__body { font-family: Georgia, "Times New Roman", serif; color: var(--ink); }
.lb-book--paper .lb-book__body p:first-of-type::first-letter { font-family: Georgia, "Times New Roman", serif; color: var(--ink); }
.lb-book--paper .lb-book__body blockquote { color: var(--ink); border-color: var(--ink); }
.lb-book--paper .lb-book__body a { color: var(--ink); }
.lb-book--paper .lb-book__nav { color: var(--ink); background: var(--paper); border-color: var(--ink-dim); }
.lb-book--paper .lb-book__nav:hover:not(:disabled) { background: var(--ink); color: var(--paper); }
.lb-book--paper .lb-book__page--cover .lb-book__title { font-size: var(--step-3); }

@media (max-width: 859px) {
	.lb-book__spread { grid-template-columns: 1fr; min-height: 360px; grid-column: 1 / -1; order: 1; }
	.lb-book__spread::before { display: none; }
	.lb-book__stage { grid-template-columns: 1fr 1fr; gap: 12px; }
	.lb-book__nav--prev { order: 2; justify-self: start; }
	.lb-book__nav--next { order: 3; justify-self: end; }
	.lb-book__page.is-turning-fwd, .lb-book__page.is-turning-back { left: 0; width: 100%; }
	.lb-book__page.is-turning-back { transform-origin: left center; animation-name: lb-turn-fwd; }
	.lb-book__page.is-left, .lb-book__page.is-right { box-shadow: none; }
	.lb-book__toc { flex: 1 1 100%; width: 0; min-width: 100%; flex-wrap: nowrap; overflow-x: auto; margin-left: 0; padding-bottom: 4px; scrollbar-width: thin; }
	.lb-book__toc-item { flex: 0 0 auto; }
}
@media (prefers-reduced-motion: reduce) {
	.lb-book__page.is-turning-fwd, .lb-book__page.is-turning-back { animation: none; }
}
@media print { .lb-book__page { display: block !important; break-inside: avoid; } .lb-book__nav, .lb-book__toc, .lb-book__counter { display: none; } }

/* ===========================================================================
   STREETS — the district after Enter: [glitch_district] > [glitch_street] > [glitch_lot]
=========================================================================== */
.lb-district { max-width: var(--grid); margin: 0 auto; padding: var(--sp-5) var(--gutter) var(--sp-8); }
.lb-district__inscription { font-family: var(--font-subsign, var(--font-display)); font-size: var(--step-1); color: var(--text-dim); margin: 0 0 var(--sp-5); }
.lb-district__chips { position: sticky; top: 0; z-index: 5; display: flex; gap: 6px; overflow-x: auto; padding: 10px 0; margin: 0 0 var(--sp-4); background: linear-gradient(hsl(var(--n-0)), hsl(var(--n-0) / .92) 70%, hsl(var(--n-0) / 0)); scrollbar-width: none; }
.lb-district__chips:empty { display: none; }
.lb-district__chip { flex: 0 0 auto; font: 600 .74rem/1 var(--font-body); letter-spacing: .1em; text-transform: uppercase; color: var(--text-dim); text-decoration: none; padding: 8px 12px; border: 1px solid var(--hairline-2); border-radius: var(--r-pill); background: hsl(var(--n-1) / .8); }
.lb-district__chip.is-here { color: hsl(var(--n-0)); background: var(--accent); border-color: var(--accent); }
.lb-street { --sh: var(--street-h, var(--accent-h)); --street: hsl(var(--sh) 80% 55%); --street-glow: hsl(var(--sh) 90% 60% / .45); position: relative; padding: var(--sp-6) 0 var(--sp-4); }
.lb-street + .lb-street { border-top: 1px dashed var(--hairline); }
.lb-street__head { display: grid; grid-template-columns: auto 1fr; gap: 6px 22px; align-items: baseline; margin-bottom: var(--sp-4); }
.lb-street__sign { grid-row: 1 / 3; margin: 0; font-family: var(--font-sign, var(--font-display)); font-size: clamp(1.6rem, 3.4vw, 2.6rem); line-height: 1; color: hsl(var(--sh) 95% 72%); text-shadow: 0 0 14px var(--street-glow), 0 0 40px var(--street-glow); padding: 10px 18px; border: 2px solid hsl(var(--sh) 80% 55% / .55); border-radius: var(--r-sm); background: hsl(var(--n-1) / .85); box-shadow: inset 0 0 30px hsl(var(--sh) 90% 60% / .12); }
.lb-street__glyph { margin-right: 10px; color: var(--street); }
.lb-street__job { margin: 0; font: 600 .78rem/1.2 var(--font-body); letter-spacing: .22em; text-transform: uppercase; color: var(--street); }
.lb-street__inscription { margin: 0; font-family: var(--font-subsign, var(--font-display)); font-size: var(--step-0); color: var(--text-dim); }
.lb-street__lots { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.lb-street__road { height: 14px; margin-top: 18px; border-top: 2px solid hsl(var(--n-9) / .12); background: repeating-linear-gradient(90deg, hsl(var(--sh) 80% 60% / .5) 0 26px, transparent 26px 52px) center / 100% 2px no-repeat; }
.lb-lot { position: relative; display: block; aspect-ratio: 16 / 10; border-radius: var(--r-sm); overflow: hidden; background: var(--surface); border: 1px solid var(--hairline); color: var(--text); text-decoration: none; transform: translateY(0); transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .25s; }
.lb-lot:hover, .lb-lot:focus-visible { transform: translateY(-4px); border-color: transparent; box-shadow: 0 0 0 2px var(--street), 0 18px 40px -16px var(--street-glow); outline: none; }
.lb-lot--featured { grid-column: span 2; aspect-ratio: 32 / 10; }
.lb-lot__facade::before { content: ""; position: absolute; inset: 6px; border: 1px solid hsl(var(--sh) 80% 55% / .35); border-radius: 3px; pointer-events: none; z-index: 1; }
.lb-lot__poster { position: absolute; inset: 0; }
.lb-lot__img { width: 100%; height: 100%; object-fit: cover; display: block; }
.lb-lot--contain .lb-lot__img { object-fit: contain; padding: 4%; background: hsl(var(--n-2)); }   /* fit="contain": a logo or seal, never cropped */
.lb-lot__facade { position: absolute; inset: 0; background: linear-gradient(180deg, hsl(var(--n-2)) 0 58%, hsl(var(--n-1)) 58% 100%); }
.lb-lot__awning { position: absolute; left: 0; right: 0; top: 0; height: 16%; background: repeating-linear-gradient(90deg, hsl(var(--sh) 70% 40%) 0 18px, hsl(var(--sh) 70% 28%) 18px 36px); border-bottom: 3px solid hsl(var(--n-0) / .6); box-shadow: 0 6px 12px -4px hsl(var(--n-0) / .7); }
.lb-lot__awning::after { content: ""; position: absolute; left: 0; right: 0; bottom: -10px; height: 10px; background: repeating-linear-gradient(90deg, hsl(var(--sh) 70% 34%) 0 18px, transparent 18px 36px); clip-path: polygon(0 0, 100% 0, 100% 40%, 0 40%); }
.lb-lot__board { position: absolute; left: 10%; right: 10%; top: 24%; padding: 6px 8px; text-align: center; font-family: var(--font-sign, var(--font-display)); font-size: clamp(.95rem, 1.4vw, 1.3rem); line-height: 1.05; color: hsl(var(--sh) 95% 75%); background: hsl(var(--n-0) / .8); border: 1px solid hsl(var(--sh) 80% 55% / .5); border-radius: 4px; text-shadow: 0 0 10px var(--street-glow); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lb-lot__window { position: absolute; left: 12%; width: 40%; top: 58%; height: 30%; background: radial-gradient(ellipse at 50% 30%, hsl(var(--sh) 90% 70% / .55), hsl(var(--sh) 80% 40% / .15) 70%); border: 2px solid hsl(var(--n-9) / .18); border-radius: 3px; }
.lb-lot__door { position: absolute; right: 14%; width: 22%; top: 55%; bottom: 0; background: hsl(var(--n-3)); border: 2px solid hsl(var(--n-9) / .18); border-bottom: 0; border-radius: 4px 4px 0 0; }
.lb-lot__num { position: absolute; left: 0; right: 0; top: 8px; text-align: center; font: 700 .62rem/1 var(--font-mono, monospace); letter-spacing: .08em; color: var(--text-dim); }
.lb-lot__badge { position: absolute; top: 10px; right: 10px; z-index: 2; font: 700 .62rem/1 var(--font-body); letter-spacing: .12em; text-transform: uppercase; padding: 6px 9px; border-radius: var(--r-pill); background: hsl(var(--n-0) / .8); color: var(--text); border: 1px solid var(--hairline-2); }
.lb-lot__badge--live { color: #7CFFB2; border-color: #7CFFB2; }
.lb-lot__badge--live::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: #7CFFB2; margin-right: 6px; animation: lb-pulse 1.6s ease-in-out infinite; }
.lb-lot__badge--soon { color: #FFD166; border-color: #FFD166; }
.lb-lot__badge--lease { color: var(--text-dim); }
.lb-lot__badge--locked { color: #F706F1; border-color: #F706F1; }
.lb-lot__cat { position: absolute; top: 10px; left: 10px; z-index: 2; font: 600 .62rem/1 var(--font-body); letter-spacing: .12em; text-transform: uppercase; color: hsl(var(--sh) 95% 75%); background: hsl(var(--n-0) / .7); padding: 6px 8px; border-radius: 4px; }
.lb-lot__caption { position: absolute; left: 0; right: 0; bottom: 0; z-index: 2; padding: 26px 12px 10px; background: linear-gradient(transparent, hsl(var(--n-0) / .85) 45%); opacity: 0; transform: translateY(6px); transition: opacity .2s, transform .2s; }
.lb-lot:hover .lb-lot__caption, .lb-lot:focus-visible .lb-lot__caption, .lb-lot.is-open .lb-lot__caption { opacity: 1; transform: none; }
.lb-lot__name { display: block; font-family: var(--font-display); font-size: var(--step-0); color: var(--heading); }
.lb-lot__line { display: block; font-size: .8rem; color: var(--text-dim); margin-top: 2px; }
.lb-lot--soon .lb-lot__facade { filter: saturate(.6); }
.lb-lot--soon .lb-lot__poster::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(-45deg, hsl(var(--n-0) / .0) 0 22px, #FFD166 22px 26px, hsl(var(--n-0) / .0) 26px 48px) bottom / 100% 12px no-repeat; }
.lb-lot--lease .lb-lot__facade { opacity: .55; }
.lb-lot--lease .lb-lot__board { color: var(--text-dim); text-shadow: none; border-style: dashed; }
.lb-lot--locked { filter: grayscale(.8); }
.lb-lot--locked:hover { filter: grayscale(.4); }
@keyframes lb-pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .4; transform: scale(.7); } }
@media (max-width: 719px) {
	.lb-street__head { grid-template-columns: 1fr; }
	.lb-street__sign { grid-row: auto; font-size: 1.5rem; }
	.lb-street__lots { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 12px; padding-bottom: 6px; margin-inline: calc(var(--gutter) * -1); padding-inline: var(--gutter); scrollbar-width: none; }
	.lb-lot, .lb-lot--featured { flex: 0 0 78%; scroll-snap-align: start; }
	.lb-lot__caption { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
	.lb-lot, .lb-lot__caption { transition: none; }
	.lb-lot__badge--live::before { animation: none; }
}

/* ===========================================================================
   PAPER — the blog index as a district paper (index.php) + single post dateline
=========================================================================== */
.lb-paper__dateline { max-width: none; font: 600 .74rem/1.4 var(--font-body); letter-spacing: .18em; text-transform: uppercase; color: var(--text-dim); text-align: center; margin: -8px 0 var(--sp-6); padding-bottom: 14px; border-bottom: 1px solid var(--hairline); }
.lb-paper__empty { max-width: none; }
.lb-paper__editions { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 22px; }
.lb-edition { margin: 0; }
.lb-edition__link { display: flex; flex-direction: column; height: 100%; background: var(--surface); border: 1px solid var(--hairline); border-radius: var(--r); overflow: hidden; color: var(--text); text-decoration: none; transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .25s; }
.lb-edition__link:hover { transform: translateY(-4px); border-color: var(--accent-24); box-shadow: var(--shadow-lift); }
.lb-edition__art img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.lb-edition__body { display: flex; flex-direction: column; gap: 8px; padding: 20px 22px 22px; }
.lb-edition__kicker { font: 600 .7rem/1 var(--font-body); letter-spacing: .2em; text-transform: uppercase; color: var(--accent); }
.lb-edition__title { margin: 0; font-family: var(--font-display); font-size: var(--step-1); color: var(--heading); line-height: 1.15; }
.lb-edition__excerpt { color: var(--text-dim); font-size: var(--step-0); line-height: 1.6; }
.lb-edition__more { margin-top: auto; padding-top: 8px; font: 600 .8rem/1 var(--font-body); letter-spacing: .08em; color: var(--accent); }
.lb-paper__empty { text-align: center; color: var(--text-dim); font-family: var(--font-subsign, var(--font-display)); font-size: var(--step-1); padding: var(--sp-7) 0; }
.lb-post-meta { font: 600 .74rem/1 var(--font-body); letter-spacing: .18em; text-transform: uppercase; color: var(--accent); margin: 0 0 var(--sp-5); }
.lb-post-meta small { font-size: inherit; }
.pagination .nav-links { display: flex; justify-content: center; gap: 10px; margin-top: var(--sp-6); }
.pagination .page-numbers { font: 600 .78rem/1 var(--font-body); letter-spacing: .1em; text-transform: uppercase; color: var(--text-dim); border: 1px solid var(--hairline-2); border-radius: var(--r-pill); padding: 10px 14px; text-decoration: none; }
.pagination .page-numbers.current, .pagination .page-numbers:hover { color: hsl(var(--n-0)); background: var(--accent); border-color: var(--accent); }

/* ===========================================================================
   CHASSIS — what every district inherits from glitchmob.wtf (inc/chassis.php)
=========================================================================== */
:root { --signal-1: #0AF2C5; --signal-2: #F706F1; --panel-light: hsl(0 0% 100% / .74); --panel-dark: hsl(0 0% 0% / .79); --footer-bg: #303030; }
body.lb-has-field::before { background: none; }
body.lb-has-field { background: #000; }
#pf-bg { z-index: 0; }
/* panels over the field: [vc_row panel="light|dark|fold|band"] */
.lb-panel { position: relative; }
.lb-panel > .lb-row-inner { padding-top: clamp(20px, 4vw, 50px); padding-bottom: clamp(20px, 4vw, 50px); }
.lb-panel-light { background: var(--panel-light); color: #111; }
.lb-panel-light h1, .lb-panel-light h2, .lb-panel-light h3, .lb-panel-light p, .lb-panel-light li, .lb-panel-light .v-lead, .lb-panel-light .v-body-text { color: #111; }
.lb-panel-light .v-section-label, .lb-panel-light .lb-eyebrow { color: #333; }
.lb-panel-light .v-section-label::before, .lb-panel-light .v-section-label::after { background: hsl(0 0% 0% / .35); }
.lb-panel-light a { color: #111; text-decoration: underline; text-underline-offset: 3px; }
.lb-panel-light .lb-icon-text { background: hsl(0 0% 100% / .62); border: 1px solid hsl(0 0% 0% / .12); box-shadow: none; }
.lb-panel-light .lb-icon-text p, .lb-panel-light .lb-icon-text .lb-icon-title { color: #111; }
.lb-panel-light .lb-icon { color: #111; background: hsl(0 0% 0% / .06); }
.lb-panel-light .lb-btn { color: #111; border-color: #111; background: transparent; }
.lb-panel-light .lb-btn:hover { background: #111; color: #fff; }
.lb-panel-dark .lb-icon-text { background: hsl(0 0% 100% / .05); }
.lb-panel-dark { background: var(--panel-dark); color: #EAEAEA; }
.lb-panel-fold { background: linear-gradient(180deg, hsl(0 0% 40% / .55), hsl(0 0% 0% / .9)); }
.lb-panel-band { background: var(--signal-1); color: #000; }
.lb-panel-band h2, .lb-panel-band h3, .lb-panel-band p { color: #000; font-style: italic; }
/* glitch-text: the glitchmob.wtf signature, ported as measured (research/glitchmob/glitchmob-glitch-text.css):
   two copies BEHIND the text (magenta, cyan), hidden 85% of a 6 s cycle, then four fast sliced jumps with
   translate + clip-path, staggered by .1 s / .2 s. Off under reduced motion. */
.glitch-text { position: relative; display: inline-block; overflow: hidden; text-shadow: 1px 1px 5px hsl(0 0% 0% / .8); }
.glitch-text::before, .glitch-text::after { content: attr(data-text); position: absolute; top: 0; left: 0; width: 100%; height: 100%; opacity: 0; pointer-events: none; background: none; -webkit-text-fill-color: currentColor; animation: lb-glitch 6s infinite ease-in-out; }
.glitch-text::before { color: var(--signal-2, #ff00ff); z-index: -1; animation-delay: .1s; }
.glitch-text::after { color: var(--signal-1, #00ffff); z-index: -2; animation-delay: .2s; }
@keyframes lb-glitch {
	0%, 85% { transform: translate(0, 0); clip-path: inset(0 0 0 0); opacity: 0; }
	87% { transform: translate(4px, -4px); clip-path: inset(5% 5% 20% 5%); opacity: 1; }
	89% { transform: translate(-6px, 6px); clip-path: inset(10% 20% 5% 15%); opacity: 1; }
	91% { transform: translate(6px, -2px); clip-path: inset(15% 10% 30% 10%); opacity: 1; }
	93% { transform: translate(-4px, 2px); clip-path: inset(20% 15% 10% 20%); opacity: 1; }
	100% { transform: translate(0, 0); clip-path: inset(0 0 0 0); opacity: 0; }
}
.glitch-text.is-glitching::before, .glitch-text.is-glitching::after { animation-duration: var(--glitch-dur, 6s); }
@media (prefers-reduced-motion: reduce) { .glitch-text::before, .glitch-text::after { display: none; } }
/* phone-line band + the #303030 four-column footer with marker titles */
.lb-phone-band { background: linear-gradient(180deg, hsl(0 0% 34%), hsl(0 0% 6%)); text-align: center; padding: clamp(26px, 5vw, 56px) var(--gutter); }
.lb-phone-band__line { margin: 0; font-family: var(--font-sign, var(--font-display)); font-size: clamp(1.4rem, 3.4vw, 2.6rem); color: #fff; letter-spacing: .02em; text-shadow: 0 0 18px hsl(0 0% 0% / .6); }
.lb-footer { border-top: 0; padding: 0; text-align: left; background: var(--footer-bg); color: #EAEAEA; font-size: var(--step--1); }
.lb-footer__cols { max-width: var(--grid); margin: 0 auto; padding: clamp(36px, 6vw, 70px) var(--gutter) clamp(28px, 5vw, 56px); display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(22px, 3vw, 44px); }
.lb-footer__col p { margin: 0 0 10px; max-width: none; color: #EAEAEA; }
.lb-footer__title { margin: 0 0 14px; font-family: var(--font-sign, var(--font-display)); font-size: 1.5rem; letter-spacing: .5px; color: var(--signal-2); line-height: 1.3; }
.lb-footer__name { font-weight: 700; color: #fff; }
.lb-footer__links { list-style: none; margin: 0; padding: 0; }
.lb-footer__links li { margin: 0 0 8px; }
.lb-footer__links a { color: #fff; text-decoration: none; }
.lb-footer__links a:hover { color: var(--signal-2); }
.lb-footer__date { display: block; font-size: .74rem; color: #A9A9A9; letter-spacing: .08em; text-transform: uppercase; }
.lb-footer__channel { border-color: var(--signal-2); color: var(--signal-2); }
.lb-footer__copy { color: #A9A9A9; margin-top: 18px; }
@media (max-width: 900px) { .lb-footer__cols { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .lb-footer__cols { grid-template-columns: 1fr; } }

/* ===========================================================================
   DESK — the district host's chat panel ([glitch_desk], assets/js/desk.js)
=========================================================================== */
.lb-desk { position: fixed; right: clamp(12px, 2vw, 28px); bottom: clamp(12px, 2vw, 28px); z-index: 40; font-family: var(--font-body); }
.lb-desk__door { display: inline-flex; align-items: center; gap: 10px; font: 700 .8rem/1 var(--font-body); letter-spacing: .14em; text-transform: uppercase; color: hsl(var(--n-0)); background: var(--accent); border: 0; border-radius: var(--r-pill); padding: 14px 20px; cursor: pointer; box-shadow: 0 14px 36px -12px var(--accent-40); }
.lb-desk__door:hover { background: var(--accent-bright); }
.lb-desk__dot { width: 8px; height: 8px; border-radius: 50%; background: hsl(var(--n-0)); animation: lb-pulse 1.8s ease-in-out infinite; }
.lb-desk__panel[hidden] { display: none; }
.lb-desk__panel { position: absolute; right: 0; bottom: calc(100% + 12px); width: min(380px, calc(100vw - 24px)); max-height: min(70vh, 560px); display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--accent-24); border-radius: var(--r); box-shadow: var(--shadow-lift); overflow: hidden; }
.lb-desk__head { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px 12px 18px; border-bottom: 1px solid var(--hairline); }
.lb-desk__name { font-family: var(--font-display); font-size: var(--step-1); color: var(--accent); }
.lb-desk__close { background: none; border: 0; color: var(--text-dim); font-size: 22px; line-height: 1; cursor: pointer; padding: 4px 8px; }
.lb-desk__log { flex: 1 1 auto; overflow-y: auto; padding: 14px 18px; display: flex; flex-direction: column; gap: 12px; min-height: 160px; }
.lb-desk__line p { margin: 0; max-width: none; font-size: .95rem; line-height: 1.55; color: var(--text); }
.lb-desk__who { display: block; font: 700 .64rem/1 var(--font-body); letter-spacing: .18em; text-transform: uppercase; color: var(--text-dim); margin-bottom: 4px; }
.lb-desk__line--host .lb-desk__who { color: var(--accent); }
.lb-desk__line--user { align-self: flex-end; text-align: right; max-width: 85%; }
.lb-desk__line--user p { background: var(--surface-2); border-radius: var(--r-sm); padding: 8px 12px; display: inline-block; text-align: left; }
.lb-desk__doorlink { display: inline-block; margin-top: 8px; font: 700 .78rem/1 var(--font-body); letter-spacing: .1em; text-transform: uppercase; color: hsl(var(--n-0)); background: var(--accent); border-radius: var(--r-pill); padding: 9px 14px; text-decoration: none; }
.lb-desk__form { display: flex; gap: 8px; padding: 12px 14px; border-top: 1px solid var(--hairline); }
.lb-desk__in { flex: 1 1 auto; min-width: 0; font: 500 .95rem/1.3 var(--font-body); color: var(--text); background: var(--surface-2); border: 1px solid var(--hairline-2); border-radius: var(--r-sm); padding: 10px 12px; }
.lb-desk__in:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.lb-desk__send { font: 700 .78rem/1 var(--font-body); letter-spacing: .1em; text-transform: uppercase; color: hsl(var(--n-0)); background: var(--accent); border: 0; border-radius: var(--r-sm); padding: 0 16px; cursor: pointer; }
.lb-desk__send:disabled { opacity: .5; cursor: default; }
.lb-desk__note { margin: 0; padding: 0 18px 12px; font-size: .7rem; color: var(--text-dim); }
.lb-desk__wait p { color: var(--text-dim); }
@media (max-width: 520px) { .lb-desk__panel { max-height: 72vh; } .lb-desk__door { padding: 12px 16px; } }
@media (prefers-reduced-motion: reduce) { .lb-desk__dot { animation: none; } }

/* ===========================================================================
   EDITORIAL — hero with the H1, plain section heads, ledger table, figures ([glitch_hero], inc/hero.php)
=========================================================================== */
.lb-hero { position: relative; display: grid; align-items: end; min-height: min(78vh, 820px); margin: 0; overflow: hidden; background: var(--surface); }
.lb-hero--short { min-height: min(52vh, 560px); }
.lb-hero__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.lb-hero__scrim { position: absolute; inset: 0; background: linear-gradient(180deg, hsl(var(--n-0) / .10) 0%, hsl(var(--n-0) / .18) 45%, hsl(var(--n-0) / .88) 100%); }
.lb-hero__inner { position: relative; z-index: 1; width: 100%; max-width: var(--grid); margin: 0 auto; padding: clamp(28px, 6vw, 72px) var(--gutter) clamp(28px, 5vw, 56px); }
.lb-hero--center .lb-hero__inner { text-align: center; }
.lb-hero__title { margin: 0 0 .25em; font-size: clamp(2.6rem, 7vw, 6.2rem); line-height: .95; letter-spacing: -.025em; max-width: 14ch; color: #fff; text-shadow: 0 2px 24px hsl(var(--n-0) / .6); }
.lb-hero--center .lb-hero__title { margin-inline: auto; }
.lb-hero__line { max-width: 44ch; font-size: var(--step-1); line-height: 1.45; color: hsl(0 0% 100% / .86); margin: 0 0 1.2em; }
.lb-hero--center .lb-hero__line { margin-inline: auto; }
.lb-hero__doors { margin: 0; display: flex; gap: 22px; align-items: center; flex-wrap: wrap; }
.lb-hero--center .lb-hero__doors { justify-content: center; }
.lb-hero__door2 { color: #fff; font-weight: 600; text-decoration: underline; text-underline-offset: 5px; text-decoration-color: var(--accent); }
.lb-hero__door2:hover { color: var(--accent-bright); }
/* plain section head: a small index + the heading, left, no rules, no uppercase kicker */
.lb-head { display: grid; grid-template-columns: auto 1fr; gap: 18px; align-items: baseline; margin: 0 0 var(--sp-5); }
.lb-head__n { font-family: var(--font-mono); font-size: var(--step--1); color: var(--accent); letter-spacing: .04em; }
.lb-head h2 { margin: 0; font-size: clamp(1.9rem, 4vw, 3.2rem); letter-spacing: -.02em; }
/* prose split: a heading column and a measured copy column */
.lb-split { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(24px, 5vw, 72px); align-items: start; }
.lb-split > * { min-width: 0; }
@media (max-width: 860px) { .lb-split { grid-template-columns: 1fr; } }
.lb-prose p { max-width: 62ch; font-size: var(--step-0); line-height: 1.75; }
.lb-prose p:first-child { font-size: var(--step-1); line-height: 1.5; }
/* ledger: a table that reads as a ledger, not three cards */
.lb-ledger { width: 100%; border-collapse: collapse; margin: 0 0 var(--sp-5); font-size: var(--step-0); }
.lb-ledger th, .lb-ledger td { text-align: left; vertical-align: top; padding: 16px 18px 16px 0; border-bottom: 1px solid var(--hairline-2); }
.lb-ledger th { font-family: var(--font-display); font-weight: 600; font-size: var(--step-1); letter-spacing: -.01em; width: 26%; color: var(--heading); }
.lb-ledger td { color: var(--text); line-height: 1.6; }
.lb-ledger td:last-child { color: var(--text-dim); width: 24%; }
.lb-ledger tr:first-child th, .lb-ledger tr:first-child td { border-top: 1px solid var(--hairline-2); }
.lb-panel-light .lb-ledger th, .lb-panel-light .lb-ledger td { color: #111; border-color: hsl(0 0% 0% / .18); }
.lb-panel-light .lb-ledger td:last-child { color: #444; }
/* figures with a caption line */
.lb-caption { font-size: var(--step--1); color: var(--text-dim); margin: 10px 0 0; max-width: 60ch; }
.lb-panel-light .lb-caption { color: #444; }
.lb-tools { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(18px, 3vw, 40px); }
.lb-tools li { border-top: 2px solid var(--accent); padding-top: 14px; }
.lb-tools strong { display: block; font-family: var(--font-display); font-size: var(--step-1); margin-bottom: 6px; }
.lb-tools p { margin: 0; max-width: none; }
@media (max-width: 720px) { .lb-tools { grid-template-columns: 1fr; } }

/* ===========================================================================
   MOTION — scroll reveal (JS adds .reveal + .is-in; safe without JS)
=========================================================================== */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.8s var(--ease), transform 0.8s var(--ease); transition-delay: var(--rd, 0ms); will-change: opacity, transform; }
.reveal.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	.reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
	.lb-row-parallax { background-attachment: scroll; }
}
