#include <bits/stdc++.h>
using namespace std;
const int mod = 1e9 + 7;
int maxSize, sSize, sValue, minValue, memo[2001][2001][2];
int solve(int n, int m, int pos) {
  if (m > 2000) return 0;
  if (n == 0) {
    if (m == 0 && pos == 1) return 1;
    if (m >= minValue && m + sValue == 0 && pos == 0) return 1;
    return 0;
  }
  if (memo[n][m][pos] != 0) return memo[n][m][pos] - 1;
  int val = solve(n - 1, m + 1, pos);
  val %= mod;
  if (m > 0) {
    val += solve(n - 1, m - 1, pos);
    val %= mod;
  }
  if (m >= minValue && pos == 0) {
    val += solve(n, m + sValue, 1);
    val %= mod;
  }
  memo[n][m][pos] = val + 1;
  return val;
}
int main() {
  cin.sync_with_stdio(0);
  cin.tie(0);
  cin >> maxSize >> sSize;
  string s;
  cin >> s;
  for (int i = 0; i < sSize; i++) {
    char c = s[i];
    if (c == '(')
      sValue++;
    else
      sValue--;
    minValue = min(minValue, sValue);
  }
  minValue *= -1;
  int ans = solve(maxSize - sSize, 0, 0);
  printf("%d\n", ans);
  return 0;
}
