#include <bits/stdc++.h>
using namespace std;
const long long mod = (1e9) + 7;
const long long INF = (1e5) + 10;
long long dp[2000 + 10][2000 + 10];
char str[100010];
int main() {
  int n, m;
  scanf("%d%d", &n, &m);
  scanf("%s", str + 1);
  int cnt = 0;
  int mint = INF;
  for (int i = 1; i <= m; i++) {
    cnt += (str[i] == '(' ? 1 : -1);
    mint = min(mint, cnt);
  }
  dp[0][0] = 1;
  for (int i = 1; i <= n - m; i++) {
    dp[i][0] = dp[i - 1][1];
    for (int j = 1; j <= i; j++) {
      dp[i][j] = (dp[i - 1][j - 1] + dp[i - 1][j + 1]) % mod;
    }
  }
  long long ans = 0;
  for (int i = 0; i <= n - m; i++) {
    for (int j = 0; j <= i; j++) {
      if (j + mint >= 0 && j + cnt <= n - m - i)
        ans += dp[i][j] * dp[n - m - i][cnt + j];
      ans %= mod;
    }
  }
  printf("%lld\n", ans);
  return 0;
}
