/* =========================
   pet.css
   ========================= */

/* Balance Display */
.balance-display {
    font-size: 18px;
    font-weight: bold;
    color: #4CAF50;
    margin: 15px 0;
    text-align: center;
}

/* Shop Pet Container */
.shop-pet {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 15px;
    width: 120px;
    text-align: center;
}

.shop-pet img {
    width: 100%;
    height: auto;
    max-height: 100px;
    border-radius: 10px;
    margin-bottom: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.shop-pet p {
    font-size: 14px;
    margin: 5px 0;
    color: #333;
}

.buy-pet-button {
    padding: 6px 12px;
    background-color: #28a745;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 12px;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s;
}

.buy-pet-button:hover {
    background-color: #218838;
    transform: translateY(-2px);
}

/* Container for the glowing effect */
.selected-pet-animated-border {
    position: relative;
    display: inline-block;
    padding: 10px;
    border-radius: 20px;
    background: radial-gradient(circle, rgba(255, 215, 0, 0.6), transparent);
    box-shadow: 
        0 0 30px 10px rgba(255, 215, 0, 0.5),
        0 0 60px 20px rgba(255, 69, 0, 0.3);
    animation: glowingEffect 2s infinite alternate;
    overflow: visible;
}

@keyframes glowingEffect {
    0% {
        box-shadow: 
            0 0 20px 5px rgba(255, 215, 0, 0.5), 
            0 0 40px 15px rgba(255, 69, 0, 0.3);
    }
    100% {
        box-shadow: 
            0 0 40px 10px rgba(255, 215, 0, 0.7), 
            0 0 80px 25px rgba(255, 69, 0, 0.5);
    }
}

.selected-pet-container {
    display: flex;
    justify-content: center;
    margin: 20px 0;
}

/* Modals */
.pet-collection,
.pet-shop,
.pet-stat {
    display: flex;
    justify-content: center;
    align-items: center;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 999;
}

.hidden {
    display: none;
}

/* Modal Content */
.pet-modal-content {
    background-color: #fff;
    padding: 20px;
    border-radius: 15px;
    text-align: center;
    position: relative;
    max-width: 500px;
    width: 95%;
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.3);
    overflow-y: auto;
    max-height: 90%;
}

.pet-modal-content h3 {
    font-size: 20px;
    margin-bottom: 15px;
    color: #333;
    font-weight: bold;
}

/* Close button for modal */
.close-button {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    color: #333;
    transition: color 0.3s;
}

.close-button:hover {
    color: red;
}

/* Pet options inside the modal */
.pet-options {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
    padding: 10px 0;
}

.pet-option {
    width: 100px;
    height: 100px;
    cursor: pointer;
    border-radius: 10px;
    transition: transform 0.3s ease, box-shadow 0.3s;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    background-color: #f9f9f9;
}

.pet-option:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

/* Responsive */
@media (max-width: 768px) {
    .shop-pet {
        width: 100px;
    }
    .shop-pet img {
        max-height: 80px;
    }
    .pet-modal-content {
        max-width: 90%;
        max-height: 85%;
    }
}
@media (max-width: 480px) {
    .shop-pet {
        width: 90px;
    }
    .shop-pet img {
        max-height: 70px;
    }
    .pet-modal-content {
        max-width: 85%;
        padding: 15px;
    }
}
