/**
 * Game Showcase Styles
 * Game logo, subtitle, screenshot carousel
 */

/* Game Showcase Panel */
#game-showcase {
    position: fixed;
    left: 80px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 150;
    max-width: 750px;
    perspective: 1000px;
}

.showcase-content {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    transform-style: preserve-3d;
    transition: transform 0.15s ease-out;
    will-change: transform;
    backface-visibility: hidden;
    padding-top: 240px;
}

.game-logo {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    max-width: 500px;
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 12px 24px rgba(0, 0, 0, 0.6)) drop-shadow(0 6px 12px rgba(0, 0, 0, 0.4));
    transition: filter 0.3s ease;
}

    .game-logo:hover {
        filter: drop-shadow(0 16px 32px rgba(0, 0, 0, 0.8)) drop-shadow(0 8px 16px rgba(0, 0, 0, 0.6));
    }

.game-subtitle {
    max-width: 600px;
    font-size: 16px;
    color: white;
    margin: 0;
    font-weight: 400;
    letter-spacing: 0.5px;
    text-align: center;
    line-height: 1.6;
    text-shadow: 5px 5px 10px rgba(0, 0, 0, 0.7), 5px 5px 10px rgba(0, 0, 0, 1);
    padding: 20px 40px;
    border-radius: 12px;
    backdrop-filter: blur(1px);
    -webkit-backdrop-filter: blur(1px);
}

/* Screenshot Carousel - 4-Panel System (3 visible + 1 hidden) */
.screenshot-carousel {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 30px;
    width: 100%;
    max-width: 900px;
    perspective: 1800px;
    position: relative;
    height: 200px;
    overflow: visible;
}

.screenshot-track {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    transform-style: preserve-3d;
    --transition-speed: 0.7s; /* Default speed, can be overridden for fast mode */
}

.screenshot-item {
    position: absolute;
    border-radius: 16px;
    overflow: hidden;
    cursor: default;
    transition: transform var(--transition-speed, 0.7s) cubic-bezier(0.25, 0.46, 0.45, 0.94),
                opacity var(--transition-speed, 0.7s) cubic-bezier(0.25, 0.46, 0.45, 0.94),
                z-index 0s calc(var(--transition-speed, 0.7s) * 0.5);
    will-change: transform, opacity;
    backface-visibility: hidden;
    pointer-events: none;
}

/* Fast transition mode (5X faster for indicator navigation) */
.screenshot-track.fast-transition .screenshot-item {
    transition: transform 0.14s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                opacity 0.14s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                z-index 0s 0.07s;
}

/* Hidden left panel - completely off-screen */
.screenshot-hidden-left {
    width: 360px;
    height: 202.5px;
    opacity: 0;
    transform: translateX(0px) translateZ(-150px) scale(0.5);
    z-index: 1;
    pointer-events: none;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.6);
    transition: transform var(--transition-speed, 0.7s) cubic-bezier(0.25, 0.46, 0.45, 0.94),
                opacity var(--transition-speed, 0.7s) cubic-bezier(0.25, 0.46, 0.45, 0.94),
                z-index 0s calc(var(--transition-speed, 0.7s) * 0.5);
}

/* Fast mode for hidden panel */
.screenshot-track.fast-transition .screenshot-hidden-left {
    transition: transform 0.14s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                opacity 0.14s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                z-index 0s 0.07s;
}

/* Left side - 50% visible behind center */
.screenshot-side-left {
    width: 360px;
    height: 202.5px;
    opacity: 0.5;
    transform: translateX(-160px) translateZ(-120px) scale(0.79);
    z-index: 5;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.6);
    pointer-events: none;
    transition: transform var(--transition-speed, 0.7s) cubic-bezier(0.25, 0.46, 0.45, 0.94),
                opacity var(--transition-speed, 0.7s) cubic-bezier(0.25, 0.46, 0.45, 0.94),
                box-shadow 0.3s ease,
                z-index 0s calc(var(--transition-speed, 0.7s) * 0.5);
}

    .screenshot-side-left:hover {
        opacity: 0.75;
    }

/* Fast mode for left panel */
.screenshot-track.fast-transition .screenshot-side-left {
    transition: transform 0.14s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                opacity 0.14s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                box-shadow 0.3s ease,
                z-index 0s 0.07s;
}

/* Center - largest, fully visible, NO transform on hover to prevent jerkiness */
.screenshot-center {
    width: 360px;
    height: 202.5px;
    opacity: 1;
    transform: translateX(0) translateZ(0) scale(1);
    z-index: 10;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
    transition: transform var(--transition-speed, 0.7s) cubic-bezier(0.25, 0.46, 0.45, 0.94),
                opacity var(--transition-speed, 0.7s) cubic-bezier(0.25, 0.46, 0.45, 0.94),
                box-shadow 0.3s ease,
                z-index 0s calc(var(--transition-speed, 0.7s) * 0.5);
    pointer-events: auto;
    cursor: pointer;
}

    .screenshot-center:hover {
        box-shadow: 0 24px 70px rgba(0, 0, 0, 0.9);
    }

/* Fast mode for center panel */
.screenshot-track.fast-transition .screenshot-center {
    transition: transform 0.14s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                opacity 0.14s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                box-shadow 0.3s ease,
                z-index 0s 0.07s;
}

/* Navigation buttons - Fixed empty boxes on sides of center panel */
.carousel-nav-button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    height: 100%;
    z-index: 20;
    cursor: pointer;
    background: transparent;
    border: none;
    padding: 0;
    transition: background 0.3s ease;
    pointer-events: auto;
    outline: none;
}

.carousel-nav-left {
    left: 0;
    width: 120px;
}

.carousel-nav-center {
    left: 50%;
    transform: translate(-50%, -50%);
    width: 360px;
}

.carousel-nav-right {
    right: 0;
    width: 120px;
}

.carousel-nav-button:hover {
    background: rgba(224, 192, 128, 0.05);
}

.carousel-nav-button:active {
    background: rgba(224, 192, 128, 0.1);
}



/* Right side - 50% visible behind center */
.screenshot-side-right {
    width: 360px;
    height: 202.5px;
    opacity: 0.5;
    transform: translateX(160px) translateZ(-120px) scale(0.79);
    z-index: 5;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.6);
    pointer-events: auto;
    cursor: pointer;
    transition: transform var(--transition-speed, 0.7s) cubic-bezier(0.25, 0.46, 0.45, 0.94),
                opacity 0.3s ease,
                box-shadow 0.3s ease,
                z-index 0s;
}

    .screenshot-side-right:hover {
        opacity: 0.75;
        z-index: 15;
    }

/* Fast mode for right panel */
.screenshot-track.fast-transition .screenshot-side-right {
    transition: transform 0.14s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                opacity 0.14s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                box-shadow 0.3s ease,
                z-index 0s 0.07s;
}

/* All thumbnails are non-interactive - navigation buttons handle all clicks */
.screenshot-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border: 3px solid rgba(224, 192, 128, 0.3);
    border-radius: 16px;
    transition: border-color 0.3s ease;
    pointer-events: none;
    cursor: default;
}

/* Disable all interactions during animation */
.screenshot-track.animating .screenshot-item {
    pointer-events: none;
}

/* Carousel Indicators */
.carousel-indicators {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin-top: 12px;
}

.carousel-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(224, 192, 128, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

    .carousel-indicator:hover {
        background: rgba(224, 192, 128, 0.5);
    }

    .carousel-indicator.active {
        background: #e0c080;
        width: 24px;
        border-radius: 4px;
        box-shadow: 0 2px 8px rgba(224, 192, 128, 0.4);
    }

/* Watch Trailer Button */
.watch-trailer-btn {
    margin-top: 24px;
    padding: 14px 40px;
    background: linear-gradient(135deg, rgba(224, 192, 128, 0.2) 0%, rgba(224, 192, 128, 0.1) 100%);
    border: 2px solid rgba(224, 192, 128, 0.4);
    border-radius: 50px;
    color: #e0c080;
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 1px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    text-transform: uppercase;
}

.watch-trailer-btn .play-icon {
    width: 24px;
    height: 24px;
    color: #e0c080;
    transition: transform 0.3s ease;
}

.watch-trailer-btn:hover {
    background: linear-gradient(135deg, rgba(224, 192, 128, 0.3) 0%, rgba(224, 192, 128, 0.2) 100%);
    border-color: #e0c080;
    box-shadow: 0 6px 25px rgba(224, 192, 128, 0.3);
    transform: translateY(-2px);
}

.watch-trailer-btn:hover .play-icon {
    transform: scale(1.1);
}

.watch-trailer-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 10px rgba(224, 192, 128, 0.2);
}
/* Full Screen Modal */
.screenshot-fullscreen {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

    .screenshot-fullscreen.active {
        opacity: 1;
    }

.fullscreen-image {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
    transition: opacity 0.3s ease;
}

.fullscreen-close {
    position: absolute;
    top: 30px;
    right: 30px;
    width: 56px;
    height: 56px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 2px solid rgba(224, 192, 128, 0.4);
    border-radius: 50%;
    color: #e0c080;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 2001;
}

    .fullscreen-close:hover {
        background: rgba(224, 192, 128, 0.2);
        border-color: #e0c080;
        transform: scale(1.1) rotate(90deg);
    }

.fullscreen-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 64px;
    height: 64px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 2px solid rgba(224, 192, 128, 0.4);
    border-radius: 50%;
    color: #e0c080;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 2001;
}

.fullscreen-arrow-left {
    left: 40px;
}

.fullscreen-arrow-right {
    right: 40px;
}

.fullscreen-arrow:hover {
    background: rgba(224, 192, 128, 0.2);
    border-color: #e0c080;
    transform: translateY(-50%) scale(1.1);
}

.fullscreen-arrow:active {
    transform: translateY(-50%) scale(0.95);
}

.fullscreen-counter {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 10px 24px;
    border-radius: 20px;
    border: 2px solid rgba(224, 192, 128, 0.3);
    color: #e0c080;
    font-size: 1rem;
    font-weight: 500;
    letter-spacing: 0.5px;
    z-index: 2001;
}

/* Steam Widget */
#steam-widget {
    position: fixed;
    right: 20px;
    bottom: 80px;
    z-index: 150;
    background: rgba(0, 0, 0, 0);
    border-radius: 8px;
    padding: 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

    #steam-widget iframe {
        border-radius: 4px;
        display: block;
    }

/* Video Player Modal */
.video-player-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 2500;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    padding: 75px;
}

.video-player-modal.active {
    opacity: 1;
}

.video-player-modal.fullscreen-active {
    padding: 0;
}

/* Hide UI elements when video is open */
.video-player-modal.active ~ #header,
.video-player-modal.active ~ #game-showcase,
.video-player-modal.active ~ #footer {
    opacity: 0;
    pointer-events: none;
}

.video-close {
    position: absolute;
    top: 100px;
    right: 100px;
    width: 56px;
    height: 56px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 2px solid rgba(224, 192, 128, 0.4);
    border-radius: 50%;
    color: #e0c080;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 2502;
    opacity: 1;
}

.video-player-modal.fullscreen-active .video-close {
    top: 30px;
    right: 30px;
}

.video-player-modal.controls-hidden .video-close {
    opacity: 0;
    pointer-events: none;
}

.video-close:hover {
    background: rgba(224, 192, 128, 0.2);
    border-color: #e0c080;
    transform: scale(1.1) rotate(90deg);
}

.video-container {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    background: #000;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
}

.video-player-modal.fullscreen-active .video-container {
    border-radius: 0;
}

.trailer-video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    background: #000;
}

/* Custom Video Controls - Overlay Style */
.video-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 16px;
    padding: 20px 24px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.7) 70%, transparent 100%);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 2501;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.video-player-modal.controls-hidden .video-controls {
    opacity: 0;
    pointer-events: none;
}

/* Center Play/Pause Button - Large overlay in center of video */
.video-center-play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 3px solid rgba(224, 192, 128, 0.5);
    border-radius: 50%;
    color: #e0c080;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 2501;
    opacity: 1;
}

.video-player-modal.controls-hidden .video-center-play {
    opacity: 0;
    pointer-events: none;
}

.video-center-play:hover {
    background: rgba(224, 192, 128, 0.3);
    border-color: #e0c080;
    transform: translate(-50%, -50%) scale(1.1);
}

.video-center-play:active {
    transform: translate(-50%, -50%) scale(0.95);
}

.video-center-play svg {
    width: 36px;
    height: 36px;
}

/* Center button only hides when video is playing AND controls are hidden */
.video-player-modal.controls-hidden .video-center-play {
    opacity: 0;
    pointer-events: none;
}

/* Control buttons in footer - smaller, only in control bar */
.video-mute,
.video-fullscreen {
    background: transparent;
    border: none;
    color: #e0c080;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
    border-radius: 50%;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.video-mute:hover,
.video-fullscreen:hover {
    background: rgba(224, 192, 128, 0.2);
    transform: scale(1.1);
}

.video-mute:active,
.video-fullscreen:active {
    transform: scale(0.95);
}

.video-progress-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.video-progress-bar {
    width: 100%;
    height: 6px;
    background: rgba(224, 192, 128, 0.2);
    border-radius: 3px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.video-progress-bar:hover {
    height: 8px;
}

.video-progress-filled {
    height: 100%;
    background: linear-gradient(90deg, #e0c080 0%, #c9a868 100%);
    border-radius: 3px;
    width: 0%;
    transition: width 0.1s linear;
    position: relative;
}

.video-progress-filled::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 12px;
    height: 12px;
    background: #e0c080;
    border-radius: 50%;
    box-shadow: 0 0 8px rgba(224, 192, 128, 0.6);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.video-progress-bar:hover .video-progress-filled::after {
    opacity: 1;
}

.video-time {
    display: flex;
    gap: 6px;
    align-items: center;
    font-size: 13px;
    color: rgba(224, 192, 128, 0.8);
    font-weight: 500;
    letter-spacing: 0.5px;
}

.video-time-divider {
    color: rgba(224, 192, 128, 0.4);
}
