* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: #808080;
  font-family: Arial, sans-serif;
}

.bg {
  background-image: url(./bg/mondstadt.jpg);
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  background-position: center;
  background-size: cover;
  transform-origin: center;
}

.container {
  text-align: center;
  z-index: 9;
}

.control {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2em;
}
.result {
  display: flex;
  margin: 20px;
}
#mcName {
  padding: 5px;
  font-size: 2em;
  min-width: 100px;
  display: flex;
  align-items: center;
  background-color: #f0f0f0;
}
.result-container {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  min-height: 95px;
  margin-left: 20px;
  min-width: 160px;
  background-color: #aaaaaa;
}
.result-char {
  text-align: left;
  background-color: #f0f0f0;
  font-size: 0.8em;
  width: 80px;
  height: calc(80px + 1.2em);
  transition: transform 0.3s ease;
  background-size: contain;
  background-repeat: no-repeat;
  background-origin: content-box;
  background-position: bottom;
  margin: 5px;
  padding: 5px;
  border: 3px solid #c4c4c4;
  border-radius: 4px;
}
.name-center {
  text-align: center;
}
.close-btn {
  border: none;
  width: 20px;
  height: 20px;
  padding: 0;
  background-color: #910000;
  color: white;
  cursor: pointer;
  border-radius: 5px;
  position: absolute;
  margin-left: 60px;
  margin-top: -15px;
}
.character-container {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  min-width: 645px;
  max-width: 1125px;
  overflow: hidden;
  position: relative;
  padding: 30px 25px;
}

.character {
  background-color: #f0f0f0;
  font-size: 0.6em;
  width: 53px;
  height: calc(53px + 1.2em);
  transition: transform 0.3s ease;
  background-size: contain;
  background-repeat: no-repeat;
  background-origin: content-box;
  background-position: bottom;
  margin: 3px;
  padding: 3px;
  border: 3px solid #c4c4c4;
  border-radius: 4px;
  cursor: grab;
}
.Anemo { border-color: #33ccb3; }
.Pyro { border-color: #e2311d; }
.Electro { border-color: #d376f0; }
.Cryo { border-color: #98c8e8; }
.Hydro { border-color: #1c72fd; }
.Geo { border-color: #cfa726; }
.Dendro { border-color: #7bb42d; }
.character.selected {
  transform: scale(2);
  z-index: 1000;
}
.character.discarded:not(.selected) {
  filter: grayscale(100%) opacity(0.3);
}
.btn {
  padding: 10px 20px;
  color: white;
  border: none;
  cursor: pointer;
  font-size: 16px;
  border-radius: 5px;
}
.btn.start {background-color: #4CAF50;}
.btn.start:hover {background-color: #45a049;}
.btn.clear {background-color: #5d5d5d;}
.btn.clear:hover {background-color: #5d5d5d;}
