/* Profile Image Display System */

/* Profile pictures - show real images */
.thumb img,
[data-profile-image],
.profile-pic,
.user-avatar {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 50%;
    box-shadow: 0 8px 25px rgba(0,0,0,0.25);
    background: linear-gradient(135deg, #E91E63, #FF5722);
    display: block;
    border: 8px solid #E91E63;
}

/* Profile card images */
.profile-card img,
.member-card img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: 12px 12px 0 0;
}

/* Avatar backgrounds - use gradient if image fails to load */
[data-user-avatar],
.user-profile-pic {
    background: linear-gradient(135deg, #E91E63, #FF5722);
    border-radius: 50%;
}

/* Homepage profile image styling */
.profiles_window.thumb {
    width: 280px;
    height: 280px;
    margin: 20px auto;
}

.profiles_window.pic_block {
    text-align: center;
    padding: 0;
    background: #f5f5f5;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    border: 6px solid #E91E63;
    width: 280px;
    height: 280px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.profiles_window.pic_block img,
.profiles_window a img,
.profiles_window a img.avatar {
    width: 280px !important;
    height: 280px !important;
    object-fit: cover !important;
    border-radius: 50% !important;
    display: block !important;
}

/* Browse page - profile images */
.thumb {
    background: white;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    width: 300px;
    height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.thumb:hover img {
    transform: scale(1.05);
    transition: transform 0.3s ease;
}

/* Fallback image display */
img[alt="profile"],
img[alt="avatar"] {
    background: linear-gradient(135deg, #E91E63, #FF5722);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

/* Video/Photo thumbnails */
.photo-thumb,
.video-thumb {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.photo-thumb img,
.video-thumb img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

/* Ensure images load properly */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Loading state */
img[loading="lazy"] {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Homepage profile picture block */
.profiles_window {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 20px auto;
}

.profiles_window .pic {
    display: inline-block;
}

/* Responsive images */
@media (max-width: 768px) {
    .thumb img { min-height: 300px; }
    .profile-card img { height: 250px; }
    .photo-thumb img { height: 150px; }
    .thumb {
        width: 250px;
        height: 250px;
    }
}
