I can (road) bike with an Airpod fairly securely in. For longer rides where I want to listen to a podcast, a little bit of surgical tape brings even more security.
You may be aware of this, but the recommended way to wear Airpods (especially the 3rd gen non-Pro?) is to twist the stalks towards your face to 'lock' them into place better.
(I discovered this when I was about to angrily throw out my new 3rd gen Airpods, as they were fatter than my original gen 1 model, and just wouldn't stay in place. I've never seen anyone else doing this [and I sometimes get comments from people for wearing mine oddly] but it's a game-changer.)
https://www.reddit.com/r/airpods/comments/qgqo5a/psa_if_the_...