h4 {
    color: #036;
    display: block;
    font-size: 16px;
    line-height: 1.25;
    font-weight: 700;
}

h5 {
    color: #c20017;
    display: block;
    font-size: 14px;
    line-height: 1.25;
    font-weight: 700;
    text-transform: capitalize;
}

h4:hover {
    text-decoration: underline;
}

/* content //////////////////////////////////////*/
.main-content {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    margin-bottom: 10px;
    padding-bottom: 10px;
}

/* ///////////////////////////////////////// */

.content {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.item a {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.item img {
    flex-shrink: 0;
    object-fit: cover;
    width: 100%;
    aspect-ratio: 3 / 2;
    display: block;
    border-radius: 4px;
}

.item-text {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.item-text h4 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 18px;
    line-height: 1.3;
    font-weight: 800;
}

.item-text time {
    display: block;
    font-size: 14px;
    font-weight: 450;
    color: #666;
}

@media (max-width: 1000px) {
    .content {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 700px) {
    .content {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 500px) {
    .content {
        display: flex;
        flex-direction: column;
        gap: 15px;
    }

    .item a {
        display: flex;
        flex-direction: row;
        gap: 10px;
    }

    .item {
        padding-bottom: 15px;
        border-bottom: 1px solid #ccc;
    }

    .item:last-child {
        padding-bottom: 0;
        border-bottom: none;
    }

    .item a img {
        width: 150px;
        height: 100px;
    }

    .item-text {
        gap: 5px;
    }

    .item h4 {
        order: 2;
        font-size: 18px;
        line-height: 1.4;
        font-weight: 600;
    }

    .item h5 {
        order: 1;
    }

    .item-text time {
        order: 0;
    }
}

@media (max-width: 400px) {
    .item a img {
        width: 120px;
        height: 80px;
    }

    .item-text {
        gap: 2px;
    }

    .item a h4 {
        font-size: 16px;
        font-weight: 600;
        line-height: 1.25;
    }
}
