/* Container */
.ic-36977-container {
	position: relative;
	width: 100%;
	height: 400px; /* Default height, overridden by control */
	overflow: hidden;
	user-select: none;
	-webkit-user-select: none;
	touch-action: none;
	margin: 0;
	padding: 0;
	box-sizing: border-box;
	border-radius: inherit;
    isolation: isolate; 
    display: block !important; /* Force block to ignore flex parents */
}

/* Images Wrappers - STRICT FULL SIZE */
.ic-36977-img {
	position: absolute;
	top: 0;
	left: 0;
	width: 100% !important;
	height: 100% !important;
	margin: 0 !important;
	padding: 0 !important;
	border: none !important;
	display: block !important;
	pointer-events: none;
    overflow: hidden;
    flex: none !important; /* Prevent flex shrinking */
}

/* Actual Images - STRICT FILL */
.ic-36977-img img {
	display: block !important;
	width: 100% !important;
	height: 100% !important;
	object-fit: cover !important;
	object-position: center !important;
	max-width: none !important;
	min-width: 0 !important;
	min-height: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	border: none !important;
    transform: none !important;
    transition: none !important;
    flex: none !important;
}

/* Before Image (Top Layer) */
.ic-36977-img-before {
	z-index: 2;
	clip-path: inset(0 50% 0 0); 
	-webkit-clip-path: inset(0 50% 0 0);
    will-change: clip-path;
}

/* After Image (Bottom Layer) */
.ic-36977-img-after {
	z-index: 1;
}

/* Labels */
.ic-36977-label {
	position: absolute;
	z-index: 3;
	padding: 5px 10px;
	border-radius: 4px;
	font-size: 14px;
	font-weight: bold;
	pointer-events: none;
	transition: opacity 0.3s ease;
	white-space: nowrap; 
	line-height: 1.2;
}

.ic-36977-label-before {
	left: 20px;
}

.ic-36977-label-after {
	right: 20px;
}

/* Overlay */
.ic-36977-overlay {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	pointer-events: none;
	z-index: 2;
}

/* Handle */
.ic-36977-handle {
	position: absolute;
	top: 50%;
	left: 50%;
	z-index: 10;
	cursor: ew-resize; 
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 0 10px rgba(0,0,0,0.3);
	pointer-events: auto; 
    will-change: left, top;
}

.ic-36977-handle-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	pointer-events: none;
	z-index: 2;
}

.ic-36977-handle-line {
	position: absolute;
	top: -5000px;
	bottom: -5000px;
	width: 2px;
	z-index: -1;
	background-color: #fff;
	margin-left: -1px;
}

/* Vertical Orientation Support */
.ic-36977-container[data-orientation="vertical"] .ic-36977-handle {
	cursor: ns-resize;
}

.ic-36977-container[data-orientation="vertical"] .ic-36977-handle-line {
	top: auto;
	bottom: auto;
	left: -5000px;
	right: -5000px;
	height: 2px;
	width: auto;
	margin-left: 0;
	margin-top: -1px;
}

.ic-36977-container[data-orientation="vertical"] .ic-36977-img-before {
	clip-path: inset(0 0 50% 0);
	-webkit-clip-path: inset(0 0 50% 0);
}

/* Transition for smooth movement */
.ic-36977-is-animating .ic-36977-img-before {
	transition: clip-path 0.2s ease-out, -webkit-clip-path 0.2s ease-out;
}
.ic-36977-is-animating .ic-36977-handle {
	transition: left 0.2s ease-out, top 0.2s ease-out;
}
