/* ==========================================================================
   BANDROOM (WEBRTC P2P JAMMING & COLLABORATIVE SYNC)
   ========================================================================== */

.modal-bandroom-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(10, 10, 15, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  box-sizing: border-box;
}

.modal-bandroom-card {
  background: var(--bg-surface-raised, #161722);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 20px;
  width: 100%;
  max-width: 760px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6), 0 0 30px rgba(56, 189, 248, 0.1);
  display: flex;
  flex-direction: column;
  color: var(--text-primary, #f0f0f5);
  animation: bandRoomPop 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes bandRoomPop {
  0% { transform: scale(0.96) translateY(12px); opacity: 0; }
  100% { transform: scale(1) translateY(0); opacity: 1; }
}

.bandroom-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 24px 28px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.bandroom-badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.14);
  border: 1px solid rgba(56, 189, 248, 0.3);
  padding: 3px 10px;
  border-radius: 999px;
  margin-bottom: 8px;
}

.bandroom-title {
  margin: 0 0 4px;
  font-size: 1.4rem;
  font-weight: 700;
}

.bandroom-subtitle {
  margin: 0;
  font-size: 0.88rem;
  color: var(--text-secondary, #94a3b8);
}

.btn-close-bandroom {
  background: rgba(255, 255, 255, 0.06);
  border: none;
  color: var(--text-secondary, #94a3b8);
  font-size: 1.1rem;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.btn-close-bandroom:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.bandroom-body {
  padding: 24px 28px;
}

.bandroom-setup-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

@media (max-width: 600px) {
  .bandroom-setup-grid {
    grid-template-columns: 1fr;
  }
}

.setup-box {
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
}

.setup-box h3 {
  margin: 0;
  font-size: 1.05rem;
  color: #f8fafc;
}

.setup-box p {
  margin: 0;
  font-size: 0.82rem;
  color: var(--text-secondary, #94a3b8);
  line-height: 1.4;
}

.join-input-row {
  display: flex;
  gap: 8px;
}

.room-code-input {
  flex: 1;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 10px;
  padding: 8px 12px;
  color: #fff;
  font-family: monospace;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.btn-bandroom-action {
  padding: 10px 18px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-bandroom-action.primary {
  background: #38bdf8;
  color: #000;
  border: none;
}

.btn-bandroom-action.secondary {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.btn-bandroom-action.danger {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

/* Active Room Status */
.active-room-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.2);
  border-radius: 14px;
  padding: 14px 18px;
  margin-bottom: 20px;
}

.code-lbl {
  font-size: 0.72rem;
  font-weight: 800;
  color: var(--text-secondary, #94a3b8);
  margin-right: 6px;
}

.code-val {
  font-family: monospace;
  font-size: 1.2rem;
  color: #38bdf8;
}

.peers-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.peer-avatar-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.avatar-circle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  color: #fff;
  font-weight: 800;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.4);
}

.peer-meta strong {
  display: block;
  font-size: 0.85rem;
  color: #fff;
}

.peer-meta span {
  display: block;
  font-size: 0.72rem;
  color: var(--text-secondary, #94a3b8);
}
