.mgp-gallery {
	--mgp-gap: clamp(6px, .9vw, 14px);
	display: grid;
	grid-template-columns: 32fr 40fr 28fr;
	grid-template-rows: repeat(12, 1fr);
	gap: var(--mgp-gap);
	width: 100%;
	aspect-ratio: 1.8 / 1;
	min-height: 420px;
	max-height: 720px;
	overflow: hidden;
}

.mgp-gallery__item {
	position: relative;
	display: block;
	min-width: 0;
	overflow: hidden;
	border-radius: clamp(8px, 1.15vw, 18px);
	background: #f2ede8;
	color: #fff;
	text-decoration: none !important;
	opacity: 1;
	transform: translate3d(0, 0, 0) scale(1);
	transition: opacity .8s cubic-bezier(.22, 1, .36, 1) var(--mgp-delay, 0ms),
		transform .8s cubic-bezier(.22, 1, .36, 1) var(--mgp-delay, 0ms);
	will-change: transform, opacity;
	isolation: isolate;
}

.mgp-gallery.is-enhanced:not(.is-visible) .mgp-gallery__item {
	opacity: 0;
	transform: translate3d(0, 34px, 0) scale(.965);
}

.mgp-gallery.is-visible .mgp-gallery__item {
	opacity: 1;
	transform: translate3d(0, 0, 0) scale(1);
}

.mgp-gallery__item--1 { grid-column: 1; grid-row: 1 / 8; }
.mgp-gallery__item--2 { grid-column: 2; grid-row: 1 / 6; }
.mgp-gallery__item--3 { grid-column: 3; grid-row: 1 / 6; }
.mgp-gallery__item--4 { grid-column: 1; grid-row: 8 / 13; }
.mgp-gallery__item--5 { grid-column: 2; grid-row: 6 / 13; }
.mgp-gallery__item--6 { grid-column: 3; grid-row: 6 / 13; }

.mgp-gallery__media {
	position: absolute !important;
	inset: 0 !important;
	display: block !important;
	width: 100% !important;
	height: 100% !important;
	overflow: hidden !important;
}

.mgp-gallery__image {
	display: block !important;
	width: 100% !important;
	height: 100% !important;
	min-width: 100% !important;
	min-height: 100% !important;
	max-width: none !important;
	max-height: none !important;
	object-fit: cover !important;
	object-position: center center !important;
	transform: scale(1.001);
	transition: transform .75s cubic-bezier(.16, 1, .3, 1), filter .45s ease;
	will-change: transform;
}

.mgp-gallery__item:hover {
	z-index: 3;
	box-shadow: none !important;
	outline: none;
}

.mgp-gallery__item:focus-visible {
	z-index: 3;
	box-shadow: 0 0 0 3px #fff, 0 0 0 6px #bf7950, 0 18px 46px rgba(48, 29, 19, .2) !important;
	outline: none;
}

.mgp-gallery__item:hover .mgp-gallery__image,
.mgp-gallery__item:focus-visible .mgp-gallery__image {
	transform: scale(1.07);
	filter: saturate(.9);
}

.mgp-gallery__item.is-pressed {
	transform: scale(.985);
	transition-duration: .14s;
}

@media (max-width: 767px) {
	.mgp-gallery {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		grid-template-rows: none;
		grid-auto-rows: clamp(135px, 43vw, 230px);
		aspect-ratio: auto;
		min-height: 0;
		max-height: none;
	}

	.mgp-gallery__item {
		grid-column: auto;
		grid-row: auto;
		border-radius: 9px;
	}

	.mgp-gallery__item--1,
	.mgp-gallery__item--5,
	.mgp-gallery__item--6 {
		grid-row: span 2;
	}

}

@media (prefers-reduced-motion: reduce) {
	.mgp-gallery__item,
	.mgp-gallery__image {
		transition-duration: .01ms !important;
		transition-delay: 0ms !important;
	}

	.mgp-gallery__item {
		opacity: 1;
		transform: none;
	}
}

/* Never use native dotted outlines on plugin buttons. */
.mgp-gallery button:focus { outline: none !important; outline-style: none !important; }
.mgp-gallery button:focus-visible { outline: none !important; box-shadow: 0 0 0 3px rgba(191,121,80,.25) !important; }
