* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  margin: 0;
  height: 100%;
  overflow: hidden;
  overscroll-behavior: none;
  background: #b9cfdb;
  font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Noto Sans JP", sans-serif;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
}

canvas {
  display: block;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  touch-action: none;
}

.menu {
  position: fixed;
  left: 50%;
  top: 64%;
  transform: translate(-50%, -50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  width: min(86vw, 340px);
  transition: opacity .25s;
}
.menu.hidden { opacity: 0; pointer-events: none; }
/* ラウンドの合間は結果だけ表示する */
.menu.result-only { pointer-events: none; }
.menu.result-only .row,
.menu.result-only .start { display: none; }

.row { display: flex; gap: 8px; width: 100%; }
.row button { flex: 1; }

button {
  font: inherit;
  font-size: 17px;
  font-weight: 700;
  padding: 13px 0;
  border: 2px solid #2b4a5e;
  border-radius: 12px;
  background: rgba(255, 255, 255, .88);
  color: #2b4a5e;
  cursor: pointer;
}
button.selected { background: #2b4a5e; color: #fff; }
button:active { transform: scale(.97); }

.start {
  width: 100%;
  font-size: 22px;
  padding: 16px 0;
  margin-top: 6px;
  background: #d8342c;
  border-color: #d8342c;
  color: #fff;
  box-shadow: 0 4px 0 #9c211b;
}
.start:active { transform: translateY(3px); box-shadow: 0 1px 0 #9c211b; }

.result {
  font-size: 26px;
  font-weight: 800;
  color: #2b4a5e;
  background: rgba(255, 255, 255, .9);
  border-radius: 14px;
  padding: 10px 22px;
  text-align: center;
  line-height: 1.35;
}
.result small { display: block; font-size: 15px; font-weight: 600; }
