#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  bool a[n][n];
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < n; j++) {
      char ch;
      cin >> ch;
      a[i][j] = ch == '.';
    }
  }
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < n; j++) {
      if (i > 0 && j > 0 && i < n - 1 && j < n - 1) {
        if (a[i][j] && a[i - 1][j] && a[i + 1][j] && a[i][j - 1] &&
            a[i][j + 1]) {
          a[i][j] = false;
          a[i - 1][j] = false;
          a[i + 1][j] = false;
          a[i][j - 1] = false;
          a[i][j + 1] = false;
        }
      }
    }
  }
  bool ist = true;
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < n; j++) {
      ist = !a[i][j];
      if (!ist) {
        break;
      }
    }
    if (!ist) {
      break;
    }
  }
  if (ist)
    cout << "YES";
  else
    cout << "NO";
  return 0;
}
