Undocumented teen obtains abortion after court battle