Kindle Format 8 CSS
From MobileRead
This page is targeted at the supported CSS features in Amazon's KF8 format. They are likely to also work the same on ePub files.
[edit] Superscript CSS
For sup tag CSS that doesn't mess with the line height:
sup { font-size: 0.65em; line-height:0.65em; }
[edit] Nice Dropcap
For a dropcap that aligns nicely:
.dropcap {
line-height: 100%;
font-size: 341%;
margin-right: 0.075em;
margin-top:-0.22em;
float:left;
height:0.8em;
}
/* This works after an "L" as well. If you really want to finely tune, probably "L" and "J" should have some work done; I haven't done enough testing to make sure it works through font changes and font-size changes yet. */
span.afterA { margin-left: -0.5em; }
line-height: 100%;
font-size: 341%;
margin-right: 0.075em;
margin-top:-0.22em;
float:left;
height:0.8em;
}
/* This works after an "L" as well. If you really want to finely tune, probably "L" and "J" should have some work done; I haven't done enough testing to make sure it works through font changes and font-size changes yet. */
span.afterA { margin-left: -0.5em; }
See also: Kindle Idiosyncracies