:host {
  display: inline-block;
}

div {
  --background-color: var(--pine-color-primary-100);
  --badge-background-color: var(--pine-color-base-white);
  --border: var(--pine-border-default);
  --radius-round: 50%;
  align-items: center;
  background-color: var(--background-color);
  border-radius: var(--admin-radius-round, var(--radius-round));
  display: inline-flex;
  justify-content: center;
  position: relative;
}
:host(.pds-avatar--admin) div {
  --admin-radius-round: 12px;
  border-radius: var(--admin-radius-round);
}
:host(.pds-avatar--has-image) div {
  background: transparent;
}
@supports selector(:has) {
  div:has(img) {
    background-color: transparent;
  }
}

.pds-avatar__button {
  --box-shadow-focus: 0 0 0 4px var(--pine-color-primary-200);
  align-items: center;
  appearance: none;
  background: transparent;
  border: 0;
  border-radius: var(--radius-round);
  cursor: pointer;
  display: flex;
  padding: 0;
}
.pds-avatar__button:focus-visible {
  box-shadow: var(--box-shadow-focus);
  outline: none;
}

.pds-avatar__badge {
  background-color: var(--badge-background-color);
  border: var(--border);
  border-color: var(--badge-background-color);
  border-radius: var(--radius-round);
  bottom: 0;
  position: absolute;
  right: 0;
}

img {
  border-radius: var(--admin-radius-round, var(--radius-round));
  height: 100%;
  object-fit: cover;
  width: 100%;
}