That’s ok, you’ve given us more than enough now. I don’t see any hair loss to be concerned about. Your hair thins out and recedes a bit as you age. This is all that’s going on here.
That being said, dandruff, particularly if it’s caused by sebhorreic dermatitis, can cause temporary thinning depending on how much you pick at it, how roughly you do so, and how severe the build up is. The condition itself doesn’t cause hair loss on its own, but scratching the affected area can damage your follicles. Additionally, if you don’t exfoliate the build up regularly it can clog up your hair follicles.
The good news is that hair lost as a secondary effect of the condition isn’t permanent and should return once the condition is dealt with. Get that under control and most, if not all, hair affected by it will return.