*, *:before, *:after {
    box-sizing: border-box;
}

body {
  padding: 0.5rem;
}

.d-none {
  display: none !important;
}

.spinit-variant-field {
  display: grid;
  grid-template: 1fr / 1fr;
  margin: 0;
  width: 100%;
  height: 100%;
}

.spinit-variant {
  grid-area: 1 / 1 / 2 / 2;  
  height: 100%;
  width: 100%;
  background-color: white;
  transform: rotate(0deg);
  display: none;
}
.spinit-variant.active {
  display: block;
}


.spinit-playfield {
  display: grid;
  grid-template: 1fr / 1fr;
  margin: 0 auto;
  width: 80vw;
  height: 80vw;
  max-height: 20rem;
  max-width: 20rem;
}

.spinit-valid {
  grid-area: 1 / 1 / 2 / 2;
  height: 20rem;
  width: 20rem;
  background-color: rgba(255,255,255,0.8);
  padding: 4rem 2rem;
  font-size: 1.5rem;
  font-weight: bold;
  text-align: center;
  justify-content: center;
  align-items: center;
  display: none;
  transition: transform 1.5s ease-in-out;
}
.spinit-valid.active {
  transform: rotate(360deg);
  display: flex;
}

.spinit-grid {
  transition: transform 1.5s ease-in-out;
  grid-area: 1 / 1 / 2 / 2;
  background-color: white;
  display: grid;
  grid-template: repeat(5,1fr) / repeat(5,1fr);
  font-size: 2rem;
  line-height: 2rem;
  font-weight: bold;
  border-top: 10px solid #C44601;
  border-right: 10px solid #0073e6;
  border-bottom: 10px solid #f57600;
  border-left: 10px solid #89ce00;
  width: 100%;
  height: 100%;
}
.spinit-cell {
  display: flex;
  justify-content: center;
  align-items: center;
  border: 1px solid #aaa;
  width: 100%;
  height: 100%;
}

.fixed-highlight {
  border-color: yellow;
  border-width: 3px;
}


.pre span {
  opacity: 0.3;
}

.spinit-cell span {
    transition: transform 1.5s ease-in-out;
}

.spinit-grid.rotate1 {
  transform: rotate(90deg);
}
.spinit-grid.rotate1 .spinit-cell span{
  transform: rotate(-90deg)
}

.spinit-grid.rotate2 {
  transform: rotate(180deg);
}
.spinit-grid.rotate2 .spinit-cell span{
  transform: rotate(-180deg)
}

.spinit-grid.rotate3 {
  transform: rotate(270deg);
}
.spinit-grid.rotate3 .spinit-cell span{
  transform: rotate(-270deg)
}

.spinit-grid.rotate3b {
  transform: rotate(-90deg);
}
.spinit-grid.rotate3b .spinit-cell span{
  transform: rotate(90deg)
}



.spinit-grid.rotate4 {
  transform: rotate(360deg);
}
.spinit-grid.rotate4 .spinit-cell span {
  transform: rotate(-360deg)
}



.spinit-grid.no-transition {
  transition-property: none !important;
}
.spinit-grid.no-transition .spinit-cell span {
  transition-property: none !important;
}

.controls {
  display: block;  
  margin: 0.25rem 0;
  text-align: center;
}

.controls button {
  font-size: 1.5rem;
  display: inline-block;
  margin: 0.25rem
}


.w1.active {
  color: white;
  background-color: #C44601;
}

.w2.active {
  color: black;
  background-color: #89ce00;
}

.w3.active {
  color: black;
  background-color: #f57600;
}

.w4.active {
  color: white;
  background-color: #0073e6;
}

.w5.active {
  color: white;
  background-color: #999;
  }

.active.not-now {
  opacity: 0.3;
}
.w5.active.not-now {
  opacity: 1;
}

.solutions {
  text-align:center;
  font-size: 2rem;
  max-width: calc(100vw - 2rem);
  overflow: scroll;
}

.solution {
  padding: 0.25rem;
  height: 2.8125rem;
}

.player-word {
  vertical-align: top;
}

.in-dict {
  display: none;
  font-size: .75rem;
  background-color: white;
  color: black;
  border: 1px solid black;
  padding: 0.25rem 0.5rem;
  line-height: 1;
  margin: 0.425rem 0 0 1rem;
  vertical-align: top;
}
.in-dict.active {
  display: inline-block;
}

.today-words {
  font-size: 1.25rem;
  text-align: center;
  padding-bottom: 1rem;
}

.variant-switches {
  text-align: center;
}