I am trying to find a way to count unique values in a list, based on multiple criteria. The problem is, the list is thousands of rows long, and i need to count the unique values for EACH of several products, and each product will have a different range. I assume I have to somehow combine SUMIF and dynamic ranges, but I'm stumped.

Specifically, my data is like this:

Product Run Color

A 1 Red

A 1 Blue

A 1 Green

B 1 Red

B 1 Green

A 2 Orange

A 2 Red

C 1 Blue

I need to know the number of different colors I made for EACH product, in EACH separate run, i.e. product A, run 1, 3 colors; product A run 2, 2 colors; etc.

I have MANY different products, each with MANY separate runs, and each run may have anywhere from 1-10 different colors.

Any ideas? Thanks in advance.