 * {
  box-sizing: border-box;
  font-family: Inter, Segoe UI, Roboto, Arial, sans-serif;
}
:root {
  --bg: #f3f4f6;
  --card: #ffffff;
  --accent: #332c04;
  --muted: #6b7280;
}
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, #eef2f7, white);
  padding: 24px;
}
.page {
  width: 100%;
  max-width: 440px;
}
.calculator {
  background: var(--card);
  border-radius: 12px;
  box-shadow: 0 6px 18px rgba(16, 24, 40, 0.08);
  padding: 16px;
}
.display {
  background: #0b1220;
  color: #e6eef3;
  font-size: 2rem;
  padding: 16px;
  border-radius: 8px;
  text-align: right;
  overflow-x: auto;
  white-space: nowrap;
}
.keys {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-top: 12px;
}
.btn {
  padding: 14px 12px;
  border-radius: 8px;
  border: 0;
  background: #f3f4f6;
  font-size: 1.1rem;
  cursor: pointer;
  user-select: none;
}
.btn:active {
  transform: translateY(1px);
}
.operator {
  background: #0ea5a4;
  color: white;
}
.function {
  background: #ef4444;
  color: white;
}
.equals {
  background: #111827;
  color: white;
  grid-column: 3 / 4;
}
.note {
  color: var(--muted);
  font-size: 0.9rem;
  margin-top: 12px;
  text-align: center;
}
.visually-hidden {
  position: absolute !important;
  height: 1px;
  width: 1px;
  overflow: hidden;
  clip: rect(1px, 1px, 1px, 1px);
  white-space: nowrap;
}
@media (max-width: 420px) {
  .display {
    font-size: 1.5rem;
    padding: 12px;
  }
  .btn {
    padding: 12px 8px;
  }
}