The poem moves like a half-remembered dream, and its title, "Magical thinking," gives a clue: the speaker is trying to find meaning or luck in a world that offers neither. The opening image is strange. A pit acts as a guide, yet it rises out of the speaker's own "make-believe sand," so whatever direction it gives comes from invention rather than anything solid.
The second stanza asks a real question: is a lucky moment something imagined, or must one simply live in a nature that has "no cards for king and queen," meaning no ranks, no rules, no special fate waiting? Card imagery returns in the last stanza with the knave, whose mark is "buying love." The final line lands hard: the speaker finds his wife in bed with the plague. It is hard to say whether this is literal or symbolic, but either way it suggests love corrupted and hope turned to dread.
The mood is uneasy, wry, and quietly bitter, with a sense of someone gambling on comfort and losing.