/* Resize Image Specific Styles */
.editor-area {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 3rem;
    align-items: flex-start;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

.options-panel {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 2rem;
}

.options-panel h3 {
    margin-bottom: 1.5rem;
    color: var(--primary-color);
}

/* Tabs */
.unit-tabs {
    display: flex;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    margin-bottom: 2rem;
    overflow: hidden;
}

.tab-link {
    flex: 1;
    padding: 0.8rem;
    background: none;
    border: none;
    color: var(--text-color-light);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.3s ease;
}

.tab-link.active {
    background: var(--primary-color);
    color: #fff;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.input-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-weight: 500;
    margin-bottom: 0.75rem;
    text-align: left;
}

.option-group-checkboxes {
    margin: 1.5rem 0;
    display: block;
}

.checkbox-wrapper {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.checkbox-wrapper input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary-color);
}

.options-panel hr {
    border: none;
    border-top: 1px solid var(--card-border);
    margin: 1.5rem 0;
}


.slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    outline: none;
    border-radius: 10px;
    cursor: pointer;
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    background: var(--primary-color);
    border-radius: 50%;
    border: 3px solid #fff;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.2);
}

.action-buttons {
    margin-top: 2rem;
}

.btn-link {
    background: none;
    border: none;
    color: var(--text-color-light);
    cursor: pointer;
    font-size: 0.9rem;
    text-decoration: underline;
    transition: color 0.3s ease;
    margin-top: 1rem;
    display: block;
    text-align: center;
    width: 100%;
}

.btn-link:hover {
    color: var(--primary-color);
}

/* Preview Panel */
.image-preview-panel {
    width: 100%;
    background: var(--card-bg);
    border-radius: 16px;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 400px;
    border: 1px solid var(--card-border);
}

.image-preview-panel p {
    color: var(--text-color-light);
    margin-bottom: 1rem;
}

.image-preview-panel p:last-child {
    margin-top: 1rem;
    margin-bottom: 0;
}

.image-preview-panel strong {
    color: var(--primary-color);
}

#image-preview {
    max-width: 100%;
    max-height: 70vh;
    object-fit: contain;
    border-radius: 6px;
    background-color: rgba(0, 0, 0, 0.2);
}

@media screen and (max-width: 900px) {
    .editor-area {
        grid-template-columns: 1fr;
    }

    .image-preview-panel {
        grid-row: 1;
        /* Show preview on top on mobile */
    }
}