/*Declaration of the color variables*/
:root {
  --bg-color: #000;
  --orange-color: #ff9501;
  --grey-color-1: #a6a6a6;
  --grey-color-2: #4f4f4f;
  --grey-color-3: #333;
  --white-color: #fdfdfd;
}

.calc {
  margin: 50px auto;
  width: 300px;
  border-radius: 20px;
  background: var(--bg-color);
  color: var(--white-color);
  font-family: Arial, serif;
  padding: 18px;
  box-shadow: 4px 4px 4px var(--grey-color-2);
}

@media (max-width: 576px) {
  .calc {
    margin: 0 auto;
  }
}

.calc-screen {
  height: 80px;
  padding: 10px;
  display: grid;
  justify-items: end;
  align-items: end;
  margin-top: 25px;
}

.calc-screen p {
  max-height: 110px;
  width: 100%;
  font-size: 3rem;
  margin: 0;
  word-wrap: anywhere;
  overflow: auto;
}

.buttons {
  display: grid;
  grid-template-areas:
    "ac arrow-left percent division"
    "seven eigth nine multi"
    "four five six minus"
    "one two three plus"
    "zero zero dot equal";
  grid-gap: 7px;
  justify-items: center;
}

.btn {
  width: 60px;
  height: 60px;
  background: var(--grey-color-3);
  border-radius: 50%;
  text-align: center;
  line-height: 60px;
  font-size: 1.5rem;
  cursor: pointer;
  user-select: none;
  transition: filter 0.2s;
}

.btn.zero {
  grid-area: zero;
  width: 100%;
  border-radius: 34px;
}

.btn:hover {
  filter: brightness(120%);
}

.btn:active {
  filter: brightness(90%);
}

.btn.bg-grey {
  background: var(--grey-color-1);
}

.btn.bg-orange {
  background: var(--orange-color);
}

.errors {
  margin-top: 0;
  margin-bottom: 10px;
  margin-left: 15px;
  color: red;
  height: 20px;
}