Designing flat bands, localized and itinerant states in TaS2 trilayer heterostructures | Synapse