Alerts on Expression

Hello Grafana community !
I am a new user of Grafana. My question is about the alerts conditions.
I have two queries A and B.
A → Transmission Lost
B → Transmission Recovered.

I would like to raise an alert when the count of query B isn’t arriving in the 30seconds following the count of query A ?
If the event arriving in the 30s after a “Transmission Lost” is not a “Transmission Recovered” then raise an alarm.

I tried to do it on the Alerting condition, but maybe if we can use a Math expression between the two queries that recover the period of time between A and B then put an alert condition.

A and B are on the same Timestamp

Is it possible ?