/* Debug styles - make the grid more visible */
body {
    --grid-bg: #1a1a1a;
}

.image-grid-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    opacity: 0.7;
    overflow: hidden;
    background-color: var(--grid-bg);

}

.image-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    grid-template-rows: repeat(6, 1fr);
    width: 100%;
    height: 100%;
    grid-gap: 4px;
    padding: 4px;
}

.tile {
    position: relative;
    overflow: hidden;
    background-color: #1a1a1a;
    border-radius: 4px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Lighten grid images for better background contrast */
.tile img {
    filter: brightness(1.25) contrast(1.08);
    transition: filter 0.3s;
}

[data-theme="dark"] .tile img {
    filter: brightness(1.35) contrast(1.10);
}


.tile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease, filter 0.3s ease;
}

.tile:hover {
    z-index: 10;
    transform: scale(1.05);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.tile:hover img {
    transform: scale(1.1);
    filter: brightness(1.1);
}

/* Define different sized tiles */
.large {
    grid-column: span 2;
    grid-row: span 2;
}

.medium {
    grid-column: span 2;
    grid-row: span 1;
}

.tall {
    grid-column: span 1;
    grid-row: span 2;
}

/* Tile animations on page load */
@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.8); }
    to { opacity: 1; transform: scale(1); }
}

.tile {
    opacity: 0;
    animation: fadeIn 0.5s ease forwards;
}

/* Staggered animation delay for tiles */
.tile:nth-child(1) { animation-delay: 0.05s; }
.tile:nth-child(2) { animation-delay: 0.1s; }
.tile:nth-child(3) { animation-delay: 0.15s; }
.tile:nth-child(4) { animation-delay: 0.2s; }
.tile:nth-child(5) { animation-delay: 0.25s; }
.tile:nth-child(6) { animation-delay: 0.3s; }
.tile:nth-child(7) { animation-delay: 0.35s; }
.tile:nth-child(8) { animation-delay: 0.4s; }
.tile:nth-child(9) { animation-delay: 0.45s; }
.tile:nth-child(10) { animation-delay: 0.5s; }
.tile:nth-child(11) { animation-delay: 0.55s; }
.tile:nth-child(12) { animation-delay: 0.6s; }
.tile:nth-child(13) { animation-delay: 0.65s; }
.tile:nth-child(14) { animation-delay: 0.7s; }
.tile:nth-child(15) { animation-delay: 0.75s; }
.tile:nth-child(16) { animation-delay: 0.8s; }
.tile:nth-child(17) { animation-delay: 0.85s; }
.tile:nth-child(18) { animation-delay: 0.9s; }
.tile:nth-child(19) { animation-delay: 0.95s; }
.tile:nth-child(20) { animation-delay: 1s; }
.tile:nth-child(21) { animation-delay: 1.05s; }
.tile:nth-child(22) { animation-delay: 1.1s; }
.tile:nth-child(23) { animation-delay: 1.15s; }
.tile:nth-child(24) { animation-delay: 1.2s; }
.tile:nth-child(25) { animation-delay: 1.25s; }
