:root {
	color-scheme: dark;
	--background: #171512;
	--panel: #211e19;
	--text: #f3ebdc;
	--muted: #c7b8a4;
	--accent: #e9a34b;
	--border: #5b4c39;
	font: 100%/1.6 system-ui, sans-serif;
}

* {
	box-sizing: border-box;
}

body {
	margin: 0;
	min-height: 100vh;
	background: radial-gradient(ellipse at 50% 0%, #272016, transparent 36rem), var(--background);
	color: var(--text);
}

.shell {
	width: min(100% - 2.5rem, 72rem);
	margin-inline: auto;
	padding-block: 1.5rem 4rem;
}

a {
	color: var(--accent);
	text-underline-offset: 0.2em;
}

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

a:focus-visible {
	outline: 2px solid var(--text);
	outline-offset: 4px;
}

.back {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	gap: 0.45rem;
	color: var(--muted);
}

header {
	margin-block: 2rem 2.25rem;
}

h1,
h2 {
	margin: 0;
	font-family: Georgia, serif;
	font-weight: 500;
	line-height: 1.05;
}

h1 {
	font-size: clamp(3.25rem, 9vw, 6rem);
	letter-spacing: -0.055em;
}

h2 {
	font-size: 2.15rem;
	letter-spacing: -0.035em;
}

p {
	margin: 0.8rem 0 0;
	color: var(--muted);
}

.games {
	--card-gap: 1.25rem;
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: var(--card-gap);
}

.game {
	min-width: 0;
	display: flex;
	flex-direction: column;
	border: 1px solid var(--border);
	border-radius: 0.65rem;
	background: var(--panel);
	overflow: hidden;
}

.game-art {
	position: relative;
	aspect-ratio: 2 / 1;
	max-height: 15rem;
	border-bottom: 1px solid var(--border);
	background: var(--background);
}

.game-scene {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.game-tile {
	position: absolute;
	inset: 0.65rem 0.65rem auto auto;
	width: 42px;
	height: 42px;
	padding: 4px;
	border: 1px solid var(--border);
	border-radius: 0.35rem;
	background: #171512ed;
	image-rendering: pixelated;
}

.game-details {
	flex: 1;
	display: flex;
	flex-direction: column;
	padding: clamp(1rem, 3vw, 1.65rem);
}

.game-details p {
	margin-bottom: 1.35rem;
}

.game-actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.25rem 1rem;
	margin-top: auto;
}

.play,
.wiki {
	display: inline-flex;
	align-items: center;
	gap: 0.55rem;
	min-height: 44px;
}

.play {
	padding-inline: 1rem;
	border-radius: 0.35rem;
	background: var(--accent);
	color: var(--background);
	font-weight: 700;
	text-decoration: none;
}

.play:hover {
	background: var(--text);
	color: var(--background);
}

.art-credit {
	font-size: 0.8125rem;
	text-align: right;
}

.art-credit a {
	color: inherit;
}

@media (min-width: 62rem) {
	.games {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

@media (42rem < width < 62rem) {
	.game:last-child:nth-child(odd) {
		grid-column: 1 / -1;
		justify-self: center;
		width: calc((100% - var(--card-gap)) / 2);
	}
}

@media (max-width: 42rem) {
	.games {
		grid-template-columns: 1fr;
	}
}
