/**
 * A2Z Home Slider Styles
 */

/* Import Inter font */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

.a2z-slider-widget {
	position: relative;
	width: 100%;
	height: 85vh;
	background-color: #0A0A0A;
	overflow: hidden;
	font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
	box-sizing: border-box;
}

/* Skeleton Pulse Animation */
@keyframes a2z-skeleton-pulse {
	0% {
		opacity: 0.15;
	}

	50% {
		opacity: 0.25;
	}

	100% {
		opacity: 0.15;
	}
}

/* Initial Hidden State for entrance animation */
.a2z-slider-hidden,
.a2z-slider-navigation-hidden {
	opacity: 0 !important;
	visibility: hidden !important;
}

@media (max-width: 767px) {
	.a2z-slider-widget {
		height: 85vh;
		min-height: 400px;
		max-height: 100vh;
	}
}

@media (min-width: 768px) {
	.a2z-slider-widget {
		height: 85vh;
	}
}

@media (min-width: 1024px) {
	.a2z-slider-widget {
		height: 85vh;
	}
}

.a2z-slider-container {
	position: relative;
	width: 100%;
	height: 100%;
}

/* Image Layers */
.a2z-slider-images {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
}

.a2z-slider-image-layer {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	opacity: 0;
	/* No CSS transition - GSAP handles all animations */
	/* Images remain in DOM during transitions for smooth crossfade */
	will-change: opacity, transform;
	overflow: hidden;
	/* Ensure image doesn't overflow during Ken Burns */
	/* GSAP will control opacity - CSS is just initial state */
}

/* Skeleton pulse during loading */
.a2z-slider-image-layer::before {
	content: '';
	position: absolute;
	inset: 0;
	background-color: #1a1a1a;
	animation: a2z-skeleton-pulse 1.8s infinite ease-in-out;
	z-index: 1;
	pointer-events: none;
	opacity: 1;
	transition: opacity 0.8s ease-out;
}

.a2z-slider-image-layer.active::before {
	opacity: 0;
	visibility: hidden;
}

.a2z-slider-image-layer.active {
	/* GSAP controls opacity, this is just for initial state */
	opacity: 1;
}

.a2z-slider-bg-image {
	width: 100%;
	height: 100%;
	object-fit: cover !important;
	object-position: center center !important;
	display: block;
	transform-origin: center center;
	will-change: transform, opacity;
	backface-visibility: hidden;
	-webkit-backface-visibility: hidden;
	/* Ensure image fills entire container */
	min-width: 100%;
	min-height: 100%;
}

/* Gradient Overlay */
.a2z-slider-gradient {
	position: absolute;
	inset: 0;
	background: linear-gradient(to bottom, rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.6));
	z-index: 1;
	pointer-events: none;
}

/* Content */
.a2z-slider-content {
	position: relative;
	z-index: 2;
	width: 100%;
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	pointer-events: none;
}

.a2z-slider-content * {
	pointer-events: auto;
}

/* Ensure CTA buttons are always interactive when slide is active */
.a2z-slider-slide-content.active .a2z-slider-cta-button {
	pointer-events: auto !important;
	cursor: pointer !important;
}

.a2z-slider-slide-content {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	pointer-events: none;
	z-index: 1;
	/* Ensure proper stacking */
}

.a2z-slider-slide-content.active {
	opacity: 1;
	pointer-events: auto;
	z-index: 10;
	/* Active slide on top - ensures hover works */
}

.a2z-slider-text-wrapper {
	text-align: center;
	max-width: 90%;
	width: 100%;
	padding: 96px 16px 0 16px;
	/* Desktop: 96px top, 16px horizontal */
	margin-top: -64px;
	/* Desktop: -64px pull-up */
	box-sizing: border-box;
}

/* Tablet: 768px - 1023px */
@media (min-width: 768px) and (max-width: 1023px) {
	.a2z-slider-text-wrapper {
		padding: 84px 24px 0 24px;
		/* Tablet: 84px top, 24px horizontal */
		margin-top: -56px;
		/* Tablet: -56px pull-up */
		max-width: 90%;
	}
}

/* Mobile: <768px */
@media (max-width: 767px) {
	.a2z-slider-text-wrapper {
		padding: 58px 24px 0 24px;
		/* Mobile: 58px top, 24px horizontal */
		margin-top: -40px;
		/* Mobile: -40px pull-up */
		max-width: 100%;
	}
}

/* Heading */
.a2z-slider-heading {
	font-family: 'Inter', sans-serif;
	font-size: 28px;
	/* Mobile default */
	font-weight: 400;
	line-height: 1.375;
	/* Mobile and Tablet */
	color: #ffffff;
	letter-spacing: -0.02em;
	margin: 0 0 24px 0;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	gap: 0;
	word-wrap: break-word;
	overflow-wrap: break-word;
}

/* Tablet: 768px - 1023px */
@media (min-width: 768px) and (max-width: 1023px) {
	.a2z-slider-heading {
		font-size: 52px;
		line-height: 1.375;
	}
}

/* Desktop: â‰¥1024px */
@media (min-width: 1024px) {
	.a2z-slider-heading {
		font-size: 68px;
		line-height: 1.2;
	}
}

/* Mobile: <768px */
@media (max-width: 767px) {
	.a2z-slider-heading {
		font-size: 28px;
		line-height: 1.375;
		margin: 0 0 20px 0;
		padding: 0 10px;
	}

	.a2z-slider-heading-line-2 {
		display: flex;
		flex-direction: row;
		flex-wrap: wrap;
		justify-content: center;
		align-items: baseline;
		gap: 0;
	}
}

.a2z-slider-heading-line-1,
.a2z-slider-heading-line-2 {
	display: block;
	width: 100%;
	text-align: center;
	word-wrap: break-word;
	overflow-wrap: break-word;
}

@media (max-width: 767px) {

	.a2z-slider-heading-line-1,
	.a2z-slider-heading-line-2 {
		width: 100%;
	}
}

.a2z-slider-heading-line-1 {
	margin-bottom: 0;
}

.a2z-slider-heading-line-2 {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: baseline;
	gap: 0.2em;
	white-space: normal;
}

/* Mobile: Keep everything on same line if possible */
@media (max-width: 767px) {
	.a2z-slider-heading-line-2 {
		flex-wrap: nowrap;
		gap: 0;
		white-space: normal;
	}

	.a2z-slider-heading-prefix,
	.a2z-slider-action-word-wrapper,
	.a2z-slider-heading-end {
		display: inline-block;
		white-space: normal;
	}

	.a2z-slider-heading-prefix {
		margin-right: 0.25em;
	}

	.a2z-slider-action-word-wrapper {
		display: inline-block;
		max-width: none;
		width: auto;
		margin-right: 0.25em;
	}

	.a2z-slider-heading-end {
		margin-left: 0;
	}
}

.a2z-slider-heading-prefix,
.a2z-slider-heading-end {
	display: inline-block;
}

.a2z-slider-action-word-wrapper {
	display: inline-block;
	position: relative;
	max-width: 18ch;
	overflow: visible;
	/* Allow movement outside bounds */
}

@media (max-width: 767px) {
	.a2z-slider-action-word-wrapper {
		max-width: none;
		width: auto;
		display: inline-block;
		text-align: left;
	}

	.a2z-slider-action-word {
		font-size: 28px !important;
		/* Same as heading on mobile - match exactly */
		line-height: 1.375;
		/* Match heading line-height */
		white-space: nowrap;
		word-break: normal;
	}
}

.a2z-slider-action-word {
	display: inline-block;
	white-space: nowrap;
	font-family: 'Inter', sans-serif;
	font-size: 28px;
	/* Mobile default */
	font-weight: 400;
	line-height: 1.375;
	/* Match heading line-height on mobile/tablet */
	letter-spacing: -0.02em;
	will-change: transform, opacity;
	/* Optimize for animations */
	transform: translate3d(0, 0, 0);
	/* Force hardware acceleration and enable transforms */
	backface-visibility: hidden;
	/* Prevent flickering */
	-webkit-backface-visibility: hidden;
}

/* Tablet: 768px - 1023px */
@media (min-width: 768px) and (max-width: 1023px) {
	.a2z-slider-action-word {
		font-size: 52px;
		line-height: 1.375;
		/* Match heading line-height */
	}
}

/* Desktop: â‰¥1024px */
@media (min-width: 1024px) {
	.a2z-slider-action-word {
		font-size: 68px;
		line-height: 1.2;
		/* Match heading line-height */
	}
}

/* Subheadline */
.a2z-slider-subheadline {
	font-size: 17px;
	/* Mobile default */
	font-weight: 400;
	color: rgba(255, 255, 255, 0.8);
	margin: 0 0 24px 0;
	max-width: 90%;
	/* Mobile: percentage-based */
	margin-left: auto;
	margin-right: auto;
	word-wrap: break-word;
	overflow-wrap: break-word;
	white-space: normal;
	/* Mobile: allows wrapping */
}

/* Tablet: 768px - 1023px */
@media (min-width: 768px) and (max-width: 1023px) {
	.a2z-slider-subheadline {
		font-size: 16px;
		max-width: 48rem;
		/* 3xl (~768px) */
		white-space: nowrap;
		/* Tablet: single line */
	}
}

/* Desktop: â‰¥1024px */
@media (min-width: 1024px) {
	.a2z-slider-subheadline {
		font-size: 18px;
		max-width: 56rem;
		/* 4xl (~896px) */
		white-space: nowrap;
		/* Desktop: single line */
	}
}

/* Mobile: <768px */
@media (max-width: 767px) {
	.a2z-slider-subheadline {
		font-size: 17px;
		margin: 0 0 24px 0;
		/* Same gap as desktop - no change */
		padding: 0;
		max-width: 90%;
		white-space: normal;
		/* Mobile: allows wrapping */
	}

	.a2z-mobile-break {
		display: block !important;
		margin-top: 4px;
	}
}

/* CTA Button */
.a2z-slider-cta-wrapper {
	margin-top: 24px;
}

.a2z-slider-cta-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0 16px;
	/* Mobile default */
	height: 40px;
	/* Mobile default */
	min-width: 170px;
	border: 1px solid #ffffff;
	border-radius: 9999px;
	background-color: transparent;
	color: #ffffff;
	font-size: 14px;
	font-weight: 400;
	text-transform: uppercase;
	text-decoration: none;
	cursor: pointer;
	transition: background-color 200ms ease, color 200ms ease, border-color 200ms ease;
	box-sizing: border-box;
	white-space: nowrap;
}

/* Tablet: 768px - 1023px */
@media (min-width: 768px) and (max-width: 1023px) {
	.a2z-slider-cta-button {
		height: 44px;
		padding: 0 20px;
	}
}

/* Desktop: â‰¥1024px */
@media (min-width: 1024px) {
	.a2z-slider-cta-button {
		height: 48px;
		padding: 0 24px;
	}
}

/* Mobile: <768px */
@media (max-width: 767px) {
	.a2z-slider-cta-button {
		height: 40px;
		padding: 0 16px;
		min-width: 170px;
		/* Same as desktop - no change */
		font-size: 14px;
		/* Same as desktop - no change */
		width: auto;
		max-width: calc(100% - 32px);
	}

	.a2z-slider-cta-wrapper {
		margin-top: 24px;
		/* Same as desktop - no change */
		padding: 0;
	}
}

/* CTA Button Hover - Desktop/Tablet only (200ms smooth color inversion) */
@media (hover: hover) and (pointer: fine) {

	/* Target all CTA buttons in active slides - ensure highest specificity */
	.a2z-slider-slide-content.active .a2z-slider-cta-button:hover,
	.a2z-slider-slide-content.active .a2z-slider-cta-wrapper .a2z-slider-cta-button:hover,
	.a2z-slider-content .a2z-slider-slide-content.active .a2z-slider-cta-button:hover {
		background-color: #ffffff !important;
		color: #000000 !important;
		border-color: #ffffff !important;
		/* No movement, no scaling, no shadows - just smooth color fill */
	}

	/* Ensure text color changes on hover - highest specificity */
	.a2z-slider-slide-content.active .a2z-slider-cta-button:hover .a2z-slider-cta-text,
	.a2z-slider-slide-content.active .a2z-slider-cta-wrapper .a2z-slider-cta-button:hover .a2z-slider-cta-text,
	.a2z-slider-content .a2z-slider-slide-content.active .a2z-slider-cta-button:hover .a2z-slider-cta-text {
		color: #000000 !important;
	}
}

/* Mobile (touch-only) - no hover effect, immediate navigation on tap */
@media (hover: none) and (pointer: coarse) {}

.a2z-slider-cta-text {
	display: inline-block;
	color: inherit;
	/* Inherit color from parent button */
	transition: color 200ms ease;
	/* Smooth color transition on hover */
	pointer-events: none;
	/* Allow parent button to handle hover */
}

/* Ensure CTA button itself handles all hover events */
.a2z-slider-cta-button {
	pointer-events: auto !important;
}

/* Navigation */
.a2z-slider-navigation {
	position: absolute;
	z-index: 100;
	width: 100%;
	height: 100%;
	pointer-events: none;
	top: 0;
	left: 0;
}

/* Desktop Arrows */
.a2z-slider-arrow {
	position: absolute !important;
	top: 50% !important;
	transform: translateY(-50%) !important;
	width: 48px !important;
	height: 48px !important;
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	background: transparent !important;
	border: none !important;
	cursor: pointer !important;
	color: #ffffff !important;
	pointer-events: auto !important;
	transition: opacity 0.3s ease !important;
	padding: 0 !important;
	margin: 0 !important;
	z-index: 101 !important;
	opacity: 1 !important;
	visibility: visible !important;
	/* Override theme button styles - prevent pink background */
	text-decoration: none !important;
}

.a2z-slider-arrow:hover,
.a2z-slider-arrow:focus,
.a2z-slider-arrow:active {
	background: transparent !important;
	background-color: transparent !important;
	color: #ffffff !important;
	text-decoration: none !important;
	opacity: 0.7 !important;
}

/* Desktop: Blurred circle behind arrow on hover */
@media (min-width: 1024px) and (hover: hover) {
	.a2z-slider-arrow::before {
		content: '';
		position: absolute;
		top: 50%;
		left: 50%;
		transform: translate(-50%, -50%);
		width: 44px;
		height: 44px;
		border-radius: 50%;
		background: rgba(255, 255, 255, 0.15);
		backdrop-filter: blur(12px);
		-webkit-backdrop-filter: blur(12px);
		opacity: 0;
		transition: opacity 0.3s ease;
		pointer-events: none;
		z-index: 0;
	}

	.a2z-slider-arrow svg {
		position: relative;
		z-index: 1;
	}

	.a2z-slider-arrow:hover::before,
	.a2z-slider-arrow:focus::before {
		opacity: 1;
	}
}

.a2z-slider-arrow-prev {
	left: 12px !important;
	right: auto !important;
}

.a2z-slider-arrow-next {
	right: 12px !important;
	left: auto !important;
}

.a2z-slider-arrow svg {
	width: 28px !important;
	height: 28px !important;
	display: block !important;
	flex-shrink: 0 !important;
}

.a2z-slider-arrow svg path {
	stroke: currentColor !important;
	fill: none !important;
	stroke-width: 2 !important;
}

/* Tablet/Mobile Navigation - Arrows move to bottom with dots in between */
@media (max-width: 1023px) {
	.a2z-slider-navigation {
		position: absolute !important;
		bottom: 24px !important;
		left: 50% !important;
		transform: translateX(-50%) !important;
		display: flex !important;
		align-items: center !important;
		justify-content: center !important;
		gap: 16px !important;
		/* 16px gap between elements */
		width: auto !important;
		height: auto !important;
		top: auto !important;
		flex-wrap: nowrap !important;
		z-index: 100 !important;
		padding: 0 20px;
		box-sizing: border-box;
		max-width: 100%;
	}

	/* Reorder: dots in the middle, arrows on sides */
	.a2z-slider-arrow-prev {
		order: 1 !important;
	}

	.a2z-slider-dots {
		order: 2 !important;
	}

	.a2z-slider-arrow-next {
		order: 3 !important;
	}

	.a2z-slider-arrow {
		position: static !important;
		transform: none !important;
		width: 40px !important;
		height: 40px !important;
		top: auto !important;
		left: auto !important;
		right: auto !important;
		flex-shrink: 0 !important;
		opacity: 1 !important;
		visibility: visible !important;
	}

	.a2z-slider-arrow svg {
		width: 24px !important;
		height: 24px !important;
		display: block !important;
		flex-shrink: 0 !important;
	}

	.a2z-slider-arrow svg path {
		stroke: currentColor !important;
		fill: none !important;
		stroke-width: 2 !important;
	}

	/* Disable hover effects on touch devices */
	@media (hover: none) and (pointer: coarse) {

		.a2z-slider-arrow:hover,
		.a2z-slider-arrow:focus {
			opacity: 1 !important;
		}
	}
}

/* Dots */
.a2z-slider-dots {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	pointer-events: auto;
}

/* Desktop: â‰¥1024px - Dots standalone at bottom center */
@media (min-width: 1024px) {
	.a2z-slider-dots {
		position: absolute;
		bottom: 24px;
		left: 50%;
		transform: translateX(-50%);
	}
}

/* Tablet/Mobile: <1024px - Dots between arrows */
@media (max-width: 1023px) {
	.a2z-slider-dots {
		position: static;
		transform: none;
		display: flex;
		align-items: center;
		justify-content: center;
		gap: 8px;
	}
}

@media (max-width: 1023px) {
	.a2z-slider-dots {
		position: static;
		transform: none;
		margin: 0;
	}
}

@media (max-width: 767px) {
	.a2z-slider-dots {
		gap: 6px;
	}

	.a2z-slider-navigation {
		bottom: 20px !important;
		gap: 10px !important;
		padding: 0 16px;
		box-sizing: border-box;
	}
}

.a2z-slider-dot {
	width: 8px !important;
	height: 8px !important;
	border-radius: 50% !important;
	border: none !important;
	background-color: #ffffff !important;
	cursor: pointer !important;
	opacity: 0.4 !important;
	transition: opacity 0.3s ease, transform 0.3s ease !important;
	padding: 0 !important;
	flex-shrink: 0 !important;
	margin: 0 !important;
	/* Override theme button styles - prevent pink background */
	color: transparent !important;
	text-decoration: none !important;
}

/* Override theme hover/focus styles - prevent pink background */
.a2z-slider-dot:hover,
.a2z-slider-dot:focus,
.a2z-slider-dot:active {
	background-color: #ffffff !important;
	color: transparent !important;
	text-decoration: none !important;
	opacity: 1 !important;
	transform: scale(1.1) !important;
}

.a2z-slider-dot.active {
	opacity: 1 !important;
	background-color: #ffffff !important;
	color: transparent !important;
}

.a2z-slider-dot.active:hover,
.a2z-slider-dot.active:focus {
	background-color: #ffffff !important;
	color: transparent !important;
	opacity: 1 !important;
	transform: scale(1.1) !important;
}

/* Elementor Editor Specific */
.elementor-editor-active .a2z-slider-widget {
	min-height: 400px;
}

/* Editor mode adjustments */
.elementor-editor-active .a2z-slider-widget {
	pointer-events: auto;
}

.elementor-editor-active .a2z-slider-slide-content:not(.active) {
	opacity: 0;
	pointer-events: none;
}

.elementor-editor-active .a2z-slider-image-layer:not(.active) {
	opacity: 0;
	/* Keep in DOM for editor preview */
}

/* CRITICAL: All image layers must remain in DOM during transitions */
/* Never use display: none - it breaks Ken Burns animations */
.a2z-slider-image-layer {
	/* Always visible in DOM, opacity controls visibility */
	display: block !important;
}