/* 页面基本样式 */
body {
  font-family: "Arial", sans-serif;
  margin: 0;
  padding: 0;
  background: linear-gradient(135deg, #ff9800, #0083b0); /* 渐变背景 */
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100vh;
  text-align: center;
  /* overflow: hidden; */
}

h1 {
  font-size: 2.5rem;
  margin-bottom: 20px;
}

h2,
h3 {
  font-size: 1.5rem;
  margin-top: 20px;
}

/* 容器样式 */
#userInfo,
#roomList,
#peerIds,
#videoContainer {
  width: 92%;
  margin-left: auto;
  margin-right: auto;
  text-align: left;
}

/* 按钮样式 */
button {
  background-color: #0083b0;
  color: white;
  border: none;
  padding: 10px 20px;
  margin: 10px 0;
  border-radius: 5px;
  font-size: 1.1rem;
  cursor: pointer;
  transition: background-color 0.3s ease;
  margin-right: 16px;
}

button:hover {
  background-color: #F44336;
}

button:disabled {
  background-color: #bbb;
  cursor: not-allowed;
}

/* 输入框样式 */
input {
  padding: 10px;
  font-size: 1rem;
  width: 52%;
  border-radius: 5px;
  border: 1px solid #ccc;
}

/* 视频样式 */
video {
  width: 100%;
  max-width: 456px;
  max-height: 456px;
  margin: 10px;
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}
.tit {
}
#userInfo {
  width: 100%;
}
#userInfo > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 800px;
}
.room {
  display: flex;

  align-items: center;

  justify-content: space-between;
}
#videoContainer{
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
}
/* 小屏幕适应 */
@media (max-width: 768px) {
  body {
    padding: 20px;
    height: auto;
  }
  #userInfo > div {
    width: auto;
    flex-wrap: wrap;
  }
  .room {
    flex-wrap: wrap;
  }

  #videoContainer {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
  }

  video {
    width: 100%;
    max-width: 300px;
  }

  #userInfo {
    width: 100%;
    text-align: center;
  }

  #roomList {
    width: 100%;
  }

  button {
    width: 100%;
  }

  input {
    width: 100%;
  }
  .btnBox{
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}
  .btnBox button{
    margin: 0 auto;
    margin-top: 16px;
}
  #roomList{
    
display: grid;
    
grid-template-columns: 1fr 1fr;
    
gap: 10px;
  }
}

/* 手机端优化 */
@media (max-width: 480px) {
  h1 {
    font-size: 2rem;
  }
  h2,
  h3 {
    font-size: 1.2rem;
  }
}

//屏幕宽度大于1200px 小于1600px
@media (min-width: 1200px) and (max-width: 1600px) {
  body {
    background: red;
  }
}
