/**
 * Property Gallery Carousel Styles
 *
 * @package    Connect CRM Real State
 * @author     David Perez
 * @copyright  2023 Closemarketing
 */

/* Gallery Container */
.ccrmre-property-gallery {
	max-width: 100%;
	margin: 0 auto 30px;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, sans-serif;
}

/* Main Slider */
.ccrmre-gallery-main {
	position: relative;
	width: 100%;
	aspect-ratio: 16 / 9;
	background: #000;
	border-radius: 8px;
	overflow: hidden;
	margin-bottom: 15px;
}

.ccrmre-gallery-slider {
	width: 100%;
	height: 100%;
	position: relative;
}

.ccrmre-gallery-slide {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	opacity: 0;
	transition: opacity 0.5s ease-in-out;
	display: flex;
	align-items: center;
	justify-content: center;
}

.ccrmre-gallery-slide.active {
	opacity: 1;
	z-index: 1;
}

.ccrmre-gallery-slide img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	display: block;
}

/* Navigation Buttons */
.ccrmre-gallery-prev,
.ccrmre-gallery-next {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	background: rgba(0, 0, 0, 0.5);
	color: #fff;
	border: none;
	width: 50px;
	height: 50px;
	border-radius: 50%;
	font-size: 30px;
	line-height: 1;
	cursor: pointer;
	z-index: 10;
	transition: all 0.3s ease;
	display: flex;
	align-items: center;
	justify-content: center;
}

.ccrmre-gallery-prev:hover,
.ccrmre-gallery-next:hover {
	background: rgba(0, 0, 0, 0.8);
	transform: translateY(-50%) scale(1.1);
}

.ccrmre-gallery-prev {
	left: 15px;
}

.ccrmre-gallery-next {
	right: 15px;
}

.ccrmre-gallery-prev span,
.ccrmre-gallery-next span {
	display: block;
	line-height: 1;
}

/* Counter */
.ccrmre-gallery-counter {
	position: absolute;
	bottom: 15px;
	right: 15px;
	background: rgba(0, 0, 0, 0.7);
	color: #fff;
	padding: 8px 15px;
	border-radius: 20px;
	font-size: 14px;
	z-index: 10;
	font-weight: 500;
}

/* Thumbnails */
.ccrmre-gallery-thumbnails {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
	gap: 10px;
	padding: 5px;
	background: #f5f5f5;
	border-radius: 8px;
}

.ccrmre-gallery-thumb {
	width: 100%;
	height: 80px;
	cursor: pointer;
	border-radius: 4px;
	overflow: hidden;
	border: 3px solid transparent;
	transition: all 0.3s ease;
	position: relative;
}

.ccrmre-gallery-thumb:hover {
	transform: scale(1.05);
	border-color: #666;
}

.ccrmre-gallery-thumb.active {
	border-color: #0073aa;
	box-shadow: 0 0 10px rgba(0, 115, 170, 0.3);
}

.ccrmre-gallery-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* Responsive */
@media (max-width: 768px) {
	.ccrmre-gallery-main {
		aspect-ratio: 4 / 3;
	}

	.ccrmre-gallery-prev,
	.ccrmre-gallery-next {
		width: 40px;
		height: 40px;
		font-size: 24px;
	}

	.ccrmre-gallery-prev {
		left: 10px;
	}

	.ccrmre-gallery-next {
		right: 10px;
	}

	.ccrmre-gallery-counter {
		bottom: 10px;
		right: 10px;
		font-size: 12px;
		padding: 6px 12px;
	}

	.ccrmre-gallery-thumbnails {
		grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
		gap: 8px;
	}

	.ccrmre-gallery-thumb {
		height: 60px;
	}
}

@media (max-width: 480px) {
	.ccrmre-gallery-main {
		aspect-ratio: 1 / 1;
		border-radius: 4px;
	}

	.ccrmre-gallery-thumbnails {
		grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
		gap: 6px;
		border-radius: 4px;
	}

	.ccrmre-gallery-thumb {
		height: 50px;
	}
}

