In reality, the website doesn't really know exactly what type of device you are using, but in our designs, it does know the width of the display. Based upon the width of the display, the site can decide how it should display content. For small windows, say smart phones in portrait mode like the iPhone, the site will put the menu at the top of the page to save valuable screen real estate. Content will be re-ordered such that is "stacks" into the smart phone browser window, rather than having you "pinch to zoom".
This also allows us to reveal or hide certain content depending on the device. For example, if we know you are browsing from a small format device like a mobile phone, we could assume you might be doing so when you ARE NOT using a wi-fi connection. As 3G connections tend to be much slower than wi-fi, we can optimize the content, images for example, for the slower bandwidth.
Take our client Bald Ridge Marina for example. It was important to this client for thier site to be easily navigable via mobile devices, because marina visitors often need directions when using mobile devices in thier car. The Bald Ridge Marina site presents a view completely optimized and formatted for smaller devices when viewed from a smart phone.