As the gravitational force acts downward and the displacement of the bucket is upward, force acts opposite to the displacement of the body. The work done being a dot product of force and displacement vectors, becomes negative as cosine of 1800 is −1.