.ade-before-after {
	--ade-position: 50%;
	position: relative;
	width: 100%;
	height: 420px;
	overflow: hidden;
	background: #f3f3f3;
	box-shadow: 0 12px 32px rgba(0, 0, 0, 0.14);
	isolation: isolate;
}

.ade-before-after,
.ade-before-after * {
	box-sizing: border-box;
}

.ade-img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	user-select: none;
	pointer-events: none;
}

.ade-after-img {
	z-index: 1;
}

.ade-before-wrap {
	position: absolute;
	inset: 0;
	z-index: 2;
	clip-path: inset(0 calc(100% - var(--ade-position)) 0 0);
}

.ade-before-img {
	z-index: 2;
}

.ade-handle {
	position: absolute;
	top: 0;
	left: var(--ade-position);
	z-index: 5;
	height: 100%;
	transform: translateX(-50%);
	pointer-events: none;
}

.ade-handle-line {
	display: block;
	width: 4px;
	height: 100%;
	background: rgba(255, 255, 255, 0.95);
	box-shadow: 0 0 12px rgba(0, 0, 0, 0.35);
}

.ade-handle-button {
	position: absolute;
	top: 50%;
	left: 50%;
	width: 46px;
	height: 46px;
	border-radius: 50%;
	transform: translate(-50%, -50%);
	background: #fff;
	color: #222;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 20px;
	font-weight: 700;
	box-shadow: 0 4px 18px rgba(0, 0, 0, 0.25);
}

.ade-range {
	position: absolute;
	inset: 0;
	z-index: 10;
	width: 100%;
	height: 100%;
	margin: 0;
	opacity: 0;
	cursor: ew-resize;
}

.ade-label {
	position: absolute;
	top: 16px;
	z-index: 6;
	padding: 7px 12px;
	border-radius: 999px;
	background: rgba(0, 0, 0, 0.62);
	color: #fff;
	font-size: 13px;
	font-weight: 700;
	line-height: 1;
	letter-spacing: .02em;
	backdrop-filter: blur(4px);
}

.ade-label-before {
	left: 16px;
}

.ade-label-after {
	right: 16px;
}

@media (max-width: 767px) {
	.ade-handle-button {
		width: 40px;
		height: 40px;
		font-size: 18px;
	}
}
