/* Saraswaan Floating Video Widget */

.sfv-root {
	--sfv-width: 168px;
	--sfv-radius: 16px;
	--sfv-shadow: 0 12px 36px rgba(0, 0, 0, 0.32);
	--sfv-z-index: 999999;
	--sfv-offset-x: 18px;
	--sfv-offset-y: 86px;
	display: block;
}

.sfv-root[hidden],
.sfv-root.is-dismissed {
	display: none !important;
}

.sfv-widget {
	position: fixed;
	right: var(--sfv-offset-x);
	bottom: var(--sfv-offset-y);
	z-index: var(--sfv-z-index);
	width: var(--sfv-width);
	border-radius: var(--sfv-radius);
	overflow: hidden;
	box-shadow: var(--sfv-shadow);
	background: #111;
	border: 2px solid rgba(255, 255, 255, 0.12);
	cursor: pointer;
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.sfv-widget:hover {
	transform: translateY(-3px) scale(1.02);
	box-shadow: 0 16px 40px rgba(0, 0, 0, 0.38);
}

.sfv-close {
	position: absolute;
	top: 8px;
	right: 8px;
	z-index: 3;
	width: 28px;
	height: 28px;
	border: 0;
	border-radius: 50%;
	background: rgba(0, 0, 0, 0.75);
	color: #fff;
	font-size: 18px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 0;
}

.sfv-close:hover,
.sfv-close:focus {
	background: rgba(0, 0, 0, 0.92);
	outline: none;
}

.sfv-preview {
	display: block;
	width: 100%;
	padding: 0;
	border: 0;
	background: transparent;
	cursor: pointer;
	position: relative;
	aspect-ratio: 9 / 16;
}

.sfv-preview-video {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	pointer-events: none;
	background: #000;
}

.sfv-preview-video::-webkit-media-controls,
.sfv-preview-video::-webkit-media-controls-enclosure,
.sfv-preview-video::-webkit-media-controls-panel {
	display: none !important;
	-webkit-appearance: none;
}

.sfv-modal {
	position: fixed;
	inset: 0;
	z-index: calc(var(--sfv-z-index) + 1);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
}

.sfv-modal[hidden] {
	display: none;
}

.sfv-modal-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.78);
	cursor: pointer;
}

.sfv-modal-dialog {
	position: relative;
	z-index: 1;
	width: min(92vw, 480px);
	max-height: 90vh;
	border-radius: 18px;
	overflow: hidden;
	background: #000;
	box-shadow: 0 20px 56px rgba(0, 0, 0, 0.5);
}

.sfv-modal-close {
	position: absolute;
	top: 10px;
	right: 10px;
	z-index: 2;
	width: 36px;
	height: 36px;
	border: 0;
	border-radius: 50%;
	background: rgba(0, 0, 0, 0.75);
	color: #fff;
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 0;
}

.sfv-modal-close:hover,
.sfv-modal-close:focus {
	background: rgba(0, 0, 0, 0.92);
	outline: none;
}

.sfv-modal-video {
	display: block;
	width: 100%;
	height: auto;
	max-height: 90vh;
	object-fit: contain;
	background: #000;
}

@media (max-width: 767px) {
	.sfv-root {
		--sfv-width: 132px;
		--sfv-offset-x: 14px;
		--sfv-offset-y: 76px;
	}

	.sfv-modal-dialog {
		width: min(94vw, 380px);
	}
}

@media (prefers-reduced-motion: reduce) {
	.sfv-widget {
		transition: none;
	}
}

body.sfv-modal-open {
	overflow: hidden;
}

/* Fallback when JS has not measured WhatsApp yet */
a.sfv-whatsapp-anchor {
	position: fixed !important;
	right: 18px !important;
	bottom: 18px !important;
	left: auto !important;
	top: auto !important;
	z-index: 999998 !important;
}

@media (max-width: 767px) {
	a.sfv-whatsapp-anchor {
		right: 14px !important;
		bottom: 14px !important;
	}
}
