﻿.home-new {
    padding-top: 45px;
}

.home-new-bottom {
    padding-top: 35px;
}

.list-new {
    display: grid;
    grid-auto-rows: minmax(min-content,max-content);
    grid-template-columns: repeat(4,minmax(0,1fr));
    column-gap: 20px;
    row-gap: 20px;
}

.item-new {
    background: #F8F8F8;
    border-radius: 5px;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
}

.item-new-top {
}

    .item-new-top img {
        height: 211px;
        overflow: hidden;
        object-fit: cover;
        transition: transform 0.5s ease;
    }

.item-new-bottom {
    padding: 11px;
    transition: color 0.3s ease;
}

    .item-new-bottom .new-title {
        overflow: hidden;
        text-overflow: ellipsis;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        display: -webkit-box;
        font-size: 16px;
        font-family: 'monB';
        color: #33b480;
        margin-bottom: 10px;
        transition: color 0.3s ease;
    }

    .item-new-bottom .new-descript {
        overflow: hidden;
        text-overflow: ellipsis;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        display: -webkit-box;
        font-size: 14px;
        font-family: 'monR';
        color: #545454;
        transition: color 0.3s ease;
    }

.news-options__type {
    margin-top: 5px;
    padding-top: 5px;
    font-family: 'monR';
    font-size: 12px;
    color: #b5b5b5;
    border-top: 1px solid #b5b5b591;
    transition: color 0.3s ease;
}

.item-new:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.12);
    /* background: #fff; */
}

    .item-new:hover .item-new-bottom {
    }

    .item-new:hover .item-new-top img {
        transform: scale(1.08);
    }

    .item-new:hover .new-title {
        color: #f98541; /* Màu cam chủ đạo */
    }

    .item-new:hover .new-descript {
        color: #666;
    }

    .item-new:hover .news-options__type {
        color: #999;
    }

.news-options__type svg {
}

    .news-options__type svg path {
        fill: #b5b5b5;
    }

.options-item span {
}




/*css-new*/
.home-contact-container {
    display: flex;
    /* align-items: center; */
    background: #F4F4F4;
    border-radius: 15px 0px 0 0px;
    margin-top: 60px;
}

.h-contact-left {
    background: #18B381;
    display: flex;
    justify-content: center; /* căn giữa ngang */
    /* align-items: center; */ /* căn giữa dọc */
    /* hoặc chiều cao cố định nếu cần, ví dụ: 150px */
    width: 30%;
    border-radius: 15px 15px 0 0px;
}

.img-logo-footer {
    display: flex;
    align-items: center;
}

    .img-logo-footer img {
        height: 60%;
    }

.h-contact-right {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 10px;
    gap: 19px;
}


.contact-item img {
    width: 69%;
    max-width: 100%;
    height: auto;
    display: block;
    overflow: hidden;
}

.contact-item {
    display: flex;
    justify-content: center;
    width: 72%;
}

.h-contact-rigth .contact-item {
}
/* Sửa .h-contact-right (Viewport) */
.h-contact-right {
    display: flex;
    align-items: center;
    /* justify-content: center; */ /* Bạn có thể bỏ justify-content ở đây */
    padding: 12px 10px;
    gap: 19px; /* Gap này có thể không cần thiết nữa */
    overflow: hidden; /* QUAN TRỌNG: Ẩn các logo bị tràn ra ngoài */
    width: 100%; /* Đảm bảo nó chiếm phần không gian còn lại */
}

/* Thêm class cho Track */
.marquee-track {
    display: flex; /* Giữ các logo trên một hàng */
    align-items: center; /* Căn giữa các logo theo chiều dọc */
    gap: 19px; /* Khoảng cách giữa các logo (giữ lại từ code của bạn) */
    width: max-content; /* QUAN TRỌNG: Để track rộng bằng tổng nội dung */
    /* Áp dụng animation bạn đã viết */
    animation: scrollMarquee 40s linear infinite;
    /* Bạn có thể đổi 40s thành tốc độ bạn muốn */
}

    /* Tùy chọn: Dừng lại khi người dùng hover chuột vào */
    .marquee-track:hover {
        animation-play-state: paused;
    }

/* Keyframes bạn đã có (chỉnh lại 100%) */
@keyframes scrollMarquee {
    0% {
        transform: translateX(0);
    }

    100% {
        /* Dịch chuyển 50% tổng chiều rộng. 
           Vì JS đã nhân đôi nội dung, nên -50% sẽ quay về đúng vị trí đầu 
           một cách mượt mà. */
        transform: translateX(-50%);
    }
}

/* Giữ nguyên các class .azza-zaa và .contact-item của bạn */
.azza-zaa {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 110px;
    background: #FFFF;
    overflow: hidden;
    border-radius: 3px;
    border: 1px solid #dfdddd;
    /* Thêm flex-shrink để đảm bảo chúng không bị co lại */
    flex-shrink: 0;
    width: 30%;
}

@media (max-width: 1023px) and (min-width: 740px) {
    .list-new {
        grid-template-columns: repeat(2, 1fr);
    }

    .item-new-top img {
        height: 200px;
    }

    .home-contact-container {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .h-contact-left {
        width: 100%;
        border-radius: 15px 15px 0 0;
    }

    .h-contact-right {
        width: 100%;
        gap: 15px;
        padding: 15px;
    }
}

/* --- Mobile (≤739px) --- */
@media (max-width: 739px) {
    .home-new {
        padding-top: 25px;
    }

    .list-new {
        grid-template-columns: repeat(2, 1fr);
        row-gap: 10px;
        column-gap: 10px;
    }

    .item-new-top img {
        height: 142px;
    }

    .new-title {
        font-size: 15px !important;
        margin-bottom: 6px !important;
    }

    .new-descript {
        font-size: 13px !important;
    }

    .home-contact-container {
        flex-direction: column;
        align-items: center;
        margin-top: 40px;
        border-radius: 10px;
    }

    .h-contact-left {
        width: 100%;
        border-radius: 10px 10px 0 0;
        padding: 15px;
    }

    .h-contact-right {
        flex-direction: column;
        width: 100%;
        padding: 15px 10px;
    }

    .azza-zaa {
        width: 100%;
        height: auto;
        padding: 10px;
    }

    .contact-item img {
        width: 80%;
    }

    .home-contact-container {
        flex-direction: column;
        align-items: center;
        margin-top: 40px;
        border-radius: 10px;
    }

    .h-contact-left {
        width: 100%;
        border-radius: 10px 10px 0 0;
        padding: 15px;
    }

    .h-contact-right {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
        width: 100%;
        padding: 15px 10px;
    }

    .azza-zaa {
        flex: 1 1 45%; /* 2 logo mỗi hàng */
        max-width: 45%;
        height: 133px;
    }

    .contact-item img {
        width: 90%;
    }

    .marquee-track {
        animation: none; /* Tắt animation lướt */
        width: 100%; /* Reset lại width (không dùng max-content) */
        /* Các thuộc tính này để nó hoạt động giống .h-contact-right */
        /* mà bạn đã code cho mobile */
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
    }

    /* Reset lại overflow của .h-contact-right */
    .h-contact-right {
        overflow: visible; /* Hoặc auto, để không bị cắt */
        /* Giữ các style mobile khác của bạn (flex-wrap, v.v...) */
    }

    .contact-item {
        width: 100%
    }

    .img-logo-footer img {
        height: 100%;
    }
}
