refactored sections visibility filtering