/* Compact contact list: identity on the left, activity and read state on the right. */
.contacts { padding: 0 0 10px; }
.contact {
  position: relative;
  height: 68px;
  gap: 12px;
  padding: 10px 16px 10px 12px;
  border-radius: 0;
  color: #48515b;
}
.contact::after {
  content: '';
  position: absolute;
  left: 68px;
  right: 16px;
  bottom: 0;
  height: 1px;
  background: #edf0f2;
  pointer-events: none;
}
.contact:hover { background: #f7f8fa; }
.contact.active, .contact.active:hover { background: #f0f2f5; color: #48515b; }
.contact:focus-visible { outline: 2px solid #2aabee; outline-offset: -2px; }
.contact-avatar-wrap { position: relative; flex: 0 0 44px; width: 44px; height: 44px; }
.contact .avatar { width: 44px; height: 44px; border-radius: 50%; flex-basis: 44px; font-size: 16px; }
.contact-avatar-wrap .provider-indicator {
  position: absolute;
  right: -3px;
  bottom: -2px;
  z-index: 1;
  width: 14px;
  height: 14px;
  border: 2px solid #fff;
  box-sizing: content-box;
  border-radius: 50%;
  background-color: #fff;
}
.contact-body { display: flex; flex-direction: column; gap: 5px; }
.contact-top { align-items: center; gap: 10px; }
.contact-identity { display: flex; align-items: center; min-width: 0; gap: 5px; }
.contact-kind { display: grid; place-items: center; flex: 0 0 14px; width: 14px; height: 14px; color: #657587; }
.contact-kind svg { display: block; width: 100%; height: 100%; }
.contact-kind-group { color: #356ca0; }
.contact-kind-channel { color: #775887; }
html[data-theme=dark] .contact-kind { color: #a7bacc; }
html[data-theme=dark] .contact-kind-group { color: #8bc7fd; }
html[data-theme=dark] .contact-kind-channel { color: #d3addc; }
.contact-name, .contact.active .contact-name { font-size: 14px; line-height: 18px; font-weight: 600; color: inherit; }
.contact-time { flex: 0 0 auto; color: #969da5; font-size: 11px; line-height: 16px; font-weight: 400; white-space: nowrap; }
.contact-bottom { display: flex; align-items: center; gap: 8px; min-width: 0; min-height: 20px; }
.contact .last-message, .contact.active .last-message {
  flex: 1;
  min-width: 0;
  margin: 0;
  font-size: 13px;
  line-height: 20px;
  font-weight: 400;
  color: #9299a1;
}
.contact .contact-side { gap: 5px; min-height: 20px; }
.contact .contact-unread-badge, .contact.active .contact-unread-badge {
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: #2aabee;
  color: #fff;
  font-size: 11px;
  font-weight: 500;
  line-height: 20px;
}
.contact :is(.contact-pin,.contact-muted,.contact-notes-icon),
.contact.active :is(.contact-pin,.contact-muted,.contact-notes-icon) {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  margin: 0;
  color: #a0a8af;
}
.contact :is(.contact-pin,.contact-muted), .contact.active :is(.contact-pin,.contact-muted) {
  width:20px; height:20px; justify-content:center; border-radius:6px; opacity:1;
}
.contact .contact-pin, .contact.active .contact-pin { color:#555f6d; background:#eaedf1; transform:none; }
.contact-pin .chat-ui-icon { width:14px; height:14px; flex-basis:14px; transform:rotate(32deg); }
.contact .contact-muted, .contact.active .contact-muted { color:#b52f3a; background:#fae8e9; }
.contact .message-receipt { color:#647587; }
.contact .message-receipt.is-read { color:#137fae; }
html[data-theme=dark] .contact .contact-pin { color:#d4deeb; background:#394857; }
html[data-theme=dark] .contact .contact-muted { color:#ffa1a8; background:#563239; }
html[data-theme=dark] .contact .message-receipt { color:#9eafbf; }
html[data-theme=dark] .contact .message-receipt.is-read { color:#71ccf4; }
.contact-folder-heading { padding-right: 16px; }
.contact-folder-contents { margin-left: 12px; padding-left: 0; }
.contact-folder-contents .contact { padding-left: 10px; padding-right: 16px; }
.contact-folder-contents .contact::after { left: 66px; }
html[data-theme=dark] .contact { color: var(--tg-text); }
html[data-theme=dark] .contact::after { background: #354552; }
html[data-theme=dark] .contact:hover { background: #2e3e4b; }
html[data-theme=dark] .contact.active, html[data-theme=dark] .contact.active:hover { background: #354a5a; color: var(--tg-text); }
html[data-theme=dark] .contact.active .contact-name { color: var(--tg-text); }
html[data-theme=dark] .contact .last-message, html[data-theme=dark] .contact.active .last-message,
html[data-theme=dark] .contact-time { color: #9baeba; }
html[data-theme=dark] .contact-avatar-wrap .provider-indicator { border-color: var(--tg-panel); }
