For a straight-text book, actually, Markdown is excellent. You can include images, or for technical content, tables, easily.
Technical papers with formulae and complex references are slightly more detailed, but that ends up being gloss. Even LaTeX for a simple text is quite minimal (though you need the starting template).
Source: I've made something of a hobby of marking up source docs into HTML, LaTeX, and Markdown. Of the set, Markdown would be my first go-to, and I've used it for some book-length projects.
Example here: https://ello.co/dredmorbius/post/lhw2eq4qmnnwxijlcrfyba