#include <bits/stdc++.h>
using namespace std;
long long dp_cata[3021][5021];
int main() {
  dp_cata[0][0] = 1;
  for (long long j = 0; j <= 5001; j++)
    for (long long i = 0; i <= 3001; i++) {
      if (i == 0) {
        if (j != 0) dp_cata[i][j] = dp_cata[i + 1][j - 1];
      } else
        dp_cata[i][j] =
            (dp_cata[i + 1][j - 1] + dp_cata[i - 1][j - 1]) % 1000000007;
    }
  long long n, m;
  string s;
  cin >> n >> m >> s;
  if (n % 2 != 0) {
    cout << 0;
    exit(0);
  }
  long long x = 0, y = 0;
  long long lientiep = 0;
  for (long long i = 0; i < s.size(); i++) {
    if (s[i] == '(')
      x++;
    else
      y++;
    lientiep = max(lientiep, y - x);
  }
  if (x > n / 2 || y > n / 2) {
    cout << 0;
    exit(0);
  }
  long long X = n / 2 - x;
  long long Y = n / 2 - y;
  long long ans = 0;
  for (int i = 0; i <= n - m; i++) {
    for (int j = 0; j <= i; j++)
      if (j + x >= i - j + y && j - (i - j) >= lientiep) {
        if (j < i - j) continue;
        ans =
            (ans +
             dp_cata[j - (i - j)][i] *
                 dp_cata[2 * (n / 2 - (i - j + y)) - (n - m - i)][n - m - i]) %
            1000000007;
      }
  }
  cout << ans;
}
