/* Custom Cursor — actif sur tous les tiers desktop */
.cursor,
.cursor-follower {
    display: none;
}

.cursor {
    position: fixed;
    width: 8px;
    height: 8px;
    background: var(--neon-cyan);
    border-radius: 50%;
    pointer-events: none;
    z-index: 999999;
    transition: background 0.3s ease;
    top: 0;
    left: 0;
}

.cursor-follower {
    position: fixed;
    width: 40px;
    height: 40px;
    border: 1px solid var(--neon-cyan-dim);
    border-radius: 50%;
    pointer-events: none;
    z-index: 999998;
    transition: border-color 0.3s ease;
    top: 0;
    left: 0;
}

/* Afficher dès qu'un tier est connu (low / medium / high) */
.low-perf .cursor,
.medium-perf .cursor,
.high-perf .cursor,
.low-perf .cursor-follower,
.medium-perf .cursor-follower,
.high-perf .cursor-follower {
    display: block;
}

/* mix-blend + will-change uniquement en high (coûteux sans GPU) */
.high-perf .cursor {
    mix-blend-mode: difference;
    will-change: transform;
}

.high-perf .cursor-follower {
    will-change: transform;
}

.cursor.hover {
    background: var(--neon-pink);
}

.cursor-follower.hover {
    border-color: var(--neon-pink);
}

/* Accueil gate : pas de curseur custom (natif jusqu’au passage du portail) */
body.gate-locked .cursor,
body.gate-locked .cursor-follower {
    display: none !important;
    opacity: 0 !important;
}

/* Curseur natif quand custom désactivé (mobile / no-custom / gate) */
html.no-custom-cursor,
html.no-custom-cursor body {
    cursor: auto;
}

html.no-custom-cursor a,
html.no-custom-cursor button {
    cursor: pointer;
}

html:not(.no-custom-cursor).low-perf,
html:not(.no-custom-cursor).medium-perf,
html:not(.no-custom-cursor).high-perf {
    cursor: none;
}

html:not(.no-custom-cursor).low-perf a,
html:not(.no-custom-cursor).low-perf button,
html:not(.no-custom-cursor).low-perf .magnetic,
html:not(.no-custom-cursor).medium-perf a,
html:not(.no-custom-cursor).medium-perf button,
html:not(.no-custom-cursor).medium-perf .magnetic,
html:not(.no-custom-cursor).high-perf a,
html:not(.no-custom-cursor).high-perf button,
html:not(.no-custom-cursor).high-perf .magnetic {
    cursor: none;
}

@media (max-width: 767px) {
    .cursor,
    .cursor-follower {
        display: none !important;
    }

    html {
        cursor: auto !important;
    }
}
