Fixing a few issues with margins
Switching to use attr over data (need the dom attribtues for styling; jquery uses internal cache for subsequent data calls)
Slight refactoring