Hello,
I had the same need, applied your code and got the template working.
As a matter of fact, though, I need to have a mobile version of the website. I tried applying the built-in facility in the template I'm using (JSN Epic) and, as a result, I have the text all in one column of the width of a letter... How can I solve the problem?
You can see what it looks like from the attachment.