/* YU Gallery – Modal Style */

.yu-gallery-lock { 
	overflow: hidden; 
}

.yu-gallery {
	position: fixed;
	inset: 0;
	z-index: 999999; /* por encima del header de Divi */
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	background: rgba(0, 0, 0, .6);
	opacity: 0;
	visibility: hidden;
	transition: opacity .25s, visibility .25s;
}

.yu-gallery.is-open { 
	opacity: 1; 
	visibility: visible; 
}

.yu-gallery__dialog {
	position: relative;
	width: 100%;
	max-width: 1240px;
	max-height: 100%;
	overflow: auto;
	background: #fff;
	border-radius: 24px;
	padding: 36px;
	box-sizing: border-box;
}

.yu-gallery__close {
	position: absolute;
	top: 24px;
	right: 24px;
	width: 44px;
	height: 44px;
	border: 1px solid #ddd;
	border-radius: 50%;
	background: #fff;
	cursor: pointer;
	display: grid;
	place-items: center;
}

.yu-gallery__header { 
	margin-bottom: 22px; 
	padding-right: 60px; 
}

.yu-gallery__title {
	margin: 0 0 14px;
	padding: 0;
	font-family: 'Playfair Display', Georgia, serif; /* cambia por la fuente de tu tema */
	font-size: clamp(24px, 3vw, 36px);
	font-weight: 400;
	line-height: 1.2;
	color: #111;
}

.yu-gallery__meta {
	margin: 0;
	padding: 0;
	font-size: 11px;
	font-family: "Barlow", sans-serif;
    font-weight: 600;
    font-style: normal;
	letter-spacing: .15em;
	text-transform: uppercase;
	color: #555;
}

.yu-gallery__stage {
	position: relative;
	height: min(55vh, 480px);
	background: #d9d9d9;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
}

.yu-gallery__image {
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: 100%;
	object-fit: contain;
	display: block;
}

.yu-gallery__nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 48px;
	height: 48px;
	border: 0;
	border-radius: 50%;
	background: #fff;
	box-shadow: 0 2px 8px rgba(0, 0, 0, .15);
	cursor: pointer;
	display: grid;
	place-items: center;
}

.yu-gallery__nav--prev { 
	left: 20px; 
}

.yu-gallery__nav--next { 
	right: 20px; 
}

.yu-gallery__nav:disabled { 
	display: none; 
}

.yu-gallery svg {
	width: 20px;
	height: 20px;
	fill: none;
	stroke: #111;
	stroke-width: 1.8;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.yu-gallery__counter {
	position: absolute;
	right: 20px;
	bottom: 20px;
	padding: 5px 14px;
	border-radius: 999px;
	background: #fff;
	font-size: 11px;
	letter-spacing: .1em;
	color: #7a1f1f;
}

.yu-gallery__thumbs {
	display: flex;
	gap: 12px;
	margin-top: 24px;
	padding-bottom: 8px;
	overflow-x: auto;
	scroll-behavior: smooth;
}

.yu-gallery__thumb {
	flex: 0 0 104px;
	height: 64px;
	padding: 0;
	border: 0;
	background: #eee;
	cursor: pointer;
	opacity: .55;
	transition: opacity .2s;
}

.yu-gallery__thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.yu-gallery__thumb:hover,
.yu-gallery__thumb.is-active { 
	opacity: 1; 
}

.yu-gallery button:focus-visible { 
	outline: 2px solid #111; 
	outline-offset: 2px; 
}

@media (max-width: 768px) {

	.yu-gallery { 
		padding: 20px;
	}

	.yu-gallery__dialog { 
		padding: 36px; 
		border-radius: 24px;
		min-height: 100%; 
	}

	.yu-gallery__close { 
		top: 16px; 
		right: 16px; 
	}

	.yu-gallery__stage { 
		height: 50vh; 
	}

	.yu-gallery__nav { 
		width: 40px; 
		height: 40px; 
	}

	.yu-gallery__nav--prev { 
		left: 10px; 
	}

	.yu-gallery__nav--next { 
		right: 10px; 
	}

	.yu-gallery__thumb { 
		flex-basis: 80px; 
		height: 52px; 
	}

}

@media (prefers-reduced-motion: reduce) {
  
	.yu-gallery, .yu-gallery__thumbs { 
		transition: none; 
		scroll-behavior: auto; 
	}

}
