.hva-wrap {
	position: relative;
	width: 100%;
	height: var(--hva-height, 80vh);
	overflow: hidden;
	background: #000;
	line-height: 0;
}
/* altezza "auto" = proporzioni originali del video (il rapporto esatto viene letto dal file) */
.hva-wrap[data-height="auto"] {
	height: auto;
	aspect-ratio: var(--hva-ratio, 16 / 9);
}

.hva-wrap .hva-video {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	max-width: none;
}

/* Video interni */
.hva-wrap.hva-inline {
	border-radius: var(--hva-radius, 0);
	margin-left: auto;
	margin-right: auto;
}
.hva-wrap.hva-inline .hva-video { cursor: pointer; }

/* Pulsanti (specificità alta per non farsi sovrascrivere dagli stili globali dei button del tema) */
.hva-wrap button.hva-btn,
.hva-wrap button.hva-play {
	position: absolute;
	z-index: 5;
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(0, 0, 0, .55);
	color: #fff;
	cursor: pointer;
	box-shadow: none;
	text-shadow: none;
	min-height: 0;
	transition: background .2s ease, transform .2s ease;
	-webkit-appearance: none;
	appearance: none;
}
.hva-wrap button.hva-btn:hover,
.hva-wrap button.hva-play:hover {
	background: rgba(0, 0, 0, .8);
	color: #fff;
	transform: scale(1.06);
}
.hva-wrap button.hva-btn:focus-visible,
.hva-wrap button.hva-play:focus-visible {
	outline: 2px solid #fff;
	outline-offset: 2px;
}

/* Speaker: in alto a destra */
.hva-wrap button.hva-btn {
	top: 16px;
	right: 16px;
	width: 44px;
	height: 44px;
}
.hva-wrap .hva-btn svg {
	width: 22px;
	height: 22px;
	fill: currentColor;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}
.hva-wrap .hva-btn svg path:first-child { stroke: none; }
.hva-wrap .hva-btn .hva-ico-on path:not(:first-child) { fill: none; }
.hva-wrap .hva-btn .hva-ico-off line { fill: none; }

.hva-wrap .hva-ico-on { display: none; }
.hva-wrap:not(.hva-is-muted) .hva-ico-on { display: block; }
.hva-wrap:not(.hva-is-muted) .hva-ico-off { display: none; }

/* Play centrale (solo se autoplay disattivato, bloccato o video in pausa) */
.hva-wrap button.hva-play {
	top: 50%;
	left: 50%;
	width: 76px;
	height: 76px;
	margin: -38px 0 0 -38px;
}
.hva-wrap button.hva-play:hover { transform: scale(1.06); }
.hva-wrap button.hva-play[hidden],
.hva-wrap.hva-playing button.hva-play { display: none; }
.hva-wrap .hva-play svg { width: 34px; height: 34px; fill: currentColor; margin-left: 4px; }

@media (max-width: 600px) {
	.hva-wrap button.hva-btn { top: 10px; right: 10px; width: 40px; height: 40px; }
}
