.contact-cards {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr;
    gap: 30px;
}

.contact-cards__card {
    border-radius: 8px;
    overflow: hidden;
    border-left: 1px solid #170D69;
    border-right: 1px solid #170D69;
    border-top: 1px solid #170D69;
}

.border-container {
    position: relative;
    border-bottom: 4px solid #170D69;
    padding: 20px;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.border-container::before {
    content: '';
    position: absolute;
    z-index: 3;
    bottom: -4px;
    left: 0;
    width: 22%;
    height: 4px;
    transition: all 10s;
    background-color: #E13A44;
}

.border-container:hover::before {
    animation: red-line 300ms linear forwards;
}

@keyframes red-line {
    0% {
        left: 0;
        width: 22%;
    }

    50% {
        left: 20%;
        width: 80%;
    }

    100% {
        left: 78%;
        width: 22%;
    }
}

.border-container::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 78%;
    width: 22%;
    height: 4px;
    background-color: #38ADF0;
}


.contact-cards__card:hover .border-container::after {
    animation: blue-line 200ms 200ms linear forwards;
}

@keyframes blue-line {
    0% {
        left: 0;
        width: 0;
    }

    100% {
        left: 0%;
        width: 22%;
    }
}

.contact-cards__card:hover .border-container::before {
    width: 100%;
}

.contact-cards__card__title {
    margin-bottom: 10px;
}

.contact-cards__card__description {
    color: #898989;
}

.contact-cards__card__link {
    margin-top: auto;
    color: #E13A44;
    font-weight: 400;
    transition: .2s linear;
}

.contact-cards__card__link:hover {
    opacity: .6;
}

.contact-cards__card__link i {
    font-size: 12px;
    padding-left: 10px;
}

@media (max-width: 772px) {
    .contact-cards {
        grid-template-columns: 1fr;
    }
}