In real life, most bugs try to avoid water, because if they touch it, they won't be able to fly. This is also the case with bees. For that reason, after at least half of their hitbox has been in contact with water, they have to walk. I think this would work the same as a potion effect, that lasts for a couple of minutes after they last got wet.
This effect will be given to them when they:
- Touch water
- Get hit by a Splash Potion of Water
- Get hit by a Lingering Potion of Water
- Are not in their hive when it's raining
- Are not in their hive during a thunderstorm
(The last two require some explanation. If the bee is hiding under a solid block, they will not get this effect. If they aren't hiding under a solid block or are in their hive, they will get the effect.)
This idea could be further expanded, for example, when they get hit by any Splash or Lingering potion. Or, when they are in a cold biome, and it starts to snow, they get hurt by the snow (not the blocks, the particles).