/* USER / PARTICIPANT CARD
   Doküman kuralı:
   Kullanıcı kartı = avatar + nick + rol + kamera + mikrofon + durum ikonları
   Slot yok. Stage yok. Kamera popup mantığı var.
*/

.participants-list,
.room-participants-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px;
}

.participants-list:empty::before,
.room-participants-list:empty::before {
  content: "Katılımcılar yükleniyor...";
  display: block;
  padding: 18px;
  border-radius: 20px;
  background: #f8fafc;
  color: #64748b;
  text-align: center;
  font-weight: 700;
}

/* Ana kullanıcı kartı */
.user-card,
.participant-card {
  position: relative;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 72px;
  padding: 12px;
  border-radius: 22px;
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, .08);
  box-shadow: 0 12px 30px rgba(15, 23, 42, .055);
  transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease, background .16s ease;
}

.user-card:hover,
.participant-card:hover {
  transform: translateY(-2px);
  border-color: rgba(220, 38, 38, .22);
  box-shadow: 0 18px 44px rgba(15, 23, 42, .09);
}

/* Avatar */
.user-card-avatar,
.participant-avatar {
  width: 48px;
  height: 48px;
  overflow: hidden;
  border-radius: 18px;
  background: linear-gradient(135deg, #fee2e2, #ffffff);
  border: 1px solid rgba(15, 23, 42, .08);
  object-fit: cover;
}

.user-card-avatar img,
.participant-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Nick / rol */
.user-card-info,
.participant-info {
  min-width: 0;
}

.user-card-info strong,
.participant-info strong {
  display: block;
  overflow: hidden;
  color: #111827;
  font-size: 14px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-card-info span,
.participant-info span {
  display: block;
  margin-top: 4px;
  overflow: hidden;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Rol badge */
.user-role-badge,
.participant-role {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  margin-top: 5px;
  padding: 4px 8px;
  border-radius: 999px;
  background: #f8fafc;
  color: #475569;
  font-size: 11px;
  font-weight: 900;
  border: 1px solid rgba(15, 23, 42, .07);
}

.user-role-badge.is-admin,
.participant-role.is-admin,
.user-role-badge.is-root,
.participant-role.is-root {
  background: #fff1f2;
  color: #991b1b;
  border-color: rgba(220, 38, 38, .24);
}

/* Icon alanı */
.user-card-icons,
.participant-icons {
  display: flex;
  align-items: center;
  gap: 6px;
}

.user-card-icon,
.participant-icons button,
.participant-icons span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(15, 23, 42, .08);
  border-radius: 13px;
  background: #f8fafc;
  color: #334155;
  font-size: 15px;
  cursor: pointer;
  transition: background .16s ease, border-color .16s ease, transform .16s ease, color .16s ease;
}

.user-card-icon:hover,
.participant-icons button:hover {
  transform: translateY(-1px);
  background: #fff1f2;
  color: #991b1b;
  border-color: rgba(220, 38, 38, .24);
}

/* Aktif kamera / mikrofon */
.user-card-icon.is-active,
.participant-icons .is-active,
.user-card[data-camera="1"] .user-camera-icon,
.participant-card[data-camera="1"] .user-camera-icon,
.user-card[data-mic="1"] .user-mic-icon,
.participant-card[data-mic="1"] .user-mic-icon {
  background: #dcfce7;
  color: #166534;
  border-color: rgba(22, 163, 74, .26);
}

/* Kapalı / engelli durumlar */
.user-card-icon.is-muted,
.user-card-icon.is-blocked,
.participant-icons .is-muted,
.participant-icons .is-blocked,
.user-card[data-banned="1"],
.participant-card[data-banned="1"] {
  background: #fef2f2;
  color: #991b1b;
  border-color: rgba(220, 38, 38, .28);
}

.user-card[data-banned="1"],
.participant-card[data-banned="1"] {
  opacity: .78;
}

/* Online durumu */
.user-card::after,
.participant-card::after {
  content: "";
  position: absolute;
  left: 45px;
  bottom: 13px;
  width: 11px;
  height: 11px;
  border-radius: 999px;
  background: #22c55e;
  border: 2px solid #fff;
  box-shadow: 0 0 0 4px rgba(34, 197, 94, .14);
}

.user-card[data-online="0"]::after,
.participant-card[data-online="0"]::after {
  background: #94a3b8;
  box-shadow: none;
}

/* Sağ tık seçili/hover */
.user-card.is-context-open,
.participant-card.is-context-open {
  border-color: rgba(220, 38, 38, .42);
  box-shadow: 0 0 0 4px rgba(220, 38, 38, .09), 0 18px 44px rgba(15, 23, 42, .10);
}

/* Mobil */
@media (max-width: 720px) {
  .user-card,
  .participant-card {
    grid-template-columns: 44px minmax(0, 1fr) auto;
    min-height: 66px;
    padding: 10px;
    border-radius: 19px;
  }

  .user-card-avatar,
  .participant-avatar {
    width: 44px;
    height: 44px;
    border-radius: 16px;
  }

  .user-card-icon,
  .participant-icons button,
  .participant-icons span {
    width: 32px;
    height: 32px;
    border-radius: 12px;
  }
}.room-context-menu {
  position: fixed;
  z-index: 10000;
  min-width: 210px;
  padding: 8px;
  border-radius: 18px;
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, .10);
  box-shadow: 0 24px 70px rgba(15, 23, 42, .18);
}

.room-context-menu button {
  width: 100%;
  min-height: 40px;
  justify-content: flex-start;
  padding: 0 12px;
  border-radius: 12px;
  background: transparent;
  color: #334155;
  box-shadow: none;
  font-size: 13px;
  font-weight: 900;
}

.room-context-menu button:hover {
  transform: none;
  background: #fff1f2;
  color: #991b1b;
}