Just to add to this, my issue doesn't seem to be limited to a particular range; all autofocus functionality is not working. Manual focus works correctly, but in apps that do not allow manual focus this prevents any images from being taken (eg: in Google Pay the device is unable to focus on barcodes or QR codes, and there is no option to manually do so. I'm pretty sure this was working when I first bought the phone in October last year so not sure what has caused it to stop since then? I've tried carrying out a factory reset but this didn't help unfortunately.