* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background: black;
  height: 100vh;
  overflow: hidden;
  font-family: Arial, sans-serif;
}

/* FUNDO ANIMADO */
.background {
  position: fixed;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.background span {
  position: absolute;
  width: 120px;
  height: 120px;
  border: 1px solid white;
  opacity: 0.1;
  animation: move 25s linear infinite;
}

.background span:nth-child(1) {
  top: 10%;
  left: 20%;
}

.background span:nth-child(2) {
  top: 60%;
  left: 10%;
  width: 80px;
  height: 80px;
  animation-duration: 18s;
}

.background span:nth-child(3) {
  top: 30%;
  left: 70%;
  border-radius: 50%;
  animation-duration: 30s;
}

.background span:nth-child(4) {
  top: 80%;
  left: 60%;
  width: 150px;
  height: 150px;
  animation-duration: 22s;
}

@keyframes move {
  from {
    transform: translateY(0) rotate(0deg);
  }
  to {
    transform: translateY(-120vh) rotate(360deg);
  }
}

/* CONTAINER */
.container {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
}

/* CALCULADORA */
.calculator {
  background: white;
  padding: 20px;
  border-radius: 12px;
  width: 260px;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.15);
}

#display {
  width: 100%;
  height: 50px;
  font-size: 24px;
  border: none;
  border-bottom: 2px solid black;
  margin-bottom: 15px;
  text-align: right;
  outline: none;
}

/* BOTÕES */
.buttons {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

button {
  height: 45px;
  background: black;
  color: white;
  border: none;
  font-size: 18px;
  cursor: pointer;
  transition: 0.3s;
}

button:hover {
  background: white;
  color: black;
  border: 1px solid black;
}

.equal {
  grid-row: span 1;
}

.zero {
  grid-column: span 2;
}
button {
  height: 45px;
  background: black;
  color: white;
  border: none;
  font-size: 18px;
  cursor: pointer;
  transition: 0.3s;
}

button:hover {
  background: white;
  color: black;
  border: 1px solid black;
}