Looks like a typical cooler and based on everything about the hand and what you've said about the villain, the only mistake you made was the somewhat light 3 bet preflop. I'm sure he would've called that with even a lesser hand then 5s, given what you said about him. Everything else, position of players in hand, trips with decent kicker, etc. was just bad luck for you. Villain played it well and got you committed by the river.