Add 404 page with smart redirection for broken links