Funnily enough, they don’t have blue pigments! I don’t understand the exact physics, but from what I understand they have yellow pigment that lies underneath a layer of cells that reflect blue light back, which combine to make green. But if you were to isolate the yellow pigment it would still look yellow, while the blue reflecting cells only look blue in specific lighting conditions.