How can I track inventory for customizable product parts?

I am selling different costumizable produtcs. some do have part similar.
f.e. i am selling a blue car with red lights.

how can i set up the product so that “red lights” does have its own inventory?