/**
 * Custom Hero Slider Styles
 * Namespaced under .custom-hero-slider to avoid Elementor conflicts
 */

/* ============================================
   CSS Variables
   ============================================ */
.custom-hero-slider {
	--chs-overlay-color: rgba(0, 0, 0, 0.4);
	--chs-text-color: #ffffff;
	--chs-primary-color: #ffffff;
	--chs-primary-hover: #f0f0f0;
	--chs-transition-speed: 0.3s;
	--chs-font-title: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
	--chs-font-subtitle: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* ============================================
   1. Main Slider Container
   ============================================ */
.custom-hero-slider {
	height: 100%;
	min-height: 400px;
	max-height: 100%;
	position: relative;
	overflow: hidden;
	margin: 0;
	padding: 0;
	border-radius: 1rem;
}

/* ============================================
   2. Swiper Wrapper & Slides
   ============================================ */
.custom-hero-slider .swiper-wrapper {
	display: flex;
	height: 100%;
	width: 100%;
}

.custom-hero-slider .swiper-slide {
	flex-shrink: 0;
	width: 100%;
	height: 100%;
	position: relative;
	overflow: hidden;
}

/* ============================================
   3. Media Layer
   ============================================ */
.custom-hero-slider .hero-slider-media {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: 1;
}

.custom-hero-slider .hero-slider-media.hero-slider-media-image {
	background-size: cover;
	background-position: center;
	background-repeat: no-repeat;
}

.custom-hero-slider .hero-slider-media video {
	position: absolute;
	top: 50%;
	left: 50%;
	min-width: 100%;
	min-height: 100%;
	width: auto;
	height: auto;
	transform: translate(-50%, -50%);
	object-fit: cover;
}

/* ============================================
   4. Dark Overlay
   ============================================ */
.custom-hero-slider .hero-slider-overlay {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background-color: var(--chs-overlay-color);
	z-index: 2;
	pointer-events: none;
}

/* ============================================
   5. 2x2 Grid Layout
   ============================================ */
.custom-hero-slider .hero-slider-grid {
	display: grid;
	grid-template-columns: 1.5fr 1fr;
	grid-template-rows: 1fr 1fr;
	width: 100%;
	height: 100%;
	gap: 0;
	position: relative;
	z-index: 3;
}

/* ============================================
   6. Content Quadrant (Bottom-Left)
   ============================================ */
.custom-hero-slider .hero-slider-content {
	grid-area: 2 / 1 / 3 / 2;
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	align-items: flex-start;
	padding: 4rem;
	color: var(--chs-text-color);
    position: relative;
}

/* Content inner container */
.custom-hero-slider .hero-slider-content-inner {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
}

/* Title styles */
.custom-hero-slider .hero-slider-title {
	font-family: "vinila-condensed", sans-serif !important;
	font-weight: 700 !important;
	font-size: 5rem;
	line-height: 5rem;
	color: #FFFFFF;
	margin-bottom: 1rem;
    position: relative;
}

/* Subtitle styles */
.custom-hero-slider .hero-slider-subtitle {
	font-family: "vinila-condensed", sans-serif !important;
	font-size: 1.2rem;
	font-weight: 400;
	color: #FFFFFF;
	margin-bottom: 3rem;
}

/* Image styles */
.custom-hero-slider .hero-slider-image {
	margin-bottom: 1.5rem;
}

.custom-hero-slider .hero-slider-image img {
	max-width: 100%;
	height: auto;
}

/* Button styles */
.custom-hero-slider .hero-slider-button a {
	background-color: #134265 !important;
	border-radius: 2rem;
	padding: 0.4rem 0.4rem 0.4rem 1rem;
	color: #FFF !important;
	font-weight: 500;
	text-decoration: none;
	display: inline-flex;
	align-items: center;
	transition: background 0.3s ease;
}

.custom-hero-slider .hero-slider-button a:hover {
	background-color: #43B1FE !important;
}

/* Button icon styles */
.custom-hero-slider .hero-slider-button-icon {
	background-color: #fff;
	border-radius: 2rem;
	padding: 0.8rem;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	margin-left: 0.5rem;
	width: 48px;
	height: 48px;
}


.custom-hero-slider .hero-slider-button .hero-slider-button-content {
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.custom-hero-slider .hero-slider-button-icon svg {
	width: 25px;
	height: 18px;
}

/* Button text styles */
.custom-hero-slider .hero-slider-button-text {
	font-family: "vinila-condensed", sans-serif;
	font-size: 1rem;
}


/* ============================================
   7. Navigation (Fixed on Container)
   ============================================ */
.custom-hero-slider .hero-slider-navigation {
	position: absolute;
	bottom: 4rem;
	right: 4rem;
	z-index: 50;
	display: flex;
	gap: 10px;
}

/* ============================================
   8. Empty Quadrants
   ============================================ */
.custom-hero-slider .hero-slider-empty-bottom-left {
	grid-area: 2 / 1 / 3 / 2;
}

.custom-hero-slider .hero-slider-empty-top-right {
	grid-area: 1 / 2 / 2 / 3;
	display: flex;
	align-items: center;
	justify-content: center;
}

/* Static slide image positioned at right of h1 title */
.custom-hero-slider .hero-slider-static-image {
	max-width: 100%;
	height: auto;
	max-height: 300px;
	object-fit: contain;
    position: absolute;
    top: -7rem;
    right: -7rem;
}

/* ============================================
   9. Navigation Buttons
   ============================================ */
.custom-hero-slider .hero-slider-nav-button {
	display: flex;
	align-items: center;
	justify-content: center;
	background: #F3EFE9;
	border: 0;
	padding: 10px !important;
	border-radius: 50%;
	transition: background 0.3s ease;
	z-index: 50;
	cursor: pointer;
}

/* Navigation button icon */
.custom-hero-slider .hero-slider-nav-button-icon {
	display: block;
	width: 26px;
	height: 26px;
	background-image: url('https://hopinportugal.com/wp-content/uploads/2025/12/icons-1.svg');
	background-size: contain;
	background-repeat: no-repeat;
	background-position: center;
	transition: background-image 0.3s ease;
}

/* Previous button rotation */
.custom-hero-slider .hero-slider-prev {
	transform: rotate(-135deg);
}

/* Next button rotation */
.custom-hero-slider .hero-slider-next {
	transform: rotate(45deg);
}

/* Hover effect - change icon */
.custom-hero-slider .hero-slider-nav-button:hover {
	background: #43B1FE;
}

.custom-hero-slider .hero-slider-nav-button:hover .hero-slider-nav-button-icon {
	background-image: url('https://hopinportugal.com/wp-content/uploads/2025/10/icons.png');
}

/* Disabled state */
.custom-hero-slider .hero-slider-nav-button.swiper-button-disabled {
	opacity: 0.3;
	cursor: not-allowed;
}

.custom-hero-slider .hero-slider-nav-button.swiper-button-disabled:hover {
	background: #F3EFE9;
	transform: none;
}

.custom-hero-slider .hero-slider-nav-button.swiper-button-disabled:hover .hero-slider-nav-button-icon {
	background-image: url('https://hopinportugal.com/wp-content/uploads/2025/12/icons-1.svg');
}

/* ============================================
   11. Responsive Mobile Layout
   ============================================ */
@media (max-width: 1024px) {

	.custom-hero-slider .hero-slider-grid {
		grid-template-rows: 0.5fr 1fr;
	}

	.custom-hero-slider .hero-slider-navigation {
		bottom: 15px;
		transform: translateX(50%);
		        padding: 1.5rem;
	}

	.custom-hero-slider .hero-slider-static-image,
	.custom-hero-slider .hero-slider-empty-bottom-left,
	.custom-hero-slider .hero-slider-empty-top-right {
		display: none;
	}


	.custom-hero-slider .hero-slider-content h3,
	.custom-hero-slider .hero-slider-content .hero-slider-subtitle {
		font-size: clamp(0.875rem, 2vw, 1.125rem);
		max-width: 100%;
	}

	.custom-hero-slider .hero-slider-content .hero-slider-description {
		max-width: 100%;
	}
}

@media (max-width: 768px) {
	.custom-hero-slider {
		height: auto;
		min-height: 600px;
	}

	.custom-hero-slider .swiper-slide {
		height: 100%;
		min-height: 100dvh;
	}

	.custom-hero-slider .hero-slider-grid {
		grid-template-columns: 1fr;
		grid-template-rows: 1fr;
		        height: 100dvh;
	}

	.custom-hero-slider .hero-slider-content {
		grid-area: 2 / 1 / 3 / 2;
		padding: 2rem 1.5rem;
		justify-content: flex-end;		
        margin-bottom: 2rem;
	}

	.custom-hero-slider .hero-slider-content h2,
	.custom-hero-slider .hero-slider-content .hero-slider-title {
		font-size: clamp(3.5rem, 3vw, 4rem);
		margin-bottom: 0.75rem;
        line-height: 3.8rem;
	}

	.custom-hero-slider .hero-slider-content h3,
	.custom-hero-slider .hero-slider-content .hero-slider-subtitle {
		font-size: clamp(0.875rem, 3vw, 1rem);
		margin-bottom: 1.5rem;
	}

	.custom-hero-slider .hero-slider-nav-button-icon {
		width: 22px;
		height: 22px;
	}
}

@media (max-width: 480px) {
	.custom-hero-slider .hero-slider-grid {
	       grid-template-rows: 1fr;
		grid-template-columns: 1fr;
		        height: 100dvh;
	   }

	.custom-hero-slider .hero-slider-content {
		grid-area: 2 / 1 / 3 / 2;
		padding: 1.5rem 1rem;
	}

	.custom-hero-slider .hero-slider-content h3,
	.custom-hero-slider .hero-slider-content .hero-slider-subtitle {
		font-size: 0.875rem;
	}

	.custom-hero-slider .hero-slider-content .hero-slider-description {
		font-size: 0.875rem;
		margin-bottom: 1.5rem;
	}

	.custom-hero-slider .hero-slider-content .hero-slider-button,
	.custom-hero-slider .hero-slider-content .hero-slider-cta {
		padding: 0.75rem 0;
		font-size: 0.875rem;
		width: 100%;
		max-width: 280px;
	}

	.custom-hero-slider .hero-slider-content .hero-slider-button-secondary {
		margin-left: 0;
		margin-top: 0.75rem;
	}

	.custom-hero-slider .hero-slider-nav-button-icon {
		width: 18px;
		height: 18px;
	}
}

/* ============================================
   12. Focus States (Accessibility)
   ============================================ */


.custom-hero-slider a:focus,
.custom-hero-slider button:focus {
	outline: none;
}

/* Skip to content link for accessibility */
.custom-hero-slider .hero-slider-skip-link {
	position: absolute;
	top: -100%;
	left: 0;
	background: #000;
	color: #fff;
	padding: 8px 16px;
	z-index: 100;
	transition: top 0.3s;
}

.custom-hero-slider .hero-slider-skip-link:focus {
	top: 0;
}

/* ============================================
   13. Video Specifics
   ============================================ */
.custom-hero-slider .hero-slider-media video {
	-webkit-appearance: none;
	appearance: none;
	border: none;
}

.custom-hero-slider .hero-slider-media video::-webkit-media-controls {
	display: none !important;
}

.custom-hero-slider .hero-slider-media video::-webkit-media-controls-enclosure {
	display: none !important;
}

/* Video loading state */
.custom-hero-slider .hero-slider-media.video-loading {
	background-color: #000;
}

.custom-hero-slider .hero-slider-media.video-loading::after {
	content: '';
	position: absolute;
	top: 50%;
	left: 50%;
	width: 40px;
	height: 40px;
	margin: -20px 0 0 -20px;
	border: 4px solid rgba(255, 255, 255, 0.3);
	border-top-color: #fff;
	border-radius: 50%;
	animation: hero-slider-spin 1s linear infinite;
}

@keyframes hero-slider-spin {
	to {
		transform: rotate(360deg);
	}
}

/* ============================================
   Additional Utility Classes
   ============================================ */

/* Text alignment variants */
.custom-hero-slider .hero-slider-content.text-left {
	text-align: left;
	align-items: flex-start;
}

.custom-hero-slider .hero-slider-content.text-center {
	text-align: center;
	align-items: center;
}

.custom-hero-slider .hero-slider-content.text-right {
	text-align: right;
	align-items: flex-end;
}

/* Content positioning variants */
.custom-hero-slider .hero-slider-content.content-top {
	justify-content: flex-start;
}

.custom-hero-slider .hero-slider-content.content-center {
	justify-content: center;
}

.custom-hero-slider .hero-slider-content.content-bottom {
	justify-content: flex-end;
}

/* Animation classes for content */
.custom-hero-slider .hero-slider-content.animate-in {
	animation: hero-slider-fade-in 0.8s ease-out forwards;
}

.custom-hero-slider .hero-slider-content .hero-slider-title.animate-in {
	animation: hero-slider-slide-up 0.8s ease-out 0.2s forwards;
	opacity: 0;
}

.custom-hero-slider .hero-slider-content .hero-slider-subtitle.animate-in {
	animation: hero-slider-slide-up 0.8s ease-out 0.4s forwards;
	opacity: 0;
}

.custom-hero-slider .hero-slider-content .hero-slider-description.animate-in {
	animation: hero-slider-slide-up 0.8s ease-out 0.6s forwards;
	opacity: 0;
}

.custom-hero-slider .hero-slider-content .hero-slider-button.animate-in {
	animation: hero-slider-slide-up 0.8s ease-out 0.8s forwards;
	opacity: 0;
}

@keyframes hero-slider-fade-in {
	from {
		opacity: 0;
	}
	to {
		opacity: 1;
	}
}

@keyframes hero-slider-slide-up {
	from {
		opacity: 0;
		transform: translateY(30px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* ============================================
   Print Styles
   ============================================ */
@media print {
	.custom-hero-slider {
		display: none;
	}
}

/* ============================================
   Reduced Motion Support
   ============================================ */
@media (prefers-reduced-motion: reduce) {
	.custom-hero-slider *,
	.custom-hero-slider *::before,
	.custom-hero-slider *::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
		scroll-behavior: auto !important;
	}

	.custom-hero-slider .hero-slider-content.animate-in,
	.custom-hero-slider .hero-slider-content .hero-slider-title.animate-in,
	.custom-hero-slider .hero-slider-content .hero-slider-subtitle.animate-in,
	.custom-hero-slider .hero-slider-content .hero-slider-description.animate-in,
	.custom-hero-slider .hero-slider-content .hero-slider-button.animate-in {
		animation: none;
		opacity: 1;
		transform: none;
	}
}

/* ============================================
   High Contrast Mode Support
   ============================================ */
@media (prefers-contrast: high) {
	.custom-hero-slider {
		--chs-overlay-color: rgba(0, 0, 0, 0.7);
	}

	.custom-hero-slider .hero-slider-nav-button {
		border: 2px solid #ffffff;
	}
}
