– Set fonts using ems
Set the font size attribute in the body tag to 62.5 per cent like this:
body { font-size: 62.5% }
This makes one em roughly ten pixels (16 x 62.5% = 10). Now you can equate pixel sizes to ems. For example, type that is set in 12 pixels could be expressed as 1.2em; 9 pixels becomes 0.9em and so on.
– Space saver
Nobody likes building forms in HTML, especially as browsers insist on adding padding around them for no reason. Simply add the following CSS to your stylesheet: