/* Mobile First CSS - Base styles for mobile */

.container {
    max-width: calc(100vw - 1rem);
    margin: 1rem auto;
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    padding: 0 0.5rem;
    box-sizing: border-box;
    width: 100%;
    overflow-x: hidden;
}

.tagline {
    color: #aaa;
    font-size: 1.1em;
    letter-spacing: 1px;
}

.playlists {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.playlist-card {
    background: #1a1a1a;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 1rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    min-width: 0;
    max-width: calc(100vw - 2rem);
    box-sizing: border-box;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.playlist-header {
    display: flex;
    flex-direction: row;
    align-items: center;
    padding: 12px;
    gap: 10px;
    position: relative;
    box-sizing: border-box;
    min-width: 0;
}

.playlist-thumbnail {
    width: 80px;
    height: 80px;
    border-radius: 12px;
    overflow: hidden;
    flex-shrink: 0;
    position: relative;
}

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

.playlist-info {
    flex: 1;
}

.playlist-title {
    font-size: 1.2em;
    font-weight: 700;
    margin-bottom: 8px;
    color: #fff;
}

.playlist-description {
    color: #999;
    font-size: 0.85em;
    line-height: 1.5;
    margin-bottom: 8px;
}

.playlist-meta {
    color: #666;
    font-size: 0.75em;
}

.expand-button {
    width: 35px;
    height: 35px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
    position: absolute;
    bottom: 10px;
    right: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    font-size: 16px;
    color: #333;
}

.expand-button:hover {
    background: #fff;
    transform: scale(1.1);
}

.expand-button.rotated {
    transform: rotate(180deg);
}

.songs-container {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s ease;
    background: rgba(0, 0, 0, 0.3);
}

.songs-container.expanded {
    max-height: 10000px;
}

.song-item {
    display: flex;
    align-items: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    cursor: pointer;
    transition: background 0.2s ease;
    text-decoration: none;
    color: inherit;
    gap: 10px;
    padding: 12px;
    box-sizing: border-box;
    min-width: 0;
    overflow: hidden;
}

.song-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

.song-number {
    width: 20px;
    text-align: center;
    color: #666;
    font-size: 0.9em;
    flex-shrink: 0;
}

.song-thumbnail {
    width: 60px;
    height: 45px;
    flex-shrink: 0;
    margin-block-end: 1rem;
}

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

.song-info {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.song-title {
    font-weight: 600;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    display: block;
    position: relative;
    font-size: 0.9em;
}

.song-channel {
    color: #999;
    font-size: 0.75em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    display: block;
    position: relative;
}

.loading {
    padding: 40px 20px;
    text-align: center;
    color: #666;
    font-size: 1.1em;
}

.error {
    padding: 20px;
    text-align: center;
    color: #ff6b6b;
    background: rgba(255, 107, 107, 0.1);
    border-radius: 10px;
    margin: 20px 0;
}

/* Tablet and up styles */
@media (min-width: 768px) {
    .playlist-card {
        margin-bottom: 2rem;
        max-width: 100%;
    }

    .playlist-thumbnail {
        width: 100px;
        height: 100px;
    }

    .playlist-title {
        font-size: 1.5em;
    }

    .playlist-description {
        font-size: 0.95em;
        margin-bottom: 10px;
    }

    .playlist-meta {
        font-size: 0.85em;
    }

    .expand-button {
        width: 40px;
        height: 40px;
        bottom: 15px;
        right: 15px;
        font-size: 18px;
    }

    .song-item {
        padding: 20px;
        gap: 15px;
    }

    .song-thumbnail {
        width: 120px;
        height: 100px;
    }

    .song-title {
        font-size: 1em;
    }

    .song-channel {
        font-size: 0.85em;
    }
}