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