
body {
  width: 830px;
  margin: auto;
  background-color: black;
}

/*** HEADER ***/

.header {
  width: 830px;
  margin: auto;
  height: 60px;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
}
.header > p {
  padding: 5px 0 0 25px;
  margin: 0;
  font-size: 40px;
  font-family: 'Trebuchet MS', 'Lucida Sans Unicode', 'Lucida Grande', 'Lucida Sans', Arial, sans-serif;
}
.score-container {
  display: flex;
  flex-direction: row;
}
.header-container {
  display: flex;
  flex-direction: row;
  padding-right: 40px;
  font-family: 'Lucida Sans', 'Lucida Sans Regular', 'Lucida Grande', 'Lucida Sans Unicode', Geneva, Verdana, sans-serif;
  font-size: 15pxx;
}
#moves, #score {
  padding-left: 5px;
}
.container {
  display: grid;
  grid-template-columns: repeat(9, auto);
  width: min-content;
  margin: 0 auto 0 auto;
  border-radius: 0 0 30px 30px;
}

/*** STOCK ***/

.reset {
  position: absolute;
  height: 120px;
  width: 80px;
  left: 28px;
  top: 10px;
  font-size: 102px;
  text-align: center;
  user-select: none;
}
.reset:hover {
  cursor: pointer;
}

.stockrow {
  position: relative;
  width: 830px;
  margin: auto;
}
#stockdown{
  position: absolute;
  left: 30px;
  top: 10px;
}
#stockdown:hover {
  cursor: pointer;
}
#stockdown2{
  position: absolute;
  left: 40px;
  top: 10px;
}
#stockdown3{
  position: absolute;
  left: 50px;
  top: 10px;
}
#stockup {
  position: absolute;
  left: 170px;
  top: 10px;
}

#stockup div.card:nth-child(1) {
  z-index: 800;
}
#stockup div.card:nth-child(2) {
  z-index: 700;
}
#stockup div.card:nth-child(3) {
  z-index: 600;
}

#stockup div.card:nth-child(2):hover,
#stockup div.card:nth-child(3):hover {
  outline: none;
}

/*** FOUNDATIONS ***/

.foundation-container {
  display: flex;
  justify-content: flex-end;
  background-size: 20px 20px;
  padding: 10px;
}

.foundation {
  height: 120px;
  width: 80px;
  font-size: 100px;
  text-align: center;
  margin: 0 0 0 5px;
}
.foundation > .card {
  box-shadow: none;
  top: 13px;
}

/*** CARDS ***/

.card {
  position: absolute;
  height: 120px;
  width: 80px;
  background-color: #ffffff;
  background-size: 10px 10px;
  background-image: repeating-linear-gradient(45deg, #00000010 0, #00000010 1px, #ffffff 0, #ffffff 50%);
  border: 1px solid #333;
  border-radius: .5rem;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 60px;
  box-shadow: 0 5px 10px #111;
  user-select: none;
}
.card:hover {
  cursor: pointer;
  outline: 1px solid white;
}

.cardback {
  position: absolute;
  height: 120px;
  width: 80px;
  border-radius: .5rem;
  box-shadow: 0 5px 10px #111;
}

.card::before,
.card::after {
  position: absolute;
  content: attr(id);
  font-size: 1.5rem;
}
.card::before {
  top: 2px;
  left: 6px;
}
.card::after {
  bottom: 2px;
  right: 6px;
  transform: rotate(180deg);
}

/*** MODAL ***/

.modal {
  display: none;
  position: fixed;
  z-index: 1;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgb(0,0,0);
  background-color: rgba(0,0,0,0.5);
}
.modal-content {
  position: relative;
  background-color: rgba(247, 247, 247, 0.9);
  margin: 230px auto; 
  padding: 20px 20px 15px 20px;
  border: 1px solid black;
  width: 350px;
  border-radius: 10px;
  box-shadow: 2px 2px 5px black;
}
.modal-content > p {
  text-align: center;
  padding-left: 15px;
  font-size: 24px;
  font-family: 'Trebuchet MS', 'Lucida Sans Unicode', 'Lucida Grande', 'Lucida Sans', Arial, sans-serif;
}

.start-container {
  position: relative;
  padding-top: 40px;
}

.start-background {
  display: flex;
  justify-content: flex-end;
  width: 100%;
  height: 130px;
  border-radius: 10px 10px 10px 0px;
}
.start-background2 {
  width: 87%;
  height: 65%;
  align-self: flex-end;
  border-radius: 10px 10px 10px 0;
}

#easy-game, #hard-game {
  border-radius: 10px;
  font-size: 48px;
  height: 150px;
  width: 95px;
  top: 0;
}

#easy-game {
  position: absolute;
  left: 70px;
}
#hard-game {
  position: absolute;
  right: 70px;
}

#hard-game:hover, #easy-game:hover {
  cursor: pointer;
}

#easy-game:hover ~ #easy3 > p,
#easy-game:hover ~ #easy4 > p {
  visibility: visible;
}

#hard-game:hover ~ #hard3 > p,
#hard-game:hover ~ #hard4 > p {
  visibility: visible;
}

#easy-game:hover ~ #easy3,
#easy-game:hover ~ #easy4 {
  transform: rotate(0deg);
  background-color: #ffffff;
  background-size: 5px 5px;
  background-image: repeating-linear-gradient(45deg, #00000010 0, #00000010 1px, #ffffff 0, #ffffff 50%);
  border: 1px solid black;
}
#hard-game:hover ~ #hard3,
#hard-game:hover ~ #hard4 {
  transform: rotate(0deg);
  background-color: #ffffff;
  background-size: 5px 5px;
  background-image: repeating-linear-gradient(45deg, #00000010 0, #00000010 1px, #ffffff 0, #ffffff 50%);
  border: 1px solid black;
}

#easy-game:hover ~ #easy3::after,
#easy-game:hover ~ #easy3::before,
#easy-game:hover ~ #easy4::after,
#easy-game:hover ~ #easy4::before {
  position: absolute;
  font-size: 12px;
  color: inherit;
}
#easy-game:hover ~ #easy3::after,
#easy-game:hover ~ #easy3::before {
  content: "A♥";
}
#easy-game:hover ~ #easy3::after {
  bottom: 1px;
  right: 1px;
  transform: rotate(180deg);
}
#easy-game:hover ~ #easy3::before {
  top: 1px;
  left: 1px;
}
#easy-game:hover ~ #easy4::after,
#easy-game:hover ~ #easy4::before {
  content: "J♣";
}
#easy-game:hover ~ #easy4::after {
  bottom: 1px;
  right: 1px;
  transform: rotate(180deg);
}
#easy-game:hover ~ #easy4::before {
  top: 1px;
  left: 1px;
}
#hard-game:hover ~ #hard3::after,
#hard-game:hover ~ #hard3::before,
#hard-game:hover ~ #hard4::after,
#hard-game:hover ~ #hard4::before {
  position: absolute;
  font-size: 12px;
  color: inherit;
}
#hard-game:hover ~ #hard3::after,
#hard-game:hover ~ #hard3::before {
  content: "K♠";
}
#hard-game:hover ~ #hard3::after {
  bottom: 1px;
  right: 1px;
  transform: rotate(180deg);
}
#hard-game:hover ~ #hard3::before {
  top: 1px;
  left: 1px;
}
#hard-game:hover ~ #hard4::after,
#hard-game:hover ~ #hard4::before {
  content: "Q♦";
}
#hard-game:hover ~ #hard4::after {
  bottom: 1px;
  right: 1px;
  transform: rotate(180deg);
}
#hard-game:hover ~ #hard4::before {
  top: 1px;
  left: 1px;
}

#easy-game:hover ~ #easy3 {
  left: 23px;
  bottom: 30px;
}
#easy-game:hover ~ #easy4 {
  left: -5px;
  bottom: 40px;
  transform: rotate(-35deg);
}
#hard-game:hover ~ #hard3 {
  right: 30px;
  bottom: 20px;
  transform: rotate(-5deg);
}
#hard-game:hover ~ #hard4 {
  right: 0px;
  bottom: 20px;
  transform: rotate(25deg);
}

#easy-game > p, #hard-game > p {
  font-family: Verdana, Geneva, Tahoma, sans-serif;
  font-size: 16px;
  font-weight: 900;
}

.small-card.start:hover {
  cursor: default;
}
.small-card.start > p {
  visibility: hidden;
  font-size: 28px;
  color: inherit;
}

#easy1 {
  left: -5px;
  bottom: 15px;
  transform: rotate(-30deg);
}
#easy2 {
  left: 37px;
  bottom: 42px;
  transform: rotate(5deg);
}
#easy3 {
  left: 20px;
  bottom: 37px;
  transform: rotate(-15deg);
}
#easy4 {
  left: 0px;
  bottom: 30px;
  transform: rotate(-25deg);
}
#hard1 {
  right: 40px;
  bottom: 40px;
  transform: rotate(-5deg);
}
#hard2 {
  right: 20px;
  bottom: 37px;
  transform: rotate(20deg);
}
#hard3 {
  right: 5px;
  bottom: 30px;  
  transform: rotate(5deg);
}
#hard4 {
  right: 0px;
  bottom: 15px;
  transform: rotate(35deg);
}

.close-new,
.close-theme {
  color: #aaa;
  float: right;
  font-size: 28px;
  font-weight: bold;
}
.close-new:hover,
.close-new:focus,
.close-theme:hover,
.close-theme:focus {
  color: black;
  text-decoration: none;
  cursor: pointer;
}

/*** SIDEBAR ***/

.sidebar {
  position: relative;
  width: 124px;
  border-radius: 0px 0px 0px 30px;
}

.theme-btn {
  width: 100px;
  height: 50px;
  margin-top: 20px;
  font-family: 'Lucida Sans', 'Lucida Sans Regular', 'Lucida Grande', 'Lucida Sans Unicode', Geneva, Verdana, sans-serif;
  font-size: 20px;
  color: white;
  border-radius: 0 20px 20px 0;
  transition: border-radius 0.3s ease-in-out, transform 0.3s ease-in-out;
}
.theme-btn:hover {
  cursor: pointer;
  border-radius: 20px 20px 20px 20px;
  transform: scaleX(1.15) scaleY(1.15);
}

#newgame {
  position: absolute;
  display: flex;
  bottom: 0px;
  left: 30px;
  padding: 10px;
  font-size: 56px;
  bottom: 30px;
  width: 140px;
  padding: 0px;
  margin: 0px;
  z-index: 999;
  align-items: center;
  color: white;
  border-bottom: 1px solid white;
  transition: 0.3s ease-in-out;
}
#newgame:hover {
  cursor: pointer;
  animation-name: blink;
  animation-duration: 1.2s;
  animation-iteration-count: infinite;
}

@keyframes blink {
    0% {
        opacity: 1;
    }
    25% {
        opacity: 0.7;
    }
    50% {
        opacity: 1;
    }
    75% {
        opacity: 0.7;
    }
    100% {
        opacity: 1;
    }
}

#exclamation {
  opacity: 0;
  transition: 0.3s ease-in-out;
}

#newgame:hover #exclamation {
  opacity: 1;
}

#star {
  color: white;
}

#newgame:hover #star {
    animation-name: spin;
    animation-duration: 2s;
    animation-iteration-count: infinite;
}

@keyframes spin {
  to {
      transform: rotateY(0deg);
  }
  from {
      transform: rotateY(360deg);
  }
}

#star-1 {
  bottom: 38px;
  left: 34px;
  transform: rotate(40deg);
}

#star-2 {
  bottom: 38px;
  left: 11px;
  transform: rotate(-40deg);
}

#star-3 {
  bottom: 18px;
  left: 39px;
  transform: rotate(120deg);
}

#star-4 {
  bottom: 18px;
  left: 7px;
  transform: rotate(-120deg);
}

#newgame > span {
  position: absolute;
  font-family: 'Trebuchet MS', 'Lucida Sans Unicode', 'Lucida Grande', 'Lucida Sans', Arial, sans-serif;
  font-size: 36px;
  left: 50px;
  bottom: 10px;
}

/*** COLUMNS ***/

.column {
  display: flex;
  position: relative;
  justify-content: center;
  width: 98px;
  height: 600px;
  background-color: none;
}
#column0 {
  padding-left: 10px;
  border-radius: 30px 0px 0px 0px;
}
#column6 {
  padding-right: 10px;
  border-radius: 0 30px 30px 0;
}

.row0 {
  top: 10px;
}
.row1 {
  top: 37px;
}
.row2 {
  top: 64px;
}
.row3 {
  top: 91px;
}
.row4 {
  top: 118px;
}
.row5 {
  top: 145px;
}
.row6 {
  top: 172px;
}
.row7 {
  top: 199px;
}
.row8 {
  top: 226px;
}
.row9 {
  top: 253px;
}
.row10 {
  top: 280px;
}
.row11 {
  top: 307px;
}
.row12 {
  top: 334px;
}
.row13 {
  top: 361px;
}
.row14 {
  top: 388px;
}
.row15 {
  top: 415px;
}
.col0 {
  left: 50px;
}
.col1 {
  left: 15px;
}
.col2 {
  left: -20px;
}
