/* CSS Reset - Critical for consistent sizing */
*, *::before, *::after {
    box-sizing: border-box;
}

/* Gallery Styles for HTML5 UP Multiverse Template Implementation */
/* Override main.css to enable scrolling */
html, body {
    height: auto !important;
    overflow: auto !important;
}

body {
    font-family: 'Source Sans Pro', Helvetica, Arial, sans-serif;
    background: #1a1a1a;
    margin: 0;
    padding: 0;
    width: 100%;
    overflow-x: hidden;
}

/* Ensure main container fills full width */
#main {
    display: flex;
    flex-wrap: wrap;
    padding-top: 80px;
    width: 100%;
}

/* Custom Header (preserved from current design) */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 60px;
    background: rgba(43, 43, 43, 0.98); /* fallback */
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 40px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* Modern browsers get the enhanced version */
@supports (backdrop-filter: blur(10px)) {
    header {
        background: linear-gradient(135deg, rgba(43, 43, 43, 0.98), rgba(30, 30, 30, 0.98));
        backdrop-filter: blur(10px);
    }
}

header h1 {
    font-size: 1.5em;
    font-weight: 300;
}

header h1 a {
    color: #fff;
    text-decoration: none;
    transition: color 0.3s;
}

header h1 a:hover {
    color: #D17A22;
}

header .back-link {
    color: #fff;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: color 0.3s;
}

header .back-link:hover {
    color: #D17A22;
}

/* Responsive header adjustments */
@media screen and (max-width: 768px) {
    header {
        padding: 0 20px;
    }

    header h1 {
        font-size: 1.2em;
    }
}

/* Multiverse Template - Thumbnail Styles */

#main .thumb {
    position: relative;
    overflow: hidden;
    width: 25%;
    height: calc(40vh - 2em);
    min-height: 18em;
    cursor: pointer;
    transition: opacity 0.3s ease;
}

#main .thumb:after {
    background-image: linear-gradient(to top, rgba(10, 17, 25, 0.35) 5%, rgba(10, 17, 25, 0) 35%);
    pointer-events: none;
    background-size: cover;
    content: '';
    display: block;
    height: 100%;
    left: 0;
    position: absolute;
    top: 0;
    width: 100%;
    z-index: 1;
}

#main .thumb .image {
    border: 0;
    height: 100%;
    left: 0;
    position: absolute;
    top: 0;
    width: 100%;
    display: block;
}

#main .thumb .image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

#main .thumb:hover {
    opacity: 0.8;
    z-index: 2;
}

/* Responsive Breakpoints */
@media screen and (max-width: 1680px) {
    #main .thumb {
        width: 33.33333%;
    }
}

@media screen and (max-width: 1280px) {
    #main .thumb {
        width: 50%;
    }
}

@media screen and (max-width: 768px) {
    #main .thumb {
        width: 50%;
        height: calc(30vh - 2em);
        min-height: 15em;
    }
}

@media screen and (max-width: 480px) {
    #main .thumb {
        width: 100%;
        height: calc(40vh - 2em);
    }
}
