/* ============================================
   自由活动宠物系统 - CSS
   ============================================ */

/* 自由宠物容器 */
.free-pet-container {
    position: fixed;
    z-index: 9999;
    cursor: grab;
    user-select: none;
    transition: none;
}

.free-pet-container:active {
    cursor: grabbing;
}

/* 宠物 GIF 图片 */
.free-pet-gif {
    width: 200px;
    height: 200px;
    object-fit: contain;
    pointer-events: none;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
}

/* 走路动画 - 水平翻转 */
.free-pet-container.walking-left .free-pet-gif {
    transform: scaleX(-1);
}

/* 宠物状态气泡 */
.pet-bubble {
    position: absolute;
    bottom: 210px;
    left: 50%;
    transform: translateX(-50%);
    background: white;
    padding: 12px 18px;
    border-radius: 18px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    font-size: 16px;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
    max-width: 200px;
    word-wrap: break-word;
}

.pet-bubble.show {
    opacity: 1;
}

.pet-bubble::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-top: 8px solid white;
}

/* 宠物状态指示器 */
.pet-status-indicator {
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 4px;
}

.pet-status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    opacity: 0.8;
}

.pet-status-dot.hunger {
    background: #f59e0b;
}

.pet-status-dot.happiness {
    background: #ec4899;
}

/* 小地图指示器（可选） */
.pet-minimap {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 80px;
    height: 60px;
    background: rgba(0,0,0,0.1);
    border-radius: 8px;
    z-index: 9998;
}

.pet-minimap-dot {
    position: absolute;
    width: 8px;
    height: 8px;
    background: #f59e0b;
    border-radius: 50%;
    transition: all 0.5s;
}


/* 固定按钮 */
.free-pet-pin-btn {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 28px;
    height: 28px;
    background: white;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    cursor: pointer;
    z-index: 10;
    opacity: 0;
    transition: opacity 0.2s, transform 0.2s;
    pointer-events: auto;
}

.free-pet-container:hover .free-pet-pin-btn {
    opacity: 1;
}

.free-pet-pin-btn:hover {
    transform: scale(1.2);
    box-shadow: 0 3px 12px rgba(0,0,0,0.3);
}

/* 固定状态下按钮始终可见 */
.free-pet-container.pinned .free-pet-pin-btn {
    opacity: 1;
}
