pub fn path_to_string(path: &Path) -> String
Safely converts a path to a string, handling non-UTF-8 paths gracefully.
Uses lossy conversion (replacement character � for invalid UTF-8).