Simpler 404/500 handler functions (fewer imports)