/* css/components/premium_video.css */

.movie-summary-section {
    margin-top: 4rem;
    margin-bottom: 6rem;
}

.video-theater-container {
    width: 100%;
    max-width: 720px;
    margin: 12rem auto;
    background: #000;
    padding: 10px;
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.4);
    overflow: hidden;
    transition: all 0.5s ease;
    cursor: pointer;
}

.video-frame {
    position: relative;
    width: 100%;
    padding-top: 56.25%;
    border-radius: 20px;
    overflow: hidden;
}

.video-frame video {
    position: absolute;
    inset: 0; width: 100%; height: 100%;
    object-fit: cover;
}

.play-circle {
    width: 100px; height: 100px;
    background: transparent;
    border: 1px solid rgba(251, 191, 36, 0.4);
    border-radius: 50%;
    display: flex; justify-content: center; align-items: center;
    position: relative;
    transition: all 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.play-circle::before {
    content: "";
    position: absolute;
    inset: 10px;
    background: linear-gradient(135deg, #c5a059 0%, #fcf6ba 100%);
    border-radius: 50%;
    z-index: 1;
    box-shadow: 0 6px 15px rgba(0,0,0,0.12);
}

.play-circle i {
    color: #fff;
    font-size: 2rem;
    margin-left: 6px;
    z-index: 2;
}

.play-circle::after {
    content: ""; position: absolute; inset: -15px;
    border: 1px solid rgba(251, 191, 36, 0.15);
    border-radius: 50%;
    animation: master-pulse 5s infinite;
}

@keyframes master-pulse {
    0% { transform: scale(1); opacity: 0.3; }
    100% { transform: scale(1.5); opacity: 0; }
}

.video-theater-container:hover .play-circle {
    transform: scale(1.08);
    border-color: rgba(251, 191, 36, 0.7);
}

.video-overlay {
    position: absolute; inset: 0;
    background: rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(2px);
    display: flex; justify-content: center; align-items: center;
    transition: all 0.7s ease;
}

.video-theater-container:hover .video-overlay {
    background: rgba(0, 0, 0, 0.25);
    backdrop-filter: blur(0.5px);
}

.play-text {
    display: block;
    margin-top: 2rem;
    font-family: "Kaisei Opti", serif;
    font-size: 0.95rem;
    font-weight: 400;
    letter-spacing: 0.5em;
    color: #fff;
    text-shadow: 0 2px 8px rgba(0,0,0,0.3);
    text-align: center;
}

.video-title-label {
    color: #fff;
    padding: 1.2rem 1rem;
    font-family: "Kaisei Opti", serif;
    font-size: 1.1rem;
    letter-spacing: 0.1em;
}

/* Replay Overlay */
.video-replay-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s;
    z-index: 10;
}

.video-theater-container.is-finished .video-replay-overlay {
    opacity: 1;
    pointer-events: auto;
}

.replay-trigger {
    color: #fff;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    font-family: "Kaisei Opti", serif;
    letter-spacing: 0.2em;
}

.replay-trigger i {
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

/* Cinema Mode Support */
body.cinema-mode { overflow: hidden; }
.cinema-backdrop {
    position: fixed; inset: 0;
    background: rgba(0,0,0,0.95);
    backdrop-filter: blur(25px);
    z-index: 9998;
    opacity: 1;
    transition: opacity 0.4s;
}

.video-theater-container.cinema-active {
    position: fixed;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 96vw; max-width: 1300px;
    z-index: 10000;
    padding: 15px;
    margin: 0;
}

/* Hide play trigger when playing */
.video-theater-container.is-playing .video-overlay {
    opacity: 0;
    pointer-events: none;
}

/* --- Premium Custom Controls --- */
.video-controls-bar {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.4) 60%, transparent 100%);
    display: flex;
    flex-direction: column;
    padding: 0;
    z-index: 100;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
}

.video-theater-container.is-playing:hover .video-controls-bar,
.video-theater-container.cinema-active:hover .video-controls-bar,
.video-theater-container.is-playing:active .video-controls-bar {
    opacity: 1;
    transform: translateY(0);
}

/* Progress Area */
.video-progress-area {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    cursor: pointer;
    position: relative;
    transition: height 0.2s;
}

.video-progress-area:hover {
    height: 6px;
}

.video-progress-line {
    height: 100%;
    background: linear-gradient(90deg, #c5a059, #fcf6ba);
    width: 0%;
    position: relative;
    box-shadow: 0 0 10px rgba(251, 191, 36, 0.3);
}

.video-progress-line::after {
    content: "";
    position: absolute;
    right: -6px; top: 50%;
    transform: translateY(-50%) scale(0);
    width: 14px; height: 14px;
    background: #fff;
    border-radius: 50%;
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.8);
    transition: transform 0.2s;
}

.video-progress-area:hover .video-progress-line::after {
    transform: translateY(-50%) scale(1);
}

/* Controls Content */
.controls-row {
    display: flex;
    align-items: center;
    padding: 8px 15px 12px;
    gap: 12px;
}

.ctrl-btn {
    background: none; border: none;
    color: #fff;
    font-size: 1.1rem;
    cursor: pointer;
    opacity: 0.85;
    transition: all 0.2s;
    display: flex; align-items: center; justify-content: center;
    width: 36px; height: 36px;
}

.ctrl-btn:hover {
    opacity: 1;
    transform: scale(1.1);
    color: #fcf6ba;
}

.video-time {
    color: #fff;
    font-size: 0.85rem;
    font-family: 'Outfit', sans-serif;
    opacity: 0.9;
    letter-spacing: 0.05em;
}

.ctrl-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Volume Pop-up */
.volume-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.volume-slider-pop {
    position: absolute;
    bottom: 55px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: rgba(20, 20, 20, 0.9);
    backdrop-filter: blur(15px);
    padding: 20px 8px;
    border-radius: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    opacity: 0;
    visibility: hidden;
    transition: all 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.volume-wrap.active-slider .volume-slider-pop {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.volume-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 80px;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 5px;
    transform: rotate(-90deg);
    margin: 40px 0;
    cursor: pointer;
}

.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 14px; height: 14px;
    background: #fcf6ba;
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(251, 191, 36, 0.5);
    cursor: pointer;
}

/* Mobile Optimizations */
@media (max-width: 768px) {
    .video-controls-bar {
        opacity: 1; /* Always show on mobile when touched */
        transform: translateY(0);
        padding-bottom: 5px;
    }
    
    .controls-row {
        padding: 5px 10px 10px;
        gap: 8px;
    }
    
    .ctrl-btn {
        width: 44px; height: 44px;
        font-size: 1.3rem;
    }
    
    .video-time {
        font-size: 0.75rem;
    }
    
    .video-progress-area {
        height: 6px;
    }
    
    .volume-slider-pop {
        bottom: 60px;
        padding: 25px 12px;
    }
    
    .volume-slider {
        width: 100px;
        margin: 50px 0;
    }
}
