A hunch and a little bit of googling have led me to conclude that what I saw today were probably terrestrial leeches. I never knew there was such a creature as a terrestrial leech. I thought they only lived in fresh water, but I found out there are indeed ones that live in leaf litter and damp soil -- and there was plenty of both under the shrubs! (There are also species of marine leeches as well.) They feed on worms, snails, insect larvae, etc., but this kind does not suck blood.
In dry weather, some terrestrial species burrow in the soil where they can survive for many months even in a total lack of environmental water. In these conditions the skin gets completely dry and they go into a kind of estivation, but within a few minutes of sprinkling with a few drops of water, these leeches emerge, fully active.
I find stuff like this fascinating. I will never tire of the wonder of the world I live in.