One way is to use the Url-Rewrite extension.
You can then use a rule like this to catch all requests:
<system.webServer>
...
<rewrite>
<rules>
<rule name="SiteDown" stopProcessing="true">
<match url=".*" />
<action type="CustomResponse" statusCode="503" statusReason="Down for maintenance" statusDescription="will be back up soon" />
</rule>
</rules>
</rewrite>
</system.webServer>
This takes care of the Search Engines, for the users you can add the following:
<system.webServer>
...
<httpErrors existingResponse="Auto" errorMode="Custom" defaultResponseMode="File">
<remove statusCode="503" subStatusCode="-1" />
<error statusCode="503" path="503.html" />
</httpErrors>
</system.webServer>
and then put a 503.html file in the root of your site which has a nice error message.
Because you can not use styles or images in the page that are on the site itself, you need to link to another site or put all styles and images inline in the html page.