Logic behing the Layout - UNDER CONSTRUCTION