/* PuzzlePit custom cursors (public/cursors). Each rule lists a plain PNG first, then an
   image-set() with a sharper 2x image for high-density screens; browsers that don't support
   image-set() in cursor keep the first rule. The numbers are each image's hotspot. */
html {
  cursor: url("/cursors/arrow.png") 2 2, default;
  cursor: image-set(url("/cursors/arrow.png") 1x, url("/cursors/arrow@2x.png") 2x) 2 2, default;
}
:is(a[href], button, summary, select, label:has(input:is([type="checkbox"], [type="radio"])),
  input:is([type="checkbox"], [type="radio"], [type="range"], [type="file"], [type="submit"], [type="button"]),
  [role="button"], [role="tab"], [role="switch"], [role="option"], .segmented label, .player-icon-option):not(:disabled, [aria-disabled="true"]) {
  cursor: url("/cursors/hand.png") 14 1, pointer;
  cursor: image-set(url("/cursors/hand.png") 1x, url("/cursors/hand@2x.png") 2x) 14 1, pointer;
}
:is(input:not([type="checkbox"], [type="radio"], [type="range"], [type="file"], [type="submit"], [type="button"], [type="color"]),
  textarea, [contenteditable="true"]):not(:disabled) {
  cursor: url("/cursors/text.png") 16 16, text;
  cursor: image-set(url("/cursors/text.png") 1x, url("/cursors/text@2x.png") 2x) 16 16, text;
}
:is(:disabled, [aria-disabled="true"]), :disabled * {
  cursor: url("/cursors/blocked.png") 16 16, not-allowed;
  cursor: image-set(url("/cursors/blocked.png") 1x, url("/cursors/blocked@2x.png") 2x) 16 16, not-allowed;
}
/* Main-site buttons are disabled only while their request runs, so show the hourglass there. */
#lobby-view button:disabled, dialog button:disabled, .contact-panel button:disabled {
  cursor: url("/cursors/busy.png") 16 16, wait;
  cursor: image-set(url("/cursors/busy.png") 1x, url("/cursors/busy@2x.png") 2x) 16 16, wait;
}
/* Choices that are simply unavailable (a taken player icon, the end of a list). */
.player-icon-option:has(input:disabled), .player-icon-option:has(input:disabled) *, .player-icon-rotation button:disabled {
  cursor: url("/cursors/blocked.png") 16 16, not-allowed;
  cursor: image-set(url("/cursors/blocked.png") 1x, url("/cursors/blocked@2x.png") 2x) 16 16, not-allowed;
}
/* Something is loading but the page is still usable. */
:is(body.loading, [aria-busy="true"]) {
  cursor: url("/cursors/arrow-busy.png") 2 2, progress;
  cursor: image-set(url("/cursors/arrow-busy.png") 1x, url("/cursors/arrow-busy@2x.png") 2x) 2 2, progress;
}
/* The page is blocked until something finishes. */
.is-waiting, .is-waiting * {
  cursor: url("/cursors/busy.png") 16 16, wait;
  cursor: image-set(url("/cursors/busy.png") 1x, url("/cursors/busy@2x.png") 2x) 16 16, wait;
}
