Hi, welcome to the forum.
Just to be clear, I believe you're saying that the "Before" image is the darker one on the right. Your contrast adjustment ("After") is the lighter image on the left. Correct?
To some degree, brightness and contrast adjustments are a matter of personal taste. Since you are new to Photoshop, I wonder if you're familiar with how to read the
histogram graph for the image. For example, when you open a Levels adjustment, it provides a histogram. I opened a Levels adjustment separately for each half of the Before & After (screen shot below). For either one, if you look where the red arrow is pointing it shows that the image lacks a substantial portion of the tonal scale for bright colors (approaching pure white). The histogram is suggesting that this image can still be brightened substantially—providing even more contrast—before the whites start to "blow out".
In my version down below (see the third image on the far right), I adjusted the white slider of the Levels adjustment to bring the brightest areas of the image much closer to pure white. The image now has the full range of luminosity from black to white. To me, this image now "pops" and is more pleasing. As I said, these things are a matter of personal taste. But I want to make sure that you're aware of what the histogram shows and what your options are.