#include <bits/stdc++.h>
using namespace std;
const long long Mod = 1e9 + 7;
const int inf = 1 << 30;
string s;
long long dp[2005][4005];
long long DP[2005][4005];
int n, m, in, inB = inf;
long long mod(long long x) { return (x + Mod) % Mod; }
long long F(int pos, int tapawut) {
  if (tapawut > 0) return 0;
  if (pos > n) return (tapawut == 0);
  long long &res = DP[pos - m][-tapawut];
  if (~res) return res;
  res = 0;
  res = mod(res + F(pos + 1, tapawut + 1));
  res = mod(res + F(pos + 1, tapawut - 1));
  return res;
}
long long Solution(int pos, int tapawut) {
  if (pos > n - m + 1 || tapawut < 0) return 0;
  long long &res = dp[pos][tapawut];
  if (~res) return res;
  res = 0;
  if (tapawut + inB >= 0) res = mod(F(pos + m, -(tapawut + in)));
  res = mod(res + Solution(pos + 1, tapawut + 1));
  res = mod(res + Solution(pos + 1, tapawut - 1));
  return res;
}
int main() {
  scanf("%d%d", &n, &m);
  cin >> s;
  for (int i = 0; i < m; i++) {
    in += (s[i] == '(');
    in -= (s[i] == ')');
    inB = min(inB, in);
  }
  if (in > 2000 || in < -2000) {
    puts("0");
    exit(0);
  }
  memset(DP, -1, sizeof(DP));
  memset(dp, -1, sizeof(dp));
  long long ans = Solution(1, 0);
  printf("%lld", ans);
}
