Hi Jerry, Welcome to MR!
Unfortunately the answer to your questions is mostly: it depends.
The ePub3 standard is based on html5 but only certain parts of it are supported. Also, only certain functions of scripting are supported. MR has a wiki that talks about
ebook production and you can find in there more specifics about
html5. That certainly isn't all there is to know, but it'll get you started. You may also find it interesting - in a sharp-stick-in-the-eye kind of way - to read the
ePub3 standards.
Cheers!