#include <bits/stdc++.h>
using namespace std;
template <typename T>
inline void output(T a, int p) {
  if (p)
    cout << fixed << setprecision(p) << a << "\n";
  else
    cout << a << "\n";
}
int main() {
  cin.tie(0);
  ios::sync_with_stdio(0);
  int N, M;
  string S;
  cin >> N >> M >> S;
  int mn = 2e9 + 7, mx = -2e9 + 7, val = 0;
  for (int i = (int)(0); i < (int)(S.size()); i++) {
    if (S[i] == '(') {
      val++;
    } else {
      val--;
    }
    mn = min(mn, val), mx = max(mx, val);
  }
  vector<vector<long long>> C(2010, vector<long long>(2010));
  C[0][0] = 1;
  for (int i = (int)(0); i < (int)(2009); i++) {
    for (int j = (int)(0); j < (int)(2010); j++) {
      if (j) (C[i + 1][j - 1] += C[i][j]) %= 1000000007;
      if (j < 2009) (C[i + 1][j + 1] += C[i][j]) %= 1000000007;
    }
  }
  long long ret = 0;
  for (int i = (int)(0); i < (int)(N - S.size() + 1); i++) {
    int l = i, r = N - (int)S.size() - i;
    for (int j = (int)(0); j < (int)(i + 1); j++) {
      if (j + mn < 0 || j + mx > N / 2 || j + val < 0) continue;
      ret += C[l][j] * C[r][j + val];
      ret %= 1000000007;
    }
  }
  output(ret, 0);
  return 0;
}
