Just a play with words.
Like a black horse, a mare, so it may become a nightmare - different meaning here of course.
The original meaning comes from "Alb" and thus Albtraum, but since language changes "Alptraum" is now also official writing.
The sound of both words is the same anyway.
An Alb (also Elb, Elben etc.) is a natural spirit, they are also called "Elfen" or "elves" in english (or should i say anglisch). If you have a dream that frightens you, you probaly dreamt of some strange supernatural creatures.
Albs are inituially described as creatures of light, or white foglike creatures, but there are also the dark black (negative) albs.
(Picture by August Malmstroem)