/*settings*/

:root {
	--key_value: 18px;
	--color-grey: #ababab;
	--transition: all .666s;
	--transition_s: all .333s;
	--transition_l: all 1.333s;
	--header: 42px;
}

body {
	margin: 0;
	padding: 0;
	background-color: white;
}

* {
	box-sizing: border-box;
}

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

img,
video,
iframe {
	display: block;
	object-fit: cover;
	transform: translate3d(0, 0, 0);
}

video {
	width: 100%;
}

@media (min-width: 768px) {

	.single-view img,
	.single-view iframe {
		max-width: 100vw;
		max-height: 100vh;
	}

}

#archive img {
	width: 100%;
}

#archive iframe {
	/* position: absolute;
	top: 0;
	left: 0; */
	width: 100%;
	transition: var(--transition);
	pointer-events: none;
	transition: var(--transition);
	transition-delay: 1s;
}

/* #archive .vimeo-thumb.load {
	opacity: 0;
	filter: blur(10px);
} */

video {
	transition: var(--transition);
}

#archive video.load {
	opacity: 0;
	filter: blur(10px);
}

.vimeo-thumb {
	/* display: none; */
	position: absolute;
	top: 0;
	left: 0;
	z-index: -1;
	/* filter: blur(20px);
	opacity: .5;
	transform: translate3d(0,0,0);
	transition: var(--transition); */
}

/*fonts*/

/* @font-face {
	font-family: 'HelveticaNeue';
	src: url('/Users/axvgarcia/Documents/WORK/2511_estergmera/estergmera.com/styles/fonts/HelveticaNeue.ttc') format('ttc');
} */

a {
	all: unset;
	display: block;
	cursor: pointer;
	color: var(--color-grey);
	transition: var(--transition);
}

span {
	all: unset;
}

a:not(.list-item):hover,
a.active:not(#press-button) {
	color: black;
}

h1,
h2,
p,
a,
span,
::before,
::after {
	font-family: "Inter", Arial, sans-serif;
	font-optical-sizing: auto;
	font-weight: 500;
	font-size: 15px;
	margin: 0;
	padding: 0;
	line-height: var(--key_value);
}

h1,
h2,
p {
	color: black;
}

/*header*/

header {
	width: 100%;
	display: flex;
	align-items: flex-start;
	position: sticky;
	top: 0;
	left: 0;
	padding: var(--key_value) var(--key_value) 0;
	z-index: 2;
}

header>* {
	flex: 1;
}

header h1 {
	text-transform: uppercase;
}

nav {
	display: flex;
	align-items: flex-start;
	flex-grow: 7;
	gap: 3px;
}

nav a {
	width: fit-content;
}

#about-button {
	margin-left: auto;
}

nav>*:not(:last-child) {
	width: calc(100vw/24);
}

nav>*.active a {
	color: black;
}

#title a {
	color: black;
	width: fit-content;
	white-space: nowrap;
	margin-right: 10px;
}

#title a:hover {
	color: var(--color-grey);
}

/*info*/

#info-container {
	display: none;
}

/*list*/

#list {
	padding: 0 calc(100vw/24);
	position: fixed;
	width: 100vw;
	top: calc(100vw/24 + var(--header));
}

#list {
	pointer-events: none;
}

.list-item .title>* {
	pointer-events: auto;
}

.list-item {
	display: flex;
	overflow: hidden;
	height: var(--key_value);
	transition: var(--transition);
	position: relative;
	gap: 3px;
}

.list-item.load {
	opacity: 0;
	filter: blur(10px);
}

.list-item>* {
	flex: 1;
}

.list-item>*:not(:first-child) {
	flex-grow: 5;
}

.list-item .category {
	flex-grow: 4;
}

.list-item>*:last-child {
	text-align: right;
}

.list-item>*:nth-last-child(3) {
	flex-grow: 10;
}

.list-item .duration {
	flex-grow: 2;
}

.list-item.filter {
	height: 0 !important;
	padding: 0 initial !important;
}

#list span {
	white-space: nowrap;
}

/*gallery*/

#gallery-container {
	position: fixed;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100vh;
	overflow: scroll;
	z-index: -1;
}

#gallery-container>* {
	transition: var(--transition_l);
}

#gallery-container>*.hide {
	opacity: 0;
	filter: blur(10px);
}

.thumbnail {
	transition: var(--transition);
	overflow: hidden;
	position: relative;
	width: calc(100vw/24*10 - 80px);
	margin: 0 auto;
	display: block;
}

.thumbnail:not(:last-child) {
	margin-bottom: 5px;
}

.thumbnail.unactive {
	filter: blur(3px);
	opacity: .3;
}

/* .thumbnail.film.photo.switch>*:first-child {
	height: 0;
} */

.thumbnail.film.photo>* {
	transition: var(--transition);
}

.thumbnail.film.photo img {
	position: absolute;
	top: 0;
	left: 0;
	opacity: 0;
	pointer-events: none;
	/* z-index: -1; */
}

.thumbnail.film.photo.switch img {
	opacity: 1;
	pointer-events: auto;
}

.thumbnail.film.photo.switch video {
	opacity: 0;
	pointer-events: none;
}

/* #archive .thumbnail::before {
	content: "Loading...";
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
} */

.thumbnail img {
	transition: var(--transition);
}

/* .thumbnail img.filter {
	height: 0 !important;
	margin-bottom: 0 !important;
} */

.thumbnail.filter {
	height: 0 !important;
	margin-bottom: 0 !important;
}

/*single*/

#post>* {
	transition: var(--transition);
}

#post.hide>* {
	opacity: 0;
	filter: blur(10px);
}

#post {
	min-height: 100vh;
}

#post>* {
	transition: var(--transition);
}

#single-gallery {
	position: fixed;
	display: flex;
	align-items: center;
	justify-content: center;
	height: 100%;
	/* width: calc(100vw/24*13); */
	width: 100vw;
	left: 50%;
	transform: translate(-50%, 0);
}

#single-gallery>* {
	position: absolute;
	transition: var(--transition_s);
	opacity: 0;
	/* max-width: 100%; */
	max-width: calc(100vw/24*13);
}

#single-gallery iframe {
	/* width: 100%; */
	width: calc(100vw/24*13);
	height: auto;
}

#single-gallery>*.active {
	opacity: 1;
	z-index: 1;
}

.video-wrapper:fullscreen .video-controls {
	aspect-ratio: auto !important;
	width: 100% !important;
}

.video-wrapper:fullscreen iframe {
	width: 100vw !important;
	margin: auto 0;
	height: 100% !important;
}

.video-wrapper:not(.active) {
	pointer-events: none;
}

#single-gallery iframe {
	position: relative;
}

#loading {
	transition: var(--transition);
	position: fixed;
	top: 50%;
	left: 50%;
	transform: translate(-50%, 0);
	z-index: -9;
	color: var(--color-grey);
	animation: blink 1s ease-in-out infinite;
}

@keyframes blink {

	0%,
	100% {
		opacity: .8;
	}

	50% {
		opacity: 0.2;
	}
}

#single-index {
	position: absolute;
	left: calc(100vw/24);
	top: 50vh;
	transform: translateY(0);
	transition: var(--transition);
}

#single-index.hide,
#loading.hide {
	opacity: 0;
	filter: blur(10px);
}

#thumbnails {
	position: absolute;
	top: calc(var(--header) + 100vw/24);
	right: var(--key_value);
	width: calc(100vw/24);
	z-index: 999;
	display: flex;
	flex-direction: column;
}

#thumbnails>* {
	width: 100%;
	height: auto;
	transition: var(--transition_s);
	opacity: .333;
	margin-bottom: 5px;
}

#thumbnails .video-wrapper:last-of-type {
	padding-bottom: 10px;
	margin-bottom: 10px !important;
	border-bottom: 1px solid var(--color-grey);
}

#thumbnails .video-wrapper:last-of-type.single {
	padding-bottom: 0;
	margin-bottom: 5px !important;
	border: none;
}

#thumbnails .video-wrapper:first-of-type {
	order: -1;
}

#thumbnails iframe {
	width: 100%;
}

#thumbnails>*.active {
	opacity: 1;
}

#credits-button {
	position: fixed;
	top: 50vh;
	left: calc((100vw/24 * 20));
}

#credits-button.active a {
	color: black;
}

@media (min-width: 768px) {

	#credits-button.film {
		left: calc(100vw/24 * 21);
	}

}

@media (min-width: 768px) {

	#single-gallery.credits {
		transform: translate(-50%, calc((var(--credits-height)*-1) - (var(--key_value)*2)));
	}

}

#single-index.credits {
	top: calc(50vh - calc(var(--credits-height) + var(--key_value)*2));
}

#credits {
	position: fixed;
	left: 0;
	bottom: 0;
	padding: 0 calc(100vw/24 + var(--key_value) * 2) 0 var(--key_value);
	/* transform: translateY(100%); */
	max-height: 0;
	overflow: hidden;
	transition: var(--transition);
	box-sizing: content-box;
}

#credits.active {
	/* transform: none; */
	max-height: calc(var(--credits-height));
	padding-bottom: var(--key_value);
}

#credits span {
	font-weight: 400;
	/* color: var(--color-grey); */
}

/* #credits.active {
	transform: translateY(0);
} */

.video-controls {
	position: absolute;
	z-index: 1;
	top: 0;
	left: 50%;
	transform: translateX(-50%);
	display: flex;
	align-items: end;
	width: auto !important;
	height: 100%;
	gap: var(--key_value);
	transition: var(--transition);
	opacity: 1;
	cursor: pointer;
}

.video-controls.hidden {
	opacity: 0;
}

.video-controls p {
	color: white;
	transition: var(--transition);
	white-space: nowrap;
}

.video-controls>* {
	margin-bottom: var(--key_value);
}

.play-pause {
	padding-left: var(--key_value);
}

.fullscreen-toggle {
	padding-right: var(--key_value);
}

.video-controls p:hover {
	opacity: .333;
}

input[type="range"] {
	all: unset;
	width: 100%;
	position: relative;
	height: 1px;
	background-color: white;
	margin-bottom: calc(var(--key_value) + var(--key_value)/2);
}

input[type="range"]::-webkit-slider-thumb {
	-webkit-appearance: none;
	height: 5px;
	width: 5px;
	border-radius: 50%;
	background: white;
	transition: var(--transition_s);
}

input[type="range"]:hover::-webkit-slider-thumb {
	height: 10px;
	width: 10px;
}

.fullscreen-toggle {
	order: 10;
}

/* about */

#about {
	position: fixed;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100dvh;
	background-color: rgba(255, 255, 255, .8);
	opacity: 0;
	pointer-events: none;
	transition: var(--transition);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
	display: flex;
	align-items: end;
	padding: var(--key_value) var(--key_value) 0;
	/* padding: var(--key_value); */
}

#about.active {
	opacity: 1;
	pointer-events: all;
}

#about h1,
#social a {
	text-transform: uppercase;
}

#about>* {
	flex: 1;
}

#about a,
#about p {
	font-weight: normal;
}

#contact a,
#contact p {
	color: black;
}

#contact a:hover {
	color: var(--color-grey);
}

#about h1,
#contact>div>div {
	margin-bottom: var(--key_value);
}

#press {
	flex-grow: 3.8;
	transition: var(--transition);
}

#contact>div {
	padding-right: calc(100vw/24);
}

/* #press .content>* {
	display: flex;
	flex-wrap: wrap;
	padding-right: calc(100vw/24*4);
	transition: var(--transition_l);
	overflow: hidden;
} */

/* @media (min-width: 1024px) {
	#press .main {
		max-height: 180px;
	}
} */

#press .content {
	display: flex;
	padding-right: calc(100vw/24*4);
}

#press .content>* {
	flex: 1;
    padding-right: calc(100vw/24);
}

#press .content>* div {
	margin-bottom: var(--key_value);
	transition: var(--transition);
	overflow: hidden;
}

@media (min-width: 768px) {
	
	#press .content>* div[data-hierarchy="other"] {
		margin-bottom: 0;
	}

}

/* @media (min-width: 2560px) {
#press .content a {
		margin-right: calc(100vw/24);
	}
} */

#press .heading {
	display: flex;
	gap: var(--key_value);
}

#press .heading>* {
	min-width: calc(100vw/24 * 3);
	white-space: nowrap;
	font-weight: 500;
	text-transform: uppercase;
}

/*responsive*/

@media (min-width: 768px) {

	#prev-next,
	#preview,
	.post-data {
		display: none;
	}
}

@media (max-width: 768px) {

	/*settings*/

	:root {
		--key_value: 14px;
	}

	h1,
	h2,
	p,
	a,
	span,
	::before,
	::after {
		font-size: 12px;
	}

	img,
	video {
		width: 100% !important;
		padding: 0 !important;
	}

	/*header*/

	header {
		padding: var(--key_value) calc(var(--key_value)*1.2);
		background-color: white;
	}

	header * {
		font-size: 13px;
	}

	#title {
		flex-grow: 3;
	}

	nav {
		flex-grow: 5;
	}

	nav>*:not(:last-child) {
		width: calc(100vw/8);
	}

	/*gallery*/

	#gallery-container {
		position: relative;
		height: initial;
		overflow: initial;
		z-index: 0;
	}

	.thumbnail {
		width: initial;
	}

	.thumbnail:not(:last-child) {
		margin-bottom: 0;
	}

.thumbnail.load {
	opacity: 0;
	filter: blur(10px);
}

	.vimeo-thumb {
		width: 100%;
		height: auto;
	}

	#list {
		display: none;
	}

	.post-data {
		display: flex;
		position: relative;
		padding: 1px calc(var(--key_value)*1.2);
		transition: var(--transition);
		/* height: var(--key_value); */
		/* box-sizing: content-box; */
		position: absolute;
		bottom: 0;
		left: 0;
		width: 100%;
	}

	.post-data.filter {
		height: 0 !important;
		padding: 0 calc(var(--key_value)*1.2) !important;
	}

	.post-data>* {
		flex: 1;
		white-space: nowrap;
	}

	.post-data>*:nth-child(1),
	.post-data>*:nth-child(2) {
		flex: 0;
	}

	.post-data>*:nth-child(1)::after {
		content: "-";
		margin: 0 3px;
	}

	#archive .post-data>*:nth-last-child(2) {
		text-align: right;
	}

	#archive .post-data>*:last-child {
		display: none;
	}

	.post-data span {
		color: black;
	}

	/* about */

	#about {
		background-color: rgba(255, 255, 255, .8);
		display: flex;
		flex-direction: column;
		align-items: stretch;
		padding: var(--key_value) calc(var(--key_value)*1.2) 0;
		overflow: scroll;
	}

	#about.active {
	overflow: scroll;
}

	#contact {
		margin-top: auto;
		padding-top: calc(var(--header) + var(--key_value));
	}

	#about>* {
		flex: 0;
		justify-self: end;
	}

	#about h1 {
		margin-bottom: 0;
	}

	#contact,
	#contact>div {
		display: flex;
	}

	#contact>* {
		flex: 1;
	}

	#not-social {
		order: 9;
	}

	#social>* {
		width: fit-content;
		margin-left: auto;
	}

	#contact>div {
		flex-grow: 3;
		flex-wrap: wrap;
		padding: 0;
	}

	#contact>div>* {
		flex: 1;
	}

	#bio {
		flex: 0 1 66.666% !important;
		padding-right: calc(100%/6);
	}

	#press .heading {
		margin-bottom: var(--key_value);
		gap: 0;
	}

	#press .heading>* {
		width: calc((100vw - var(--key_value) * 2) / 8 * 2);
		white-space: normal;
	}

		#press .content {
			display: block;
			padding: 0 0 0 calc((100vw - var(--key_value) * 2) / 8 * 2);
		}

		#press .content>* {
			display: block;
			transition: var(--transition_l);
	padding-right: 0;
	max-height: 0;
	overflow: hidden;
}

#press .content>* a {
	width: 100%;
	margin-bottom: var(--key_value);
}

	/* single */

	#single-gallery {
		position: relative;
		width: 100vw;
		left: auto;
		transform: none;
		align-items: start;
		/* padding: 0 var(--key_value); */
	}

#single-gallery>* {
	max-width: 100%;
}

#single-gallery iframe {
	width: 100%;
}

	#single-gallery>*:not(.video-wrapper) {
		top: 0;
		left: 0;
		padding: 0 var(--key_value) !important;
	}

	#single-gallery .video-wrapper {
		width: 100%;
	}

	#single-gallery>*.active {
		position: relative;
	}

	#post {
		min-height: calc(100dvh - var(--header));
		display: flex;
		flex-direction: column;
	}

	#post .post-data {
		padding: var(--key_value) calc(var(--key_value)*1.2) 7px !important;
		position: sticky;
		top: var(--header);
		z-index: 9;
		background-color: white;
	}

	#post .post-data>*:last-child {
		text-align: right;
	}

	#single-index {
		display: none;
	}

	#post-footer {
		position: sticky;
		bottom: 0;
		width: 100%;
		background-color: white;
		z-index: 9;
		padding-top: calc(var(--key_value)/1.2);
		margin-top: auto;
	}

	#post-footer>* {
		padding: 0 calc(var(--key_value)*1.2) 10px;
	}

	#post-buttons {
		display: flex;
		justify-content: space-between;
		padding-bottom: calc(var(--key_value) * 1.2);
	}

	#credits-button {
		position: relative;
		top: auto;
		left: 0;
		bottom: 0;
		transition: var(--transition);
	}

	#credits-button>* {
		width: fit-content;
	}

	.video-controls>* {
		margin-bottom: 10px;
	}

	.play-pause {
		padding-left: calc(var(--key_value)*1.2);
	}

	.fullscreen-toggle {
		padding-right: calc(var(--key_value)*1.2);
	}

	input[type="range"] {
		margin-bottom: calc(10px + var(--key_value)/2);
	}

	#thumbnails {
		position: relative;
		width: 100%;
		flex-direction: row;
		gap: 5px;
		top: 0;
		right: 0;
		padding-bottom: 0;
		width: 100%;
		overflow: scroll;
		pointer-events: none;
		transition: var(--transition);
		max-height: 0;
		overflow: hidden;
	}

	#thumbnails.active {
		pointer-events: auto;
		overflow-x: scroll;
		max-height: calc(var(--thumb-height) + var(--key_value));
		/* padding-bottom: calc(var(--key_value)/1.2); */
		padding-bottom: 10px;
	}

	#thumbnails>*,
	#thumbnails img {
		height: 60px;
		width: fit-content;
		margin: 0;
	}

	#thumbnails img{
		width: auto !important;
	}

	#thumbnails video {
		width: auto !important;
		height: 100%;
	}

	#thumbnails .video-wrapper:last-of-type {
		margin: 0 5px 0 0 !important;
		padding: 0 10px 0 0 !important;
		border-right: 1px solid var(--color-grey);
		border-bottom: none;
	}

#thumbnails .video-wrapper:last-of-type.single {
	padding: 0;
	border: none;
}

	#credits {
		position: relative;
		padding: 0 calc(var(--key_value)*1.2);
	}

	#preview {
		position: relative;
		z-index: 99;
		width: fit-content;
	}

	#preview::after {
		content: " +";
	}

	#preview.active::after {
		content: " -";
	}

	#prev-next {
		margin-top: auto;
		display: flex;
		/* padding-bottom: calc(var(--key_value)*2); */
		width: 100%;
		justify-content: space-between;
		transition: var(--transition);
	}

	#prev-next a {
		display: flex;
		flex-direction: column;
	}

	#prev-next a {
		font-weight: 400;
	}

	#prev a::before {
		content: "Previous";
	}

	#next a::before {
		content: "Next";
		align-self: end;
		width: fit-content;
	}

}