.tekne-galeri {
	position: relative;
	width: 100%;
	max-width: 100%;
	margin: 0;
	padding: 0;
}

.tekne-galeri__grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 4px;
	width: 100%;
}

.tekne-galeri__cell {
	position: relative;
	display: block;
	margin: 0;
	padding: 0;
	border: 0;
	background: transparent;
	border-radius: 10px;
	overflow: hidden;
	cursor: pointer;
	aspect-ratio: 4 / 3;
	line-height: 0;
	transition: opacity 0.2s ease;
}

.tekne-galeri__cell:hover,
.tekne-galeri__cell:focus-visible {
	opacity: 0.92;
	outline: none;
}

.tekne-galeri__image {
	position: absolute;
	inset: 0;
	display: block;
	width: 100% !important;
	height: 100% !important;
	max-width: none !important;
	max-height: none !important;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: inherit;
	object-fit: cover;
	object-position: center center;
}

.tekne-galeri--match-height {
	display: flex;
	flex-direction: column;
	min-height: 0;
}

.tekne-galeri--match-height .tekne-galeri__grid {
	flex: 1;
	height: 100%;
	min-height: 0;
	grid-template-rows: repeat(2, minmax(0, 1fr));
}

.tekne-galeri--match-height .tekne-galeri__cell {
	aspect-ratio: auto;
	height: 100%;
	min-height: 0;
}

.single-tekneler .elementor-section:has(.tekne-galeri--match-height) > .elementor-container,
.single-tekneler .e-con:has(.tekne-galeri--match-height) {
	align-items: stretch !important;
}

.single-tekneler .elementor-column:has(.tekne-galeri--match-height),
.single-tekneler .e-con.e-child:has(.tekne-galeri--match-height) {
	display: flex;
	flex-direction: column;
}

.single-tekneler .elementor-widget-shortcode:has(.tekne-galeri--match-height),
.single-tekneler .elementor-widget-text-editor:has(.tekne-galeri--match-height) {
	flex: 1;
	display: flex;
	flex-direction: column;
	min-height: 0;
}

.single-tekneler .elementor-section:has(.tekne-galeri--match-height) .elementor-widget-theme-post-featured-image img {
	width: 100%;
	height: auto;
	display: block;
	object-fit: cover;
}

.tekne-galeri__more {
	position: absolute;
	right: 8px;
	bottom: 8px;
	z-index: 2;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 40px;
	padding: 0 16px;
	border: 0;
	border-radius: 999px;
	background: rgba(15, 23, 42, 0.88);
	color: #fff;
	font-size: 14px;
	font-weight: 600;
	line-height: 1;
	cursor: pointer;
	box-shadow: 0 10px 24px rgba(15, 23, 42, 0.24);
	transition: background 0.2s ease, transform 0.2s ease;
}

.tekne-galeri__more:hover,
.tekne-galeri__more:focus-visible {
	background: rgba(15, 23, 42, 0.96);
	transform: translateY(-1px);
	outline: none;
	color: #fff;
}

/* Mobil Swiper */
.tekne-galeri__swiper-wrap {
	display: none;
}

.tekne-galeri__swiper {
	position: relative;
	width: 100%;
	overflow: hidden;
	border-radius: 12px;
}

.tekne-galeri__swiper .swiper-slide {
	height: auto;
}

.tekne-galeri__swiper .tekne-galeri__cell {
	width: 100%;
	aspect-ratio: 4 / 3;
	border-radius: 12px;
}

.tekne-galeri__pagination {
	position: static !important;
	margin-top: 10px;
}

.tekne-galeri__pagination .swiper-pagination-bullet {
	width: 8px;
	height: 8px;
	background: rgba(15, 23, 42, 0.25);
	opacity: 1;
}

.tekne-galeri__pagination .swiper-pagination-bullet-active {
	background: rgba(15, 23, 42, 0.88);
}

.tekne-galeri__nav {
	position: absolute;
	top: 50%;
	z-index: 2;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.92);
	color: #0f172a;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
	transform: translateY(-50%);
	box-shadow: 0 8px 20px rgba(15, 23, 42, 0.18);
}

.tekne-galeri__nav--prev {
	left: 10px;
}

.tekne-galeri__nav--next {
	right: 10px;
}

.tekne-galeri__nav.swiper-button-disabled {
	opacity: 0.35;
	cursor: not-allowed;
}

body.tekne-galeri-lightbox-open {
	overflow: hidden;
}

.tekne-galeri-lightbox {
	position: fixed;
	inset: 0;
	z-index: 99999;
	display: none;
	align-items: center;
	justify-content: center;
	padding: 24px;
	background: rgba(8, 12, 20, 0.92);
}

.tekne-galeri-lightbox.is-open {
	display: flex;
}

.tekne-galeri-lightbox__dialog {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	width: min(100%, 1100px);
	max-height: calc(100vh - 48px);
}

.tekne-galeri-lightbox__image-wrap {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	max-height: calc(100vh - 120px);
}

.tekne-galeri-lightbox__image {
	display: block;
	max-width: 100%;
	max-height: calc(100vh - 120px);
	width: auto;
	height: auto;
	border-radius: 12px;
	object-fit: contain;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
}

.tekne-galeri-lightbox__counter {
	margin-top: 14px;
	color: rgba(255, 255, 255, 0.88);
	font-size: 14px;
	font-weight: 500;
}

.tekne-galeri-lightbox__close,
.tekne-galeri-lightbox__nav {
	position: absolute;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	border: 0;
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.14);
	color: #fff;
	font-size: 28px;
	line-height: 1;
	cursor: pointer;
	transition: background 0.2s ease;
}

.tekne-galeri-lightbox__close:hover,
.tekne-galeri-lightbox__close:focus-visible,
.tekne-galeri-lightbox__nav:hover,
.tekne-galeri-lightbox__nav:focus-visible {
	background: rgba(255, 255, 255, 0.24);
	outline: none;
}

.tekne-galeri-lightbox__close {
	top: 16px;
	right: 16px;
	font-size: 32px;
}

.tekne-galeri-lightbox__nav {
	top: 50%;
	transform: translateY(-50%);
}

.tekne-galeri-lightbox__nav--prev {
	left: 16px;
}

.tekne-galeri-lightbox__nav--next {
	right: 16px;
}

.tekne-galeri-lightbox__nav:disabled {
	opacity: 0.35;
	cursor: not-allowed;
}

@media (max-width: 767px) {
	.tekne-galeri--mobile-swiper .tekne-galeri__grid,
	.tekne-galeri--mobile-swiper .tekne-galeri__more {
		display: none !important;
	}

	.tekne-galeri--mobile-swiper .tekne-galeri__swiper-wrap {
		display: block;
	}

	.tekne-galeri--mobile-swiper.tekne-galeri--match-height {
		height: auto !important;
	}

	.tekne-galeri__grid {
		gap: 3px;
	}

	.tekne-galeri__more {
		right: 6px;
		bottom: 6px;
		min-height: 36px;
		padding: 0 14px;
		font-size: 13px;
	}

	.tekne-galeri-lightbox {
		padding: 12px;
	}

	.tekne-galeri-lightbox__close {
		top: 8px;
		right: 8px;
	}

	.tekne-galeri-lightbox__nav--prev {
		left: 8px;
	}

	.tekne-galeri-lightbox__nav--next {
		right: 8px;
	}
}
