/* Reorder Manager Styles */

.reorder-toggle-btn {
    margin: 16px 0;
}

/* Reorderable Item Modifications */
.reorder-mode {
    cursor: grab;
    transition: all 0.25s ease-out;
    user-select: none;
    margin-bottom: 0;
}

.reorder-mode:first-child {
    position: relative;
}

/* Generic drag handle styling - can be customized per implementation */
.reorder-drag-handle,
.job-step-drag-handle {
    position: absolute;
    left: 8px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    font-weight: bold;
    color: var(--grey-400);
    line-height: 1;
    cursor: grab;
    padding: 4px;
    user-select: none;
    z-index: 10;
}

.reorder-drag-handle:hover,
.job-step-drag-handle:hover {
    color: var(--brand-green);
}

.reorder-drag-handle:active,
.job-step-drag-handle:active {
    cursor: grabbing;
}

/* Placeholder for drag position */
.reorder-placeholder,
.job-step-reorder-placeholder {
    background-color: var(--grey-300);
    border-radius: 6px;
    height: 6px;
    width: 100%;
}

.placeholder-content {
    color: var(--brand-green);
    font-weight: 500;
    font-size: 14px;
}

/* Dragging state */
.dragging {
    transition: none !important;
    will-change: transform;
    z-index: 1000;
}

/* Instructions */
.reorder-instructions {
    margin-bottom: 16px;
}

/* Mobile-specific adjustments */
@media (max-width: 768px) {
    .reorder-mode h3,
    .reorder-mode .item-title {
        font-size: 15px;
        line-height: 1.3;
    }
    
    .reorder-drag-handle,
    .job-step-drag-handle {
        font-size: 16px;
    }
}

/* Touch-friendly drag handle for mobile */
@media (pointer: coarse) {
    .reorder-drag-handle,
    .job-step-drag-handle {
        left: 12px;
        font-size: 16px;
        padding: 8px;
    }
    
    .reorder-mode {
        cursor: default;
        -webkit-touch-callout: none;
        -webkit-user-select: none;
        -khtml-user-select: none;
        -moz-user-select: none;
        -ms-user-select: none;
        user-select: none;
    }
}

/* Job Step Specific Styles (for backwards compatibility) */
.job-step-container.reorder-mode .job-step-header {
    position: relative;
}

.job-step-container.reorder-mode .job-step-header h3 {
    margin-left: 20px;
}

.job-step-container.reorder-mode .job-step-hazards {
    display: none;
}

@media (pointer: coarse) {
    .job-step-container.reorder-mode .job-step-header h3 {
        margin-left: 24px;
    }
} 