Structure of differentiated planetesimals: A chondritic fridge on top of a magma ocean