* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: #ffffff;

    background: url("../fireflies-radio-bg.jpg") no-repeat center top;
    background-size: cover;

    min-height: 100vh;
}

/* HEADER */

.ff-header {
    text-align: center;
    padding: 20px 20px 0;
}

.ff-logo {
    height: 70px;
    margin-bottom: 8px;
}

.ff-title {
    margin: 0;
    font-size: clamp(2.4rem, 4.5vw, 3.6rem);
    letter-spacing: 0.22em;
    font-weight: 700;
    color: #3a4c52;
    text-transform: uppercase;
    text-shadow:
        0 6px 12px rgba(0, 0, 0, 0.15),
        0 0 20px rgba(255, 255, 255, 0.35);
}

/* MAIN */

.ff-main {
    max-width: 100%;
    margin: 0 auto 40px;
    padding: 0 30px 40px;
}

.ff-header + .ff-main {
    margin-top: 0 !important;
}

/* ===== STRONA GŁÓWNA – BOXY Z RADIEM ===== */

.stations-grid {
    max-width: 1120px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
}

.station-card {
    position: relative;
    border-radius: 26px;
    padding: 18px 20px 16px;

    background: linear-gradient(
        135deg,
        rgba(14, 130, 170, 0.9) 0%,
        rgba(35, 205, 185, 0.9) 100%
    );

    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);

    border: 1px solid rgba(255, 255, 255, 0.55);

    box-shadow:
        0 20px 45px rgba(0, 0, 0, 0.25),
        0 0 30px rgba(0, 255, 220, 0.35);
}

.station-card-header {
    margin-bottom: 8px;
}

.station-title {
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.station-subtitle {
    font-size: 0.9rem;
    color: #e3fffb;
}

.station-body iframe {
    width: 100%;
    border-radius: 18px;
    background: transparent;
}

.station-footer {
    margin-top: 24px;
    display: flex;
    justify-content: center;
}

.station-button {
    display: inline-flex;
    align-items: center;
    gap: 12px;

    border-radius: 999px;
    padding: 18px 36px;

    border: none;
    text-decoration: none;

    font-size: 1.1rem;
    font-weight: 700;

    cursor: pointer;

    background: linear-gradient(135deg, #00c58a, #00e0a0);
    color: #02221a;

    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.35);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.station-button:hover {
    transform: translateY(-2px) scale(1.03);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
}

/* ===== PLAYER NA PEŁNĄ SZEROKOŚĆ ===== */

.ff-radio-shell {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 1440px;
    margin: 0 auto;
    width: 100%;
}

/* ff-card to tylko „obudowa” */
.ff-card {
    position: relative;
    border-radius: 0;
    padding: 0;
    background: transparent;
    border: none;
    box-shadow: none;
    overflow: visible;
}

/* Właściwy panel playera */

.radio-player {
    display: block;
    border-radius: 32px;
    padding: 18px 24px 20px;

    background: linear-gradient(
        135deg,
        rgba(14, 130, 170, 0.9) 0%,
        rgba(35, 205, 185, 0.9) 100%
    );

    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);

    border: 1px solid rgba(255, 255, 255, 0.55);

    box-shadow:
        0 20px 45px rgba(0, 0, 0, 0.25),
        0 0 30px rgba(0, 255, 220, 0.35);

    overflow: hidden;
}

/* GÓRA PLAYERA */

.rp-top {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 16px;
    align-items: center;
    margin-bottom: 14px;
}

.rp-cover {
    width: 88px;
    height: 88px;
    border-radius: 18px;
    overflow: hidden;
    box-shadow:
        0 10px 22px rgba(0, 0, 0, 0.55),
        0 0 18px rgba(0, 0, 0, 0.8);
    flex-shrink: 0;
    background: rgba(0,0,0,0.25);
}

.rp-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.rp-info {
    min-width: 0;
}

.rp-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: #e3fffb;
    opacity: 0.9;
    margin-bottom: 4px;
}

.rp-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 2px;
    color: #ffffff;
    text-shadow: 0 1px 2px rgba(0,0,0,0.35);
}

.rp-artist {
    font-size: 0.85rem;
    color: #e3fffb;
    opacity: 0.9;
}

/* Kontrolki */

.rp-controls {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 12px;
}

.rp-controls button {
    border: none;
    border-radius: 999px;
    padding: 7px 14px;
    font-size: 0.8rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(0, 0, 0, 0.25);
    color: #ffffff;
    backdrop-filter: blur(6px);
}

.rp-controls button.primary {
    background: #00c58a;
    color: #02221a;
    font-weight: 600;
    box-shadow: 0 0 12px rgba(0, 0, 0, 0.35);
}

.rp-controls button:hover {
    transform: translateY(-1px);
    filter: brightness(1.05);
}

/* Pasek postępu */

.rp-progress-container {
    margin-top: 10px;
}

.rp-progress-bar {
    width: 100%;
    height: 4px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.35);
    overflow: hidden;
    cursor: pointer;
}

.rp-progress {
    width: 0;
    height: 100%;
    background: #e3fffb;
    box-shadow: 0 0 8px rgba(255, 255, 255, 0.9);
}

.rp-time {
    display: flex;
    justify-content: space-between;
    font-size: 0.72rem;
    color: #e3fffb;
    opacity: 0.9;
    margin-top: 4px;
}

/* Wyszukiwarka */

.rp-search {
    margin-top: 14px;
}

.rp-search input {
    width: 100%;
    border-radius: 999px;
    border: none;
    padding: 6px 12px;
    font-size: 0.8rem;
    outline: none;
    background: rgba(0, 0, 0, 0.25);
    color: #ffffff;
}

.rp-search input::placeholder {
    color: rgba(255, 255, 255, 0.8);
}

/* PLAYLISTA – KAFELKI */

.rp-playlist-wrapper {
    margin-top: 10px;
    border-radius: 14px;
    background: rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.35);
    box-shadow:
        0 12px 24px rgba(0, 0, 0, 0.35),
        0 0 16px rgba(0, 0, 0, 0.45);
}

.rp-playlist {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 14px;
}

.rp-track {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 8px;
    border-radius: 16px;
    background: rgba(0, 0, 0, 0.22);
    box-shadow:
        0 6px 16px rgba(0, 0, 0, 0.4);
    cursor: pointer;
    transition: transform 0.12s ease-out, box-shadow 0.12s ease-out,
    background 0.12s ease-out;
}

.rp-track:hover {
    transform: translateY(-2px);
    background: rgba(0, 0, 0, 0.32);
    box-shadow:
        0 10px 22px rgba(0, 0, 0, 0.55);
}

.rp-track.active {
    outline: 2px solid #00ffbb;
    outline-offset: 0;
}

/* okładka kafelka */

.rp-track-cover {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    border-radius: 12px;
    overflow: hidden;
    background: rgba(0,0,0,0.4);
}

.rp-track-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* play bubble */

.rp-track-cover::after {
    content: "▶";
    position: absolute;
    right: 8px;
    bottom: 8px;
    width: 28px;
    height: 28px;
    border-radius: 999px;
    background: #00c58a;
    color: #02221a;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 10px rgba(0,0,0,0.6);

    opacity: 0;
    transform: scale(0.85);
    transition: opacity 0.12s ease-out, transform 0.12s ease-out;
}

.rp-track:hover .rp-track-cover::after {
    opacity: 1;
    transform: scale(1);
}

/* meta */

.rp-track-title-row {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.rp-track-title {
    font-weight: 600;
    font-size: 0.9rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.rp-track-artist {
    font-size: 0.78rem;
    color: #e3fffb;
    opacity: 0.9;
}

.rp-track-duration {
    font-size: 0.74rem;
    color: #e3fffb;
    opacity: 0.8;
}

/* RWD */

@media (max-width: 640px) {
    .ff-main {
        padding: 0 16px 32px;
    }

    .rp-top {
        grid-template-columns: 1fr;
    }

    .rp-cover {
        width: 76px;
        height: 76px;
    }
}
