/* General body and HTML styling */
body, html {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    overflow: hidden; /* Prevents scrollbars */
    background-color: #000; /* Black background for loading */
    font-family: 'Audiowide', sans-serif;
}

/* Styles for the main play button overlay */
#play-button-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10;
    background-color: rgba(0, 0, 0, 0.5);
    cursor: pointer;
    transition: opacity 0.5s ease;
}

/* Hides the play button container when the .hidden class is added */
#play-button-container.hidden {
    opacity: 0;
    pointer-events: none; /* Disables interaction when hidden */
}

/* The play button itself */
#master-play-btn {
    font-size: 5vw;
    width: 10vw;
    height: 10vw;
    min-width: 80px;
    min-height: 80px;
    max-width: 150px;
    max-height: 150px;
    border-radius: 50%;
    border: 3px solid white;
    background-color: rgba(0, 0, 0, 0.4);
    color: white;
    cursor: pointer;
    transition: transform 0.2s ease, background-color 0.2s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    /* Optical centering for the play icon */
    padding-left: 1vw;
}

#master-play-btn:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

/* Styles for the fullscreen video container */
#shuffle-video-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

/* The video elements */
.shuffle-video-player {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0; /* Hidden by default */
    transition: opacity 1.5s ease-in-out; /* Smooth fade transition */
}

.shuffle-video-player.active {
    opacity: 1; /* The active player is visible */
}


/* --- UPDATED STYLES FOR HOVER/TAP CONTROLS --- */

/* Fullscreen container to detect hover/tap */
#hover-controls-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 5;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

#hover-controls-container.visible {
    opacity: 1;
    pointer-events: auto;
}

/* NEW: Panel with background for controls */
#controls-panel {
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 20px 30px;
    border-radius: 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px; /* Space between play button and volume group */
}

/* The pause/play button that appears on hover */
#hover-play-pause-btn {
    font-size: 3vw;
    width: 7vw;
    height: 7vw;
    min-width: 60px;
    min-height: 60px;
    max-width: 100px;
    max-height: 100px;
    border-radius: 50%;
    border: 2px solid white;
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    cursor: pointer;
    transition: transform 0.2s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: auto;
}

#hover-play-pause-btn:hover {
    transform: scale(1.1);
}

/* NEW: Group for volume icon and slider */
#volume-control-group {
    display: flex;
    align-items: center;
}

/* NEW: Volume icon */
#volume-icon {
    font-size: 26px;
    color: white;
    margin-right: 15px;
    text-shadow: 0 0 5px rgba(0, 0, 0, 0.5); /* Add shadow for better visibility */
}

/* Volume slider styles */
#volume-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 50vw;
    height: 10px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 5px;
    outline: none;
    cursor: pointer;
    pointer-events: auto;
}

/* --- SLIDER THUMB STYLES --- */
#volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    background: #ffffff;
    border-radius: 50%;
    border: 1px solid rgba(0, 0, 0, 0.2);
    cursor: pointer;
}

#volume-slider::-moz-range-thumb {
    width: 24px;
    height: 24px;
    background: #ffffff;
    border-radius: 50%;
    border: 1px solid rgba(0, 0, 0, 0.2);
    cursor: pointer;
}