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

:root {
	font-size: 12px;
}

body {
	margin: 0;
	--color-text: #715942;
    --color-text-alt: #5a4939;
    --color-alt: #e8c59e;
	--color-text-button: #fff;
    --color-bg: #060606;
    --color-link: #e8c59e;
    --color-link-hover: #e8c59e;
	--color-deco: #292724;
    color: var(--color-text);
    background-color: var(--color-bg);
	font-family: usual,-apple-system, BlinkMacSystemFont, Segoe UI, Helvetica, Arial, sans-serif;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

/* Page Loader */
.js .loading::before,
.js .loading::after {
	content: '';
	position: fixed;
	z-index: 1000;
}

.js .loading::before {
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: var(--color-bg);
}

.js .loading::after {
	top: 50%;
	left: 50%;
	width: 60px;
	height: 60px;
	margin: -30px 0 0 -30px;
	border-radius: 50%;
	opacity: 0.4;
	background: var(--color-link);
	animation: loaderAnim 0.7s linear infinite alternate forwards;

}

@keyframes loaderAnim {
	to {
		opacity: 1;
		transform: scale3d(0.5,0.5,1);
	}
}

a {
	text-decoration: none;
	color: var(--color-link);
	outline: none;
}

a:hover {
	color: var(--color-link-hover);
	outline: none;
}

/* Better focus styles from https://developer.mozilla.org/en-US/docs/Web/CSS/:focus-visible */
a:focus {
	/* Provide a fallback style for browsers
	 that don't support :focus-visible */
	outline: none;
	background: lightgrey;
}

a:focus:not(:focus-visible) {
	/* Remove the focus indicator on mouse-focus for browsers
	 that do support :focus-visible */
	background: transparent;
}

a:focus-visible {
	/* Draw a very noticeable focus style for
	 keyboard-focus on browsers that do support
	 :focus-visible */
	outline: 2px solid red;
	background: transparent;
}

.unbutton {
	background: none;
	border: 0;
	padding: 0;
	margin: 0;
	font: inherit;
}

.unbutton:focus {
	outline: none;
}

.js .oh {
	display: inline-block;
	position: relative;
	overflow: hidden;
}

.js .oh > span {
	display: inline-block;
	will-change: transform;
}

.frame {
	z-index: 1000;
	text-transform: uppercase;
	position: relative;
	text-align: left;
	top: 0;
	left: 0;
	display: grid;
	align-items: start;
	align-content: space-between;
	width: 100%;
	padding: 3rem 4vw 1.85rem;
	grid-template-columns: 100%;
	grid-template-areas: 'title'
						'links'
						'author'
						'credits';
}

.frame a {
	font-weight: 700;
}

.frame__title {
	grid-area: title;
	font-size: 1rem;
	margin: 0 0 1rem;
	font-weight: normal;
}

.frame__links {
	grid-area: links;
}

.frame__links a:not(:last-child) {
	margin-right: 1rem;
}

.frame__author {
	grid-area: author;
	margin: 1rem 0;
}

.frame__credits {
	grid-area: credits;
	margin: 0;
}

.frame__category {
	margin: 0;
	grid-area: title;
	justify-self: start;
}

.frame__close {
	grid-area: title;
	justify-self: end;
	text-transform: uppercase;
	font-weight: bold;
	cursor: pointer;
	color: var(--color-text);
}

.frame__close span::before {
	content: "\2715";
	margin: 0 0.25rem 0;
	vertical-align: top;
}

.content {
	display: flex;
	flex-direction: column;
	width: 100vw;
	height: calc(100vh - 13rem);
	position: relative;
	justify-content: flex-start;
	align-items: center;
	padding: 6rem 4vw;
	font-family: meno-banner, serif;
}

.content--menu {
	pointer-events: none;
}

.content__quote {
	font-size: 5.25vw;
	margin: 0;
	text-indent: 20vw;
	line-height: 1.1;
}

.content__quote span.word {
	will-change: transform, opacity;
}

.menu-item {
	font-weight: 400;
	position: relative;
	display: inline-block;
	text-indent: 0;
	cursor: pointer;
	z-index: 100;
	pointer-events: auto;
}

.menu-item::after {
	content: '';
	position: absolute;
	top: 89%;
	left: 0;
	width: 100%;
	height: 0.375vw;
	background: var(--color-alt);
	z-index: -1;
	transform: scale3d(0.001,1,1);
	opacity: 0;
	transform-origin: 100% 50%;
	transition: transform 0.3s cubic-bezier(0.2,1,0.3,1), opacity 0.1s 0.2s linear;
}

.menu-item.menu-item--active::after,
.content--menu .menu-item.menu-item--active:hover::after,
.menu-item:hover::after {
	opacity: 1;
	transform: scale3d(1,1,1);
	transform-origin: 0% 50%;
	transition: transform 0.7s cubic-bezier(0.2,1,0.3,1), opacity 0.1s linear;
}

.content--menu .menu-item::after {
	transform-origin: 0% 50%;
}

.content--menu .menu-item:hover::after {
	transform: scale3d(0.15,1,1);
}

.splitting .word {
	text-indent: 0;
}

.menu-item span {
	pointer-events: none;
}

.galleries {
	position: absolute;
	width: 100%;
	height: 100vh;
	top: 0;
	left: 0;
	pointer-events: none;
}

.galleries__deco {
	position: fixed;
	bottom: 0;
	color: var(--color-deco);
	font-size: 7vw;
	text-transform: uppercase;
	white-space: nowrap;
	line-height: 0.3;
	text-indent: -2vw;
	pointer-events: none;
	opacity: 0;
	will-change: transform, opacity;
	font-family: meno-banner, serif;
	font-style: italic;

}

.galleries__button {
	position: absolute;
	width: 20vw;
	height: 20vw;
	text-align: center;
	display: flex;
	align-items: center;
	justify-content: center;
	top: 50%;
	left: 30vw;
	margin: -10vw 0 0 -10vw;
	color: var(--color-text-button);
	text-transform: uppercase;
	font-weight: bold;
	font-size: 1.25rem;
	cursor: pointer;
	clip-path: circle(calc(50% + 2px) at 50% 50%);
	border: 1px solid var(--color-text-button);
	border-radius: 50%;
	opacity: 0;
	cursor: not-allowed;
}

.galleries__button::before {
	content: '+';
	margin-right: 0.5rem;
}

.gallery--current ~ .galleries__button {
	pointer-events: auto;
}

.gallery {
	position: relative;
	width: 100%;
	height: 100%;
	display: flex;
	overflow: hidden;
	align-items: center;
	isolation: isolate;
	height: 0;
}

.gallery--current {
	position: absolute;
	top: 0;
	left: 0;
	height: 100%;
}

.gallery__img {
	flex: none;
	width: 14.5vw;
	height: auto;
	margin: 0 -1vw;
	mix-blend-mode: soft-light;
	opacity: 0.8;
	will-change: transform, opacity;
}

.gallery__img:nth-child(odd) {
	margin-top: 20vh;
}

.gallery__img:nth-child(3n) {
	margin-top: -20vh;
}

@media screen and (min-width: 53em) {
	.frame {
		pointer-events: none;
		position: fixed;
		height: 100vh;
		grid-template-columns: 20vw 36vw 1fr auto;
		grid-template-rows: auto auto auto;
		grid-template-areas: 'title links category close'
							'... ... ... ...'
							'author ad ad credits';
	}
	.frame__title {
		margin: 0;
	}
	.frame__links {
		padding: 0;
	}
	.frame__author {
		align-self: end;
		justify-self: start;
		margin: 0;
	}
	.frame__credits {
		justify-self: end;
		align-self: end;
	}
	.frame__close {
		grid-area: close;
	}
	.frame__category {
		grid-area: category;
		justify-self: start;
		margin: 0;
	}
	.frame a, 
	.frame button {
		pointer-events: auto;
	}
	.content {
		height: 100vh;
		justify-content: center;
	}
}
