Alrighty, yeah that's most likely the culprit then which is a bit easier at least to deal with than having SBD all the time. So for now just keep his lights out, tonight cover his tank with a towel if you have a spare one; the total darkness should help him calm down and chill out and it should raise the heat a little bit for him to be comfortable.
If you can, can you get either New Life Spectrum or Omega One Betta pellets? Those are top end quality food right now (I and my fish prefer NLS over Omega though) and they are much better to feed a fish who has potential issues with his swim bladder. With these pellets you can also feed him a little more; 3-4 at each feeding since he does need food still and they don't swell as much as other foods do which means they can eat more and use more of it. The things you want to look for on foods are fillers; fillers are bad, they are anything that consists of Wheat, Corn and Soybean.
The first three ingredients are what makes up the majority of the food so you can just look at those, if there are fillers in the first three then it's probably not a good food. Omega has no fillers in it's first three, making it one of the best foods you can get (only 3 dollars something for a bottle as well that will last you a looong time). NLS does have one filler but it makes up for it by having garlic and spirulina in it's formula. Garlic is a natural anti-parasitic food and Bettas loooooove it! Not saying it will prevent your fish from internal parasites, but it certainly does help ward them off! And I know my fish absolutely go nuts over this stuff as well
Again, only 4 dollars and something generally for a larger container than Omega and that will last you and even looooooooonger time! Still have mine and it's almost a year old, just now making a dent in it! lol and I've even spilled some XD
And no worries, we all start somewhere and all we have to go is up from there! Ask all the questions you need, whether you think they're silly or not; it could save your Betta's life if you do