/* Category Buttons Section */
#music-categories {
    padding: 20px 0;
    background-color: #f5f5f5;
    box-sizing: border-box;
}

#music-categories .inner {
    max-width: 1800px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    box-sizing: border-box;
}

.category-toggle {
    padding: 4px 20px;
    border: 2px solid #ccc;
    background-color: #fff;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.category-toggle.selected {
    background-color: #0073aa;
    color: #fff;
    border-color: #0073aa;
}

/* Songs Section */
#all-songs {
    padding: 20px 0;
    box-sizing: border-box;
    background: #ffffff;
}

#all-songs .inner {
    max-width: 1800px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    flex-wrap: wrap;
    box-sizing: border-box;
}

.song-card {
    width: calc(16.66% - 20px);
    margin: 10px;
    display: block;
    box-sizing: border-box;
}

.song-card.hidden {
    display: none;
}

.itembox {
    border: 1px solid #ddd;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    background-color: #fff;
    position: relative;
    transition: background-color 0.3s ease;
    box-sizing: border-box;
}

.itembox:hover {
    background-color: #f0f0f0;
}

.itembox:hover .play-button:not(.playing) {
    background-color: #00cc00;
}

.song-image {
    position: relative;
    box-sizing: border-box;
}

.song-image img {
    width: 100%;
    height: auto;
    display: block;
    box-sizing: border-box;
}

.play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    background-color: rgba(0, 0, 0, 0.7);
    border: none;
    border-radius: 50%;
    color: #fff;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.8;
    transition: background-color 0.3s ease, opacity 0.3s ease;
    box-sizing: border-box;
}

.play-button.playing {
    background-color: #ff0000;
}

.play-button .dashicons {
    display: flex;
    justify-content: space-around;
    align-items: center;
    font-size: 48px;
    line-height: 80px;
    width: 100%;
    height: 100%;
    box-sizing: border-box;
}

.play-button:not(.playing) .dashicons-controls-play {
    display: flex;
}

.play-button:not(.playing) .dashicons-dismiss {
    display: none;
}

.play-button.playing .dashicons-controls-play {
    display: none;
}

.play-button.playing .dashicons-dismiss {
    display: flex;
}

.play-button:hover:not(.playing) {
    opacity: 1;
}

.play-button.playing:hover {
    background-color: #ff0000;
}

/* Song Title and Group */
.song-title {
    padding: 10px;
    font-size: 18px;
    font-weight: bold;
    box-sizing: border-box;
}

.song-group {
    padding: 0 10px 10px;
    font-size: 14px;
    color: #666;
    box-sizing: border-box;
}

/* Start Playlist Section */
#start-playlist {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #020310;
    z-index: 1000;
    padding: 10px 0;
    box-sizing: border-box;
}

#start-playlist .inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: center;
    box-sizing: border-box;
}

.start-playlist-button {
    padding: 10px 20px;
    background-color: #0073aa;
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s ease;
    box-sizing: border-box;
}

.start-playlist-button:hover {
    background-color: #005d88;
}

/* ... (all existing CSS remains unchanged until Playlist View) ... */

/* Playlist View */
#playlist-view {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at center, #1e5799 0%, #1b1b1b 100%); /* Added gradient background */
    z-index: 2000;
    overflow-y: auto;
    box-sizing: border-box;
}

.playlist-container {
    display: flex;
    max-width: 1600px;
    margin: 0 auto;
    padding: 20px;
    box-sizing: border-box;
}

.left-sidebar {
    width: 400px;
    padding-right: 20px;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    padding: 20px 0;
    box-sizing: border-box;
    transition: display 0.3s ease;
    -webkit-overflow-scrolling: touch;
    &::-webkit-scrollbar {
        display: none;
    }
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.left-sidebar[style*="display: none"] {
    display: none !important;
}

.playlist-section {
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    box-sizing: border-box;
    -webkit-overflow-scrolling: touch;
    &::-webkit-scrollbar {
        display: none;
    }
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.playlist-itembox {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
    background-color: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 5px;
    box-sizing: border-box;
    cursor: pointer;
}

.playlist-itembox:hover {
    background-color: #f0f0f0;
}

.playlist-itembox.active {
    background-color: #e6f3ff;
}

.playlist-image {
    width: 80px;
    height: 80px;
    overflow: hidden;
    box-sizing: border-box;
}

.playlist-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    box-sizing: border-box;
}

.playlist-title {
    flex-grow: 1;
    padding: 0 10px;
    font-size: 14px;
    font-weight: bold;
    box-sizing: border-box;
}

.main-screen {
    flex-grow: 1;
    padding: 20px;
    text-align: center;
    box-sizing: border-box;
}

.main-screen-title {
    font-weight: bold;
    margin: 0 0 10px 0;
    text-align: center;
    color: white; /* Changed to white */
}

.main-screen-image {
    width: 640px;
    height: auto;
    max-width: 640px;
    box-sizing: border-box;
}

.main-screen-group {
    margin: 10px 0 0 0;
    text-align: center;
    color: white; /* Changed to white */
}

.song-controls {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.volume-control, .progress-control {
    display: flex;
    align-items: center;
    gap: 10px;
}

.volume-icon, .music-icon {
    font-size: 24px;
    background: none;
    border: none;
    cursor: default;
    padding: 0;
    color: white; /* Set base color for volume and music icons */
}

.volume-slider {
    width: 200px;
}

.progress-container {
    width: 640px;
    position: relative;
}

.progress-slider {
    width: 100%;
    cursor: pointer;
}

.navigation-control {
    display: flex;
    align-items: center;
    gap: 10px;
}

.prev-track, .next-track, .pause-track, .stop-track, .shuffle-icon, .playlist-toggle, .lyrics-toggle {
    font-size: 24px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    color: white; /* Set base color for all navigation Dashicons */
}

.pause-track.paused {
    color: #ff0000; /* Override to red when paused */
}

.shuffle-icon.active {
    color: #0073aa; /* Override to blue when active */
}

.right-sidebar {
    width: 400px;
    padding-left: 20px;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    padding: 20px 0;
    box-sizing: border-box;
    transition: display 0.3s ease;
    -webkit-overflow-scrolling: touch;
    &::-webkit-scrollbar {
        display: none;
    }
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.right-sidebar[style*="display: none"] {
    display: none !important;
}

.lyrics-content {
    font-size: 21px;
    color: white; /* Changed to white */
    padding-right: 10px;
    box-sizing: border-box;
}

/* Station Carousel Section */
#station-carousel {
    padding: 20px 0;
    background-color: #f5f5f5;
    box-sizing: border-box;
    background: radial-gradient(ellipse at center, #1e5799 0%, #1b1b1b 100%);
}

.carousel-inner {
    max-width: 1500px;
    margin: 0 auto;
    padding: 0 60px;
    position: relative;
    overflow: hidden;
    white-space: nowrap;
}

.titlewrapper {
    text-align: center; /* Centers the text horizontally */
    color: white; /* Sets text color to white */
    font-size: 2em; /* Sets font size to 2em */
    font-weight: bold; /* Makes the font bold */
    padding: 10px 0; /* Adds some vertical spacing (adjust as needed) */
}

.carousel-item {
    display: inline-block;
    margin-right: 10px;
    vertical-align: top;
}

.station-image {
    width: 200px;
    height: 200px;
    object-fit: cover;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 3px solid transparent;
    box-sizing: border-box;
}

.station-image:hover {
    border-color: white;
}

.carousel-prev, .carousel-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: #0073aa;
    color: #fff;
    border: none;
    padding: 10px;
    cursor: pointer;
    font-size: 16px;
    z-index: 10;
    width: 60px;
}

.carousel-prev {
    left: 10px;
}

.carousel-next {
    right: 10px;
}

.carousel-prev:hover, .carousel-next:hover {
    background-color: #005d88;
}

@media (max-width: 1600px) {
    #music-categories .inner, #all-songs .inner {
        max-width: 1400px;
    }
    .carousel-inner {
        max-width: 1200px;
        padding: 0 40px;
    }
    .titlewrapper {
        font-size: 1.8em; /* Slightly reduce for responsiveness */
    }
    .station-image {
        width: 180px;
        height: 180px;
    }
    .carousel-prev {
        left: 10px;
    }
    .carousel-next {
        right: 10px;
    }
}

@media (max-width: 1200px) {
    #music-categories .inner, #all-songs .inner {
        max-width: 1000px;
    }
    .carousel-inner {
        max-width: 900px;
        padding: 0 20px;
    }
    .titlewrapper {
        font-size: 1.5em; /* Further reduce for smaller screens */
    }
    .station-image {
        width: 150px;
        height: 150px;
    }
    .carousel-prev {
        left: 10px;
    }
    .carousel-next {
        right: 10px;
    }
    .song-card {
        width: calc(25% - 20px);
    }
}

.loading {
    text-align: center;
    color: white;
    font-size: 1.5em;
    padding: 20px;
}

/* Add to existing music.css */
#splash-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: #020310;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 1;
    transition: opacity 2s ease-out, transform 2s ease-out;
    position: relative;
    overflow:hidden;
}

#splash-screen.shrink {
    opacity: 0;
    transform: scale(0.1);
    transition: opacity 2s ease-out, transform 2s ease-out;
}

.splash-content {
    text-align: center;
}

.splash-logo {
    max-width: 80%;
    max-height: 80vh;
}

#main-view {
    display: none; /* Initially hidden until splash screen fades */
    opacity: 0;
    transition: opacity 1s ease-in;
}

#main-view.active {
    display: block;
    opacity: 1;
}

#splash-screen .spearman {
    position: absolute; 
    bottom:10%; 
    right: 10%;
    width: 400px;
    height: auto;
    /*transition: all 1s;*/
    /*transform: translateX(410px);*/
}

#splash-screen.shrink .spearman {

    /*transform: translateX(-500px);*/


}