body {
    font-family: sans-serif;
    margin: 0;
    background-color: #f4f4f4;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding-top: 20px;
    min-height: 100vh;
}

.editor-container {
    display: flex;
    background-color: #fff;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    border-radius: 8px;
    overflow: hidden;
}

.controls {
    width: 300px;
    padding: 20px;
    border-right: 1px solid #ddd;
    background-color: #f9f9f9;
}

.controls h2 {
    margin-top: 0;
    text-align: center;
    color: #333;
}

.control-group {
    margin-bottom: 20px;
}

.control-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #555;
}

.control-group input[type="file"],
.control-group input[type="text"],
.control-group button {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    box-sizing: border-box;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.control-group input[type="text"] {
    margin-bottom: 5px; /* Reduce margin for text input if button is directly below */
}

.control-group button {
    background-color: #007bff;
    color: white;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.control-group button:hover {
    background-color: #0056b3;
}

.control-group button#aspect-ratio-4-3,
.control-group button#aspect-ratio-3-4 {
    width: calc(50% - 5px); /* Adjust width for two buttons side-by-side */
    display: inline-block;
}

.control-group button#aspect-ratio-4-3 {
    margin-right: 5px;
}

.canvas-area {
    padding: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    /* background-color: #e0e0e0; */ /* Optional: to see canvas boundaries easily */
}

#cover-canvas {
    border: 1px dashed #999;
    /* Dimensions will be set by JavaScript based on selected aspect ratio */
}

/* 图片选择按钮样式 */
.image-selection {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.image-option {
    flex: 1;
    padding: 8px 12px;
    border: 2px solid #ddd;
    background-color: #fff;
    color: #666;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.image-option:hover {
    border-color: #007bff;
    color: #007bff;
}

.image-option.active {
    border-color: #007bff;
    background-color: #007bff;
    color: white;
}

#custom-upload-section {
    padding: 10px;
    background-color: #f8f9fa;
    border-radius: 4px;
    border: 1px solid #e9ecef;
}

#custom-upload-section label {
    font-size: 14px;
    margin-bottom: 5px;
} 