This is what I’ve created. I’m setting class='handHeld' to <body> in iPad, based on which
the optionsWrapper and #container should switch positions using CSS classes I’ve defined at the bottom in jsfiddle.net.
.handHeld div.optionsWrapper { ... }
.handHeld div#container { ... }
to something like this: 
How to achieve that using CSS only? Please note that first 3 rows (green, gray and blue) may
not be present always so I can not grab their height statically to position div.optionsWrapper?
Since
optionsWrapperis a child ofcontainer, you cannot do this via CSS. You must have the two divs side by side as start. Then, one of the two divs must have an absolute height (in px). And last but not least, thepositionstyle of their parent must berelative. Having the parent relative, settingabsolute left/top:0on optionsWrapper should put it in top left corner of container.Easiest illustrated via inline styles here:
with no ‘handheld’, your standard styling (but with options ‘outside’)
when body has the ‘handheld’ class:
http://jsfiddle.net/QzQCt/