Currently you can configure a page to be displayed when no page can be found for a friendly url by setting the layout.friendly.url.page.not.found property in portal.properties
However there are many other cases that result in a 404 error for which you currently cannot configure a nicer looking 404 page.
Like when you enter an url of the sorts : /c/message_boards/find_thread?p_l_id=10633&threadId=10415 and the thread cannot be found.
It would be nice if we could configure a page that would be used in all cases that would normally return a 404 status. I looked at the code in PortalImpl and it does not look like this would be hard to add at all.