Fixed the error of the undefined exception element.
Fixed the ending if brace.
Removed global styles and attached them to the block they are used.