/* ==========================================================================
   features/face_focus.css — face-centered crops for circular avatars.
   Applied to <img class="is-face"> inside .avatar / .m-search__avatar circles by
   js/features/face_focus.js (FaceFocus.imgAttrs / FaceFocus.apply), which sets
   the --ff-* custom properties from the per-photo focus `fc` (tools/face_focus.py).
   Percentages only, so the same values work at 28 / 40 / 64 / 96 px.
   object-position keeps the image covering its box; scale(z) about an origin
   inside the box can only grow it, so the circle never shows empty edges.
   Tokens only. No hex colors.
   ========================================================================== */

.avatar img.is-face,
.m-search__avatar img.is-face,
.m-profile__avatar img.is-face {
  object-fit: cover;
  object-position: var(--ff-x, 50%) var(--ff-y, 22%);
  transform-origin: var(--ff-ox, 50%) var(--ff-oy, 50%);
  transform: scale(var(--ff-z, 1));
}

/* WebKit can skip border-radius clipping for transformed children without a stacking context. */
.avatar:has(> img.is-face),
.m-search__avatar:has(> img.is-face),
.m-profile__avatar:has(> img.is-face) {
  isolation: isolate;
}
