/* =========================================
   オープニングスライドショー（重なり優先＋背後透過）
   ========================================= */

#opening-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000000;
    z-index: 10000;
    transition: opacity 0.8s ease, visibility 0.8s ease;
    overflow: hidden;
}

#opening-overlay.fade-out {
    opacity: 0;
    visibility: hidden;
}

/* スライドスタックコンテナ */
.slideshow-stack {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 70%;
    max-width: 500px;
    height: auto;
    transform: translate(-50%, -50%);
}

/* 各スライド（重ねる＋傾き＋背後透過） */
.slide-stack {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    transition: all 0.6s ease;
    filter: drop-shadow(0 10px 25px rgba(0, 0, 0, 0.5));
}

/* 非アクティブなスライド（背後に重なる） */
.slide-stack:not(.active) {
    opacity: 0.4;
    transform: translate(0, 0) scale(0.92) rotate(var(--rotate, 0deg));
    filter: blur(2px);
    pointer-events: none;
    transition: all 0.6s ease;
}

/* アクティブなスライド（最前面） */
.slide-stack.active {
    opacity: 1;
    transform: translate(0, 0) scale(1) rotate(var(--rotate, 0deg));
    z-index: 10;
    filter: blur(0);
}

/* 画像自体 */
.slide-stack-img {
    width: 100%;
    height: auto;
    border-radius: 16px;
    border: 2px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    background: #1a1a1a;
    display: block;
}

/* テキストコンテンツ */
.slide-content {
    position: absolute;
    bottom: 20%;
    left: 0;
    right: 0;
    text-align: center;
    color: white;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    z-index: 20;
}

.slide-content h1 {
    font-size: 2rem;
    margin: 0 0 10px;
    letter-spacing: 4px;
    font-weight: 800;
}

.slide-content p {
    font-size: 0.9rem;
    opacity: 0.9;
    margin: 0;
}

/* プログレスバー（非表示） */
.progress-bar-container {
    display: none;
}

/* インジケータードット（非表示） */
.slide-indicators {
    display: none;
}

/* スキップボタン */
.skip-opening {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 8px 20px;
    border-radius: 30px;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: bold;
    transition: all 0.3s ease;
    z-index: 30;
}

.skip-opening:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* レスポンシブ */
@media (max-width: 768px) {
    .slideshow-stack {
        width: 85%;
    }
    
    .slide-content {
        bottom: 15%;
    }
    
    .slide-content h1 {
        font-size: 1.4rem;
    }
    
    .slide-content p {
        font-size: 0.75rem;
    }
    
    .skip-opening {
        bottom: 15px;
        right: 15px;
        padding: 6px 16px;
        font-size: 0.7rem;
    }
}

/* =========================================
   オープニング再生ボタン用スタイル
   ========================================= */

/* 再生ボタンコンテナ */
#opening-play-container {
    position: fixed;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    text-align: center;
    animation: fadeInUp 0.6s ease;
}

/* 再生ボタン */
#opening-play-btn {
    padding: 16px 40px;
    font-size: 1.2rem;
    font-weight: bold;
    background: linear-gradient(135deg, #e67e22, #f39c12);
    color: white;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(230, 126, 34, 0.4);
    transition: all 0.3s ease;
    font-family: inherit;
    letter-spacing: 1px;
}

#opening-play-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 30px rgba(230, 126, 34, 0.6);
}

#opening-play-btn:active {
    transform: scale(0.95);
}

/* レスポンシブ */
@media (max-width: 768px) {
    #opening-play-container {
        bottom: 60px;
    }
    
    #opening-play-btn {
        padding: 14px 28px;
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    #opening-play-btn {
        padding: 12px 20px;
        font-size: 0.85rem;
    }
}