ModuleTypeDetector
Infers ModuleType from the plugin class names applied to a Gradle subproject.
Pulled out of the task so detection logic can grow as the AGP/KGP ecosystem evolves without touching the task itself, and so it is unit-testable in isolation from Gradle.
Detection priority
Order matters. KMP must be checked before plain Android because a KMP module often also has the Android library plugin applied. The first match wins.
Adding new module types
When AGP or KGP introduces new plugin IDs, add them here. The ModuleType enum is the contract; this object is the detection implementation.