Im not sure if your asking for input but if you are here are the thoughts of a novice.
It seems when the bishop pins the knight to the queen it would have been preferable to move the h7 pawn to h6 rather than pushing the d7 pawn to d6. I think h6 is better becuase exchanging a knight for a bishop is slightly in your favor(I am given to understand bishops are worth 3.25 while knights are worth 3 in theory.) The alternative would be to retreat with the bishop loosing a tempo (I think thats how that word is used) becuase the h6 move also gives your king an escape rought which might be useful later in the game.
Ultimatly I should have moved my knight I had many opportunites.