/* ========================
   Tile Layout
======================== */


.row-adjust {
    width: 24px;
    height: 24px;
    margin-right: 4px;
    font-weight: bold;
    cursor: pointer;
    align-self: center;
}
.tile-row {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
}


.tile {
    width: 100px;   /* tile width */
    height: 120px;   /* tile height */
    background-color: #f9f9f9;
    border: 2px solid #999;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 6px;
}

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

.tile-spacer {
    width: 50px; /* half tile width */
}

/* ========================
   File Input (hidden)
======================== */
#image-upload {
    display: none;
}

/* ========================
   Parent Container (sidebar + tiles)
======================== */
#app {
    display: flex;
    gap: 10px;
    
    
}

body {
    background-color: blue;
    color: white;
    font-family: Arial, Helvetica, sans-serif;
}

select {
    font-size: 1em;
    padding: 4px;
    margin: 6px;
    background-color: blue;
    color: white;
    border: 1px solid #ccc;
}


/* ========================
   Sidebar
======================== */
#sidebar {
    width: 220px;      /* fixed width */
    flex-shrink: 0;    /* prevent shrinking */
    height: 100%;
    display: flex;
    flex-direction: column; /* vertical layout */
    padding: 5px;
    border: 1px solid #ccc;
    box-sizing: border-box;
}

/* Sidebar title */
#sidebar h3 {
    margin: 0 0 5px 0;
    font-size: 1em;
}

/* Upload button container */
#upload-container {
    margin-bottom: 10px;
    text-align: left;
}

/* Upload button styling */
button {
    margin: 6px;
    padding: 4px 8px;
    font-size: 0.9em;
//    border-radius: 4px;
    border: 1px solid #ccc;
    background-color: #0000dd;
    cursor: pointer;
    color: white;
}

button:hover {
    background-color: #0000ff
}

/* Sidebar images grid */


#sidebar-images {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-content: flex-start; /* 🔑 THIS FIXES THE BIG GAPS */
    min-height: 640px;
    border: 1px solid gray;
}


#sidebar-images img {
    width: calc(50% - 4px); /* two per row */
    height: 100px;
    cursor: grab;
    
}

/* ========================
   Tile container
======================== */
#tile-container {
    flex: 1;  /* fills remaining horizontal space */
    padding: 10px;
    display: flex;
    flex-direction: column;
}
