:root {
  color-scheme: light;
  --desk-a: #8f6f52;
  --desk-b: #6f513d;
  --paper: #f2e7d6;
  --paper-2: #e5d4bc;
  --ink: #2d241b;
  --muted: rgba(45, 36, 27, 0.68);
  --accent: #b6542f;
}

html,
body {
  margin: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background:
    radial-gradient(circle at top, rgba(255, 246, 231, 0.2), transparent 32%),
    linear-gradient(160deg, var(--desk-a), var(--desk-b));
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
  overscroll-behavior: none;
}

body {
  font-family: "Iowan Old Style", "Palatino Linotype", Georgia, serif;
}

#app {
  position: fixed;
  inset: 0;
}

#game {
  width: 100%;
  height: 100%;
  display: block;
  touch-action: none;
  cursor: default;
}

#hud {
  position: absolute;
  inset: max(14px, env(safe-area-inset-top)) auto auto max(14px, env(safe-area-inset-left));
  width: min(320px, calc(100vw - 28px));
  color: rgba(40, 31, 22, 0.9);
  pointer-events: none;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
}

#title {
  font-size: clamp(20px, 3vw, 28px);
  letter-spacing: 0.04em;
  margin-bottom: 8px;
}

#goal,
#hint {
  font-size: clamp(12px, 1.8vw, 15px);
  line-height: 1.35;
  max-width: 28ch;
}

#goal {
  margin-bottom: 6px;
}

#hint {
  color: var(--muted);
}

#nudge {
  pointer-events: auto;
  margin-top: 10px;
  border: 1px solid rgba(62, 44, 30, 0.35);
  background: rgba(250, 241, 225, 0.84);
  color: rgba(48, 37, 27, 0.92);
  font: inherit;
  font-size: clamp(12px, 1.7vw, 14px);
  line-height: 1;
  padding: 10px 12px;
  border-radius: 999px;
  box-shadow: 0 4px 10px rgba(48, 35, 24, 0.12);
  cursor: pointer;
}

#nudge:active {
  transform: translateY(1px);
}

@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto;
  }
}
