main {
    display: flex;
    flex-direction: column;
    align-items: center;
}
.top-header {
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: var(--primary-color);
    color: var(--white-color);
    width: 100%;
    height: 100px;
    font-size: 16px;
    font-weight: 800;
    margin-bottom: 0;
}
.post {
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
    padding: 50px 0;
    width: 1050px;
    color: var(--black-color);
    background-color: var(--white-color);
}
.content {
    box-sizing: border-box;
    width: 100%;
    background-color: var(--light-gray-color);
    padding: 50px;
    margin-top: 50px;
    font-size: 18px;
    font-weight: 300;
    color: var(--post-text-color);
}
.content h2 {
    font-size: 22px;
    font-weight: 400;
}
hr {
    width: 100px;
    border: 1px solid var(--primary-color);
    margin: 0;
}
h1 {
    font-size: 32px;
    font-weight: 400;
}
img {
    width: 500px;
    height: auto;
}
.row {
    display: flex;
    justify-content: space-between;
}
.hidden {
    display: none;
}

.video-preview, iframe {
    width: 100%;
    height: 500px;
    background-color: var(--light-gray-color);
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}
.map-preview {
    width: 100%;
    height: 500px;
    background-color: var(--light-gray-color);
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}
.post > h2 {
    font-size: 28px;
    font-weight: 400;
    line-height: 26px;
    margin-top: 50px;
}


.gallery-container {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.main-display {
    position: relative;
    width: 100%;
    height: auto;
    overflow: hidden;
}

.main-display img {
    width: 100%;
    height: 600px;
    object-fit: cover;
    top: 0;
    left: 0;
    transition: opacity 0.5s ease-in-out; /* Only transition opacity */
}

.main-display img.fade-in {
    opacity: 0; /* Start hidden */
}

.main-display img.fade-in-active {
    opacity: 1; /* Fade in */
}

.main-display img.fade-out-active {
    opacity: 0; /* Fade out */
}

#button-previous, #button-next {
    box-sizing: border-box;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 20px 10px;
    cursor: pointer;
    font-size: 28px;
    z-index: 100;
    transition: color, background-color 0.3s;
}

#button-previous {
    left: 0;
    border-radius: 0 20px 20px 0;
}

#button-next {
    right: 0;
    border-radius: 20px 0 0 20px;
}
#button-previous:hover, #button-next:hover {
    background-color: var(--light-gray-color);
    color: var(--black-color);
}

.thumbnail-container {
    display: flex;
    justify-content: center;
    margin-top: 10px;
    flex-wrap: wrap;
    gap: 10px;
}

.thumbnail {
    width: 100px;
    height: 75px;
    margin: 0 5px;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.3s;
}

.thumbnail:hover, .thumbnail.active {
    box-sizing: border-box;
    opacity: 1;
}

/** responsivity **/

@media screen and (max-width: 1240px) {
    .post {
        width: 100%;
        align-items: center;
        gap: 50px;
        margin-bottom: 50px;
    }
    .post > h2 {
        margin-top: 0;
        margin: 20px 0;
    }
    .content {
        padding: 50px;
    }
    img {
        width: 100%;
    }
    .video-preview, .map-preview {
        height: 400px;
        margin: 50px 0;
    }
    .gallery-container {
        width: 100%;
    }
    .thumbnail {
        width: 75px;
        height: 50px;
    }
    .thumbnail-container {
        overflow-x: auto;
    }
    .thumbnail-container::-webkit-scrollbar {
        display: none;
    }
}
@media screen and (max-width: 1060px) {
    img {
        width: 100%;
    }
    .main-display img {
        width: 100%;
        height: auto;
    }
}
@media screen and (max-width: 570px) {
    .content h2:nth-child(1) {
        display: none;
    }
    .content {
        padding: 25px;
    }
    .row {
        justify-content: center;
    }
}
