img-comparison-slider {
  visibility: hidden;
}

img-comparison-slider [slot='second'] {
  display: block;
}

img-comparison-slider.rendered {
  visibility: inherit;
}



  img-comparison-slider {
    --divider-color: #fff; 
    --divider-width: 8px;
    outline: none;
    border-radius: 8px;
	  --default-handle-opacity: 1;
	  --divider-shadow:0 0 12px rgba( 51, 51, 51, 0.25); 
    --default-handle-width: 0; 
    --default-handle-opacity: 0;
  }

  .custom-handle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    background-color: #fff; 
    border-radius: 50%;
    box-shadow: 0 2px 15px rgba( 51, 51, 51, 0.25);
    cursor: grab;
	  overflow: hidden;
  }

  .custom-handle img {
    width: 100%;
    height: auto;
    user-select: none;
    -webkit-user-drag: none;
  }

  .custom-handle:active {
    cursor: grabbing;
    transform: scale(0.9); 
    transition: transform 0.2s;
  }


  figcaption {
    color: #fff;
    font-size: 30px;
    text-align: center;
    pointer-events: none;
    position: absolute;
    top: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 175px;
    height: 50px;
    border-radius: 5px;
    background: rgba(0, 0, 0, .2);
  }

  .before figcaption {
    left: 25px;
  }

  .after figcaption {
    right: 25px;
  }

  figure {
    margin: 0;
    position: relative;
  }

@media (max-width: 767.98px) {

  img-comparison-slider {
    --divider-width: 4px;
  }
img-comparison-slider.rendered {
	height: auto;
}

  .custom-handle {
    width: 32px;
    height: 32px;
    box-shadow: 0 2px 8px rgba(51, 51, 51, 0.2);
  }


  figcaption {
    top: 10px;      
    width: 80px; 
    height: 28px;   
    font-size: 14px; 
    border-radius: 3px;
  }


  .before figcaption {
    left: 8px;
  }
  .after figcaption {
    right: 8px;
  }
}
