html, body {
    background: #333;
    color: #fff;
    margin: 0;
    padding: 0;
    height: 100%;
    min-height: 100%;
}

body {
    background: #333;
    color: #fff;
    margin: 0;
    padding: 0;
    min-height: 100vh;
}

body.gallery-background {
    background: #1a1a1a; /* Neutral dark background for gallery */
    color: #fff;
    height: 100%;
    min-height: 100vh;
    margin: 0;
    padding: 0;
}

.gallery-container {
    padding: 2em;
    background: rgba(0, 0, 0, 0.8);
    color: #fff;
    margin-top: 100px;
    flex: 1 0 auto;
}

.gallery-section {
    margin-bottom: 4em;
}

.gallery-title {
    font-size: 2em;
    margin-bottom: 1em;
}

.gallery-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

.gallery-item {
    margin: 1em;
    width: 320px;
    height: 320px;
    overflow: hidden;
    border-radius: 10px;
    cursor: pointer;
    transition: transform 0.3s;
    text-align: center;
}

.gallery-item img,
.gallery-item video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-item:hover {
    transform: scale(1.1);
}

.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80%;
    max-width: 800px;
    background: #222;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.8);
    z-index: 1000;
    display: none;
}

.modal img,
.modal video {
    width: 100%;
    height: auto;
}

.modal-content {
    margin-bottom: 20px;
}

.modal-close {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 2em;
    color: #fff;
    cursor: pointer;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 999;
    display: none;
}

.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}

.lightbox img {
    max-width: 90%;
    max-height: 90%;
}

.lightbox:target {
    opacity: 1;
    visibility: visible;
}

.close {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 2em;
    color: #fff;
    text-decoration: none;
}

.prev, .next {
    position: absolute;
    top: 50%;
    font-size: 2em;
    color: #fff;
    text-decoration: none;
    padding: 0.5em;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    cursor: pointer;
}

.prev {
    left: 20px;
}

.next {
    right: 20px;
}
