I encountered something strange in KEPUB yesterday. The book CSS contains this (among a few other things):
Code:
h1 {
text-align: center;
font-size:1.5em;
margin:1.5em 0em 1.5em 0em;
font-weight: bold;
}
span.smallcaps {
text-transform:uppercase;
font-size:80%;
}
p.left {
text-indent: 0em;
margin-top:0em;
margin-bottom:0em;
text-align:justify;
}
p.follow {
text-indent: 1.5em;
margin-top:0em;
margin-bottom:0em;
text-align:justify;
}
The book opens with an h1 header, then p.left with span.smallcaps, then p.follow for subsequent paragraphs. When I open the XHTML file in my browser, everything looks normal, but on my Kobo, the body text is smaller than it should be.
Is it the case that WebKit does not reset font sizes when moving from one CSS class to another, and it's necessary to specify font-size:1em/100%/medium in order to reset the font to the default size after any class that might change it? The only explanation I can think of is that the smallcaps 80% size is being misapplied to p.left and p.follow, since they don't specify a font-size of their own.