Headlights:
I don't know the real structure of this car headlight, so I thought of it bymyself.
Rearlight:
You can use the same technique as in headlight.