#modal {
    height: 100%;
    width: 100%;
    position: fixed;
    inset: 0;
    outline: none;
    border: none;
    background-color: var(--modal-bg);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
    display: none;
    -webkit-animation-name: fadeIn; /* Fade in the background */
    -webkit-animation-duration: 0.4s;
    animation-name: fadeIn;
    animation-duration: 0.4s;
    color: var(--main-text);
    z-index: 1000;
}

.modal-content {
    background-color: var(--main-bg);
    height: 100%;
    max-width: 600px;
    position: fixed;
    right: 0;
    padding: 1rem 1.8rem;
    overflow-y: scroll;
    /* Hide scrollbar for IE, Edge and Firefox */
    -ms-overflow-style: none; /* IE and Edge */
    scrollbar-width: none; /* Firefox */

    -webkit-animation-name: slideIn;
    -webkit-animation-duration: 0.4s;
    animation-name: slideIn;
    animation-duration: 0.4s;
}

/* Hide scrollbar for Chrome, Safari and Opera */
.modal-content::-webkit-scrollbar {
    display: none;
}

.modal-content > * {
    margin-bottom: 0.6rem;
}

.modal-content h3 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
}

.modal-content img {
    width: 100%;
    border-radius: 20px;
}

.modal-content .pills {
    justify-content: flex-start;
}

.modal-content a {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.modal-content .description p {
    margin-bottom: 0.4rem;
}

#closeModal {
    border-radius: 100%;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    margin-left: auto;
}

#closeModal:hover {
    transform: scale(1.1);
    border-radius: 95%;
}

.modal-content .links {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.6rem;
    margin-top: 1.2rem;
}

ul {
    list-style-position: inside;
    margin-inline-start: 1rem;
}

@-webkit-keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@-webkit-keyframes fadeOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

@media only screen and (min-width: 600px) {
    @-webkit-keyframes slideIn {
        from {
            right: -300px;
            opacity: 0;
        }
        to {
            right: 0;
            opacity: 1;
        }
    }

    @keyframes slideIn {
        from {
            right: -300px;
            opacity: 0;
        }
        to {
            right: 0;
            opacity: 1;
        }
    }

    @-webkit-keyframes slideOut {
        from {
            right: 0;
            opacity: 1;
        }
        to {
            right: -300px;
            opacity: 0;
        }
    }

    @keyframes slideOut {
        from {
            right: 0;
            opacity: 1;
        }
        to {
            right: -300px;
            opacity: 0;
        }
    }
}
