/**
 * BK Tech Slider Banner CSS
 * Author: Bùi Đức Hạnh (https://buhaweb.com/)
 * Prefix: bdh-bk-
 * Kit 4 Global Design System Compliant
 */

/* ====================================================
   SLIDER CONTAINER & CLS OPTIMIZATION
   ==================================================== */
.bdh-bk-slider-banner {
	position: relative;
	width: 100%;
	box-sizing: border-box;
	contain: paint layout;
}

.bdh-bk-slider-banner__container {
	position: relative;
	width: 100%;
	overflow: hidden;
	list-style: none;
	padding: 0;
	margin: 0;
	z-index: 1;
	display: block;
	box-sizing: border-box;
}

/* FOUC & CLS Fix: Reserve space and hide trailing slides before Swiper initializes */
.bdh-bk-slider-banner__container:not(.swiper-initialized) .swiper-wrapper {
	display: flex;
	width: 100%;
	overflow: hidden;
}

.bdh-bk-slider-banner__container:not(.swiper-initialized) .bdh-bk-slider-banner__slide {
	flex-shrink: 0;
	width: 100%;
}

.bdh-bk-slider-banner__container:not(.swiper-initialized) .bdh-bk-slider-banner__slide:not(:first-child) {
	display: none;
}

/* Default responsive heights when height_mode is custom */
.bdh-bk-slider-banner--custom-height .bdh-bk-slider-banner__container,
.bdh-bk-slider-banner--custom-height .bdh-bk-slider-banner__slide {
	height: 500px;
}

@media (max-width: 1024px) {
	.bdh-bk-slider-banner--custom-height .bdh-bk-slider-banner__container,
	.bdh-bk-slider-banner--custom-height .bdh-bk-slider-banner__slide {
		height: 380px;
	}
}

@media (max-width: 767px) {
	.bdh-bk-slider-banner--custom-height .bdh-bk-slider-banner__container,
	.bdh-bk-slider-banner--custom-height .bdh-bk-slider-banner__slide {
		height: 240px;
	}
}

/* ====================================================
   SLIDE ITEMS & MEDIA
   ==================================================== */
.bdh-bk-slider-banner__slide {
	position: relative;
	overflow: hidden;
	box-sizing: border-box;
	display: flex;
	align-items: center;
	justify-content: center;
}

.bdh-bk-slider-banner__link,
.bdh-bk-slider-banner__media {
	display: block;
	position: relative;
	width: 100%;
	height: 100%;
	text-decoration: none;
	color: inherit;
	overflow: hidden;
}

.bdh-bk-slider-banner__image {
	display: block;
	width: 100%;
	height: 100%;
	max-width: 100%;
	object-fit: cover;
	object-position: center center;
	transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
	transform: translateZ(0);
	backface-visibility: hidden;
}

/* Optional Overlay on slides */
.bdh-bk-slider-banner__overlay {
	position: absolute;
	inset: 0;
	pointer-events: none;
	z-index: 2;
	transition: background-color 0.3s ease;
}

/* ====================================================
   CAPTION / CONTENT OVERLAY
   ==================================================== */
.bdh-bk-slider-banner__caption {
	position: absolute;
	inset: 0;
	z-index: 3;
	display: flex;
	box-sizing: border-box;
	padding: 40px;
	pointer-events: none;
}

.bdh-bk-slider-banner__caption-content {
	max-width: 650px;
	pointer-events: auto;
}

.bdh-bk-slider-banner__title {
	font-size: var(--e-global-typography-e47b9d8-font-size, 38px);
	font-weight: var(--e-global-typography-e47b9d8-font-weight, 700);
	line-height: var(--e-global-typography-e47b9d8-line-height, 1.3em);
	color: var(--e-global-color-8d5d81d, #FFFFFF);
	margin: 0 0 10px 0;
	text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.bdh-bk-slider-banner__subtitle {
	font-size: var(--e-global-typography-afd6f4d-font-size, 16px);
	font-weight: var(--e-global-typography-afd6f4d-font-weight, 400);
	line-height: var(--e-global-typography-afd6f4d-line-height, 1.65em);
	color: var(--e-global-color-14ec4f2, #F8F9FA);
	margin: 0;
	text-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
}

/* Vertical & Horizontal alignment helpers */
.bdh-bk-slider-banner__caption--top { align-items: flex-start; }
.bdh-bk-slider-banner__caption--middle { align-items: center; }
.bdh-bk-slider-banner__caption--bottom { align-items: flex-end; }

.bdh-bk-slider-banner__caption--left { justify-content: flex-start; text-align: left; }
.bdh-bk-slider-banner__caption--center { justify-content: center; text-align: center; }
.bdh-bk-slider-banner__caption--right { justify-content: flex-end; text-align: right; }

/* ====================================================
   NAVIGATION ARROWS
   ==================================================== */
.bdh-bk-slider-arrow {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 10;
	width: 44px;
	height: 44px;
	padding: 0 !important;
	margin: 0;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border: 1px solid transparent;
	background-color: rgba(31, 42, 68, 0.5); /* Navy transparent */
	color: var(--e-global-color-8d5d81d, #FFFFFF);
	border-radius: 50%;
	cursor: pointer;
	outline: none;
	transition: all 0.25s ease;
	line-height: 1;
	box-sizing: border-box;
}

.bdh-bk-slider-arrow i,
.bdh-bk-slider-arrow svg {
	font-size: 18px;
	width: 1em;
	height: 1em;
	pointer-events: none;
}

.bdh-bk-slider-arrow:hover {
	background-color: var(--e-global-color-938e6c1, #2A9150);
	color: var(--e-global-color-8d5d81d, #FFFFFF);
	transform: translateY(-50%) scale(1.08);
}

.bdh-bk-slider-arrow--prev {
	left: 16px;
}

.bdh-bk-slider-arrow--next {
	right: 16px;
}

.bdh-bk-slider-arrow.swiper-button-disabled {
	opacity: 0.3;
	cursor: not-allowed;
	pointer-events: none;
}

/* ====================================================
   PAGINATION DOTS
   ==================================================== */
.bdh-bk-slider-pagination {
	position: absolute;
	bottom: 16px;
	left: 0;
	right: 0;
	z-index: 10;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 0;
	margin: 0;
	pointer-events: none;
}

.bdh-bk-slider-pagination.swiper-pagination-bullets {
	bottom: 16px;
}

.bdh-bk-slider-pagination--outside {
	position: relative;
	bottom: auto;
	margin-top: 14px;
}

.bdh-bk-slider-pagination .swiper-pagination-bullet {
	display: inline-block;
	width: 10px;
	height: 10px;
	padding: 0;
	margin: 0 !important;
	border: none;
	border-radius: 20px;
	background-color: rgba(255, 255, 255, 0.55);
	cursor: pointer;
	pointer-events: auto;
	transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
	opacity: 1;
	outline: none;
}

.bdh-bk-slider-pagination--outside .swiper-pagination-bullet {
	background-color: var(--e-global-color-fcc82ce, #E5E7EB);
}

.bdh-bk-slider-pagination .swiper-pagination-bullet-active {
	width: 26px;
	background-color: var(--e-global-color-1070229, #2CAC55);
	border-radius: 20px;
}

/* Hide navigation on mobile if configured */
@media (max-width: 767px) {
	.bdh-bk-slider-banner--hide-arrows-mobile .bdh-bk-slider-arrow {
		display: none !important;
	}
	
	.bdh-bk-slider-banner__caption {
		padding: 20px;
	}
	
	.bdh-bk-slider-banner__title {
		font-size: var(--e-global-typography-8dc9564-font-size, 24px);
	}
}
