#include <bits/stdc++.h>
using namespace std;
long long dp[2001][2001];
long long md = 1000000007;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  long long n, m;
  cin >> n >> m;
  string s;
  cin >> s;
  long long cnt = 0, mn = 0;
  for (int i = 0; i < m; i++) {
    if (s[i] == '(') {
      cnt++;
    } else {
      cnt--;
    }
    mn = min(mn, cnt);
  }
  dp[0][0] = 1;
  for (int i = 1; i <= n - m; i++) {
    for (int j = 0; j <= i; j++) {
      if (j > 0) dp[i][j] = ((dp[i][j] % md) + (dp[i - 1][j - 1] % md)) % md;
      dp[i][j] = ((dp[i][j] % md) + (dp[i - 1][j + 1] % md)) % md;
    }
  }
  long long ans = 0;
  for (int i = 0; i <= n - m; i++) {
    for (int j = 0; j <= i; j++) {
      if (j + mn >= 0 && j + cnt <= n - m - i) {
        if (j + mn >= 0)
          ans = (ans + 1ll * dp[i][j] * dp[n - m - i][j + cnt]) % md;
      }
    }
  }
  cout << ans << endl;
}
