Have you ever encountered those times where you were walking on a grass patch looking straight ahead and your friend beside you suddenly screams, "Watch out for that dog &*#$ !!!".
*Phew*... thanks pal... then you step around the warm fresh pile of you know what. Just a few seconds later you both hear a yelp and spin around to find a very sexy lady frantically shaking off the poop from her shoes. "Wah heng ah !!! Could have been me!", you gleefully exclaim [Downward Counterfactual Thought: Reflecting on how a situation might have been worse]. Your friend, however approaches the lady and offers assistance and after the ordeal he returns with her number and you say, "Aiya!! I should have approached her first.. you very LuCkY ah!! [Upward Counterfactual Thought], and then, "Oh yah.. forgot I'm married hor... good thing my wife is so caring and loving [Downward Counterfactual Thought]".
Counterfactual thoughts are actually thoughts which focus on 'how a situation might have been otherwise', or 'how things might have been different'. As its name implies, it is a counter to a fact which currently exists.
As you have noticed, upward counterfactual thinking is related to negative thinking whereas upward counterfactual thinking is related to positive thoughts. Also related to upward and downward social comparison. As the textbook would have it, Upward Counterfactual focuses on 'wanting to improve' whereas for Downward Counterfactual it is on 'wanting to feel better'.
Also it is visible that upward counterfactual thinking often arouses negative emotions, which could generate ideas about how to avoid negative outcomes in future whereas downward counterfactual thinking often arouses positive emotions, which could be cleverly used to improve our mood or heal our self-esteem.
All my definitions are straight from the text...
cheers.