/* =============================
   ポップアップ全体
============================= */
#multi-select-popup {
  position: fixed !important;          /* ← 親の影響を受けないように */
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) !important;
  width: 90vw;
  max-width: 600px;
  max-height: 90vh;
  background: #fff;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  padding: 16px;
  overflow-y: auto;
  z-index: 99999;                      /* ← かなり手前に出す */
  box-shadow: 0 6px 20px rgba(0,0,0,0.25);
}



/* =============================
   ポップアップの中身
============================= */
#multi-select-popup .popup-content {
  background: #fff;
  width: 90%;
  max-width: 600px;
  margin: 50px auto;
  padding: 1rem;
  border-radius: 8px;
  max-height: 80vh;    /* ← ウィンドウより高くならない */
  overflow-y: auto;    /* ← コンテンツが多いとき中だけスクロール */
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

/* ポップアップ内のカテゴリボックス */
.popup-tab-content {
  max-height: 350px; /* ← 適当な高さに制限 */
  overflow-y: auto;  /* ← 中身が長ければスクロールバーが出る */
  padding-right: 8px; /* ← スクロールバーの分だけ余白 */
}

/* =============================
   ポップアップのボタンエリア
============================= */
#multi-select-popup .popup-buttons {
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
  margin-top: 1rem;
}

#multi-select-popup button {
  padding: 8px 16px;
  border: none;
  border-radius: 6px;
  font-weight: bold;
  cursor: pointer;
}

#multi-select-ok {
  background: #3b82f6;
  color: #fff;
}

#multi-select-cancel {
  background: #e5e7eb;
  color: #111;
}

/* =============================
   選択中のカテゴリ表示（赤文字）
============================= */
#multi-select-popup .selected-category {
  color: #ef4444; /* 赤文字 */
  font-weight: bold;
}

/* =============================
   bodyのスクロール制御
============================= */
body.popup-open {
  overflow: hidden; /* ポップアップ中は背景スクロール禁止 */
}

/* ===== ルーレット部分 ===== */
.roulette-container {
  width: 100%;
  height: 150px; /* 全体高さ（調整OK） */
  overflow: hidden;
  position: relative;
  border: 2px solid #e5e7eb;
  border-radius: 10px;
  background: #fff;
  margin-bottom: 1rem;
  display: flex;
  //align-items: center; /* ←中身を縦中央に配置 */
}
.roulette-track {
  display: flex;
}
.roulette-item {
  display: flex;
  flex-direction: column; /* 上:画像 / 下:テキスト */
  align-items: center;
  margin: 0 5px;
}
.roulette-item-img {
  width: 150px;
  height: 120px;          /* ←高さ自由に変更できる */
  background-size: cover;
  background-position: center;
  border-radius: 8px;
}
/* テキスト部分 */
.roulette-item-label {
  flex: 0 0 auto;
  height: 30px; /* ← ここでテキスト領域の高さを調整 */
  background: rgba(0,0,0,0.7);
  color: #fff;
  font-size: 0.9rem;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.center-marker{
  position: absolute;
  top: 0;
  left: 50%;
  width: 2px;
  height: 100%;
  background: red;
}

.roulette-item:nth-child(odd) .roulette-item-img {
  background-color: #fff; /* 奇数：白 */
}

.roulette-item:nth-child(even) .roulette-item-img {
  background-color: #000; /* 偶数：黒 */
}