Why not Markdown - pandoc - epub/pdf?
I really liked it because I have infinite layout control with LaTeX, and it’s a full blown programming language with if statements, operator overloading, functions, etc etc. makes it really easy to have one source document that does different things when outputting to different formats.