* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Roboto', sans-serif;
}

body {
    background-color: #f0f0f0;
    color: #333;
    line-height: 1.6;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background-color: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* Section Headers */
.section-header {
    background-color: #0055a5;
    color: white;
    padding: 10px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.section-header h2 {
    font-size: 18px;
    font-weight: 500;
    margin: 0;
}

.section-content {
    padding: 15px;
    border-bottom: 1px solid #e0e0e0;
}

/* Input Rows */
.input-row {
    display: flex;
    margin-bottom: 15px;
}

.input-row:last-child {
    margin-bottom: 0;
}

.input-label {
    width: 150px;
    padding: 8px 0;
    font-weight: 500;
}

.input-field {
    flex: 1;
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    padding: 8px 12px;
    position: relative;
}

.input-field input[type="file"] {
    width: 100%;
}

/* Info Note */
.info-note {
    margin-top: 15px;
    padding: 10px;
    background-color: #e0f0ff;
    border-left: 4px solid #0055a5;
    font-size: 14px;
}

.info-note p {
    margin: 0;
}

/* Dropdown Select */
.dropdown-select {
    width: 100%;
    padding: 8px;
    border: none;
    background-color: transparent;
    font-size: 14px;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="12" height="6" viewBox="0 0 12 6"><path d="M0 0l6 6 6-6z" fill="%23666"/></svg>');
    background-repeat: no-repeat;
    background-position: right 10px center;
    cursor: pointer;
}

.dropdown-select:focus {
    outline: none;
}

/* Checkbox */
.checkbox-row {
    margin-bottom: 15px;
}

.checkbox-container {
    display: flex;
    align-items: center;
    position: relative;
    padding-left: 35px;
    cursor: pointer;
    user-select: none;
}

.checkbox-container input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    position: absolute;
    left: 0;
    height: 20px;
    width: 20px;
    background-color: #f5f5f5;
    border: 1px solid #ddd;
}

.checkbox-container:hover input ~ .checkmark {
    background-color: #e0e0e0;
}

.checkbox-container input:checked ~ .checkmark {
    background-color: #0055a5;
    border-color: #0055a5;
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.checkbox-container input:checked ~ .checkmark:after {
    display: block;
    left: 7px;
    top: 3px;
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.checkbox-label {
    font-weight: 400;
}

/* Buttons */
.action-btn, .reset-btn {
    padding: 5px 15px;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
}

.action-btn {
    background-color: #f0f0f0;
    color: #333;
}

.action-btn:hover {
    background-color: #e0e0e0;
}

.action-btn:disabled {
    background-color: #ccc;
    color: #666;
    cursor: not-allowed;
}

.reset-btn {
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
}

.reset-btn:hover {
    background-color: rgba(255, 255, 255, 0.3);
}

/* Make Convert button more prominent */
#convert-btn {
    background-color: #ff5500;
    color: white;
    font-size: 16px;
    font-weight: 600;
    padding: 8px 25px;
    transition: background-color 0.2s;
}

#convert-btn:hover {
    background-color: #ff7733;
}

#convert-btn:disabled {
    background-color: #ffaa88;
    color: #ffffff;
}

/* Progress Bar */
.progress-container {
    display: flex;
    align-items: center;
    margin-top: 20px;
}

.progress-bar {
    flex-grow: 1;
    height: 20px;
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    margin-right: 10px;
    overflow: hidden;
}

.progress {
    height: 100%;
    background-color: #0055a5;
    width: 0%;
    transition: width 0.3s;
}

#progress-text {
    min-width: 40px;
    text-align: right;
    font-size: 14px;
}

/* Results Grid */
.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 10px;
}

.cdl-file {
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    padding: 10px;
    display: flex;
    flex-direction: column;
    cursor: pointer;
}

.cdl-file.selected {
    background-color: #e0f0ff;
    border-color: #0055a5;
}

.cdl-file-name {
    margin-bottom: 5px;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cdl-file-actions {
    display: flex;
    justify-content: flex-end;
}

.cdl-file-actions a {
    color: #0055a5;
    text-decoration: none;
    font-size: 14px;
}

.cdl-file-actions a:hover {
    text-decoration: underline;
}

/* Log Container */
.log-container {
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    padding: 10px;
    height: 150px;
    overflow-y: auto;
    font-family: monospace;
    font-size: 14px;
    white-space: pre-wrap;
}

/* Preview Section */
.preview-header {
    margin-top: 20px;
}

.preview-content {
    padding: 0;
}

.preview-panel {
    display: flex;
}

.preview-left {
    flex: 1;
    padding: 15px;
    border-right: 1px solid #e0e0e0;
}

.preview-right {
    width: 300px;
    padding: 15px;
    background-color: #f9f9f9;
}

.cdl-preview {
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    padding: 10px;
    height: 300px;
    overflow: auto;
    font-family: monospace;
    font-size: 14px;
    white-space: pre-wrap;
}

.info-row {
    display: flex;
    margin-bottom: 10px;
}

.info-label {
    width: 100px;
    font-weight: 500;
}

.info-value {
    flex: 1;
    font-family: monospace;
}

/* Footer */
footer {
    max-width: 1200px;
    margin: 10px auto 0;
    padding: 10px 15px;
    background-color: #f5f5f5;
    border-top: 1px solid #ddd;
    font-size: 14px;
    color: #666;
}

.footer-content {
    display: flex;
    justify-content: space-between;
}