Hi,
A simple check for SKUAvailableItems of the parent product would indeed return 0 (aka not available) if the tracking and quantites are set for variants, even when there are some variants existing.
It works automatically only in the opposite direction, when you query the available items on the product variant and the tracking is set "By product".
Now, how to approach you aim - an inspiration can be found e.g. in the default control ShoppingCartItemSelector code - in
Kentico 12 it is \CMS\CMSModules\Ecommerce\Controls\ProductOptions\ShoppingCartItemSelector.ascx.cs,
method private void SetStockInformation().
Case branch for when the inventory type is TrackInventoryTypeEnum.ByVariants checks for any available items in all variants of the product:
Variants.Exists(variant => variant.Variant.SKUAvailableItems > 0)
This collection used in the control is not available in transformation directly, so it might be worth creating a custom function for this purpose, accepting the SKUInfo object, allowing easier control over the implementation.