/* =======================
   Futuristic Minimal Audio Player
   ======================= */
#radio-player-container {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 2px 0;
    z-index: 99999;
    display: flex;
    justify-content: center;
    color: var(--player-text, #e6f1ff);
}

.player-content {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    max-width: 1243px !important;
    width: 100% !important;
    height: 80px !important;
    padding: 0 12px !important;
    flex-wrap: wrap !important;
    position: relative;
}

.player-shell {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    width: 100%;
    height: 100%;
    padding: 0 28px;
    border-radius: 22px;
    background: radial-gradient(120% 180% at 10% 10%, rgba(255, 255, 255, 0.06) 0%, rgba(255, 255, 255, 0.02) 55%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.35);
    overflow: hidden;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    color: inherit;
}

.player-shell::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        var(--player-bg, #0b0f1c) 0%,
        var(--player-secondary, rgba(5, 9, 22, 0.7)) 100%
    );
    background: linear-gradient(
        135deg,
        var(--player-bg, #0b0f1c) 0%,
        color-mix(in srgb, var(--player-secondary, rgba(5, 9, 22, 0.7)) 80%, rgba(0, 0, 0, 0.4)) 100%
    );
    z-index: -2;
}

.player-shell::after {
    content: "";
    position: absolute;
    inset: -140% -80%;
    background: radial-gradient(circle at center, rgba(75, 225, 255, 0.4), transparent 70%);
    transform: translate3d(-12%, -16%, 0) rotate(18deg);
    transition: transform 1.1s ease, opacity 0.6s ease;
    opacity: 0.55;
    z-index: -1;
}

#radio-player-container.playing .player-shell::after {
    transform: translate3d(6%, 4%, 0) rotate(-12deg);
    opacity: 0.75;
}

.player-brand {
    display: flex;
    align-items: center;
    gap: 18px;
    min-width: 0;
    flex: 1 1 auto;
}

.player-section {
    display: flex;
    align-items: center;
    gap: 16px;
}

.player-divider {
    width: 1px;
    height: 46px;
    background: linear-gradient(
        180deg,
        rgba(255, 255, 255, 0.12) 0%,
        rgba(255, 255, 255, 0.05) 100%
    );
    border-radius: 999px;
    flex: 0 0 auto;
    opacity: 0.9;
}

.player-logo-frame {
    width: 60px;
    height: 60px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.player-logo-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: inherit;
}

.player-brand-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.station-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 2px 10px;
    border-radius: 14px;
    font-size: 8px;
    line-height: 1;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    background: linear-gradient(135deg, var(--player-live, rgba(255, 255, 255, 0.18)), rgba(255, 255, 255, 0.08));
    color: var(--player-live-text, #0b0f1c);
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.28);
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.25), 0 4px 12px rgba(255, 40, 110, 0.25);
    min-height: 14px;
    min-width: 62px;
    max-width: 90px;
    white-space: nowrap;
    text-shadow: 0 0 6px rgba(255, 255, 255, 0.45);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.station-badge .fa,
.station-badge .fas {
    font-size: 9px;
}

.station-name {
    margin: 2px 0 0;
    font-size: 15px;
    font-weight: 500;
    font-family: "Poppins", "Segoe UI", sans-serif;
    color: inherit;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: 0.01em;
}

.meta-label {
    text-transform: uppercase;
    letter-spacing: 0.18em;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.55);
    color: color-mix(in srgb, var(--player-text, #d9e3f2) 60%, rgba(255, 255, 255, 0.3));
    font-weight: 500;
}

.player-metadata {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    min-width: 0;
    flex: 0 1 300px;
}

.metadata-wrapper {
    max-width: 250px;
    overflow: hidden;
    white-space: nowrap;
    position: relative;
}

.metadata-scroller {
    display: inline-block;
    padding-left: 100%;
    animation: scroll-metadata 16s linear infinite;
}

.player-metadata-text {
    display: inline-block;
    white-space: nowrap;
    font-size: 0.95rem;
    color: inherit;
}

.player-controls {
    display: flex;
    align-items: center;
    gap: 20px;
    flex: 0 0 auto;
    min-width: 0;
}

.player-button {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border: 1px solid color-mix(in srgb, var(--player-icon, #4be1ff) 70%, rgba(255, 255, 255, 0.4));
    background: linear-gradient(135deg, var(--player-icon, #4be1ff) 10%, rgba(8, 17, 26, 0.4) 90%);
    background: linear-gradient(
        135deg,
        color-mix(in srgb, var(--player-icon, #4be1ff) 85%, rgba(255, 255, 255, 0.2)) 10%,
        color-mix(in srgb, var(--player-icon, #4be1ff) 65%, rgba(8, 17, 26, 0.4)) 90%
    );
    color: var(--player-button-text, #05131d);
    font-size: 22px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 12px 24px rgba(75, 225, 255, 0.25);
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, color 0.25s ease;
}

.player-button:hover,
.player-button:focus {
    transform: translateY(-3px);
    box-shadow: 0 18px 32px rgba(75, 225, 255, 0.35);
    outline: none;
}

.player-button.pause {
    color: var(--player-button-text, #05131d);
}

.player-volume {
    display: flex;
    align-items: center;
    gap: 14px;
}

#volume-control {
    width: 130px;
    background: transparent;
    -webkit-appearance: none;
    appearance: none;
}

#volume-control::-webkit-slider-runnable-track {
    height: 4px;
    background: rgba(255, 255, 255, 0.16);
    border-radius: 999px;
}

#volume-control::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    background: var(--player-icon, #4be1ff);
    border-radius: 50%;
    border: none;
    box-shadow: 0 0 0 6px rgba(75, 225, 255, 0.18);
    margin-top: -6px;
    cursor: pointer;
}

#volume-control::-moz-range-track {
    height: 4px;
    background: rgba(255, 255, 255, 0.16);
    border-radius: 999px;
}

#volume-control::-moz-range-thumb {
    width: 14px;
    height: 14px;
    background: var(--player-icon, #4be1ff);
    border: none;
    border-radius: 50%;
    box-shadow: 0 0 0 5px rgba(75, 225, 255, 0.18);
}

.volume-icon {
    color: rgba(255, 255, 255, 0.75);
    font-size: 20px;
}

@keyframes scroll-metadata {
  0% {
    transform: translateX(0%);
  }
  100% {
    transform: translateX(-100%);
  }
}

.player-social-icons {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-left: auto;
    flex-wrap: nowrap;
    flex: 0 0 auto;
    overflow-x: auto;
    max-width: 320px;
    padding-bottom: 4px;
    scrollbar-width: thin;
    scrollbar-color: color-mix(in srgb, var(--player-icon, #4be1ff) 40%, rgba(255, 255, 255, 0.2)) transparent;
}

.icon-social {
    color: var(--player-icon, #4be1ff);
    font-size: 18px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.02);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.icon-social:hover,
.icon-social:focus {
    transform: translateY(-2px);
    border-color: var(--player-icon, #4be1ff);
    box-shadow: 0 14px 24px rgba(75, 225, 255, 0.3);
    outline: none;
}

.player-loader {
    position: absolute;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.spinner {
    width: 34px;
    height: 34px;
    border: 3px solid rgba(255, 255, 255, 0.25);
    border-top: 3px solid var(--player-icon, #4be1ff);
    border-radius: 50%;
    animation: spin 0.9s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

#player-image {
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}

#radio-player-container.playing #player-image {
    transform: scale(1.04);
    box-shadow: 0 18px 30px rgba(75, 225, 255, 0.25);
}

@media (max-width: 1024px) {
    .player-shell {
        gap: 20px;
        padding: 0 20px;
    }

    .metadata-wrapper {
        max-width: 200px;
    }

    .player-social-icons {
        gap: 10px;
        max-width: 260px;
    }
}

@media (max-width: 780px) {
    .player-shell {
        gap: 18px;
    }

    .player-social-icons {
        display: none;
    }
}

@media screen and (max-width: 480px) {
    .player-content {
        height: auto !important;
        padding: 8px 12px !important;
    }

    .player-shell {
        flex-direction: column;
        align-items: stretch;
        gap: 18px;
        padding: 14px 18px;
        height: auto;
    }

    .player-divider {
        width: 100%;
        height: 1px;
    }

    .player-section {
        justify-content: space-between;
        width: 100%;
        gap: 14px;
    }

    .player-brand {
        width: 100%;
    }

    .player-brand-info {
        flex: 1;
    }

    .station-name {
        font-size: 14px;
    }

    .player-metadata {
        width: 100%;
        flex: 1;
        justify-content: space-between;
        gap: 10px;
    }

    .metadata-wrapper {
        max-width: 100%;
        flex: 1;
    }

    .player-controls {
        width: 100%;
        justify-content: space-between;
    }

    #volume-control {
        width: 100px;
    }

    .player-social-icons {
        width: 100%;
        justify-content: flex-start;
        display: flex;
        gap: 12px;
        max-width: 100%;
        padding-bottom: 6px;
    }
}

.player-social-icons::-webkit-scrollbar {
    height: 6px;
}

.player-social-icons::-webkit-scrollbar-track {
    background: transparent;
}

.player-social-icons::-webkit-scrollbar-thumb {
    background: color-mix(in srgb, var(--player-icon, #4be1ff) 45%, rgba(255, 255, 255, 0.2));
    border-radius: 999px;
}
