/* Image Crop Modal - Native style fullscreen */
#cropModal .modal-dialog {
    margin: 0;
    padding: 0;
    max-width: 100vw;
    width: 100vw;
    height: 100vh;
}

#cropModal .modal-content {
    width: 100vw;
    height: 100vh;
    border: none;
    border-radius: 0;
    background-color: #1a1a1a;
    display: flex;
    flex-direction: column;
}

/* Top toolbar */
#cropModal .crop-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background-color: #1a1a1a;
    flex-shrink: 0;
    padding-top: max(12px, env(safe-area-inset-top));
}

#cropModal .crop-title {
    color: #fff;
    font-size: 17px;
    font-weight: 600;
}

#cropModal .crop-btn {
    width: 44px;
    height: 44px;
    border: none;
    background: transparent;
    color: #fff;
    font-size: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 50%;
}

#cropModal .crop-btn:active {
    background: rgba(255, 255, 255, 0.15);
}

#cropModal .crop-cancel {
    color: #fff;
}

#cropModal .crop-confirm {
    color: #34C759;
}

/* Crop container - takes remaining space */
#cropModal .crop-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: #1a1a1a;
    padding: 0;
    min-height: 0;
}

#cropModal #croppr-image {
    max-width: 100%;
    max-height: 100%;
    display: block;
    visibility: hidden; /* Hidden until cropper initializes */
}

/* Cropper container styling */
#cropModal .cropper-container {
    background: #1a1a1a !important;
}

/* Dark semi-transparent overlay outside crop area */
.cropper-modal {
    background-color: rgba(0, 0, 0, 0.6) !important;
}

/* Crop box border */
.cropper-view-box {
    outline: 2px solid #fff !important;
}

/* Grid dashed lines */
.cropper-dashed {
    border-color: rgba(255, 255, 255, 0.4) !important;
}

/* Hide the blue lines on edges */
.cropper-line {
    background-color: transparent !important;
}

/* Corner handles - white circles, larger for touch */
.cropper-point {
    width: 18px !important;
    height: 18px !important;
    background-color: #fff !important;
    opacity: 1 !important;
    border-radius: 50% !important;
}

.cropper-point.point-nw,
.cropper-point.point-ne,
.cropper-point.point-sw,
.cropper-point.point-se {
    width: 22px !important;
    height: 22px !important;
}

/* Hide edge handles, only show corners */
.cropper-point.point-n,
.cropper-point.point-e,
.cropper-point.point-s,
.cropper-point.point-w {
    display: none !important;
}

/* Hide background pattern */
.cropper-bg {
    background-image: none !important;
}

.cropper-canvas {
    background: #1a1a1a !important;
}

/* Face box visibility */
.cropper-face {
    background-color: transparent !important;
}
