/* ==========================================================================
   header.css — ultra-minimal horizontal.
   Solid bg, 1px border-bottom, text wordmark, text nav.
   No glass, no blur, no gradients.
   ========================================================================== */

.header {
	background: var(--c-bg);
	height: var(--header-h);
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 100;
	border-bottom: 1px solid var(--c-border);
	display: flex;
	align-items: center;
}

.header__inner {
	max-width: var(--max-w);
	margin: 0 auto;
	padding: 0 var(--s-24);
	width: 100%;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.header__brand {
	font-family: var(--f-heading);
	font-weight: 500;
	font-size: 1.25rem;
	color: var(--c-text);
	text-decoration: none;
	line-height: 1;
	letter-spacing: -0.005em;
}

.header__brand:hover,
.header__brand:focus-visible {
	color: var(--c-accent);
	text-decoration: none;
}

/* --- Desktop nav --- */
.header__nav {
	display: flex;
	gap: var(--s-24);
	list-style: none;
	margin: 0;
	padding: 0;
	align-items: center;
}

.header__nav-link {
	font-family: var(--f-body);
	font-weight: 400;
	font-size: 0.875rem;
	color: var(--c-text);
	text-decoration: none;
	padding: var(--s-8) 0;
	transition: color var(--dur) var(--ease);
	display: inline-block;
	line-height: 1;
}

.header__nav-link:hover,
.header__nav-link:focus-visible {
	color: var(--c-accent);
	text-decoration: none;
}

.header__nav-link.is-active {
	color: var(--c-accent);
	text-decoration: underline;
	text-underline-offset: 4px;
	text-decoration-thickness: 1px;
}

/* --- Hamburger (mobile) --- */
.header__hamburger {
	display: none;
	background: none;
	border: none;
	padding: var(--s-8);
	cursor: pointer;
	width: 40px;
	height: 40px;
	position: relative;
	color: var(--c-text);
}

.header__hamburger span {
	display: block;
	width: 22px;
	height: 1px;
	background: var(--c-text);
	margin: 5px auto;
	transition: transform var(--dur) var(--ease), opacity var(--dur) var(--ease);
}

.header__hamburger[aria-expanded="true"] span:nth-child(1) {
	transform: translateY(6px) rotate(45deg);
}
.header__hamburger[aria-expanded="true"] span:nth-child(2) {
	opacity: 0;
}
.header__hamburger[aria-expanded="true"] span:nth-child(3) {
	transform: translateY(-6px) rotate(-45deg);
}

/* --- Mobile overlay --- */
.header__mobile {
	position: fixed;
	top: var(--header-h);
	left: 0;
	right: 0;
	bottom: 0;
	background: var(--c-bg);
	z-index: 99;
	padding: var(--s-32) var(--s-24) var(--s-48);
	overflow-y: auto;
	/* JS controls open/close via [aria-hidden] — avoid display rules here */
}

.header__mobile[aria-hidden="true"] {
	visibility: hidden;
	pointer-events: none;
	opacity: 0;
}

.header__mobile[aria-hidden="false"] {
	visibility: visible;
	pointer-events: auto;
	opacity: 1;
	transition: opacity var(--dur) var(--ease);
}

.header__mobile-nav {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: var(--s-8);
}

.header__mobile-nav a {
	display: block;
	padding: var(--s-16) 0;
	border-bottom: 1px solid var(--c-border);
	font-family: var(--f-heading);
	font-weight: 500;
	font-size: 1.25rem;
	color: var(--c-text);
	text-decoration: none;
}

.header__mobile-nav a:hover,
.header__mobile-nav a.is-active {
	color: var(--c-accent);
}

.header__mobile-utility {
	list-style: none;
	padding: 0;
	margin: var(--s-32) 0 0;
	display: flex;
	flex-direction: column;
	gap: var(--s-12);
}

.header__mobile-utility a {
	font-family: var(--f-body);
	font-weight: 400;
	font-size: 0.875rem;
	color: var(--c-text-dim);
	text-decoration: none;
}

.header__mobile-utility a:hover {
	color: var(--c-accent);
}

/* --- Responsive --- */
@media (max-width: 900px) {
	.header__nav {
		display: none;
	}
	.header__hamburger {
		display: inline-block;
	}
}

@media (min-width: 901px) {
	.header__mobile {
		display: none;
	}
}

/* Body scroll-lock when mobile menu open (JS adds .mw-no-scroll) */
body.mw-no-scroll {
	overflow: hidden;
}
