:root {
	--ink: #000;
	--paper: #fafafa;
	--yellow: #fedb8a;
	--orange: #fea878;
	--cyan: #bff6fd;
	--green: #98e784;
	--purple: #c3a0fe;
	--border: 3px solid var(--ink);
	--radius: 0.5rem;
	--font: 'Sometype Mono', monospace;
	--gap: 2rem;
	--line: 3rem;
}

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

html {
	font-size: 16pt;
	-webkit-text-size-adjust: none;
	text-size-adjust: none;
}

body {
	margin: 0;
	min-width: 320px;
	background: var(--paper);
	color: var(--ink);
	font-family: var(--font);
	font-weight: 500;
	line-height: 1;
	overflow-x: hidden;
}

/* Fixed diagonal-cross background pattern. */
body::before {
	content: '';
	position: fixed;
	inset: 0 0 auto;
	height: 100vh;
	height: 100lvh;
	z-index: -1;
	pointer-events: none;
	background: url('/images/bg-cross.svg') center / 553px repeat;
}

main {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	width: 35rem;
	max-width: 100%;
	min-height: 100vh;
	min-height: 100svh;
	margin: 0 auto;
	padding: 3rem;
	text-align: center;
	transition: opacity 0.75s ease-in-out;
}

ul {
	margin: 0;
	padding: 0;
	list-style: none;
}

a {
	color: inherit;
	text-decoration: none;
}

svg {
	display: block;
	fill: currentColor;
	pointer-events: none;
}

.avatar {
	display: block;
	width: 7.5rem;
	height: auto;
	border: var(--border);
	border-radius: var(--radius);
}

.line {
	flex-shrink: 0;
	width: 3px;
	height: var(--line);
	background: var(--ink);
}

.tagline {
	width: 100%;
	padding: 2rem;
	background: var(--purple) url('/images/bg-grid.svg') center / 553px repeat;
	border: var(--border);
	border-radius: var(--radius);
}

.tagline h1 {
	margin: 0;
	font: inherit;
	font-size: 1em;
	line-height: 1.5;
}

.links {
	display: flex;
	flex-direction: column;
	gap: var(--gap);
	width: 100%;
}

.links a {
	display: flex;
	align-items: center;
	gap: 0.5em;
	height: 3rem;
	padding: 0 1.375rem 0 1.5rem;
	background: var(--yellow);
	border: var(--border);
	border-radius: var(--radius);
	text-align: left;
	white-space: nowrap;
	transition: transform 0.25s ease, background-color 0.25s ease;
}

.links span {
	flex: 1;
	overflow: hidden;
}

.links svg {
	flex-shrink: 0;
	width: 1.05em;
	height: 1.05em;
}

.socials {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: var(--gap);
	font-size: 1.5em;
}

.socials a {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 2em;
	height: 2em;
	background: var(--yellow);
	border: var(--border);
	border-radius: var(--radius);
	transition: transform 0.125s ease, background-color 0.125s ease;
}

.socials svg {
	width: 50%;
	height: 50%;
}

.cyan {
	background-color: var(--cyan) !important;
}

.green {
	background-color: var(--green) !important;
}

.links a:hover,
.socials a:hover {
	background-color: var(--orange) !important;
}

.links a:hover {
	transform: scale(1.025);
}

.socials a:hover {
	transform: scale(1.095);
}

/* Entrance animations: main.js adds .is-visible once each element scrolls into view. */
.js.loading main,
.js [data-reveal]:not(.is-visible) {
	opacity: 0;
}

.is-visible[data-reveal='fade'] {
	animation: fade 0.75s ease;
}

.is-visible[data-reveal='wipe'] {
	mask-repeat: no-repeat;
	mask-position: 0% 100%;
	animation: wipe 1s ease;
}

.is-visible[data-reveal='wipe-reverse'] {
	mask-repeat: no-repeat;
	mask-position: 100% 100%;
	animation: wipe-reverse 0.75s ease;
}

.is-visible[data-reveal='flip'] > * {
	animation: flip 0.75s ease both;
}

.is-visible[data-reveal='flip'] > :nth-child(2) {
	animation-delay: 0.125s;
}

@keyframes fade {
	from { opacity: 0; }
}

@keyframes wipe {
	from { mask-image: linear-gradient(45deg, #000 50%, transparent 50%); mask-size: 0% 0%; }
	to { mask-image: linear-gradient(45deg, #000 50%, transparent 50%); mask-size: 220% 220%; }
}

@keyframes wipe-reverse {
	from { mask-image: linear-gradient(135deg, transparent 50%, #000 50%); mask-size: 0% 0%; }
	to { mask-image: linear-gradient(135deg, transparent 50%, #000 50%); mask-size: 220% 220%; }
}

@keyframes flip {
	from { opacity: 0; transform: perspective(1000px) rotateY(-50deg); }
}

@media (prefers-reduced-motion: reduce) {
	.js [data-reveal]:not(.is-visible) {
		opacity: 1;
	}

	main {
		transition: none;
	}

	[data-reveal],
	[data-reveal] > * {
		animation: none !important;
	}
}

@media (max-width: 1680px) {
	html {
		font-size: 12pt;
	}
}

@media (max-width: 980px) {
	html {
		font-size: 10pt;
	}
}

@media (max-width: 736px) {
	html {
		font-size: 14pt;
	}

	:root {
		--gap: 1.25rem;
		--line: 2rem;
	}

	main {
		padding: 3rem 2rem;
	}

	.avatar {
		width: 6rem;
	}

	.tagline {
		padding: 2rem 1.5rem;
	}
}

@media (max-width: 360px) {
	:root {
		--gap: 0.9375rem;
	}

	main {
		padding: 2.25rem 1.5rem;
	}

	.tagline {
		padding: 1.5rem 1.125rem;
	}
}
