I recently added a custom webpart, and all pages started giving me a 404 error (even the root). I can get to central administration, but I don't see any errors either there, or in the event viewer. I'm not sure where else to check for error messages. I tried going to the site using http://siteurl./?contents=1, (which I understand is supposed to disable webparts) but that's not working either.
The site may want to use a master page that is not where the page is looking for it. To verify it, open the requested page in SharePoint Designer. If the master page is missing, it will give a more detailed error.