Here are a few things going on. First of all, the HTML / CSS parser in iText and iTextSharp is far from complete. They are definitely very powerful, but there are still ways to go. Each version is getting better, so always make sure you are using the latest version.
Secondly, I saw more HTML / CSS actions in an add-on for iText / iTextSharp called XMLWorker, which you can look at. You no longer load styles, you just go through raw HTML / CSS, and it calculates a lot of things. You can see examples here, see the list of supported CSS attributes , download it here (and get two missing files here and here ).
Third, LoadTagStyle designed to load style attributes for HTML tags, not CSS identifiers or classes. You want to use LoadStyle to load by class:
styles.LoadStyle("<classname>", "<attribute>", "<value>");
Unfortunately, this method still does not do what you want it to always do. For example, to change the font size that you would say:
styles.LoadStyle("headerdiv", "font-size", "60ptx);
But to make it work, you can only use relative HTML font sizes (1,2, -1, etc.) or PT sizes, and you should use the size property:
styles.LoadStyle("headerdiv", "size", "60pt"); //or styles.LoadStyle("headerdiv", "size", "2");
LoadStyle honestly feels like an afterthought that was only partially completed, and I recommend not actually using it. Instead, I recommend writing style attributes directly on the line if you can:
string html = "<div id=\"personal\" class=\"headerdiv\" style=\"padding-left:50px;font-size:60pt;font-family:Cambria;font-weight:700;\">Personal Data</div>";
Obviously, this defeats CSS points and again why they are working on the new XMLWorker above.
Finally, to use fonts by name, you first need to register them in iTextSharp, they will not look for them:
iTextSharp.text.FontFactory.Register(@"c:\windows\fonts\cambria.ttc", "Cambria");