/* The card of someone else in the room (profile-card.js): frosted glass left of the People panel, a sheet from
   the bottom on a phone. Medal colours are the name tag's (web/level-badge.js). Warm, never red, and nothing
   on it ranks anyone. */

.profile-card { --medal: #8a8a84; position: fixed; z-index: 32; right: calc(var(--gap) * 2 + 320px); top: calc(var(--bar, 50px) + 2 * var(--gap) + 74px); width: 300px; max-height: calc(100dvh - var(--bar, 50px) - 4 * var(--gap) - 74px); display: flex; flex-direction: column; gap: 6px; padding: 12px 16px 14px; overflow-y: auto; overscroll-behavior: contain; opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity .25s ease, transform .3s cubic-bezier(.2, .8, .2, 1), visibility 0s .3s; }
.profile-card.on { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
/* the name plates' materials (web/nameplate.js): dark wood, painted wood, brass, gold */
.profile-card[data-tier="low"] { --medal: #5b4430; }
.profile-card[data-tier="mid"] { --medal: #3f5c4e; }
.profile-card[data-tier="high"] { --medal: #b98d4e; --medal-ink: #111; }
.profile-card[data-tier="top"] { --medal: #dcb968; --medal-ink: #111; }
body.side-closed .profile-card { right: var(--gap); }
body.bag-open .profile-card { right: calc(var(--gap) * 2 + 344px); }

.profile-card > * { flex-shrink: 0; }
.pc-head { display: flex; align-items: center; gap: 12px; }
.pc-medal { flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--medal); color: var(--medal-ink, #f5f2ee); font-size: 18px; font-weight: 800; box-shadow: 0 0 0 3px color-mix(in srgb, var(--medal) 28%, transparent); font-variant-numeric: tabular-nums; }
.pc-medal:empty::before { content: "\2615"; font-size: 17px; }
.pc-who { flex: 1; display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.pc-name { font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pc-who small { color: var(--hud-muted); font-size: 12.5px; }
.profile-card h3 { margin: 8px 0 0; font-size: 11.5px; font-weight: 700; letter-spacing: .02em; text-transform: uppercase; color: var(--hud-muted); }
.pc-items { display: flex; flex-wrap: wrap; gap: 5px; margin: 0; padding: 0; list-style: none; }
.pc-items li { display: inline-flex; align-items: center; gap: 4px; max-width: 100%; padding: 2px 9px 2px 3px; border: 1px solid var(--hud-line); border-radius: 999px; background: color-mix(in srgb, var(--panel) 70%, transparent); font-size: 12px; line-height: 1.2; }
.pc-items li.none { padding-left: 9px; border-style: dashed; color: var(--hud-muted); }
.pc-items img { flex: none; width: 24px; height: 24px; object-fit: contain; }
.pc-items img[hidden] { display: none; }
.pc-items span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pc-count { margin: 10px 0 0; padding-top: 10px; border-top: 1px solid var(--hud-line); font-size: 14px; font-weight: 650; }
.pc-you { margin: 0; padding: 7px 10px; border-radius: 10px; background: color-mix(in srgb, var(--accent) 16%, transparent); font-size: 13px; }
.pc-you[hidden] { display: none; }
.pc-emotes[hidden] { display: none; }
.emote-picker.inline { position: static; display: flex; flex-direction: column; gap: 6px; padding: 0; transform: none; will-change: auto; visibility: visible; opacity: 1; scale: 1; transition: none; }
.emote-picker.inline:not(.open) { display: none; }
.emote-picker.inline .emote-pick-title { flex-wrap: wrap; gap: 0 8px; white-space: normal; }
.emote-picker.inline .emote-pick-row { justify-content: space-between; }
.emote-picker.inline .emote-pick-btn { width: 40px; height: 40px; }
body.emote-library .emote-picker.inline .emote-pick-btn { width: 40px; height: 40px; font-size: 20px; }
.profile-card .icon-btn { flex: none; }

@media (max-width: 760px) {
  .profile-card { top: auto; left: var(--gap); right: var(--gap); bottom: var(--gap); width: auto; max-height: min(88dvh, 680px); transform: translateY(16px); }
  body.side-closed .profile-card, body.bag-open .profile-card { right: var(--gap); }
  .profile-card .icon-btn { width: 44px; height: 44px; }
  .emote-picker.inline .emote-pick-btn, body.emote-library .emote-picker.inline .emote-pick-btn { width: 44px; height: 44px; }
  .profile-card { gap: 4px; padding: 10px 14px 12px; }
  .pc-count { margin-top: 6px; padding-top: 8px; }
}
@media (prefers-reduced-motion: reduce) { .profile-card { transition: none; } }
body.pip .profile-card, body.record .profile-card { display: none !important; }
.pc-tasks { margin: 8px 0 0; font-size: 13.5px; color: var(--hud-muted); font-variant-numeric: tabular-nums; }
