/* ============================================================
   ヒーロースライダー専用スタイル
   ============================================================ */

/* ---- Slider Container ---- */
.hero-slider {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.hero-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0;
  transition: opacity 1.2s ease;
  will-change: opacity;
}

.hero-slide.active {
  opacity: 1;
}

/* 各スライド画像 */
.hero-slide:nth-child(1) { background-image: url('../images/hero_bg.jpg'); background-position: center 30%; }
.hero-slide:nth-child(2) { background-image: url('../images/hero_slide2.jpg'); background-position: center 20%; }
.hero-slide:nth-child(3) { background-image: url('../images/hero_slide3.jpg'); background-position: center 25%; }
.hero-slide:nth-child(4) { background-image: url('../images/hero_slide4.jpg'); background-position: center center; }

/* ---- Slider Overlay ---- */
.hero-slide::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    rgba(20, 5, 45, 0.82) 0%,
    rgba(20, 5, 45, 0.55) 55%,
    rgba(0, 0, 0, 0.15) 100%
  );
}

/* ---- Slider Dots ---- */
.slider-dots {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
  z-index: 10;
}

.slider-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  padding: 0;
}

.slider-dot.active {
  background: var(--color-accent-gold);
  width: 28px;
  border-radius: 4px;
}

/* ---- Slider Arrows ---- */
.slider-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: white;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1rem;
}

.slider-arrow:hover {
  background: rgba(91, 45, 142, 0.7);
  border-color: var(--color-primary-light);
}

.slider-arrow--prev { left: 24px; }
.slider-arrow--next { right: 24px; }

/* ---- Slide Counter ---- */
.slider-counter {
  position: absolute;
  bottom: 24px;
  right: 32px;
  z-index: 10;
  font-family: var(--font-en);
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 0.1em;
}

.slider-counter .current {
  font-size: 1.4rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.9);
}

/* ---- Slide Caption (スライドごとのサブテキスト) ---- */
.slide-caption {
  display: none; /* デスクトップでは非表示 */
}

.hero-slide.active .slide-caption {
  opacity: 1;
  transform: translateY(0);
}

.slide-caption__tag {
  display: inline-block;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 50px;
  padding: 5px 18px;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.85);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-family: var(--font-en);
}

/* ---- Progress Bar ---- */
.slider-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  background: var(--color-primary);
  z-index: 10;
  width: 0%;
  transition: none;
}

.slider-progress.animating {
  transition: width 5s linear;
  width: 100%;
}

/* Responsive */
@media (max-width: 768px) {
  .slider-arrow { display: none; }
  .slider-counter { display: none; }
  .slider-dots { bottom: 56px; }

  /* スマホ用縦型画像に切り替え */
  .hero-slide:nth-child(1) {
    background-image: url('../images/hero_bg_sp.jpg');
    background-position: center top;
  }
  .hero-slide:nth-child(2) {
    background-image: url('../images/hero_slide2_sp.jpg');
    background-position: center top;
  }
  .hero-slide:nth-child(3) {
    background-image: url('../images/hero_slide3_sp.jpg');
    background-position: center top;
  }
  .hero-slide:nth-child(4) {
    background-image: url('../images/hero_slide4_sp.jpg');
    background-position: center center;
  }

  /* スマホ用オーバーレイを少し明るく */
  .hero-slide::after {
    background: linear-gradient(
      180deg,
      rgba(20, 5, 45, 0.55) 0%,
      rgba(20, 5, 45, 0.75) 60%,
      rgba(20, 5, 45, 0.90) 100%
    );
  }
}
