A heart attack (心臓麻痺, shinzo-mahi, lit. "heart paralysis") is a term used when the heart rapidly loses the ability to pump properly. It is the default cause of death for a victim killed with a Death Note in the Death Note series.
The Japanese term used for heart attack is a causal term, not a medical one, and the medical specifics are not given in the Death Note series. The term is most closely associated with ventricular fibrillation, rather than with myocardial infarction which is usually what people mean when they say heart attack in English.
Ventricular fibrillation is when the heart quivers instead of pumping due to disorganized electrical activity in the ventricles. Since victims of the Death Note die almost immediately, it seems that the victim's heart suffers ventricular fibrillation, immediately resulting in cardiac arrest (blood stops flowing properly), leading to unconsciousness and death within minutes.
Sudden pain, especially chest pain, can be a side effect. This is exhibited very commonly in the Death Note series, as can be seen when individuals who are suffering heart attacks clutch at their chest or neck.
In English, a "heart attack" is generally in reference to a myocardial infarction, which is a blockage in one of the coronary arteries. A myocardial infarction can sometimes result in ventricular fibrillation and death. Risk of a myocardial infarction increases with stress. One such heart attack is exhibited in the series, suffered by Soichiro Yagami, who survives.
When a name is written in a Death Note but the cause of death is left unspecified, the default death is a heart attack. If the time is also unspecified, the heart attack occurs forty seconds after the name is written down.
When Light Yagami gains ownership of the Death Note, he writes in it the names of criminals. The causes of death are left unspecified, meaning that all the criminals die of heart attacks. This is intentional on Light's part, as he wants to show that there was some sort of higher power behind all of it, which will be obvious if only criminals are dying of only heart attacks. However, Light uses various other methods to kill people with the Death Note throughout the series, though this is generally in order to be discreet, as is the case with Naomi Misora and Kiichiro Osoreda. There are a few other exceptions, such as with Takuo Shibuimaru, who is a test subject of sorts, various criminals in order to test out the capabilities of the Death Note, and Wedy, for some unknown reason, who dies in a motor vehicle accident.
Light's plan of letting people know that there was a higher authority committing these murders ultimately succeeds, and heart attacks became known as the signature of Kira, a figure who punishes criminals with god-like powers.
Other Kira use only heart attacks as well, such as Kyosuke Higuchi, who presumably wants to be thought of as Kira despite his killings being targeted at competing business executives rather than criminals, and C-Kira, who also wants to be thought of as the original Kira. Kira who work with Light Yagami, such as Misa Amane, Teru Mikami, and Kiyomi Takada, also do this in order to make it look like Kira is only one being and so that the deaths of criminals will still be attributed to him.
Heart attacks as a default death are also used when the person writing the name has a limited amount of time to write the name. This is seen to be the case with the Shinigami Gelus, who had to act quickly, before Misa Amane's stalker killed her. Rem is another example, since the Japanese Task Force knew that she was up to something and was desperately searching for her before she could kill anyone else. Mafia member Jack Neylon also does this, presumably due to convenience and, later on, limited time when the mafia's base is being invaded.