When clicking on any of those links, redirecting to an URL like “root/category/post-name/”, the 404 template is loaded,
If you remove the category_template
filter, are the links still 404?
For categories, your cpt post should appear in the list of posts in that category. So the url is root/category/
.
When clicking on any of those cpt links, the single template should load and the url would be root/project/post-name/