* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #1a1a2e, #16213e);
  font-family: system-ui, -apple-system, sans-serif;
  padding: 1rem;
}

.calculator {
  background: #0f1729;
  border-radius: 24px;
  padding: 1.5rem;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  width: 100%;
  max-width: 360px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.display {
  background: #000;
  color: #fff;
  font-size: 2.5rem;
  font-weight: 300;
  text-align: right;
  padding: 1.5rem 1rem;
  border-radius: 16px;
  margin-bottom: 1rem;
  overflow-x: auto;
  white-space: nowrap;
  letter-spacing: 0.02em;
  min-height: 90px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.buttons {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
}

.btn {
  border: none;
  background: #1e293b;
  color: #fff;
  font-size: 1.4rem;
  font-weight: 500;
  padding: 1.25rem 0;
  border-radius: 12px;
  cursor: pointer;
  transition: transform 0.1s, background 0.15s;
  font-family: inherit;
}

.btn:hover {
  background: #273449;
}

.btn:active {
  transform: scale(0.96);
}

.btn.operator {
  background: #f59e0b;
  color: #0f1729;
  font-weight: 700;
}

.btn.operator:hover {
  background: #fbbf24;
}

.btn.equals {
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
  font-weight: 700;
  grid-column: span 2;
}

.btn.equals:hover {
  background: linear-gradient(135deg, #34d399, #10b981);
}

.btn.clear {
  background: #dc2626;
  color: white;
  font-weight: 700;
}

.btn.clear:hover {
  background: #ef4444;
}

.btn.zero {
  grid-column: span 2;
}
