body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 200px 20px 20px 20px;
    background-color: #f5f5f5;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    height: auto;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.playlist {
    background-color: white;
    border-radius: 4px;
    padding: 15px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    overflow-y: auto;
    max-height: 300px;
    flex-grow: 1;
}

.player-container {
    width: 100%;
    background-color: #000;
    margin-bottom: 20px;
}

#videoPlayer {
    width: 100%;
    height: auto;
    max-height: 70vh;
}

/* 修改controls容器样式 */
.controls {
    display: flex;
    gap: 15px; /* 增加按钮间距 */
    margin-bottom: 20px;
    flex-wrap: wrap;
    align-items: center;
}

/* 修改播放列表按钮间距 */
.playlist {
    background-color: white;
    border-radius: 4px;
    padding: 10px 15px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    overflow-y: auto;
    max-height: 300px;
    /* 移除flex-grow */
    display: flex;
    margin: 10px 0;
    flex-wrap: wrap;
    gap: 15px;
    align-content: flex-start;
    /* 添加最小高度 */
    min-height: fit-content;
}

.playlist-item {
    padding: 10px;
    background-color: #818381;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    display: inline-block;
    min-width: 120px;
    white-space: nowrap;
    margin: 0 10px 10px 0; /* 添加上下间距15px */
    gap: 15px;
}

/* 其他按钮样式也做相应修改 */
button, .file-input-button {
    padding: 10px 15px;
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    display: inline-block;
    min-width: 80px;
    white-space: nowrap;
}

.playlist-item:hover {
    background-color: #45a049;
}

.playlist-item.active {
    background-color: #2E7D32;
    font-weight: bold;
}

@media (max-width: 600px) {
    .controls {
        flex-direction: column;
    }
    
    button {
        width: 100%;
    }
}