/* YunaGRP WindowsMita cursor — hybrid zero-chase build.
 * Moving: native/browser PNG cursor (instant).
 * Idle: animated WebP overlay; native cursor is completely hidden.
 * Windows/Chrome may visually enlarge a native CSS cursor compared with a DOM
 * image. The native-small PNGs keep a 32x32 cursor canvas but scale the visible
 * artwork to 25x25 around its hotspot, so movement and idle animation appear
 * much closer in size without sacrificing the native cursor's low latency.
 */

@media (hover: hover) and (pointer: fine), (any-hover: hover) and (any-pointer: fine) {
  /* Default static cursors. The JS only changes data-mita-cursor-role on <html>.
     Applying the cursor to every descendant with !important intentionally beats
     Tailwind/ARC/admin rules such as button{cursor:pointer!important}. */
  html.mita-cursor-native[data-mita-cursor-role="Normal"]      { --mita-native-cursor: url("native-small/Normal.png") 0 0, auto; }
  html.mita-cursor-native[data-mita-cursor-role="Link"]        { --mita-native-cursor: url("native-small/Link.png") 4 0, pointer; }
  html.mita-cursor-native[data-mita-cursor-role="Text"]        { --mita-native-cursor: url("native-small/Text.png") 4 9, text; }
  html.mita-cursor-native[data-mita-cursor-role="Busy"]        { --mita-native-cursor: url("native-small/Busy.png") 15 15, wait; }
  html.mita-cursor-native[data-mita-cursor-role="Working"]     { --mita-native-cursor: url("native-small/Working.png") 0 0, progress; }
  html.mita-cursor-native[data-mita-cursor-role="Help"]        { --mita-native-cursor: url("native-small/Help.png") 0 0, help; }
  html.mita-cursor-native[data-mita-cursor-role="Unavailable"] { --mita-native-cursor: url("native-small/Unavailable.png") 0 0, not-allowed; }
  html.mita-cursor-native[data-mita-cursor-role="Move"]        { --mita-native-cursor: url("native-small/Move.png") 15 15, move; }
  html.mita-cursor-native[data-mita-cursor-role="Horizontal"]  { --mita-native-cursor: url("native-small/Horizontal.png") 15 15, ew-resize; }
  html.mita-cursor-native[data-mita-cursor-role="Vertical"]    { --mita-native-cursor: url("native-small/Vertical.png") 15 15, ns-resize; }
  html.mita-cursor-native[data-mita-cursor-role="Diagonal1"]   { --mita-native-cursor: url("native-small/Diagonal1.png") 15 15, nwse-resize; }
  html.mita-cursor-native[data-mita-cursor-role="Diagonal2"]   { --mita-native-cursor: url("native-small/Diagonal2.png") 15 15, nesw-resize; }
  html.mita-cursor-native[data-mita-cursor-role="Precision"]   { --mita-native-cursor: url("native-small/Precision.png") 5 6, crosshair; }
  html.mita-cursor-native[data-mita-cursor-role="Alternate"]   { --mita-native-cursor: url("native-small/Alternate.png") 4 0, alias; }
  html.mita-cursor-native[data-mita-cursor-role="Handwriting"] { --mita-native-cursor: url("native-small/Handwriting.png") 0 0, auto; }
  html.mita-cursor-native[data-mita-cursor-role="Person"]      { --mita-native-cursor: url("native-small/Person.png") 0 0, auto; }
  html.mita-cursor-native[data-mita-cursor-role="Pin"]         { --mita-native-cursor: url("native-small/Pin.png") 0 0, auto; }

  html.mita-cursor-native,
  html.mita-cursor-native *,
  html.mita-cursor-native *::before,
  html.mita-cursor-native *::after {
    cursor: var(--mita-native-cursor, url("native-small/Normal.png") 0 0, auto) !important;
  }

  /* Idle animation mode. This is deliberately stronger than all button/input
     cursor declarations in the project, fixing the old double-cursor problem. */
  html.mita-cursor-animated-idle,
  html.mita-cursor-animated-idle *,
  html.mita-cursor-animated-idle *::before,
  html.mita-cursor-animated-idle *::after {
    cursor: none !important;
  }
}

#mita-web-cursor {
  position: fixed !important;
  left: 0 !important;
  top: 0 !important;
  width: 35px !important;
  height: 35px !important;
  display: block !important;
  max-width: none !important;
  max-height: none !important;
  min-width: 0 !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  filter: none !important;
  object-fit: contain !important;
  pointer-events: none !important;
  user-select: none !important;
  -webkit-user-select: none !important;
  visibility: hidden;
  z-index: 2147483647 !important;
  transform: translate3d(-100px, -100px, 0);
  transition: none !important;
  animation: none !important;
  will-change: transform;
  contain: layout style paint;
  backface-visibility: hidden;
}
