/* --- START OF FILE css/controls.css --- */
.controls, .downloads { /* Keep this for overall margin */
    margin-top: 15px;
}

.upload-area {
    margin-bottom: 20px; /* Increased margin */
    padding: 15px;
    border: 2px dashed #ddd;
    border-radius: 4px;
    background-color: #f9f9f9;
}

.upload-area input[type="file"] {
    padding: 6px 12px;
    cursor: pointer;
    border-radius: 4px;
    background-color: #e9ecef;
    border: 1px solid #ced4da;
    color: #495057;
    display: inline-block;
    margin-bottom: 8px;
}

.upload-area input[type="file"]::file-selector-button {
    display:none;
}

.upload-area p {
    font-size: 0.9em;
    color: #777;
    margin-top: 5px;
}

.control-group {
    margin-bottom: 12px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center; /* Center items within the group */
    gap: 5px 10px; /* row-gap column-gap */
}

.control-group label {
    margin-right: 3px; /* Slightly reduced */
    text-align: right;
}

/* Specific control styling */
.controls .section-title {
    text-align: center;
    margin-top: 0;
    margin-bottom: 15px;
}

/* 角丸スライダー */
.controls .control-group label[for="borderRadiusSlider"] {
    min-width: 150px;
}
#borderRadiusSlider {
    width: 160px;
}
#radiusValueDisplay {
    min-width: 25px;
    text-align: left;
}

/* 土台レイヤーのプリセットとカスタム入力の調整 */
.controls .control-group label[for^="basePreset"],
.controls .control-group label[for^="baseCustom"] {
    min-width: 90px;
}
.controls .control-group select[id^="basePreset"] {
    min-width: 100px;
    margin-right: 5px; /* Reduced from 10px */
}
.controls .control-group input[type="number"][id^="baseCustom"] {
    width: 70px;
}

/* 画像レイヤーの割合スライダー */
.controls .control-group label[for="imageLayerScalePercentage"] {
    min-width: 130px;
}
#imageLayerScalePercentage {
    width: 150px;
    margin: 0 5px;
}
#imageLayerScaleDisplay {
    min-width: 35px;
    text-align: left;
}
/* +/- ボタンのスタイル */
.scale-btn {
    width: 30px;
    height: 30px;
    border-radius: 4px;
    background-color: #e9ecef;
    border: 1px solid #ced4da;
    color: #495057;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}
.scale-btn:hover:not(:disabled) {
    background-color: #d1d7dc;
}
.scale-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}
.controls .control-group label[for^="imageLayerResize"]{
    min-width: 60px;
}
.controls .control-group input[type="number"][id^="imageLayerResize"] {
    width: 70px;
}

.control-group input[type="checkbox"] + label {
    margin-left: 2px; /* Space between checkbox and its label */
    text-align: left;
}
/* --- END OF FILE css/controls.css --- */