/* 基础播放器示例样式 */
.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

h1 {
    text-align: center;
    color: #333;
    margin-bottom: 30px;
}

h2, h3 {
    color: #555;
    margin-bottom: 15px;
}

.player-section {
    margin-bottom: 30px;
}

.player-container {
    background: #000;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    margin-bottom: 20px;
}

.controls-section {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.controls {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.controls button {
    padding: 10px 16px;
    border: none;
    border-radius: 6px;
    background: #007bff;
    color: white;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.2s;
}

.controls button:hover:not(:disabled) {
    background: #0056b3;
}

.controls button:disabled {
    background: #6c757d;
    cursor: not-allowed;
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 10px;
}

.volume-control label {
    font-weight: 500;
    color: #555;
}

.volume-control input[type="range"] {
    flex: 1;
    max-width: 200px;
}

.volume-control span {
    font-weight: 500;
    color: #007bff;
    min-width: 40px;
}

.info-section {
    background: #fff;
    border: 1px solid #dee2e6;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

#player-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 10px;
}

#player-info p {
    margin: 5px 0;
    padding: 8px;
    background: #f8f9fa;
    border-radius: 4px;
    font-size: 14px;
}

#player-info span {
    font-weight: 600;
    color: #007bff;
}

.keyboard-section {
    background: #e9ecef;
    padding: 20px;
    border-radius: 8px;
}

.keyboard-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.keyboard-section li {
    padding: 8px 0;
    border-bottom: 1px solid #dee2e6;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.keyboard-section li:last-child {
    border-bottom: none;
}

kbd {
    background: #495057;
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 12px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .controls {
        justify-content: center;
    }
    
    .controls button {
        flex: 1;
        min-width: 80px;
    }
    
    #player-info {
        grid-template-columns: 1fr;
    }
    
    .keyboard-section li {
        flex-direction: column;
        gap: 5px;
        text-align: center;
    }
}

/* 加载状态 */
.loading {
    position: relative;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    margin: -20px 0 0 -20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 错误状态 */
.error {
    background: #f8d7da;
    color: #721c24;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
}

.error h3 {
    color: #721c24;
    margin-bottom: 10px;
}

/* 全屏状态样式调整 */
.player-container:-webkit-full-screen {
    width: 100vw;
    height: 100vh;
    border-radius: 0;
}

.player-container:-moz-full-screen {
    width: 100vw;
    height: 100vh;
    border-radius: 0;
}

.player-container:fullscreen {
    width: 100vw;
    height: 100vh;
    border-radius: 0;
}
