I had issues with Logitech over the years and found two main causes.
1. Battery degradation meant the mouse would appear charged but have variable lag at unpredictable times.
2. Too many devices using Bluetooth/wifi located in the same desk space.
Switching bluetooth off on some unused devices, headphones, tablet, spare laptop (or switching them off completely) to reduce interference did help