#include <bits/stdc++.h>
using namespace std;
int D[4][2] = {{1, -1}, {1, 0}, {1, 1}, {2, 0}};
int main() {
  int n;
  cin >> n;
  vector<string> m(n);
  for (int i = 0; i < n; i++) cin >> m[i];
  for (int i = 0; i < n; i++)
    for (int j = 0; j < n; j++) {
      if (m[i][j] == '.') {
        m[i][j] = '#';
        for (auto x : D) {
          int ii = i + x[0];
          int jj = j + x[1];
          if (ii < 0 || ii >= n || jj < 0 || jj >= n || m[ii][jj] == '#') {
            cout << "NO\n";
            return 0;
          }
          m[ii][jj] = '#';
        }
      }
    }
  cout << "YES\n";
}
