The dust from the event is believed to have denied sufficient light to support photosynthesis and thus most plant life died. With that, herbivorous dinos died off, and then the carnivorous ones who depended on them for food.
That doesn't explain all the non-dino species that did survive, which also included herbivores and carnivores.
Why ALL non-avian dinosaurs, the big ones, the small ones, in all sorts of ecological niches died. But alligators, insects, avian dinosaurs, etc lived.
Why aquatic dinosaurs all died off, but fishes, squids, sharks, etc all lived.