*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
    border: none;
    list-style-type: none;
    font-family: 'Poppins', sans-serif;
    color: white;
}

html {
    overflow: visible;
}

body {
    max-width: 100%;
    height: 100vh;
}

.main-container {
    display: flex;
    width: 100%;
    height: 100vh;
    background-color: black;
}

.main-container .image-preview {
    flex: 1;
    position: relative;
    overflow: hidden;
    transition: all 1s cubic-bezier(0.08, 0.82, 0.17, 1);
    clip-path: polygon(0 0, 100% 0%, 100% 100%, 0% 100%);
}

.main-container .image-preview:hover {
    flex: 2;
}

.main-container .image-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 1s cubic-bezier(0.08, 0.82, 0.17, 1);
}


.main-container .image-preview:hover img {
    transform: translateX(-10%);
    opacity: 1 !important;
}


.main-container .image-preview .overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 1) 100%);
    transition: all 1s cubic-bezier(0.08, 0.82, 0.17, 1);
    transform: translateX(10%);
    opacity: 0;
}

.main-container .image-preview:hover .overlay {
    transform: translateY(0%);
    opacity: 1;
}

.main-container .image-preview .overlay .desc {
    position: absolute;
    bottom: 3rem;
    padding: 1rem;
    opacity: 0;
    transform: translateY(100%);
    transition: all 1s cubic-bezier(0.08, 0.82, 0.17, 1);
    text-align: justify;
}

.main-container .image-preview .overlay .desc h1{
    margin-bottom: 1rem;
}

.main-container .image-preview:hover .overlay .desc {
    transform: translateY(0%);
    opacity: 1;
}


.main-container .image-preview video {
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    position: absolute;
    object-fit: cover;
    display: none;
}

.main-container .image-preview:hover video {
    display: block;
}


@media (max-width: 1024px) {
    .main-container {
        flex-direction: column;
        min-height: auto;
        height: auto;
    }

    .main-container .image-preview {
        flex: unset;
        height: 80vh;
    }

    .main-container .image-preview .overlay {
        height: 40%;
    }

    .main-container .image-preview:hover {
        flex: unset;
    }
}

@media (max-width: 768px) {
    .main-container {
        flex-direction: column;
        min-height: auto;
    }

    .main-container .image-preview {
        height: 60vh;
    }

    .main-container .image-preview .overlay {
        height: 40%;
    }

    .main-container .image-preview .overlay .desc {
        padding: 0.5rem;
    }

    .main-container .image-preview .overlay .desc h1 {
        font-size: 1.5rem;
    }
}