/*
Theme Name: Pixelpad
Theme URI: https://wordpress.org/themes/
Author: Pixelpad
Description: A playful retro-desktop blogging theme for guest-post sites. Every post and box is a classic computer window. Posts on the left, then two sidebars on the right: folders for Categories and Pages, and a window of 10 shuffled posts (image, title, 100-word preview) that change on every visit. Self-hosted fonts, no theme JavaScript.
Version: 1.0.0
Requires at least: 5.9
Tested up to: 7.2
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: pixelpad
Update URI: false
Tags: blog, news, three-columns, right-sidebar, custom-logo, custom-menu, featured-images, threaded-comments, translation-ready, theme-options
*/

/* Fonts (self-hosted, no Google requests) */
@font-face {
	font-family: "Pixelify Sans";
	src: url("assets/fonts/pixelify-sans.woff2") format("woff2");
	font-weight: 400 700;
	font-style: normal;
	font-display: swap;
}
@font-face {
	font-family: "Atkinson Hyperlegible";
	src: url("assets/fonts/atkinson-hyperlegible-400.woff2") format("woff2");
	font-weight: 400 400;
	font-style: normal;
	font-display: swap;
}
@font-face {
	font-family: "Atkinson Hyperlegible";
	src: url("assets/fonts/atkinson-hyperlegible-700.woff2") format("woff2");
	font-weight: 700 700;
	font-style: normal;
	font-display: swap;
}

/* ==========================================================================
   Base (shared structure; the theme section below sets the look)
   ========================================================================== */
*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

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

img, video, svg, iframe { max-width: 100%; }
img { height: auto; }
a { color: inherit; }
p { margin: 0 0 1em; }

h1, h2, h3, h4, h5, h6 {
	margin: 0 0 0.5em;
	font-family: var(--px-display);
	line-height: 1.15;
	text-wrap: balance;
}

:focus-visible { outline: 3px solid var(--px-focus, currentColor); outline-offset: 3px; border-radius: 4px; }

.px-wrap { width: min(100% - 32px, var(--px-wrap)); margin-inline: auto; }

.screen-reader-text {
	border: 0;
	clip: rect(1px, 1px, 1px, 1px);
	clip-path: inset(50%);
	height: 1px;
	margin: -1px;
	overflow: hidden;
	padding: 0;
	position: absolute !important;
	width: 1px;
	word-wrap: normal !important;
}
.screen-reader-text:focus,
.skip-link:focus {
	clip: auto !important;
	clip-path: none;
	height: auto;
	width: auto;
	left: 12px;
	top: 12px;
	z-index: 1000;
	padding: 12px 18px;
	background: var(--px-accent);
	color: var(--px-on-accent);
	border-radius: 8px;
	font-weight: 700;
	text-decoration: none;
}

/* Buttons */
.px-btn,
.comment-form .submit {
	display: inline-flex;
	align-items: center;
	gap: 0.4em;
	padding: 0.7em 1.25em;
	background: var(--px-accent);
	color: var(--px-on-accent);
	border: 0;
	border-radius: var(--px-btn-radius, 8px);
	font-family: var(--px-display);
	font-weight: 700;
	font-size: 0.95rem;
	line-height: 1.2;
	text-decoration: none;
	cursor: pointer;
	transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}
.px-btn:hover,
.comment-form .submit:hover { transform: translateY(-2px); }

/* Mobile menu toggle (pure CSS checkbox) */
.px-nav-toggle { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.px-nav-button { display: none; }
.px-burger { position: relative; width: 18px; height: 12px; }
.px-burger::before,
.px-burger::after,
.px-burger span {
	content: "";
	position: absolute;
	left: 0;
	width: 100%;
	height: 2px;
	background: currentColor;
	border-radius: 2px;
	transition: transform 0.2s ease, opacity 0.2s ease;
}
.px-burger::before { top: 0; }
.px-burger span { top: 5px; }
.px-burger::after { top: 10px; }
.px-nav-toggle:checked + .px-nav-button .px-burger::before { transform: translateY(5px) rotate(45deg); }
.px-nav-toggle:checked + .px-nav-button .px-burger span { opacity: 0; }
.px-nav-toggle:checked + .px-nav-button .px-burger::after { transform: translateY(-5px) rotate(-45deg); }
.px-nav-toggle:focus-visible + .px-nav-button { outline: 3px solid currentColor; outline-offset: 3px; }

.px-menu { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; margin: 0; padding: 0; list-style: none; }
.px-menu li { position: relative; }
.px-menu a { display: block; text-decoration: none; }
.px-menu .sub-menu {
	position: absolute;
	top: 100%;
	left: 0;
	z-index: 60;
	min-width: 210px;
	margin: 0;
	padding: 8px;
	list-style: none;
	opacity: 0;
	visibility: hidden;
	transform: translateY(6px);
	transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s;
}
.px-menu li:hover > .sub-menu,
.px-menu li:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: none; }

/* Thumbnails */
.px-thumb {
	display: block;
	position: relative;
	overflow: hidden;
	aspect-ratio: 16 / 9;
	text-decoration: none;
	background: var(--px-soft);
}
.px-thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.4s ease;
}
a.px-thumb:hover img { transform: scale(1.04); }
.px-thumb__fallback {
	display: grid;
	place-items: center;
	width: 100%;
	height: 100%;
	background: var(--px-tone, var(--px-soft));
	font-family: var(--px-display);
	font-weight: 700;
	font-size: clamp(2.6rem, 7vw, 4.2rem);
	line-height: 1;
	color: var(--px-tone-ink, var(--px-ink));
}

/* Chips + meta */
.px-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.px-chip { text-decoration: none; }
.px-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 0; color: var(--px-muted); font-size: 0.88rem; }
.px-meta__item + .px-meta__item::before { content: "·"; margin: 0 8px; }
.px-meta a { color: var(--px-ink); font-weight: 700; text-decoration: none; }
.px-meta a:hover { text-decoration: underline; }
.px-meta__avatar { width: 40px; height: 40px; margin-right: 10px; border-radius: 50%; }

/* Lists in boxes */
.px-catlist,
.px-pagelist,
.px-randlist { margin: 0; padding: 0; list-style: none; }
.px-pagelist .children { display: none; }
.px-cat,
.px-pagelist a { text-decoration: none; }
.px-randlist,
.px-rand,
.px-rand__media { position: relative; }
.px-rand__title { margin: 0 0 6px; }
.px-rand__title a,
.px-card__title a,
.px-full__title a { text-decoration: none; }
.px-rand__text { margin: 0 0 8px; }
.px-rand__more { font-weight: 700; }
.widget.px-box > :not(.px-box__title) { margin: 16px 18px; }
.widget.px-box ul { padding-left: 1.1em; }

/* Article content */
.px-entry { font-size: 1.075rem; line-height: 1.78; overflow-wrap: break-word; }
.px-entry > * { margin-block: 0 1.15em; }
.px-entry > *:last-child { margin-bottom: 0; }
.px-entry h2 { font-size: clamp(1.45rem, 2.6vw, 1.85rem); margin-top: 1.6em; }
.px-entry h3 { font-size: clamp(1.25rem, 2.2vw, 1.5rem); margin-top: 1.5em; }
.px-entry h4 { font-size: 1.15rem; margin-top: 1.4em; }
.px-entry a { color: var(--px-link, var(--px-ink)); font-weight: 600; text-decoration: underline; text-decoration-color: var(--px-accent); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.px-entry a:hover { text-decoration-thickness: 4px; }
.px-entry ul,
.px-entry ol { padding-left: 1.4em; }
.px-entry li { margin-bottom: 0.4em; }
.px-entry li::marker { color: var(--px-accent); }
.px-entry blockquote { margin-inline: 0; }
.px-entry blockquote p:last-child { margin-bottom: 0; }
.px-entry blockquote cite { display: block; margin-top: 10px; font-size: 0.9rem; font-style: normal; color: var(--px-muted); }
.px-entry img { border-radius: var(--px-img-radius, 8px); }
.px-entry figure { margin-inline: 0; }
.px-entry figcaption,
.wp-caption-text,
.wp-element-caption { margin-top: 8px; color: var(--px-muted); font-size: 0.88rem; text-align: center; }
.px-entry code,
.px-entry kbd { padding: 0.12em 0.4em; background: var(--px-soft); border-radius: 6px; font-family: var(--px-mono); font-size: 0.88em; }
.px-entry pre { padding: 20px 22px; background: #15131c; color: #f3f0e8; border-radius: 10px; overflow-x: auto; font-family: var(--px-mono); font-size: 0.9rem; line-height: 1.6; }
.px-entry pre code { padding: 0; background: none; color: inherit; }
.px-entry table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
.px-entry th,
.px-entry td { padding: 10px 12px; border: 1px solid var(--px-line); text-align: left; }
.px-entry th { background: var(--px-soft); }
.px-entry .wp-block-table { overflow-x: auto; }
.px-entry hr { border: 0; height: 1px; background: var(--px-line); margin: 2.4em 0; }
.px-entry .more-link { display: inline-block; margin-top: 4px; font-family: var(--px-display); font-weight: 700; }
.px-pagelinks { margin-top: 22px; font-weight: 700; }
.px-pagelinks a,
.px-pagelinks > span:not(:first-child) { margin-left: 6px; }

.px-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.px-tags a { padding: 0.3em 0.75em; border-radius: 6px; background: var(--px-soft); font-size: 0.82rem; font-weight: 600; text-decoration: none; }
.px-tags a::before { content: "#"; color: var(--px-accent); margin-right: 1px; }

/* WordPress core classes */
.alignleft { float: left; margin: 0.3em 1.4em 1em 0; }
.alignright { float: right; margin: 0.3em 0 1em 1.4em; }
.aligncenter { display: block; margin-inline: auto; }
.alignwide,
.alignfull { width: 100%; }
.wp-caption { max-width: 100%; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.gallery-caption { font-size: 0.85rem; }
.sticky { position: relative; }
.bypostauthor > .comment-body { outline: 2px solid var(--px-accent); }

/* Single post */
.px-single__thumb { margin: 0; }
.px-single__thumb img { display: block; width: 100%; height: auto; }
.px-single .px-tags { margin-top: 30px; }
.px-author { display: grid; grid-template-columns: auto 1fr; gap: 18px; align-items: start; margin-top: 32px; padding: 22px; }
.px-author__avatar { width: 88px; height: 88px; border-radius: 50%; }
.px-author__label { font-size: 0.75rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--px-muted); }
.px-author__name { margin: 2px 0 6px; font-size: 1.35rem; }
.px-author__name a { text-decoration: none; }
.px-author__bio { margin: 0 0 8px; font-size: 0.98rem; color: var(--px-muted); }
.px-author__site { font-weight: 700; font-size: 0.92rem; }
@media (max-width: 520px) {
	.px-author { grid-template-columns: 1fr; }
	.px-author__avatar { width: 64px; height: 64px; }
}

.px-postnav { margin-top: 36px; }
.px-postnav .nav-links { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.px-postnav .nav-next { grid-column: 2; text-align: right; }
.px-postnav a { display: block; height: 100%; padding: 18px 20px; text-decoration: none; }
.px-postnav__label { display: block; margin-bottom: 4px; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--px-muted); }
.px-postnav__title { font-family: var(--px-display); font-weight: 700; line-height: 1.3; }
@media (max-width: 640px) {
	.px-postnav .nav-links { grid-template-columns: 1fr; }
	.px-postnav .nav-next { grid-column: auto; }
}

/* Pagination */
.pagination { margin-top: 44px; }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: 8px; }
.page-numbers {
	display: inline-grid;
	place-items: center;
	min-width: 46px;
	height: 46px;
	padding: 0 12px;
	font-family: var(--px-display);
	font-weight: 700;
	text-decoration: none;
	transition: background-color 0.15s ease, color 0.15s ease;
}
.page-numbers.dots { background: transparent !important; border-color: transparent !important; }

/* Archive header */
.px-archive-head { margin-bottom: 32px; }
.px-archive-head__title { margin: 10px 0 8px; font-size: clamp(2.1rem, 5vw, 3.2rem); }
.px-archive-head__desc { color: var(--px-muted); max-width: 60ch; }
.px-archive-head .px-search { margin-top: 18px; max-width: 520px; }

/* Search + comments */
.px-search { display: flex; gap: 8px; }
.px-search__input,
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
	width: 100%;
	padding: 12px 14px;
	background: var(--px-paper);
	color: var(--px-ink);
	border: 1px solid var(--px-line);
	border-radius: var(--px-input-radius, 8px);
	font: inherit;
	font-size: 1rem;
}
.px-search__input:focus,
.comment-form input:focus,
.comment-form textarea:focus { outline: none; border-color: var(--px-accent); box-shadow: 0 0 0 3px var(--px-ring, rgba(0, 0, 0, 0.12)); }
.px-search__btn {
	flex: none;
	display: grid;
	place-items: center;
	width: 50px;
	background: var(--px-accent);
	color: var(--px-on-accent);
	border: 0;
	border-radius: var(--px-input-radius, 8px);
	cursor: pointer;
}

.px-comments { margin-top: 44px; }
.px-comments__title { font-size: 1.6rem; margin-bottom: 20px; }
.px-comment-list,
.px-comment-list .children { margin: 0; padding: 0; list-style: none; }
.px-comment-list .children { margin-left: clamp(14px, 4vw, 34px); }
.comment-body { margin-bottom: 16px; padding: 18px 20px; background: var(--px-paper); border: 1px solid var(--px-line); border-radius: var(--px-radius); }
.comment-author { display: flex; align-items: center; gap: 10px; font-family: var(--px-display); font-weight: 700; }
.comment-author .avatar { border-radius: 50%; }
.comment-author .says { display: none; }
.comment-metadata { margin: 4px 0 10px; font-size: 0.82rem; }
.comment-metadata a { color: var(--px-muted); text-decoration: none; }
.comment-content { font-size: 1rem; }
.reply a { font-size: 0.85rem; font-weight: 700; }
.comment-respond { padding: clamp(20px, 4vw, 30px); background: var(--px-paper); border: 1px solid var(--px-line); border-radius: var(--px-radius); }
.comment-form p { margin-bottom: 14px; }
.comment-form label { display: block; margin-bottom: 4px; font-weight: 600; font-size: 0.92rem; }
.comment-form .comment-form-cookies-consent { display: flex; gap: 8px; align-items: flex-start; }
.comment-form .comment-form-cookies-consent label { display: inline; font-weight: 400; }
.comment-reply-title small { margin-left: 10px; font-size: 0.85rem; }

/* 404 + empty */
.px-404,
.px-empty { padding: clamp(28px, 5vw, 48px); text-align: center; background: var(--px-paper); border-radius: var(--px-radius); }
.px-404__num { margin: 0; font-family: var(--px-display); font-weight: 800; font-size: clamp(5rem, 18vw, 9rem); line-height: 1; color: var(--px-accent); }
.px-404 .px-search,
.px-empty .px-search { max-width: 460px; margin: 18px auto 22px; }

/* Footer widgets */
.px-footer__widgets { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 30px; padding-bottom: 32px; margin-bottom: 32px; }
.px-footer-widget ul { padding-left: 1.1em; }

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


/* ==========================================================================
   Pixelpad look
   ========================================================================== */
:root {
	--px-bg: #2a8c8c;
	--px-paper: #ffffff;
	--px-face: #c3c3c3;
	--px-hi: #ffffff;
	--px-lo: #808080;
	--px-dark: #1f1f1f;
	--px-ink: #111111;
	--px-muted: #3d3d3d;
	--px-soft: #e8e8e8;
	--px-line: #9a9a9a;
	--px-accent: #000080;
	--px-on-accent: #ffffff;
	--px-link: #0000cc;
	--px-radius: 0;
	--px-btn-radius: 0;
	--px-input-radius: 0;
	--px-img-radius: 0;
	--px-focus: #111111;
	--px-ring: rgba(0, 0, 128, 0.2);
	--px-display: "Pixelify Sans", "Courier New", monospace;
	--px-body: "Atkinson Hyperlegible", Verdana, Tahoma, system-ui, sans-serif;
	--px-mono: "Courier New", ui-monospace, monospace;
	--px-wrap: 1340px;
	--px-raised: inset -1px -1px var(--px-dark), inset 1px 1px var(--px-hi), inset -2px -2px var(--px-lo), inset 2px 2px #dfdfdf;
	--px-sunken: inset -1px -1px var(--px-hi), inset 1px 1px var(--px-lo), inset -2px -2px #dfdfdf, inset 2px 2px var(--px-dark);
}

body {
	background-color: var(--px-bg);
	background-image: radial-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1px);
	background-size: 4px 4px;
	font-size: 1rem;
}
h1, h2, h3, h4, h5, h6 { font-family: var(--px-display); font-weight: 600; letter-spacing: 0; }
:focus-visible { outline: 1px dotted #000; outline-offset: -4px; }
.px-thumb { background: var(--px-soft); }
a.px-thumb:hover img { transform: none; }
.px-thumb__fallback { background: var(--px-accent); color: #ffffff; font-family: var(--px-display); }
.px-t1 .px-thumb__fallback,
.px-thumb__fallback.px-t1 { background: #008080; }
.px-thumb__fallback.px-t2 { background: #800080; }
.px-thumb__fallback.px-t3 { background: #808000; }
.px-thumb__fallback.px-t4 { background: #800000; }

/* Bevelled buttons */
.px-btn,
.comment-form .submit,
.px-search__btn {
	background: var(--px-face);
	color: var(--px-ink);
	border: 0;
	border-radius: 0;
	box-shadow: var(--px-raised);
	font-family: var(--px-display);
	font-weight: 500;
	padding: 0.55em 1.1em;
}
.px-btn:hover,
.comment-form .submit:hover { transform: none; background: #d4d4d4; }
.px-btn:active,
.px-search__btn:active { box-shadow: var(--px-sunken); }
.px-search__input,
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea { border: 0; border-radius: 0; box-shadow: var(--px-sunken); background: #ffffff; }
.px-search__input:focus,
.comment-form input:focus,
.comment-form textarea:focus { box-shadow: var(--px-sunken); outline: 1px dotted #000; outline-offset: -5px; }
.px-search__btn { width: 42px; padding: 0; color: var(--px-ink); }

/* Window chrome */
.px-win,
.px-box,
.px-single,
.px-404,
.px-empty,
.comment-respond,
.px-archive-head {
	background: var(--px-face);
	box-shadow: var(--px-raised), 4px 4px 0 rgba(0, 0, 0, 0.25);
	padding: 4px;
	border-radius: 0;
}
.px-win__bar,
.px-box > .px-box__title,
.px-box--random .px-box__title {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	margin: 0;
	padding: 4px 4px 4px 8px;
	background: var(--px-accent);
	background: linear-gradient(90deg, var(--px-accent), color-mix(in srgb, var(--px-accent) 55%, #3aa0ff));
	color: var(--px-on-accent);
	font-family: var(--px-display);
	font-size: 0.95rem;
	font-weight: 600;
	line-height: 1.3;
}
.px-win__name { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.px-win__btns { display: flex; gap: 2px; flex: none; }
.px-wb { position: relative; width: 18px; height: 16px; background: var(--px-face); box-shadow: var(--px-raised); }
.px-wb::after { content: ""; position: absolute; background: #000; }
.px-wb--min::after { left: 5px; right: 6px; bottom: 4px; height: 2px; }
.px-wb--max::after { left: 4px; right: 5px; top: 3px; bottom: 4px; background: transparent; border: 1px solid #000; border-top-width: 2px; }
.px-wb--close::after { content: "\00d7"; inset: 0; background: none; color: #000; font: 700 14px/15px var(--px-body); text-align: center; }
.px-win__body,
.px-box__body { margin-top: 4px; padding: 16px 18px; background: var(--px-paper); box-shadow: var(--px-sunken); }
.px-win__status { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 4px; font-size: 0.8rem; }
.px-win__status > * { flex: 1 1 auto; padding: 2px 8px; box-shadow: inset -1px -1px var(--px-hi), inset 1px 1px var(--px-lo); color: var(--px-ink); text-decoration: none; white-space: nowrap; }
.px-win__status a:hover { text-decoration: underline; }

/* Menu bar */
.px-menubar { position: relative; z-index: 50; background: var(--px-face); box-shadow: inset 0 -1px var(--px-lo), inset 0 -2px var(--px-dark), inset 0 1px var(--px-hi); }
.px-menubar__inner { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; min-height: 52px; padding-block: 6px; }
.px-brand { margin-right: auto; }
.px-brand__title { margin: 0; font-family: var(--px-display); font-size: 1.35rem; font-weight: 700; }
.px-brand__title a,
.px-start { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; color: var(--px-ink); }
.px-brand__icon { flex: none; width: 22px; height: 22px; background:
	linear-gradient(#ff3b30, #ff3b30) 0 0 / 10px 10px no-repeat,
	linear-gradient(#34c759, #34c759) 12px 0 / 10px 10px no-repeat,
	linear-gradient(#0a84ff, #0a84ff) 0 12px / 10px 10px no-repeat,
	linear-gradient(#ffcc00, #ffcc00) 12px 12px / 10px 10px no-repeat;
	transform: skewX(-8deg);
}
.custom-logo { max-height: 40px; width: auto; }
.px-menubar__panel { display: flex; align-items: center; gap: 10px; }
.px-menu { gap: 0; }
.px-menu a { padding: 6px 12px; font-family: var(--px-display); font-size: 0.98rem; color: var(--px-ink); }
.px-menu a:hover,
.px-menu .current-menu-item > a,
.px-menu .current_page_item > a { background: var(--px-accent); color: var(--px-on-accent); }
.px-menu .sub-menu { background: var(--px-face); box-shadow: var(--px-raised), 3px 3px 0 rgba(0, 0, 0, 0.25); padding: 3px; }
.px-menubar .px-search__input { width: 180px; padding: 7px 10px; font-size: 0.9rem; }
.px-menubar .px-search__btn { width: 38px; }
.px-cta { padding: 0.5em 0.9em; font-size: 0.92rem; }

.px-marquee { margin-top: 14px; }
.px-marquee p { display: inline-block; margin: 0; padding: 4px 12px; background: rgba(0, 0, 0, 0.25); color: #ffffff; font-family: var(--px-display); font-size: 0.95rem; }

@media (max-width: 1000px) {
	.px-nav-button { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; background: var(--px-face); box-shadow: var(--px-raised); font-family: var(--px-display); cursor: pointer; }
	.px-menubar__panel { display: none; flex-basis: 100%; flex-direction: column; align-items: stretch; padding-bottom: 6px; }
	.px-nav-toggle:checked ~ .px-menubar__panel { display: flex; }
	.px-menu { flex-direction: column; align-items: stretch; }
	.px-menu .sub-menu { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; padding-left: 14px; }
	.px-menubar .px-search__input { width: 100%; }
	.px-cta { align-self: flex-start; }
}

/* Layout: main + two sidebars on the right */
.px-layout {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 220px 300px;
	grid-template-areas: "main a b";
	gap: 20px;
	align-items: start;
	padding-block: 20px 50px;
}
.px-main { grid-area: main; min-width: 0; }
.px-side { min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.px-side--a { grid-area: a; }
.px-side--b { grid-area: b; }
@media (max-width: 1180px) {
	.px-layout { grid-template-columns: minmax(0, 1fr) 280px; grid-template-areas: "main b" "a b"; }
}
@media (max-width: 820px) {
	.px-layout { grid-template-columns: minmax(0, 1fr); grid-template-areas: "main" "a" "b"; }
	.px-side--a { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
}

/* Post windows */
.px-feed { display: flex; flex-direction: column; gap: 22px; }
.px-full__thumb { margin: -16px -18px 16px; aspect-ratio: 16 / 8; border-bottom: 2px solid var(--px-ink); }
.px-full__title,
.px-card__title { margin: 4px 0 8px; font-size: clamp(1.5rem, 3vw, 2rem); line-height: 1.15; }
.px-full__title a,
.px-card__title a { color: var(--px-ink); }
.px-full__title a:hover,
.px-card__title a:hover { background: var(--px-accent); color: var(--px-on-accent); }
.px-full .px-meta { margin-bottom: 16px; }
.px-full .px-tags { margin-top: 18px; }
.px-card__inner { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 18px; }
.px-card__thumb { aspect-ratio: 4 / 3; box-shadow: var(--px-sunken); padding: 2px; background: var(--px-face); }
.px-card__title { font-size: 1.4rem; }
.px-card__excerpt { color: var(--px-muted); font-size: 0.97rem; }
.px-card__excerpt p { margin: 0 0 10px; }
.px-btn--bevel { font-size: 0.9rem; padding: 0.4em 1.2em; }
@media (max-width: 600px) {
	.px-card__inner { grid-template-columns: minmax(0, 1fr); }
}

.px-chip { display: inline-block; padding: 1px 8px; background: var(--px-face); box-shadow: var(--px-raised); color: var(--px-ink); font-family: var(--px-display); font-size: 0.82rem; }
.px-chip:hover { box-shadow: var(--px-sunken); }
.px-meta { font-size: 0.85rem; color: var(--px-muted); }
.px-meta a { color: var(--px-link); text-decoration: underline; }

/* Sidebar windows */
.px-box { padding: 4px; }
.px-box__heading { margin: 0; font-size: inherit; font-weight: inherit; color: inherit; }
.px-box__hint { padding: 0 6px; background: var(--px-face); color: var(--px-ink); box-shadow: var(--px-raised); font-size: 0.72rem; }
.px-box__body { padding: 10px 10px; }
.px-catlist li,
.px-pagelist li { margin: 0; }
.px-cat,
.px-pagelist a { display: flex; align-items: center; gap: 10px; padding: 5px 6px; color: var(--px-ink); font-size: 0.95rem; }
.px-cat::before {
	content: "";
	flex: none;
	width: 20px;
	height: 15px;
	background:
		linear-gradient(#f5d36c, #f5d36c) 0 3px / 20px 12px no-repeat,
		linear-gradient(#e2b33b, #e2b33b) 0 0 / 9px 4px no-repeat;
	box-shadow: inset 0 -1px #a17a16;
}
.px-pagelist a::before {
	content: "";
	flex: none;
	width: 14px;
	height: 17px;
	background: #ffffff repeating-linear-gradient(transparent 0 4px, #9a9a9a 4px 5px) 3px 4px / 8px 10px no-repeat;
	box-shadow: inset 0 0 0 1px #555;
}
.px-cat__name { flex: 1; }
.px-count { font-size: 0.78rem; color: var(--px-muted); }
.px-cat:hover,
.px-cat.is-current,
.px-pagelist a:hover,
.px-pagelist .current_page_item > a { background: var(--px-accent); color: var(--px-on-accent); }
.px-cat:hover .px-count,
.px-cat.is-current .px-count { color: var(--px-on-accent); }

.px-randlist { display: flex; flex-direction: column; }
.px-rand { padding: 10px 0 14px; border-bottom: 1px dashed var(--px-line); }
.px-rand:first-child { padding-top: 2px; }
.px-rand:last-child { border-bottom: 0; padding-bottom: 4px; }
.px-rand__thumb { aspect-ratio: 16 / 10; margin-bottom: 8px; box-shadow: var(--px-sunken); padding: 2px; background: var(--px-face); }
.px-rand__num { position: absolute; top: 6px; left: 6px; padding: 0 6px; background: var(--px-face); box-shadow: var(--px-raised); font-family: var(--px-display); font-size: 0.75rem; }
.px-rand__title { font-size: 1.05rem; line-height: 1.25; }
.px-rand__title a { color: var(--px-ink); }
.px-rand__title a:hover { background: var(--px-accent); color: var(--px-on-accent); }
.px-rand__text { font-size: 0.85rem; line-height: 1.5; color: var(--px-muted); }
.px-rand__more { display: inline-block; padding: 2px 10px; background: var(--px-face); box-shadow: var(--px-raised); color: var(--px-ink); font-family: var(--px-display); font-size: 0.82rem; font-weight: 500; text-decoration: none; }
.px-rand__more:active { box-shadow: var(--px-sunken); }
.widget.px-box > :not(.px-box__title) { margin: 4px 0 0; padding: 10px; background: #ffffff; box-shadow: var(--px-sunken); }
@media (max-width: 820px) {
	.px-randlist { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 0 20px; }
	.px-rand:last-child { border-bottom: 1px dashed var(--px-line); padding-bottom: 14px; }
}

/* Single, page, archive, 404 in windows */
.px-single::before,
.px-archive-head::before,
.px-404::before {
	content: attr(data-title);
	display: block;
	padding: 4px 8px;
	background: var(--px-accent);
	background: linear-gradient(90deg, var(--px-accent), color-mix(in srgb, var(--px-accent) 55%, #3aa0ff));
	color: var(--px-on-accent);
	font-family: var(--px-display);
	font-size: 0.95rem;
	min-height: 26px;
}
.px-single::before { content: "Document"; }
.px-page::before { content: "Page"; }
.px-archive-head::before { content: "Folder"; margin: -4px -4px 0; }
.px-404::before { content: "Error"; margin: -4px -4px 14px; background: #800000; }
.px-single__head,
.px-single__body { background: #ffffff; padding: 20px clamp(16px, 3vw, 30px); }
.px-single__head { margin-top: 4px; box-shadow: inset 1px 1px var(--px-lo), inset -1px 0 var(--px-hi); }
.px-single__thumb { background: #ffffff; padding: 0 clamp(16px, 3vw, 30px); }
.px-single__body { box-shadow: inset 1px 0 var(--px-lo), inset -1px -1px var(--px-hi); }
.px-single__title { margin: 6px 0 14px; font-size: clamp(1.9rem, 4vw, 2.7rem); line-height: 1.12; }
.px-entry a { color: var(--px-link); text-decoration-color: currentColor; text-decoration-thickness: 1px; }
.px-entry a:hover { background: var(--px-accent); color: var(--px-on-accent); }
.px-entry blockquote,
.px-entry .wp-block-quote { padding: 16px 18px; background: #ffffe1; box-shadow: inset 0 0 0 1px #000; font-size: 1.08rem; }
.px-entry pre { background: #000; color: #c0c0c0; border-radius: 0; }
.px-entry li::marker { color: var(--px-ink); }
.px-author { background: var(--px-face); box-shadow: var(--px-raised); border-radius: 0; }
.px-author__avatar { border-radius: 0; box-shadow: var(--px-sunken); padding: 2px; background: var(--px-face); }
.px-postnav a { background: var(--px-face); box-shadow: var(--px-raised); }
.px-postnav a:active { box-shadow: var(--px-sunken); }
.px-postnav__label { color: var(--px-ink); }
.px-tags a { background: var(--px-face); box-shadow: var(--px-raised); border-radius: 0; color: var(--px-ink); }
.px-tags a::before { color: var(--px-ink); }
.px-archive-head { padding-bottom: 14px; }
.px-archive-head > :not(:first-child) { margin-inline: 14px; }
.px-archive-head__title { margin-top: 12px; }
.px-kicker { display: inline-block; margin-top: 12px; font-family: var(--px-display); font-size: 0.85rem; }
.px-404__num { font-family: var(--px-display); color: #800000; }
.px-comments__title { color: #ffffff; text-shadow: 1px 1px 0 #000; }
.comment-body { background: #ffffff; border: 0; border-radius: 0; box-shadow: var(--px-sunken); }
.comment-respond { border: 0; padding: 14px 18px; }

.page-numbers { background: var(--px-face); box-shadow: var(--px-raised); border-radius: 0; color: var(--px-ink); }
a.page-numbers:hover { background: #d4d4d4; }
.page-numbers.current { box-shadow: var(--px-sunken); background: #b8b8b8; }

/* Taskbar */
.px-footer__widgets { margin-bottom: 20px; padding: 16px; background: var(--px-face); box-shadow: var(--px-raised); }
.px-taskbar { position: sticky; bottom: 0; z-index: 40; background: var(--px-face); box-shadow: inset 0 1px var(--px-hi), inset 0 2px #dfdfdf; }
.px-taskbar__inner { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; padding: 4px 6px; }
.px-start { padding: 4px 10px; background: var(--px-face); box-shadow: var(--px-raised); font-family: var(--px-display); font-weight: 700; }
.px-start:active { box-shadow: var(--px-sunken); }
.px-taskbar__menu { display: flex; flex-wrap: wrap; gap: 4px; margin: 0; padding: 0; list-style: none; }
.px-taskbar__menu a { display: block; padding: 4px 12px; min-width: 110px; background: var(--px-face); box-shadow: var(--px-raised); color: var(--px-ink); font-size: 0.85rem; text-decoration: none; }
.px-taskbar__credit { flex: 1; margin: 0; padding-inline: 6px; font-size: 0.82rem; color: var(--px-muted); }
.px-tray { display: flex; gap: 12px; padding: 4px 10px; box-shadow: inset -1px -1px var(--px-hi), inset 1px 1px var(--px-lo); font-size: 0.82rem; }
.px-tray a { color: var(--px-ink); text-decoration: none; }
@media (max-width: 700px) {
	.px-taskbar { position: static; }
	.px-taskbar__credit { flex-basis: 100%; order: 5; }
}
.px-404,
.px-empty { padding: 4px 4px 24px; }
.px-404 > *,
.px-empty > * { margin-inline: 20px; }
.px-empty { padding-top: 20px; }
