*, *::before, *::after {
  box-sizing: border-box;
  font-family: Gotham Rounded, sans-serif;
  font-weight: normal;
}

body {
  padding: 0;
  margin: 0;
  background: linear-gradient(to right, #ffffff, #ff0000);
}

.calculator-grid {
  display: grid;
  justify-content: center;
  align-content: center;
  height: 70%;
  grid-template-columns: repeat(4, 100px);
  grid-template-rows: minmax(120px, auto) repeat(5, 100px);
}

.calculator-grid > button {
  cursor: pointer;
  font-size: 2rem;
  border: 1px solid rgb(255, 255, 255);
  outline: none;
  background-color: rgba(255, 255, 255, .75);
  box-shadow: 4px 4px 8px 0 rgba(0, 0, 0, 0.2);
  transition: background-color 0.3s, box-shadow 0.3s;
}

.calculator-grid > button:hover {
  background-color: rgba(255, 255, 255, .9);
}

.calculator-grid > button:focus {
  background-color: rgba(255, 255, 255, .9);
  box-shadow: 4px 4px 8px 0 rgba(0, 0, 0, 0.4);
  outline: none;
}

.span-two {
  grid-column: span 2;
}

.output {
  grid-column: 1 / -1;
  background-color: rgba(0, 0, 0, .75);
  display: flex;
  align-items: flex-end;
  justify-content: space-around;
  flex-direction: column;
  padding: 10px;
  word-wrap: break-word;
  word-break: break-all;
}

.output .previous-operand {
  color: rgba(255, 255, 255, .75);
  font-size: 1.5rem;
}

.output .current-operand {
  color: white;
  font-size: 2.5rem;
}

@media (max-width: 768px) {
  .calculator-grid {
    grid-template-columns: repeat(4, 80px);
    grid-template-rows: minmax(100px, auto) repeat(5, 80px);
  }
  
  .calculator-grid > button {
    font-size: 1.6rem;
  }
}