leader of the party after Hayden resigned to avoid a leadership spill. Bob Hawke led Labor back to office at the 1983 federal election and the party won four consecutive elections under Hawke. In December 1991 Paul Keating defeated Bob Hawke in a leadership spill. The ALP then won the 1993 federal election. It was in power for five terms over 13 years, until severely defeated by John Howard at the 1996 federal election. This was the longest period the party has ever been in government at the national level. Kim Beazley led the party to the 1998 federal election, winning 51 percent of the two-party-preferred vote but falling short on seats, and the ALP lost ground at the 2001 federal election. After a brief period when Simon Crean served as ALP leader, Mark Latham led Labor to the 2004 federal election but lost further ground. Beazley replaced Latham in 2005; not long afterwards he in turn was forced out of the leadership by Kevin Rudd. Rudd went on to defeat John Howard at the 2007 federal election with 52.7 percent of the two-party vote (Howard became the first Prime Minister since Stanley Melbourne Bruce to lose not just the election but his own parliamentary seat). The Rudd Government ended prior to the 2010 federal election with the overthrow of Rudd as leader of the Party by deputy leader Julia Gillard. Gillard, who was also the first woman to serve as Prime Minister of Australia, remained Prime Minister in a hung parliament following the election. Her government lasted until 2013, when Gillard lost a leadership spill, with Rudd becoming leader once again. Later that year the ALP lost the 2013 election. After this defeat, Bill Shorten became leader of the party. The party narrowly lost the 2016 election, yet gained 14 seats. It remained in opposition after the 2019 election, despite having been ahead in opinion polls for the preceding two years. The party lost in 2019 some of the seats which it had won back in 2016. After the 2019 defeat, Shorten resigned from the leadership, though he remained in parliament. Anthony Albanese was elected as leader unopposed and led the party to victory in the 2022 election. Between the 2007 federal election and the 2008 Western Australian state election, Labor was in government nationally and in all eight state and territory legislatures. This was the first time any