* {
  box-sizing: border-box;
  margin:0;
  padding:0;
  -webkit-user-select: none; /* Safari */
  -ms-user-select: none; /* IE 10+ and Edge */
  user-select: none; /* Standard syntax */
}
    
#frame-page {
  height: calc(var(--vh, 1vh) * 100);
  border: white calc(var(--vh, 1vh) * 1) solid;
  background: white;
}

#container-game {
  background: silver;
  border: silver calc(var(--vh, 1vh) * 1) ridge;
  height: calc(var(--vh, 1vh) * 98);
  margin: 0 auto;
  padding: calc(var(--vh, 1vh) * 1); 
  width: calc(var(--vh, 1vh) * 130);
}

.card img {
  border-radius: 5%;
  height: 80%;
  left: 50%;
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  width: auto;
  z-index: 1;
}

#decks {
  float: left;
  height: 100%;
  position: relative;
  width: calc(var(--vh, 1vh) * 60);
}

#deck-t {
  background: red;
  height: 50%;
  position: relative;
  width: 100%;
}

#deck-t #evaluateButton, #deck-t button, #deck-t #buttonDeal, #deck-b button, #deck-b #howtoButton, #deck-b #buttonInstructions, #evaluateWarButton, #deck-b #newGame {
  background-color: #efefef;
  border-radius: 4px;
  cursor: pointer;
  font-size: 1vw;
  height: 10%;
  left: 50%;
  position: absolute;
  text-align: center;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 25%;
}

#deck-t #buttonDeal {
  color: red;
  font-size: calc(var(--vh, 1vh) * 6);
  font-weight: bold;
  height: 100%;
  left: 50%;
  top: 50%;
  transform: translate(-50%, 0);
  width: 50%;
  z-index: 1;
}

#deck-t #evaluateButton {
  box-shadow: 0 0 10px 10px gold;
  display: none;
  left: 50%;
  top: 100%;
  transform: translate(-50%, -50%);
  width: 20%;
  z-index: 1;
}

#deck-t #evaluateWarButton {
  box-shadow: 0 0 10px 10px red;
  display: none;
  left: 128.5%;
  top: 100%;
  width: 20%;
  z-index: 1;
}

#deck-b #howtoButton {
  left: 14.5%;
  top: 68%;
}

#deck-b #buttonInstructions {
  left: 14.5%;
  top: 80%;
}

#deck-b #newGame {
  left: 14.5%;
  top: 92%;
}

#deck-b {
  background: black;
  height: 50%;
  position: relative;
  width: 100%;
}

#deck, #deck2 {
  height: 100%;
  width: 100%;
}

#battleground {
  float: left;
  height: 100%;
  position: relative;
  width: calc(var(--vh, 1vh) * 34);
}

#battleground-t, #battleground-b {
  background: gold;
  float: left;
  height: 50%;
  position: relative;
  width: 100%;
}

#battleground-t .card, #battleground-b .card {
  left: 50%;
  top: 48%;
  height: 50%;
  position: absolute;
  transform: translate(-50%, 0%);
  width: auto;
}

#battleground-t {
  border-bottom: black calc(var(--vh, 1vh) * .25) solid;
}

#battleground-b {
  border-top: black calc(var(--vh, 1vh) * .25) solid;
}

#battleground-b .card {
  top: 2%;
}

#battleground-b .card:nth-child(2) {
  top: 10%;
}

#battleground-b .card:nth-child(3) {
  top: 18%;
}

#battleground-b .card:nth-child(4) {
  top: 26%;
}

#battleground-b .card:nth-child(5) {
  top: 34%;
}

#battleground-b .card:nth-child(6) {
  top: 42%;
}

#battleground-b .card:nth-child(7) {
  top: 50%;
}

#battleground-t .card:nth-child(2) {
  top: 40%;
}

#battleground-t .card:nth-child(3) {
  top: 32%;
}

#battleground-t .card:nth-child(4) {
  top: 24%;
}

#battleground-t .card:nth-child(5) {
  top: 16%;
}

#battleground-t .card:nth-child(6) {
  top: 8%;
}

#battleground-t .card:nth-child(7) {
  top: 0%;
}

#decks-discard {
  float: left;
  height: 100%;
  position: relative;
  width: calc(var(--vh, 1vh) * 32);
}

#deckDiscard {
  background: red;
  height: 50%;
  position: relative;
  width: 100%;
}

#deckDiscard2 {
  background: black;
  height: 50%;
  position: relative;
  width: 100%;
}

#deckDiscard .card, #deckDiscard2 .card {
  left: 50%;
  top: 50%;
  height: 80%;
  position: absolute;
  transform: translate(-50%, -50%);
  width: auto;
}

#deckDiscard .card:nth-last-child(2), #deckDiscard2 .card:nth-last-child(2) {
  left: 60%;
  top: 60%;
}

#redWinsBattle, #blackWinsBattle, #redWinsWar, #blackWinsWar, #war, #redWins, #blackWins {
  background: red;
  border: red calc(var(--vh, 1vh) * 10) ridge;
  display: none;
  height: auto;
  left: 50%;
  max-width: calc(var(--vh, 1vh) * 130);
  outline: white calc(var(--vh, 1vh) * 10) solid;
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  width: auto;
  z-index: 2;
}

#redWinsBattle img, #blackWinsBattle img, #redWinsWar img, #blackWinsWar img, #war img, #redWins img, #blackWins img {
  height: auto;
  position: relative;
  width: 100%;
}

#blackWinsBattle, #blackWinsWar, #war, #blackWins {
  background: black;
  border: black calc(var(--vh, 1vh) * 10) ridge;
}

#redWins, #blackWins {
  outline: gold calc(var(--vh, 1vh) * 20) ridge;
  z-index: 5;
}

#war {
  background: black;
  border-bottom: red calc(var(--vh, 1vh) * 10) ridge;
  border-left: red calc(var(--vh, 1vh) * 10) ridge;
  border-top: black calc(var(--vh, 1vh) * 10) ridge;
  border-right: black calc(var(--vh, 1vh) * 10) ridge;
}

#warningLandscape {
  background: lightgray;
  color: black;
  display: none;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 8vh;
  height: calc(var(--vh, 1vh) * 100);
  justify-content: center;
  position: absolute;
  text-align: center;
  width: 100%;
  z-index: 100;
}

#warningLandscape p {
  position: absolute;
  top: 50%;
  transform: translate(0%, -50%);
  width: 100%;
}

@media screen and (orientation:portrait) {
  #warningLandscape {
    display: block;
  }  
  html {
    background: lightgrey;
  }
  #frame-page {
    display: none;
  }
}