reworked
further semplification
Prevent range position inside trees with offset position