* {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
	touch-action: manipulation;
}

button {
	border: none;
}

::selection {
	background-color: var(--gray);
	mix-blend-mode: exclusion;
	color: var(--black);
}

html {
	scroll-behavior: smooth;
}

body {
	background-color: var(--white);
	font-family: "DM Sans", sans-serif;
	font-size: clamp(1rem, 2vw, 2.5rem);
	font-weight: 300;
	font-style: normal;
	color: var(--black);

	--black: #00000d;
	--white: #e8e0da;
	--gray: color-mix(in oklch, var(--white) 50%, var(--black));
	--accent: #e7717b;

	--accent-1: oklch(from var(--accent) calc(l + 0.15) c h);
	--accent-2: oklch(from var(--accent) calc(l + 0.30) c h);
	--accent-3: oklch(from var(--accent) calc(l + 0.45) c h);
	--accent-4: oklch(from var(--accent) calc(l + 0.55) c h);

	--danger: #ff425d;

	padding: 10vw;
	padding-top: 5vw;
	padding-bottom: 5vw;
	line-height: 1.3;
}

html,
body {
	-ms-overflow-style: none;
	scrollbar-width: none;

	&::-webkit-scrollbar {
		display: none;
	}
}

.separator {
	width: 100%;
	height: 2px;
	background: var(--black);
}

@keyframes fade {
	from {
		opacity: 0;
	}

	to {
		opacity: 1;
	}
}

.dark-background {
	animation: fade 1s;
	border-top-right-radius: 20px;
	border-top-left-radius: 20px;
	padding: 10vw;
	padding-top: 5vw;
	margin-top: 2.5vw;
	padding-bottom: 5vw;
	left: 0;
	position: absolute;
	width: 100%;
	background: var(--black);
	color: var(--white);

	& .separator {
		background: var(--white);
	}
}

.text-container {
	overflow: hidden;
	width: fit-content;
	height: fit-content;
	vertical-align: bottom;
	--delay: 0s;
	--x: 0;
	--y: 1;
	animation: reveal-overflow 0.8s var(--delay) forwards;
	animation-play-state: paused;

	&>* {
		transform: translate(calc(var(--x) * 100%), calc(var(--y) * 100%));
		animation: reveal 0.8s cubic-bezier(0.77, 0, 0.175, 1) var(--delay) forwards;
		animation-play-state: paused;
	}

	&.in-view {
		animation-play-state: running;

		&>* {
			animation-play-state: running;
		}
	}
}

@keyframes reveal {
	to {
		transform: translate(0, 0);
	}
}

@keyframes reveal-overflow {

	0%,
	99% {
		overflow: hidden;
	}

	100% {
		overflow: visible;
	}
}

strong {
	font-weight: 500;
}

footer {
	font-weight: 500;
	font-size: 0.6em;
	color: var(--gray);
}

h3 {
	margin-bottom: 0.5rem;
}

a:visited,
a {
	color: var(--white);
}

a:not(.button-area) {
	font-weight: 500;
	text-decoration-thickness: 2px;
	text-decoration-color: var(--accent);
	transition: background 0.15s, color 0.2s;

	&:active {
		background: var(--accent);
		color: var(--black);
	}

	@media (hover: hover) {
		&:hover {
			background: var(--accent);
			color: var(--black);
		}
	}
}

a.button-area {
	text-decoration: none;
}

@keyframes curtain-open {
	from {
		transform: translateY(100%);
	}

	to {
		transform: translateY(0);
	}
}

@keyframes curtain-close {
	from {
		transform: translateY(0);
	}

	to {
		transform: translateY(-100%);
		display: none;
	}
}

.curtain {
	position: fixed;
	/* background: var(--color, var(--white)); */
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: 200;
	display: none;

	&.active {
		animation: curtain-open 0.5s forwards;
		display: block;
	}

	/* animation: curtain-close 1s forwards; */
}

label {
	position: absolute;
	margin-top: 200px;
}

.img-container {
	position: relative;
	width: fit-content;
	height: fit-content;

	&>img {
		border: 2px solid var(--black);
		display: block;
	}

	&>div {
		background: var(--black);
		top: 0;
		left: 0;
		width: 100%;
		height: 100%;
		position: absolute;
		/* display: none; */
		opacity: 0;
		transition: opacity 0.2s;
	}

	&:has(>img.none)>div {
		/* display: block; */
		opacity: 1;
	}
}


svg {
	width: 1em;
	height: 1em;
	display: inline-block;
	/* vertical-align: middle; */
	margin-top: 0.04em;
	stroke-width: 2px;
	aspect-ratio: 1;
}

.cursor {
	position: fixed;
	top: 0;
	left: 0;
	pointer-events: none;
	z-index: 102;
	will-change: transform;
	background: none;

	transition: opacity 0.1s;

	&.none {
		opacity: 0;
	}

	background-color: transparent;

	&:has(.diff) {
		mix-blend-mode: exclusion;
	}

	&:has(~ .dark-background:hover)>.ball {
		background-color: var(--white);

		&.focus {
			background-color: var(--black);
		}
	}
}

.cursor>.ball {
	position: absolute;
	width: clamp(0.3rem, 1vw, 0.6rem);
	height: clamp(0.3rem, 1vw, 0.6rem);
	border-radius: 999px;
	background-color: var(--black);
	translate: -50% -50%;
	/* will-change: transform; */
	transition: background-color 0.2s;

	&.focus,
	&.diff {
		background-color: var(--white);
		/* mix-blend-mode: difference; */
	}
}

.cursor>.text {
	position: absolute;
	translate: -50% -50%;
	display: flex;
	color: var(--white);
	font-size: clamp(0.1rem, 1vw, 0.14rem);
	font-family: "DM Sans";
	font-weight: 500;
	text-align: center;
	align-items: center;
	justify-content: center;
	mix-blend-mode: exclusion;
	white-space: nowrap;
	line-height: 1;
	/* will-change: transform; */
}

@keyframes pop-load {
	from {
		opacity: 0;
		scale: 0.9;
	}

	to {
		opacity: 1;
		scale: 1;
	}
}

@keyframes bob {
	0% {
		scale: 1;
	}

	35% {
		scale: 1.1 1;
	}

	100% {
		scale: 1;
	}
}

.nav-container {
	width: 100%;
	justify-content: center;
	display: flex;
	flex-wrap: wrap;
}

.button-area {
	display: flex;
	background: none;
	width: clamp(15rem, 30vw, 18rem);
	height: 6rem;
	justify-content: center;
	align-items: center;
	cursor: pointer;
}

.button-area span {
	background-image: linear-gradient(to right, var(--black) 50%, var(--white) 50%);
	background-size: 300%;
	background-position-x: 100%;
	border: 2px solid black;
	display: flex;
	text-align: center;
	align-items: center;
	justify-content: center;
	height: 3rem;
	width: clamp(10rem, 20vw, 12rem);
	font-family: "DM Sans";
	font-size: clamp(1rem, 2vw, 1.2rem);
	font-weight: 300;
	font-style: normal;
	color: var(--black);
	cursor: pointer;
	-webkit-tap-highlight-color: transparent;
	user-select: none;
	-webkit-user-select: none;
}

.button-area {
	& span {
		margin-top: 4px;
		will-change: scale;
		transition:
			background-position 1s cubic-bezier(.08, .72, 0, .91), color 0.15s, translate 0.15s cubic-bezier(.04, .61, 1, 1);
	}

	&:active span {
		background-position-x: 0%;
		color: var(--white);
		animation: bob 0.4s cubic-bezier(.04, .61, 1, 1);
	}

	@media (hover: hover) {
		&:hover span {
			background-position-x: 0%;
			color: var(--white);
			animation: bob 0.4s cubic-bezier(.04, .61, 1, 1);
		}
	}

	&.toggle span {
		translate: 50px;
	}
}

.progress-bar {
	display: flex;
	position: fixed;
	top: 15vh;
	left: calc(100% - clamp(1rem, 4vw, 2rem) - 3vw);
	width: clamp(1rem, 4vw, 2rem);
	height: 70vh;
	background: none;
	flex-direction: column;
	/* gap: 3rem; */
	justify-content: center;
	align-items: center;

	&>.checkpoint-bridge {
		width: 0;
		border-left: 2px dashed var(--black);
		height: clamp(2rem, 4vw, 4rem);
		margin-bottom: 5px;

		&.active {
			border-left: 2px solid var(--black);
		}
	}

	&>.checkpoint {
		width: 100%;
		background: none;
		aspect-ratio: 1;
		justify-content: center;
		align-items: center;
		display: flex;
		cursor: pointer;
		opacity: 0.5;
		position: relative;
		border-radius: 50%;

		&>.progress-where {
			position: absolute;
			top: 50%;
			left: 0;
			transform: translateX(-100%) translateY(-50%);
			white-space: nowrap;
			color: var(--white);
			background-color: var(--black);
			display: none;
		}

		&:active {
			opacity: 0.75;

			&>.checkpoint-indicate {
				scale: 3
			}

			&:not(.active)>.progress-where {
				display: block;
			}
		}

		@media (hover: hover) {
			&:hover {
				opacity: 0.75;

				&>.checkpoint-indicate {
					scale: 3
				}

				&:not(.active)>.progress-where {
					display: block;
				}
			}
		}

		&>.checkpoint-indicate {
			position: absolute;
			width: 6px;
			aspect-ratio: 1;
			background: var(--black);
			transition: scale 0.15s ease, background-color 0.1s;
			border-radius: 50%;
		}

		&>.checkpoint-dot {
			width: 6px;
			aspect-ratio: 1;
			background: var(--black);
			z-index: 2;
			border-radius: 50%;
		}

		&.active {
			opacity: 1;

			&>.checkpoint-indicate {
				scale: 5.5;
			}

			&>.checkpoint-dot {
				background: var(--white);
			}

			/* box-sizing: content-box; */
		}
	}
}

@media (max-width: 700px) {

	.dark-background,
	body {
		padding: 1rem;
		padding-top: 2rem;
		padding-bottom: 2rem;
	}

	.dark-background {
		margin-top: 1rem;
	}

	.cursor>.ball {
		width: clamp(0.9rem, 1vw, 1.1rem);
		height: clamp(0.9rem, 1vw, 1.1rem);
	}

	.cursor>.text {
		font-size: clamp(0.1rem, 1vw, 0.2rem);
	}

	.image-in-text {
		&>.img-container {
			margin-top: 1rem;
			margin-bottom: 1rem;
		}

		flex-wrap: wrap;
	}
}
