fixed margin and updated some functions + demo