/* ==========================================================================
   Galeria com Detalhes — estilos do carrossel e do lightbox
   ========================================================================== */

.gd-gallery {
	position: relative;
	width: 100%;
}

/* ---------- Carrossel ---------- */

.gd-swiper {
	width: 100%;
	overflow: hidden;
	padding-bottom: 8px; /* espaço para a paginação não colar nas imagens */
}

.gd-slide {
	cursor: default;
}

.gd-slide__img-wrap {
	position: relative;
	width: 100%;
	height: 260px; /* sobrescrito pelo controle de estilo do Elementor */
	border-radius: 8px;
	overflow: hidden;
	background: transparent; /* controlável pelo Elementor em Estilo > Imagens */
}

.gd-slide__img-wrap img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.gd-slide__caption {
	margin-top: 8px;
	font-size: 14px;
	line-height: 1.3;
	text-align: center;
}

/* área clicável / lupa quando o lightbox está ativo */
.gd-gallery[data-lightbox="yes"] .gd-slide__img-wrap {
	cursor: zoom-in;
}

.gd-slide__expand {
	position: absolute;
	right: 10px;
	bottom: 10px;
	width: 34px;
	height: 34px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 50%;
	background: rgba(0, 0, 0, 0.45);
	color: #fff;
	opacity: 0;
	transform: translateY(4px);
	transition: opacity 0.2s ease, transform 0.2s ease;
	pointer-events: none;
}

.gd-slide__img-wrap:hover .gd-slide__expand {
	opacity: 1;
	transform: translateY(0);
}

/* Setas de navegação do carrossel (fora do swiper, controladas via JS) */
.gd-swiper-button {
	position: absolute;
	top: 45%;
	transform: translateY(-50%);
	width: 40px;
	height: 40px;
	border-radius: 50%;
	background: rgba(0, 0, 0, 0.45);
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	z-index: 5;
	user-select: none;
	transition: background 0.2s ease, opacity 0.2s ease;
}

.gd-swiper-button:hover {
	background: rgba(0, 0, 0, 0.7);
}

.gd-swiper-button.swiper-button-disabled {
	opacity: 0.35;
	cursor: default;
}

.gd-swiper-button--prev {
	left: -8px;
}

.gd-swiper-button--next {
	right: -8px;
}

.gd-swiper .swiper-pagination-bullet {
	background: #ccc;
	opacity: 1;
}

.gd-swiper .swiper-pagination-bullet-active {
	background: #333;
}

/* ---------- Lightbox ---------- */

.gd-lightbox {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: none;
	align-items: center;
	justify-content: center;
	padding: 24px;
}

.gd-lightbox.is-open {
	display: flex;
}

.gd-lightbox__overlay {
	position: absolute;
	inset: 0;
	background: rgba(10, 10, 10, 0.92);
}

.gd-lightbox__box {
	position: relative;
	width: 100%;
	max-width: 1100px;
	max-height: 90vh;
	z-index: 1;
}

.gd-lightbox__inner {
	display: flex;
	width: 100%;
	max-height: 90vh;
	background: #fff;
	border-radius: 10px;
	overflow: hidden;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.gd-lightbox__inner--right {
	flex-direction: row-reverse;
}

.gd-lightbox__media {
	flex: 1 1 55%;
	background: #ffffff; /* controlável pelo Elementor em Estilo > Lightbox */
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 300px;
	max-height: 90vh;
}

.gd-lightbox__media img {
	width: 100%;
	height: 100%;
	max-height: 90vh;
	object-fit: contain;
	display: block;
}

.gd-lightbox__details {
	flex: 1 1 45%;
	padding: 40px;
	overflow-y: auto;
	display: flex;
	flex-direction: column;
	justify-content: center;
	background: #fff;
}

.gd-lightbox__title {
	margin: 0 0 16px;
	font-size: 26px;
	line-height: 1.25;
	color: #111;
}

.gd-lightbox__desc {
	margin: 0 0 24px;
	font-size: 15px;
	line-height: 1.6;
	color: #555;
	white-space: pre-line;
}

.gd-lightbox__button {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	align-self: flex-start;
	background: none;
	padding: 0;
	border-radius: 0;
	color: #222;
	text-decoration: underline;
	text-underline-offset: 3px;
	font-size: 14px;
	font-weight: 600;
	transition: opacity 0.2s ease;
}

.gd-lightbox__button::before {
	content: '';
	flex: 0 0 auto;
	width: 14px;
	height: 14px;
	background-color: currentColor;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2'%3E%3Cpath d='M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71'/%3E%3Cpath d='M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71'/%3E%3C/svg%3E") no-repeat center / contain;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2'%3E%3Cpath d='M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71'/%3E%3Cpath d='M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71'/%3E%3C/svg%3E") no-repeat center / contain;
}

.gd-lightbox__button:hover {
	opacity: 0.75;
	color: #222;
}

.gd-lightbox__button:empty {
	display: none;
}

/* fechar */
.gd-lightbox__close {
	position: absolute;
	top: -44px;
	right: 0;
	background: transparent;
	border: 0;
	color: #fff;
	cursor: pointer;
	padding: 6px;
	line-height: 0;
	z-index: 2;
}

/* setas do lightbox */
.gd-lightbox__nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	background: transparent;
	border: 0;
	color: #fff;
	cursor: pointer;
	padding: 10px;
	line-height: 0;
	z-index: 2;
}

/* Neutraliza qualquer :hover/:focus que o tema aplique em <button> por padrão
   (ex.: cor de destaque do tema) — o hover real é definido só aqui. */
.gd-lightbox__close:hover,
.gd-lightbox__close:focus,
.gd-lightbox__nav:hover,
.gd-lightbox__nav:focus {
	background-color: rgba(255, 255, 255, 0.15) !important;
	outline: none;
}

.gd-lightbox__nav--prev {
	left: -56px;
}

.gd-lightbox__nav--next {
	right: -56px;
}

body.gd-lightbox-open {
	overflow: hidden;
}

/* ==========================================================================
   Responsivo — Tablet (empilha imagem em cima, texto embaixo)
   ========================================================================== */
@media (max-width: 1024px) {

	.gd-lightbox {
		padding: 16px;
	}

	.gd-lightbox__inner,
	.gd-lightbox__inner--right {
		flex-direction: column;
		max-height: 92vh;
		overflow-y: auto;
	}

	.gd-lightbox__media {
		flex: 0 0 auto;
		max-height: 45vh;
		min-height: 220px;
	}

	.gd-lightbox__media img {
		max-height: 45vh;
	}

	.gd-lightbox__details {
		flex: 1 1 auto;
		padding: 28px;
	}

	.gd-lightbox__nav--prev {
		left: 4px;
	}

	.gd-lightbox__nav--next {
		right: 4px;
	}

	.gd-lightbox__close {
		top: 8px;
		right: 8px;
		background: rgba(0, 0, 0, 0.4);
		border-radius: 50%;
	}
}

/* ==========================================================================
   Responsivo — Mobile
   ========================================================================== */
@media (max-width: 767px) {

	.gd-swiper-button {
		width: 32px;
		height: 32px;
	}

	.gd-swiper-button--prev {
		left: 4px;
	}

	.gd-swiper-button--next {
		right: 4px;
	}

	.gd-lightbox {
		padding: 0;
	}

	.gd-lightbox__box {
		max-width: 100%;
		max-height: 100vh;
	}

	.gd-lightbox__inner {
		border-radius: 0;
		max-height: 100vh;
		height: 100vh;
	}

	.gd-lightbox__media {
		max-height: 38vh;
		min-height: 180px;
	}

	.gd-lightbox__media img {
		max-height: 38vh;
	}

	.gd-lightbox__details {
		padding: 20px;
	}

	.gd-lightbox__title {
		font-size: 20px;
	}

	.gd-lightbox__nav {
		top: auto;
		bottom: 12px;
		transform: none;
		background: rgba(0, 0, 0, 0.45);
		border-radius: 50%;
	}

	.gd-lightbox__nav--prev {
		left: 12px;
	}

	.gd-lightbox__nav--next {
		right: 12px;
	}

	.gd-lightbox__close {
		top: 8px;
		right: 8px;
		background: rgba(0, 0, 0, 0.4);
		border-radius: 50%;
	}
}
