Who will be Iran's next Supreme Leader?
The head of the Assembly of Experts, the body that elects the Supreme Leader of Iran, has died after almost five months in a coma.
Mohammad Reza Mahdavi Kani was considered to be a unifying figure in Iranian politics and his death opens up a period of uncertainty at a crucial time.
It comes just a month after the country's 75-year-old Supreme Leader Ayatollah Ali Khamenei had prostate surgery, with official photographs showing him pale and fragile in his hospital bed. The events raise the question of who will eventually take over as leader, and how that choice will be made.
How powerful is the Supreme Leader?
The Supreme Leader is by far the most powerful man in Iran.
He is commander-in-chief of the armed forces and appoints the heads of the judiciary and the state broadcaster, as well as half of the members of the Guardian Council - the powerful body which vets candidates for presidential and parliamentary elections.
In a few cases, the Supreme Leader has ordered parliament to stop passing legislation. He has also ordered the house arrest of dissidents and opposition leaders.
Key ministers are selected with the Supreme Leader's agreement and he has the ultimate say on Iran's foreign policy and nuclear programme.
No substantial political change can happen in Iran unless it gets a green light from the Supreme Leader.
This can create difficulty for whomever holds the elected role of president.
How will Ayatollah Khamenei's successor be chosen?
Iran's first Supreme Leader was Grand Ayatollah Ruhollah Khomeini. When he took power after the Islamic Revolution in 1979 he was already 77 years old, so the succession was always an important but unspoken question.
But a few years later, after Khomeini had suffered a series of strokes, a system was set up for choosing a new Supreme Leader.
The Assembly of Experts, a council of 82 elected clerics, was charged with electing, supervising and even disqualifying the Supreme Leader.
In 1989 when Khomeini died, the assembly selected Ayatollah Khamenei, who was then serving as president.
Although Khomeini had said that the Supreme Leader must be a Grand Ayatollah, this was not the case for the clerics' choice and the law had to be changed.
Another clause allowing people to choose the Supreme Leader directly was also removed from the constitution.
What this made clear was that although in theory the process of selecting a new leader is established by law, in practice powerful lobbies can interpret and change the law as they want.
Will the next Supreme Leader be as powerful?
Iran could have a very different future depending on which faction in the Assembly of Experts gains the upper hand in choosing the next leader.
There are two groups - conservatives and moderates.
The conservatives, who dominate the assembly, support Ayatollah Khamenei. They believe the leader of the Islamic regime is the representative of God on Earth and must be obeyed.
The moderates believe in the divine role of the Supreme Leader but hold that he takes his legitimacy from the people and should be responsible to them.
Some moderate members have called for changes to the current leadership model, suggesting the Ayatollah Khamenei's successor should serve for a fixed term rather than for life, and that a council of leaders should be set up to work with him.
But Ayatollah Khamenei has dismissed all talk of reform as long as he is Supreme Leader.
So, who are the possible contenders?
Fifteen members of the Assembly of Experts are charged with drawing up a list of potential candidates for the role of Supreme Leader. The list is not made public but is likely to contain a number of well-known names.
The first of these is former president Ali Akbar Hashemi Rafsanjani. A moderate who also used to head the Assembly of Experts, he and Ayatollah Khamenei were once close friends. Mr Rafsanjani played a significant role in helping him become Supreme Leader, but their friendship soured, especially after Mr Rafsanjani backed the mass opposition protests that erupted after the disputed presidential election in 2009.
The main candidates from the conservative faction are former heads of the judiciary, Grand Ayatollah Mahmoud Hashemi Shahroudi and Mohammad Yazdi, and current judiciary chief Sadeq Larijani. Judiciary heads are appointed by the Supreme Leader and thus are close allies.
Two hardline clerics, Mohammad Taqi Mesbah-Yazdi and Ayatollah Abbas Vaez Tabasi, are usually mentioned because of their religious authority. But their lack of experience in government is generally considered to rule them out as serious contenders.
There are two further names, both with family connections to the leadership.
Mojtaba Khamenei, the son of the current Supreme Leader, who is close to the conservatives, and Hassan Khomeini, a grandson of the former leader who supports the moderates.
Both are in their 40s and so considered quite young for such a senior position, but succession by blood is common in Shia Islam, and it is not impossible that either of them could succeed Ayatollah Khamenei.
Who has the upper hand - moderates or conservatives?
Over past decade conservatives have gained more seats in the Assembly of Experts because all candidates are vetted by the Guardian Council, whose most influential members are chosen directly and indirectly by the Supreme Leader.
The next election to the Assembly of Experts will be held in February 2016 and it is expected that members who supported the 2009 opposition protest will be disqualified from standing again.
The death of the Assembly head, Mohammad Reza Mahdavi Kani, is likely to change the current balance of power.
He was close to both conservative and moderate candidates, and a battle is now likely between the two camps for control of the Assembly.
Who else has a say?
Although the Assembly of Experts has the formal role of selecting the new leader, there will be intense behind the scenes lobbying to influence their decision.
Key players are likely to be the powerful Revolutionary Guards, and the office of the current Supreme Leader.
Another important group will be the supporters of whoever holds the presidency when a new leader is chosen.
The incumbent, President, Hassan Rouhani, is a moderate member of the Assembly of Experts, and this has for now helped to boost the position of the moderates.
Which leads to one more intriguing possibility. If President Rouhani can maintain good ties with Ayatollah Khamenei until the end of his term of office, then his name too could be added to the list of potential candidates to succeed him.