﻿.croppie-container {
    width: 100%;
    height: 100%;
}

.croppie-container .cr-image {
    z-index: -1;
    position: absolute;
    top: 0;
    left: 0;
    transform-origin: 0 0;
    max-height: none;
    max-width: none;
}

.croppie-container .cr-boundary {
    position: relative;
    overflow: hidden;
    margin: 0 auto;
    z-index: 1;
    width: 100%;
    height: 100%;
}

.croppie-container .cr-viewport,
.croppie-container .cr-resizer {
    position: absolute;
    border: 2px solid #fff;
    margin: auto;
    top: 0;
    bottom: 0;
    right: 0;
    left: 0;
    box-shadow: 0 0 2000px 2000px rgba(0, 0, 0, 0.5);
    z-index: 0;
}

.croppie-container .cr-resizer {
  z-index: 2;
  box-shadow: none;
  pointer-events: none;
}

.croppie-container .cr-resizer-vertical,
.croppie-container .cr-resizer-horisontal {
  position: absolute;
  pointer-events: all;
}

.croppie-container .cr-resizer-vertical::after,
.croppie-container .cr-resizer-horisontal::after {
    display: block;
    position: absolute;
    box-sizing: border-box;
    border: 1px solid black;
    background: #fff;
    width: 10px;
    height: 10px;
    content: '';
}

.croppie-container .cr-resizer-vertical {
  bottom: -5px;
  cursor: row-resize;
  width: 100%;
  height: 10px;
}

.croppie-container .cr-resizer-vertical::after {
    left: 50%;
    margin-left: -5px;
}

.croppie-container .cr-resizer-horisontal {
  right: -5px;
  cursor: col-resize;
  width: 10px;
  height: 100%;
}

.croppie-container .cr-resizer-horisontal::after {
    top: 50%;
    margin-top: -5px;
}

.croppie-container .cr-original-image {
    display: none;
}

.croppie-container .cr-vp-circle {
    border-radius: 50%;
}

.croppie-container .cr-overlay {
    z-index: 1;
    position: absolute;
    cursor: move;
    touch-action: none;
}

.croppie-container .cr-slider-wrap {
    position: relative;
    width: 85%;
    max-width: 360px;
    margin: 15px auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-zoom-step {
    width: 32px;
    height: 32px;
    min-width: 32px;
    border-radius: 50%;
    border: 1px solid #cbd5e1;
    background: #ffffff;
    color: #334155;
    font-size: 18px;
    font-weight: bold;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    transition: all 0.2s ease;
    user-select: none;
}

.btn-zoom-step:hover {
    background: #198754;
    border-color: #198754;
    color: #ffffff;
    transform: scale(1.08);
}

.btn-zoom-step:active {
    transform: scale(0.95);
}

.croppie-result {
    position: relative;
    overflow: hidden;
}

.croppie-result img {
    position: absolute;
}

.croppie-container .cr-image,
.croppie-container .cr-overlay,
.croppie-container .cr-viewport {
    -webkit-transform: translateZ(0);
    -moz-transform: translateZ(0);
    -ms-transform: translateZ(0);
    transform: translateZ(0);
}

/*************************************/
/***** CUSTOM ZOOM SLIDER         ****/
/*************************************/

/* Hide the native range input - we use a custom div slider instead */
.cr-slider {
    display: none !important;
}

/* Custom slider track */
.cr-custom-track {
    position: relative;
    flex: 1;
    height: 6px;
    background: #cbd5e1;
    border-radius: 6px;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
}

/* Bidirectional fill from center */
.cr-custom-fill {
    position: absolute;
    top: 0;
    height: 100%;
    background: #198754;
    border-radius: 6px;
    pointer-events: none;
}

/* Center tick mark */
.cr-custom-center {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 2px;
    height: 14px;
    background: #0d6efd;
    border-radius: 1px;
    pointer-events: none;
    opacity: 0.7;
    z-index: 1;
}

/* Draggable thumb */
.cr-custom-thumb {
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #ffffff;
    border: 2.5px solid #198754;
    box-shadow: 0 2px 6px rgba(0,0,0,0.25);
    cursor: grab;
    z-index: 2;
    transition: box-shadow 0.1s ease, transform 0.1s ease;
    /* start at center */
    left: 50%;
}

.cr-custom-thumb:active,
.cr-custom-thumb.dragging {
    cursor: grabbing;
    transform: translate(-50%, -50%) scale(1.15);
    box-shadow: 0 3px 10px rgba(25,135,84,0.45);
}

/*******************************************/

/***********************************/
/* Rotation Tools */
/***********************************/
.cr-rotate-controls {
	position: absolute;
	bottom: 5px;
	left: 5px;
	z-index: 1;
}
.cr-rotate-controls button {
	border: 0;
	background: none;
}
.cr-rotate-controls i:before {
	display: inline-block;
	font-style: normal;
	font-weight: 900;
	font-size: 22px;
}
.cr-rotate-l i:before {
	content: 'â†º';
}
.cr-rotate-r i:before {
	content: 'â†»';
}