Improved path resolution