.profile-directory {
  margin: 0; padding: 14px var(--side) 24px; scroll-margin-top: 12px;
  color: var(--ink); background: var(--surface);
}
.directory-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 12px; }
.profile-card {
  display: flex; min-width: 0; flex-direction: column; overflow: hidden;
  border: 1px solid #51445e; border-radius: 14px; background: #241d32;
  box-shadow: inset 0 1px #ffffff0b;
}
.profile-photo-slot {
  position: relative; display: block; width: 100%; aspect-ratio: 1;
  overflow: hidden; border-bottom: 1px solid #4b3b57; background: #30273e;
}
.profile-photo-slot:has(> img) { aspect-ratio: auto; }
/* The editor may insert an absolutely positioned image with inline sizing. */
.profile-photo-slot > img { display: block; width: 100%; height: auto !important; position: static !important; }
.profile-info { display: flex; flex-direction: column; align-items: flex-start; gap: 7px; padding: 11px 12px 12px; }
.profile-tag {
  display: inline-flex; align-items: center; justify-content: center; min-height: 32px;
  padding: 5px 12px; border: 1px solid #f3ecff99; border-radius: 10px;
  background: linear-gradient(135deg, #eee6ff, #d6c4f4); color: #30213f;
  font-size: .875rem; font-weight: 700; line-height: 1.4;
  box-shadow: inset 0 1px #ffffff80, 0 2px 6px #0002;
}
.profile-detail { display: flex; align-items: center; gap: 5px; color: #c8bed3; font-size: .875rem; line-height: 1.4; }
.profile-detail svg { width: 14px; height: 14px; flex: none; color: #ccb6ea; stroke-width: 1.8; }
.profile-card:focus-visible { outline: 3px solid var(--lime); outline-offset: 2px; }
@media (hover: hover) { .profile-card:hover { border-color: #bba0d0; } }
@media (prefers-reduced-motion: no-preference) {
  .profile-card { transition: transform .16s ease, border-color .16s ease; }
  .profile-card:active { transform: scale(.98); }
}
