/* Reset & base */
* {
  box-sizing: border-box;
  font-family: "Segoe UI", Tahoma, sans-serif;
}

body {
  background: linear-gradient(135deg, #0d6efd, #6610f2);
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  margin: 0;
}

/* Calculator Card */
.calculator {
  width: 320px;
  padding: 15px;
  border-radius: 20px;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.25);
  background: #1e1e2f;
}

/* Screen */
.calculator-screen {
  width: 100%;
  height: 70px;
  border: none;
  border-radius: 12px;
  background: #000;
  color: #00ffcc;
  font-size: 2rem;
  text-align: right;
  padding: 10px 15px;
  margin-bottom: 15px;
  outline: none;
}

/* Buttons Grid */
.calculator-keys {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

/* Buttons Base */
.calculator-keys button {
  height: 55px;
  border-radius: 12px;
  font-size: 1.2rem;
  font-weight: bold;
  transition: 0.15s ease;
}

/* Hover + Click Effects */
.calculator-keys button:hover {
  transform: scale(1.04);
}

.calculator-keys button:active {
  transform: scale(0.96);
}

/* Operator Buttons */
.operator {
  background: #0dcaf0 !important;
  color: #000 !important;
}

/* Number Buttons */
.btn-light {
  background: #f8f9fa !important;
}

/* AC Button */
.all-clear {
  grid-column: span 2;
  background: red !important;
}

/* Equal Button */
.equal-sign {
  grid-column: span 2;
  background: #ffc107 !important;
  color: #000 !important;
  font-size: 1.4rem;
}

/* Responsive */
@media (max-width: 400px) {
  .calculator {
    width: 95%;
  }

  .calculator-screen {
    font-size: 1.6rem;
  }

  .calculator-keys button {
    height: 50px;
    font-size: 1rem;
  }
}
