Since we use `matchesRatio && isLarger` as condition below, comparing overall areas should work since we also limited the aspect ratio. Let me change it.