/* Chess Home — persistent voice channels rail + admin modal.
 * Layered AFTER voice.css so we inherit the wood-cut / cream palette.
 * All rules are namespaced under `.vc-*` / `.voice-channels-*` so
 * nothing else in the app can accidentally collide.
 */

.voice-channels-card { margin-bottom: 12px; }

.vc-list {
  list-style: none;
  margin: 6px -8px 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.vc-row {
  position: relative;
  padding: 8px 10px 10px;
  border-radius: 6px;
  border-bottom: 1px dashed rgba(58, 43, 24, 0.18); /* wood underline */
  transition: background 120ms ease;
}
.vc-row:hover  { background: rgba(255, 249, 232, 0.55); }
.vc-row:last-child { border-bottom: none; }

.vc-row-head {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: "Fraunces", Georgia, serif;
  font-weight: 600;
  font-size: 14px;
  color: #3a2b18;
}
.vc-icon      { font-size: 15px; line-height: 1; opacity: 0.9; }
.vc-name      { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.vc-count-chip {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  background: #e6f0e2;
  color: #2f6b3a;
  border: 1px solid #b7d4b0;
  letter-spacing: 0.02em;
}
.vc-count-chip.empty {
  background: #f2ede1;
  color: #7d6b52;
  border-color: #d9cfb8;
}

.vc-row-body {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 6px;
}

.vc-avatar-stack {
  display: flex;
  align-items: center;
  min-height: 22px;
}
.vc-mini-avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1.5px solid #fff8e7;
  box-shadow: 0 0 0 1px rgba(58, 43, 24, 0.35);
  margin-left: -6px;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-transform: uppercase;
}
.vc-mini-avatar:first-child { margin-left: 0; }

.vc-row-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.vc-join-btn,
.vc-leave-btn {
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 700;
}
.vc-leave-btn {
  background: #f7efdd;
  color: #3a2b18;
  border: 1px solid #a6825b;
}

.vc-row.in-channel { background: #fff9e8; }
.vc-row.in-channel .vc-name::after {
  content: " · you";
  font-weight: 500;
  color: #7d6b52;
  font-size: 11px;
}

/* Speaking indicator — reuses the dot pattern from voice_chat.js. */
.vc-mini-avatar.speaking {
  box-shadow: 0 0 0 2px #5e9c6c, 0 0 6px 2px rgba(94, 156, 108, 0.55);
}

.vc-admin-inline {
  color: #7d6b52;
  font-size: 13px;
  padding: 2px 4px;
}
.vc-admin-inline:hover { color: #3a2b18; }

/* ---------- Admin modal ---------- */
.vc-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(28, 20, 8, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1200;
}
.vc-modal-backdrop[hidden] { display: none; }

.vc-modal {
  background: #fff8e7;
  border: 1.5px solid #3a2b18;
  border-radius: 10px;
  box-shadow: 4px 4px 0 #3a2b18;
  width: min(420px, 92vw);
  padding: 0;
  color: #3a2b18;
  overflow: hidden;
}
.vc-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px 8px;
  border-bottom: 1px dashed rgba(58, 43, 24, 0.35);
}
.vc-modal-title {
  margin: 0;
  font-family: "Fraunces", Georgia, serif;
  font-size: 17px;
  font-weight: 600;
}
.vc-modal-body { padding: 12px 16px 16px; }
.vc-modal-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}
.vc-error { color: #a3241f; font-weight: 600; }

/* ---------- Event live-join banner ---------- */
.event-live-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  margin-bottom: 10px;
  background: linear-gradient(90deg, #fff9e8 0%, #e6f0e2 100%);
  border: 1.5px solid #2f6b3a;
  border-radius: 10px;
  box-shadow: 3px 3px 0 #3a2b18;
  font-family: "Fraunces", Georgia, serif;
}
.event-live-banner-body { flex: 1; min-width: 0; }
.event-live-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #d93f2f;
  margin-right: 8px;
  vertical-align: middle;
  animation: vc-pulse 1.5s ease-in-out infinite;
  box-shadow: 0 0 0 3px rgba(217, 63, 47, 0.25);
}
@keyframes vc-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(217, 63, 47, 0.6); }
  70%  { box-shadow: 0 0 0 8px rgba(217, 63, 47, 0);   }
  100% { box-shadow: 0 0 0 0 rgba(217, 63, 47, 0);     }
}
.event-live-pending { opacity: 0.85; }
