Hi and welcome
I am very sorry for your loss; it is always a most upsetting experience! I have lost three of my piggies to a heart attack/sudden acute heart failure, two of them at a very young age. When it happens, there is nothing you can do. One died on the examination table at the vets where she was seen straight away as soon as I noticed the first sign; several members have lost piggies on the way to the vet. The experience left me literally shaking like a leaf, so I feel for you!
Piggies like that live with a time bomb in their body that can go off at any time, usually without warning. This is more common in inbred or indiscriminately mass bred piggies; one of the young piggies I lost I know was from a background like that.
Seizures happen when the heart shuts down and the rest of the otherwise healthy body becomes deprived of oxygen while it itself is closing down. It can be very upsetting to watch; the only thing you can do if they are protracted is to see your closest vet as an emergency for pts. Thankfully, the piggy is by then mostly out of it. We call it "running to the Rainbow Bridge".
PS: If your boy has a companion, we have got tips on what you can best to do for a bereaved piggy in this thread here. You are welcome to post a tribute to the boy that has so sadly passed away in our Rainbow Bridge if and whenever it feels right for you.