* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.auth-section {
    position: absolute; 
    top: 20px;
    right: 20px;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #ff9137 0%, #ef4f59 100%);
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    overflow: hidden;
}

.header {
    background: linear-gradient(135deg, #ff9137 0%, #ef4f59 100%);
    color: white;
    padding: 60px 30px 30px 30px;
    text-align: center;
    position: relative; 
}

.header-logo {
    width: 500px;
    max-width: 90%;
    height: auto;
    margin-bottom: 10px;
}

.header h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
}

.content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    padding: 30px;
}

.right-column-stack {
    display: flex;
    flex-direction: column;
    gap: 30px;
}


.form-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.color-input-container {
    display: flex;
    align-items: center;
    /* Optional: Style the container to match your existing form boxes */
    border: 1px solid #ccc;
    border-radius: 5px;
    padding: 5px;
    background-color: #fff;
    width: fit-content; /* Adjust width as needed */
}

.color-input-container input {
    /* Remove borders from the text input so it merges with the container box */
    border: none;
    outline: none;
    padding: 0 5px; /* Add slight padding */
    width: 80px; /* Control the width of the text input */
}

.color-input-container input[type="color"] {
    /* Style the color picker itself */
    width: 35px;
    height: 35px;
    border: none;
    padding: 0;
    cursor: pointer;
}

label {
    font-weight: 600;
    color: #333;
    font-size: 0.95em;
}

input, select {
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 1em;
    transition: border-color 0.3s;
}

input:focus, select:focus {
    outline: none;
    border-color: #667eea;
}

input[type="color"] {
    height: 50px;
    cursor: pointer;
}

input:disabled {
    background-color: #f5f5f5;
    cursor: not-allowed;
}

.checkbox-group {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 10px 0;
}

.checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.button-group {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

button {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
}

.btn-danger {
    background: #dc3545;
    color: white;
}

.btn-danger:hover {
    background: #c82333;
}

.preview-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.preview-box {
    border: 2px dashed #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f9f9f9;
}

.preview-canvas {
    max-width: 100%;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    image-rendering: pixelated;
}

.files-section {
    margin-top: 30px;
    padding: 30px;
    background: #f9f9f9;
    border-top: 2px solid #e0e0e0;
}

.files-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 15px;
}

.selection-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    width: 100%;
}

.settings-section {
    padding: 20px 0;
    border-bottom: 1px solid #e0e0e0;
}

.settings-section:last-child {
    border-bottom: none;
}

.settings-section h3 {
    margin-bottom: 15px;
    color: #333;
}

.settings-section .form-group {
    margin-bottom: 15px;
}

.settings-section label {
    display: flex;
    align-items: center;
    gap: 10px;
}

.files-header h2 {
    color: #333;
}

.file-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}

.file-item {
    display: flex;
    align-items: center;
    padding: 12px;
    background: white;
    border-radius: 6px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    cursor: pointer;
    transition: transform 0.2s;
}

.file-item input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
    margin-right: 10px;
}

.file-name {
    font-weight: 500;
    color: #333;
    flex: 1;
    margin-left: 10px;
}

.btn-delete {
    background: #dc3545;
    color: white;
    padding: 6px 12px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9em;
    transition: background 0.2s;
}

.btn-delete:hover {
    background: #c82333;
}

.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-content {
    display: none;
    position: absolute;
    bottom: 100%;
    left: 0;
    background-color: white;
    min-width: 200px;
    box-shadow: 0 -4px 12px rgba(0,0,0,0.15);
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 5px;
    z-index: 100;
}

.dropdown-content button {
    width: 100%;
    text-align: left;
    padding: 12px 16px;
    border: none;
    background: white;
    color: #333;
    cursor: pointer;
    font-size: 0.95em;
    transition: background 0.2s;
}

.dropdown-content button:hover {
    background: #f0f0f0;
}

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

.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background-color: white;
    margin: 15% auto;
    padding: 30px;
    border-radius: 8px;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
    animation: slideDown 0.3s;
}

@keyframes slideDown {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-buttons {
    display: flex;
    gap: 10px;
    margin-top: 20px;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.empty-state {
    text-align: center;
    color: #999;
    padding: 40px;
}

/* Image preview modal */
.image-preview-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.8);
    animation: fadeIn 0.3s;
}

.image-preview-content {
    position: relative;
    margin: 5% auto;
    max-width: 90%;
    max-height: 90%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-preview-content img {
    max-width: 100%;
    max-height: 85vh;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    image-rendering: pixelated;
}

.close-preview {
    position: absolute;
    top: -40px;
    right: 0;
    color: white;
    font-size: 35px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.2s;
}

.close-preview:hover {
    color: #ff6b6b;
}

/* @media (max-width: 1024px) {
    .header-logo {
        max-width: 200px;
    }
    
    .content {
        grid-template-columns: 1fr;
    }
    
    .files-header {
        flex-direction: column;
        align-items: flex-start;
    }
 }

@media (max-width: 600px) {
    .auth-section {
        position: static;
        margin-top: 15px;
        justify-content: center;
    }
 }

@media (max-width: 1024px) {
    .content {
        grid-template-columns: 1fr;
    }
    
    .files-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .auth-section {
        top: 15px;
        right: 15px;
    }
} */

@media (max-width: 1024px) {
    .content {
        grid-template-columns: 1fr;
    }
    
    .files-header {
        flex-direction: column;
        align-items: flex-start;
    }
}
