:root {
	--ink: #0b0a08;
	--ink-2: #141210;
	--bone: #f2ede4;
	--bone-dim: #c9c2b4;
	--red: #d64545;
	--violet: #6e56cf;
	--teal: #2fa88c;
	--amber: #d6844a;
	--line: rgba(242, 237, 228, 0.14);
	--card-w: min(480px, 82vw);
}

* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

html {
	background: var(--ink);
	scroll-behavior: smooth;
}

body {
	background: var(--ink);
	color: var(--bone);
	font-family: 'Space Grotesk', sans-serif;
	overflow-x: hidden;
	cursor: default;
}

::selection {
	background: var(--red);
	color: var(--bone);
}

a {
	color: inherit;
}

.mono {
	font-family: 'JetBrains Mono', monospace;
	letter-spacing: 0.03em;
}

/* focus visibility */
a:focus-visible,
button:focus-visible {
	outline: 2px solid var(--red);
	outline-offset: 4px;
}

/* ---------- SMOKE CANVAS ---------- */
#smoke {
	position: fixed;
	inset: 0;
	width: 100vw;
	height: 100vh;
	z-index: 3;
	pointer-events: none;
	mix-blend-mode: screen;
	opacity: 1;
}

/* film grain overlay */
.grain {
	position: fixed;
	inset: 0;
	z-index: 60;
	pointer-events: none;
	opacity: 0.05;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* vignette to keep edges dark & focus centered */
.vignette {
	position: fixed;
	inset: 0;
	z-index: 4;
	pointer-events: none;
	background: radial-gradient(ellipse at center, transparent 35%, rgba(11, 10, 8, 0.55) 100%);
}

/* ---------- NAV ---------- */
header {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 50;
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 28px clamp(20px, 5vw, 56px);
	mix-blend-mode: difference;
}

.logo {
	font-family: 'Fraunces', serif;
	font-weight: 600;
	font-size: 22px;
	letter-spacing: 0.02em;
}

nav ul {
	display: flex;
	gap: clamp(16px, 3vw, 36px);
	list-style: none;
	font-size: 13px;
}

nav a {
	text-decoration: none;
	position: relative;
	padding-bottom: 2px;
}
nav a::after {
	content: '';
	position: absolute;
	left: 0;
	right: 0;
	bottom: -2px;
	height: 1px;
	background: currentColor;
	transform: scaleX(0);
	transform-origin: right;
	transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}
nav a:hover::after,
nav a:focus-visible::after {
	transform: scaleX(1);
	transform-origin: left;
}

/* ---------- HERO ---------- */
.hero {
	position: relative;
	min-height: 100svh;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	text-align: center;
	z-index: 5;
	padding: 0 24px;
}

.hero .eyebrow {
	font-size: 12px;
	color: var(--red);
	text-transform: uppercase;
	letter-spacing: 0.28em;
	margin-bottom: 22px;
	opacity: 0;
	animation: rise 0.9s 0.3s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.hero h1 {
	font-family: 'Fraunces', serif;
	font-weight: 900;
	font-size: clamp(3.2rem, 12vw, 9rem);
	line-height: 0.92;
	letter-spacing: -0.02em;
	opacity: 0;
	animation: rise 1.1s 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.hero h1 em {
	font-style: italic;
	font-weight: 400;
	color: var(--bone-dim);
}

.hero .sub {
	margin-top: 26px;
	max-width: 520px;
	font-size: clamp(15px, 2vw, 18px);
	line-height: 1.6;
	color: var(--bone-dim);
	opacity: 0;
	animation: rise 0.9s 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.hero .scroll-hint {
	position: absolute;
	bottom: 10px;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
	font-size: 11px;
	color: var(--bone-dim);
	opacity: 0;
	animation: rise 0.9s 1.2s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}
.scroll-hint .line {
	width: 1px;
	height: 36px;
	background: linear-gradient(var(--bone-dim), transparent);
	animation: pulse-line 2s ease-in-out infinite;
}

@keyframes rise {
	from {
		opacity: 0;
		transform: translateY(28px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}
@keyframes pulse-line {
	0%,
	100% {
		opacity: 0.3;
	}
	50% {
		opacity: 1;
	}
}

/* ---------- CLOTHESLINE SECTION ---------- */
.darkroom {
	position: relative;
	z-index: 5;
	padding: 6vh 0 24vh;
}

.darkroom-intro {
	max-width: 640px;
	margin: 0 auto 14vh;
	padding: 0 24px;
	text-align: center;
}
.darkroom-intro .tag {
	font-size: 11px;
	color: var(--red);
	text-transform: uppercase;
	letter-spacing: 0.28em;
	display: block;
	margin-bottom: 16px;
}
.darkroom-intro h2 {
	font-family: 'Fraunces', serif;
	font-weight: 500;
	font-size: clamp(1.8rem, 4vw, 2.6rem);
	line-height: 1.2;
}

/* the "line" the cards hang from - decorative diagonal wire */
.wire {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: 1;
	pointer-events: none;
}
.wire svg {
	width: 100%;
	height: 100%;
}
.wire path {
	stroke: rgba(242, 237, 228, 0.32);
	stroke-width: 1.2;
	fill: none;
	stroke-dasharray: 3 7;
}

.card-track {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 16vh;
}

.card-row {
	display: flex;
	width: 100%;
	position: relative;
}
/* alternate alignment to create the diagonal, top-right -> bottom-left feel */
.card-row:nth-child(odd) {
	justify-content: flex-end;
	padding-right: clamp(6vw, 12vw, 18vw);
}
.card-row:nth-child(even) {
	justify-content: flex-start;
	padding-left: clamp(6vw, 12vw, 18vw);
}

.peg {
	position: absolute;
	top: -14px;
	width: 14px;
	height: 14px;
	z-index: 3;
}
.peg::before,
.peg::after {
	content: '';
	position: absolute;
	background: var(--red);
}
.peg::before {
	width: 14px;
	height: 5px;
	border-radius: 3px;
	top: 0;
	left: 0;
}
.peg::after {
	width: 2px;
	height: 11px;
	left: 6px;
	top: 3px;
	background: var(--ink-2);
}
.card-row:nth-child(odd) .peg {
	right: clamp(6vw, 12vw, 18vw);
	margin-right: 24px;
}
.card-row:nth-child(even) .peg {
	left: clamp(6vw, 12vw, 18vw);
	margin-left: 24px;
}

.card {
	width: var(--card-w);
	background: linear-gradient(160deg, rgba(242, 237, 228, 0.05), rgba(242, 237, 228, 0.02));
	border: 1px solid var(--line);
	backdrop-filter: blur(18px) saturate(140%);
	-webkit-backdrop-filter: blur(18px) saturate(140%);
	border-radius: 2px;
	padding: clamp(28px, 4vw, 44px);
	box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.6);
	will-change: transform, opacity;
	transform-origin: top center;
	position: relative;
}

.card::before {
	content: '';
	position: absolute;
	top: -14px;
	left: 50%;
	width: 1px;
	height: 14px;
	background: rgba(242, 237, 228, 0.3);
}

.card .frame-label {
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-size: 11px;
	color: var(--bone-dim);
	margin-bottom: 20px;
	padding-bottom: 14px;
	border-bottom: 1px solid var(--line);
}

.card .frame-label .dot {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: var(--red);
	display: inline-block;
	margin-right: 8px;
}

.card h3 {
	font-family: 'Fraunces', serif;
	font-weight: 600;
	font-size: clamp(1.5rem, 3vw, 2rem);
	margin-bottom: 14px;
	line-height: 1.15;
}

.card p {
	font-size: 15px;
	line-height: 1.7;
	color: var(--bone-dim);
	margin-bottom: 18px;
}

.card .meta {
	display: flex;
	flex-wrap: wrap;
	gap: 10px 18px;
	font-size: 11px;
	color: var(--bone-dim);
	margin-top: 20px;
	padding-top: 16px;
	border-top: 1px solid var(--line);
}
.card .meta span b {
	color: var(--bone);
	font-weight: 400;
}

.card .stack {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 16px;
}
.card .stack span {
	font-size: 11px;
	padding: 5px 10px;
	border: 1px solid var(--line);
	border-radius: 20px;
	color: var(--bone-dim);
}

.card .cta {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin-top: 22px;
	font-size: 13px;
	text-decoration: none;
	color: var(--bone);
	border-bottom: 1px solid var(--red);
	padding-bottom: 2px;
}
.card .cta svg {
	width: 12px;
	height: 12px;
	transition: transform 0.3s;
}
.card .cta:hover svg {
	transform: translate(3px, -3px);
}

/* about card variant */
.card.about {
	background: linear-gradient(160deg, rgba(214, 132, 74, 0.08), rgba(110, 86, 207, 0.05));
}

/* ---------- FOOTER / CONTACT ---------- */
.contact {
	position: relative;
	z-index: 5;
	min-height: 80vh;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	text-align: center;
	padding: 10vh 24px;
}

.contact .tag {
	font-size: 11px;
	color: var(--red);
	text-transform: uppercase;
	letter-spacing: 0.28em;
	margin-bottom: 20px;
}

.contact h2 {
	font-family: 'Fraunces', serif;
	font-weight: 500;
	font-size: clamp(2.2rem, 7vw, 5rem);
	line-height: 1.05;
	max-width: 900px;
}

.contact .email {
	margin-top: 40px;
	font-family: 'Fraunces', serif;
	font-style: italic;
	font-size: clamp(1.3rem, 3vw, 1.8rem);
	text-decoration: none;
	border-bottom: 1px solid var(--line);
	padding-bottom: 6px;
	transition:
		border-color 0.3s,
		color 0.3s;
}
.contact .email:hover {
	border-color: var(--red);
	color: var(--red);
}

footer {
	position: relative;
	z-index: 5;
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 28px clamp(20px, 5vw, 56px) 40px;
	font-size: 11px;
	color: var(--bone-dim);
}
footer .socials {
	display: flex;
	gap: 20px;
	list-style: none;
}
footer .socials a {
	text-decoration: none;
}
footer .socials a:hover {
	color: var(--red);
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 780px) {
	:root {
		--card-w: min(420px, 86vw);
	}
	.card-row:nth-child(odd) {
		padding-right: 7vw;
	}
	.card-row:nth-child(even) {
		padding-left: 7vw;
	}
	.card-row:nth-child(odd) .peg {
		right: 7vw;
		margin-right: 18px;
	}
	.card-row:nth-child(even) .peg {
		left: 7vw;
		margin-left: 18px;
	}
	nav ul {
		gap: 14px;
	}
	nav a {
		font-size: 11px;
	}
}

@media (max-width: 560px) {
	nav ul li:not(:last-child) {
		display: none;
	}
	.card-track {
		gap: 12vh;
	}
	.darkroom {
		padding-bottom: 16vh;
	}
}

/* ---------- REDUCED MOTION ---------- */
@media (prefers-reduced-motion: reduce) {
	* {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
	}
	.card {
		transform: none !important;
	}
}
