body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: #121212;
    color: #ffffff;
}

.header {
    padding: 1rem;
    text-align: center;
    font-size: 1.5rem;
    font-weight: bold;
}

.directory-form {
    display: flex;
    justify-content: center;
    padding: 1rem;
    background-color: #2a2a2a;
    border-radius: 10px;
    margin: 1rem;
}

.directory-form input {
    padding: 0.5rem;
    border: none;
    border-radius: 5px;
    margin-right: 0.5rem;
    flex: 1;
}

.directory-form button {
    padding: 0.5rem 1rem;
    background-color: #ffd700;
    color: black;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.section {
    padding: 1rem;
    margin: 0.5rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.section h2 {
    margin: 0;
    font-size: 1.2rem;
}

.arrow {
    font-size: 1.5rem;
}

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

.image-tile {
    position: relative;
    aspect-ratio: 1;
    border-radius: 10px;
    overflow: hidden;
    background-color: #2a2a2a;
}

.image-tile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.processed-indicator {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 24px;
    height: 24px;
    background-color: #ffd700;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: black;
    font-weight: bold;
    font-size: 14px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.create-collection {
    display: flex;
    align-items: center;
    padding: 1rem;
    background-color: #2a2a2a;
    border-radius: 10px;
    margin: 1rem;
    cursor: pointer;
    transition: background-color 0.2s;
}

.create-collection:hover {
    background-color: #3a3a3a;
}

.create-collection:hover .plus {
    transform: scale(1.1);
}

.create-collection .plus {
    width: 40px;
    height: 40px;
    background-color: #ffd700;
    border-radius: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin-right: 1rem;
    color: black;
    transition: transform 0.2s;
}

.process-button {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    padding: 1rem 2rem;
    background-color: #ffd700;
    color: black;
    border: none;
    border-radius: 25px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.collection {
    background-color: #2a2a2a;
    border-radius: 10px;
    margin: 1rem;
    padding: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.collection-preview {
    width: 60px;
    height: 60px;
    border-radius: 5px;
    overflow: hidden;
}

.collection-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.collection-info h3 {
    margin: 0;
    font-size: 1rem;
}

.collection-info p {
    margin: 0.2rem 0 0 0;
    font-size: 0.8rem;
    color: #888;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
}

.modal-content {
    position: relative;
    margin: auto;
    padding: 20px;
    width: 80%;
    max-width: 800px;
    background-color: #2a2a2a;
    border-radius: 10px;
    top: 50%;
    transform: translateY(-50%);
}

.close {
    position: absolute;
    right: 20px;
    top: 10px;
    color: #fff;
    font-size: 30px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover {
    color: #ffd700;
}

#modalImage {
    width: 100%;
    max-height: 60vh;
    object-fit: contain;
    border-radius: 5px;
}

.modal-info {
    margin-top: 20px;
    color: #fff;
}

/* Tag styles */
.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.tag {
    background-color: #ffd700;
    color: black;
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.9rem;
    font-weight: 500;
    display: inline-block;
}

/* Collection list in modal */
.collection-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.modal-collection {
    background-color: #3a3a3a;
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.9rem;
}

/* Collection Modal Styles */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: #fff;
    font-size: 0.9rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid #444;
    border-radius: 5px;
    background-color: #1a1a1a;
    color: #fff;
    font-family: inherit;
    font-size: 0.9rem;
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #ffd700;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 2rem;
}

.btn-cancel,
.btn-create {
    padding: 0.8rem 1.5rem;
    border: none;
    border-radius: 5px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-cancel {
    background-color: #3a3a3a;
    color: #fff;
}

.btn-create {
    background-color: #ffd700;
    color: black;
    font-weight: bold;
}

.btn-cancel:hover {
    background-color: #444;
}

.btn-create:hover {
    background-color: #ffed4a;
}

/* Collection page styles */
.back-button {
    position: absolute;
    left: 1rem;
    top: 1rem;
    padding: 0.5rem 1rem;
    background-color: #2a2a2a;
    border: none;
    border-radius: 5px;
    color: #fff;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.2s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.back-button:hover {
    background-color: #3a3a3a;
}

.collection-header {
    padding: 2rem 1rem;
    text-align: center;
    margin-bottom: 1rem;
}

.collection-header h1 {
    font-size: 2.5rem;
    margin: 0 0 1rem;
    color: #ffd700;
}

.collection-description {
    color: #888;
    font-size: 1.1rem;
    max-width: 800px;
    margin: 1rem auto;
    line-height: 1.5;
}

/* Collection assignment in modal */
.collection-assign {
    margin-top: 1rem;
    display: flex;
    gap: 0.5rem;
}

.collection-assign select {
    flex: 1;
    padding: 0.5rem;
    border: 1px solid #444;
    border-radius: 5px;
    background-color: #1a1a1a;
    color: #fff;
    font-family: inherit;
}

.btn-assign {
    padding: 0.5rem 1rem;
    background-color: #ffd700;
    color: black;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    transition: background-color 0.2s;
}

.btn-assign:hover {
    background-color: #ffed4a;
}

/* Collection page header styles */
.collection-header {
    text-align: center;
    padding: 3rem 1rem 2rem;
}

.collection-header h1 {
    font-size: 2.5rem;
    margin: 0 0 1rem;
}

.collection-header p {
    color: #888;
    font-size: 1.1rem;
    max-width: 800px;
    margin: 0 auto;
}

/* Tag Input Styles */
.tag-input-container {
    display: flex;
    margin-top: 10px;
    gap: 8px;
}

.tag-input-container input {
    flex: 1;
    padding: 8px;
    border: 1px solid #444;
    border-radius: 5px;
    background-color: #1a1a1a;
    color: #fff;
}

.tag-input-container input:focus {
    outline: none;
    border-color: #ffd700;
}

.tag-add-btn {
    background-color: #ffd700;
    color: black;
    border: none;
    border-radius: 5px;
    padding: 8px 12px;
    cursor: pointer;
    font-weight: bold;
}

.tag-add-btn:hover {
    background-color: #ffed4a;
}

.tag {
    background-color: #ffd700;
    color: black;
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    margin-right: 5px;
    margin-bottom: 5px;
}

.tag .remove-tag {
    margin-left: 5px;
    cursor: pointer;
    font-weight: bold;
}

.tag .remove-tag:hover {
    color: #ff4444;
}

/* Collection Checkbox Styles */
.collection-checkboxes {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin: 1rem 0;
}

.collection-checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem;
    background-color: #3a3a3a;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.collection-checkbox:hover {
    background-color: #444;
}

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

.collection-checkbox label {
    cursor: pointer;
    color: #fff;
    font-size: 0.9rem;
}

.btn-save {
    background-color: #ffd700;
    color: black;
    border: none;
    border-radius: 5px;
    padding: 0.5rem 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.2s;
    margin-top: 1rem;
    width: 100%;
}

.btn-save:hover {
    background-color: #ffed4a;
}