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

html,
body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #7ec8e3;
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
  /* Stop iOS rubber-band scroll / accidental gestures */
  overscroll-behavior: none;
  touch-action: none;
  position: fixed;
  inset: 0;
}

#game-container {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

canvas {
  display: block;
  touch-action: none;
  max-width: 100%;
  max-height: 100%;
}

/* Portrait / tall screens: ask to rotate for iPad */
#rotate-hint {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: linear-gradient(180deg, #9ad9f0 0%, #7ec8e3 100%);
}

.rotate-card {
  text-align: center;
  background: #fff8e7;
  border: 4px solid #e8d5b7;
  border-radius: 28px;
  padding: 36px 28px;
  max-width: 420px;
  box-shadow: 0 12px 0 rgba(45, 52, 54, 0.08);
}

.rotate-emoji {
  font-size: 64px;
  line-height: 1;
  margin-bottom: 16px;
}

.rotate-title {
  font-size: 28px;
  color: #2d3436;
  margin-bottom: 10px;
}

.rotate-sub {
  font-size: 20px;
  color: #636e72;
}

@media screen and (orientation: portrait) and (max-width: 1024px) {
  #rotate-hint {
    display: flex;
  }

  #game-container {
    visibility: hidden;
    pointer-events: none;
  }
}
