body {
	margin: 0;
	overflow: hidden;
	background: #181818;
	font-family: "Inter", sans-serif;
	font-optical-sizing: auto;
	font-weight: 400;
	font-style: normal;
	color: #fff;
}
*{
	user-select: none; 
	box-sizing: border-box;
}
.viewport {
	width: 100vw;
	height: 100vh;
	overflow: hidden;
	position: relative;
}

.hero {
	position: absolute;
	inset: 0;

	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;

	z-index: 10;
	pointer-events: none;

	color: white;
	z-index: 9998;
}

.hero__logo {
	position: fixed;
	top: 32px;
	left: 0px;
	right: 0px;
	z-index: 9998;
	text-align: center;
	opacity: 0;
	will-change: opacity;
	pointer-events: none;
}

.hero__title {
	font-family: "Instrument Serif", serif;
	font-size: 72px;
	letter-spacing: -0.01px;
	opacity: 0;
	position: relative;
	color: #454545;
	will-change: opacity;
	line-height: 85px;
}

.hero__title::before {
	content: attr(data-text);
	position: absolute;
	top: 0;
	left: 0;
	width: 0;
	overflow: hidden;
	white-space: nowrap;
	color: #fff;
	/* колір замальовування */
	animation: fillText 2s linear forwards;
}

@keyframes fillText {
	from {
		width: 0;
	}

	to {
		width: 100%;
	}
}

.hero__text {
	font-family: "Inter Tight", sans-serif;
	font-size: 17px;
	margin: 8px 0 0;
	opacity: 0;
	transform: translateY(30px);
	will-change: opacity, transform;
}

#canvas {
	position: absolute;

	width: 3840px;
	height: 3240px;
	transform-origin: 0 0;
}

.card {
	position: absolute;
	overflow: hidden;
	cursor: pointer;
}

.card img {
	width: 100%;
	height: 100%;
	object-fit: cover;

	position: absolute;
	left: 0%;
	top: 0%;

	will-change: transform;
}

.gallery-popup {
	position: fixed;
	inset: 0;
	z-index: 9999;

	display: flex;

	background: #181818;

	opacity: 0;
	visibility: hidden;

	transition: .4s;
	width: 100%;
	height: 100%;
}

.gallery-popup.active {
	opacity: 1;
	visibility: visible;
}

.gallery-sidebar {
	width: 90px;
	overflow-y: auto;
	padding: 16px;
	position: relative;
	z-index: 1000;
}

.gallery-thumbs {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.gallery-thumbs img {
	width: 100%;
	cursor: pointer;
	border-radius: 4px;
	opacity: .5;
	transition: .3s;
}

.gallery-thumbs img.active {
	opacity: 1;
}

.gallery-main {
	flex: 1;

	display: flex;
	align-items: center;
	justify-content: center;
	margin-left: -104px;
	width: calc(100% + 104px);
}

.gallery-main img {
	max-width: 100%;
	max-height: 100vh;
	width: 100%;
	height: 100%;
	will-change: opacity;
	object-fit: contain;
}
.gallery-main img.fullsize {
    object-fit: cover;
}

.gallery-close {
	position: absolute;
	top: 20px;
	right: 20px;
	background: none;
	border: none;
	color: white;
	font-size: 11px;
	cursor: pointer;
	width: 8px;
	padding: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	border: 1px solid rgba(255, 255, 255, 0.2);
	transition: border-color 0.3s;
	z-index: 100;
}

.gallery-close:hover {
	border-color: #fff;
}

.gallery-sidebar {
	width: 104px;
	height: 100vh;
	padding: 32px 0px;
	box-sizing: border-box;
}

.thumbs-swiper {
	height: 100%;
}

.thumbs-swiper .swiper-slide {
	width: 100%;
	height: auto;
	cursor: pointer;
	padding: 0 32px;
	box-sizing: border-box;
}

.thumbs-swiper img {
	width: 100%;
	display: block;
	transition: .3s;
}

.thumbs-swiper .active:after {
	content: '';
	display: block;
	background: #fff;
	position: absolute;
	left: 18px;
	top: 50%;
	width: 6px;
	height: 6px;
	border-radius: 100%;
	transform: translateY(-50%);
}

.modal {
	position: fixed;
	z-index: 9998;
	left: 32px;
	bottom: 32px;
	border: 1px solid #323232;
	background: rgba(0, 0, 0, 1);
	display: flex;
	flex-direction: column;
	gap: 16px;
	padding: 24px;
	border-radius: 4px;
	opacity: 0;
	transition: .4s;
	width: 384px;
	max-width: 100%;
	font-family: "Inter Tight", sans-serif;
}

.modal.active {
	opacity: 1;
}

.modal__title {
	font-size: 14px;
	display: flex;
	align-items: center;
	gap: 13px;
	font-family: "Inter Tight", sans-serif;
}

.modal__text {
	font-size: 12px;
}

.modal__bottom {
	display: flex;
	gap: 16px;
	justify-content: flex-start;
	align-items: center;
}

.modal__btn {
	padding: 8px 16px;
	background: #fff;
	color: #000;
	border-radius: 100px;
	cursor: pointer;
	display: inline-flex;
	border: 1px solid #0000001A;
	font-size: 13px;
}

.modal__btn:hover {
	background: #555;
	color: #fff;
}

.modal__link {
	display: inline-block;
	font-size: 14px;
	text-decoration: none;
}
.copyright {
	position: fixed;
	bottom: 32px;
	left: auto;
	right: 28px;
	z-index: 9998;
	font-size: 10px;
	line-height: 150%;
	font-family: "Inter Tight", sans-serif;
	text-transform: uppercase;
	pointer-events: none;
	color: rgba(255, 255, 255, 0.8);
	opacity: 0.4;
	writing-mode: vertical-rl;
    transform: rotate(180deg);
}

@media screen and (max-width: 768px) {
	.hero__title {
		font-size: 44px;
	}

	.modal {
		left: 10px;
		right: 10px;
		bottom: 10px;
	}

	.modal__title {
		font-size: 12px;
	}

	.gallery-popup {
		flex-direction: column;
	}

	.gallery-image {
		max-height: 80vh;
	}

	.gallery-sidebar {
		width: 100%;
		height: fit-content; 
		order: 2;
		padding: 10px;
		box-sizing: border-box; 
		flex: 0 0 auto;
    	align-self: flex-start;
	}

	.gallery-main {
		flex: 1;
		order: 1;
		margin: 0;
		width: 100%;
	}

	.thumbs-swiper {
		width: 100%;
		height: 100%;
	}

	.thumbs-swiper .swiper-slide {
		width: 40px;
		flex-shrink: 0;
		padding: 15px 0;
	}

	.thumbs-swiper img {
		width: 100%;
		object-fit: cover;
	}

	.thumbs-swiper .active:after {
		left: 50%;
		top: 3px;
		transform: translateX(-50%);
	}
	.copyright{
		bottom: 10px;
		right: 10px;
	}
}