/* ===== スタートプレイヤー決定セクション ===== */
.start-player-section {
  height: 300vh;
  position: relative;
  background: var(--light);
  --section-title-top: clamp(7%, 9vh, 11%);
  --section-title-left: clamp(9%, 12vw, 16%);
  --section-title-max-width: clamp(18rem, 30vw, 26rem);
  --section-title-gap: 0.8rem;
}

.start-player-container {
  width: 100%;
  height: 100%;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0 1rem;
  gap: 8rem; /* PC画面で広い間隔 */
}

/* === スタートプレイヤーマーカー === */
.start-player-marker {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  opacity: 0;
  transform: scale(0);
  margin-top: 12rem; /* PC画面で適切な間隔 */
  z-index: 15;
}

.start-player-marker img {
  width: clamp(58px, 7vw, 80px);
  height: auto;
  display: block;
  border-radius: 0;
  filter: drop-shadow(0 12px 22px rgba(0, 0, 0, 0.18));
}

.marker-label {
  font-size: clamp(1.2rem, 3vw, 1.8rem);
  font-weight: 600;
  color: var(--ink);
  opacity: 0;
  transform: translateY(-10px);
  font-family: 'Noto Sans JP', sans-serif;
}

/* === プレイヤーコマ群 === */
.players-container {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2.5rem; /* PC画面で適切な間隔 */
  flex-wrap: wrap;
  max-width: 700px; /* PC画面で適切な幅 */
  margin-top: 4rem; /* PC画面で適切な間隔 */
}

.player-piece {
  width: 80px;
  height: 80px;
  opacity: 0;
  transform: scale(0);
}

.player-piece img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
  transition: transform 0.3s ease;
}

.player-piece img:hover {
  transform: scale(1.1);
}

/* === SVGアニメーションレイヤー === */
.start-player-svg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10;
  pointer-events: none;
}

.start-player-svg .line {
  stroke: var(--accent);
  stroke-width: 3;
  fill: none;
  stroke-linecap: butt;
}

.start-player-svg .label {
  fill: var(--ink);
  font-size: 18px;
  font-weight: 600;
  opacity: 0;
  text-anchor: middle;
  dominant-baseline: middle;
}

#marker-text {
  font-size: 1.5rem;
  font-weight: 600;
}

#start-player-center-text{
  position: fixed;
  top: 57%;
  left: 50%;
  transform: translate(-50%, -50%); /* 中央固定は親で保持 */
  z-index: 100;           /* マーカー(z=15)やSVG(z=10)より前 */
  pointer-events: none;   /* クリック無効化 */
  font-family: 'Noto Sans JP', sans-serif;
}

#start-player-center-text .center-text-content{
  opacity: 0;
  transform: scale(.8);   /* ここをアニメで1.0へ */
  text-align: center;
  color: var(--ink);
  font-weight: 600;
  font-size: clamp(1rem, 2.6vw, 1.4rem);
  line-height: 1.7;
}


#start-player-center-text .center-text-content {
  /* テキストの折り返し禁止 */
  white-space: nowrap;
}

#start-player-center-text p{ margin: 0 0 .5rem 0; }
#start-player-center-text p:last-child{ margin-bottom: 0; }


/* ===== レスポンシブ対応 ===== */

/* === タブレット（768px以下） === */
@media (max-width: 768px) {
  .start-player-section {
    --section-title-top: 8%;
    --section-title-left: 10%;
    --section-title-max-width: min(82vw, 24rem);
  }

  .start-player-container {
    gap: 4rem;
  }
  
  .start-player-marker {
    margin-top: 0.5rem;
  }

  .start-player-marker img {
    width: clamp(54px, 12vw, 72px);
    filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.18));
  }

  .players-container {
    gap: 1.5rem;
    max-width: 500px;
    margin-top: 2rem;
  }

  .player-piece {
    width: 60px;
    height: 60px;
  }

  .start-player-svg .line {
    stroke-width: 4;
  }

  .start-player-svg .label {
    font-size: 16px;
  }

  #marker-text {
    font-size: 2rem;
  }

  #start-player-center-text {
    top: 52%;
  }
}

/* === スマートフォン（480px以下） === */
@media (max-width: 480px) {
  .start-player-section {
    --section-title-top: 10%;
    --section-title-left: 8%;
    --section-title-max-width: min(88vw, 22rem);
  }

  .start-player-container {
    gap: 3rem;
  }
  
  .start-player-marker {
    margin-top: 1rem;
  }

  .start-player-marker img {
    width: clamp(50px, 24vw, 66px);
  }

  .players-container {
    gap: 1rem;
    margin-top: 1.5rem;
  }

  .player-piece {
    width: 50px;
    height: 50px;
  }

  .start-player-svg .line {
    stroke-width: 5;
  }

  .start-player-svg .label {
    font-size: 14px;
  }

  #marker-text {
    font-size: 2.8rem;
  }

  #start-player-center-text {
    top: 70%;
  }

  #start-player-center-text .center-text-content {
    font-size: 1rem;
    line-height: 1.5;
  }
}

/* === 極小スマートフォン（360px以下） === */
@media (max-width: 360px) {
  .start-player-section {
    --section-title-top: 9%;
    --section-title-left: 6%;
    --section-title-max-width: min(90vw, 20rem);
  }

  .start-player-container {
    gap: 2.5rem;
  }
  
  .start-player-marker {
    margin-top: -12rem;
  }

  .start-player-marker img {
    width: clamp(46px, 42vw, 58px);
  }

  .players-container {
    gap: 0.8rem;
    margin-top: 1rem;
  }

  .player-piece {
    width: 40px;
    height: 40px;
  }

  .start-player-svg .line {
    stroke-width: 6;
  }

  .start-player-svg .label {
    font-size: 12px;
  }

  #marker-text {
    font-size: 3rem;
  }

  #start-player-center-text {
    top: 58%;
  }

  #start-player-center-text .center-text-content {
    font-size: 0.9rem;
    line-height: 1.4;
  }
}
