You might have a short in the headlight switch, that shorts when the parking light section of the headlight swtich is turned and it might be killing the brake lights somehow.
or......bulbs. Lol