/**
 * Friends: profile friend bar, friend rows (profile preview, /user/{pid}/friends,
 * /member/friends), member notifications Friends tab and the @mention picker.
 * Ported from the live theme's user.min.css. Bell rows live in notifications-bell.css.
 */

.ak-fav-note {
  font-size: 12px;
  color: #9d9dbb;
  margin: 0 0 10px;
}

.ak-friend-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 10px;
}

.ak-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: .38rem .75rem;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.06);
  color: #cfe8f8;
  text-decoration: none;
  cursor: pointer;
  line-height: 1.2;
}

.ak-btn:hover {
  filter: brightness(1.08);
  color: #fff;
  text-decoration: none;
}

.ak-btn-primary {
  background: rgba(38,163,214,.22);
  border-color: rgba(38,163,214,.55);
  color: #9ee7ff;
}

.ak-btn-danger {
  background: rgba(180,35,24,.18);
  border-color: rgba(180,35,24,.45);
  color: #ffb4ae;
}

.ak-btn-muted {
  color: #9d9dbb;
}

.ak-btn[hidden] {
  display: none!important;
}

.ak-friend-name {
  font-size: 13px;
  font-weight: 700;
  color: #e8eef6;
  text-align: center;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ak-friend-title {
  display: flex;
  justify-content: center;
  max-width: 100%;
  min-width: 0;
}

.ak-friend-title .ak-title-eq {
  margin: 0;
  max-width: 100%;
  font-size: 11px;
  justify-content: center;
}

.ak-friend-rankline {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  max-width: 100%;
  min-width: 0;
}

.ak-friend-rank {
  font-size: 10px;
  color: #9d9dbb;
  text-align: center;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ak-friends-panel {
  padding: 10px;
  background: rgba(28,28,28,.2);
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 12px;
}

.ak-friends-panel.is-compact {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 6px;
  padding: 8px;
}

.ak-friends-panel.is-compact .ak-friend-row {
  padding: 6px 8px;
  border-radius: 10px;
  min-width: 0;
  width: 100%;
}

.ak-friends-panel.is-compact .ak-friend-who {
  gap: 8px;
  width: 100%;
}

.ak-friends-panel.is-compact .ak-friend-ava-wrap {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
}

.ak-friends-panel.is-compact .ak-friend-who .ak-friend-ava {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
}

.ak-friends-panel.is-compact .ak-friend-who .ak-friend-copy {
  min-width: 0;
  overflow: hidden;
}

.ak-friends-panel.is-compact .ak-friend-who .ak-friend-top {
  gap: 4px 6px;
}

.ak-friends-panel.is-compact .ak-friend-who .ak-friend-name {
  font-size: 12px;
  font-weight: 700;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ak-friends-panel.is-compact .ak-friend-who .ak-friend-title {
  min-width: 0;
  max-width: 100%;
}

.ak-friends-panel.is-compact .ak-friend-who .ak-friend-title .ak-title-eq,
.ak-friends-panel.is-compact .ak-friend-who .ak-title-eq {
  font-size: 9px;
  padding: 0 6px;
  max-width: 100%;
  overflow: hidden;
}

.ak-friends-panel.is-compact .ak-friend-who .ak-friend-rankline {
  gap: 4px;
  max-width: 100%;
  overflow: hidden;
}

.ak-friends-panel.is-compact .ak-friend-who .badg-aura {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
}

.ak-friends-panel.is-compact .ak-friend-who .badg-level,
.ak-friends-panel.is-compact .ak-friend-who img.badg-level {
  width: 16px;
  height: 16px;
  min-width: 16px;
  min-height: 16px;
}

.ak-friends-panel.is-compact .ak-friend-who .ak-friend-rank {
  font-size: 10px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ak-friends-panel.is-compact .ak-friend-who .ak-friend-copy {
  gap: 2px;
}

.ak-friends-panel.is-compact .ak-friend-row>.ak-btn,
.ak-friends-panel.is-compact .ak-friend-acts .ak-btn {
  font-size: 11px;
  padding: .28rem .55rem;
  flex: 0 0 auto;
}

.ak-friends-panel.is-compact .ak-friend-acts {
  gap: 4px;
}

@media (max-width:575.98px) {
  .ak-friends-panel.is-compact {
    grid-template-columns: 1fr;
  }
}

@media (min-width:1200px) {
  .ak-friends-panel.is-compact {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }
}

.ak-friends-foot {
  display: flex;
  justify-content: flex-end;
  margin-top: 8px;
}

.ak-friends-foot a,
.ak-friends-foot a:hover,
.ak-friends-foot a:focus,
.ak-friends-head-link a,
.ak-friends-head-link a:hover,
.ak-friends-head-link a:focus {
  font-size: 12px;
  color: #5ec4f0;
  text-decoration: none!important;
  font-weight: 700;
}

.ak-friends-foot a:hover,
.ak-friends-foot a:focus,
.ak-friends-head-link a:hover,
.ak-friends-head-link a:focus {
  color: #9ee7ff;
}

.ak-friends-head-link {
  padding-top: 4px;
}

.ak-friend-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 0 0 14px;
}

.ak-friend-tabs a {
  padding: .35rem .7rem;
  border-radius: 8px;
  color: #c5d0dc;
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
  border: 1px solid rgba(255,255,255,.08);
}

.ak-friend-tabs a.is-on {
  color: #9ee7ff;
  border-color: rgba(38,163,214,.5);
  background: rgba(38,163,214,.14);
}

.ak-friend-rows {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.ak-friend-rows.is-quiet {
  gap: 6px;
}

.ak-friend-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: .85rem 4px;
  border-top: 1px solid rgba(255,255,255,.06);
}

.ak-friend-rows.is-quiet .ak-friend-row {
  padding: 10px 12px;
  border-top: 0;
  border-radius: 12px;
  background: rgba(255,255,255,.025);
  border: 1px solid transparent;
  transition: background .15s ease,border-color .15s ease;
}

.ak-friend-rows.is-quiet .ak-friend-row:hover {
  background: rgba(255,255,255,.04);
  border-color: rgba(38,163,214,.2);
}

.ak-friend-rows.is-quiet.ak-friends-panel.is-compact {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 6px;
}

@media (max-width:575.98px) {
  .ak-friend-rows.is-quiet.ak-friends-panel.is-compact {
    grid-template-columns: 1fr;
  }
}

.ak-friend-who {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  flex: 1 1 auto;
  color: #fff;
  text-decoration: none;
  font-weight: 700;
}

.ak-friend-ava-wrap {
  position: relative;
  width: 52px;
  height: 52px;
  flex: 0 0 52px;
}

.ak-friend-ava-link {
  display: block;
  width: 100%;
  height: 100%;
  text-decoration: none;
  color: inherit;
}

.ak-friend-who .ak-friend-ava {
  width: 52px;
  height: 52px;
  flex: 0 0 52px;
  position: relative;
  overflow: visible;
  display: block;
}

.ak-friend-who .avatar-clip {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  overflow: hidden;
  background: #101925;
}

.ak-friend-who .avatar-clip-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ak-friend-who .avatar-decoration {
  position: absolute!important;
  top: -14%!important;
  left: -14%!important;
  width: 128%!important;
  height: 128%!important;
  max-width: none!important;
  object-fit: contain;
  pointer-events: none;
  z-index: 2;
}

.ak-friend-who .ak-friend-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  min-width: 0;
  flex: 1;
}

.ak-friend-who .ak-friend-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
  min-width: 0;
}

.ak-friend-who .ak-friend-name {
  text-align: left;
  font-size: 13px;
  font-weight: 800;
  color: #fff;
  line-height: 1.2;
  text-decoration: none;
}

a.ak-friend-name:hover {
  color: #9ee7ff;
}

.ak-friend-who .ak-friend-title {
  justify-content: flex-start;
}

.ak-friend-who .ak-friend-title .ak-title-eq {
  margin: 0;
  font-size: 10px;
  padding: 1px 7px;
}

.ak-friend-who .ak-friend-rankline {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
}

.ak-friend-who .ak-title-eq {
  margin: 0;
  font-size: 12px;
}

.ak-friend-who .badg-aura {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  margin: 0;
  overflow: visible;
  flex: 0 0 26px;
}

.ak-friend-who .badg-aura::before,
.ak-friend-who .badg-aura::after {
  display: none!important;
  content: none!important;
  animation: none!important;
}

.ak-friend-who .badg-aura,
.ak-friend-who .badg-aura * {
  animation: none!important;
}

.ak-friend-who .badg-level,
.ak-friend-who img.badg-level {
  width: 22px;
  height: 22px;
  min-width: 22px;
  min-height: 22px;
  margin: 0;
  object-fit: contain;
  display: block;
  border-radius: 4px;
}

.ak-friend-who .ak-friend-rank {
  font-size: 12px;
  color: #9d9dbb;
  font-weight: 700;
}

.ak-friend-acts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  flex: 0 0 auto;
}

.ak-mention {
  position: fixed;
  z-index: 10050;
  width: min(280px,calc(100vw - 16px));
  background: #142030;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 10px;
  box-shadow: 0 12px 32px rgba(0,0,0,.45);
  overflow: hidden;
}

.ak-mention-tabs {
  display: flex;
  border-bottom: 1px solid rgba(255,255,255,.06);
}

.ak-mention-tabs button {
  flex: 1;
  background: transparent;
  border: 0;
  color: #9d9dbb;
  padding: .45rem;
  font-weight: 700;
  font-size: 12px;
  cursor: pointer;
}

.ak-mention-tabs button.is-on {
  color: #9ee7ff;
}

.ak-mention-list {
  max-height: 240px;
  overflow: auto;
}

.ak-mention-hit {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  text-align: left;
  background: transparent;
  border: 0;
  border-top: 1px solid rgba(255,255,255,.05);
  color: #e8eef5;
  padding: .45rem .6rem;
  cursor: pointer;
}

.ak-mention-hit:hover,
.ak-mention-hit.is-on {
  background: rgba(255,255,255,.05);
}

.ak-mention-hit img {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
}

.ak-mention-hit em {
  margin-left: auto;
  font-style: normal;
  font-size: 10px;
  color: #9ee7ff;
}

.ak-mention-empty {
  padding: .55rem .7rem;
  color: #8097b2;
  font-size: 12px;
}

/* <x-frontend.avatar> renders a bare <img> when no decoration is equipped. */
.ak-friend-who .ak-friend-ava > img.avatar-clip-img {
  border-radius: 50%;
  background: #101925;
}

.ak-btn:disabled {
  opacity: .6;
  cursor: wait;
}

.member-notifications-page .noti-row-actions.ak-friend-acts {
  align-items: center;
  margin-left: 8px;
}
