Mental well-being is shaped by the mind's ethical quality, determined by wholesome or unwholesome roots. Buddhist philosophy explains that engaging in kusala (wholesome) activities like generosity, ethics, and meditation produces calm and contentment, while akusala (unwholesome) activities driven by craving and aversion cause restlessness and suffering.