#include <bits/stdc++.h>
using namespace std;
int main() {
  int i, j;
  int n, count = 0;
  cin >> n;
  char a[n][n];
  for (i = 0; i < n; i++) {
    for (j = 0; j < n; j++) {
      cin >> a[i][j];
      if (a[i][j] == '.') {
        count++;
      }
    }
  }
  if (count % 5 != 0) {
    cout << "NO";
  } else {
    int tiles = 0;
    for (i = 1; i < n - 1; i++) {
      for (j = 1; j < n - 1; j++) {
        if ((a[i][j] == '.') && (a[i + 1][j] == '.') && (a[i - 1][j] == '.') &&
            (a[i][j + 1] == '.') && (a[i][j - 1] == '.')) {
          tiles++;
          a[i][j] = '#';
          a[i - 1][j] = '#';
          a[i + 1][j] = '#';
          a[i][j - 1] = '#';
          a[i][j + 1] = '#';
        }
      }
    }
    if (count == (tiles * 5))
      cout << "YES";
    else {
      cout << "NO";
    }
  }
  return 0;
}
