.tab-container {
  width: 760px;
  margin: 0 auto;
  font-family: sans-serif;
}

/* ラジオボタンを非表示 */
.tab-container input[type="radio"] {
  display: none;
}

/* タブラベル表示 */
.tab-labels {
  display: flex;
  border-bottom: 2px solid #ccc;
  overflow-x: auto;
}

.tab-labels label {
  flex: 1;
  min-width: 120px;
  padding: 10px;
  text-align: center;
  background: #ddd;
  color: #666;
  border: 1px solid #bbb;
  border-bottom: none;
  cursor: pointer;
  transition: 0.3s;
}

/* チェックされたラベルのスタイル */
#tab1:checked ~ .tab-labels label[for="tab1"],
#tab2:checked ~ .tab-labels label[for="tab2"],
#tab3:checked ~ .tab-labels label[for="tab3"],
#tab4:checked ~ .tab-labels label[for="tab4"],
#tab5:checked ~ .tab-labels label[for="tab5"] {
  background: #fff;
  color: #000;
  font-weight: bold;
  border: 2px solid #000;
  border-bottom: none;
  position: relative;
  top: 1px;
  z-index: 2;
}

/* タブ内容エリア */
.tab-contents {
  border: 1px solid #ccc;
  background: #fff;
  padding: 10px;
}

/* 各タブ内容（初期は非表示） */
.tab-content {
  display: none;
}

/* チェックされたタブの内容を表示 */
#tab1:checked ~ .tab-contents #content1,
#tab2:checked ~ .tab-contents #content2,
#tab3:checked ~ .tab-contents #content3,
#tab4:checked ~ .tab-contents #content4,
#tab5:checked ~ .tab-contents #content5 {
  display: block;
}

/* 商品のレイアウト */
.products {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
}

.product {
  flex: 1 1 140px;
  border: 1px solid #aaa;
  padding: 10px;
  text-align: center;
  box-sizing: border-box;
}