EDIT: merged two answers here:
This formula will do what you are looking for, assuming you move everything one column to the right (adding an empty column in column A):
=SUM(IF(C2:AK2="Team1";IF(C3:AK3 < B3:AJ3;1;0)))
What this does is that it first looks if you have Team1 in the column. It then proceeds to check if the data below is less than the one preceding that. It is important you have the last if as A and the others as B because otherwise it will summarise the wrong data. (For team2 you will have to change the last B3:AJ3 to A3:AI3)
Also, use shift+enter when you enter this to make sure it becomes an array formula.
I would highly recommend you switch your columns and rows to a more standardised form first in order to have an easier workflow with your data. I mean something like this
I would then recommend you check out the answer for a similar question here. To summarise, you gather the data in one column and then use a
=SUM(IF(B:B < A:A;1;0))
assuming you have team1 in column B and general in column A.