body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    color: #fff;
    background-color: #1a1a1a; 
}

canvas {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    /* z-index: -1; */ /* Removed to fix visibility issue */
}

#ui-container {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 1; /* Ensure menu is on top of the canvas */
    background: rgba(0, 0, 0, 0.5);
    padding: 15px 25px;
    border-radius: 10px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

h1 {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.5em;
}

.control-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

label {
    font-weight: bold;
}

select {
    padding: 5px;
    border-radius: 5px;
    border: 1px solid #555;
    background: #333;
    color: #fff;
    font-family: inherit;
}

#gamut-controls button {
    padding: 5px 10px;
    border-radius: 5px;
    border: 1px solid #555;
    background: #333;
    color: #fff;
    cursor: pointer;
}

#video-controls {
    align-items: center;
}

#video-controls button {
    padding: 5px 10px;
    border-radius: 5px;
    border: 1px solid #555;
    background: #333;
    color: #fff;
    cursor: pointer;
}

#video-controls input[type="range"] {
    flex-grow: 1;
    margin: 0 10px;
}

#video-controls.hidden {
    display: none;
}

#gamut-controls.hidden {
    display: none;
}

#file-bin-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1; /* Ensure it's on top of the canvas */
    width: 300px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    overflow: hidden;
    transition: height 0.3s ease;
    height: 120px; /* Default height */
}

#file-bin-container.collapsed {
    height: 38px; /* Height of the header */
}

#file-bin-header {
    padding: 10px;
    font-weight: bold;
    cursor: pointer;
    background: rgba(255, 255, 255, 0.1);
}

#file-bin-list {
    list-style: none;
    margin: 0;
    padding: 10px;
    display: flex;
    gap: 10px;
    overflow-x: auto;
}

#file-bin-list li img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 5px;
    cursor: pointer;
    border: 2px solid transparent;
}

#file-bin-list li img.active {
    border-color: #4a90e2;
}

#video-preview-wrapper {
    padding: 10px;
}

#video-preview-wrapper.hidden {
    display: none;
}

#video-source {
    width: 100%;
    height: auto;
    border-radius: 5px;
}

#back-to-files-btn {
    width: 100%;
    padding: 8px;
    margin-top: 10px;
    border-radius: 5px;
    border: 1px solid #555;
    background: #333;
    color: #fff;
    cursor: pointer;
}
