#include <bits/stdc++.h>
using namespace std;
const int MAXN = 5010;
const int mod = 1e9 + 7;
const int INF = 0x3f3f3f3f;
const double pi = acos(-1.0);
const double eps = 1e-4;
int n, m;
long long dp[2100][2100];
char s[200010];
void solve() {
  if (n & 1) {
    puts("0");
    return;
  }
  int cnt = 0, flag = 0;
  int tmp = 0;
  for (int i = 0; i < m; i++) {
    if (s[i] == '(')
      cnt++;
    else
      cnt--;
    tmp = max(tmp, -cnt);
    if (cnt < 0) flag = 1;
  }
  int mx = 0;
  int cnt1 = 0;
  for (int i = m - 1; i >= 0; i--) {
    if (s[i] == '(')
      cnt1++;
    else
      cnt1--;
    mx = max(mx, cnt1);
  }
  if (n == m && flag) {
    puts("0");
    return;
  }
  long long ans = 0;
  for (int i = tmp; i <= n - m; i++) {
    for (int j = tmp; j <= i; j++) {
      if (tmp + cnt < mx || tmp + cnt < 0 || tmp + cnt > 2000) continue;
      ans += (dp[i][j] * dp[n - m - i][tmp + cnt]) % mod;
      ans %= mod;
    }
  }
  cout << ans << endl;
}
int main() {
  memset(dp, 0, sizeof dp);
  dp[0][0] = 1;
  for (int i = 1; i <= 2000; i++) {
    for (int j = 0; j <= i; j++) {
      if (j > 0) dp[i][j] += dp[i - 1][j - 1];
      dp[i][j] %= mod;
      if (j != i) dp[i][j] += dp[i - 1][j + 1];
      dp[i][j] %= mod;
    }
  }
  cin >> n >> m;
  cin >> s;
  solve();
  return 0;
}
