/* Le widget occupe l’espace restant de son conteneur Elementor (ex. 100dvh) */
.elementor-widget-expo_sonore {
	flex: 1 1 auto;
	min-height: 0;
	width: 100%;
	display: flex;
	flex-direction: column;
}
.elementor-widget-expo_sonore > .elementor-widget-container {
	flex: 1 1 auto;
	min-height: 0;
	display: flex;
	flex-direction: column;
}

.es-expo {
	--es-gap: 40px;
	--es-sub: #fff;
	--es-fade: 1000ms;
	--es-btn-size: 56px;
	--es-btn-bg: #fff;
	--es-btn-ink: #1c1f10;
	--es-line: #fff;
	--es-line-dim: rgba(255, 255, 255, .35);
	--es-time: #fff;

	flex: 1 1 auto;
	min-height: 0;
	width: 100%;
	display: flex;
	flex-direction: column;
	gap: var(--es-gap);
}

/* Images */
.es-expo .es-stage {
	position: relative;
	flex: 1 1 auto;
	min-height: 240px;
	width: 100%;
	margin: 0 auto;
}
.es-expo .es-stage img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	max-width: none;
	margin: 0;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	object-fit: contain;
	opacity: 0;
	transition: opacity 1.2s ease;
}
.es-expo .es-stage img.is-on {
	opacity: 1;
}

/* Sous-titres : chaque phrase apparaît en fondu */
.es-expo .es-sub {
	margin: 0 auto;
	max-width: 60em;
	min-height: 2.7em;
	text-align: center;
	line-height: 1.35;
	color: var(--es-sub);
	text-wrap: balance;
	opacity: 0;
	transition: none;
}
.es-expo .es-sub.is-in {
	opacity: 1;
	transition: opacity var(--es-fade) ease;
}

/* Lecteur */
.es-expo .es-player {
	display: flex;
	align-items: center;
	gap: 20px;
}
.es-expo .es-play,
.es-expo .es-play:hover,
.es-expo .es-play:focus,
.es-expo .es-play:active {
	-webkit-appearance: none;
	appearance: none;
	flex: none;
	box-sizing: border-box;
	width: var(--es-btn-size);
	min-width: var(--es-btn-size);
	height: var(--es-btn-size);
	min-height: var(--es-btn-size);
	aspect-ratio: 1;
	padding: 0;
	margin: 0;
	border: 0;
	border-radius: 50%;
	background: var(--es-btn-bg);
	color: var(--es-btn-ink);
	box-shadow: none;
	font-size: 0;
	line-height: 0;
	text-transform: none;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
}
.es-expo .es-play svg {
	width: 40%;
	height: 40%;
	flex: none;
	fill: currentColor;
}
.es-expo .es-play svg.es-i-play {
	display: block;
	transform: translateX(6%);
}
.es-expo .es-play svg.es-i-pause {
	display: none;
}
.es-expo.is-playing .es-play svg.es-i-play {
	display: none;
}
.es-expo.is-playing .es-play svg.es-i-pause {
	display: block;
}

.es-expo .es-segs {
	flex: 1 1 auto;
	min-width: 0;
	display: flex;
	gap: 20px;
}
.es-expo .es-seg,
.es-expo .es-seg:hover,
.es-expo .es-seg:focus {
	position: relative;
	flex: 1 1 0;
	min-width: 0;
	height: 28px;
	padding: 0;
	margin: 0;
	border: 0;
	border-radius: 0;
	background: none;
	box-shadow: none;
	cursor: pointer;
}
.es-expo .es-track {
	position: absolute;
	left: 0;
	right: 0;
	top: 50%;
	height: 2px;
	margin-top: -1px;
	border-radius: 2px;
	background: var(--es-line-dim);
	overflow: hidden;
}
.es-expo .es-fill {
	position: absolute;
	left: 0;
	top: 0;
	bottom: 0;
	width: 0;
	border-radius: 2px;
	background: var(--es-line);
}
.es-expo .es-time {
	flex: none;
	box-sizing: content-box;
	text-align: right;
	color: var(--es-time);
	font-variant-numeric: tabular-nums;
	white-space: nowrap;
}

.es-expo .es-play:focus-visible,
.es-expo .es-seg:focus-visible {
	outline: 2px solid var(--es-line);
	outline-offset: 4px;
}

.es-empty {
	padding: 1em;
	border: 1px dashed currentColor;
	text-align: center;
}

@media (max-width: 640px) {
	.es-expo .es-player { gap: 12px; }
	.es-expo .es-segs { gap: 5px; }
	.es-expo .es-time { font-size: .85em; }
}

@media (prefers-reduced-motion: reduce) {
	.es-expo .es-stage img { transition-duration: .2s; }
	.es-expo .es-sub.is-in { transition-duration: 0s; }
}
