layout and code revamp