* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: #f4f6fb;
  color: #1f2937;
}

.app {
  max-width: 540px;
  margin: 32px auto;
  padding: 20px;
}

h1 {
  margin: 0 0 16px;
  text-align: center;
}

.controls {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 12px;
}

button {
  border: none;
  border-radius: 8px;
  background: #2563eb;
  color: #fff;
  padding: 10px 14px;
  cursor: pointer;
  font-size: 14px;
}

button:hover {
  background: #1d4ed8;
}

.message {
  min-height: 22px;
  margin: 0 0 14px;
  text-align: center;
}

.timer {
  margin: 0 0 10px;
  text-align: center;
  font-weight: 700;
}

.board {
  display: grid;
  grid-template-columns: repeat(9, 1fr);
  border: 2px solid #111827;
  background: #111827;
}

.cell {
  width: 100%;
  aspect-ratio: 1 / 1;
  border: 1px solid #d1d5db;
  text-align: center;
  font-size: 1.2rem;
  outline: none;
}

.cell.notes {
  color: #2b68c9;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.cell.given {
  background: #e5e7eb;
  font-weight: 700;
}

.cell.duplicate {
  background: #fecaca;
  color: #dc2626;
}

.cell:nth-child(3n) {
  border-right: 2px solid #111827;
}

.cell:nth-child(9n) {
  border-right: 1px solid #d1d5db;
}

.cell:nth-child(n + 19):nth-child(-n + 27),
.cell:nth-child(n + 46):nth-child(-n + 54) {
  border-bottom: 2px solid #111827;
}
