/* Add class="fairy-cursor" to <body>. */
.fairy-glow, .fairy-glow-layer { display: none; }

/* Ein Leuchten, das dem Zeiger folgt, ist Bewegung. Wer im System weniger
   davon eingestellt hat, bekommt den Zeiger, aber kein Nachziehen. */
@media (hover: hover) and (pointer: fine) and (forced-colors: none)
  and (prefers-reduced-motion: no-preference) {
  .fairy-cursor {
    cursor: url("./fairy-cursor.svg?v=2") 3 3, auto;
  }

  .fairy-cursor :is(a[href], button, summary, [role="button"], select, input[type="button"], input[type="submit"], input[type="reset"], input[type="checkbox"], input[type="radio"], input[type="range"], label[for]) {
    cursor: url("./fairy-cursor.svg?v=2") 3 3, pointer;
  }

  .fairy-cursor :where(input:not([type="button"]):not([type="submit"]):not([type="reset"]):not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="file"]):not([type="color"]), textarea, [contenteditable="true"]) {
    cursor: text;
  }

  .fairy-cursor :is(:disabled, [aria-disabled="true"]) {
    cursor: not-allowed;
  }

  .fairy-cursor .fairy-glow-layer {
    display: block;
    position: fixed;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    user-select: none;
    z-index: 2147483647;
  }

  .fairy-cursor .fairy-glow[data-visible] {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    width: 96px;
    height: 96px;
    border-radius: 50%;
    pointer-events: none;
    user-select: none;
    background: radial-gradient(circle closest-side, rgba(232, 83, 175, .35) 0%, rgba(232, 83, 175, .22) 35%, rgba(232, 83, 175, .08) 68%, rgba(232, 83, 175, 0) 100%);
  }
}

/* Der Fairy-Zeiger selbst bleibt auch bei reduzierter Bewegung — er zieht nicht
   nach, er ist nur ein anderes Bild. Nur das Leuchten entfaellt. */
@media (hover: hover) and (pointer: fine) and (forced-colors: none) and (prefers-reduced-motion: reduce) {
  .fairy-cursor { cursor: url("./fairy-cursor.svg?v=2") 3 3, auto; }
  .fairy-cursor :is(a[href], button, summary, [role="button"], select, input[type="button"], input[type="submit"], input[type="reset"], label[for]) {
    cursor: url("./fairy-cursor.svg?v=2") 3 3, pointer;
  }
}
