/*
Theme Name: TRPMix Music Theme
Theme URI: https://trpmix.com/
Author: TRPMix Team
Author URI: https://trpmix.com/
Description: قالب موسيقى متكامل مع مشغل مستمر ومتوافق مع PHP 7/8
Version: 2.0.2
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: trpmix
*/

/* Reset & Base */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Noto Kufi Arabic', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #0f0f13;
    color: #e0e0e0;
    line-height: 1.8;
    direction: rtl;
    text-align: right;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    font-weight: 500;
}
h1, h2, h3, h4, h5, h6, .site-title, .page-title, .card-title {
    font-family: 'Noto Kufi Arabic', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-weight: 700;
    letter-spacing: -0.02em;
}
a { text-decoration: none; color: #ff6b35; transition: color 0.3s; }
a:hover { color: #ff8c5a; }
img { max-width: 100%; height: auto; display: block; }
ul, ol { list-style: none; }

/* Container */
.container { max-width: 1200px; margin: 0 auto; padding: 0 15px; width: 100%; }

/* Header */
.site-header {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    padding: 15px 0;
    border-bottom: 2px solid #ff6b35;
    position: sticky;
    top: 0;
    z-index: 1000;
}
.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 15px;
}
.site-logo img { max-height: 50px; }
.site-title {
    font-size: 1.8rem;
    color: #ff6b35;
    font-weight: 800;
    letter-spacing: -0.03em;
}

/* Navigation */
.main-nav ul { display: flex; gap: 20px; flex-wrap: wrap; }
.main-nav a {
    color: #e0e0e0;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 25px;
    transition: all 0.3s;
    font-size: 0.95rem;
}
.main-nav a:hover { background: #ff6b35; color: #fff; }

/* Search */
.search-form { display: flex; gap: 5px; }
.search-form input {
    padding: 8px 15px;
    border: 1px solid #333;
    border-radius: 20px;
    background: #1a1a2e;
    color: #fff;
    width: 200px;
    font-family: 'Noto Kufi Arabic', sans-serif;
    font-weight: 500;
}
.search-form button {
    padding: 8px 20px;
    border: none;
    border-radius: 20px;
    background: #ff6b35;
    color: #fff;
    cursor: pointer;
    transition: background 0.3s;
    font-family: 'Noto Kufi Arabic', sans-serif;
    font-weight: 600;
}
.search-form button:hover { background: #ff8c5a; }

/* Breadcrumbs */
.breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 15px 0;
    font-size: 0.9rem;
    color: #888;
    align-items: center;
    font-weight: 500;
}
.breadcrumbs a { color: #ff6b35; }
.breadcrumbs .separator { color: #555; }

/* Content */
.site-content {
    padding: 30px 0;
    flex: 1;
}
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    margin-top: 40px;
}
.section-header:first-child { margin-top: 0; }
.page-title {
    font-size: 1.6rem;
    padding-bottom: 8px;
    border-bottom: 3px solid #ff6b35;
    display: inline-block;
    font-weight: 800;
}
.view-all {
    font-size: 0.9rem;
    font-weight: 600;
    padding: 6px 16px;
    background: #1a1a2e;
    border-radius: 20px;
    border: 1px solid #ff6b35;
    transition: all 0.3s;
}
.view-all:hover { background: #ff6b35; color: #fff; }

/* Grid */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

/* Card */
.card {
    background: #1a1a2e;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid #252540;
}
.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(255,107,53,0.15);
}
.card-thumb { position: relative; overflow: hidden; }
.card-thumb img {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    transition: transform 0.5s;
}
.card:hover .card-thumb img { transform: scale(1.05); }
.card-body { padding: 15px; }
.card-title {
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.card-meta {
    font-size: 0.8rem;
    color: #888;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 500;
}
.card-play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 50px;
    height: 50px;
    background: rgba(255,107,53,0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
    cursor: pointer;
    border: none;
    color: #fff;
    font-size: 1.2rem;
}
.card:hover .card-play { opacity: 1; }

/* Single Song */
.song-header {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 30px;
    margin-bottom: 30px;
    background: #1a1a2e;
    padding: 25px;
    border-radius: 15px;
}
.song-cover img {
    width: 100%;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.3);
}
.song-info h1 { font-size: 1.5rem; margin-bottom: 10px; color: #fff; font-weight: 800; }
.song-info .artist { font-size: 1.05rem; color: #ff6b35; margin-bottom: 15px; font-weight: 600; }
.song-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 20px; }
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 25px;
    border-radius: 25px;
    font-weight: 700;
    cursor: pointer;
    border: none;
    transition: all 0.3s;
    font-family: 'Noto Kufi Arabic', sans-serif;
    font-size: 0.9rem;
}
.btn-primary { background: #ff6b35; color: #fff; }
.btn-primary:hover { background: #ff8c5a; }
.btn-secondary { background: #252540; color: #e0e0e0; }
.btn-secondary:hover { background: #33335a; }
.btn-success { background: #28a745; color: #fff; }

/* Lyrics */
.lyrics-box {
    background: #1a1a2e;
    padding: 25px;
    border-radius: 12px;
    margin-top: 20px;
    line-height: 2.2;
    white-space: pre-line;
    font-weight: 500;
}

/* Lists */
.song-list { display: flex; flex-direction: column; gap: 8px; }
.song-list-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 15px;
    background: #1a1a2e;
    border-radius: 8px;
    transition: background 0.3s;
    cursor: pointer;
}
.song-list-item:hover, .song-list-item.current { background: #252540; border-right: 3px solid #ff6b35; }
.song-list-item .num { width: 30px; text-align: center; color: #888; font-weight: 600; }
.song-list-item .title { flex: 1; font-weight: 600; }
.song-list-item .duration { color: #888; font-size: 0.85rem; font-weight: 500; }
.song-list-item .play-btn {
    width: 35px;
    height: 35px;
    background: #ff6b35;
    border: none;
    border-radius: 50%;
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 30px;
    flex-wrap: wrap;
}
.pagination li { list-style: none; }
.pagination a, .pagination span {
    padding: 8px 16px;
    background: #1a1a2e;
    border-radius: 8px;
    color: #e0e0e0;
    transition: all 0.3s;
    display: inline-block;
    font-weight: 600;
}
.pagination a:hover, .pagination .current {
    background: #ff6b35;
    color: #fff;
}

/* Footer */
.site-footer {
    background: #0a0a0f;
    padding: 25px 0;
    border-top: 1px solid #1a1a2e;
    margin-bottom: 80px;
}
.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}
.footer-nav ul {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}
.footer-nav a { color: #888; font-weight: 500; }
.footer-nav a:hover { color: #ff6b35; }
.copyright { color: #888; font-size: 0.85rem; font-weight: 500; }

/* ============================= */
/* STICKY PLAYER BAR */
/* ============================= */
.trpmix-player-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #1a1a2e 0%, #0f0f1a 100%);
    border-top: 2px solid #ff6b35;
    padding: 10px 20px;
    z-index: 9999;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 -5px 20px rgba(0,0,0,0.5);
    transform: translateY(100%);
    transition: transform 0.4s ease;
    font-family: 'Noto Kufi Arabic', sans-serif;
}
.trpmix-player-bar.active { transform: translateY(0); }

.player-thumb {
    width: 50px;
    height: 50px;
    border-radius: 6px;
    overflow: hidden;
    flex-shrink: 0;
}
.player-thumb img { width: 100%; height: 100%; object-fit: cover; }

.player-info {
    flex: 1;
    min-width: 0;
}
.player-info .title {
    font-size: 0.9rem;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.player-info .artist {
    font-size: 0.75rem;
    color: #888;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 500;
}

.player-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}
.player-btn {
    background: none;
    border: none;
    color: #e0e0e0;
    font-size: 1.2rem;
    cursor: pointer;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s;
}
.player-btn:hover { background: rgba(255,107,53,0.2); color: #ff6b35; }
.player-btn.play-pause {
    width: 45px;
    height: 45px;
    background: #ff6b35;
    color: #fff;
    font-size: 1.1rem;
}
.player-btn.play-pause:hover { background: #ff8c5a; }

.player-progress {
    flex: 2;
    min-width: 150px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.player-progress input[type="range"] {
    flex: 1;
    -webkit-appearance: none;
    height: 4px;
    background: #333;
    border-radius: 2px;
    outline: none;
}
.player-progress input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 12px;
    background: #ff6b35;
    border-radius: 50%;
    cursor: pointer;
}
.player-progress .time {
    font-size: 0.7rem;
    color: #888;
    min-width: 40px;
    text-align: center;
    font-weight: 500;
}

.player-volume {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 120px;
}
.player-volume input[type="range"] {
    flex: 1;
    -webkit-appearance: none;
    height: 4px;
    background: #333;
    border-radius: 2px;
    outline: none;
}
.player-volume input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 10px;
    height: 10px;
    background: #ff6b35;
    border-radius: 50%;
    cursor: pointer;
}

.player-extra {
    display: flex;
    align-items: center;
    gap: 10px;
}
.player-extra a, .player-extra button {
    color: #888;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    transition: color 0.3s;
}
.player-extra a:hover, .player-extra button:hover { color: #ff6b35; }

/* Not Found */
.not-found { text-align: center; padding: 60px 20px; }
.not-found h1 { font-size: 6rem; color: #ff6b35; margin-bottom: 20px; font-weight: 900; }
.not-found h2 { margin-bottom: 20px; font-weight: 700; }
.not-found p { color: #888; margin-bottom: 30px; font-weight: 500; }

/* Page Content */
.page-content .entry-content { line-height: 1.9; font-weight: 500; }
.page-content .entry-content p { margin-bottom: 15px; }

/* Responsive */
@media (max-width: 768px) {
    .song-header { grid-template-columns: 1fr; }
    .header-inner { flex-direction: column; }
    .main-nav ul { justify-content: center; }
    .search-form input { width: 150px; }
    .player-volume { display: none; }
    .trpmix-player-bar { padding: 8px 10px; gap: 8px; }
    .player-progress { min-width: 80px; }
    .grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
    .footer-inner { flex-direction: column; text-align: center; }
    .section-header { flex-direction: column; gap: 10px; align-items: flex-start; }
}
