/* ─────────────────────────────────────────────────────────────────────────────
   ATHERIA — EXPERIENCE GALLERY (carousel + GSAP Flip modal)
   A single large image "stage" with prev/next arrows to browse. Clicking the
   image opens the same GSAP Flip modal mechanism used by the Room Gallery
   (Flip.from / Flip.fit) for a seamless zoom-in / zoom-out transition.
   ───────────────────────────────────────────────────────────────────────────── */

.elementor-widget-atheria_experience_gallery.elementor-invisible {
	visibility: visible !important;
}

.ath-exp-gal {
	display: block;
	padding-top: 4rem;
	padding-bottom: 4rem;
	position: relative;
	z-index: 0;
	--ath-exp-gal-ratio: 947 / 360;
}

.ath-exp-gal__inner {
	position: relative;
	display: block;
}

.ath-exp-gal__head {
	margin-bottom: 2rem;
	max-width: 60ch;
}

.ath-exp-gal__eyebrow {
	display: block;
	font-family: var(--ath-font-eyebrow, sans-serif);
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--ath-on-surface-accent, #487797);
	margin-bottom: 0.75rem;
}

.ath-exp-gal__title {
	font-family: var(--ath-font-heading, serif);
	color: var(--ath-on-surface, #243C4C);
	font-size: clamp(1.75rem, 1.2rem + 2.4vw, 2.75rem);
	line-height: 1.1;
	margin: 0;
}

.ath-exp-gal__desc {
	font-family: var(--ath-font-body, sans-serif);
	color: var(--ath-on-surface-muted, #5C7684);
	font-size: 0.9375rem;
	line-height: 1.65;
	margin: 1rem 0 0;
}

.ath-exp-gal__stage {
	position: relative;
	width: 100%;
	border-radius: var(--ath-radius-lg, 2rem);
	overflow: hidden;
	background: var(--ath-arctic-mist, #ACBCBF);
}

.ath-exp-gal__track {
	position: relative;
	width: 100%;
	aspect-ratio: var(--ath-exp-gal-ratio, 947 / 360);
}

.ath-exp-gal__slide {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.5s var(--ath-ease-out, ease);
}

.ath-exp-gal__slide.is-active {
	position: relative;
	opacity: 1;
	visibility: visible;
	z-index: 1;
}

.ath-exp-gal .ath-exp-gal__slide img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	cursor: zoom-in;
}

.ath-exp-gal--natural .ath-exp-gal__slide.is-active img {
	height: auto;
}

.ath-exp-gal__slide:not(.is-active) img {
	height: 100%;
	object-fit: cover;
}

.ath-exp-gal__ctrl {
	position: absolute !important;
	top: 50% !important;
	z-index: 3 !important;
	transform: translateY(-50%) !important;
	background: var(--ath-exp-gal-arrow-bg, color-mix(in srgb, var(--ath-arctic-navy) 60%, transparent)) !important;
	border: 1px solid var(--ath-exp-gal-arrow-border, rgba(255,255,255,0.32)) !important;
	color: var(--ath-exp-gal-arrow-color, #fff) !important;
	width: var(--ath-exp-gal-arrow-size, 44px) !important;
	height: var(--ath-exp-gal-arrow-size, 44px) !important;
	border-radius: 50% !important;
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	cursor: pointer !important;
	font-size: 1.3rem !important;
	line-height: 1 !important;
	padding: 0 !important;
	margin: 0 !important;
	box-shadow: none !important;
	backdrop-filter: var(--ath-exp-gal-arrow-blur, blur(8px)) !important;
	-webkit-backdrop-filter: var(--ath-exp-gal-arrow-blur, blur(8px)) !important;
	transition: background 0.2s ease !important;
}

/* Navy glass keeps the white icon at 3:1 over any photo, even pure white, and darkens on hover. */
.ath-exp-gal__ctrl:hover {
	background: var(--ath-exp-gal-arrow-bg-hover, color-mix(in srgb, var(--ath-arctic-navy) 70%, transparent)) !important;
	border-color: var(--ath-exp-gal-arrow-border-hover, var(--ath-exp-gal-arrow-border, rgba(255,255,255,0.32))) !important;
	color: var(--ath-exp-gal-arrow-color-hover, var(--ath-exp-gal-arrow-color, #fff)) !important;
}

.ath-exp-gal__ctrl--prev {
	left: 1rem !important;
}

.ath-exp-gal__ctrl--next {
	right: 1rem !important;
}

.ath-exp-gal__dots {
	display: flex;
	justify-content: center;
	gap: 0.5rem;
	margin-top: 1.25rem;
}

.ath-exp-gal__dot {
	width: 8px !important;
	height: 8px !important;
	border-radius: 50% !important;
	background: var(--ath-border-strong, #6C878D) !important;
	border: 0 !important;
	padding: 0 !important;
	cursor: pointer;
	transition: background 0.25s ease, transform 0.25s ease;
}

/* The scale is load-bearing, not decoration. Active and inactive read 4.62 and 3.67 against
   the page but only 1.26 against each other, so size - not tone - is what tells a visitor which
   slide they are on. Removing it leaves two dots all but indistinguishable. Raising the tones to
   separate them instead runs into D-071: the pair that clears both bars puts the active dot on
   navy, which is a design change and was declined here. Revisit that reasoning before touching
   either line. */
.ath-exp-gal__dot.is-active {
	background: var(--ath-on-surface-accent, #487797) !important;
	transform: scale(1.3);
}

.ath-exp-gal__modal {
	position: fixed;
	inset: 0;
	z-index: 9999999;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 4vw;
	visibility: hidden;
	opacity: 0;
	transition: opacity 0.35s var(--ath-ease-out, ease), visibility 0.35s;
}

.ath-exp-gal__modal.is-open {
	visibility: visible;
	opacity: 1;
}

.ath-exp-gal__overlay {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.96);
	z-index: 1;
}

.ath-exp-gal__mimg {
	position: relative;
	z-index: 2;
	max-width: 92vw;
	max-height: calc(100vh - 180px);
	width: auto;
	height: auto;
	object-fit: contain;
	display: block;
	border-radius: var(--ath-radius-md, 1rem);
	box-shadow: 0 24px 80px rgba(0,0,0,.5);
	transform: scale(0.96);
	transition: transform 0.35s var(--ath-ease-out, cubic-bezier(.22,1,.36,1));
}

.ath-exp-gal__modal.is-open .ath-exp-gal__mimg {
	transform: scale(1);
}

.ath-exp-gal__mthumbs {
	position: absolute;
	bottom: max(1.5rem, env(safe-area-inset-bottom, 1.5rem));
	left: 0;
	width: 100%;
	display: flex;
	justify-content: center;
	gap: 0.5rem;
	z-index: 1000000;
}

.ath-exp-gal__mthumb {
	width: 65px;
	height: 45px;
	border-radius: 4px;
	overflow: hidden;
	opacity: 0.35;
	cursor: pointer;
	transition: opacity 0.3s, transform 0.3s;
	border: 2px solid transparent;
	box-sizing: border-box;
}

.ath-exp-gal__mthumb.is-active {
	opacity: 1;
	border-color: #fff;
	transform: scale(1.1);
}

.ath-exp-gal__mthumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	pointer-events: none;
}

.ath-exp-gal__close,
.ath-exp-gal__mnav {
	position: fixed !important;
	z-index: 1000000 !important;
	background: rgba(255,255,255,0.12) !important;
	border: 1px solid rgba(255,255,255,0.3) !important;
	color: #fff !important;
	width: 48px !important;
	height: 48px !important;
	border-radius: 50% !important;
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	cursor: pointer !important;
	font-size: 1.4rem !important;
	line-height: 1 !important;
	padding: 0 !important;
	margin: 0 !important;
	box-shadow: none !important;
	backdrop-filter: blur(8px) !important;
	-webkit-backdrop-filter: blur(8px) !important;
	transition: background 0.2s ease !important;
}

.ath-exp-gal__close:hover,
.ath-exp-gal__mnav:hover {
	background: rgba(255,255,255,0.28) !important;
}

.ath-exp-gal__close {
	top: max(1.5rem, env(safe-area-inset-top, 1.5rem)) !important;
	right: max(1.5rem, env(safe-area-inset-right, 1.5rem)) !important;
	bottom: auto !important;
	left: auto !important;
	transform: none !important;
}

.ath-exp-gal__mnav--prev {
	left: clamp(1rem,3vw,2rem) !important;
	top: 50% !important;
	transform: translateY(-50%) !important;
	right: auto !important;
	bottom: auto !important;
}

.ath-exp-gal__mnav--next {
	right: clamp(1rem,3vw,2rem) !important;
	top: 50% !important;
	transform: translateY(-50%) !important;
	left: auto !important;
	bottom: auto !important;
}

@media (max-width: 767px) {
	.ath-exp-gal:not(.ath-exp-gal--natural):not(.ath-exp-gal--phone-ratio) .ath-exp-gal__track {
		aspect-ratio: 1 / 1;
	}
	.ath-exp-gal__mnav {
		width: 40px !important;
		height: 40px !important;
		font-size: 1.1rem !important;
	}
	.ath-exp-gal__ctrl {
		width: var(--ath-exp-gal-arrow-size, 38px) !important;
		height: var(--ath-exp-gal-arrow-size, 38px) !important;
		font-size: 1.1rem !important;
	}
	.ath-exp-gal__mthumb {
		width: 50px;
		height: 35px;
	}
	.ath-exp-gal__mimg {
		max-height: calc(100vh - 160px);
	}
}

/* With no photos the gallery gives its column to the row, and its section when nothing but a heading shares it, unless its "With no photos" control keeps the space. */
@supports selector(:has(*)) {
	body:not(.elementor-editor-active) .e-con:has(> .elementor-widget-atheria_experience_gallery:only-child .ath-exp-gal--empty),
	body:not(.elementor-editor-active) .e-con:has(> .e-con-inner > .elementor-widget-atheria_experience_gallery:only-child .ath-exp-gal--empty),
	body:not(.elementor-editor-active) [data-elementor-type] > :is(.e-con, .e-div-block-base, .e-flexbox-base):has(.ath-exp-gal--empty):not(:has(.elementor-widget:not(.elementor-widget-atheria_experience_gallery, .elementor-widget-atheria_section_heading, .elementor-widget-heading))) {
		display: none;
	}

	body:not(.elementor-editor-active) :is(.e-con, .e-con-inner):has(> .e-con > .elementor-widget-atheria_experience_gallery:only-child .ath-exp-gal--empty) > .e-con,
	body:not(.elementor-editor-active) :is(.e-con, .e-con-inner):has(> .e-con > .e-con-inner > .elementor-widget-atheria_experience_gallery:only-child .ath-exp-gal--empty) > .e-con {
		--width: 100% !important;
	}
}
