Legal - iCloud - Apple
VII. B "In addition, Apple may terminate your Account upon 30 days’ prior notice via email to the address associated with your Account if (a) your Account has been inactive for one (1) year; or (b) there is a general discontinuance of the Service or any part thereof."
From a post by Apple Community Specialist Brittany1416 in thread Inactive Apple ID - Apple Community :
"We'd like to get you some help with this issue. For this issue [an inactive Apple ID], please contact Apple Support for assistance. You may be able to reach Apple Support here: Contact - Official Apple Support "
Telephone numbers --> Contact Apple for support and service - Apple Support
Note that having an "inactive" account is not the same as having a disabled account. If your account is disabled, see this article --> If your Apple ID is locked or disabled - Apple Support