I’ve done this same thing. My dad lived on the other side of the country and it was a way for me to “take him out to eat” at a restaurant that he loved but was too expe dive for his tastes. Another time, I bought him a round of golf at a nice golf course that he would not treat himself to. He did not “believe” in gift cards wither, but on both occasions he mentioned that it was as if I took him to eat/golf and it was a nice gift for the guy who has everything.
I think your comment is the key. Many others tell what to do, but yours addresses the core in that you won’t be happy unless you decide or allow yourself to be happy (perception).
I used to mock those people who would say things like “smile in the mirror and tell yourself that it’s going to be a great day”. Later in life, I figured out that that’s what they needed to do, so good for them. For me, it’s something else. I need to be around nature to ground my feelings. Other times, it’s physical cardiac exertion, like a bike ride.
Medication can help if there’s a real medical problem, like depression. Self medicating can be dangerous.