refactored main

css is broken I'm doing something stupid with z-indexes but can't
figure it out