/**
 * Amitry Booking - embed styles.
 * Scoped to .amitry-booking-embed so themes are never touched.
 */

.amitry-booking-embed {
	position: relative;
	isolation: isolate;
	overflow: hidden;
	--amitry-embed-h: 520px;
	--amitry-embed-overlay: 0.55;
	--amitry-embed-ink: #17171a;
	--amitry-embed-paper: #f8f8f5;
	--amitry-embed-accent: #5b47f0;
}

.amitry-booking-embed.has-no-image .amitry-booking-embed__media {
	background: linear-gradient(160deg, #1e1b4b, #312e81 60%, #4c1d95);
}

/* The wizard progress bar bleeding across the top edge. */
.amitry-booking-embed::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0;
	height: 3px;
	width: 42%;
	background: var(--amitry-embed-accent);
	z-index: 3;
}

.amitry-booking-embed__media {
	position: absolute;
	left: 0;
	right: 0;
	top: -18%;
	bottom: -18%;
	z-index: 0;
}

.amitry-booking-embed__img {
	position: absolute;
	inset: 0;
	background-size: cover;
	background-position: center;
	transform: translate3d(0, 0, 0);
}

.amitry-booking-embed.is-parallax .amitry-booking-embed__img {
	will-change: transform;
}

.amitry-booking-embed__overlay {
	position: absolute;
	inset: 0;
	z-index: 1;
	background: #0b0b14;
	opacity: var(--amitry-embed-overlay);
}

.amitry-booking-embed__inner {
	position: relative;
	z-index: 2;
	max-width: 1080px;
	margin: 0 auto;
	padding: 0 24px;
	min-height: var(--amitry-embed-h);
	display: flex;
	align-items: center;
}

/* ---------- call to action ---------- */

.amitry-booking-embed__cta {
	max-width: 640px;
	color: #fff;
	padding: 72px 0;
}

.amitry-booking-embed.is-center .amitry-booking-embed__inner {
	justify-content: center;
}

.amitry-booking-embed.is-center .amitry-booking-embed__cta {
	text-align: center;
}

.amitry-booking-embed__title {
	font-size: clamp(30px, 4.4vw, 54px);
	line-height: 1.05;
	letter-spacing: -0.025em;
	margin: 0 0 16px;
	font-weight: 700;
	color: #fff;
}

.amitry-booking-embed__text {
	font-size: 18px;
	line-height: 1.6;
	color: rgba(255, 255, 255, 0.84);
	margin: 0 0 30px;
	max-width: 46ch;
}

.amitry-booking-embed.is-center .amitry-booking-embed__text {
	margin-left: auto;
	margin-right: auto;
}

.amitry-booking-embed__btn {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	background: var(--amitry-embed-ink);
	color: #fff;
	border: 0;
	border-radius: 999px;
	padding: 16px 28px;
	font-weight: 600;
	font-size: 16px;
	line-height: 1;
	cursor: pointer;
	text-decoration: none;
	transition: transform 0.18s ease, background 0.18s ease;
}

.amitry-booking-embed__btn:hover,
.amitry-booking-embed__btn:focus {
	color: #fff;
	background: #000;
	transform: translateY(-2px);
	text-decoration: none;
}

.amitry-booking-embed__btn:focus-visible {
	outline: 3px solid #fff;
	outline-offset: 3px;
}

.amitry-booking-embed__btn svg {
	transition: transform 0.18s ease;
}

.amitry-booking-embed__btn:hover svg {
	transform: translateX(3px);
}

/* ---------- embedded wizard ---------- */

.amitry-booking-embed--inline .amitry-booking-embed__inner {
	padding-top: 56px;
	padding-bottom: 56px;
}

.amitry-booking-embed__frame {
	width: 100%;
	max-width: 940px;
	margin: 0 auto;
	background: var(--amitry-embed-paper);
	border-radius: 20px;
	box-shadow: 0 30px 70px rgba(10, 10, 25, 0.34);
	overflow: hidden;
}

.amitry-booking-embed__frame iframe {
	display: block;
	width: 100%;
	height: 640px;
	border: 0;
	background: var(--amitry-embed-paper);
}

/* ---------- editor helper ---------- */

.amitry-booking-embed-notice {
	padding: 28px;
	border: 1px dashed #c3c4c7;
	border-radius: 10px;
	text-align: center;
	color: #646970;
	font-size: 14px;
	background: #fff;
}

@media (max-width: 782px) {
	.amitry-booking-embed__cta {
		padding: 56px 0;
	}

	.amitry-booking-embed__frame iframe {
		height: 560px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.amitry-booking-embed__img {
		transform: none !important;
	}

	.amitry-booking-embed__btn {
		transition: none;
	}
}

/* ---------- lightbox ---------- */

.amitry-booking-embed__modal {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 24px;
}

.amitry-booking-embed__modal[hidden] {
	display: none;
}

.amitry-booking-embed__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(10, 10, 20, 0.72);
	cursor: pointer;
	animation: amitry-embed-fade 0.2s ease;
}

.amitry-booking-embed__dialog {
	position: relative;
	width: 100%;
	max-width: 960px;
	max-height: calc(100vh - 48px);
	background: var(--amitry-embed-paper);
	border-radius: 18px;
	box-shadow: 0 30px 80px rgba(5, 5, 20, 0.45);
	overflow: hidden;
	animation: amitry-embed-rise 0.24s cubic-bezier(0.2, 0.8, 0.3, 1);
}

.amitry-booking-embed__close {
	position: absolute;
	top: 12px;
	right: 12px;
	z-index: 2;
	width: 40px;
	height: 40px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 50%;
	border: 1px solid rgba(0, 0, 0, 0.08);
	background: #fff;
	color: #52525b;
	cursor: pointer;
	padding: 0;
}

.amitry-booking-embed__close:hover {
	color: #18181b;
	background: #f4f4f5;
}

.amitry-booking-embed__close:focus-visible {
	outline: 2px solid var(--amitry-embed-accent);
	outline-offset: 2px;
}

.amitry-booking-embed__modal-frame {
	height: calc(100vh - 48px);
	max-height: 820px;
}

.amitry-booking-embed__modal-frame iframe {
	display: block;
	width: 100%;
	height: 100%;
	border: 0;
	background: var(--amitry-embed-paper);
}

.amitry-booking-embed-modal-open {
	overflow: hidden;
}

@keyframes amitry-embed-fade {
	from { opacity: 0; }
	to   { opacity: 1; }
}

@keyframes amitry-embed-rise {
	from { opacity: 0; transform: translateY(14px) scale(0.99); }
	to   { opacity: 1; transform: none; }
}

@media (max-width: 782px) {
	.amitry-booking-embed__modal {
		padding: 0;
	}

	.amitry-booking-embed__dialog {
		max-width: none;
		max-height: 100vh;
		height: 100vh;
		border-radius: 0;
	}

	.amitry-booking-embed__modal-frame {
		height: 100vh;
	}
}

@media (prefers-reduced-motion: reduce) {
	.amitry-booking-embed__backdrop,
	.amitry-booking-embed__dialog {
		animation: none;
	}
}
