/* Native cursors use the supplied Kyuu artwork without a tracking/animation loop. */
@media (hover: hover) and (pointer: fine) {
  body {
    cursor: url("../Kyuu_01_Pointer.cur") 4 4,
      url("../Kyuu_01_Pointer.png") 4 4, auto;
  }
  body :is(a[href], button, summary, select, [role="button"], label[for]) {
    cursor: url("../Kyuu_13_Select.cur") 4 4,
      url("../Kyuu_13_Select.png") 4 4, pointer;
  }
  body :is(input, textarea, [contenteditable="true"]) { cursor: text; }
  body :is(button, input, select, textarea):disabled { cursor: not-allowed; }
}

/* Activate the animated layer only after its image and position are ready. */
html.custom-cursor-active, html.custom-cursor-active * { cursor: none !important; }
#customCursor {
  position: fixed;
  inset: 0 auto auto 0;
  width: 64px;
  height: 64px;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  overflow: visible;
  pointer-events: none;
  user-select: none;
  z-index: 2147483647;
  will-change: transform;
}
#customCursor::backdrop { display: none; }
#customCursor img { display: none; width: 64px; height: 64px; max-width: none; pointer-events: none; }
html[data-cursor-state="default"] #customCursor [data-cursor-image="default"],
html[data-cursor-state="select"] #customCursor [data-cursor-image="select"],
html[data-cursor-state="text"] #customCursor [data-cursor-image="text"] { display: block; }
@media (hover: none), (pointer: coarse) { #customCursor { display: none !important; } }
