/* The game canvas is an interaction surface: a drag must never refresh it. */
html, body, #game { overscroll-behavior: none; }
#world { touch-action: none; }

/* Opt-in list feedback floats above content without moving the reading place. */
.weilight-safety-card { position: relative; }
.weilight-pull-status { position: absolute; top: 8px; left: 0; right: 0; z-index: 5; height: 0; margin: 0; padding: 0; overflow: visible; overflow-anchor: none; text-align: center; pointer-events: none; }
.weilight-pull-status[hidden] { display: none !important; }
.weilight-pull-status > span { display: inline-block; max-width: calc(100% - 24px); padding: 7px 14px; border-radius: 18px; background: #fffdf4; color: #244c42; box-shadow: 0 2px 12px #102b2630; font: 14px/1.5 system-ui,sans-serif; }
.weilight-pull-status[data-state=error] > span { color: #863820; }
.weilight-pull-hint { font-size: 12px; color: #536c63; }

/* Suppress accidental game-control selection while keeping reading/editing. */
#game button, #game [role="button"], #world, #game img, #game svg {
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  -webkit-user-drag: none;
}
#game button, #game [role="button"] { touch-action: manipulation; }
#game input, #game textarea, #game [contenteditable="true"] {
  -webkit-user-select: text;
  user-select: text;
  -webkit-touch-callout: default;
}

/* Scroll a sheet or conversation without transferring the gesture to canvas. */
#sheet, #lifePanel, #homePanel, #publicJournalDialog, #mistPanel,
.experience-drawer, .weather-card, .philosophy-body, .philosophy-log,
.npc-chat-log, .spirit-thread, .mist-conversation {
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}
@media (pointer: coarse) {
  #game input:not([type="range"]):not([type="checkbox"]):not([type="radio"]),
  #game textarea, #game select { font-size: max(16px, 1em); }
}
