/*
Theme Name: Prompt
Theme URI: https://wordpress.org/themes/
Author: Prompt
Description: A hacker-terminal blogging theme for guest-post sites. Monospace text on a dark screen, a file-tree sidebar for Categories and Pages on the left, posts as terminal output in the middle, and 10 shuffled posts (image, title, 100-word preview) on the right that change on every visit. Self-hosted font, 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: prompt
Update URI: false
Tags: blog, news, three-columns, left-sidebar, right-sidebar, custom-logo, custom-menu, featured-images, threaded-comments, translation-ready, theme-options
*/

/* Fonts (self-hosted, no Google requests) */
@font-face {
	font-family: "JetBrains Mono";
	src: url("assets/fonts/jetbrains-mono.woff2") format("woff2");
	font-weight: 100 800;
	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(--pr-bg);
	color: var(--pr-ink);
	font-family: var(--pr-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(--pr-display);
	line-height: 1.15;
	text-wrap: balance;
}

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

.pr-wrap { width: min(100% - 32px, var(--pr-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(--pr-accent);
	color: var(--pr-on-accent);
	border-radius: 8px;
	font-weight: 700;
	text-decoration: none;
}

/* Buttons */
.pr-btn,
.comment-form .submit {
	display: inline-flex;
	align-items: center;
	gap: 0.4em;
	padding: 0.7em 1.25em;
	background: var(--pr-accent);
	color: var(--pr-on-accent);
	border: 0;
	border-radius: var(--pr-btn-radius, 8px);
	font-family: var(--pr-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;
}
.pr-btn:hover,
.comment-form .submit:hover { transform: translateY(-2px); }

/* Mobile menu toggle (pure CSS checkbox) */
.pr-nav-toggle { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.pr-nav-button { display: none; }
.pr-burger { position: relative; width: 18px; height: 12px; }
.pr-burger::before,
.pr-burger::after,
.pr-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;
}
.pr-burger::before { top: 0; }
.pr-burger span { top: 5px; }
.pr-burger::after { top: 10px; }
.pr-nav-toggle:checked + .pr-nav-button .pr-burger::before { transform: translateY(5px) rotate(45deg); }
.pr-nav-toggle:checked + .pr-nav-button .pr-burger span { opacity: 0; }
.pr-nav-toggle:checked + .pr-nav-button .pr-burger::after { transform: translateY(-5px) rotate(-45deg); }
.pr-nav-toggle:focus-visible + .pr-nav-button { outline: 3px solid currentColor; outline-offset: 3px; }

.pr-menu { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; margin: 0; padding: 0; list-style: none; }
.pr-menu li { position: relative; }
.pr-menu a { display: block; text-decoration: none; }
.pr-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;
}
.pr-menu li:hover > .sub-menu,
.pr-menu li:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: none; }

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

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

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

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

.pr-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.pr-tags a { padding: 0.3em 0.75em; border-radius: 6px; background: var(--pr-soft); font-size: 0.82rem; font-weight: 600; text-decoration: none; }
.pr-tags a::before { content: "#"; color: var(--pr-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(--pr-accent); }

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

.pr-postnav { margin-top: 36px; }
.pr-postnav .nav-links { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.pr-postnav .nav-next { grid-column: 2; text-align: right; }
.pr-postnav a { display: block; height: 100%; padding: 18px 20px; text-decoration: none; }
.pr-postnav__label { display: block; margin-bottom: 4px; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--pr-muted); }
.pr-postnav__title { font-family: var(--pr-display); font-weight: 700; line-height: 1.3; }
@media (max-width: 640px) {
	.pr-postnav .nav-links { grid-template-columns: 1fr; }
	.pr-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(--pr-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 */
.pr-archive-head { margin-bottom: 32px; }
.pr-archive-head__title { margin: 10px 0 8px; font-size: clamp(2.1rem, 5vw, 3.2rem); }
.pr-archive-head__desc { color: var(--pr-muted); max-width: 60ch; }
.pr-archive-head .pr-search { margin-top: 18px; max-width: 520px; }

/* Search + comments */
.pr-search { display: flex; gap: 8px; }
.pr-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(--pr-paper);
	color: var(--pr-ink);
	border: 1px solid var(--pr-line);
	border-radius: var(--pr-input-radius, 8px);
	font: inherit;
	font-size: 1rem;
}
.pr-search__input:focus,
.comment-form input:focus,
.comment-form textarea:focus { outline: none; border-color: var(--pr-accent); box-shadow: 0 0 0 3px var(--pr-ring, rgba(0, 0, 0, 0.12)); }
.pr-search__btn {
	flex: none;
	display: grid;
	place-items: center;
	width: 50px;
	background: var(--pr-accent);
	color: var(--pr-on-accent);
	border: 0;
	border-radius: var(--pr-input-radius, 8px);
	cursor: pointer;
}

.pr-comments { margin-top: 44px; }
.pr-comments__title { font-size: 1.6rem; margin-bottom: 20px; }
.pr-comment-list,
.pr-comment-list .children { margin: 0; padding: 0; list-style: none; }
.pr-comment-list .children { margin-left: clamp(14px, 4vw, 34px); }
.comment-body { margin-bottom: 16px; padding: 18px 20px; background: var(--pr-paper); border: 1px solid var(--pr-line); border-radius: var(--pr-radius); }
.comment-author { display: flex; align-items: center; gap: 10px; font-family: var(--pr-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(--pr-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(--pr-paper); border: 1px solid var(--pr-line); border-radius: var(--pr-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 */
.pr-404,
.pr-empty { padding: clamp(28px, 5vw, 48px); text-align: center; background: var(--pr-paper); border-radius: var(--pr-radius); }
.pr-404__num { margin: 0; font-family: var(--pr-display); font-weight: 800; font-size: clamp(5rem, 18vw, 9rem); line-height: 1; color: var(--pr-accent); }
.pr-404 .pr-search,
.pr-empty .pr-search { max-width: 460px; margin: 18px auto 22px; }

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

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


/* ==========================================================================
   Prompt look
   ========================================================================== */
:root {
	color-scheme: dark;
	--pr-bg: #0a0d0b;
	--pr-paper: #0f1411;
	--pr-panel: #121a15;
	--pr-ink: #e4ffe0;
	--pr-text: #b6e8b1;
	--pr-muted: #7fa883;
	--pr-dim: #4c6b50;
	--pr-soft: #16211a;
	--pr-line: #22322a;
	--pr-green: #4af27a;
	--pr-cyan: #5ee8ff;
	--pr-pink: #ff79c6;
	--pr-accent: #ffb000;
	--pr-on-accent: #15131c;
	--pr-link: #5ee8ff;
	--pr-radius: 6px;
	--pr-btn-radius: 4px;
	--pr-input-radius: 4px;
	--pr-img-radius: 4px;
	--pr-focus: #ffb000;
	--pr-ring: rgba(255, 176, 0, 0.25);
	--pr-display: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
	--pr-body: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
	--pr-mono: "JetBrains Mono", ui-monospace, monospace;
	--pr-wrap: 1400px;
}

body {
	color: var(--pr-text);
	font-size: 0.95rem;
	line-height: 1.7;
	background-image: radial-gradient(ellipse at 50% -20%, rgba(74, 242, 122, 0.09), transparent 60%);
	background-attachment: fixed;
}
h1, h2, h3, h4, h5, h6 { color: var(--pr-ink); font-weight: 700; letter-spacing: -0.02em; }
::selection { background: var(--pr-green); color: #0a0d0b; }
a { color: var(--pr-link); }

.pr-thumb { background: var(--pr-soft); border: 1px solid var(--pr-line); }
.pr-thumb::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(transparent 0 2px, rgba(0, 0, 0, 0.18) 2px 3px); pointer-events: none; }
.pr-thumb img { filter: saturate(0.85) contrast(1.05); }
a.pr-thumb:hover img { transform: none; filter: none; }
.pr-thumb__fallback { display: flex; align-items: center; justify-content: center; gap: 0.08em; background: var(--pr-soft); color: var(--pr-green); font-weight: 700; }
.pr-thumb__fallback::before { content: "["; color: var(--pr-dim); }
.pr-thumb__fallback::after { content: "]"; color: var(--pr-dim); }

.pr-ps1 { white-space: nowrap; color: var(--pr-muted); }
.pr-ps1__user { color: var(--pr-green); font-weight: 700; }
.pr-ps1__dir { color: var(--pr-cyan); }
.pr-cmd { color: var(--pr-ink); }
.pr-cmd a { color: var(--pr-accent); text-decoration: none; }
.pr-cmd a:hover { text-decoration: underline; }

.pr-btn { font-weight: 700; }
.pr-btn:hover { background: var(--pr-green); color: #0a0d0b; transform: none; }

/* Header */
.pr-header { padding-top: 18px; }
.pr-header > .pr-wrap { border: 1px solid var(--pr-line); border-radius: 10px; background: var(--pr-paper); overflow: visible; }
.pr-titlebar { display: flex; align-items: center; gap: 14px; padding: 8px 14px; border-bottom: 1px solid var(--pr-line); background: #0c110e; border-radius: 10px 10px 0 0; font-size: 0.78rem; color: var(--pr-dim); }
.pr-dots { display: flex; gap: 7px; }
.pr-dots span { width: 11px; height: 11px; border-radius: 50%; background: #ff5f57; }
.pr-dots span:nth-child(2) { background: #febc2e; }
.pr-dots span:nth-child(3) { background: #28c840; }
.pr-titlebar__text { flex: 1; text-align: center; margin-right: 47px; }
.pr-header__inner { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 24px; padding: 18px 20px; }
.pr-brand { margin-right: auto; }
.pr-brand__title { margin: 0; font-size: clamp(1.3rem, 2.6vw, 1.75rem); font-weight: 800; line-height: 1.2; }
.pr-brand__title a { color: var(--pr-ink); text-decoration: none; }
.pr-brand__caret { margin-right: 10px; color: var(--pr-green); }
.pr-cursor { display: inline-block; width: 0.6em; height: 1.05em; margin-left: 6px; vertical-align: -0.15em; background: var(--pr-green); animation: pr-blink 1.1s steps(1) infinite; }
@keyframes pr-blink { 50% { opacity: 0; } }
.pr-brand__tagline { margin: 4px 0 0; font-size: 0.82rem; color: var(--pr-dim); }
.custom-logo { max-height: 56px; width: auto; }
.pr-header__panel { display: flex; align-items: center; gap: 18px; }
.pr-header__tools { display: flex; align-items: center; gap: 10px; }
.pr-menu { gap: 2px; }
.pr-menu a { padding: 6px 8px; color: var(--pr-text); font-size: 0.9rem; }
.pr-menu > li > a::before { content: "["; color: var(--pr-dim); margin-right: 3px; }
.pr-menu > li > a::after { content: "]"; color: var(--pr-dim); margin-left: 3px; }
.pr-menu a:hover,
.pr-menu .current-menu-item > a,
.pr-menu .current_page_item > a { color: var(--pr-accent); }
.pr-menu .sub-menu { background: var(--pr-paper); border: 1px solid var(--pr-line); border-radius: 6px; }
.pr-cta { padding: 0.55em 0.9em; font-size: 0.85rem; white-space: nowrap; }
.pr-cta::before { content: "./"; }

.pr-search { display: flex; align-items: stretch; gap: 0; border: 1px solid var(--pr-line); border-radius: 4px; background: #0a0d0b; }
.pr-search__label { display: grid; place-items: center; padding: 0 10px; color: var(--pr-pink); font-size: 0.85rem; border-right: 1px solid var(--pr-line); }
.pr-search__input { width: 150px; padding: 8px 10px; border: 0; background: transparent; color: var(--pr-ink); font: inherit; font-size: 0.88rem; }
.pr-search__input:focus { outline: none; box-shadow: none; }
.pr-search:focus-within { border-color: var(--pr-accent); }
.pr-search__btn { width: auto; padding: 0 12px; border: 0; border-left: 1px solid var(--pr-line); border-radius: 0 4px 4px 0; background: var(--pr-soft); color: var(--pr-green); font: inherit; font-size: 0.85rem; cursor: pointer; }
.pr-search__btn:hover { background: var(--pr-green); color: #0a0d0b; }

@media (max-width: 1100px) {
	.pr-nav-button { display: inline-flex; align-items: center; gap: 10px; padding: 8px 14px; border: 1px solid var(--pr-line); border-radius: 4px; color: var(--pr-green); cursor: pointer; }
	.pr-header__panel { display: none; flex-basis: 100%; flex-direction: column; align-items: stretch; }
	.pr-nav-toggle:checked ~ .pr-header__panel { display: flex; }
	.pr-menu { flex-direction: column; align-items: stretch; }
	.pr-menu .sub-menu { position: static; opacity: 1; visibility: visible; transform: none; border: 0; padding-left: 18px; }
	.pr-header__tools { flex-wrap: wrap; }
	.pr-header__tools .pr-search { flex: 1 1 260px; }
	.pr-search__input { width: 100%; }
}

/* Layout */
.pr-layout {
	display: grid;
	grid-template-columns: 240px minmax(0, 1fr) 310px;
	grid-template-areas: "tree main random";
	gap: 26px;
	align-items: start;
	padding-block: 26px 60px;
}
.pr-main { grid-area: main; min-width: 0; }
.pr-side { min-width: 0; display: flex; flex-direction: column; gap: 22px; }
.pr-side--tree { grid-area: tree; position: sticky; top: 20px; }
.pr-side--random { grid-area: random; }
@media (max-width: 1180px) {
	.pr-layout { grid-template-columns: minmax(0, 1fr) 290px; grid-template-areas: "main random" "tree random"; }
	.pr-side--tree { position: static; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
}
@media (max-width: 820px) {
	.pr-layout { grid-template-columns: minmax(0, 1fr); grid-template-areas: "main" "tree" "random"; }
}

.pr-cmdline { margin: 0 0 14px; font-size: 0.9rem; }

/* Post output blocks */
.pr-feed { display: flex; flex-direction: column; gap: 18px; }
.pr-card,
.pr-full { padding: 14px 18px 18px; background: var(--pr-paper); border: 1px solid var(--pr-line); border-radius: var(--pr-radius); transition: border-color 0.15s ease; }
.pr-card:hover,
.pr-full:hover { border-color: #2f5a3b; }
.pr-card__cmd { margin: 0 0 12px; font-size: 0.85rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pr-card__out { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 20px; padding-left: 14px; border-left: 2px solid var(--pr-line); }
.pr-card__thumb { aspect-ratio: 4 / 3; }
.pr-card__title,
.pr-full__title { margin: 2px 0 8px; font-size: 1.3rem; line-height: 1.3; }
.pr-card__title a,
.pr-full__title a { color: var(--pr-ink); }
.pr-card__title a::before,
.pr-full__title a::before { content: "## "; color: var(--pr-dim); }
.pr-card__title a:hover,
.pr-full__title a:hover { color: var(--pr-accent); }
.pr-card__excerpt { margin: 0 0 8px; color: var(--pr-text); font-size: 0.9rem; line-height: 1.65; }
.pr-comment-line { margin: 0; font-size: 0.78rem; color: var(--pr-dim); }
.pr-comment-line a { color: var(--pr-muted); text-decoration: none; }
.pr-comment-line a:hover { color: var(--pr-accent); }
.pr-full__out { padding-left: 14px; border-left: 2px solid var(--pr-line); }
.pr-full__thumb { aspect-ratio: 16 / 8; margin-bottom: 14px; }
.pr-full .pr-comment-line { margin-bottom: 16px; }
@media (max-width: 640px) {
	.pr-card__out { grid-template-columns: minmax(0, 1fr); padding-left: 10px; }
}

.pr-chips { gap: 6px; margin-bottom: 4px; }
.pr-chip { font-size: 0.75rem; color: var(--pr-pink); }
.pr-chip::before { content: "#"; }
.pr-chip:hover { color: var(--pr-accent); }
.pr-meta { color: var(--pr-dim); font-size: 0.8rem; }
.pr-meta a { color: var(--pr-muted); }

/* File-tree sidebar */
.pr-side--tree .pr-box { padding: 14px 16px; background: var(--pr-paper); border: 1px solid var(--pr-line); border-radius: var(--pr-radius); }
.pr-box__title,
.pr-box__heading { margin: 0 0 8px; font-size: 0.88rem; font-weight: 700; color: var(--pr-cyan); letter-spacing: 0; }
.pr-catlist li,
.pr-pagelist li { position: relative; padding-left: 34px; line-height: 1.9; }
.pr-catlist li::before,
.pr-pagelist li::before { content: "├──"; position: absolute; left: 0; color: var(--pr-dim); }
.pr-catlist li:last-child::before,
.pr-pagelist li:last-child::before { content: "└──"; }
.pr-cat { display: flex; justify-content: space-between; gap: 8px; color: var(--pr-text); font-size: 0.88rem; }
.pr-cat__name::after { content: "/"; color: var(--pr-dim); }
.pr-cat:hover,
.pr-cat.is-current { color: var(--pr-accent); }
.pr-count { color: var(--pr-dim); font-size: 0.78rem; }
.pr-count::before { content: "("; }
.pr-count::after { content: ")"; }
.pr-pagelist a { display: block; color: var(--pr-text); font-size: 0.88rem; text-transform: lowercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pr-pagelist a::after { content: ".md"; color: var(--pr-dim); }
.pr-pagelist a:hover,
.pr-pagelist .current_page_item > a { color: var(--pr-accent); }
.widget.pr-box > :not(.pr-box__title) { margin: 6px 0; }

/* Random posts */
.pr-box--random { padding: 14px 16px; background: var(--pr-paper); border: 1px solid var(--pr-line); border-radius: var(--pr-radius); }
.pr-box--random .pr-box__title { display: flex; flex-direction: column; gap: 2px; margin-bottom: 14px; padding-bottom: 10px; border-bottom: 1px dashed var(--pr-line); }
.pr-box--random .pr-box__heading { margin: 0; color: var(--pr-green); }
.pr-box__hint { font-size: 0.75rem; color: var(--pr-dim); }
.pr-box__hint::before { content: "# "; }
.pr-rand { padding-bottom: 16px; margin-bottom: 16px; border-bottom: 1px dashed var(--pr-line); }
.pr-rand:last-child { border-bottom: 0; margin-bottom: 0; padding-bottom: 0; }
.pr-rand__thumb { aspect-ratio: 16 / 9; margin-bottom: 10px; }
.pr-rand__num { position: absolute; top: 6px; left: 6px; z-index: 1; padding: 0 6px; background: #0a0d0b; color: var(--pr-accent); font-size: 0.72rem; border: 1px solid var(--pr-line); }
.pr-rand__title { font-size: 0.98rem; line-height: 1.35; }
.pr-rand__title a { color: var(--pr-ink); }
.pr-rand__title a:hover { color: var(--pr-accent); }
.pr-rand__text { font-size: 0.8rem; line-height: 1.6; color: var(--pr-muted); }
.pr-rand__more { color: var(--pr-green); font-size: 0.8rem; text-decoration: none; }
.pr-rand__more::before { content: "→ "; }
.pr-rand__more span[aria-hidden] { display: none; }
.pr-rand__more:hover { color: var(--pr-accent); }
.pr-side--random .widget.pr-box { padding: 14px 16px; background: var(--pr-paper); border: 1px solid var(--pr-line); border-radius: var(--pr-radius); }
@media (max-width: 820px) {
	.pr-randlist { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 0 20px; }
	.pr-rand:last-child { border-bottom: 1px dashed var(--pr-line); margin-bottom: 16px; padding-bottom: 16px; }
}

/* Single + page */
.pr-single { padding: 18px 22px 24px; background: var(--pr-paper); border: 1px solid var(--pr-line); border-radius: var(--pr-radius); }
.pr-single::before { content: "$ cat ./" attr(id) ".md"; display: block; margin-bottom: 14px; color: var(--pr-muted); font-size: 0.82rem; }
.pr-single__title { margin: 4px 0 12px; font-size: clamp(1.7rem, 3.6vw, 2.4rem); line-height: 1.2; }
.pr-single__title::before { content: "# "; color: var(--pr-dim); }
.pr-single__thumb { margin-bottom: 22px; }
.pr-single__thumb img { border: 1px solid var(--pr-line); }
.pr-entry { color: var(--pr-text); font-size: 0.98rem; line-height: 1.8; }
.pr-entry h2::before { content: "## "; color: var(--pr-dim); }
.pr-entry h3::before { content: "### "; color: var(--pr-dim); }
.pr-entry h2,
.pr-entry h3 { font-size: 1.25rem; }
.pr-entry a { color: var(--pr-cyan); text-decoration-color: var(--pr-cyan); text-decoration-thickness: 1px; }
.pr-entry a:hover { color: var(--pr-accent); }
.pr-entry blockquote,
.pr-entry .wp-block-quote { padding: 4px 0 4px 18px; border-left: 3px solid var(--pr-accent); color: var(--pr-ink); }
.pr-entry li::marker { content: "- "; color: var(--pr-green); }
.pr-entry ol li::marker { content: counter(list-item) ". "; }
.pr-entry pre { background: #050706; border: 1px solid var(--pr-line); }
.pr-entry code { background: var(--pr-soft); color: var(--pr-pink); }
.pr-author { background: var(--pr-soft); border: 1px solid var(--pr-line); border-radius: var(--pr-radius); }
.pr-author__name a { color: var(--pr-ink); }
.pr-author__site { color: var(--pr-cyan); }
.pr-postnav a { background: var(--pr-paper); border: 1px solid var(--pr-line); border-radius: var(--pr-radius); }
.pr-postnav a:hover { border-color: var(--pr-accent); }
.pr-postnav__title { color: var(--pr-ink); }
.pr-tags a { background: var(--pr-soft); color: var(--pr-pink); }
.pr-tags a::before { color: var(--pr-dim); }

.page-numbers { border: 1px solid var(--pr-line); border-radius: 4px; color: var(--pr-text); font-family: var(--pr-body); }
a.page-numbers:hover { border-color: var(--pr-accent); color: var(--pr-accent); }
.page-numbers.current { background: var(--pr-green); border-color: var(--pr-green); color: #0a0d0b; }

.pr-kicker { color: var(--pr-pink); font-size: 0.85rem; }
.pr-kicker::before { content: "$ cd "; color: var(--pr-muted); }
.pr-archive-head__title { font-size: clamp(1.8rem, 4vw, 2.6rem); }
.pr-archive-head__title::before { content: "~/"; color: var(--pr-dim); }
.pr-404,
.pr-empty { background: var(--pr-paper); border: 1px solid var(--pr-line); text-align: left; }
.pr-404__num { font-size: clamp(3rem, 10vw, 6rem); color: var(--pr-pink); }
.pr-404__num::before { content: "ERR "; color: var(--pr-dim); font-size: 0.4em; vertical-align: middle; }
.pr-404 .pr-search,
.pr-empty .pr-search { margin-inline: 0; }
.comment-body,
.comment-respond { background: var(--pr-paper); border-color: var(--pr-line); }
.comment-author { color: var(--pr-ink); }
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea { background: #0a0d0b; border-color: var(--pr-line); color: var(--pr-ink); }

/* Footer */
.pr-footer { padding-block: 26px 30px; border-top: 1px solid var(--pr-line); font-size: 0.85rem; }
.pr-footer a { text-decoration: none; }
.pr-footer__widgets { border-bottom: 1px dashed var(--pr-line); }
.pr-footer-widget__title { font-size: 0.9rem; color: var(--pr-cyan); }
.pr-footer__line { margin: 0 0 12px; }
.pr-footer__cmd { color: var(--pr-ink); }
.pr-footer__cmd::after { content: ""; display: inline-block; width: 0.6em; height: 1.05em; margin-left: 4px; vertical-align: -0.15em; background: var(--pr-green); animation: pr-blink 1.1s steps(1) infinite; }
.pr-footer__menu { display: flex; flex-wrap: wrap; gap: 4px 18px; margin: 0; padding: 0; list-style: none; }
.pr-footer__menu a { color: var(--pr-text); }
.pr-footer__menu a::before { content: "./"; color: var(--pr-dim); }
.pr-footer__menu a:hover,
.pr-footer__bottom a:hover { color: var(--pr-accent); }
.pr-footer__bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; margin-top: 16px; color: var(--pr-dim); }
.pr-footer__bottom p { margin: 0; }
.pr-footer__bottom a { color: var(--pr-muted); }
