The color attribute is used to provide a potential indirect value, currentcolor, for the fill, stroke, stop-color, flood-color, and lighting-color attributes.
Mind you, I am still mystified as to how you've "reverse engineered" the gradient fills and the layered shapes, so to me it is still like you're dealing up magic.