/* ============================================
   DOG AVATAR STYLES - BUGGY THEME
   Clean avatar display for the adorable puppy
   ============================================ */

/* Container for dog avatars with proper cropping */
.dog-avatar-wrapper {
  position: relative;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  overflow: hidden;
  background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
  border: 3px solid #fff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* The actual dog image - positioned to show face */
.dog-avatar-image {
  position: absolute;
  width: 100%; /* Scale up to zoom in on face */
  height: auto;
  top: 10%; /* Adjust to center on puppy's face */
  left: 0%; /* Center horizontally on puppy */
  /* Removed transform scale to prevent conflicting zoom */
  object-fit: cover;
  object-position: center 30%; /* Focus on upper portion where face is */
}

/* Specific positioning for the car puppy image */
.dog-avatar-image.puppy-car {
  width: 90%;
  top: 10%;
  left: 5%;
  object-position: 45% 25%; /* Fine-tune to center on puppy's face */
}

/* Small avatar version (navbar) */
.dog-avatar-wrapper.avatar-sm {
  width: 36px;
  height: 36px;
  border-width: 2px;
}

.dog-avatar-wrapper.avatar-sm .dog-avatar-image {
  width: 110%; /* More zoom for small size */
  top: 5%;
  left: -5%;
}

/* Medium avatar version */
.dog-avatar-wrapper.avatar-md {
  width: 64px;
  height: 64px;
}

/* Large avatar version */
.dog-avatar-wrapper.avatar-lg {
  width: 128px;
  height: 128px;
}

/* Extra large avatar version (profile pages) */
.dog-avatar-wrapper.avatar-xl {
  width: 200px;
  height: 200px;
  border-width: 4px;
}

/* Fallback gradient background */
.dog-avatar-fallback {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 48px;
}

/* Loading state */
.dog-avatar-wrapper.loading {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

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

/* Hover effect */
.dog-avatar-wrapper:hover {
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
  cursor: pointer;
}

/* Badge for default avatars */
.dog-avatar-badge {
  position: absolute;
  bottom: 5px;
  right: 5px;
  background: #78c2ad;
  color: white;
  border-radius: 12px;
  padding: 2px 8px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  z-index: 2;
}

/* Integration with navbar */
.user-avatar .dog-avatar-wrapper {
  width: 36px;
  height: 36px;
  position: absolute;
  top: 0;
  left: 0;
}

/* Clean display in avatar manager */
.current-avatar-display .dog-avatar-wrapper {
  margin: 0 auto;
}

/* Mobile responsive adjustments */
@media (max-width: 768px) {
  .dog-avatar-wrapper {
    width: 100px;
    height: 100px;
  }
  
  .dog-avatar-wrapper.avatar-sm {
    width: 32px;
    height: 32px;
  }
}

/* Blur background effect for better focus */
.dog-avatar-wrapper::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at center, transparent 40%, rgba(255, 255, 255, 0.3) 100%);
  z-index: 1;
  pointer-events: none;
}

/* Ensure image is behind the gradient overlay */
.dog-avatar-image {
  z-index: 0;
}