MVC3 exposes an IsMobileDevice flag in the Request.Browser object.
So in your razor code, you can query this variable and render accordingly.
For example, in your view (razor):
@if (Request.Browser.IsMobileDevice) {
<!-- HTML here for mobile device -->
} else {
<!-- HTML for desktop device -->
}