/* soundtracks.css - только для страницы саундтреков */
/* Основные стили (header, nav, footer, body, container) берутся из style.css */

/* Глобальный плеер */
.global-player {
    position: sticky;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #1a2a1a 0%, #0f1a0f 100%);
    border-top: 2px solid #bd8a3e;
    padding: 12px 20px;
    z-index: 1000;
    box-shadow: 0 -5px 20px rgba(0,0,0,0.5);
    border-radius: 16px 16px 0 0;
    margin-top: 30px;
}

.player-bar {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
    max-width: 1200px;
    margin: 0 auto;
}

.player-controls {
    display: flex;
    gap: 8px;
    align-items: center;
}

.player-btn {
    background: #2a3a2a;
    border: 1px solid #bd8a3e;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    color: #ffd966;
    font-size: 16px;
    transition: all 0.2s;
}

.player-btn:hover {
    background: #bd8a3e;
    color: #0f1a0f;
    transform: scale(1.05);
}

.player-btn.repeat-active,
.player-btn.shuffle-active {
    background: #bd8a3e;
    color: #0f1a0f;
}

.player-info {
    flex: 1;
    min-width: 150px;
}

.player-song {
    font-size: 16px;
    font-weight: bold;
    color: #ffd966;
}

.player-artist {
    font-size: 12px;
    color: #8aa07a;
}

.player-progress {
    flex: 2;
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 180px;
}

.progress-bar {
    flex: 1;
    height: 4px;
    background: #3e5a3e;
    border-radius: 2px;
    cursor: pointer;
    position: relative;
}

.progress-fill {
    height: 100%;
    background: #bd8a3e;
    border-radius: 2px;
    width: 0%;
    transition: width 0.1s linear;
}

.current-time, .duration {
    font-size: 11px;
    color: #8aa07a;
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 8px;
}

.volume-control i {
    color: #bd8a3e;
}

#volumeSlider {
    width: 70px;
    cursor: pointer;
    background: #2a3a2a;
}

/* Секция сортировки */
.sort-section {
    background: #0f1a0f;
    border-radius: 16px;
    padding: 12px 20px;
    margin: 20px auto;
    max-width: 800px;
    border: 1px solid #3e5a3e;
}

.sort-container {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.sort-icon {
    color: #bd8a3e;
    font-size: 16px;
}

.sort-label {
    color: #ffd966;
    font-size: 14px;
    font-weight: 500;
}

.sort-select {
    background: #1e2a1e;
    border: 1px solid #3e5a3e;
    color: #ddd;
    padding: 8px 16px;
    border-radius: 30px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
}

.sort-select:hover {
    border-color: #bd8a3e;
}

/* Сетка песен */
.music-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 800px;
    margin: 0 auto 30px;
    padding: 0 20px;
}

.music-card {
    background: #0f1a0f;
    border: 1px solid #3e5a3e;
    border-radius: 16px;
    padding: 15px 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    cursor: pointer;
    transition: all 0.2s;
}

.music-card:hover {
    background: #1a2a1a;
    border-color: #bd8a3e;
    transform: translateX(5px);
}

.music-card.active-music {
    background: linear-gradient(135deg, #1a3a1a, #0f1a0f);
    border: 2px solid #ffd966;
    box-shadow: 0 0 15px rgba(189,138,62,0.3);
}

.music-icon {
    width: 50px;
    height: 50px;
    background: #1e2a1e;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #bd8a3e;
}

.music-info {
    flex: 1;
}

.music-title {
    font-size: 18px;
    font-weight: bold;
    color: #ffd966;
}

.music-artist {
    font-size: 13px;
    color: #8aa07a;
    margin: 4px 0;
}

.music-desc {
    font-size: 12px;
    color: #a0b088;
}

.music-meta {
    font-size: 11px;
    color: #bd8a3e;
    margin-top: 6px;
}

.music-play-btn {
    font-size: 32px;
    color: #bd8a3e;
    transition: transform 0.2s;
}

.music-card:hover .music-play-btn {
    transform: scale(1.1);
}

#audioPlayer {
    display: none;
}

/* Страница описания */
.page-description {
    background: #0f1a0f;
    border-radius: 16px;
    padding: 20px;
    margin: 20px 0;
    text-align: center;
}

.description-title {
    color: #ffd966;
    font-size: 20px;
    margin-bottom: 10px;
}

.description-content p {
    color: #8aa07a;
    font-size: 14px;
}

.description-features {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.feature {
    color: #bd8a3e;
    font-size: 14px;
}

.feature i {
    margin-right: 8px;
}

/* Секретная кнопка */
.secret-admin-btn {
    width: 100%;
    height: 8px;
    background: transparent;
    cursor: pointer;
    margin-top: 12px;
    border-radius: 4px;
}

.secret-admin-btn:hover {
    background: rgba(189, 138, 62, 0.15);
}

/* ============ АДМИН-ПАНЕЛЬ ============ */
.admin-controls {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: linear-gradient(135deg, #0f1a0f 0%, #0a120a 100%);
    border: 2px solid #bd8a3e;
    border-radius: 24px;
    max-width: 550px;
    width: 90%;
    z-index: 2000;
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
    overflow: hidden;
    animation: adminSlideIn 0.3s ease;
    display: flex;
    flex-direction: column;
}

@keyframes adminSlideIn {
    from {
        opacity: 0;
        transform: translate(-50%, -40%);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%);
    }
}

/* Заголовок */
.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    background: linear-gradient(135deg, #1a2a1a 0%, #0f1a0f 100%);
    border-bottom: 2px solid #bd8a3e;
    flex-shrink: 0;
}

.admin-header h3 {
    color: #ffd966;
    margin: 0;
    font-size: 1.3rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.admin-header h3 i {
    color: #bd8a3e;
    font-size: 1.4rem;
}

.close-admin-btn {
    background: rgba(189, 138, 62, 0.2);
    border: none;
    color: #bd8a3e;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-admin-btn:hover {
    background: #bd8a3e;
    color: #0f1a0f;
    transform: scale(1.05);
}

/* Кнопки (под заголовком) */
.admin-buttons {
    display: flex;
    gap: 15px;
    padding: 20px 25px;
    background: #0d150d;
    border-bottom: 1px solid #2a3a2a;
    flex-wrap: wrap;
    flex-shrink: 0;
}

.admin-btn {
    background: #1e2e1e;
    border: 1px solid #bd8a3e;
    color: #ffd966;
    padding: 10px 24px;
    border-radius: 40px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
}

.admin-btn:hover {
    background: #bd8a3e;
    color: #0f1a0f;
    transform: scale(1.02);
}

.admin-btn i {
    font-size: 0.9rem;
}

/* Список песен (под кнопками) */
.admin-songs-list {
    flex: 1;
    max-height: 400px;
    overflow-y: auto;
    padding: 15px 20px;
}

/* Заголовки списка */
.admin-list-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    margin-bottom: 10px;
    background: #1a2a1a;
    border-radius: 12px;
    font-size: 0.7rem;
    color: #8aa07a;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Карточка песни в админ-панели */
.admin-song-item {
    background: #1a2a1a;
    border-radius: 16px;
    padding: 15px;
    margin-bottom: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s;
    border: 1px solid #2a3a2a;
}

.admin-song-item:hover {
    background: #1e2e1e;
    border-color: #bd8a3e;
    transform: translateX(5px);
}

/* Информация о песне */
.admin-song-info {
    flex: 1;
    overflow: hidden;
}

.admin-song-title {
    font-weight: bold;
    color: #ffd966;
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.admin-song-artist {
    font-size: 0.8rem;
    color: #8aa07a;
    margin-top: 4px;
}

.admin-song-meta {
    display: flex;
    gap: 12px;
    margin-top: 6px;
    font-size: 0.7rem;
}

.admin-song-duration {
    color: #bd8a3e;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.admin-song-type {
    background: #0d150d;
    padding: 2px 8px;
    border-radius: 20px;
    color: #4caf50;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.7rem;
}

.admin-song-type.base64 {
    color: #ff9800;
}

.admin-song-type.url {
    color: #2196f3;
}

/* Кнопки действий */
.admin-song-actions {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

.edit-song-btn, .delete-song-btn {
    background: #0d150d;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}

.edit-song-btn {
    color: #4caf50;
}

.edit-song-btn:hover {
    background: #4caf50;
    color: #0f1a0f;
    transform: scale(1.05);
}

.delete-song-btn {
    color: #bd8a3e;
}

.delete-song-btn:hover {
    background: #f44336;
    color: white;
    transform: scale(1.05);
}

/* Пустое состояние */
.admin-empty {
    text-align: center;
    padding: 40px 20px;
    background: #1a2a1a;
    border-radius: 16px;
    color: #8aa07a;
}

.admin-empty i {
    font-size: 3rem;
    margin-bottom: 15px;
    display: block;
    color: #bd8a3e;
}

/* Счётчик песен */
.admin-stats {
    padding: 12px 20px;
    background: #0d150d;
    border-top: 1px solid #2a3a2a;
    font-size: 0.75rem;
    color: #8aa07a;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.admin-stats span {
    color: #ffd966;
    font-weight: bold;
}

/* Скроллбар */
.admin-songs-list::-webkit-scrollbar {
    width: 6px;
}

.admin-songs-list::-webkit-scrollbar-track {
    background: #1c2a1c;
    border-radius: 10px;
}

.admin-songs-list::-webkit-scrollbar-thumb {
    background: #bd8a3e;
    border-radius: 10px;
}

/* Адаптация для мобильных */
@media (max-width: 600px) {
    .admin-controls {
        width: 95%;
        max-height: 90vh;
    }
    
    .admin-song-item {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }
    
    .admin-song-actions {
        width: 100%;
        justify-content: flex-end;
    }
    
    .admin-buttons {
        justify-content: center;
    }
    
    .admin-header h3 {
        font-size: 1.1rem;
    }
}

/* Модальные окна */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.95);
    z-index: 2000;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background: #0f1a0f;
    border: 2px solid #bd8a3e;
    border-radius: 24px;
    padding: 30px;
    max-width: 400px;
    width: 90%;
    position: relative;
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 28px;
    cursor: pointer;
    color: #bd8a3e;
}

.modal-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.modal-tab {
    flex: 1;
    padding: 10px;
    background: #1e2e1e;
    border: none;
    color: #8aa07a;
    cursor: pointer;
    border-radius: 10px;
}

.modal-tab.active {
    background: #bd8a3e;
    color: #0a120a;
}

.auth-form h3 {
    color: #ffd966;
    margin-bottom: 15px;
    text-align: center;
}

.auth-input {
    width: 100%;
    padding: 12px;
    margin: 10px 0;
    background: #1e2e1e;
    border: 1px solid #3e5a3e;
    border-radius: 12px;
    color: #fff;
    font-size: 14px;
}

.auth-input:focus {
    outline: none;
    border-color: #bd8a3e;
}

.auth-btn {
    width: 100%;
    padding: 12px;
    background: #bd8a3e;
    border: none;
    border-radius: 12px;
    color: #0a120a;
    font-weight: bold;
    cursor: pointer;
    margin: 10px 0;
}

.auth-btn.google {
    background: #db4437;
    color: white;
}

.auth-divider {
    text-align: center;
    margin: 15px 0;
    color: #8aa07a;
}

/* Модальное окно добавления песни */
.modal-add-song {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.95);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.modal-add-song-content {
    background: #0f1a0f;
    padding: 30px;
    border-radius: 24px;
    max-width: 500px;
    width: 90%;
    border: 2px solid #bd8a3e;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-add-song-content h3 {
    color: #ffd966;
    margin-bottom: 20px;
    text-align: center;
}

.modal-add-song-content input,
.modal-add-song-content textarea {
    width: 100%;
    padding: 10px 15px;
    margin: 10px 0;
    background: #1e2a1e;
    border: 1px solid #3e5a3e;
    color: #ddd;
    border-radius: 12px;
    font-size: 14px;
}

/* Загрузка файла */
.file-upload-area {
    border: 2px dashed #bd8a3e;
    border-radius: 16px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    background: #1e2a1e;
    margin-bottom: 15px;
}

.file-upload-area:hover {
    background: #2a3a2a;
    border-color: #ffd966;
}

.file-upload-area i {
    font-size: 32px;
    color: #bd8a3e;
    margin-bottom: 8px;
}

.file-hint {
    font-size: 10px;
    color: #8aa07a;
}

.upload-divider {
    text-align: center;
    margin: 15px 0;
    position: relative;
}

.upload-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #3e5a3e;
}

.upload-divider span {
    background: #0f1a0f;
    padding: 0 15px;
    position: relative;
    color: #8aa07a;
    font-size: 11px;
}

.selected-file-name {
    font-size: 11px;
    color: #4caf50;
    text-align: center;
    margin-top: 8px;
    padding: 5px;
    background: #1e2a1e;
    border-radius: 8px;
}

.upload-progress {
    margin: 15px 0;
}

.progress-bar-small {
    height: 4px;
    background: #3e5a3e;
    border-radius: 2px;
    overflow: hidden;
}

.progress-fill-small {
    height: 100%;
    background: #4caf50;
    width: 0%;
    transition: width 0.3s;
}

/* Состояния */
.loading-spinner {
    text-align: center;
    padding: 50px;
    color: #ffd966;
}

.empty-music {
    text-align: center;
    padding: 50px;
    color: #8aa07a;
}

/* Toast уведомление */
.toast-message {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: #0f1a0f;
    color: #ffd966;
    padding: 12px 24px;
    border-radius: 50px;
    border: 1px solid #bd8a3e;
    z-index: 3000;
    font-size: 14px;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateX(-50%) translateY(20px); }
    to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

/* Адаптация */
@media (max-width: 768px) {
    .player-bar {
        flex-direction: column;
        gap: 10px;
    }
    
    .player-progress {
        width: 100%;
    }
    
    .music-card {
        flex-direction: column;
        text-align: center;
    }
    
    .toast-message {
        white-space: normal;
        text-align: center;
        max-width: 90%;
    }
    
    .description-features {
        gap: 15px;
    }
}

/* Модальное окно текста песни */
.lyrics-modal .modal-content {
    max-width: 500px;
    max-height: 80vh;
    overflow-y: auto;
}

.lyrics-text {
    white-space: pre-wrap;
    line-height: 1.6;
    font-size: 0.95rem;
    color: #ddd;
    margin-top: 20px;
    padding: 15px;
    background: #1a2a1a;
    border-radius: 12px;
    max-height: 500px;
    overflow-y: auto;
}

/* Стиль для иконки текста песни */
.has-lyrics {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #1e2a1e;
    padding: 2px 8px;
    border-radius: 20px;
    font-size: 0.7rem;
    color: #bd8a3e;
    margin-left: 8px;
}

.has-lyrics i {
    font-size: 0.7rem;
}

/* Кнопка текста в плеере */
#lyricsBtn {
    background: #2a3a2a;
    border: 1px solid #bd8a3e;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    color: #ffd966;
    font-size: 16px;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

#lyricsBtn:hover {
    background: #bd8a3e;
    color: #0f1a0f;
    transform: scale(1.05);
}

#lyricsBtn i {
    font-size: 1rem;
}
