I've been maintaining my own bike for a while now, the one thing I haven't been able to fix is the pedals wobbling. This is a little hard to describe but hopefully it's understandable, and I've attached some pictures. The pedals wobble perpendicular to the crank arm, i.e. they move vertically. When I am riding, I hear a clicking noise especially when I'm pedalling hard, which I think is the pedal wobbling in the same way, but under more load. I've done a lot of googling and all I've found is either steps on removing the pedal (which I don't think is the issue as it seems tightly attached to the crank arm) or steps on fixing the crank arm itself, which I also don't think is the problem. Again having said all that, I'm very much new to this, so any corrections or advice would be massively appreciated. I did have a mechanic address this problem about a year ago, he mentioned it was difficult to adjust my pedals specifically but he was able to fix it, although I didn't ask him at the time exactly what he did. My concern is that if I don't fix this, it may cause damage elsewhere and lead to more expensive replacements.
The bike is a Trek FX 7.4, I haven't replaced any of the pedal or crank components but I also am not sure specifically what model the pedals are, although I can probably try to dig this up if it's helpful!