.sidebar {
  width: 250px;
  min-width: 0;
  max-width: 250px;
  background-color: #2d3748;
  color: white;
  display: flex;
  flex-direction: column;
  border-right: 1px solid #1a202c;
  flex-shrink: 0;
  overflow: hidden;
}

.sidebarHeader {
  padding: 16px;
  background-color: #1a202c;
  font-weight: 600;
  font-size: 14px;
  border-bottom: 1px solid #4a5568;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.createRoomButton {
  width: 24px;
  height: 24px;
  border: none;
  background-color: #4299e1;
  color: white;
  border-radius: 4px;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s;
}

.createRoomButton:hover {
  background-color: #3182ce;
}

.roomList {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 8px 0;
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.createRoomInput {
  padding: 8px 12px;
  background-color: #1a202c;
  border-bottom: 1px solid #4a5568;
}

.createRoomInput input {
  width: 100%;
  padding: 8px;
  background-color: #2d3748;
  border: 1px solid #4a5568;
  border-radius: 4px;
  color: white;
  font-size: 14px;
  min-width: 50px;
  outline: none;
}

.createRoomInput input:focus {
  border-color: #4299e1;
}

.createRoomInput input::placeholder {
  color: #a0aec0;
}

.roomItem {
  padding: 12px 16px;
  cursor: pointer;
  transition: background-color 0.2s;
  border-left: 3px solid transparent;
  font-size: 15px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.roomItem:hover {
  background-color: #4a5568;
}

.roomItem.selected {
  background-color: #4a5568;
  border-left-color: #4299e1;
  font-weight: 600;
}

.unreadBadge {
  background-color: #f56565;
  color: white;
  border-radius: 10px;
  padding: 2px 8px;
  font-size: 12px;
  font-weight: 600;
  min-width: 20px;
  text-align: center;
}

.emptyRooms {
  padding: 16px;
  text-align: center;
  color: #a0aec0;
  font-size: 14px;
  font-style: italic;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
  .sidebar {
    width: 100%;
    max-width: 100%;
    min-width: 100%;
    max-height: 150px;
    border-right: none;
    border-bottom: 1px solid #1a202c;
    flex-shrink: 0;
    overflow: hidden;
  }

  .sidebarHeader {
    padding: 12px;
    font-size: 13px;
    flex-shrink: 0;
    width: 100%;
  }

  .roomList {
    padding: 4px 0;
    display: flex;
    flex-direction: row;
    overflow-x: auto;
    overflow-y: hidden;
    touch-action: pan-x;
    -webkit-overflow-scrolling: touch;
    width: 100%;
    flex: 1;
    min-height: 0;
  }

  .roomItem {
    padding: 8px 16px;
    white-space: nowrap;
    border-left: none;
    border-bottom: 3px solid transparent;
    font-size: 14px;
  }

  .roomItem.selected {
    border-left: none;
    border-bottom-color: #4299e1;
  }

  .createRoomButton {
    width: 22px;
    height: 22px;
    font-size: 16px;
  }
}

