/* --- 1. RESET & VARIABLES --- */
:root { 
    --sidebar-width: 240px; 
    --primary: #1e272e; 
    --accent: #ff4757; 
    --light-bg: #f4f6f8;
    --text-color: #333;
}
body { 
    font-family: 'Inter', sans-serif; 
    background: var(--light-bg); 
    color: var(--text-color); 
    margin: 0; 
    padding-bottom: 100px; 
}
a { text-decoration: none; color: inherit; }
* { box-sizing: border-box; }

/* --- 2. LEFT SIDEBAR --- */
.sidebar { 
    position: fixed; top: 0; left: 0; bottom: 0; 
    width: var(--sidebar-width); background: #fff; 
    border-right: 1px solid #e1e4e8; padding: 25px 20px; 
    overflow-y: auto; z-index: 100;
}
.mobile-close-btn { display: none; } /* Hide on Desktop */

.sidebar-logo { display: flex; align-items: center; gap: 10px; font-size: 20px; font-weight: 800; color: var(--accent); margin-bottom: 30px; }
.sidebar-logo img { width: 32px; height: auto; }

/* SEARCH BAR */
.search-box { margin-bottom: 20px; position: relative; }
.search-box input {
    width: 100%; padding: 10px 15px 10px 35px;
    border: 1px solid #eee; background: #f9f9f9;
    border-radius: 20px; outline: none; transition: 0.2s;
}
.search-box input:focus { border-color: var(--accent); background: #fff; }
.search-box i { position: absolute; left: 12px; top: 12px; color: #999; font-size: 14px; }

/* NAV MENU */
.nav-menu a { display: flex; align-items: center; gap: 12px; padding: 12px 15px; color: #555; font-weight: 600; border-radius: 8px; margin-bottom: 5px; }
.nav-menu a:hover, .nav-menu a.active { background: #f0f2f5; color: var(--accent); }
.nav-section { font-size: 11px; text-transform: uppercase; letter-spacing: 1.2px; color: #aab0b6; margin: 25px 0 10px 10px; font-weight: 700; }

/* --- 3. MAIN CONTENT --- */
.main-wrapper { margin-left: var(--sidebar-width); padding: 30px 40px; }
.main-footer { margin-left: var(--sidebar-width); text-align: center; padding: 20px; color: #999; font-size: 12px; margin-bottom: 80px; }

/* GRID & CARDS */
h2 { color: var(--primary); margin-bottom: 25px; font-weight: 800; }
.station-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 25px; }
.station-card { background: #fff; border-radius: 12px; padding: 15px; text-align: center; cursor: pointer; transition: 0.2s; border: 1px solid transparent; }
.station-card:hover { transform: translateY(-5px); box-shadow: 0 10px 25px rgba(0,0,0,0.08); }
.img-wrap { position: relative; border-radius: 8px; overflow: hidden; aspect-ratio: 1/1; margin-bottom: 12px; background: #eee; }
.img-wrap img { width: 100%; height: 100%; object-fit: cover; }
.img-wrap .overlay { position: absolute; top:0; left:0; right:0; bottom:0; background: rgba(0,0,0,0.4); display: flex; align-items: center; justify-content: center; opacity: 0; transition: 0.3s; }
.station-card:hover .overlay { opacity: 1; }
.overlay i { color: #fff; font-size: 40px; }
.station-card h4 a { color: #333; font-size: 15px; font-weight: 700; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* --- 4. DETAIL PAGE & BUTTONS --- */
.detail-layout { display: flex; gap: 40px; margin-top: 20px; }
.main-col { flex: 2; min-width: 0; }
.side-col { flex: 1; min-width: 300px; }

.detail-head { display: flex; gap: 30px; align-items: center; margin-bottom: 30px; background: #fff; padding: 30px; border-radius: 15px; }
.detail-head img { width: 180px; height: 180px; border-radius: 12px; object-fit: cover; box-shadow: 0 5px 15px rgba(0,0,0,0.1); }
.detail-meta h1 { margin: 0 0 15px 0; font-size: 28px; color: var(--primary); }

/* PLAY BUTTON */
.play-btn-lg { 
    background: var(--accent); color: #fff; border: none; padding: 12px 30px; 
    border-radius: 50px; font-size: 16px; font-weight: bold; cursor: pointer; 
    display: inline-flex; align-items: center; gap: 10px; transition: 0.2s; 
    text-transform: uppercase; box-shadow: 0 4px 15px rgba(255, 71, 87, 0.3);
}
.play-btn-lg:hover { background: #ff2e43; transform: scale(1.05); }

.desc-box { background: #fff; padding: 30px; border-radius: 15px; line-height: 1.8; color: #555; margin-bottom: 30px; }
.comment-box { background: #fff; padding: 15px; margin-bottom: 10px; border-radius: 8px; border-left: 4px solid var(--accent); }

/* SHARE BUTTONS */
.share-label { font-size: 12px; font-weight: bold; color: #888; margin-bottom: 8px; display: block; text-transform: uppercase; letter-spacing: 1px;}
.share-box { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 20px; }
.share-btn { width: 40px; height: 40px; border-radius: 50%; color: #fff; display: flex; align-items: center; justify-content: center; font-size: 16px; transition: 0.2s; box-shadow: 0 3px 10px rgba(0,0,0,0.1); }
.share-btn:hover { transform: translateY(-3px); opacity: 0.9; }
.share-fb { background: #1877f2; }
.share-x { background: #000; }
.share-in { background: #0077b5; }
.share-pin { background: #bd081c; }
.share-wa { background: #25D366; }

/* --- 5. MOBILE HEADER --- */
.mobile-header { display: none; }
.mobile-search-bar { display: none; padding: 15px; background: #fff; border-bottom: 1px solid #eee; }
.mobile-search-bar.active { display: block; }

/* --- 6. FIXED PLAYER --- */
.fixed-player { 
    position: fixed; bottom: 0; left: 0; right: 0; height: 80px; 
    background: #1e272e; color: #fff; z-index: 99999; 
    display: flex; align-items: center; padding: 0 20px; 
    border-top: 2px solid var(--accent);
}
.player-container { width: 100%; display: flex; justify-content: space-between; align-items: center; }
.p-info { display: flex; align-items: center; gap: 15px; width: 300px; }
.p-info img { width: 50px; height: 50px; border-radius: 6px; }
.p-controls { display: flex; justify-content: center; flex: 1; }

.big-play-btn { 
    width: 55px; height: 55px; border-radius: 50%; 
    background: var(--accent); border: none; color: #fff; 
    font-size: 22px; cursor: pointer; position: relative; 
    display: grid; place-items: center; z-index: 2; transition: transform 0.2s;
}
.big-play-btn:hover { transform: scale(1.05); }
.big-play-btn.buffering::after {
    content: ''; position: absolute; top: -6px; left: -6px; right: -6px; bottom: -6px; 
    border-radius: 50%; border: 3px solid rgba(255,255,255, 0.2); 
    border-top-color: #fff; animation: spin 1s linear infinite; z-index: 1;
}
@keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }
.p-volume { display: flex; align-items: center; gap: 10px; width: 200px; justify-content: flex-end; }
.p-volume i { cursor: pointer; width: 20px; text-align: center; }

/* --- 7. MOBILE RESPONSIVE --- */
@media (max-width: 992px) {
    .sidebar { transform: translateX(-100%); transition: 0.3s; box-shadow: 5px 0 15px rgba(0,0,0,0.1); }
    .sidebar.open { transform: translateX(0); }
    .main-wrapper { margin-left: 0; padding: 20px; }
    .main-footer { margin-left: 0; }
    
    .mobile-header { display: flex; justify-content: space-between; align-items: center; padding: 15px; background: #fff; border-bottom: 1px solid #eee; }
    
    .mobile-close-btn {
        display: block; text-align: right; padding: 10px; cursor: pointer;
        color: #888; font-size: 14px; font-weight: bold; margin-bottom: 10px; border-bottom: 1px solid #eee;
    }
    
    /* FIX: MOBILE DETAIL PAGE LAYOUT */
    .detail-layout { flex-direction: column; }
    
    .detail-head { 
        flex-direction: column; /* Stack vertically */
        text-align: center;     /* Center text */
        padding: 20px;
        gap: 20px;
    }
    
    .detail-head img { 
        width: 200px; /* Larger logo for mobile */
        height: 200px; 
        margin: 0 auto; 
    }
    
    .detail-meta { width: 100%; }
    
    /* Center the Social Icons */
    .share-box { justify-content: center; }

    .p-volume { display: none; }
    .p-info { width: auto; flex: 1; }
}