:root {
  --line: #7e5730;
  --board: #d8b277;
  --bg: #f7f3eb;
  --text: #1f1f1f;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: grid;
  place-items: center;
}

.app {
  width: min(92vw, 760px);
  text-align: center;
}

h1 {
  margin: 0 0 6px;
}

.title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.title-icon {
  width: 42px;
  height: 42px;
  object-fit: contain;
}

.rules {
  margin: 0 0 18px;
  opacity: 0.8;
}

.panel {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}

#status {
  margin: 0;
  font-weight: 600;
}

#restartBtn {
  border: none;
  border-radius: 8px;
  background: #2e6fe8;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 8px 14px;
  cursor: pointer;
}

#restartBtn:hover {
  background: #205dca;
}

#bombBtn {
  border: none;
  border-radius: 8px;
  background: #e57d17;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 8px 14px;
  cursor: pointer;
}

#bombBtn:hover {
  background: #cb6707;
}

#bombBtn.armed {
  background: #b93f3f;
}

#bombBtn:disabled {
  background: #9b9b9b;
  cursor: not-allowed;
}

.board-wrap {
  overflow: auto;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
  background: #f4dfb5;
  padding: 10px;
}

.board {
  margin: 0 auto;
  background: var(--board);
  border: 2px solid var(--line);
  display: grid;
  grid-template-columns: repeat(15, 38px);
  grid-template-rows: repeat(15, 38px);
  width: fit-content;
  height: fit-content;
}

.cell {
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  cursor: pointer;
  user-select: none;
  background: transparent;
  padding: 0;
  appearance: none;
}

.cell:hover {
  background: rgba(255, 255, 255, 0.2);
}

.stone {
  width: 28px;
  height: 28px;
  border-radius: 50%;
}

.stone.black {
  background: #101010;
  box-shadow: inset -2px -2px 5px rgba(255, 255, 255, 0.15);
}

.stone.white {
  background: #f2f2f2;
  box-shadow: inset -2px -2px 4px rgba(0, 0, 0, 0.2);
}
