Mudita
Mudita (Pāli and Sanskrit: मुदित) in Buddhism is joy. It is especially sympathetic or vicarious joy, the pleasure that comes from delighting in other people's well-being rather than begrudging it. The traditional paradigmatic example of this mind-state is the attitude of a parent observing a growing child's accomplishments and successes, but it is not to be confounded with pride as the person feeling mudita must not have any interest or direct income from the accomplishments of the other. If we can be happy when other people are healthy and prosperous, it is called Muditha; the opposite word is jealousy.
Application
Mudita meditation is used to cultivate appreciative joy at the success and good fortune of others. It is used to counteract the resentment, jealousy, or envy often experienced at another's success.
Many Buddhist teachers interpret joy more broadly as an inner spring of infinite joy that is available to everyone at all times, regardless of circumstances. The more deeply one drinks of this spring, the more secure one becomes in one's own abundant happiness, and the easier it then becomes to relish the joy of other people as well.
Joy is also traditionally regarded as the most difficult to cultivate of the four immeasurables (brahmavihārā: also "four sublime attitudes"). To show joy is to celebrate happiness and achievement in others even when we are facing tragedy ourselves.
According to Buddhist teacher Ayya Khema showing joy towards sadistic pleasure is wrong. Here there should instead be compassion (karuṇā).
The "far enemies" of joy are jealousy and envy, two mind-states in obvious opposition. Joy's "near enemy," the quality which superficially resembles joy but is in fact more subtly in opposition to it, is exhilaration, described as a grasping at pleasant experience out of a sense of insufficiency or lack.