Separate JS code + Create total history graph + CSS fix