Improved view & layout logic