/* Shared premium cursor — home + marketplace + fx pages */
body.p4p-fx-cursor,
body.p4p-fx-cursor * {
    cursor: auto;
}
body.p4p-fx-cursor input,
body.p4p-fx-cursor textarea,
body.p4p-fx-cursor select,
body.p4p-fx-cursor [contenteditable] {
    cursor: text;
}

.p4p-cursor {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 99999;
    pointer-events: none;
    width: 0;
    height: 0;
    will-change: transform;
}
.p4p-cursor__trail {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 99997;
}
.p4p-cursor__beam-h,
.p4p-cursor__beam-v {
    position: fixed;
    pointer-events: none;
    z-index: 99996;
    background: rgba(6, 182, 212, 0.06);
    transition: opacity 0.25s, background 0.25s;
    will-change: transform;
}
.p4p-cursor__beam-h {
    left: 0;
    width: 100vw;
    height: 1px;
    margin-top: -0.5px;
}
.p4p-cursor__beam-v {
    top: 0;
    height: 100vh;
    width: 1px;
    margin-left: -0.5px;
}
.p4p-cursor__orbit {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 64px;
    height: 64px;
    margin: -32px 0 0 -32px;
    border: 1px dashed rgba(6, 182, 212, 0.42);
    border-radius: 50%;
    animation: p4pOrbitSpin 8s linear infinite;
    opacity: 0.8;
}
.p4p-cursor__ring {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 40px;
    height: 40px;
    margin: -20px 0 0 -20px;
    border: 2px solid rgba(6,182,212,0.8);
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(6,182,212,0.3);
    transition: transform 0.35s var(--p4p-ease), border-color 0.35s, box-shadow 0.35s;
    will-change: transform;
}
.p4p-cursor__ring-2 {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 28px;
    height: 28px;
    margin: -14px 0 0 -14px;
    border: 1px solid rgba(168, 85, 247, 0.28);
    border-radius: 50%;
    transition: transform 0.25s var(--p4p-ease), border-color 0.25s;
    will-change: transform;
}
.p4p-cursor__core {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 8px;
    height: 8px;
    margin: -4px 0 0 -4px;
    background: radial-gradient(circle, var(--p4p-accent) 0%, var(--p4p-purple-soft) 100%);
    border-radius: 50%;
    transform: scale(1);
    box-shadow: 0 0 14px var(--p4p-accent-glow), 0 0 22px rgba(167, 139, 250, 0.35);
    transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s;
    will-change: transform;
}
.p4p-cursor.is-hover .p4p-cursor__core {
    transform: scale(1.8);
    box-shadow: 0 0 22px rgba(167, 139, 250, 0.55), 0 0 34px var(--p4p-accent-glow);
    background: #fff;
}
.p4p-cursor.is-hover .p4p-cursor__ring {
    transform: scale(1.65);
    border-color: var(--p4p-accent);
    box-shadow: inset 0 0 10px rgba(232,168,124,0.15), 0 0 40px var(--p4p-accent-glow);
}
.p4p-cursor.is-hover .p4p-cursor__ring-2 {
    transform: scale(1.35) rotate(45deg);
    border-color: rgba(168, 85, 247, 0.45);
}
.p4p-cursor.is-hover .p4p-cursor__beam-h,
.p4p-cursor.is-hover .p4p-cursor__beam-v {
    opacity: 0.45;
    background: rgba(6, 182, 212, 0.10);
}
.p4p-cursor.is-hover .p4p-cursor__orbit {
    border-color: rgba(168, 85, 247, 0.5);
    animation-duration: 4s;
}
.p4p-cursor.is-click .p4p-cursor__core {
    transform: scale(0.65);
    transition: transform 0.08s ease;
}
.p4p-cursor.is-click .p4p-cursor__ring {
    transform: scale(0.9);
    transition: transform 0.08s ease;
}
.p4p-cursor__ripple {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 8px;
    height: 8px;
    margin: -4px 0 0 -4px;
    border-radius: 50%;
    border: 1px solid rgba(6, 182, 212, 0.6);
    transform: scale(1);
    opacity: 0;
    pointer-events: none;
}
.p4p-cursor__ripple.is-active {
    animation: p4pCursorRipple 0.55s ease-out forwards;
}
@keyframes p4pCursorRipple {
    0% { transform: scale(1); opacity: 0.7; border-color: rgba(6, 182, 212, 0.8); }
    100% { transform: scale(5); opacity: 0; border-color: rgba(6, 182, 212, 0); }
}

@keyframes p4pOrbitSpin {
    to { transform: rotate(360deg); }
}

@media (max-width: 767px), (pointer: coarse) {
    body.p4p-fx-cursor, body.p4p-fx-cursor * { cursor: auto !important; }
    body.p4p-fx-cursor a, body.p4p-fx-cursor button { cursor: pointer !important; }
    .p4p-cursor, .p4p-cursor__trail, .p4p-cursor__beam-h, .p4p-cursor__beam-v { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    body.p4p-fx-cursor, body.p4p-fx-cursor * { cursor: auto !important; }
    .p4p-cursor { display: none; }
}
