/* General Styles */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: #121212;
    color: #e0e0e0;
    margin: 0;
    line-height: 1.6;
}

header {
    background-color: #1f1f1f;
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #333;
}

h1 {
    font-size: 2rem;
    margin: 0;
}

nav a {
    color: #e0e0e0;
    text-decoration: none;
    margin-left: 1rem;
    font-size: 1.1rem;
    transition: color 0.3s ease;
}

nav a:hover {
    color: #bb86fc;
}

main {
    padding: 2rem;
}

/* Forms */
form {
    background-color: #1f1f1f;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

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

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: bold;
}

input[type="text"], input[type="file"], select {
    width: 100%;
    padding: 0.8rem;
    background-color: #333;
    border: 1px solid #444;
    color: #e0e0e0;
    border-radius: 4px;
}

button, input[type="submit"], .secondary-button {
    background-color: #bb86fc;
    color: #121212;
    padding: 0.8rem 1.5rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.3s ease;
    margin-right: 10px;
}

button:hover, input[type="submit"]:hover, .secondary-button:hover {
    background-color: #a063e0;
}

.secondary-button {
    background-color: #333;
    color: #e0e0e0;
}

.secondary-button:hover {
    background-color: #444;
}

/* Gallery */
.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.design-card {
    background-color: #1f1f1f;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.design-card:hover {
    transform: translateY(-5px);
}

.design-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.design-card h3 {
    padding: 1rem;
    margin: 0;
}

.design-card p {
    padding: 0 1rem 1rem;
    margin: 0;
    color: #aaa;
}

/* Filters */
.filters ul {
    list-style: none;
    padding: 0;
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}

.filters li {
    background-color: #333;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.filters li:hover {
    background-color: #bb86fc;
    color: #121212;
}

/* Categories Page */
#category-list {
    list-style: none;
    padding: 0;
}

#category-list li {
    background-color: #1f1f1f;
    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: 4px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Upload Page */
#file-preview-table {
    width: 100%;
    margin-top: 2rem;
    border-collapse: collapse;
}

#file-preview-table th, #file-preview-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid #333;
    vertical-align: middle;
}

#file-preview-table th {
    background-color: #333;
}

#file-preview-table img {
    border-radius: 4px;
    object-fit: cover;
}

.progress-cell {
    min-width: 150px;
}

.progress-text {
    font-size: 0.9em;
    margin-left: 5px;
}

.action-cell {
    min-width: 120px;
    text-align: center;
}

progress {
    width: 100%;
    height: 8px;
    border-radius: 4px;
    overflow: hidden;
    border: none;
}

progress::-webkit-progress-bar {
    background-color: #333;
}

progress::-webkit-progress-value {
    background-color: #bb86fc;
    transition: width 0.1s linear;
}

.status.uploaded {
    color: #4caf50;
    font-weight: bold;
}

.status.remaining {
    color: #ffc107;
}

.status.error {
    color: #f44336;
    font-weight: bold;
    font-size: 0.9em;
}

/* Responsive Design */
@media (max-width: 768px) {
    header {
        flex-direction: column;
        align-items: flex-start;
    }

    nav {
        margin-top: 1rem;
    }

    nav a {
        margin-left: 0;
        margin-right: 1rem;
    }

    main {
        padding: 1rem;
    }

    .filters ul {
        flex-wrap: wrap;
    }
}
