.hunt-screen-stage, [data-hunt-preview] { --hunt-peek-size: clamp(150px, var(--hunt-preview-size, 180px), 200px); }
.hunt-decor-zarbi {
    position: absolute; pointer-events: auto;
    width: var(--hunt-peek-size); height: calc(var(--hunt-peek-size) * .58);
    padding: 0; overflow: visible; z-index: 2; opacity: 1 !important;
    filter: none !important; mask-image: none !important; transform: none !important;
    border: 0; border-radius: 0; background: transparent; outline: 0;
}
.hunt-peek-sprite { position: absolute; inset: 0 auto auto 0; width: var(--hunt-peek-size); height: var(--hunt-peek-size); clip-path: inset(0 0 42% 0); pointer-events: none; }
.hunt-peek-zarbi img {
    display: block; width: 100%; height: 100%; object-fit: contain;
    transform: rotate(var(--hunt-facing, 0deg)); transform-origin: 50% 55%; animation: hunt-peek-breathe 6s ease-in-out infinite alternate;
    filter: grayscale(.3) brightness(.88) drop-shadow(0 2px 1px #0009) drop-shadow(0 0 5px #a967d947);
    transition: filter .2s ease; pointer-events: none;
}
.hunt-peek-zarbi:is(:hover, :focus-visible) img { filter: grayscale(0) brightness(1.1) drop-shadow(0 3px 2px #000b) drop-shadow(0 0 10px #ba84ff99); animation-duration: 1.8s; --hunt-sway: 7deg; --hunt-lift: -5px; }
.hunt-peek-zarbi:hover { outline: 0; border-radius: 0; }
.hunt-peek-zarbi:focus-visible { outline: 2px dashed #bca0e6; outline-offset: -4px; border-radius: .75rem; }
.hunt-edge-dust { position: absolute; left: 50%; top: 68%; pointer-events: none; z-index: 3; opacity: .4; transition: opacity .9s ease, filter .9s ease; }
.hunt-peek-zarbi:is(:hover, :focus-visible) .hunt-edge-dust { opacity: .9; filter: brightness(1.15); }
/* Dust inspired by the Unown album entry: soft round motes, slow drift, no sparks. */
.hunt-edge-dust span { position: absolute; left: var(--dust-start-x); top: var(--dust-start-y); width: var(--dust-size); height: var(--dust-size); border-radius: 50%; background: #d7b9f5; box-shadow: 0 0 8px 2px rgb(209 175 255 / 35%); opacity: 0; animation: hunt-edge-drift var(--dust-duration) ease-in-out var(--dust-delay) infinite; }
.hunt-edge-dust span:nth-child(3n) { background: #f6dca3; }
@keyframes hunt-edge-drift {
    0% { opacity: 0; transform: translate3d(0, 0, 0) scale(.7); }
    25% { opacity: .55; }
    55% { opacity: .65; transform: translate3d(calc(var(--dust-x) * .45 + 5px), calc(var(--dust-y) * .4 - 5px), 0) scale(1); }
    85% { opacity: .2; }
    100% { opacity: 0; transform: translate3d(var(--dust-x), var(--dust-y), 0) scale(.8); }
}
@keyframes hunt-peek-breathe { from { transform: rotate(calc(var(--hunt-facing, 0deg) - var(--hunt-sway, 3deg))) translateY(0); } to { transform: rotate(calc(var(--hunt-facing, 0deg) + var(--hunt-sway, 1deg))) translateY(var(--hunt-lift, -2px)); } }
@media (prefers-reduced-motion: reduce) { .hunt-edge-dust { display: none; } .hunt-peek-zarbi img { animation: none; transition: none; } }
.hunt-screen-stage { position: fixed; inset: max(env(safe-area-inset-top, 0px), var(--hunt-navbar-bottom, 0px)) 0 0; overflow: clip; pointer-events: none; z-index: 1015; }
.hunt-screen-stage .hunt-screen-zarbi {
    position: absolute !important; inset: auto !important; width: var(--hunt-peek-size); height: var(--hunt-peek-size);
    padding: 0; overflow: visible; pointer-events: auto; opacity: 1 !important; filter: none !important;
    mask-image: none !important; transform: none !important; border: 0; border-radius: 0; background: transparent; outline: 0;
}
.hunt-screen-zarbi .hunt-peek-sprite { clip-path: none; }
.hunt-screen-zarbi .hunt-edge-dust { top: 50%; }
.hunt-screen-zarbi[data-screen-edge="top"] {
    top: calc(var(--hunt-peek-size) * -.33) !important;
    left: clamp(12px, calc(var(--hunt-edge-track, 50vw) - var(--hunt-peek-size) * .5), calc(100vw - var(--hunt-peek-size) - 12px)) !important;
    --hunt-facing: 180deg;
}
.hunt-screen-zarbi[data-screen-edge="bottom"] {
    bottom: calc(var(--hunt-peek-size) * -.36) !important;
    left: clamp(12px, calc(var(--hunt-edge-track, 50vw) - var(--hunt-peek-size) * .5), calc(100vw - var(--hunt-peek-size) - 12px)) !important;
    --hunt-facing: 0deg;
}
.hunt-screen-zarbi[data-screen-edge="left"] {
    left: calc(var(--hunt-peek-size) * -.36) !important;
    top: clamp(12px, var(--hunt-edge-track, 45vh), calc(100% - var(--hunt-peek-size) - 12px)) !important;
    --hunt-facing: 90deg;
}
.hunt-screen-zarbi[data-screen-edge="right"] {
    right: calc(var(--hunt-peek-size) * -.36) !important;
    top: clamp(12px, var(--hunt-edge-track, 45vh), calc(100% - var(--hunt-peek-size) - 12px)) !important;
    --hunt-facing: -90deg;
}
.hunt-screen-stage .hunt-peek-zarbi:hover { outline: 0; border-radius: 0; }
.hunt-peek-zarbi:focus-visible { outline: 2px dashed #bca0e6; outline-offset: -4px; }

/* A separate wrapper lets arrival/retreat follow the edge without fighting the idle sway. */
.hunt-peek-motion { display: block; width: 100%; height: 100%; animation: hunt-peek-arrive .55s cubic-bezier(.2,.7,.3,1) both; }
.hunt-peek-zarbi { --hunt-entry-x: 0%; --hunt-entry-y: 65%; }
.hunt-screen-zarbi[data-screen-edge="top"] { --hunt-entry-y: -75%; }
.hunt-screen-zarbi[data-screen-edge="bottom"] { --hunt-entry-y: 75%; }
.hunt-screen-zarbi[data-screen-edge="left"] { --hunt-entry-x: -75%; --hunt-entry-y: 0%; }
.hunt-screen-zarbi[data-screen-edge="right"] { --hunt-entry-x: 75%; --hunt-entry-y: 0%; }
.hunt-peek-zarbi.is-leaving { pointer-events: none; }
.hunt-peek-zarbi.is-leaving .hunt-peek-motion { animation: hunt-peek-retreat .35s ease-in both; }
.hunt-peek-zarbi.is-leaving .hunt-edge-dust { opacity: 0; }
@keyframes hunt-peek-arrive { from { opacity: 0; transform: translate(var(--hunt-entry-x), var(--hunt-entry-y)) scale(.92); } to { opacity: 1; transform: translate(0, 0) scale(1); } }
@keyframes hunt-peek-retreat { from { opacity: 1; transform: translate(0, 0); } to { opacity: 0; transform: translate(var(--hunt-entry-x), var(--hunt-entry-y)) scale(.92); } }
@media (prefers-reduced-motion: reduce) { .hunt-peek-motion, .hunt-peek-zarbi.is-leaving .hunt-peek-motion { animation: none; } }

/* Accessible visual fallback when a fingerprinted Unown image fails to load. */
.hunt-peek-zarbi .unown-hunt-fallback { display: grid; place-items: center; width: var(--hunt-peek-size); height: var(--hunt-peek-size); color: #e9d7ff; font-weight: 800; font-size: 2rem; text-shadow: 0 2px 8px #21143b; }
.hunt-peek-zarbi .unown-hunt-fallback.d-none { display: none !important; }
