It is OK to raise your price for any reason or none at all. If you think a higher price is profit maximizing, raise your price. If a competitor lowers their price to undercut you, that sounds like a great opportunity to raise your price to make it clear you beat them on quality.
Your effort matters zero -- customers will only see what they get, not what you do. BCC is five times as much code as I write for consulting clients, but they pay several orders of magnitude more for my work. Pricing based on the availability of other products only makes sense if you compete with them: ideally, you have ready answers for why you do not.