/* ========================
   Harmony Music Site CSS
======================= */

/* CSS Variables */
:root {
    --primary: #ffffff;
    --primary-dark: #5649c0;
    --secondary: #fd79a8;
    --secondary-dark: #e84393;
    --accent: #00d084;
    --dark: #2d3436;
    --light: #f5f6fa;
    --gray: #636e72;
    --card-bg: #1e1e3f;
    --shadow: 0 4px 12px rgba(0,0,0,0.2);
    --transition: all 0.3s ease;
    --shared-bg: #0e153a;
    --hover-bg: #2a2a57;
    --hover-shadow: 0 4px 12px rgba(0,0,0,0.3);
    --button-text: #ffffff;
}

/* Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background: var(--shared-bg);
    color: var(--primary);
    line-height: 1.6;
    padding-bottom: 100px;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

/* Container */
.container {
    width: 85%;
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    border: none;
}

.btn-primary {
    background-color: var(--primary-dark);
    color: var(--button-text);
}

.btn-primary:hover {
    background-color: var(--secondary-dark);
}

.btn-secondary {
    background-color: var(--secondary);
    color: var(--button-text);
}

.btn-secondary:hover {
    background-color: var(--secondary-dark);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

.btn-outline:hover {
    background-color: var(--primary);
    color: var(--primary-dark);
}

/* Section Titles */
.section-title {
    font-size: 1.3rem;
    margin-bottom: 30px;
    position: relative;
    padding-bottom: 10px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
/*     background-color: var(--primary); */
}

/* =======================
   Tracks & Blog Grid Layouts
======================= */
.tracks-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 50px;
    /* background-color: #341f97; */
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

/* Track Card */
.track-card {
/*     background-color: #341f97; */
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    color: var(--primary);
}

.track-card:hover {
    background-color: var(--hover-bg);
    box-shadow: var(--hover-shadow);
    transform: translateY(-4px);
}

.track-image {
    width: 100%;
    height: 160px;
    object-fit: cover;
}

.track-info {
    padding: 12px;
    color: var(--primary);
}

.track-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 5px;
    color: var(--primary);
    cursor: pointer; /* clickable */
}

.track-title:hover {
    color: var(--accent);
    text-decoration: underline;
}

.track-artist {
    color: var(--gray);
    margin-bottom: 12px;
}

.track-description {
    font-size: 0.85rem;
    color: white;
    margin-bottom: 5px;
}

.read-more-btn {
    color: #00b069;
    cursor: pointer;
    font-size: 15px;
    text-decoration: underline;
}

.read-more-btn:hover {
    color: var(--primary-dark);
}

/* Track Stats */
.track-stats {
    display: flex;
    justify-content: space-between;
    margin: 8px 0;
    font-size: 0.8rem;
    color: var(--gray);
}

.stat {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Track Actions Styling */
.track-actions {
    display: flex;
    flex-direction: row;
    gap: 5px;
    margin-top: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.track-actions .action-btn,
.track-actions a.action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: 30px;
    font-size: 0.9rem;
    font-weight: 600;
    border: none;
    color: #fff;
    cursor: pointer;
    transition: transform 0.25s ease, background-color 0.3s ease, box-shadow 0.3s ease;
    width: auto;
    text-align: center;
    text-decoration: none;
}

.action-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(255,255,255,0.08), 0 0 10px rgba(108,92,231,0.3);
}

/* PLAY BUTTON – Purple */
.play-btn {
    background: linear-gradient(135deg, #6c5ce7, #341f97);
    width: 50px;
    padding: 8px 12px;
}

.play-btn:hover {
    background: linear-gradient(135deg, #7b68ee, #2e1a8a);
}

/* DOWNLOAD BUTTON – Teal */
.download-btn {
    background: linear-gradient(135deg, #00b894, #00cec9);
    width: 120px;
}

.download-btn:hover {
    background: linear-gradient(135deg, #00cec9, #00b894);
}

/* LIKE BUTTON – Pink */
.like-btn {
    background: linear-gradient(135deg, #ff7675, #e84393);
    width: 50px;
}

.like-btn:hover {
    background: linear-gradient(135deg, #e84393, #fd79a8);
}

.like-btn.liked {
    background: linear-gradient(135deg, #e84393, #fd79a8);
    box-shadow: 0 4px 12px rgba(232, 67, 147, 0.5);
    transform: scale(1.05);
}

.like-btn i {
    font-size: 1rem;
}

/* Blog Card */
.blog-card {
    background-color: var(--card-bg);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.blog-card:hover {
    transform: translateY(-5px);
}

.blog-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.blog-content {
    padding: 20px;
}

.blog-title {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--primary);
}

.blog-excerpt {
    color: var(--gray);
    margin-bottom: 15px;
}

.blog-meta {
    display: flex;
    justify-content: space-between;
    color: var(--gray);
    font-size: 0.9rem;
}

/* Music Player */
.music-player {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: var(--card-bg);
    box-shadow: 0 -2px 10px rgba(0,0,0,0.2);
    padding: 15px 0;
    z-index: 1000;
    display: none;
}

.player-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.player-info {
    display: flex;
    align-items: center;
    gap: 15px;
    width: 25%;
}

.player-image {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    object-fit: cover;
}

.player-text .track-title {
    font-size: 1rem;
    margin-bottom: 0;
}

.player-text .track-artist {
    font-size: 0.8rem;
    margin-bottom: 0;
}

.player-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 50%;
}

.control-buttons {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 10px;
}

.control-btn {
    background: none;
    border: none;
    font-size: 1.2rem;
    color: var(--primary);
    cursor: pointer;
    transition: var(--transition);
}

.control-btn:hover {
    color: var(--accent);
}

.progress-container {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
}

.progress-bar {
    flex-grow: 1;
    height: 4px;
    background-color: #e0e0e0;
    border-radius: 2px;
    position: relative;
    cursor: pointer;
}

.progress {
    position: absolute;
    height: 100%;
    background-color: var(--accent);
    border-radius: 2px;
    width: 0%;
}

/* Track Artist Links */
.track-artist a {
    color: #6c5ce7;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease, text-decoration 0.3s ease;
}

.track-artist a:hover {
    color: #5649c0;
    text-decoration: underline;
    cursor: pointer;
}

/* Responsive Grids */
@media (max-width: 1200px) {
    .tracks-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 992px) {
    .tracks-grid, .blog-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .player-content {
        flex-wrap: wrap;
    }
    .player-info, .player-controls, .player-actions {
        width: 100%;
        margin-bottom: 10px;
    }
}

@media (max-width: 768px) {
    .tracks-grid, .blog-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 576px) {
    .track-actions {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        gap: 5px;
    }
     
    .download-btn {
        width: 120px;
    }
    .play-btn, .like-btn {
        width: auto;
        flex: 1 1 auto;
        min-width: 60px;
    }
}

/* ========================
   Artist Tracks Grid Layout
======================= */
.artist-tracks-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* 4 per row on large screens */
    gap: 20px;
    margin-bottom: 50px;
}

@media (max-width: 1200px) {
    .artist-tracks-grid {
        grid-template-columns: repeat(3, 1fr); 
    }
}

@media (max-width: 992px) {
    .artist-tracks-grid {
        grid-template-columns: repeat(2, 1fr); 
    }
}

@media (max-width: 768px) {
    .artist-tracks-grid {
        grid-template-columns: 1fr; 
    }
}
