The decision set off a prolonged fight over abortion access across the country and has played a major role in state and national elections.