I haven't experience losing concentration on a ride, I have fiddled a bit with my computer and wandered a bit, but nothing to where I was going off the road.
About 4 years ago, at 61, one of our sons got me to try mountain biking. I can tell you that if you want to improve concentration, ride in the dirt. Even trails that are not very technical require attention as there is always something to be aware of on the trail.
John