Hello everyone, I hope someone can answer my question quickly and correctly

I recently bought a 03 Grand Prix and just noticed an issue with my driver's side brake light. The center bulb (brake and turn) will light when I apply brakes or switch on the turn signal. However if the headlights are on, it does not illuminate. I have swapped out bulbs and changed out the socket for the light, as it had become dirty and slightly corroded from moisture.

I think this rules out a switch or other issue towards the front of the car, and is a case of damaged wire further up the line. Does anyone have a diagram of those wires or can simply tell me the breakdown for each of those wires in the bulb socket? I can gather the black one labeled "G" is ground, but the others are a brown and green wire, in a slot labelled "A" and "B."

A friend of mine has shown me a way to jury-rig the wires to the other brake light, but I don't know which wire is for what purpose. A somewhat messy solution, but I'm not sure I have the tools or resources to properly trace the problem (I don't have a test light or volt meter to simply plug in and test it)

I am open to suggestions and would appreciate and help! Thank you!