/* Custom hand-drawn cursor set. Frame data / hotspots: assets/icons/cursors/manifest.json
   Busy spin animation is handled in js/cursor.js (CSS cannot animate cursor images).

   !important is used throughout: the rest of the site has ~20 stylesheets with
   ID/class-scoped `cursor: pointer` declarations (e.g. #pixie-cat-pet-panel
   button) that outrank a plain element selector on specificity alone,
   regardless of load order. cursor is a purely cosmetic property with no
   layout/interaction side effects, so forcing it site-wide here is safe. */

/* No !important here on purpose: js/cursor.js drives the Busy animation by
   setting an inline cursor on <body>, and inline styles only lose to a
   stylesheet rule that has !important. Keeping this one non-important lets
   that inline override work, then fall back to this rule when busy ends. */
html, body {
  cursor: url("../assets/icons/cursors/normal.png") 5 2, auto;
}

a,
button,
input[type="submit"],
input[type="button"],
input[type="checkbox"],
input[type="radio"],
select,
[role="button"],
[onclick],
.xp-tb-btn,
.popup-tb-x,
.desk-icon,
.taskbar-btn {
  cursor: url("../assets/icons/cursors/click.png") 5 1, pointer !important;
}

.popup-tb {
  cursor: url("../assets/icons/cursors/move.png") 18 17, move !important;
}

input[type="text"],
input[type="email"],
input[type="search"],
input:not([type]),
textarea,
[contenteditable="true"] {
  cursor: url("../assets/icons/cursors/text-select.png") 6 18, text !important;
}

[disabled],
.disabled {
  cursor: url("../assets/icons/cursors/unavailable.png") 18 17, not-allowed !important;
}

/* Pixie cat: dragging (grabbed) and hovering (petting) states, toggled by
   js/pixie-cat-terminal-pet-v2.js via body classList */
body.pixie-cat-dragging {
  cursor: url("../assets/icons/cursors/move.png") 18 17, grabbing !important;
}

body.pixie-cat-hover {
  cursor: url("../assets/icons/cursors/pet.png") 18 11, pointer !important;
}

/* Utility classes for manual use anywhere in the markup/JS */
.cursor-normal { cursor: url("../assets/icons/cursors/normal.png") 5 2, auto !important; }
.cursor-click { cursor: url("../assets/icons/cursors/click.png") 5 1, pointer !important; }
.cursor-move { cursor: url("../assets/icons/cursors/move.png") 18 17, move !important; }
.cursor-pet { cursor: url("../assets/icons/cursors/pet.png") 18 11, pointer !important; }
.cursor-text { cursor: url("../assets/icons/cursors/text-select.png") 6 18, text !important; }
.cursor-precision { cursor: url("../assets/icons/cursors/precision.png") 18 17, crosshair !important; }
.cursor-help { cursor: url("../assets/icons/cursors/help.png") 4 8, help !important; }
.cursor-unavailable { cursor: url("../assets/icons/cursors/unavailable.png") 18 17, not-allowed !important; }
.cursor-alternate { cursor: url("../assets/icons/cursors/alternate.png") 8 1, auto !important; }
