:root {
	--bg: #070907;
	--code-bg: #050605;
	--fg: #d7f5cf;
	--muted: #849889;
	--surface: #0d120f;
	--surface-alt: #111a14;
	--accent: #74f59b;
	--accent-strong: #ffbd5b;
	--rule: #263c2d;
	--rule-hot: #4fb86d;
	--shadow: 0 0 0 1px rgb(116 245 155 / 18%), 0 20px 48px rgb(0 0 0 / 55%);
	--terminal-font:
		'Cascadia Mono', 'JetBrains Mono', 'SFMono-Regular', Consolas, 'Liberation Mono', monospace;
	color-scheme: dark;
}

* {
	box-sizing: border-box;
}

html {
	background:
		repeating-linear-gradient(
			0deg,
			rgb(255 255 255 / 3%) 0,
			rgb(255 255 255 / 3%) 1px,
			transparent 1px,
			transparent 4px
		),
		linear-gradient(90deg, rgb(116 245 155 / 5%), transparent 22rem), var(--bg);
	overflow-y: scroll;
}

body {
	color: var(--fg);
	font-family: var(--terminal-font);
	font-size: 1rem;
	line-height: 1.65;
	margin: 0;
	min-height: 100vh;
	text-rendering: geometricprecision;
}

body::before {
	background: repeating-linear-gradient(
		90deg,
		rgb(255 255 255 / 2%) 0,
		rgb(255 255 255 / 2%) 1px,
		transparent 1px,
		transparent 9px
	);
	content: '';
	inset: 0;
	mix-blend-mode: screen;
	opacity: 0.28;
	pointer-events: none;
	position: fixed;
	z-index: 10;
}

a {
	color: var(--accent-strong);
	text-decoration-color: rgb(255 189 91 / 62%);
	text-underline-offset: 0.18em;
}

a:hover {
	color: var(--accent);
	text-decoration-color: currentColor;
}

a:focus-visible {
	outline: 2px solid var(--accent-strong);
	outline-offset: 0.25rem;
}

.site-shell {
	margin: 0 auto;
	max-width: 80rem;
	padding: 1.5rem 2rem 3rem;
	position: relative;
	width: 100%;
}

.site-shell::before {
	color: rgb(116 245 155 / 58%);
	content: 'BOOT: BEAZLEY.ORG // STATIC LOG ARCHIVE';
	display: block;
	font-size: 0.75rem;
	margin-bottom: 0.65rem;
}

.site-header {
	align-items: center;
	background: rgb(5 6 5 / 78%);
	border: 1px solid var(--rule);
	box-shadow: inset 0 -1px 0 rgb(116 245 155 / 16%);
	display: flex;
	gap: 1.5rem;
	justify-content: space-between;
	margin-bottom: 1.75rem;
	padding: 0.85rem 1rem;
}

.site-name {
	color: var(--fg);
	font-size: 1rem;
	font-weight: 800;
	text-decoration: none;
}

.site-name::before {
	color: var(--accent);
	content: '> ';
}

.site-header nav a,
.section-heading a {
	color: var(--accent);
	font-size: 0.86rem;
	font-weight: 750;
	text-decoration: none;
	text-transform: uppercase;
}

h1,
h2,
h3 {
	font-weight: 850;
	line-height: 1.2;
	margin: 0;
	overflow-wrap: break-word;
}

p {
	overflow-wrap: break-word;
}

.home-hero {
	align-items: stretch;
	display: grid;
	gap: 1.25rem;
	grid-template-columns: minmax(0, 0.95fr) minmax(20rem, 1.05fr);
	padding: 1.25rem 0 0;
}

.hero-copy {
	background: rgb(13 18 15 / 84%);
	border: 1px solid var(--rule);
	box-shadow: var(--shadow);
	display: flex;
	flex-direction: column;
	justify-content: center;
	max-width: none;
	min-width: 0;
	padding: 1.5rem;
}

.eyebrow {
	color: var(--accent);
	font-size: 0.78rem;
	font-weight: 800;
	margin: 0 0 0.9rem;
	text-transform: uppercase;
}

.eyebrow::before {
	content: './';
}

.home-hero h1 {
	color: var(--fg);
	font-size: 3.6rem;
	line-height: 1;
	text-shadow: 0 0 18px rgb(116 245 155 / 24%);
}

.home-hero h1::after {
	animation: cursor-blink 1.2s steps(1, end) infinite;
	color: var(--accent-strong);
	content: '_';
}

.home-hero p:last-child {
	color: var(--muted);
	font-size: 1.08rem;
	line-height: 1.72;
	margin: 1.25rem 0 0;
	max-width: 42rem;
}

.hero-visual {
	aspect-ratio: 16 / 10;
	background: var(--surface-alt);
	border: 1px solid var(--rule-hot);
	box-shadow: var(--shadow);
	overflow: hidden;
	position: relative;
}

.hero-visual::before {
	background:
		linear-gradient(90deg, rgb(116 245 155 / 18%), transparent 45%),
		repeating-linear-gradient(
			0deg,
			rgb(0 0 0 / 18%) 0,
			rgb(0 0 0 / 18%) 2px,
			transparent 2px,
			transparent 5px
		);
	content: '';
	inset: 0;
	pointer-events: none;
	position: absolute;
	z-index: 1;
}

.hero-visual img {
	display: block;
	filter: grayscale(0.75) contrast(1.18) brightness(0.72) saturate(0.75);
	height: 100%;
	object-fit: cover;
	width: 100%;
}

/* Tab navigation */
.tab-nav {
	border-bottom: 1px solid var(--rule);
	display: flex;
	gap: 0;
	margin-bottom: 0;
	margin-top: 1.25rem;
}

.tab-link {
	border: 1px solid transparent;
	border-bottom: none;
	color: var(--muted);
	font-size: 0.86rem;
	font-weight: 750;
	padding: 0.55rem 1.1rem;
	text-decoration: none;
	text-transform: uppercase;
	transition: color 120ms ease;
}

.tab-link:hover {
	color: var(--fg);
}

/* Default state: posts visible, projects hidden */
.tab-panel {
	display: none;
}

#posts {
	display: block;
}

/* When #projects is targeted, show projects and hide posts */
body:has(#projects:target) #posts {
	display: none;
}

body:has(#projects:target) #projects {
	display: block;
}

/* Active tab highlight */
body:not(:has(#projects:target)) .tab-nav #tab-posts {
	background: rgb(116 245 155 / 5%);
	border-color: var(--rule);
	color: var(--accent);
}

body:has(#projects:target) .tab-nav #tab-projects {
	background: rgb(116 245 155 / 5%);
	border-color: var(--rule);
	color: var(--accent);
}

.entries-section {
	border-top: 1px solid var(--rule);
	padding-top: 1.5rem;
}

.section-heading {
	align-items: baseline;
	border-bottom: 1px dashed var(--rule);
	display: flex;
	gap: 1rem;
	justify-content: space-between;
	margin-bottom: 1rem;
	padding-bottom: 0.65rem;
}

.section-heading h2 {
	color: var(--fg);
	font-size: 0.95rem;
	text-transform: uppercase;
}

.section-heading h2::before {
	color: var(--accent);
	content: '$ ';
}

.entry-list {
	display: grid;
	gap: 1rem;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr));
	list-style: none;
	margin: 0;
	padding: 0;
}

.entry-list li {
	min-width: 0;
}

.entry-card {
	background: linear-gradient(180deg, rgb(116 245 155 / 6%), transparent 4rem), var(--surface);
	border: 1px solid var(--rule);
	box-shadow: inset 0 1px 0 rgb(255 255 255 / 4%);
	display: flex;
	flex-direction: column;
	height: 100%;
	min-height: 14rem;
	min-width: 0;
	padding: 1rem;
	transition:
		background-color 160ms ease,
		border-color 160ms ease,
		box-shadow 160ms ease,
		transform 160ms ease;
}

.entry-card:hover {
	background-color: #101a13;
	border-color: var(--rule-hot);
	box-shadow: var(--shadow);
	transform: translateY(-2px);
}

.entry-list h2 {
	font-size: 1.08rem;
	margin: 0.45rem 0 0.75rem;
}

.entry-list h2 a {
	color: var(--fg);
	text-decoration: none;
}

.entry-list p {
	color: var(--muted);
	font-size: 0.92rem;
	margin: 0.25rem 0 0;
}

.series-tag {
	color: var(--accent);
	display: inline-block;
	font-size: 0.78rem;
	font-weight: 500;
	margin-left: 0.35rem;
}

.project-card {
	justify-content: space-between;
}

.project-card-header {
	align-items: baseline;
	display: flex;
	gap: 0.75rem;
	justify-content: space-between;
}

.project-repo-link {
	color: var(--muted);
	font-size: 0.75rem;
	font-weight: 500;
	margin-left: 0.4rem;
	text-decoration: none;
	text-transform: lowercase;
}

.project-repo-link:hover {
	color: var(--fg);
}

.project-stars {
	color: var(--accent-strong);
	font-size: 0.8rem;
	white-space: nowrap;
}

.project-tags {
	display: flex;
	flex-wrap: wrap;
	gap: 0.35rem;
	list-style: none;
	margin: 0.85rem 0 0;
	padding: 0;
}

.project-tags li {
	background: rgb(116 245 155 / 8%);
	border: 1px solid var(--rule);
	color: var(--muted);
	font-size: 0.75rem;
	padding: 0.15em 0.5em;
}

.series-summary {
	border: 1px solid var(--rule);
	margin-bottom: 2rem;
	padding: 1rem 1.25rem;
}

.series-summary-label {
	color: var(--muted);
	font-size: 0.78rem;
	font-weight: 800;
	margin: 0 0 0.5rem;
	text-transform: uppercase;
}

.series-summary-list {
	margin: 0;
	padding-left: 1.25rem;
}

.series-summary-list li {
	font-size: 0.88rem;
	line-height: 1.55;
	padding: 0.1rem 0;
}

.series-summary-current span {
	color: var(--accent);
	font-weight: 600;
}

.post-nav {
	border-top: 1px solid var(--rule);
	display: flex;
	gap: 1rem;
	justify-content: space-between;
	margin-top: 3rem;
	padding-top: 1.25rem;
}

.post-nav a {
	color: var(--muted);
	font-size: 0.85rem;
	text-decoration: none;
}

.post-nav a:hover {
	color: var(--fg);
}

.post-nav-next {
	margin-left: auto;
	text-align: right;
}

.series-note,
time {
	color: var(--accent);
	font-size: 0.8rem;
	font-weight: 800;
}

.entry-page .site-main,
.site-main > article {
	margin: 0 auto;
	max-width: 62rem;
}

.entry-page article,
.site-main > article {
	background: rgb(13 18 15 / 78%);
	border: 1px solid var(--rule);
	box-shadow: var(--shadow);
	font-size: 0.98rem;
	line-height: 1.78;
	padding: 1.75rem;
}

article > h1:first-child {
	color: var(--fg);
	font-size: 2.25rem;
	line-height: 1.12;
	margin-bottom: 1.25rem;
	text-shadow: 0 0 14px rgb(116 245 155 / 18%);
}

article > h1:first-child::before {
	color: var(--accent);
	content: '# ';
}

article h2 {
	border-top: 1px dashed var(--rule);
	color: var(--accent-strong);
	font-size: 1.25rem;
	margin: 2.4rem 0 0.75rem;
	padding-top: 1rem;
}

article h3 {
	color: var(--accent);
	font-size: 1.08rem;
	margin: 2rem 0 0.5rem;
}

article p {
	margin: 1rem 0;
}

article ul,
article ol {
	margin: 1.1rem 0;
	padding-left: 1.35rem;
}

article li + li {
	margin-top: 0.4rem;
}

blockquote {
	background: rgb(255 189 91 / 5%);
	border-left: 3px solid var(--accent-strong);
	color: var(--muted);
	font-style: normal;
	margin: 1.25rem 0;
	padding: 0.75rem 1rem;
}

code {
	background: var(--code-bg);
	border: 1px solid var(--rule);
	color: var(--accent);
	font-family: var(--terminal-font);
	font-size: 0.9em;
	padding: 0.08em 0.3em;
}

pre {
	background: var(--code-bg);
	border: 1px solid var(--rule);
	box-shadow: inset 0 0 24px rgb(116 245 155 / 7%);
	overflow-x: auto;
	padding: 0.9rem 1rem;
}

pre code {
	background: none;
	border: 0;
	padding: 0;
}

table {
	border-collapse: collapse;
	display: block;
	font-size: 0.9rem;
	overflow-x: auto;
	width: 100%;
}

th,
td {
	border: 1px solid var(--rule);
	padding: 0.4rem 0.65rem;
	text-align: left;
}

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

.entry-image {
	background: #050605;
	border: 1px solid var(--rule);
	box-shadow: inset 0 0 28px rgb(116 245 155 / 8%);
	margin: 1.25rem 0;
	padding: 0.5rem;
}

.entry-image img {
	display: block;
	filter: grayscale(0.8) contrast(1.12) brightness(0.78);
	width: 100%;
}

.entry-image figcaption {
	color: var(--muted);
	font-size: 0.78rem;
	margin-top: 0.45rem;
}

.alignright {
	float: right;
	margin: 0.35rem 0 1rem 1.25rem;
	max-width: min(21rem, 46%);
}

hr {
	border: 0;
	border-top: 1px solid var(--rule);
	margin: 2.25rem 0;
}

.site-footer {
	border-top: 1px solid var(--rule);
	color: var(--muted);
	font-size: 0.82rem;
	margin-top: 2.5rem;
	padding-top: 0.75rem;
}

.site-footer p {
	margin: 0;
}

@keyframes cursor-blink {
	0%,
	49% {
		opacity: 1;
	}

	50%,
	100% {
		opacity: 0;
	}
}

@media (prefers-reduced-motion: reduce) {
	.home-hero h1::after {
		animation: none;
	}

	.entry-card {
		transition: none;
	}
}

@media (max-width: 760px) {
	body::before {
		opacity: 0.2;
	}

	.site-shell {
		padding: 1rem 0.85rem 2.25rem;
	}

	.site-shell::before {
		font-size: 0.68rem;
	}

	.site-header {
		margin-bottom: 1rem;
		padding: 0.75rem;
	}

	.home-hero {
		gap: 1rem;
		grid-template-columns: 1fr;
		padding: 0.75rem 0 2rem;
	}

	.hero-copy {
		padding: 1rem;
	}

	.home-hero h1 {
		font-size: 2.35rem;
	}

	.home-hero p:last-child {
		font-size: 0.95rem;
	}

	.hero-visual {
		aspect-ratio: 4 / 3;
	}

	.entry-card {
		min-height: 0;
	}

	.entry-page article,
	.site-main > article {
		padding: 1rem;
	}

	article > h1:first-child {
		font-size: 1.65rem;
	}

	.alignright {
		float: none;
		margin: 1.25rem 0;
		max-width: 100%;
	}
}
