The heroes destroyed the Noah spacecraft, but died in the process.

It's a Bolivian Army Ending, but we know that the Earthlings never did take over Mota and they didn't show up in Phantasy Star II. So my guess is that the seven heroes chose to destroy the spaceship rather than be overwhelmed by the Earthlings, possibly by Rolf using high levels of Megid (which is enough to take out an entire city, at least per PSIII).

Wren was originally built on the Noah Spacecraft by Dark Force, and Zelan and Kuran were built from the wreckage

Wren's age is 998, which means he was built two years after the destruction of Mother Brain.

We already know that the Mother Brain system is fully capable of building drones to protect itself, hence all the robotic monsters throughout the game; regardless of whether the Earthmen would have won, or whether Rolf and company would have, it didn't matter, because Noah's defense programs started up as soon as Mother Brain was destroyed. Lacking any immediate directives beyond removing the threat to the craft and without their highest AI, they went berserk and killed everyone, through sheer force of numbers.

Dark Force, having been recently defeated, used this opportunity to seize a second chance at controlling Noah, but it was extremely weak. It programmed Noah to produce a highly-advanced control android with top-priority command privileges and compatibility with the most powerful and destructive weapon types available for its weight class, with a supremely sophisticated artificial intelligence; Dark Force intended to use this android as a new body, or possibly a servant. However, the process of constructing the extremely powerful AI and modifying an existing android chassis to accommodate the increased firepower took longer than expected, and although the destruction of Parma meant that the seal was weakened enough that Dark Force could remain in Algo, it lost much of its power, and faded to dormancy within Noah while the android was still under construction.

When it was completed, the android, designated Wren, assumed control of the environmental control system as he was intended to do, and ordered that Noah be re-assigned to supporting the system in the absence of Mother Brain. Zelan was built from Noah's wreckage and was able to monitor the system from space, but required a slave machine to operate several secondary functions and properly relay commands when Zelan's orbit took it out of viable communication range. To correct this, Kuran was built from the remaining parts of Noah, including those that Dark Force had remained dormant in, and Dark Force was able to recuperate inside the new space station until the next weakening of the seal allowed him enough power to restore himself.

The Dark Force we see on Kuran is the same Dark Force from Phantasy Star II after the weakening of the seal has strengthened him; this is why he's attached directly to the hardware. His plan was to use Wren as a surrogate body and maintain control of the environment in Algo, but Wren's eventual development of self-awareness made him a poor choice, as without emotions or inherent evil he could not be easily manipulated, and being of the highest-order AI, could not be reprogrammed as needed. The other two Dark Forces we see in PSIV may actually be offshoots of this first one.

Wren built Demi as a companion for himself.

After some 600 years of observing the human condition, Wren developed emotions, and experienced loneliness. He built Demi himself, from scratch; this is why Demi is not similar to any other android type found in the games-- she's an original design. He also programmed her AI with the changes that his AI had gone through (ie, the anomalies caused by his developing emotions) with some alterations, so that she would have more sophisticated emotion and expression abilities. This is why she calls Wren "Master".

The effects of the Black Wave are a type of radiation poisoning

Why else would things living things die when exposed to it? The Psycho-Wand most likely created a field to negate it when the party fought Zio a second time and subsequently the Profound Darkness in the Edge.

Namine is responsible for no one recognizing the imported player character in Portable 2

Considering all the talk about heart at the end of Portable 1, it wouldn't be surprising if the universe temporarily became part of the Kingdom Hearts universe, just long enough for Namine to accidentally mess things up

Rolf had a brother or a sister, who is Chaz's ancestor

Rolf & Chaz look very similar, and even wear the same style of body armor as well as share a wardrobe. Maybe Rolf's brother/sister who resembled him were locked up for speaking out against Mother Brain, or he had long lost siblings. Or he had a son that he didn't know about.

Alis is descended from the Valkyria

Because Sega.