/* =====================================================================
   pages.css — styles for every page EXCEPT the homepage.
   The homepage look lives in styles.css and is not touched by this file.

   Sections (search for the === headings):
     SHARED      page header, prose, tags, placeholders, current-page nav
     ABOUT       the terminal
     WRITING     the archive listing + the post template
     ANIME       the verdict board
     BOOKS       the shelf
     MUSIC       the signal strip + era sections
     GALLERY     the grid + the viewer
     NOW         the status monitor
     SMALL SCREENS
   ===================================================================== */

:root {
	--bg: #0e0f0e;
	--panel: #0b0c0b;
	--line: #2a5a40;
	--line-dim: #1e2a20;
	--teal: #4ecfaa;
	--teal-2: #3abf90;
	--teal-3: #2a8a55;
	--teal-4: #1a5a38;
	--text: #a9c9bb;
	--text-bright: #c8f0e0;
	--amber: #cfa84e;
	--red: #cf5a4e;
	--glow: rgba(78, 207, 170, 0.5);
}

/* === SHARED ========================================================= */

.content {
	font-family: monospace;
	font-size: 12px;
	color: var(--text);
	min-width: 0;
}

.content a {
	color: var(--teal-2);
}

.content a:hover {
	color: var(--teal);
	text-shadow: 0 0 8px var(--glow);
}

/* current page highlighted in the top nav and the sidebar */
nav a.here {
	color: var(--teal);
	text-shadow: 0 0 8px rgba(78, 207, 170, 0.7);
}

.nav-item.here {
	background: linear-gradient(90deg, rgba(78, 207, 170, 0.16) 0%, transparent 80%);
	box-shadow: inset 2px 0 0 var(--teal);
}

.page-head {
	border: 1px solid var(--line);
	background: var(--panel);
	padding: 8px 10px;
	margin-bottom: 8px;
	position: relative;
	overflow: hidden;
}

.page-head::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	height: 1px;
	background: linear-gradient(90deg, transparent, var(--teal), transparent);
	opacity: 0.5;
}

.page-path {
	font-size: 12px;
	color: var(--teal-3);
	letter-spacing: 1px;
}

.page-path span {
	color: var(--teal);
	text-shadow: 0 0 8px var(--glow);
}

.page-path span::after {
	content: "_";
	animation: blink 1.1s steps(1) infinite;
}

.page-desc {
	margin-top: 4px;
	font-size: 12px;
	color: var(--teal-4);
}

@keyframes blink {
	50% { opacity: 0; }
}

.box {
	border: 1px solid var(--line);
	background: var(--panel);
	padding: 10px;
	margin-bottom: 8px;
}

.label {
	font-size: 12px;
	color: var(--teal-3);
	letter-spacing: 1px;
	text-transform: uppercase;
	margin-bottom: 8px;
}

/* long-form text */
.prose {
	max-width: 62ch;
}

.prose p {
	font-size: 13px;
	line-height: 1.75;
	color: var(--text);
	margin: 0 0 14px;
}

.prose h2 {
	font-family: monospace;
	font-size: 14px;
	color: var(--teal);
	text-shadow: 0 0 8px rgba(78, 207, 170, 0.35);
	margin: 26px 0 10px;
	font-weight: normal;
}

.prose h2::before {
	content: "## ";
	color: var(--teal-4);
}

.prose blockquote {
	margin: 16px 0;
	padding: 4px 0 4px 12px;
	border-left: 2px solid var(--teal);
	color: var(--text-bright);
	font-size: 13px;
	line-height: 1.7;
}

.prose figure {
	margin: 16px 0;
	border: 1px solid var(--line);
}

.prose figure img {
	display: block;
	width: 100%;
}

.prose figcaption {
	padding: 5px 8px;
	font-size: 11px;
	color: var(--teal-4);
	border-top: 1px solid var(--line-dim);
}

/* placeholder text — anything with class="todo" is waiting for you to write it */
.todo {
	color: var(--teal-4) !important;
	border: 1px dashed var(--line-dim);
	padding: 6px 8px;
	font-size: 12px !important;
	line-height: 1.5 !important;
}

.todo::before {
	content: "// ";
}

.tag {
	display: inline-block;
	font-size: 10px;
	letter-spacing: 1px;
	text-transform: uppercase;
	padding: 1px 6px;
	border: 1px solid var(--line);
	color: var(--teal-3);
	white-space: nowrap;
}

.chips {
	display: flex;
	flex-wrap: wrap;
	gap: 5px;
	margin-bottom: 8px;
}

.chip {
	font-family: monospace;
	font-size: 12px;
	color: var(--teal-3);
	background: var(--panel);
	border: 1px solid var(--line-dim);
	padding: 4px 9px;
	cursor: pointer;
	transition: all 0.2s;
}

.chip:hover {
	color: var(--teal);
	border-color: var(--line);
}

.chip.on {
	color: var(--teal);
	border-color: var(--teal);
	box-shadow: 0 0 10px rgba(78, 207, 170, 0.2);
	text-shadow: 0 0 6px var(--glow);
}

.chip:focus-visible,
.spine:focus-visible,
.gal-tile:focus-visible,
.sig-seg:focus-visible,
.case summary:focus-visible {
	outline: 1px solid var(--teal);
	outline-offset: 2px;
}

/* === ABOUT — the terminal ========================================== */

.term {
	border: 1px solid var(--line);
	background: #070807;
	margin-bottom: 8px;
	position: relative;
	overflow: hidden;
}

.term::after {
	content: "";
	position: absolute;
	inset: 0;
	background: repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(0, 0, 0, 0.18) 2px, rgba(0, 0, 0, 0.18) 4px);
	pointer-events: none;
}

.term-bar {
	display: flex;
	justify-content: space-between;
	padding: 4px 8px;
	border-bottom: 1px solid var(--line-dim);
	background: var(--bg);
	color: var(--teal-3);
	font-size: 11px;
	letter-spacing: 1px;
}

.term-screen {
	height: 300px;
	overflow-y: auto;
	padding: 10px;
	font-size: 12px;
	line-height: 1.6;
	scrollbar-width: thin;
	scrollbar-color: var(--line) transparent;
}

.term-line {
	white-space: pre-wrap;
	color: var(--text);
	animation: termIn 0.18s ease both;
}

.term-line.cmd {
	color: var(--teal);
	text-shadow: 0 0 6px var(--glow);
	margin-top: 8px;
}

.term-line.cmd::before {
	content: "> ";
	color: var(--teal-3);
}

.term-line b {
	color: var(--teal-2);
	font-weight: normal;
}

.term-line.dim {
	color: var(--teal-4);
}

@keyframes termIn {
	from { opacity: 0; transform: translateY(3px); }
}

.term-input-row {
	display: flex;
	align-items: center;
	gap: 6px;
	padding: 6px 10px;
	border-top: 1px solid var(--line-dim);
	color: var(--teal-3);
	position: relative;
	z-index: 1;
}

.term-input {
	flex: 1;
	min-width: 0;
	background: transparent;
	border: none;
	outline: none;
	color: var(--teal);
	font-family: monospace;
	font-size: 12px;
	caret-color: var(--teal);
}

.term-input::placeholder {
	color: var(--teal-4);
}

.term-chips {
	padding: 0 10px 10px;
	margin: 0;
	position: relative;
	z-index: 1;
}

/* === WRITING — the archive ========================================= */

.ls {
	border: 1px solid var(--line);
	background: var(--panel);
	margin-bottom: 8px;
}

.ls-head,
.ls-row {
	display: grid;
	grid-template-columns: 84px 74px 1fr 78px;
	gap: 10px;
	align-items: baseline;
	padding: 7px 10px;
}

.ls-head {
	color: var(--teal-4);
	font-size: 11px;
	letter-spacing: 1px;
	text-transform: uppercase;
	border-bottom: 1px solid var(--line);
}

.ls-head span:last-child {
	text-align: right;
}

.ls-row {
	border-bottom: 1px solid var(--line-dim);
	text-decoration: none;
	position: relative;
	transition: background 0.2s;
}

.ls-row:last-child {
	border-bottom: none;
}

.ls-row:hover {
	background: linear-gradient(90deg, rgba(78, 207, 170, 0.08), transparent 70%);
}

.ls-date {
	color: var(--teal-4);
}

.ls-title {
	color: var(--teal-2);
	font-size: 13px;
}

.ls-row:hover .ls-title {
	color: var(--teal);
	text-shadow: 0 0 8px var(--glow);
}

.ls-title::before {
	content: "";
	display: inline-block;
	width: 0;
	overflow: hidden;
	vertical-align: bottom;
	white-space: pre;
	transition: width 0.2s;
}

.ls-row:hover .ls-title::before {
	content: "> ";
	width: 2ch;
}

.ls-blurb {
	display: block;
	color: var(--teal-4);
	font-size: 11px;
	line-height: 1.5;
	max-height: 0;
	overflow: hidden;
	opacity: 0;
	transition: max-height 0.3s ease, opacity 0.3s ease, margin 0.3s ease;
}

.ls-row.on .ls-blurb,
.ls-row:hover .ls-blurb,
.ls-row:focus .ls-blurb {
	max-height: 60px;
	opacity: 1;
	margin-top: 4px;
}

.ls-status {
	text-align: right;
	font-size: 11px;
	color: var(--teal-4);
}

.ls-status.live {
	color: var(--teal);
}

.ls-row.hide,
.case.hide,
.gal-section.hide {
	display: none;
}

.ls-count {
	color: var(--teal-4);
	font-size: 11px;
	margin-bottom: 8px;
}

/* --- post template --- */

.read-bar {
	position: fixed;
	top: 0;
	left: 0;
	height: 2px;
	width: 0;
	background: var(--teal);
	box-shadow: 0 0 10px var(--teal);
	z-index: 100;
}

.post {
	border: 1px solid var(--line);
	background: var(--panel);
	padding: 18px 20px 24px;
	margin-bottom: 8px;
}

.post-title {
	font-family: monospace;
	font-size: 22px;
	font-weight: normal;
	line-height: 1.3;
	color: var(--teal);
	text-shadow: 0 0 14px rgba(78, 207, 170, 0.45);
	margin: 0 0 8px;
}

.post-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 14px;
	color: var(--teal-4);
	font-size: 11px;
	padding-bottom: 12px;
	margin-bottom: 18px;
	border-bottom: 1px solid var(--line-dim);
}

.post-nav {
	display: flex;
	justify-content: space-between;
	gap: 10px;
}

/* === ANIME — the verdict board ===================================== */

.board-stats {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 6px;
	margin-bottom: 8px;
}

.stat {
	border: 1px solid var(--line);
	background: var(--panel);
	padding: 8px 10px;
}

.stat-num {
	font-size: 22px;
	color: var(--teal);
	text-shadow: 0 0 12px var(--glow);
	line-height: 1;
}

.stat-name {
	margin-top: 5px;
	font-size: 10px;
	letter-spacing: 1px;
	text-transform: uppercase;
	color: var(--teal-4);
}

.case {
	border: 1px solid var(--line-dim);
	background: var(--panel);
	margin-bottom: 5px;
	transition: border-color 0.2s;
}

.case:hover,
.case[open] {
	border-color: var(--line);
}

.case summary {
	display: grid;
	grid-template-columns: 44px 1fr auto auto;
	gap: 10px;
	align-items: center;
	padding: 8px 10px;
	cursor: pointer;
	list-style: none;
}

.case summary::-webkit-details-marker {
	display: none;
}

.case-no {
	color: var(--teal-4);
}

.case-title {
	color: var(--teal-2);
	font-size: 13px;
}

.case:hover .case-title,
.case[open] .case-title {
	color: var(--teal);
	text-shadow: 0 0 8px var(--glow);
}

/* the stamp. Change the word inside it; add one of these classes for colour:
   v-pass (teal)  v-mark (bright, glowing)  v-warn (amber)  v-fail (red)  — no class = pending */
.verdict {
	font-size: 10px;
	letter-spacing: 2px;
	text-transform: uppercase;
	padding: 2px 7px;
	border: 1px dashed var(--line-dim);
	color: var(--teal-4);
	transform: rotate(-2deg);
	white-space: nowrap;
}

.verdict.v-pass {
	border: 1px solid var(--teal-2);
	color: var(--teal-2);
}

.verdict.v-mark {
	border: 1px solid var(--teal);
	color: var(--text-bright);
	box-shadow: 0 0 10px rgba(78, 207, 170, 0.4), inset 0 0 8px rgba(78, 207, 170, 0.15);
	text-shadow: 0 0 6px var(--teal);
}

.verdict.v-warn {
	border: 1px solid var(--amber);
	color: var(--amber);
}

.verdict.v-fail {
	border: 1px solid var(--red);
	color: var(--red);
}

.case-body {
	display: grid;
	grid-template-columns: 110px 1fr;
	gap: 12px;
	padding: 10px;
	border-top: 1px solid var(--line-dim);
	animation: termIn 0.25s ease both;
}

.case-cover {
	width: 110px;
	height: 156px;
	border: 1px solid var(--line);
	background: linear-gradient(180deg, #0d2818 0%, #060c08 100%);
	position: relative;
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
	color: rgba(78, 207, 170, 0.25);
	font-size: 10px;
}

.case-cover img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.case-cover::after {
	content: "";
	position: absolute;
	inset: 0;
	background: repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(0, 0, 0, 0.15) 2px, rgba(0, 0, 0, 0.15) 4px);
	pointer-events: none;
}

.case-fields {
	display: grid;
	grid-template-columns: 96px 1fr;
	gap: 6px 10px;
	align-content: start;
	margin: 0;
	line-height: 1.5;
}

.case-fields dt {
	color: var(--teal-4);
	text-transform: uppercase;
	font-size: 10px;
	letter-spacing: 1px;
	padding-top: 2px;
}

.case-fields dd {
	margin: 0;
	color: var(--text);
}

.legend {
	display: flex;
	flex-wrap: wrap;
	gap: 10px 14px;
	align-items: center;
	padding: 4px 2px;
}

/* === BOOKS — the shelf ============================================= */

.shelf-wrap {
	margin-bottom: 14px;
}

.shelf {
	display: flex;
	align-items: flex-end;
	gap: 3px;
	height: 226px;
	padding: 0 10px;
	border-bottom: 6px solid #16241c;
	box-shadow: 0 1px 0 var(--line), 0 10px 18px -8px rgba(78, 207, 170, 0.18);
	background: linear-gradient(180deg, transparent 60%, rgba(78, 207, 170, 0.03));
	overflow-x: auto;
	overflow-y: hidden;
	scrollbar-width: thin;
	scrollbar-color: var(--line) transparent;
}

/* a book. Set height with style="--h:160px" and colour with style="--c:#12301f" */
.spine {
	--h: 160px;
	--c: #12301f;
	flex: 0 0 auto;
	width: 34px;
	height: var(--h);
	background: linear-gradient(90deg, rgba(255, 255, 255, 0.06), transparent 30%, rgba(0, 0, 0, 0.35)), var(--c);
	border: 1px solid var(--line);
	border-bottom: none;
	color: var(--text-bright);
	font-family: monospace;
	font-size: 11px;
	cursor: pointer;
	padding: 8px 0;
	writing-mode: vertical-rl;
	text-align: left;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s, border-color 0.3s;
	position: relative;
}

.spine.wide { width: 44px; }
.spine.thin { width: 26px; }

.spine:hover {
	transform: translateY(-8px);
	border-color: var(--teal-2);
}

.spine.pulled {
	transform: translateY(-16px);
	border-color: var(--teal);
	box-shadow: 0 0 16px rgba(78, 207, 170, 0.35);
	color: var(--teal);
	text-shadow: 0 0 6px var(--glow);
}

.spine.empty {
	background: transparent;
	border-style: dashed;
	border-color: var(--line-dim);
	color: var(--teal-4);
}

.book-card {
	border: 1px solid var(--line);
	background: var(--panel);
	padding: 12px;
	min-height: 96px;
	margin-bottom: 14px;
	position: relative;
}

.book-card-title {
	font-size: 15px;
	color: var(--teal);
	text-shadow: 0 0 10px var(--glow);
}

.book-card-author {
	color: var(--teal-3);
	margin: 3px 0 8px;
}

.book-card-note {
	color: var(--text);
	line-height: 1.6;
	max-width: 62ch;
}

.book-card .tag {
	position: absolute;
	top: 12px;
	right: 12px;
}

.book-card-link {
	display: inline-block;
	margin-top: 8px;
}

/* === MUSIC — the signal + eras ===================================== */

.signal {
	position: sticky;
	top: 0;
	z-index: 20;
	border: 1px solid var(--line);
	background: rgba(11, 12, 11, 0.95);
	padding: 8px 10px 6px;
	margin-bottom: 8px;
}

.sig-bars {
	display: flex;
	gap: 4px;
	height: 44px;
	align-items: stretch;
}

.sig-seg {
	flex: 1;
	display: flex;
	align-items: flex-end;
	gap: 1px;
	background: none;
	border: none;
	padding: 0;
	cursor: pointer;
	position: relative;
}

.sig-seg i {
	flex: 1;
	background: var(--teal-4);
	opacity: 0.55;
	transition: background 0.3s, opacity 0.3s, box-shadow 0.3s;
	transform-origin: bottom;
}

.sig-seg:hover i {
	background: var(--teal-3);
	opacity: 1;
}

.sig-seg.on i {
	background: var(--teal);
	opacity: 1;
	box-shadow: 0 0 6px rgba(78, 207, 170, 0.6);
	animation: eq 0.9s ease-in-out infinite alternate;
}

.sig-seg.on i:nth-child(2n) { animation-duration: 0.6s; }
.sig-seg.on i:nth-child(3n) { animation-duration: 1.2s; }

@keyframes eq {
	from { transform: scaleY(1); }
	to { transform: scaleY(0.55); }
}

.sig-read {
	display: flex;
	justify-content: space-between;
	gap: 10px;
	margin-top: 6px;
	padding-top: 5px;
	border-top: 1px solid var(--line-dim);
	font-size: 11px;
	color: var(--teal-4);
}

.sig-read b {
	color: var(--teal);
	font-weight: normal;
	text-shadow: 0 0 6px var(--glow);
}

.era {
	border: 1px solid var(--line-dim);
	border-left: 1px solid var(--line);
	background: var(--panel);
	padding: 14px 14px 6px;
	margin-bottom: 8px;
	scroll-margin-top: 96px;
	position: relative;
}

.era-head {
	display: flex;
	align-items: baseline;
	gap: 10px;
	margin-bottom: 12px;
}

.era-no {
	color: var(--teal-4);
	font-size: 12px;
}

.era-title {
	font-family: monospace;
	font-weight: normal;
	font-size: 17px;
	color: var(--teal);
	text-shadow: 0 0 10px rgba(78, 207, 170, 0.4);
	margin: 0;
}

.era-artists {
	display: flex;
	flex-wrap: wrap;
	gap: 5px;
	margin: 0 0 14px;
}

.tracks {
	list-style: none;
	margin: 0 0 14px;
	padding: 0;
	border: 1px solid var(--line-dim);
	counter-reset: track;
}

.tracks li {
	counter-increment: track;
	display: grid;
	grid-template-columns: 28px 1fr 1fr;
	gap: 8px;
	padding: 5px 8px;
	border-bottom: 1px solid var(--line-dim);
	color: var(--text);
}

.tracks li:last-child {
	border-bottom: none;
}

.tracks li::before {
	content: counter(track, decimal-leading-zero);
	color: var(--teal-4);
}

.tracks li:hover {
	background: rgba(78, 207, 170, 0.06);
}

.tracks .artist {
	color: var(--teal-3);
}

.tracks li.blank {
	color: var(--teal-4);
}

.art-row {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 6px;
	margin-bottom: 14px;
}

.art {
	aspect-ratio: 1;
	border: 1px solid var(--line-dim);
	background: linear-gradient(135deg, #0d2818 0%, #060c08 100%);
	display: flex;
	align-items: center;
	justify-content: center;
	color: rgba(78, 207, 170, 0.25);
	font-size: 10px;
	overflow: hidden;
}

.art img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* === GALLERY ======================================================= */

.gal-grid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	grid-auto-rows: 170px;
	gap: 6px;
	margin-bottom: 14px;
}

.gal-tile {
	position: relative;
	overflow: hidden;
	border: 1px solid var(--line-dim);
	background: linear-gradient(135deg, #0d3020 0%, #060c08 100%);
	cursor: pointer;
	padding: 0;
	font-family: monospace;
	color: rgba(78, 207, 170, 0.25);
	font-size: 10px;
	transition: border-color 0.25s, box-shadow 0.25s;
}

/* make a tile bigger with class="gal-tile tall" or "gal-tile wide" */
.gal-tile.tall { grid-row: span 2; }
.gal-tile.wide { grid-column: span 2; }

.gal-tile img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	filter: saturate(0.85) brightness(0.9);
	transition: transform 0.5s ease, filter 0.3s ease;
}

.gal-tile:hover {
	border-color: var(--teal);
	box-shadow: 0 0 14px rgba(78, 207, 170, 0.25);
}

.gal-tile:hover img {
	transform: scale(1.05);
	filter: none;
}

.gal-cap {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	padding: 18px 8px 6px;
	text-align: left;
	font-size: 11px;
	color: var(--text-bright);
	background: linear-gradient(0deg, rgba(0, 0, 0, 0.85), transparent);
	opacity: 0;
	transform: translateY(6px);
	transition: all 0.25s ease;
}

.gal-tile:hover .gal-cap,
.gal-tile:focus-visible .gal-cap {
	opacity: 1;
	transform: none;
}

/* phones have no hover: gallery captions stay visible, and archive previews
   open with a tap (pages.js) instead */
@media (hover: none) {
	.gal-cap {
		opacity: 1;
		transform: none;
	}

	.ls-row:hover .ls-blurb,
	.ls-row:focus .ls-blurb {
		max-height: 0;
		opacity: 0;
		margin-top: 0;
	}

	.ls-row.on .ls-blurb {
		max-height: 60px;
		opacity: 1;
		margin-top: 4px;
	}

	.spine:hover:not(.pulled) {
		transform: none;
	}
}

/* the viewer */
.lb {
	position: fixed;
	inset: 0;
	z-index: 200;
	background: rgba(4, 6, 5, 0.95);
	display: none;
	flex-direction: column;
	font-family: monospace;
}

.lb.open {
	display: flex;
}

.lb-top {
	display: flex;
	justify-content: space-between;
	padding: 10px 14px;
	color: var(--teal-3);
	font-size: 12px;
	border-bottom: 1px solid var(--line-dim);
}

.lb-close,
.lb-arrow {
	background: none;
	border: 1px solid var(--line);
	color: var(--teal);
	font-family: monospace;
	font-size: 12px;
	cursor: pointer;
	padding: 2px 8px;
}

.lb-close:hover,
.lb-arrow:hover {
	border-color: var(--teal);
	box-shadow: 0 0 10px rgba(78, 207, 170, 0.3);
}

.lb-stage {
	flex: 1;
	min-height: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	padding: 14px;
}

.lb-frame {
	position: relative;
	max-width: 100%;
	max-height: 100%;
	min-width: 0;
	display: flex;
	border: 1px solid var(--line);
	box-shadow: 0 0 40px rgba(78, 207, 170, 0.12);
	overflow: hidden;
}

.lb-frame img {
	max-width: 100%;
	max-height: calc(100vh - 190px);
	display: block;
}

.lb-empty {
	width: min(60vw, 520px);
	height: min(50vh, 380px);
	display: flex;
	align-items: center;
	justify-content: center;
	color: var(--teal-4);
	background: linear-gradient(135deg, #0d3020 0%, #060c08 100%);
}

.lb-frame::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	top: -30%;
	height: 30%;
	background: linear-gradient(180deg, transparent, rgba(78, 207, 170, 0.07), transparent);
	animation: scanMove 5s linear infinite;
	pointer-events: none;
}

.lb-caption {
	text-align: center;
	color: var(--text-bright);
	font-size: 12px;
	padding: 0 14px 8px;
}

.lb-strip {
	display: flex;
	gap: 4px;
	justify-content: center;
	padding: 8px 14px 14px;
	overflow-x: auto;
}

.lb-thumb {
	flex: 0 0 auto;
	width: 46px;
	height: 46px;
	border: 1px solid var(--line-dim);
	background: linear-gradient(135deg, #0d3020 0%, #060c08 100%);
	padding: 0;
	cursor: pointer;
	opacity: 0.45;
	overflow: hidden;
}

.lb-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.lb-thumb.on {
	opacity: 1;
	border-color: var(--teal);
	box-shadow: 0 0 8px rgba(78, 207, 170, 0.5);
}

/* === NOW — the status monitor ====================================== */

.now-top {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 12px;
	border: 1px solid var(--line);
	background: var(--panel);
	padding: 10px 12px;
	margin-bottom: 8px;
}

.now-updated {
	color: var(--teal-3);
	line-height: 1.6;
}

.now-updated b {
	color: var(--teal);
	font-weight: normal;
	text-shadow: 0 0 6px var(--glow);
}

.meter {
	display: flex;
	align-items: flex-end;
	gap: 3px;
	height: 26px;
}

.meter i {
	width: 5px;
	background: var(--line-dim);
}

.meter i:nth-child(1) { height: 20%; }
.meter i:nth-child(2) { height: 40%; }
.meter i:nth-child(3) { height: 60%; }
.meter i:nth-child(4) { height: 80%; }
.meter i:nth-child(5) { height: 100%; }

.meter i.lit {
	background: var(--teal);
	box-shadow: 0 0 6px rgba(78, 207, 170, 0.6);
}

.meter.fading i.lit {
	background: var(--amber);
	box-shadow: 0 0 6px rgba(207, 168, 78, 0.5);
}

.meter.lost i.lit {
	background: var(--red);
	box-shadow: 0 0 6px rgba(207, 90, 78, 0.5);
}

.meter-wrap {
	display: flex;
	align-items: center;
	gap: 10px;
	color: var(--teal-4);
	font-size: 11px;
	text-align: right;
	line-height: 1.5;
}

.now-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 6px;
	margin-bottom: 8px;
}

.now-card {
	border: 1px solid var(--line);
	background: var(--panel);
	padding: 10px;
}

.now-card.span {
	grid-column: span 2;
}

.now-card .label::before {
	content: "● ";
	color: var(--teal);
	text-shadow: 0 0 6px var(--teal);
	animation: pulse 2.4s ease-in-out infinite;
}

@keyframes pulse {
	50% { opacity: 0.3; }
}

.now-item {
	padding: 6px 0;
	border-top: 1px solid var(--line-dim);
}

.now-item-name {
	color: var(--teal-2);
	font-size: 13px;
}

.now-item-note {
	color: var(--teal-4);
	margin-top: 2px;
	line-height: 1.5;
}

/* a progress bar: <div class="bar" data-progress="40"></div>  (0–100) */
.bar {
	height: 5px;
	margin-top: 6px;
	border: 1px solid var(--line-dim);
	position: relative;
}

.bar::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0;
	bottom: 0;
	width: var(--p, 0%);
	background: linear-gradient(90deg, var(--teal-4), var(--teal));
	box-shadow: 0 0 6px rgba(78, 207, 170, 0.5);
	transition: width 1.2s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.snap {
	border-top: 1px solid var(--line-dim);
}

.snap summary {
	padding: 7px 0;
	cursor: pointer;
	color: var(--teal-3);
}

.snap summary:hover {
	color: var(--teal);
}

.snap-body {
	padding: 0 0 10px 14px;
	color: var(--text);
	line-height: 1.7;
}

/* anything that can be dragged with the mouse or swiped with a finger
   (see addDrag in the .js file). pan-y keeps normal up/down scrolling. */
.swipeable {
	touch-action: pan-y;
	user-select: none;
	-webkit-user-select: none;
	cursor: grab;
}

.swipeable.grabbing,
.swipeable.grabbing * {
	cursor: grabbing;
}

/* === SMALL SCREENS ================================================= */

@media (max-width: 700px) {
	.body-wrapper { display: block; }
	.sidebar { width: auto; min-height: 0; border-right: none; border-bottom: 1px solid #181a18; }
	.sidebar .panel:last-child { display: none; }  /* top nav already has the links */
	nav { display: flex; flex-wrap: wrap; row-gap: 4px; }
	.board-stats { grid-template-columns: 1fr 1fr; }
	.gal-grid { grid-template-columns: 1fr 1fr; grid-auto-rows: 140px; }
	.now-grid { grid-template-columns: 1fr; }
	.now-card.span { grid-column: auto; }
	.art-row { grid-template-columns: 1fr 1fr; }
	.ls-head, .ls-row { grid-template-columns: 74px 1fr; }
	.ls-head span:nth-child(2), .ls-row .ls-cat, .ls-head span:nth-child(4), .ls-status { display: none; }
	.case summary { grid-template-columns: 36px 1fr auto; }
	.case summary .tag { display: none; }
	.case-body { grid-template-columns: 1fr; }
	.post { padding: 14px 12px 18px; }
	.lb-arrow { display: none; }
	.now-top { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation: none !important; transition: none !important; }
}
