When adding CSS in civimail (under source) getting an error when trying to see or send test
You will need to add your style sheet inside {literal} when adding stylesheet in Message template. For example 

{literal}
&lt;style&gt;
 your code
&lt;/style&gt;
{/literal}