Background: Juan Carlos was born to Infante Juan, Count of Barcelona and Princess Maria Mercedes of Bourbon-Two Sicilies in Rome, Italy, where his grandfather, King Alfonso XIII of Spain, and other members of the Spanish Royal Family lived in exile following the proclamation of the Second Spanish Republic in 1931. He was baptized as Juan Carlos Alfonso Victor Maria de Borbon y Borbon-Dos Sicilias. He was given the name Juan Carlos after his father and maternal grandfather, Prince Carlos of Bourbon-Two Sicilies. His early life was dictated largely by the political concerns of his father and General Franco.
Context: Juan Carlos's accession met with relatively little parliamentary opposition. Some members of the Movimiento Nacional voted against recognising him, and more against the 1976 Law for Political Reform. But even most Movimiento members supported both measures. Juan Carlos quickly instituted reforms, to the great displeasure of Falangist and conservative (monarchist) elements, especially in the military, who had expected him to maintain the authoritarian state. In July 1976, Juan Carlos dismissed prime minister Carlos Arias Navarro, who had been attempting to continue Francoist policies in the face of the king's attempts at democratisation. He instead appointed Adolfo Suarez, a former leader of the Movimiento Nacional, as prime minister, who would go on to win the following year's election and become the first democratically elected leader of the new regime. Further legitimacy was restored to Juan Carlos's position on 14 May 1977, when his father (whom many monarchists had recognized as the legitimate, exiled King of Spain during the Franco era) formally renounced his claim to the throne and recognized his son as the sole head of the Spanish Royal House, transferring to him the historical heritage of the Spanish monarchy, thus making Juan Carlos both de facto and de jure king in the eyes of the traditional monarchists. On 20 May 1977, the leader of the only recently legalized Spanish Socialist Workers' Party (PSOE), Felipe Gonzalez, accompanied by Javier Solana, visited Juan Carlos in the Zarzuela Palace. The event represented a key endorsement of the monarchy from Spain's political left, who had been historically republican. Left-wing support for the monarchy grew when the Communist Party of Spain was legalized shortly thereafter, a move Juan Carlos had pressed for, despite enormous right-wing military opposition at that time, during the Cold War. On 15 June 1977, Spain held its first post-Franco democratic elections. In 1978, the government promulgated a new constitution that acknowledged Juan Carlos as rightful heir of the Spanish dynasty and king; specifically, Title II, Section 57 asserted Juan Carlos's right to the throne of Spain by dynastic succession in the Bourbon tradition, as "the legitimate heir of the historic dynasty" rather than as the designated successor of Franco. The Constitution was passed by the democratically elected Constituent Cortes, ratified by the people in a referendum (6 December) and then signed into law by the King before a solemn meeting of the Cortes.
Question: How did Carlos help restore the monarchy?

Answer:
measures. Juan Carlos quickly instituted reforms, to the great displeasure of Falangist and conservative (monarchist) elements, especially in the military,