@import url('https://fonts.googleapis.com/css2?family=Lora:ital,wght@0,400;0,500;0,600;1,400;1,500&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
	/* Scales gently with viewport so the wide column keeps a readable line length */
	--font-size-primary: clamp(1rem, 0.85rem + 0.35vw, 1.2rem);
	--font-size-secondary: 0.75rem; /* 12px */

	--paper: #faf9f6;
	--ink: #1e1d1b;

	--foreground: rgba(30, 29, 27, 0.84);

	--rule-color: rgba(30, 29, 27, 0.22);
	--border-color: var(--rule-color);
	--border-shorthand: 0.063rem solid var(--border-color);

	--accent: #9c4a3c;

	--font-serif: 'Lora', Georgia, 'Times New Roman', serif;
	--font-mono: 'JetBrains Mono', 'SFMono-Regular', Menlo, Consolas, monospace;

	--content-width: 70vw;

	/* Button */
	--button-hover-foreground: var(--paper);
	--button-hover-backround: var(--ink);
	--font-size-button: 0.75rem; /* 12px */

	--seven: 0.438rem; /* 7px */
	--twelve: 0.75rem; /* 12px */
}

*, *::before, *::after {
	color: var(--foreground);
	box-sizing: border-box;
}

html {
	background: var(--paper);
}

body {
	min-height: 100vh;
	margin: 0;
	font-family: var(--font-serif);
	font-size: var(--font-size-primary);
	line-height: 1.7;
	background: var(--paper);
	-webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
	font-family: var(--font-serif);
	font-weight: 600;
	line-height: 1.3;
	color: var(--ink);
}

main h2, main h3, main h4 {
	margin-block-start: 1.6em;
	margin-block-end: 0.6em;
}

li::marker {
	color: var(--accent);
}

img {
	display: block;
	height: auto;
	max-width: 100%;
	border-radius: 0.25rem;
}

.container__ {
	width: var(--content-width);
	margin-inline: auto;
	padding: 0 calc(var(--twelve) * 2);
}

/* Header */

header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	border-block-end: var(--border-shorthand);
	margin-block-end: 3rem;
	padding-block: 1.5rem;
}

.__header-title {
	margin: 0;
	font-size: 1.4rem;
}

.__header-title a {
	font-style: italic;
	font-weight: 600;
}

header a {
	padding-block-end: 0.125rem;
	text-decoration: none;
}

.__header-nav ul {
	display: flex;
	gap: 1.6rem;
	margin: 0;
	padding: 0;
	list-style-type: none;
	font-family: var(--font-mono);
	font-size: var(--font-size-secondary);
	text-transform: uppercase;
	letter-spacing: 0.08em;
}

.current-page__ {
	border-block-end: 0.0625rem solid var(--accent);
	color: var(--accent);
}

/* Footer */

footer {
	background: transparent;
	border-block-start: var(--border-shorthand);
	padding: 1.5rem calc(var(--twelve) * 2);
	margin-block-start: 4rem;
	text-align: center;

	font-family: var(--font-mono);
	font-size: var(--font-size-secondary);
	letter-spacing: 0.06em;

	position: sticky;
	inset-block-start: 100%;
}

.__footer-copyright {
	color: inherit;
}

/* Notice / Link */

#notice {
	margin-top: 2rem;
	padding: 0 var(--seven);
	font-family: var(--font-mono);
	font-size: var(--font-size-secondary);
	color: rgba(30, 29, 27, 0.5);
	text-align: center;
	line-height: 1.4;
	word-wrap: break-word;
}

/* Media Query */

@media (hover: hover) {
	.__header-nav ul li a:hover {
		border-block-end: 0.0625rem solid var(--accent);
	}
}

@media (max-width: 48rem) {
	:root {
		--content-width: 100%;
	}
}

@media (max-width: 30rem) {
	header {
		flex-direction: column;
	}

	.__header-title {
		margin-block-end: 0.67rem;
	}

	.__header-nav {
		margin-block-end: 1.5rem;
	}

	.__header-nav ul {
		gap: 2.25rem;
	}
}
