* {
  margin: 0;
  padding: 0;
}

body {
  background-image: linear-gradient(rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.8)),
                    url("images/backgrounds/mountains.jpg");
  background-color: rgb(168, 184, 194);
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center;
  height: 207vh;
  position: relative;
}

@font-face {
  font-family: 'Vanilla Caramel';
  src: url("fonts/Vanilla\ Caramel.otf")
}

/* Button Styles */
.button {
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #10b439;
  color: rgb(255, 255, 255);
  height: 6vh;
  width: 20vh;

  border: none;
  border-radius: 4px;
  text-align: center;
  font-size: 2vh;

  cursor: pointer;
  transition-duration: 0.4s;
  touch-action: manipulation;
}

.button:hover {
  filter: brightness(85%);
}

.button-div {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1vh;
}

.box-buttons-div {
  display: flex;
  margin-top: 7vh;
  align-items: flex-end;
}

#submit-btn {
  margin-top: 2vh;
}

#one-counter-btn {
  display: none;
  margin-right: 10px;

  background-color: #443f3f;
  background-image: url("images/one_encounter.png");
  background-size: 6vh;
  background-repeat: no-repeat;
  background-position: center;
}

#five-counters-btn {
  display: none;
  color: black;
  margin-right: 10px;

  background-color: rgb(240, 248, 255);
  background-image: url("images/five_encounters.png");
  background-repeat: no-repeat;
  background-size: 18vh;
  background-position: center;
}

#remove-counter-btn {
  display: none;
  margin-right: 10px;

  background-color: #d42d2d;
  background-image: url("images/minus.png");
  background-repeat: no-repeat;
  background-size: 8vh;
  background-position: center;
}

#done-btn {
  display: none;
  margin-right: 10px;
  margin-top: 1vh;
  height: 8vh;
  width: 35vh;
}

#trash-btn {
  background-color: red;
  background-image: url("images/trashcan.png");
  background-size: 4vh;
  background-repeat: no-repeat;
  background-position: center;

  width: 8vh;
  margin-left: 6vw;
}

#change-box-btn {
  background-color: #00c3ff;

  margin-left: auto;
  margin-right: 6vw;
  width: 23vh;
}

.close-popup-btn {
  background-color: #d42d2d;
  background-image: url("images/minus.png");
  background-repeat: no-repeat;
  background-size: 8vh;
  background-position: center;

  position: absolute;
  right: 0;
  top: 0;
  height: 6vh;
  width: 6vh;
  max-height: 60px;
  max-width: 60px;

  border-radius: 10px;
}

.remove-grid-btn {
  background-color: #d42d2d;

  position: absolute;
  bottom: 0;
  margin-bottom: 8vh;
  left: 50%;
  transform: translateX(-50%);
  height: 6vh;
  width: 30vh;

  border-radius: 10px;
}

.continue-hunt-btn {
  background-color: #2dd45f;

  position: absolute;
  bottom: 0;
  margin-bottom: 8vh;
  left: 50%;
  transform: translateX(-50%);
  height: 6vh;
  width: 30vh;

  border-radius: 10px;
}

.yes-btn {
  position: absolute;
  bottom: 0;
  left: 0;
  margin-left: 2vw;
  margin-bottom: 8vh;
  width: 30vw;
  max-width: 250px;
}

.no-btn {
  background-color: orange;
  position: absolute;
  bottom: 0;
  right: 0;
  margin-right: 2vw;
  margin-bottom: 8vh;
  width: 30vw;
  max-width: 250px;
}

#change-wallpaper-btn {
  display: flex;
  margin-top: 2vh;
  width: 50vw;
  background-color: rgb(101, 149, 253);
}

#change-background-btn {
  display: flex;
  width: 50vw;
  margin-bottom: 5vh;
  background-color: rgb(122, 9, 150);
}

/* Pokemon Image */
#pokemon-image-div {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 5vh;
}

#pokemon-image {
  height: 35vh;
}

/* Counter */
#counter-div {
  display: flex;
  align-items: center;
  justify-content: center;
}

#counter {
  font-size: 16vh;
  font-family: 'Vanilla Caramel', Helvetica, sans-serif;
  font-weight: lighter;
  color: #ffffff;
}

/* Pokemon Name Input Field */
#name-input-div {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2vh;
}

#name-input {
  height: 5vh;
  width: 35vh;
  font-size: larger;
  text-align: center;
}

/* Pokemon Box */
#pokemon-box-div {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(22vh, 1fr));
  grid-template-rows: repeat(auto-fill, minmax(25vh, 1fr));
  grid-gap: 2vh;
  overflow: auto;

  height: 90vh;
  width: 90vw;
  margin: auto;

  background-size: cover;
  background-repeat: no-repeat;
  background-color: rgb(230, 227, 227);

  border-width: 1vh;
  border-style:groove;
  border-color: #7e89a1;

  cursor: url("images/pokeball_cursor.png"), auto;
  text-align: center;
}

.pokemon-box-image {
  height: 19vh;
  margin-left:2vh;
  margin-right:2vh;
  margin-top:2vh;
}

.pokemon-box-counter {
  font-family: 'Vanilla Caramel', Helvetica, sans-serif;
  font-size: 5vh;
  margin-left:2vh;
  margin-right:2vh;
  margin-bottom:2vh;
}

/* Popup and Overlay */
.popup {
  display: flex;
  flex-direction: column;
  background: url("images/background-popup1.png");
  background-size: cover;
  background-position: center;

  position: fixed;
  height: 80%; /* Adjusted for smaller screens */
  width: 80%; /* Adjusted for smaller screens */
  max-height: 400px;
  max-width: 600px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  padding: 20px;

  border-radius: 10px;
  box-shadow: 0px 0px 10px 0px rgba(0, 0, 0, 0.2);
}

/* Popup for completed hunt*/
.popup-complete {
  display: flex;
  flex-direction: column;
  background: url("images/background-popup1.png");
  background-size: cover;
  background-position: center;

  position: fixed;
  height: 60%;
  width: 60%;
  max-height: 400px;
  max-width: 600px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  padding: 20px;

  border-radius: 10px;
  box-shadow: 0px 0px 10px 0px rgba(0, 0, 0, 0.2);
}

/* Popup logic for phones*/
@media screen and (max-width: 600px) {
  .popup {
    height: 55%;
    width: 75%;
  }
  .popup-complete {
    height: 100%;
    width: 75%;
    max-height: 550px;
  }
}

.popup-content {
  font-family: 'Vanilla Caramel', Helvetica, sans-serif;
  text-align: center;
  font-size: 5vh;
  text-shadow: 
  -1px -1px 0 #000,  
   1px -1px 0 #000,
  -1px  1px 0 #000,
   1px  1px 0 #000;
  color: #ffffff;
  margin-top: 50px;
  margin-bottom: 50px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1;
  max-width: 120%;
  word-wrap: break-word;
}

.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.3);
}

/* Footer */
#footer-div {
  bottom: 0;
  display: flex;
  width: 100%;
  height: 4vh;
  position: absolute;
  align-items: center;
  justify-content: center;
  background-color: rgb(226, 226, 226);
  font-family:'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
}