Scriv ePubs don't render properly on Nook SimpleTouch

Hi guys. This is actually more of a Nook bug than a Scrivener bug, but I’m hoping that a workaround would be easy to program.

The ePubs that Scrivener generates use a shorthand notation to define margin sizes in CSS stylesheets:

margin: 0.0em 0.0em 0.0em 0.0em;

But when you transfer such an ePub to a Nook SimpleTouch, it comes out like this…

However, if you manually edit the ePub’s stylesheets, and define the margin sizes using the full notation…

margin-top: 0.0em; margin-right: 0.0em; margin-bottom: 0.0em; margin-left: 0.0em;
…then the ePub renders properly:

Like I say, it’s not really Literature & Latte’s fault that the Nook doesn’t understand perfectly valid CSS. But if you could program a workaround, then perhaps a great many writers would be spared from either manually adjusting stylesheets or getting one-star reviews for poor ebook formatting.

Many thanks for your time and trouble,
John.

Ouch, that’s painful. Part of the problem here is that the HTML is generated by standard OS X routines, so I have to post-process them to fix them up, which isn’t pretty. I’ll have a look to see what I can do, though - the fix might only work on 10.7+ as the best way to do it will be using regular expressions (which are only available in code from 10.7 onwards).
Thanks and all the best,
Keith