p {
  margin: 0;
}

a {
  text-decoration: none;

}


body {
  background-color: #686b79;
  background-image: url(../contactWay/img/texture.png);
}

/* 标题 */
h1 {
  text-align: center;
  font-size: 60px;
  color: #c4d7d6;
}

/* 格式 */
.flex {
  display: flex;
}

.flex1 {
  flex: 1;
}

.column {
  flex-direction: column;
}

/* 游戏内容容器 */
.container {
  position: relative;
  /*   width: 471px;
  height: 471px; */
  margin: 0 auto;
}

/* 游戏获胜信息面板 */
.game-message {
  display: none;
  position: absolute;
  background-color: rgba(152, 192, 194, 0);
  /* text-align: center; */
}



/* winner 获胜者 */
.game-message p {
  margin: auto 0 auto 0;
  color: #4d5b99;
  font-size: 50px;

}

/* 重新开始游戏按钮 */
.game-message button {
  background-color: #beab3eaf;
  ;
  /* color: #517304;
  border-color: #517304;
  width: 110px;
  height: 40px; */
  font-size: 20px;
  cursor: pointer;
  text-align: center;
  align-items: center;
}

/* 游戏面板棋盘 */
.game-board {
  background-color: #beab3e;
  background-image: url(../contactWay/img/texture.png);
  /* background-image: url(../img/th.jpg); */
  background-size: cover;
  /*width: 471px;
  height: 471px; */
}

.game-board.x .cell:not(.x):not(.o):hover::before {
  content: 'X';
  color: lightgray;
}

.game-board.o .cell:not(.x):not(.o):hover::before {
  content: 'O';
  color: lightgray;
}

/* 棋盘 - 行 */
.row {
  display: flex;
}

.row:last-child .cell {
  border-bottom: 0;
}

/* 棋盘 - 单元格 */
.cell {
  box-sizing: border-box;
  width: 157px;
  height: 157px;
  line-height: 157px;
  border-right: 3px solid #363636;
  border-bottom: 3px solid #363636;
  text-align: center;
  cursor: pointer;
  font-size: 80px;
  font-family: 'Gill Sans', 'Gill Sans MT', Calibri, sans-serif;
}

.winMessage {
  width: 471px;
  height: 471px;
  line-height: 471px;
}

.cell:last-child {
  border-right: 0;
}

.cells3 {
  border-bottom: 0;
}

/* x 玩家 */
.cell.x::before {
  content: 'X';
  /*   background-image: url(../img/favicon.ico);
  background-size: cover; */
  color: #000000;
}

/* o 玩家 */
.cell.o::before {
  content: 'O';
  color: #ffffff;
}

/* 当屏幕小于500px时要改变的CSS */
@media (max-width:500px) {


  .cell {
    width: 120px;
    height: 120px;
    line-height: 120px;
    font-size: 50px;
  }

  .row {
    height: 120px;
    line-height: 120px;
  }

  .winMessage {
    width: 360px;
    height: 360px;
    line-height: 360px;
  }

  h1 {
    text-align: center;
    font-size: 40px;
    color: #477998;
  }
}

/* 当屏幕小于370px时要改变的CSS */
@media (max-width:370px) {

  /* 
  .game-board {
    width: 300px;
    height: 300px;
  }

  .container {
    width: 300px;
    height: 300px;
  }

 */
  .cell {
    width: 100px;
    height: 100px;
    line-height: 100px;
    font-size: 40px;
  }

  .row {
    height: 100px;
    line-height: 100px;
  }

  .winMessage {
    width: 300px;
    height: 300px;
    line-height: 300px;
  }

  h1 {
    text-align: center;
    font-size: 25px;
    color: #477998;
  }
}