/**
 * virtual_tour_module.css
 *
 * Styles for template-parts/modules/virtual_tour_module.php
 * Full-width slider section — each slide has a background image,
 * left-aligned content, and a tour trigger button opening a modal iframe.
 * Multiple slides get a counter + prev/next nav bar overlaid at the bottom.
 */

/* ---------------------------------------------------------------
   Section
--------------------------------------------------------------- */
.virtual-tour-module {
	position: relative;
	width: 100%;
	height: 100svh;
	max-height: 810px;
	overflow: hidden;
	margin: 40px 0;
}

/* ---------------------------------------------------------------
   Slider wrapper — fills the section
--------------------------------------------------------------- */
.vt-slider {
	position: absolute;
	inset: 0;
}

/* ---------------------------------------------------------------
   Slides — stacked, only active is visible
--------------------------------------------------------------- */
.vt-slider__slide {
	position: absolute;
	inset: 0;
	opacity: 0;
	transition: opacity 0.5s ease;
	pointer-events: none;
	display: flex;
	align-items: stretch;
	padding: 60px 40px;
}

.vt-slider__slide.is-active {
	opacity: 1;
	pointer-events: auto;
}

/* Gradient overlay — left-to-right dark fade for text legibility */
.vt-slider__slide::after {
	content: '';
	position: absolute;
	inset: 0;
	background: linear-gradient(to right, rgba(0,0,0,0.65) 0%, rgba(0,0,0,0.25) 55%, transparent 100%);
	pointer-events: none;
}

/* ---------------------------------------------------------------
   Background image — absolute fill within each slide
--------------------------------------------------------------- */
.virtual-tour-module__bg {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
	display: block;
}

/* ---------------------------------------------------------------
   Content column
--------------------------------------------------------------- */
.virtual-tour-module__content {
	position: relative;
	z-index: 2;
	width: 100%;
	max-width: 620px;
	display: flex;
	flex-direction: column;
	gap: 28px;
}

/* Title — WYSIWYG output */
.virtual-tour-module__title {
	color: var(--white);
}

.virtual-tour-module__title p,
.virtual-tour-module__title h2,
.virtual-tour-module__title h3 {
	font-size: clamp(40px, 6vw, 64px);
	font-weight: 900;
	text-transform: uppercase;
	letter-spacing: -0.02em;
	line-height: 1;
	margin: 0 0 48px;
	color: var(--white);
}

/* Body copy */
.virtual-tour-module__body {
	color: rgba(255, 255, 255, 0.85);
	font-size: 17px;
	line-height: 1.7;
}

.virtual-tour-module__body p {
	margin: 0 0 12px;
	color: var(--white);
}

.virtual-tour-module__body p:last-child {
	margin-bottom: 0;
}

/* ---------------------------------------------------------------
   Tour trigger button
--------------------------------------------------------------- */
.virtual-tour-module__btn {
	display: inline-flex;
	align-items: center;
	gap: 18px;
	background: none;
	border: none;
	padding: 0;
	cursor: pointer;
	-webkit-appearance: none;
	appearance: none;
	margin-top: auto;
}

.virtual-tour-module__btn:focus-visible {
	outline: 2px solid var(--yellow);
	outline-offset: 4px;
	border-radius: 2px;
}

/* Yellow circle with arrow */
.virtual-tour-module__btn-icon {
	flex-shrink: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 64px;
	height: 64px;
	border-radius: 50%;
	background-color: var(--yellow);
	transition: transform 0.2s ease, background-color 0.2s ease;
}

.virtual-tour-module__btn-icon::after {
	content: '';
	display: block;
	width: 0;
	height: 0;
	border-style: solid;
	border-width: 10px 0 10px 18px;
	border-color: transparent transparent transparent var(--black);
	margin-left: 5px;
}

.virtual-tour-module__btn:hover .virtual-tour-module__btn-icon,
.virtual-tour-module__btn:focus-visible .virtual-tour-module__btn-icon {
	transform: scale(1.08);
	background-color: var(--yellow-hover);
}

/* Label text */
.virtual-tour-module__btn-label {
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--white);
}

/* ---------------------------------------------------------------
   Slider UI bar — counter + nav, overlaid at bottom of slider
--------------------------------------------------------------- */
.vt-slider__ui {
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	z-index: 3;
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	padding: 50px 40px 32px;
	background: linear-gradient(to top, rgba(0,0,0,0.45) 0%, transparent 100%);
	pointer-events: none;
}

.vt-slider__counter {
	font-size: 16px;
	font-weight: 500;
	color: var(--white);
	line-height: 1;
}

.vt-slider__nav {
	display: flex;
	gap: 10px;
	align-items: center;
	pointer-events: all;
}

.vt-slider__prev,
.vt-slider__next {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 56px;
	height: 56px;
	border-radius: 50%;
	border: 1.5px solid var(--btn-grey);
	background-color: transparent;
	color: var(--btn-grey);
	cursor: pointer;
	transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
	-webkit-appearance: none;
	appearance: none;
}

.vt-slider__prev.is-active,
.vt-slider__next.is-active {
	background-color: var(--yellow);
	border-color: var(--yellow);
	color: var(--black);
}

.vt-slider__prev.is-active:hover,
.vt-slider__next.is-active:hover {
	background-color: var(--yellow-hover);
	border-color: var(--yellow-hover);
}

.vt-slider__prev:focus-visible,
.vt-slider__next:focus-visible {
	outline: 2px solid var(--yellow);
	outline-offset: 3px;
}

.vt-slider__prev svg,
.vt-slider__next svg {
	display: block;
	flex-shrink: 0;
}

/* ---------------------------------------------------------------
   Modal overlay
--------------------------------------------------------------- */
.vt-modal {
	position: fixed;
	inset: 0;
	z-index: 9999;
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.3s ease, visibility 0.3s ease;
}

.vt-modal.is-open {
	opacity: 1;
	visibility: visible;
}

/* Backdrop — click to close */
.vt-modal__backdrop {
	position: absolute;
	inset: 0;
	background-color: rgba(0, 0, 0, 0.9);
	cursor: pointer;
}

/* Inner wrapper — wider than video to suit panoramic tours */
.vt-modal__wrapper {
	position: relative;
	z-index: 1;
	width: 92vw;
	max-width: 1400px;
}

/* Close button */
.vt-modal__close {
	position: absolute;
	top: -48px;
	right: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	background: none;
	border: 2px solid rgba(255, 255, 255, 0.4);
	border-radius: 50%;
	color: var(--white);
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
	transition: border-color 0.2s ease, color 0.2s ease;
	-webkit-appearance: none;
	appearance: none;
}

.vt-modal__close:hover,
.vt-modal__close:focus-visible {
	border-color: var(--yellow);
	color: var(--yellow);
	outline: none;
}

/* 16:9 responsive embed container */
.vt-modal__embed {
	position: relative;
	width: 100%;
	padding-bottom: 56.25%;
	height: 0;
	background-color: var(--black);
}

.vt-modal__iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: none;
}

/* Prevent body scroll while modal is open */
body.vt-modal-open {
	overflow: hidden;
}

/* ---------------------------------------------------------------
   Responsive — 992px
--------------------------------------------------------------- */
@media (max-width: 992px) {
	.virtual-tour-module {
		min-height: 80vh;
	}

	.vt-slider__slide {
		padding: 40px 20px;
	}

	.vt-slider__ui {
		padding: 30px 20px 24px;
	}

	.virtual-tour-module__content {
		max-width: 100%;
	}
}

/* ---------------------------------------------------------------
   Responsive — 768px
--------------------------------------------------------------- */
@media (max-width: 768px) {
	.virtual-tour-module {
		min-height: 70vh;
	}

	.vt-slider__slide {
		padding: 40px 20px;
		align-items: flex-start;
	}

	.vt-modal__wrapper {
		width: 95vw;
	}

	.vt-modal__close {
		top: -44px;
	}
}

/* ---------------------------------------------------------------
   Responsive — 600px
--------------------------------------------------------------- */
@media (max-width: 600px) {
	.vt-slider__prev,
	.vt-slider__next {
		width: 44px;
		height: 44px;
	}

	.virtual-tour-module__btn-icon {
		width: 52px;
		height: 52px;
	}
}
