#fsp-player-wrapper {
    position: fixed;
    bottom: 30px;
    left: 0;
    width: 100%;
    z-index: 99999;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: none;
}

#fsp-player-container {
    pointer-events: auto;
    width: 95%;
    max-width: 900px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-radius: 18px;
    padding: 10px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 15px 45px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.4);
    color: #333;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* Left Section */
.fsp-left {
    display: flex;
    align-items: center;
    gap: 15px;
    flex: 1;
    /* Symmetric with right */
    min-width: 0;
}

.fsp-logo {
    width: 80px;
    height: 48px;
    background: #e63946;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(230, 57, 70, 0.3);
    transition: background 0.3s ease, box-shadow 0.3s ease;
    padding: 5px;
}

.fsp-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.fsp-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.fsp-brand {
    font-weight: 800;
    font-size: 18px;
    color: #444;
    line-height: 1.2;
    white-space: nowrap;
}

.fsp-subtitle-container {
    width: 100%;
    overflow: hidden;
    white-space: nowrap;
    position: relative;
}

.fsp-subtitle {
    font-size: 11px;
    font-weight: 600;
    color: #777;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    display: inline-block;
}

.fsp-marquee {
    display: inline-block;
    animation: fsp-marquee-bounce 8s ease-in-out infinite alternate;
}

@keyframes fsp-marquee-bounce {

    0%,
    20% {
        transform: translateX(0);
    }

    80%,
    100% {
        transform: translateX(var(--fsp-marquee-offset, 0));
    }
}

/* Center Section / Wave Animation */
.fsp-center {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.fsp-wave {
    display: flex;
    align-items: center;
    gap: 3px;
    height: 30px;
    opacity: 0;
    transition: opacity 0.3s;
}

.fsp-wave.fsp-active {
    opacity: 1;
}

.fsp-wave-bar {
    display: block;
    width: 3px;
    height: 5px;
    background: #e63946;
    border-radius: 2px;
}

@keyframes fsp-wave-anim-1 {

    0%,
    100% {
        height: 5px;
    }

    50% {
        height: 28px;
    }
}

@keyframes fsp-wave-anim-2 {

    0%,
    100% {
        height: 8px;
    }

    50% {
        height: 20px;
    }
}

@keyframes fsp-wave-anim-3 {

    0%,
    100% {
        height: 4px;
    }

    50% {
        height: 24px;
    }
}

.fsp-wave.fsp-active .fsp-wave-bar:nth-child(3n+1) {
    animation: fsp-wave-anim-1 0.8s ease-in-out infinite;
}

.fsp-wave.fsp-active .fsp-wave-bar:nth-child(3n+2) {
    animation: fsp-wave-anim-2 1.1s ease-in-out infinite;
}

.fsp-wave.fsp-active .fsp-wave-bar:nth-child(3n+3) {
    animation: fsp-wave-anim-3 0.9s ease-in-out infinite;
}

/* 20 Bars animation delays for a smoother, wider wave */
.fsp-wave-bar:nth-child(1) {
    animation-delay: 0.1s;
}

.fsp-wave-bar:nth-child(2) {
    animation-delay: 0.3s;
}

.fsp-wave-bar:nth-child(3) {
    animation-delay: 0.2s;
}

.fsp-wave-bar:nth-child(4) {
    animation-delay: 0.5s;
}

.fsp-wave-bar:nth-child(5) {
    animation-delay: 0.1s;
}

.fsp-wave-bar:nth-child(6) {
    animation-delay: 0.4s;
}

.fsp-wave-bar:nth-child(7) {
    animation-delay: 0.2s;
}

.fsp-wave-bar:nth-child(8) {
    animation-delay: 0.6s;
}

.fsp-wave-bar:nth-child(9) {
    animation-delay: 0.3s;
}

.fsp-wave-bar:nth-child(10) {
    animation-delay: 0.7s;
}

.fsp-wave-bar:nth-child(11) {
    animation-delay: 0.2s;
}

.fsp-wave-bar:nth-child(12) {
    animation-delay: 0.8s;
}

.fsp-wave-bar:nth-child(13) {
    animation-delay: 0.4s;
}

.fsp-wave-bar:nth-child(14) {
    animation-delay: 0.9s;
}

.fsp-wave-bar:nth-child(15) {
    animation-delay: 0.3s;
}

.fsp-wave-bar:nth-child(16) {
    animation-delay: 0.7s;
}

.fsp-wave-bar:nth-child(17) {
    animation-delay: 0.2s;
}

.fsp-wave-bar:nth-child(18) {
    animation-delay: 0.5s;
}

.fsp-wave-bar:nth-child(19) {
    animation-delay: 0.1s;
}

.fsp-wave-bar:nth-child(20) {
    animation-delay: 0.4s;
}

.fsp-volume-wrapper {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    /* Align badge to the right of the group */
    gap: 4px;
    width: 100%;
    max-width: 250px;
}

/* Right Section */
.fsp-right {
    display: flex;
    align-items: center;
    gap: 20px;
    flex: 1;
    /* Symmetric with left */
    justify-content: flex-end;
}

.fsp-live-badge {
    background: #e63946;
    color: white;
    font-size: 8px;
    font-weight: 800;
    text-transform: uppercase;
    padding: 2px 7px;
    border-radius: 4px;
    letter-spacing: 0.8px;
    box-shadow: 0 2px 8px rgba(230, 57, 70, 0.4);
    animation: fsp-pulse 1.5s infinite;
    pointer-events: none;
    line-height: 1;
    margin-right: 5px;
    /* Slight offset to align with thumb */
}

@keyframes fsp-pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.05);
        opacity: 0.8;
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.fsp-volume-group {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
}

.fsp-v-icon {
    flex-shrink: 0;
    opacity: 0.5;
    transition: opacity 0.2s;
}

.fsp-volume-group:hover .fsp-v-icon {
    opacity: 0.8;
}

#fsp-volume {
    width: 100%;
    -webkit-appearance: none;
    appearance: none;
    height: 3px;
    background: rgba(230, 57, 70, 0.1);
    border-radius: 2px;
    outline: none;
    cursor: pointer;
}

#fsp-volume::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 12px;
    background: #e63946;
    border-radius: 50%;
    cursor: pointer;
    border: 2px solid #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
}

.fsp-btn-main {
    background: #e63946;
    border: none;
    width: 58px;
    height: 58px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(230, 57, 70, 0.4);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    flex-shrink: 0;
}

.fsp-btn-main:hover {
    transform: scale(1.08);
}

.fsp-btn-main:active {
    transform: scale(0.95);
}

/* Responsive */
@media (max-width: 768px) {
    #fsp-player-wrapper {
        bottom: 15px; /* Stay closer to the bottom on mobile */
    }

    #fsp-player-container {
        flex-direction: row;
        gap: 10px;
        padding: 8px 12px;
        border-radius: 12px;
    }

    .fsp-left {
        gap: 10px;
        justify-content: flex-start;
        text-align: left;
    }

    .fsp-logo {
        width: 50px;
        height: 38px;
    }

    .fsp-brand {
        font-size: 14px;
        margin-bottom: 2px;
    }

    .fsp-subtitle {
        font-size: 9px;
    }

    .fsp-center {
        display: none; /* Hide waves to save horizontal space */
    }

    .fsp-volume-wrapper {
        display: none; /* Volume slider is not needed since mobile has physical buttons */
    }

    .fsp-right {
        width: auto;
        flex: 0 0 auto;
        justify-content: flex-end;
        gap: 0;
    }

    .fsp-btn-main {
        width: 42px;
        height: 42px;
    }

    .fsp-btn-main svg {
        width: 18px !important;
        height: 18px !important;
    }
}