.svp-wrap,
.svp-wrap * {
	box-sizing: border-box;
}

.svp-wrap {
	width: 100%;
	max-width: 900px;
	margin: 0 auto;
}

.svp-wrap .svp-frame {
	position: relative;
	width: 100%;
	aspect-ratio: 16 / 9;
	background: #0c0f0c;
	border-radius: 18px;
	overflow: hidden;
	box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
	-webkit-user-select: none;
	user-select: none;
	touch-action: manipulation;
}

.svp-wrap .svp-video {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	background: #000;
	display: block;
	pointer-events: none;
}

.svp-wrap .svp-yt-holder {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	background: #000;
}

.svp-wrap .svp-yt-holder iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
	pointer-events: none;
}

.svp-wrap .svp-poster {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
	z-index: 1;
	transition: opacity 0.25s ease;
	background: #0c0f0c; /* visible only for the brief moment before a fallback image loads */
}

.svp-wrap.svp-yt-started .svp-poster,
.svp-wrap.svp-started .svp-poster {
	opacity: 0;
	pointer-events: none;
}

.svp-wrap .svp-center-play {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%) scale(1);
	z-index: 4;
	width: 68px;
	height: 68px;
	border: none;
	border-radius: 50%;
	background: #a97e2f80 !important;
	backdrop-filter: blur(3px);
	-webkit-backdrop-filter: blur(3px);
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
	transition: opacity 0.25s ease, transform 0.15s ease, background 0.15s ease;
}

.svp-wrap .svp-center-play svg {
	width: 30px;
	height: 30px;
	margin-left: 3px; /* optically center the triangle */
}

.svp-wrap .svp-center-play:hover {
	background: #A97E2F;
	transform: translate(-50%, -50%) scale(1.06);
}

.svp-wrap .svp-center-play:active {
	transform: translate(-50%, -50%) scale(0.94);
}

.svp-wrap.svp-started .svp-center-play {
	opacity: 0;
	pointer-events: none;
	transform: translate(-50%, -50%) scale(0.8);
}

@media (max-width: 480px) {
	.svp-wrap .svp-center-play {
		width: 54px;
		height: 54px;
	}
	.svp-wrap .svp-center-play svg {
		width: 24px;
		height: 24px;
	}
}

.svp-wrap .svp-clickzone {
	position: absolute;
	inset: 0;
	z-index: 2;
	cursor: pointer;
}

.svp-wrap .svp-overlay {
	position: absolute;
	inset: 0;
	z-index: 3;
	pointer-events: none;
	background: linear-gradient(
		to top,
		rgba(0, 0, 0, 0.45) 0%,
		rgba(0, 0, 0, 0.15) 35%,
		rgba(0, 0, 0, 0) 65%
	);
	opacity: 0;
	transition: opacity 0.25s ease;
}

.svp-wrap.svp-controls-visible .svp-overlay {
	opacity: 1;
}

.svp-wrap .svp-controls {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 4;
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 14px;
	pointer-events: none;
	opacity: 0;
	transform: translateY(6px);
	transition: opacity 0.25s ease, transform 0.25s ease;
}

.svp-wrap.svp-controls-visible .svp-controls {
	opacity: 1;
	transform: translateY(0);
	pointer-events: auto;
}

.svp-wrap .svp-volume-wrap {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
}

.svp-wrap .svp-volume-popup {
	position: absolute;
	bottom: calc(100% + 10px);
	left: 50%;
	transform: translateX(-50%) translateY(8px);
	width: 34px;
	height: 92px;
	background: rgba(12, 15, 12, 0.55);
	backdrop-filter: blur(4px);
	-webkit-backdrop-filter: blur(4px);
	border-radius: 8px;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 12px 0;
	opacity: 0;
	pointer-events: none;
	transition: opacity 0.2s ease, transform 0.2s ease;
	z-index: 6;
}

@media (hover: hover) {
	.svp-wrap .svp-volume-wrap:hover .svp-volume-popup,
	.svp-wrap .svp-volume-wrap:focus-within .svp-volume-popup {
		opacity: 1;
		pointer-events: auto;
		transform: translateX(-50%) translateY(0);
	}
}

.svp-wrap .svp-volume-wrap.svp-volume-open .svp-volume-popup {
	opacity: 1;
	pointer-events: auto;
	transform: translateX(-50%) translateY(0);
}

.svp-wrap .svp-vol-track {
	position: relative;
	width: 3px;
	height: 100%;
	background: rgba(255, 255, 255, 0.3);
	border-radius: 3px;
	cursor: pointer;
	touch-action: none;
}

.svp-wrap .svp-vol-fill {
	position: absolute;
	left: 0;
	bottom: 0;
	width: 100%;
	height: 100%;
	background: #ffffff;
	border-radius: 3px;
	pointer-events: none;
}

.svp-wrap .svp-vol-thumb {
	position: absolute;
	left: 50%;
	bottom: 100%;
	width: 13px;
	height: 13px;
	border-radius: 50%;
	background: #ffffff;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
	transform: translate(-50%, 50%);
	cursor: pointer;
	touch-action: none;
}

.svp-wrap .svp-btn {
	width: 40px;
	height: 40px;
	min-width: 36px;
	min-height: 36px;
	max-width: 44px;
	max-height: 44px;
	border: none;
	border-radius: 10px;
	background: rgba(30, 190, 160, 0.55);
	backdrop-filter: blur(3px);
	-webkit-backdrop-filter: blur(3px);
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	padding: 0;
	transition: background 0.15s ease, transform 0.1s ease;
}

.svp-wrap .svp-btn:hover {
	background: rgba(30, 190, 160, 0.75);
}

.svp-wrap .svp-btn:active {
	transform: scale(0.92);
}

.svp-wrap .svp-icon {
	width: 20px;
	height: 20px;
	transition: opacity 0.15s ease, transform 0.15s ease;
}

/* Crossfade between play/pause and mute/unmute icon pairs instead of a
   hard display:none/block cut, so the swap reads as one smooth motion. */
.svp-wrap .svp-btn {
	position: relative;
}

.svp-wrap .svp-btn .svp-icon {
	position: absolute;
	opacity: 0;
	transform: scale(0.7);
	pointer-events: none;
}

.svp-wrap .svp-btn .svp-icon.svp-icon-active {
	position: relative;
	opacity: 1;
	transform: scale(1);
	pointer-events: auto;
}

@media (max-width: 480px) {
	.svp-wrap .svp-frame {
		border-radius: 12px;
	}
	.svp-wrap .svp-controls {
		padding: 10px;
	}
}
