#include <bits/stdc++.h>
using namespace std;
bool fill(string second[], int i, int j, int n) {
  if (j == 0 || j == n - 1 || i + 2 >= n) return 0;
  for (int k = 0; k < 3; k++) {
    if (second[i + k][j] != '.')
      return 0;
    else
      second[i + k][j] = '#';
  }
  i++;
  for (int k : {-1, 1}) {
    if (second[i][j + k] != '.')
      return 0;
    else
      second[i][j + k] = '#';
  }
  return 1;
}
int solve() {
  int n;
  cin >> n;
  string second[55];
  for (int i = 0; i < n; i++) cin >> second[i];
  int ok = 1;
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < n; j++) {
      if (second[i][j] == '.') ok &= fill(second, i, j, n);
      if (!ok) return 0;
    }
  }
  return ok;
}
int main() {
  if (solve())
    cout << "YES\n";
  else
    cout << "NO\n";
}
