As long as the Liberators are still in low numbers, you can still get around the liberation zones and pick them off.
The production rates are closer than you are making them out to be. Tempests and Liberators have the same build time, but Tempests are 5-supply units and reactored Starports are a bit more expensive than Stargates. It can be argued how much that extra expense makes up for the 5 vs 6 supply that both structures produce within the same time period (and assuming no chronoboosts from Protoss).
Liberators also require a Fusion Core and an upgrade to get their full range, so by the late-game Terran is putting down a similar investment to get the most out of their Liberators.
You clearly don’t understand your units correctly if you think that Tempests gain a bonus against Ultralisks or Thors. The anti-massive bonus is on the air attack. The ground attack has a bonus against buildings.
Either way, that anti-massive damage is not important for Liberators. The point of Tempests against Liberators is that a group of them can pick off Liberators from outside of their range in only a few volleys. Tempests give Protoss a way to pick off larger numbers of Liberators without entering their Liberation zones.
Tempests are not intended to be an answer to Vikings or Corruptors; rather, those units are both intended to counter Tempests.
Tempests do beat Liberators, and they are capable of picking off Liberators that are trying to set-up as your army maneuvers to avoid getting stuck in Liberation zones.
I’ve already gone over the fact that expensive, high supply units don’t work as counters to Battlecruisers. mainly because of Yamato Cannons. Any ideal counter to Battlecruisers should be 2 supply so that Yamato Cannons is less impactful. For whatever reason, Blizzard doesn’t give Protoss 2-supply air-to-air units, and air units may eventually hit a critical mass where ground-to-air units stop working.
Stalkers have worked well enough against Vikings in the past, but I will argue that Colossus were simply over-nerfed against non-light targets. For that reason, Colossus are not worth getting unless the opponent commits way too heavily to Marines.
First, it was a mistake to design Immortals as an a-move counter to Siege Tanks when most Protoss units already had mobility-boosting abilities (Blink, Charge, etc) to get around them. Protoss has always been the faction with the least trouble against Tanks as most of their basic units are tough and good at forcing friendly-fire, pouncing on unsieged tanks, bypassing Sieged Tanks to attack areas they are not, and exploiting other weaknesses.
Hardened Shields Immortals basically invalidated any unit that dealt more than 20 burst damage, and no ability with the potential for such absurd scaling should ever have been implemented. The bottom line is that Protoss never needed Immortals to deal with Tanks.
Even so, Immortals are still great at killing Tanks and Thors based on their high durability and anti-armor damage. You just need a means to close into range (flanks, drops, catching Tanks unsieged, whatever) without getting blocked by a line of Hellbats and picked off first.
Going back to the air attack issue. Immortals are extremely powerful in terms of shear stats (300-400 effective health, and very high anti-armor damage). Most units don’t get close to 100 effective health per supply, and most of the ones that do tend to have low DPS. If Immortals had an air attack with similar strength to their ground attack, mass Immortal compositions would be extremely powerful, and most factions wouldn’t be able to create armies that could compete against them.
Individual Vikings and Corruptors are cheaper than Immortals, but neither can compete with the Immortal’s combination of durability and damage. Two Vikings will cost more than an Immortal and cap out at lower overall health and usually lower overall DPS. Two Corruptors will match or exceed the durability of an Immortal, but their DPS will not even be close.
Immortals can be as durable as Thors, which cost more and take up 50% more supply. The damage on the two is similar while attacking armored units (while Thors also lose a lot of DPS as overkill against squishier targets), and the Thor’s air attack sacrifices damage for range, so it has substantially lower DPS than the ground attack. The Thor’s air attacks are effective mostly because Thors are such a durable unit where the range compensates for their slowness and their durability compensates for their low DPS.
Battlecruisers cost significantly more resources and supply than Immortals, so 1:1 comparisons are silly.
Brood Lords have never been as durable as Immortals, and their usefulness mostly relies on the fact that broodling walls prevent almost all ground units from engaging them–without Broodlings, Brood Lords would need much higher damage.
You seem to be looking at individual factors of units and wondering why Immortals cannot have all of them at once, and that is just not the way that game balance actually works.