@font-face {
	font-family: 'Montserrat';
	src: url('../assets/fonts/Montserrat-Regular.woff2') format('woff2'),
		url('../assets/fonts/Montserrat-Regular.woff') format('woff');
	font-weight: 400;
	font-display: swap;
}

@font-face {
	font-family: 'Montserrat';
	src: url('../assets/fonts/Montserrat-Bold.woff2') format('woff2'),
		url('../assets/fonts/Montserrat-Bold.woff') format('woff');
	font-weight: 700;
	font-display: swap;
}

* {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
}

:root {
	--font-color: #fff;
	--bg-color: #201e1e;
}

html {
	height: 100%;
	overflow-x: hidden;
}

.lock {
	overflow: hidden;
	scrollbar-gutter: stable;
}

body {
	font-family: 'Montserrat', serif;
	font-size: 16px;
	font-weight: 400;
	color: var(--font-color);
	background: var(--bg-color);
	overflow-x: hidden;
}

input[type='search']::-webkit-search-decoration,
input[type='search']::-webkit-search-cancel-button,
input[type='search']::-webkit-search-results-button,
input[type='search']::-webkit-search-results-decoration {
	-webkit-appearance: none;
}

button {
	background: inherit;
	border: none;
}

img {
	vertical-align: top;
	height: auto;
	width: 100%;
}

.container {
	max-width: 1230px;
	width: 100%;
	padding-left: 15px;
	padding-right: 15px;
	margin: 0 auto;
}

.header {
	padding-top: 15px;
	padding-bottom: 15px;
	border-bottom: 2px solid grey;
	box-shadow: 0 3px 6px rgba(255, 255, 255, 0.16),
		0 3px 6px rgba(255, 255, 255, 0.23);
}

.header__inner {
	display: flex;
	justify-content: space-between;
}

.header__logo {
	display: flex;
	align-items: center;
	gap: 10px;
}

.header__logo-img {
	filter: invert(1);
	width: 32px;
	height: 32px;
}

.header__logo-title {
	font-size: 24px;
}

.header__search {
	max-width: 300px;
	width: 100%;
	position: relative;
	height: 42px;
}

.header__search-input {
	padding: 10px;
	padding-right: 55px;
	border-radius: 10px;
	border: 2px solid rgb(0, 0, 0);
	outline: none;
	transition: all 0.3s ease;
	box-shadow: 0 3px 6px rgba(0, 0, 0, 0.16), 0 3px 6px rgba(0, 0, 0, 0.23);
	font-size: 16px;

	width: 100%;
	height: 42px;
	background-color: #fff;
	color: #333;
}

.header__search-input::placeholder {
	color: rgb(61, 61, 61);
}

.header__search-input:focus {
	outline: none;
	border: 2px solid rgb(255, 255, 255);
	box-shadow: 0 3px 6px rgba(255, 255, 255, 0.16),
		0 3px 6px rgba(255, 255, 255, 0.23);
}

.header__search-btn-icon {
	position: absolute;
	top: 0px;
	right: 0px;
	height: 100%;
	padding-left: 5px;
	padding-right: 5px;
	border-left: 1px solid grey;
	cursor: pointer;
	transition: all 0.3s ease;
	border-radius: 4px;
	border-right: 10px;
}

.header__search-btn-icon svg path {
	transition: all 0.3s ease;
}

.header__search-icon {
	width: 24px;
	height: 24px;
}

.header__search-btn-close {
	display: none;

	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	right: 35px;
	transition: all 0.3s ease;
	cursor: pointer;
}

.header__search-btn-close--active {
	display: block;
}

.header__search-close-icon {
	width: 16px;
	height: 16px;
}

.main {
	margin-top: 20px;
	margin-bottom: 40px;
}

.gallery {
}

.gallery__inner {
	display: grid;
	grid-gap: 10px;
	grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
	grid-auto-rows: 240px;
	grid-auto-flow: dense;
}

.gallery__img-box {
	cursor: pointer;
	transition: all 0.3s ease;
	overflow: hidden;
}

.gallery__img-box:hover .gallery__img {
	transform: scale(1.05);
}

.gallery__img-box:nth-child(even) {
	grid-column: span 2;
}

.gallery__img-box:first-child {
	grid-row: span 2;
	grid-column: span 2;
}

.gallery__img {
	object-fit: cover;
	object-position: 50% 50%;
	border-radius: 4px;
	height: 100%;
	transition: all 0.3s ease;
	pointer-events: none;
}

.modal {
	position: fixed;
	top: 0;
	left: 0;
	background: rgba(0, 0, 0, 0.5);
	z-index: 1;
	width: 100%;
	height: 100%;

	opacity: 0;
	visibility: hidden;
	transition: all 0.3s ease;

	display: flex;
	justify-content: center;
	align-items: center;
	flex-direction: column;
}

.modal--active {
	opacity: 1;
	visibility: visible;
}

.modal__content {
	width: clamp(400px, 55vw, 1000px);
	position: relative;
	box-shadow: 0 3px 6px rgba(255, 255, 255, 0.16),
		0 3px 6px rgba(255, 255, 255, 0.23);
}

.modal__close-btn {
	border: none;
	background: none;
	position: absolute;
	right: -32px;
	top: -32px;
	z-index: 100;
	cursor: pointer;
	transition: all 0.3s ease;
	padding: 5px;
}

.modal__content-btn {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 100;
	cursor: pointer;
	transition: all 0.3s ease;
	background: #000;
	border: 2px solid grey;
	box-shadow: 0 3px 6px rgba(255, 255, 255, 0.16),
		0 3px 6px rgba(255, 255, 255, 0.23);
	border-radius: 4px;

	display: flex;
	justify-content: center;
	align-items: center;
}

.modal__content-next-btn {
	right: -69px;
}
.modal__content-prev-btn {
	left: -69px;
}

.modal__content-arrow {
	width: 64px;
	height: 64px;
	filter: invert(1);
	pointer-events: none;
}

.modal__content-btn--disabled {
	display: none;
}

.modal__close-img {
	width: 32px;
	height: 32px;
	filter: invert(1);
	pointer-events: none;
}

.modal__img-box {
	position: relative;
	z-index: 10;
	max-height: 500px;
	overflow: hidden;
}

.modal__img {
	width: 100%;
	height: 500px;
	object-fit: cover;
	object-position: 50% 50%;
}

.modal__img-descr {
	padding: 10px;
	background: #000;
	font-size: 21px;
	border-radius: 4px;
}

.modal__img-descr:first-letter {
	text-transform: uppercase;
}

.footer {
	padding-bottom: 10px;
}

.footer__inner {
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.footer__link {
	transition: all 0.3s ease;
}

.footer__link-img {
	width: 50px;
	height: 50px;
}

.footer__year {
	font-weight: 700;
	font-size: 24px;
}

@media (hover: hover) {
	.header__search-btn-icon:hover {
		background: #201e1e;
	}

	.header__search-btn-icon:hover svg path {
		stroke: #fff;
	}

	.header__search-btn-icon:active svg path {
		stroke: #555555;
	}

	.modal__close-btn:hover {
		opacity: 0.75;
	}

	.modal__close-btn:active {
		opacity: 0.5;
	}

	.modal__content-btn:hover {
		opacity: 0.75;
	}

	.modal__content-btn:active {
		opacity: 0.5;
	}

	.modal__content-btn--disabled:hover {
		cursor: auto;
		opacity: 0.5;
	}

  .footer__link:hover {
		opacity: 0.75;
	}

	.footer__link:active {
		opacity: 0.5;
	}
}
