/* Base Wrapper */
.tc-carousel-wrapper {
	background-color: #222222; /* Default, overridden by Elementor */
	padding: 80px 0;
	position: relative;
	overflow: hidden;
}

.tc-swiper {
	width: 100%;
	padding-bottom: 20px;
}

.tc-swiper .swiper-wrapper {
	align-items: stretch;
}

/* Base Slide */
.tc-swiper .swiper-slide {
	overflow: hidden;
	background: #f7f7f7;
	box-sizing: border-box;
}

/* Image Column */
.tc-image-col {
	position: relative;
}
.tc-image-col img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* Overlay for inactive slides */
.tc-overlay {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.6);
	transition: opacity 0.5s ease;
	z-index: 1;
}
.tc-swiper .swiper-slide-active .tc-overlay {
	opacity: 0;
}

/* Text Column */
.tc-text-col {
	background: #f7f7f7;
	display: flex;
	flex-direction: column;
	justify-content: center;
	z-index: 2;
	overflow: hidden; /* Prevent overall column from scrolling */
}

.tc-text-inner {
	width: 100%;
	display: flex;
	flex-direction: column;
	max-height: 100%;
	overflow: hidden;
}

/* Typography */
.tc-title {
	font-size: 24px;
	font-weight: 800;
	color: #1c2b4d;
	margin: 0 0 10px;
	line-height: 1.3;
	flex-shrink: 0;
}
.tc-subtitle {
	font-size: 16px;
	font-weight: 700;
	color: #6b7280;
	margin: 0 0 20px;
	line-height: 1.4;
	flex-shrink: 0;
}
.tc-content {
	font-size: 15px;
	color: #6b7280;
	line-height: 1.7;
	flex-grow: 1;
	overflow-y: auto;
	padding-right: 5px; /* Space for scrollbar */
}
/* Scrollbar styling for content */
.tc-content::-webkit-scrollbar {
	width: 4px;
}
.tc-content::-webkit-scrollbar-thumb {
	background: #dddddd;
	border-radius: 4px;
}

.tc-content p {
	margin-bottom: 15px;
}
.tc-content p:last-child {
	margin-bottom: 0;
}

/* Desktop Styles */
@media (min-width: 768px) {
	.tc-swiper .swiper-slide {
		width: 1000px; /* Fixed width prevents Swiper loop offset bugs */
		height: var(--tc-carousel-height, 420px);
		position: relative;
		border-radius: 0;
	}
	
	/* On desktop, image covers the entire slide */
	.tc-image-col {
		position: absolute;
		inset: 0;
		width: 100%;
		height: 100%;
	}
	
	/* Text overlays on the right half of the slide */
	.tc-text-col {
		position: absolute;
		right: 0;
		top: 0;
		bottom: 0;
		width: 50%;
		padding: 40px 50px;
		opacity: 0;
		visibility: hidden;
		transform: translateX(20px);
		transition: all 0.5s ease;
	}
	.tc-swiper .swiper-slide-active .tc-text-col {
		opacity: 1;
		visibility: visible;
		transform: translateX(0);
	}

	/* Navigation Arrows */
	.tc-nav {
		position: absolute;
		top: 50%;
		transform: translateY(-50%);
		width: 40px;
		height: 40px;
		display: flex;
		align-items: center;
		justify-content: center;
		z-index: 10;
		cursor: pointer;
		opacity: 0.8;
		transition: opacity 0.3s;
	}
	.tc-nav:hover {
		opacity: 1;
	}
	
	/* Absolute positioning for arrows so they sit on the inactive slides */
	.tc-nav-prev {
		left: calc(50% - 580px); /* Adjust based on active slide width + gap */
	}
	.tc-nav-next {
		right: calc(50% - 580px);
	}
}

/* Mobile Styles */
@media (max-width: 767px) {
	.tc-carousel-wrapper {
		padding: 40px 0;
	}
	.tc-swiper .swiper-slide {
		width: 85%;
		height: var(--tc-carousel-height, auto);
		display: flex;
		flex-direction: column;
		border-radius: 12px;
		padding: 15px;
		background: #ffffff; /* White card background */
		transition: transform 0.4s ease, opacity 0.4s ease;
	}
	
	/* Inactive scale & opacity on mobile */
	.tc-swiper .swiper-slide:not(.swiper-slide-active) {
		opacity: 0.5;
		transform: scale(0.95);
	}
	
	.tc-image-col {
		width: 100%;
		height: var(--tc-image-height, 250px);
		border-radius: 8px;
		overflow: hidden;
		position: relative;
		flex-shrink: 0;
	}
	
	/* Hide dark overlay completely on mobile (relying on slide opacity) */
	.tc-overlay {
		display: none;
	}
	
	.tc-text-col {
		width: 100%;
		flex-grow: 1; /* Stretch to fill remaining height in fixed cards */
		padding: 25px 5px 10px;
		position: relative;
		opacity: 1;
		visibility: visible;
		transform: none;
		background: transparent;
		overflow: hidden; /* Scroll is handled by inner .tc-content now */
	}
	
	.tc-title {
		font-size: 22px;
	}
	.tc-subtitle {
		font-size: 15px;
	}
	.tc-content {
		font-size: 14px;
	}
	
	/* Hide arrows on mobile */
	.tc-nav {
		display: none;
	}
}

/* Pagination Dots */
.tc-carousel-wrapper .tc-pagination {
	position: absolute;
	bottom: 25px;
	left: 0;
	width: 100%;
	text-align: center;
	z-index: 10;
}
.tc-carousel-wrapper .swiper-pagination-bullet {
	width: 8px;
	height: 8px;
	background: #cccccc;
	opacity: 0.7;
	margin: 0 5px;
	transition: all 0.3s;
}
.tc-carousel-wrapper .swiper-pagination-bullet-active {
	opacity: 1;
	background-color: #da2424 !important; 
}
