/* Wordsearch */
.ws-area {
  background: #fafafa;
  display: inline-block;
  /* padding: 20px; */
  -moz-user-select: -moz-none;
  -khtml-user-select: none;
  -webkit-user-select: none;
  -ms-user-select: none;
  padding: 0px;
  touch-action: none;
  position: relative;
  border-radius: 0px;
  border: 2px solid #dd4306; /* #dddddd; */ /* Voit muuttaa reunuksen paksuutta ja väriä tarpeidesi mukaan */
  margin: 4px;
}

.ws-selected {
  background: #aada007a;
}

.ws-game-over {
  display:table-cell;
  vertical-align:middle;
}

.ws-game-over h2 {
  color: #333; /* Tekstin väri */
  font-size: 24px;
  text-transform:uppercase;
  padding:0;
  margin:0 0 9px 0;
}

.ws-game-over p {
  color: #333; /* Tekstin väri */
  font-size: 18px;
  padding:0;
  margin:0;
  margin-bottom: 20px;
}

/* CSS-tyylit pelin lopetusilmoitukselle */
.ws-game-over-outer {
  background-color: rgba(255, 255, 255, 0.9); /* Valkea tausta läpinäkyvyydellä */
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.ws-game-over-inner {
  width:100%;
  height:100%;
  padding:0;
  margin:0;
  display:table;
  text-align: center;
}

.ws-game-over-box {
  background-color: white;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
}

.ws-game-over button {
  background-color: #4CAF50;
  color: white;
  padding: 10px 20px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.5s;
}

.ws-game-over button:hover {
  background-color: #45a049;
}

/* CSS reset */
body, h1 {
  margin: 0;
  padding: 0;
}

h1 {
  text-transform: uppercase;
}

h1.helper-header {
  text-transform: none;
}

body {
  color: #000000;
}

/* Common */
.fix {
  zoom: 1;
}

.fix:after {
  display: table;
  clear: both;
  content: '';
}

/* Home */
.wrap {
  width: 960px;
  margin: 0 auto;
  padding: 0px 0;
  text-align: center;
  position:relative;
  margin-top: 4vh;
}

.logo, #gameArea {
  margin-bottom: 0px;
}

.ws-area, .ws-words {
  display: inline-block;
  vertical-align: top;
}

.ws-words {
  margin-left: 20px;
  text-align: left;
  list-style: none;
  columns: 2;
  margin: 10px 0px 0px 0px;
} 

.ws-word {
  margin-bottom: 16px;
  border-radius: 16px;
}

.ws-words ::first-letter{
	text-transform : capitalize;
}

.ws-col {
  cursor: pointer;
  border-radius: 0px;
  width: 7.4vw;
  height: 7.4vw;
/*   width: 26px;
  height: 26px; */
  text-align: center;
  display: inline-block;
  line-height: 7.4vw;
  vertical-align: middle;
  border: 1px solid #dddddd;
}

.ws-row {
  line-height: normal;
}

.wrap {
  width: auto;  
}

.ws-word>del {
  border-radius: inherit;
  padding: 5px;
}

.selected {
  background-color: rgb(255, 0, 0);
}

#canvas-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 6;
}

#canvas-container-found {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 5;
}

.ws-area-wrapper {
  position: relative;
  display: inline-block;
  vertical-align: top;
  margin: auto;
  touch-action: none;
}

#ws-game-over-box {
  display: none;
  text-align: center;
  background-color: white;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
  width: 80%;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 8;
}

#game-mode-container {
  /* margin-bottom: 10px;  */
  text-align: center;
  margin-top: 24vh;
  display: flex;
  flex-direction: column;
  /* justify-content: center; */
  align-items: center;
  /* height: 55vh; */
}

#found-word {
  text-align: center;
}

#explanation-box {
  position: fixed;
  top: 30%;
/*   left: 50%;
  transform: translateX(-50%); */
  margin: 0px 8px;
  background-color: #ffffff;
  border: 3px solid #dd4306;
  border-radius: 40px;
  padding: 10px;
  max-width: 500px;
  text-align: left;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  z-index: 9999;
  font-size: 15px;
  cursor: default;
  display: none;
}

#explanation-box:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

#computer-icon {
  width: 48px;
  height: 48px;
  vertical-align: middle;
/*   padding-left: 12px;
  padding-bottom: 6px; */
  float: right;
  margin-right: 30px;
  margin-top: 3px;
}

#phone-icon {
  width: 46px;
  height: 46px;
  vertical-align: middle;
  /* padding-left: 12px; */
  float: right;
  margin-right: 30px;
  margin-top: 7px;
}

@media only screen and (min-width: 470px) {
  .ws-col {
    width: 30px;
    height: 30px;
    line-height: 30px;
  }

  .ws-words {
    columns: auto;
  }
}

@media only screen and (min-width: 520px) {
  #explanation-box {
    position: fixed;
    top: 30%;
    left: 50%;
    transform: translateX(-50%);
  }
}

@media only screen and (min-width: 900px) {
  .ws-col {
    width: 30px;
    height: 30px;
    line-height: 30px;
  }
}