You may be facing problems with 404 errors for custom post types while viewing detail pages. To resolve to try the following steps:
1. Check your permalinks from your WordPress settings and set them on the post name. As by default, according to the WordPress official standards permalinks must be on post name
Navigate Dashboard > Settings > Permalinks > Post name.
2. Ensure that none of your Custom Post Types and single pages have the same name. If they do, rename the single page, including updating the slug as well.