Final design. Work with logic