/* nixholm.com
   The one stylesheet. See DESIGN.md; every value here comes from it.
   No inline <style> blocks, no style attributes. */

/* ---------- fonts ---------- */

@font-face {
	font-family: "Cinzel Decorative";
	src: url("/assets/fonts/cinzel-decorative-400.woff2") format("woff2");
	font-weight: 400;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: "Cinzel Decorative";
	src: url("/assets/fonts/cinzel-decorative-700.woff2") format("woff2");
	font-weight: 700;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: "Cinzel Decorative";
	src: url("/assets/fonts/cinzel-decorative-900.woff2") format("woff2");
	font-weight: 900;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: "Cormorant Garamond";
	src: url("/assets/fonts/cormorant-garamond-var.woff2") format("woff2");
	font-weight: 300 700;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: "Cormorant Garamond";
	src: url("/assets/fonts/cormorant-garamond-italic-var.woff2") format("woff2");
	font-weight: 300 700;
	font-style: italic;
	font-display: swap;
}

/* ---------- tokens ---------- */

:root {
	/* materials: the physical stuff. never text. */
	--hull: #01080c;
	--deep: #131b22;
	--brass: #a06c30;
	--vellum: #c59b68;
	--blood: #540c09;

	/* inks: what text is set in. */
	--gold: #d9b15c;
	--chalk: #ede2c6;
	--dim: #b9a784;

	--s1: 0.25rem;
	--s2: 0.5rem;
	--s3: 0.75rem;
	--s4: 1rem;
	--s5: 1.5rem;
	--s6: 2rem;
	--s7: 3rem;
	--s8: 4rem;
	--s9: 6rem;

	--r-sm: 2px;
	--r-md: 6px;

	--display: "Cinzel Decorative", Georgia, serif;
	--body: "Cormorant Garamond", Georgia, serif;

	--gutter: var(--s5);
	--column: 68rem;
	--measure: 36rem;

	--ease: cubic-bezier(0.16, 1, 0.3, 1);

	/* Grain. Inline SVG turbulence, so the design system loads no images at
	   all. Never visible as a pattern: if you can see it, it is too strong. */
	--grain: url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='160'%20height='160'%3E%3Cfilter%20id='g'%3E%3CfeTurbulence%20type='fractalNoise'%20baseFrequency='0.8'%20numOctaves='4'%20stitchTiles='stitch'/%3E%3CfeColorMatrix%20type='saturate'%20values='0'/%3E%3C/filter%3E%3Crect%20width='160'%20height='160'%20filter='url%28%23g%29'/%3E%3C/svg%3E");
}

@media (min-width: 40rem) {
	:root {
		--gutter: var(--s7);
	}
}

/* ---------- reset ---------- */

*,
*::before,
*::after {
	box-sizing: border-box;
}

body,
h1,
h2,
h3,
p,
ul,
ol,
li,
figure,
blockquote {
	margin: 0;
	padding: 0;
}

ul,
ol {
	list-style: none;
}

img,
svg {
	display: block;
	max-width: 100%;
}

img {
	height: auto;
}

/* ---------- base ---------- */

html {
	-webkit-text-size-adjust: 100%;
	scrollbar-color: var(--brass) var(--hull);
	accent-color: var(--gold);
	scroll-behavior: smooth;
	/* The nav is sticky, so anchored sections must clear it. */
	scroll-padding-top: 4.5rem;
}

::selection {
	background: var(--gold);
	color: var(--hull);
}

body {
	background: var(--hull);
	color: var(--chalk);
	font-family: var(--body);
	font-size: 1.25rem;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
	display: flex;
	flex-direction: column;
	min-height: 100vh;
	min-height: 100svh;
}

body > :last-child {
	flex: 1 0 auto;
}

h1,
h2,
h3 {
	font-family: var(--display);
	font-weight: 700;
	text-transform: uppercase;
	color: var(--gold);
	text-wrap: balance;
}

h1 {
	font-size: clamp(1.75rem, 6vw, 2.75rem);
	line-height: 1.15;
	letter-spacing: 0.06em;
}

h2 {
	font-size: clamp(1.375rem, 5vw, 1.875rem);
	line-height: 1.2;
	letter-spacing: 0.08em;
	text-indent: 0.08em;
}

h3 {
	font-size: 1.0625rem;
	line-height: 1.3;
	letter-spacing: 0.1em;
	text-indent: 0.1em;
}

p {
	max-width: var(--measure);
}

p + p {
	margin-top: var(--s4);
}

a {
	color: var(--gold);
	text-decoration-thickness: 1px;
	text-underline-offset: 0.2em;
}

:focus-visible {
	outline: 2px solid var(--gold);
	outline-offset: 3px;
}

em,
.film {
	font-style: italic;
}

/* ---------- type roles ---------- */

.title {
	font-family: var(--display);
	font-size: clamp(2rem, 9vw, 6rem);
	font-weight: 900;
	line-height: 1;
	letter-spacing: 0.01em;
	text-transform: uppercase;
	color: var(--gold);
}

/* "of the" sits between the two words, the way it does on the flyer. */
.title span {
	display: block;
	font-size: 0.3em;
	font-weight: 400;
	letter-spacing: 0.32em;
	text-indent: 0.32em;
	color: var(--vellum);
	padding-block: 0.5em 0.35em;
}

.lead {
	font-size: 1.4375rem;
	line-height: 1.5;
}

.note {
	font-size: 1.0625rem;
	line-height: 1.5;
	letter-spacing: 0.01em;
	color: var(--dim);
}

.dim {
	color: var(--dim);
}

/* ---------- layout ---------- */

.wrap {
	width: 100%;
	max-width: var(--column);
	margin-inline: auto;
	padding-inline: var(--gutter);
}

.band {
	position: relative;
	isolation: isolate;
	padding-block: var(--s9);
	overflow: hidden;
}

/* Grain sits behind content so it cannot tint it. */
.band::before,
.hero::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background-image: var(--grain);
	background-size: 160px 160px;
	opacity: 0.05;
	pointer-events: none;
}

.ground-hull {
	background: var(--hull);
}

.ground-deep {
	background: var(--deep);
}

/* Plank seams. Structure, not light, so this one is not a soft ramp. */
.ground-wood {
	background:
		repeating-linear-gradient(
			to bottom,
			transparent 0 38px,
			color-mix(in srgb, var(--hull) 55%, transparent) 38px 40px
		),
		var(--deep);
}

.center {
	text-align: center;
}

.center p {
	margin-inline: auto;
}

.stack > * + * {
	margin-top: var(--s4);
}

.stack-loose > * + * {
	margin-top: var(--s6);
}

/* ---------- nav ---------- */

.nav {
	position: sticky;
	top: 0;
	z-index: 10;
	background: var(--hull);
	border-bottom: 1px solid var(--brass);
}

.nav-inner {
	display: flex;
	align-items: center;
	gap: var(--s5);
	min-height: 3.5rem;
}

.nav-mark {
	flex: none;
	display: flex;
	color: var(--brass);
}

.nav-mark svg {
	width: 28px;
	height: 28px;
}

/* Phones only. The row below takes over from 40rem up. */
.nav-toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	margin-left: auto;
	width: 2.75rem;
	height: 2.75rem;
	margin-right: calc(var(--s2) * -1);
	padding: 0;
	background: none;
	border: 0;
	border-radius: var(--r-sm);
	color: var(--gold);
	cursor: pointer;
}

.nav-toggle svg {
	width: 24px;
	height: 24px;
}

.nav-toggle .icon-close,
.nav[data-open="true"] .nav-toggle .icon-open {
	display: none;
}

.nav[data-open="true"] .nav-toggle .icon-close {
	display: block;
}

.nav-links {
	display: flex;
	gap: var(--s6);
	margin-left: auto;
}

.nav-links a {
	display: block;
	font-size: 0.9375rem;
	font-weight: 600;
	line-height: 1;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	white-space: nowrap;
	color: var(--chalk);
	text-decoration: none;
	border-bottom: 1px solid transparent;
	transition: color 200ms ease-out;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
	color: var(--gold);
	border-bottom-color: var(--gold);
}

@media (min-width: 40rem) {
	.nav-toggle {
		display: none;
	}

	.nav-links a {
		padding-block: var(--s3);
	}
}

/* The panel. Drops below the bar, full width, one link per row. */
@media (max-width: 39.999rem) {
	.nav-links {
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		flex-direction: column;
		gap: 0;
		margin-left: 0;
		padding: 0 var(--gutter) var(--s4);
		background: var(--hull);
		border-bottom: 1px solid var(--brass);
		opacity: 0;
		visibility: hidden;
		transform: translateY(-0.5rem);
		transition:
			opacity 200ms ease-out,
			transform 200ms ease-out,
			visibility 200ms;
	}

	.nav[data-open="true"] .nav-links {
		opacity: 1;
		visibility: visible;
		transform: none;
	}

	.nav-links a {
		padding-block: var(--s4);
		border-bottom: 1px solid
			color-mix(in srgb, var(--brass) 45%, transparent);
	}

	.nav-links a:last-child {
		border-bottom-color: transparent;
	}

	.nav-links a:hover,
	.nav-links a[aria-current="page"] {
		border-bottom-color: color-mix(in srgb, var(--brass) 45%, transparent);
	}
}

/* ---------- hero ---------- */

.hero {
	position: relative;
	isolation: isolate;
	overflow: hidden;
	background: var(--hull);
	padding-block: var(--s9) var(--s8);
	text-align: center;
}

/* The sea, built out of light. Every stop is a token or a token at alpha.
   The horizon sits at 62%. Nothing here animates. */
.hero::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -2;
	pointer-events: none;
	background:
		/* vignette, so the corners fall away */
		radial-gradient(
			130% 85% at 50% 50%,
			transparent 36%,
			color-mix(in srgb, var(--hull) 92%, transparent) 100%
		),
		/* the sun going down, just above the waterline */
		radial-gradient(
			76% 17% at 50% 76%,
			color-mix(in srgb, var(--gold) 30%, transparent),
			color-mix(in srgb, var(--brass) 14%, transparent) 48%,
			transparent 76%
		),
		/* its reflection running toward the viewer */
		radial-gradient(
			14% 22% at 50% 90%,
			color-mix(in srgb, var(--gold) 16%, transparent),
			transparent 70%
		),
		/* banded water, below the horizon only */
		repeating-linear-gradient(
			to bottom,
			color-mix(in srgb, var(--chalk) 5%, transparent) 0 1px,
			transparent 1px 8px
		) 0 76% / 100% 24% no-repeat,
		/* sky into sea */
		linear-gradient(
			to bottom,
			var(--hull) 0%,
			color-mix(in srgb, var(--hull) 78%, var(--deep)) 30%,
			var(--deep) 60%,
			color-mix(in srgb, var(--brass) 24%, var(--deep)) 75%,
			color-mix(in srgb, var(--deep) 82%, var(--hull)) 82%,
			var(--hull) 97%
		);
}

/* Every p here inherits the global 36rem measure. Without an auto margin it
   sits at the left of the wrap, and text-align: center then centres the
   content inside that box rather than on the page. */
.hero p {
	margin-inline: auto;
}

.hero-kicker {
	font-family: var(--body);
	font-size: 1.0625rem;
	font-style: italic;
	letter-spacing: 0.02em;
	color: var(--vellum);
}

.hero .title {
	margin-top: var(--s3);
}

@supports (background-clip: text) or (-webkit-background-clip: text) {
	.hero .title {
		background-image: linear-gradient(
			176deg,
			color-mix(in srgb, var(--chalk) 62%, var(--gold)) 0%,
			var(--gold) 26%,
			var(--brass) 45%,
			color-mix(in srgb, var(--chalk) 52%, var(--gold)) 54%,
			var(--gold) 73%,
			var(--brass) 100%
		);
		-webkit-background-clip: text;
		background-clip: text;
		color: transparent;
		/* The bevel. A real offset, never a halo. */
		filter:
			drop-shadow(0 1px 0 color-mix(in srgb, var(--hull) 60%, transparent))
			drop-shadow(0 10px 20px color-mix(in srgb, var(--hull) 80%, transparent));
	}

	.hero .title span {
		-webkit-text-fill-color: var(--vellum);
	}
}

.dateline {
	margin: var(--s6) auto 0;
	font-family: var(--display);
	font-size: clamp(0.9375rem, 3.2vw, 1.125rem);
	font-weight: 700;
	letter-spacing: 0.16em;
	text-indent: 0.16em;
	text-transform: uppercase;
	color: var(--chalk);
	max-width: none;
}

.hero-cta {
	margin-top: var(--s6);
}

/* The one authored moment. */
@media (prefers-reduced-motion: no-preference) {
	.hero-kicker,
	.hero .title,
	.dateline,
	.hero-cta {
		animation: rise 600ms var(--ease) backwards;
	}

	.hero .title {
		animation-delay: 80ms;
	}

	.dateline {
		animation-delay: 200ms;
	}

	.hero-cta {
		animation-delay: 280ms;
	}
}

@keyframes rise {
	from {
		opacity: 0;
		transform: translateY(1.25rem);
	}
}

/* ---------- ornament ---------- */

.divider {
	display: block;
	width: min(18rem, 70%);
	height: 14px;
	margin: var(--s5) auto 0;
	color: var(--brass);
}

.head {
	text-align: center;
	margin-bottom: var(--s8);
}

.head p {
	margin: var(--s5) auto 0;
}

.rule-double {
	border: 0;
	border-top: 1px solid var(--brass);
	border-bottom: 1px solid var(--brass);
	height: 3px;
	margin-block: var(--s6);
}

/* ---------- buttons ---------- */

/* A parchment plaque. Vellum ground, hull text: 13.9 contrast. */
.button {
	display: inline-flex;
	align-items: center;
	gap: var(--s3);
	font-family: var(--display);
	font-size: 0.9375rem;
	font-weight: 700;
	line-height: 1;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	padding: var(--s4) var(--s6);
	background: var(--vellum);
	color: var(--hull);
	border: 1px solid var(--brass);
	border-radius: var(--r-sm);
	text-decoration: none;
	cursor: pointer;
	box-shadow: 0 6px 18px rgba(1, 8, 12, 0.55);
	transition: transform 200ms ease-out, box-shadow 200ms ease-out;
}

.button:hover {
	transform: translateY(-2px);
	box-shadow: 0 10px 24px rgba(1, 8, 12, 0.65);
}

.button:active {
	transform: translateY(0);
}

.button svg {
	width: 16px;
	height: 16px;
	flex: none;
}

.button-quiet {
	background: transparent;
	color: var(--gold);
	box-shadow: none;
}

.button-quiet:hover {
	box-shadow: none;
}

/* ---------- the manifest ---------- */

/* Four parallel facts about the night. Genuinely parallel, so a grid earns it. */
.manifest {
	display: grid;
	gap: var(--s7);
	text-align: center;
}

@media (min-width: 34rem) {
	.manifest {
		grid-template-columns: repeat(2, 1fr);
		gap: var(--s8) var(--s6);
	}

	/* Two lines reserved, so every paragraph starts on the same line. */
	.manifest h3 {
		min-height: 2.6em;
	}
}

@media (min-width: 56rem) {
	.manifest {
		grid-template-columns: repeat(4, 1fr);
	}

	.manifest li + li {
		border-left: 1px solid var(--brass);
		padding-left: var(--s6);
	}
}

.manifest li {
	display: flex;
	flex-direction: column;
}

.manifest svg {
	width: 40px;
	height: 40px;
	margin: 0 auto var(--s4);
	color: var(--brass);
}

.manifest h3 {
	color: var(--chalk);
}

.manifest li > p {
	margin-top: var(--s3);
}

.manifest p {
	margin-top: var(--s3);
	font-size: 1.0625rem;
	line-height: 1.5;
	color: var(--dim);
	max-width: 18rem;
	margin-inline: auto;
}

/* ---------- the bar ---------- */

.bar-copy {
	text-align: center;
}

.bar-copy p {
	margin-inline: auto;
}

.bar-copy .button {
	margin-top: var(--s6);
}

/* ---------- activities ---------- */

.crew {
	display: grid;
	gap: var(--s5);
}

@media (min-width: 44rem) {
	.crew {
		grid-template-columns: repeat(3, 1fr);
	}
}

/* Parchment card. Reserved for things to act on or remember. */
.card {
	display: flex;
	flex-direction: column;
	position: relative;
	isolation: isolate;
	padding: var(--s6) var(--s5);
	background:
		radial-gradient(
			78% 62% at 22% 12%,
			color-mix(in srgb, var(--chalk) 42%, transparent),
			transparent 70%
		),
		radial-gradient(
			72% 66% at 82% 88%,
			color-mix(in srgb, var(--blood) 20%, transparent),
			transparent 66%
		),
		var(--vellum);
	color: var(--hull);
	border: 1px solid var(--brass);
	border-radius: var(--r-sm);
	text-align: center;
	box-shadow: 0 10px 28px rgba(1, 8, 12, 0.6);
}

.card::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background-image: var(--grain);
	background-size: 160px 160px;
	mix-blend-mode: multiply;
	opacity: 0.1;
	pointer-events: none;
}

.card svg {
	width: 34px;
	height: 34px;
	margin: 0 auto var(--s4);
	color: var(--blood);
}

.card h3 {
	color: var(--hull);
}

.card p {
	margin-top: var(--s3);
	font-size: 1.0625rem;
	line-height: 1.5;
	max-width: none;
}

.ticket {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: var(--s2);
	margin-top: auto;
	padding-top: var(--s5);
	font-size: 0.9375rem;
	font-style: italic;
	color: var(--blood);
}

.ticket svg {
	width: 18px;
	height: 18px;
	margin: 0;
	flex: none;
}

/* ---------- the raffle ---------- */

.raffle {
	margin-top: var(--s7);
	padding: var(--s7) var(--s6);
	background:
		radial-gradient(
			78% 62% at 22% 12%,
			color-mix(in srgb, var(--chalk) 42%, transparent),
			transparent 70%
		),
		radial-gradient(
			72% 66% at 82% 88%,
			color-mix(in srgb, var(--blood) 20%, transparent),
			transparent 66%
		),
		var(--vellum);
	color: var(--hull);
	border: 1px solid var(--brass);
	border-radius: var(--r-sm);
	text-align: center;
	position: relative;
	isolation: isolate;
	box-shadow: 0 14px 40px rgba(1, 8, 12, 0.7);
}

.raffle::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background-image: var(--grain);
	background-size: 160px 160px;
	mix-blend-mode: multiply;
	opacity: 0.1;
	pointer-events: none;
}

.raffle h2 {
	color: var(--hull);
}

.raffle .divider {
	color: var(--blood);
}

.raffle p {
	margin: var(--s5) auto 0;
	max-width: 30rem;
}

/* The one place --blood is a ground. */
.stamp {
	display: inline-flex;
	align-items: center;
	gap: var(--s3);
	margin-top: var(--s6);
	padding: var(--s3) var(--s5);
	background: var(--blood);
	color: var(--chalk);
	border-radius: var(--r-sm);
	font-size: 0.9375rem;
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	text-align: left;
}

.stamp svg {
	width: 20px;
	height: 20px;
	flex: none;
	color: var(--vellum);
}

/* ---------- the film ---------- */

.film-band {
	text-align: center;
}

.film-band svg.reel {
	width: 44px;
	height: 44px;
	margin: 0 auto var(--s5);
	color: var(--brass);
}

.film-title {
	font-family: var(--display);
	font-size: clamp(1.5rem, 5.5vw, 2.5rem);
	font-weight: 700;
	line-height: 1.15;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--gold);
}

.film-sub {
	margin: var(--s4) auto 0;
	font-size: 1.25rem;
	font-style: italic;
	color: var(--vellum);
	max-width: none;
}

/* ---------- previous years ---------- */

.years {
	margin-top: var(--s5);
	max-width: var(--measure);
	margin-inline: auto;
}

.years a {
	display: flex;
	flex-wrap: wrap;
	gap: var(--s2) var(--s5);
	align-items: baseline;
	justify-content: center;
	padding-block: var(--s4);
	border-top: 1px solid var(--brass);
	font-variant-numeric: tabular-nums;
	text-decoration: none;
}

.years li:last-child a {
	border-bottom: 1px solid var(--brass);
}

.years-title {
	color: var(--chalk);
}

.years a:hover .years-title {
	text-decoration: underline;
	text-underline-offset: 0.2em;
}

/* ---------- the doors, root landing ---------- */

.doors {
	margin-top: var(--s8);
	max-width: var(--measure);
}

.doors a {
	display: block;
	padding-block: var(--s5);
	border-top: 1px solid var(--brass);
	text-decoration: none;
	transition: transform 200ms ease-out;
}

.doors li:last-child a {
	border-bottom: 1px solid var(--brass);
}

.doors a:hover {
	transform: translateX(var(--s2));
}

.door-name {
	display: block;
	font-family: var(--display);
	font-size: 1.25rem;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	line-height: 1.3;
	color: var(--gold);
}

.door-note {
	display: block;
	margin-top: var(--s2);
	color: var(--dim);
}

/* ---------- the menu page ---------- */

/* Read standing up, in the dark, one handed, off a QR code. Single column,
   centered, generous. It should read as something printed. */
.menu-page {
	width: 100%;
	max-width: 38rem;
	margin-inline: auto;
	padding: var(--s8) var(--gutter) var(--s7);
	text-align: center;
}

.menu-head {
	padding-bottom: var(--s6);
	border-bottom: 1px solid var(--brass);
}

.menu-head svg {
	width: 40px;
	height: 40px;
	margin: 0 auto var(--s5);
	color: var(--brass);
}

.menu-sub {
	margin: var(--s4) auto 0;
	font-size: 1.0625rem;
	font-style: italic;
	color: var(--vellum);
	max-width: none;
}

.course {
	padding-top: var(--s8);
}

.course-title {
	color: var(--gold);
}

.course-list {
	margin-top: var(--s6);
}

.item + .item {
	margin-top: var(--s6);
}

.item-name {
	max-width: none;
	font-family: var(--display);
	font-size: 1.375rem;
	font-weight: 700;
	line-height: 1.25;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--chalk);
}

/* The pour. Set apart so the eye can skim ingredients alone. */
.item-build {
	max-width: none;
	margin-top: var(--s2);
	font-size: 1.125rem;
	font-style: italic;
	color: var(--gold);
}

.item-note {
	max-width: 26rem;
	margin: var(--s2) auto 0;
	font-size: 1.0625rem;
	line-height: 1.5;
	color: var(--dim);
}

.menu-foot {
	margin-top: var(--s8);
	padding-top: var(--s6);
	border-top: 1px solid var(--brass);
}

.empty {
	margin-top: var(--s7);
	padding: var(--s6);
	border: 1px solid var(--brass);
	border-radius: var(--r-sm);
	color: var(--dim);
}

/* ---------- footer ---------- */

.foot {
	padding-block: var(--s7);
	border-top: 1px solid var(--brass);
	text-align: center;
	color: var(--dim);
	font-size: 1.0625rem;
}

/* ---------- motion ---------- */

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}

	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
	}
}
