/* Reset et base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: #ffffff;
    line-height: 1.6;
    min-height: 100vh;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    padding: 20px 0;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
}

.logo {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav {
    display: flex;
    gap: 20px;
}

.nav-link {
    color: #ffffff;
    text-decoration: none;
    padding: 12px 24px;
    border-radius: 25px;
    background: rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    font-weight: 500;
}

.nav-link:hover,
.nav-link:focus,
.nav-link.active {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.nav-link.refresh {
    background: rgba(76, 175, 80, 0.3);
}

/* Section principale */
.section-title {
    font-size: 2rem;
    margin-bottom: 30px;
    text-align: center;
    opacity: 0.9;
}

/* Grille des pistes */
.tracks-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

/* Carte de piste */
.track-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 20px;
    transition: all 0.3s ease;
    cursor: pointer;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.track-card:hover,
.track-card:focus {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    outline: 2px solid rgba(255, 255, 255, 0.3);
}

.track-cover {
    width: 100%;
    height: 200px;
    margin-bottom: 15px;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.track-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.track-card:hover .track-cover img {
    transform: scale(1.05);
}

.cover-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: rgba(255, 255, 255, 0.7);
}

.track-info {
    text-align: center;
}

.track-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: #ffffff;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.track-artist {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 5px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.track-album {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 10px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.track-duration {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 40px;
}

.pagination-link {
    color: #ffffff;
    text-decoration: none;
    padding: 12px 24px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 25px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.pagination-link:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.pagination-info {
    color: rgba(255, 255, 255, 0.8);
    font-weight: 500;
}

/* État vide */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: rgba(255, 255, 255, 0.7);
}

.empty-state a {
    color: #4ecdc4;
    text-decoration: none;
    font-weight: 500;
}

/* Responsive Design */
@media (max-width: 768px) {
    .header {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
    
    .logo {
        font-size: 2rem;
    }
    
    .nav {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .tracks-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 20px;
    }
    
    .track-cover {
        height: 150px;
    }
    
    .pagination {
        flex-direction: column;
        gap: 15px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 15px;
    }
    
    .tracks-grid {
        grid-template-columns: 1fr;
    }
    
    .track-card {
        padding: 15px;
    }
}

/* Navigation clavier/télécommande */
.track-card:focus {
    outline: 3px solid #4ecdc4;
    outline-offset: 2px;
}

/* Animation d'entrée */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.track-card {
    animation: fadeInUp 0.6s ease forwards;
}

.track-card:nth-child(even) {
    animation-delay: 0.1s;
}

.track-card:nth-child(3n) {
    animation-delay: 0.2s;
}