And the best solution for this is to create a separate space for bicycles that can't be accidentally violated without running into some sort of barrier. The next best thing is probably to include certain things in the the education for the drivers license that give people the empathy and perspective of what it feels like if you are on a bicycle and some asshole overtakes you with 70 km/h and half an arm of distance.
The Dutch cycling embassy website provides some basic principles on this: https://dutchcycling.nl/expertises/cycling-behaviour/ and on infrastructure https://dutchcycling.nl/expertises/cycling-infrastructure/