.avatar-photo {
  display: grid;
  min-width: 0;
  gap: .5rem;
  padding: .7rem .8rem;
  border: 1px solid #45563b;
  border-radius: .7rem;
  background: linear-gradient(125deg, #292f24, #20261f 78%);
}

.avatar-photo p { margin: 0; }

.avatar-photo .avatar-photo-heading {
  color: #edf5e3;
  font-size: .9rem;
  line-height: 1.33;
  font-weight: 760;
}

.avatar-photo-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .4rem;
}

.avatar-photo button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .34rem;
  min-width: 0;
  min-height: 44px;
  padding: .3rem .45rem;
  border: 1px solid #617258;
  border-radius: .44rem;
  background: #171d17;
  color: #eff6e9;
  font-size: .84rem;
  font-weight: 720;
  line-height: 1.3;
  text-align: center;
  word-break: keep-all;
}

.avatar-photo button svg { width: 1.12em; height: 1.12em; flex: none; color: #bfe197; }
.avatar-photo button:enabled:hover { border-color: var(--lime, #d9ff64); }
.avatar-photo button:disabled { opacity: .56; }
.avatar-photo button:focus-visible { outline-offset: 2px; }

.avatar-photo .avatar-photo-private, .avatar-photo .avatar-photo-status {
  color: var(--muted, #c0c9bb);
  font-size: .78rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
  word-break: keep-all;
}

.avatar-photo .avatar-photo-status[data-state="success"] { color: #d7f9b1; }
.avatar-photo .avatar-photo-status[data-state="error"] { color: #ffc5b9; }
.avatar-photo .avatar-photo-status:empty {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}

.avatar-photo .avatar-photo-capture {
  position: relative;
  overflow: hidden;
  height: clamp(118px, 23dvh, 220px);
  border: 1px solid #55644a;
  border-radius: .5rem;
  background: #121710;
}

.avatar-photo-capture video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  transform: scaleX(-1);
}

.avatar-photo .avatar-photo-guide {
  position: absolute;
  inset: 13% auto 13% 50%;
  aspect-ratio: .77;
  transform: translateX(-50%);
  border: 1px dashed #e5f8c1;
  border-radius: 50%;
  filter: drop-shadow(0 1px 1px #202820);
  pointer-events: none;
}

.avatar-photo-progress:has([data-photo-shutter][hidden]) { grid-template-columns: minmax(0, 1fr); }
.avatar-photo [data-photo-shutter] { border-color: #bbdf9c; background: #bbdf9c; color: #182212; }
.avatar-photo .avatar-photo-device { justify-self: start; }

@media (max-width: 580px) {
  .avatar-photo { padding: .55rem .6rem; gap: .38rem; }
  .avatar-photo button { font-size: .8rem; }
}
