body {
  background: #eee;
  margin: 0;
  height: auto;
  --maxHeight: 75vh;
}
input,
textarea,
button,
select,
a {
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}
h1 {
  margin-top: 1rem;
  font-size: 1.8rem;
  font-family: sans-serif;
}
.calcContainer {
  min-height: 75vh;
  display: flex;
  align-items: center;
  flex-direction: column;
  user-select: none;
}
.calculator {
  margin-top: 1.5rem;
  border-radius: 0.5rem;
  height: 86vh;
  width: calc(var(--maxHeight) * 0.75);
  background: #444;
  box-shadow: 0 10px 22px #0004, 0 8px 8px #0003;
}
.btnsContainer {
  margin: auto 1rem;
}
.btn {
  min-width: calc(var(--maxHeight) * 0.75 * 0.198);
  max-width: calc(var(--maxHeight) * 0.75 * 0.198);
  min-height: calc(var(--maxHeight) * 0.75 * 0.16);
  max-height: calc(var(--maxHeight) * 0.75 * 0.16);
  margin: calc(var(--maxHeight) * 0.75 * 0.009);
  border: none;
  outline: none;
  font-size: 1.5rem;
  background: #222;
  color: #999;
  cursor: pointer;
  border-radius: 0.5rem;
  box-shadow: 0 10px 22px #0004, 0 8px 8px #0003;
  transition: background 0.5s;
}
.btn:hover,
.btn:focus {
  box-shadow: 0 10px 22px #0004, 0 8px 8px #0003;
  color: #222;
  background: #aaa;
  transition: background 0.5s;
}
.Enter {
  margin: calc(var(--maxHeight) * 0.75 * 0.009) auto;
  min-width: calc(var(--maxHeight) * 0.77 * 0.85 / 2);
  max-width: calc(var(--maxHeight) * 0.77 * 0.85 / 2);
  background: lightseagreen;
  color: #111;
}
.num {
  background: #151515;
}
.clear {
  background: #ff3a3a;
  color: #111;
}
.btnHint {
  background: #52d681;
  color: #111;
}
.input {
  width: calc(var(--maxHeight) * 0.75 * 0.9);
  margin: calc(var(--maxHeight) * 0.75 * 0.05);
  margin-bottom: calc(var(--maxHeight) * 0.75 * 0.04);
  height: calc(var(--maxHeight) * 0.75 * 0.15);
  box-sizing: border-box;
  font-size: 1.5rem;
  padding: 1rem;
  border: none;
  outline: none;
  border-radius: 0.5rem;
  background: #999;
  box-shadow: 0 10px 22px rgb(0 0 0 / 25%), 0 8px 8px rgb(0 0 0 / 22%);
  user-select: text;
}
.res {
  text-align: center;
}
.result {
  margin-top: 0.5rem;
  font-family: sans-serif;
  text-align: center;
  font-size: 1.5rem;
  background: #aaa;
  padding: 2rem;
  margin-bottom: 1rem;
  box-shadow: 0 10px 22px #0004, 0 8px 8px #0003;
  overflow-x: hidden;
}
.steps {
  font-family: sans-serif;
  font-size: 1.5rem;
  background: #aaa;
  padding: 2rem;
  box-shadow: 0 10px 22px #0004, 0 8px 8px #0003;
  overflow-x: hidden;
}

.steps > ul > li {
  list-style-type: upper-roman;
}
.hint {
  text-align: center;
  font-family: sans-serif;
  position: fixed;
  height: 85vh;
  width: calc(80vh * 0.7);
  top: 5vh;
  left: calc((100vw - (80vh * 0.7)) / 2);
  padding: 1rem;
  background: #1115;
  color: #eeee;
  border-radius: 0.5rem;
  box-sizing: border-box;
  box-shadow: 0 10px 22px #0004, 0 8px 8px #0003;
  backdrop-filter: blur(10px);
}
.hide {
  display: none;
}
.close {
  position: absolute;
  top: 0.1rem;
  right: 1rem;
  font-size: 1.5rem;
  cursor: pointer;
  user-select: none;
}
@media screen and (min-width: 768px) {
  body {
    --maxHeight: 90vh;
  }
  h1 {
    margin-top: 1rem;
    font-size: 3rem;
  }
  .btnsContainer {
    margin: auto 2.8vh;
  }
  .calculator {
    height: 90vh;
    width: calc(var(--maxHeight) * 0.8);
  }
  .btn {
    min-width: calc(var(--maxHeight) * 0.8 * 0.205);
    max-width: calc(var(--maxHeight) * 0.8 * 0.205);
    font-size: 2rem;
    min-height: calc(var(--maxHeight) * 0.8 * 0.125);
    max-height: calc(var(--maxHeight) * 0.8 * 0.125);
  }
  .Enter {
    margin: calc(var(--maxHeight) * 0.8 * 0.009) auto;
    min-width: calc(var(--maxHeight) * 0.85 * 0.85 / 2);
    max-width: calc(var(--maxHeight) * 0.85 * 0.85 / 2);
  }
  .input {
    width: calc(var(--maxHeight) * 0.8 * 0.9);
    margin: calc(var(--maxHeight) * 0.8 * 0.05);
    margin-bottom: calc(var(--maxHeight) * 0.8 * 0.04);
    height: calc(var(--maxHeight) * 0.8 * 0.13);
  }

  .result {
    position: absolute;
    text-align: center;
    min-width: 20vw;
    top: 3rem;
    left: 0%;
    font-size: 2rem;
    min-width: calc(50vw - (80vh * 1.1) / 2);
    max-width: calc(50vw - (80vh * 1.1) / 2);
    overflow-x: auto;
    font-family: sans-serif;
    background: #aaa;
    font-weight: bold;
    padding: 1rem;
    border-radius: 0 0.5rem 0.5rem 0;
    box-shadow: 0 10px 22px #0004, 0 8px 8px #0003;
  }

  .steps {
    font-family: sans-serif;
    position: absolute;
    top: 3rem;
    min-width: calc(50vw - (80vh * 1.1) / 2);
    max-width: calc(50vw - (80vh * 1.1) / 2);
    overflow-x: auto;
    right: 0%;
    font-weight: bold;
    font-size: 2rem;
    background: #aaa;
    padding: 1rem;
    border-radius: 0.5rem 0 0 0.5rem;
    box-shadow: 0 10px 22px #0004, 0 8px 8px #0003;
    text-align: center;
  }
  .hint {
    text-align: center;
    font-family: sans-serif;
    position: fixed;
    height: 90vh;
    width: 80vw;
    top: 5vh;
    left: 10vw;
    padding: 1rem 5rem;
    font-size: 1.3rem;
    background: #000a;
  }

  .close {
    top: 0.7rem;
    right: 1.8rem;
    font-size: 2rem;
  }
  .close:hover {
    transform: scale(1.3);
    transition: transform 0.1s;
  }
  ::-webkit-scrollbar {
    width: 5px;
    height: 5px;
    cursor: auto;
  }

  ::-webkit-scrollbar-track {
    background-color: #aaa;
    -webkit-border-radius: 10px;
    border-radius: 10px;
  }

  ::-webkit-scrollbar-thumb {
    -webkit-border-radius: 10px;
    border-radius: 10px;
    background: #222;
  }
}
