#include <bits/stdc++.h>
using namespace std;
int dp[2010][2010][2];
const int MOD = 1000000007;
void ck(int &x, int y) {
  x += y;
  if (x >= MOD) {
    x -= MOD;
  }
}
char s[100010];
int main() {
  int n, m;
  scanf("%d%d", &n, &m);
  scanf("%s", s);
  int minn = 0, cur = 0;
  for (int i = 0; i < m; i++) {
    if (s[i] == '(') {
      cur++;
    } else {
      cur--;
    }
    minn = min(minn, cur);
  }
  dp[0][0][0] = 1;
  for (int i = 0; i <= n - m; i++) {
    for (int k = 0; k < 2; k++) {
      for (int j = 0; j <= 2000; j++) {
        if (dp[i][j][k] == 0) {
          continue;
        }
        if (k == 0 && j + minn >= 0 && j + cur <= 2000) {
          ck(dp[i][j + cur][k + 1], dp[i][j][k]);
        }
        if (i < n - m) {
          if (j + 1 <= 2000) {
            ck(dp[i + 1][j + 1][k], dp[i][j][k]);
          }
          if (j - 1 >= 0) {
            ck(dp[i + 1][j - 1][k], dp[i][j][k]);
          }
        }
      }
    }
  }
  printf("%d\n", dp[n - m][0][1]);
  return 0;
}
