much nicer setup/breakdown for retrieving element offset