Invested (ing) as per Hanafi fiqh

Assalamualaikum warahmatullahi wabarakatuh

Thanks for reply to my previous queries.

Please address some of my further queries :-

A) What about the earning(profit) i made as i was just looking for the conditions mentioned in links below?

B) The conditions told by @Mufti_Faraz_Adam, which are below, are followed by all madhabs or not, as I didn’t see any Hanafi fiqh website mentioning those conditions, and i think based on this i can keep the profits as i didn’t knew of them and be considerate for future investments?

(1) Interest-based debt: The collective amount raised as a loan on interest, whether long-term or short-term debt does not exceed 30% of the market capitalization of the corporation.

(2) Interest-based deposit: The total amount of interest taking deposits, whether short, medium or long term, does not exceed 30% of the market capitalization of total equity.

(3) Earning from impermissible activities: The amount of income generated from prohibited component does not exceed 5% of the total income of the corporation, irrespective of the income being generated by undertaking a prohibited activity, by ownership of prohibited assets or in some other way.

C) What to do with profits earned on stocks which were not compliant and what current non-compliant stocks and their profits?

JazakAllahu Khayran