It is because calibre flattens all CSS, in order to ensure it works as best as possible across all devices.
The end result is that it looks the way it was supposed to, on the ereader screen, and looks like highly-confusing garbage in the internals -- on the theory that conversions are not usually meant to be edited.
You can use ebook-convert via the command-line and pass an output name without an extension to get it to write the un-flattened OEB directory to that location. Not really sure who would use that, actually... If you want to do anything with the HTML, do it before calibre converts it. And then it won't matter afterward, what calibre does to it.
|