A woman opened fire at YouTube's headquarters in the San Francisco Bay Area Tuesday, wounding three people before she shot and killed herself and prompted panic as employees hid and tried to flee, police and witnesses said.