/* Case study tab section CSS */
/* ===== Tab navigation content ===== */

.main-container {
    position: relative;
}

.tab-nav-bar {
    position: relative;
    /* margin: 65px 10px 40px 10px; */
    margin: 30px 10px 5px 10px;
}

.tab-navigation {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: fit-content;
    margin: 0 auto;
}

.tab-menu {
    color: var(--text-color);
    list-style: none;
    background-color: var(--third-color);
    max-width: 800px;
    padding: 10px;
    white-space: nowrap;
    border-bottom: 1px solid var(--third-color);
    border-radius: 50px;
    box-shadow: var(--box-shadow);
    scroll-behavior: smooth;

    user-select: none;
    overflow-x: auto;
}

.tab-menu.dragging {
    scroll-behavior: unset;
    cursor: grab;
}

.tab-menu::-webkit-scrollbar {
    display: none;
}

.tab-btn {
    display: inline-block;
    color: var(--text-color);
    font-size: 1em;
    font-weight: 400;
    margin: 0 2px;
    padding: 10px 20px;
    border-radius: 30px;
    cursor: pointer;
    user-select: none;
    transition: background-color .3s ease;
}

.tab-menu.dragging .tab-btn {
    pointer-events: none;
}

.tab-btn:hover {
    background-color: var(--first-color);
}

.tab-btn.active {
    background-color: #6157a3;
    color: white;
}

/* .left-btn,
.right-btn {
    position: absolute;
    color: var(--text-color);
    font-size: 1.8em;
    padding: 10px;
    cursor: pointer;
}

.left-btn {
    left: 0;
    background: linear-gradient(to left, transparent, var(--first-color) 80%);
    border-top-left-radius: 30px;
    border-bottom-left-radius: 30px;
    display: none;
}

.right-btn {
    right: 0;
    background: linear-gradient(to right, transparent, var(--first-color) 80%);
    border-top-right-radius: 30px;
    border-bottom-right-radius: 30px;
} */

/* ===== Tab content ===== */
.tab-content {
    position: relative;
    display: flex;
    justify-content: center;
    width: 100%;
}

.tab-content-port {
    position: relative;
    display: flex;
    justify-content: start !important;
    width: 100%;
}

.tab-e-case {
    /* position: absolute;
        top: 0;
        right: auto;
        bottom: 0;
        left: auto; */
    max-width: 100%;
    /* padding: 15px 50px; */
    opacity: 0;
    transform: translateX(25px);
    content-visibility: hidden;
}

.tab-e-case.active {
    transform: translateX(0);
    content-visibility: visible;
    opacity: 1;
    transition: opacity 1s ease, transform 1s ease;
}

.tab-e-case .row {
    width: 100%;
    display: flex;
    /* justify-content: center; */
    /* align-items: center; */
    /* margin: 50px 0; */
    /* gap: 30px; */
}

.tab-e-case .img-card {
    position: relative;
    width: 450px;
    max-width: 450px;
    height: 300px;
    max-height: 300px;
    border-radius: 20px;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: var(--box-shadow);
}

.tab-e-case .img-card img {
    width: 100%;
    object-fit: cover;
}

.right-column {
    max-width: 800px;
}

.info .city,
.info .description p {
    color: var(--text-color);
    margin-bottom: 10px;
}

.info .city {
    font-size: 2em;
}

.country {
    color: var(--third-color);
    font-size: 5em;
    font-weight: 700;
    text-align: center;
    text-shadow: var(--text-shadow);
}

@media screen and (max-width: 1050px) {
    section {
        margin: 0 0;
    }

    .tab-nav-bar {
        /* margin: 65px 20px 40px 25px; */
        margin: 30px 10px 5px 10px;
    }

    .tab-e-case {
        padding: 15px 25px;
    }

    .tab-e-case .row {
        flex-direction: column;
    }

    .tab-e-case .img-card {
        width: auto;
        max-width: 600px;
    }

    .country {
        font-size: 10vw;
        padding-bottom: 50px;
    }
}


/* Image gallery stlyling */

.container__img-holder {
    max-width: 280px;
    display: inline-block;
    vertical-align: top;
    margin-bottom: 20px;
    margin-left: 16px;
    cursor: pointer;
}

.container__img-holder:nth-child(4n+1) {
    margin-left: 0;
}

.container__img-holder img {
    width: 100%;
    height: 220px;
    display: block;
}


/* Popup Styling */
.img-popup {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: rgba(255, 255, 255, .5);
    display: flex;
    justify-content: center;
    align-items: center;
    display: none;
    opacity: 1;
    z-index: 9999999;
}

.img-popup img {
    max-width: 900px;
    width: 100%;
    opacity: 0;
    transform: translateY(-100px);
    -webkit-transform: translateY(-100px);
    -moz-transform: translateY(-100px);
    -ms-transform: translateY(-100px);
    -o-transform: translateY(-100px);
}

.close-btn {
    width: 35px;
    height: 30px;
    display: flex;
    justify-content: center;
    flex-direction: column;
    position: absolute;
    top: 20px;
    right: 20px;
    cursor: pointer;
}

.close-btn .bar {
    height: 4px;
    background: #333;
}

.close-btn .bar:nth-child(1) {
    transform: rotate(45deg);
}

.close-btn .bar:nth-child(2) {
    transform: translateY(-4px) rotate(-45deg);
}

.opened {
    display: flex;
}

.opened img {
    animation: animatepopup 1s ease-in-out .8s;
    -webkit-animation: animatepopup .3s ease-in-out forwards;
}

@keyframes animatepopup {

    to {
        opacity: 1;
        transform: translateY(0);
        -webkit-transform: translateY(0);
        -moz-transform: translateY(0);
        -ms-transform: translateY(0);
        -o-transform: translateY(0);
    }

}

@media screen and (max-width: 880px) {

    .container .container__img-holder:nth-child(4n+1) {
        margin-left: 16px;
    }

}