
.blog-section {
    position: relative;
    width: 100%;
    height: 100vh; /* Cao bằng màn hình */
    min-height: 750px;
    background-image: url('../image/imagesblogCraftmanship/Craftshero.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed; 
}


.blog-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    justify-content: center; 
    align-items: flex-end; 
    padding: 0; 
}

.blog-content {
    color: #ffffff;
    width: 100% !important;
    max-width: var(--container-max) !important; 
    margin: 0 auto !important;
    padding: 0 var(--side-padding) 80px var(--side-padding) !important; /* Lề 55px và đáy 80px */
    box-sizing: border-box;
    text-align: left; 
}

.blog-subtitle {
    display: block;
    margin-bottom: 30px;
    font-size: 11px;
    font-weight: 200;
    color: #ffffff;
    letter-spacing: 1px;
    text-transform: uppercase;
}


.blog-title {
    font-family: var(--special-font);
    font-size: clamp(40px, 5vw, 30px);
    font-weight: 400;
    line-height: 1.2;
    margin-bottom: 10px;
    letter-spacing: -0.02em;
}

.blog-description {
    font-size: 15px;
    line-height: 1.6;
    margin-bottom: 30px;
    opacity: 1;
    max-width: 650px;
}



.blog-btn-group {
    display: flex !important;
    gap: 15px !important;
    margin-top: 30px !important;
    justify-content: flex-start;
}


.blog-content .blog-btn {
    font-family: var(--special-font);
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    padding: 14px 35px !important;
    background-color: #ffffff;
    color: #000000;
    border: 2px solid #ffffff !important;
    border-radius: 100px !important;
    font-size: 17px !important;
    font-weight: 100;
    letter-spacing: -0.02em;
    text-decoration: none !important; 
    transition: all 0.2s ease;
}

/* Nút mới (Tất cả bài viết) - Kiểu QUOC */
.blog-content .blog-btn.btn-outline {
    background-color: transparent;
    color: #ffffff;
    border: 2px solid #ffffff !important;
}


.blog-content .blog-btn:not(.btn-outline):hover {
    background-color: transparent !important;   
    color: var(--white);    
}

/* HIỆU ỨNG HOVER RIÊNG CHO NÚT OUTLINE - Cái mày đang cần đây */
.blog-content .blog-btn.btn-outline:hover {
    background-color: var(--color-bg-dark) !important; /* MÀU TỰ CHỌN: Thay mã màu của mày vào đây */
    border-color: transparent !important;  /* Bỏ viền trắng khi hover */
    color: #ffffff !important;            /* Giữ nguyên màu chữ trắng hoặc đổi tùy ý */
}


/* --- RESPONSIVE LICHSUPROCESS --- */
@media (max-width: 1024px) {
    .blog-section {
        /* Bỏ chiều cao cố định, dùng tỉ lệ khung hình để co giãn thông minh */
        height: auto !important; 
        min-height: unset !important;
        aspect-ratio: 4 / 5; /* Tỉ lệ dọc hiện đại, giống ảnh QUOC mày gửi */
        background-attachment: scroll; /* Fix lỗi lag trên mobile */
    }

    .blog-overlay {
        display: flex;
        align-items: flex-end; 
        justify-content: center; 
        text-align: center;
        
        
        padding: 60px 20px 40px 20px !important;
        
        background: rgba(0,0,0,0.3); 
    }

    .blog-content {
        max-width: 100%;
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: center; 
        text-align: center !important;
        padding: 0 !important;
        /* CHIÊU CUỐI: Dùng margin-bottom âm để ép cụm này xuống sát mép dưới hơn nữa */
    }

    
    .blog-subtitle {
        display: block;
        font-size: 11px;
        letter-spacing: 1px;
        color: var(--wwhite);
        text-transform: uppercase;
    }


    .blog-title {
        font-size: 28px !important;
        line-height: 1.2;
        margin-bottom: 20px;
        font-weight: 400;
        width: 100%; /* Đảm bảo text có không gian để căn giữa */
    }

    .blog-description {
        font-size: 12px;
        letter-spacing: 0px;
        margin-bottom: 25px;
        
        /* [QUAN TRỌNG] Cho phép chữ dãn ra tối đa không gian cho phép */
        max-width: 100% !important; 
        width: 100% !important;
        
        /* Giữ lề lối */
        margin-left: auto;
        margin-right: auto;
    }
    
    .blog-btn {
        font-family: var(--special-font);
        padding: 13px 30px;
        font-size: 17px;
        font-weight: 400;
        /* Khóa nút không bị dãn ngang, luôn nằm chính giữa */
        width: fit-content !important; 
        display: inline-block;
        margin: 0 auto;
        margin-bottom: 0 !important;
        letter-spacing: 0rem;
    }
}

/* TABLET: Dài ngang ra tối ưu như Desktop (như hình iPad Mini mày gửi) */
@media (min-width: 768px) and (max-width: 1024px) {
    .blog-section {
        aspect-ratio: 16 / 9; /* Ép về tỉ lệ màn hình ngang */
    }
    
    .blog-title {
        font-size: 45px !important;
    }
}














/*BLOGPAGE*/
.blogpagehero,
.firstbloghero,
.secondbloghero,
.thirdbloghero,
.fourthbloghero,
.fifthbloghero,
.sixbloghero,
.seventhbloghero {
    height: 93vh; 
    position: relative; 
    display: flex;
    align-items: flex-end; 
    /* Thay đổi quan trọng: Bỏ padding cố định, dùng flex để căn giữa khối nội dung */
    padding: 0; 
    justify-content: center; 
    width: 100%;
}

/* Thêm lớp phủ sẫm màu */
.blogpagehero-bg::after,
.firstbloghero-bg::after,
.secondbloghero-bg::after,
.thirdbloghero-bg::after,
.fourthbloghero-bg::after,
.fifthbloghero-bg::after,
.sixbloghero-bg::after,
.seventhbloghero-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.3); /* Độ sẫm 25%, mày có thể tăng lên 0.3 nếu muốn tối hơn */
    z-index: 1;
}

.blogpagehero-bg,
.firstbloghero-bg,
.secondbloghero-bg,
.thirdbloghero-bg,
.fourthbloghero-bg,
.fifthbloghero-bg,
.sixbloghero-bg,
.seventhbloghero-bg { 
    position: absolute; 
    inset: 0; 
    z-index: -1; 
}


.blogpagehero-bg img,
.firstbloghero-bg img,
.secondbloghero-bg img,
.thirdbloghero-bg img,
.fourthbloghero-bg img,
.fifthbloghero-bg img,
.sixbloghero-bg img,
.seventhbloghero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: relative;
    z-index: 0;
}


.blogpagehero-text { 
    color: #fff; 
    width: 100%;
    max-width: var(--container-max); /* Khóa chặt ở 1650px */
    margin: 0 auto; /* Ép vào giữa màn hình */
    padding: 0 var(--side-padding); /* Trả lại đúng 55px padding để chữ đứng đúng vị trí cũ */
    margin-bottom: 48px;
    z-index: 2;
    text-align: left; /* Đảm bảo chữ vẫn canh trái bên trong cái lồng 1650px */
}

.sub-title {
    font-size: 11px;
    word-spacing: 5px;
    font-weight: 200;
    letter-spacing: 1px;
    margin-bottom: 30px;
}

.blogpagehero-text h1
 { font-size: 58px; line-height: 1.1; margin-bottom: 30px; font-weight: 400; }


.mobile-only { 
    display: none !important; 
}

/* Mặc định trên Desktop: Giấu nút Mobile */
.mobile-menu-btn, .mobile-overlay { display: none; }





@media (max-width: 1024px) {
    .blogpagehero,
    .firstbloghero,
    .secondbloghero,
    .thirdbloghero,
    .fourthbloghero,
    .fifthbloghero,
    .sixbloghero,
    .seventhbloghero {
       
        height: auto !important; 
        
       
        min-height: 120vw !important; 
        
    
        background-size: cover !important;
        background-position: center !important;

       
        display: flex;
        flex-direction: column;
        justify-content: flex-end; 
        align-items: center;    
        text-align: center;
        padding: 0 20px;
        padding-bottom: 20px !important; 
        padding-left: 20px !important;
        padding-right: 20px !important;
        border-top: 1px solid #ffffff;
    }

    .blogpagehero-text,
    .firstbloghero-text,
    .secondbloghero-text,
    .thirdbloghero-text,
    .fourthbloghero-text,
    .fifthbloghero-text,
    .sixbloghero-text,
    .seventhbloghero-text {
        padding: 0 !important; 
        margin: 0 auto !important;
        max-width: 100% !important; 
        width: 100% !important;
        
        /* Đảm bảo căn giữa tuyệt đối */
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center !important;
        margin-bottom: 20px !important; 
    }

}


/* TABLET: Dàn ngang ra tối ưu */
@media (min-width: 768px) and (max-width: 1024px) {
    .blogpagehero,
    .firstbloghero,
    .secondbloghero,
    .thirdbloghero,
    .fourthbloghero,
    .fifthbloghero,
    .sixbloghero,
    .seventhbloghero {
        min-height: 56vw !important; 
    }
}











.blog-page-wrapper {
    display: contents; 
}

.blog-page-wrapper[style*="display: none"] {
    display: none !important;
}


/* ==========================================================================
   BLOG GRID - BẢN TRÀN VIỀN TABLET (FULL PROFESSIONAL)
   ========================================================================== */

/* --- 1. PHẦN CHUNG --- */
.blog-card-title, .blog-card-image, .blog-card-title:hover {
    text-decoration: none !important;
    color: inherit !important;
    outline: none !important;
    display: block;
}

.blog-card-image {
    overflow: hidden !important;
    position: relative;
    width: 100%;
}

.blog-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 1s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.blog-card:hover .blog-card-image img {
    transform: scale(1.08);
}

/* --- 2. DESKTOP & TABLET LỚN (GIỮ NGUYÊN) --- */
@media screen and (min-width: 1024px) {
    .blog-grid {
        display: grid !important;
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 30px !important;
        row-gap: 80px !important;
        padding: 0 !important;
        margin-bottom: 60px !important;
    }
    .blog-card-image { aspect-ratio: 6/7; margin-bottom: 24px; }
    .blog-card-title h3 { font-size: 33px; font-weight: 600; line-height: 1.3; color: var(--color-h3); margin-bottom: 20px; }
    .blog-card-desc { font-size: 13px; line-height: 1.6; color: var(--black); font-weight: 600; }
}



/* --- 3. TABLET MINI (768px - 1023px): TRÀN VIỀN CHUYÊN NGHIỆP --- */
@media screen and (min-width: 768px) and (max-width: 1023px) {
    .casa-filter-wrapper{
        display: none;
    }

    .blog-grid {
        display: flex !important;
        overflow-x: auto !important;
        gap: 20px !important;
        /* Phá lề: Kéo tràn ra 20px để sát mép màn hình */
        margin-left: -20px !important; 
        margin-right: -20px !important;
        /* Padding đệm để card đầu/cuối không dính sát lề khi dừng */
        padding: 40px 20px 40px 20px !important; 
        scrollbar-width: none !important;
        -webkit-overflow-scrolling: touch;
    }
    
    .blog-grid::-webkit-scrollbar { display: none !important; }
    
    .blog-card { 
        width: calc((100vw - 40px - 20px) / 2) !important;
        flex: 0 0 calc((100vw - 40px - 20px) / 2) !important;
        flex-shrink: 0 !important;
    }
    .blog-card-image { 
        aspect-ratio: 6/7 !important; 
        margin-bottom: 20px !important; 
    }

    .blog-card-title h3 { 
        font-size: 25px !important; 
        line-height: 1.4 !important; 
        color: var(--color-h3) !important; 
        margin-bottom: 15px !important; 
        font-weight: 600;
    }

    .blog-card-desc { 
        font-size: 13px !important; 
        font-weight: 500;
        line-height: 1.3 !important; 
        color: var(--black) !important; 
        margin-bottom: 20px;
    }
}



/* --- 4. MOBILE (< 767px) --- */
@media screen and (max-width: 767px) {
    .casa-filter-wrapper{
        display: none;
    }

    .blog-grid {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 40px !important;
        padding: 0 20px !important;
    }
    .blog-card-image { 
        aspect-ratio: 6/7 !important; 
        margin-bottom: 20px !important; 
    }

    .blog-card-title h3 { 
        font-size: 25px !important; 
        line-height: 1.3 !important; 
        color: var(--color-h3) !important; 
        margin-bottom: 15px !important; 
        font-weight: 600;
    }

    .blog-card-desc { 
        font-size: 12px !important; 
        font-weight: 600;
        line-height: 1.6 !important; 
        color: var(--black) !important; 
        margin-bottom: 20px;
    }
}



/* --- 5. PAGINATION --- */
.blog-pagination { 
    margin-top: 120px; 
    display: flex; 
    justify-content: center; 
    align-items: center;
    gap: 15px; 
    font-size: 15px;
    color: var(--black);
}

.blog-pagination a, .blog-pagination span { text-decoration: none !important; color: var(--black) !important; }

.pag-btn {
    width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--color-border);
    display: flex; align-items: center; justify-content: center; cursor: pointer;
    transition: 0.3s cubic-bezier(0.165, 0.84, 0.44, 1); color: var(--black); background: none;
    padding: 0; outline: none;
}

.pag-btn:hover { background: var(--black) !important; color: var(--white) !important; border-color: var(--black) !important; }

@media screen and (max-width: 1023px) {
    .blog-pagination { margin-top: 40px; gap: 15px; font-size: 15px; }
    .pag-btn { width: 40px; height: 40px; }
}




/* ==========================================================================
   CASA FILTER SYSTEM - TRƯỢT TUẦN HOÀN GRID TRANSITION SIÊU MƯỢT
   ========================================================================== */


/* --- THIẾT LẬP TRÊN DESKTOP (>= 1024px) --- */
@media screen and (min-width: 1024px) {
   
    .blog-grid {
        position: relative !important;
        display: grid !important;
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 40px !important;
        row-gap: 80px !important;
        padding-top: 80px !important; 
        
     
        margin-bottom: 60px !important;
        transition: margin-bottom 0.7s cubic-bezier(0.16, 1, 0.3, 1) !important;
    }

  
    main.filter-activated .blog-grid.grid-expanded {
        margin-bottom: calc(var(--casa-card-height, 550px) + 80px + 60px) !important; 
    }

    .blog-page-wrapper {
        display: contents !important;
    }


    .blog-page-wrapper > .blog-card {
        position: relative !important;
        width: 100% !important;
        /* Chuyển động mượt mà tuyệt đối bằng transform được tối ưu GPU */
        transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1) !important;
        will-change: transform;
    }


    .casa-filter-wrapper {
        position: absolute !important;
        top: 0 !important;
        left: 0 !important;
        width: calc((100% - 60px) / 3) !important;
        z-index: 1005 !important;
        display: block !important;
    }

    /* BOX LỌC TRƯỢT NHẸ XUỐNG */
    .casa-filter-vertical-content {
        position: absolute !important;
        top: 65px !important;
        left: 0 !important;
        width: 100% !important;
        background: #ffffff !important;
        border-radius: 16px !important; /* Bo góc luxury */
        padding: 30px !important;
        box-shadow: 0 20px 50px rgba(0, 0, 0, 0.08) !important;
        display: flex;
        flex-direction: column;
        gap: 20px;
        box-sizing: border-box;
        opacity: 0;
        visibility: hidden;
        transform: translateY(-15px) scale(0.97);
        transform-origin: top left;
        transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1),
                    opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1),
                    visibility 0.4s !important;
    }


    /* NÚT TÌM KIẾM TRONG BOX BỘ LỌC */
    .casa-filter-submit-btn {
        font-family: var(--special-font);
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 50%;
        background: var(--color-bg-dark) !important;
        border: 2px solid var(--color-bg-dark) !important; /* Viền đen đồng bộ lúc đầu */
        border-radius: 999px !important;
        padding: 14px 35px !important;
        font-size: 17px;
        font-weight: 100;
        color: #ffffff !important; /* Chữ trắng */
        cursor: pointer;
        outline: none;
        
        /* Chuyển động mượt mà tuyệt đối đúng tinh thần Casa */
        transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1) !important;
        margin-top: 10px; /* Tạo thêm khoảng cách nhẹ với ô danh mục phía trên */
    }

    /* HIỆU ỨNG HOVER CHUYỂN ĐỔI NGƯỢC (REVERSE HOVER) */
    .casa-filter-submit-btn:hover {
        background: transparent !important; /* Rê chuột vào sẽ trong suốt */
        color: #000000 !important; /* Chữ chuyển thành màu đen */
        border-color: #111111 !important; /* Border đen nổi bật trên nền trắng của box */
    }

    /* Khi kích hoạt: Box trượt nhẹ xuống */
    main.filter-activated .casa-filter-vertical-content {
        opacity: 1 !important;
        visibility: visible !important;
        transform: translateY(15px) scale(1) !important;
    }

    /* ==========================================================================
       HIỆU ỨNG TRƯỢT CUBE ĐỘNG (Xử lý mượt theo Class JS gán, không theo DOM index)
       ========================================================================== */
    
    /* Card thuộc Cột 1 thực tế: Trượt sang Cột 2 */
    main.filter-activated .blog-page-wrapper > .blog-card.casa-col-1 {
        transform: translate(calc(100% + 30px), 0) !important;
    }

    /* Card thuộc Cột 2 thực tế: Trượt sang Cột 3 */
    main.filter-activated .blog-page-wrapper > .blog-card.casa-col-2 {
        transform: translate(calc(100% + 30px), 0) !important;
    }

    /* Card thuộc Cột 3 thực tế: Trượt lùi trái 2 cột và đẩy xuống hàng tiếp theo */
    main.filter-activated .blog-page-wrapper > .blog-card.casa-col-3 {
        transform: translate(calc(-200% - 60px), calc(100% + 80px)) !important;
    }
}



/* BẢNG GỢI Ý TÌM KIẾM */
.search-suggestions-box {
    position: absolute !important;
    top: 100% !important;
    left: 0 !important;
    width: 100% !important;
    background: #ffffff !important;
    border: 1px solid #eef0f3 !important;
    border-radius: 12px !important;
    margin-top: 8px !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08) !important;
    z-index: 110 !important;
    max-height: 250px !important; /* Giới hạn chiều cao nếu có quá nhiều gợi ý */
    overflow-y: auto !important; /* Hiện thanh cuộn nếu tràn */
    
    /* Hiệu ứng ẩn hiện mượt mà */
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px) !important;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

/* Kích hoạt khi có kết quả tìm kiếm */
.search-suggestions-box.is-visible {
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateY(0) !important;
}

/* Từng dòng gợi ý bài viết */
.suggestion-item {
    display: flex !important;
    flex-direction: column !important;
    padding: 12px 20px !important;
    border-bottom: 1px solid #f7f7f7 !important;
    text-decoration: none !important;
    cursor: pointer !important;
    transition: background 0.2s ease !important;
}

.suggestion-item:last-child {
    border-bottom: none !important;
}

.suggestion-item:hover {
    background: #f7f7f7 !important;
}

/* Tiêu đề bài viết trong gợi ý */
.suggestion-title {
    font-size: 14px !important;
    font-weight: 500 !important;
    color: #111111 !important;
    line-height: 1.4 !important;
}

/* Danh mục nhỏ đi kèm phía dưới tiêu đề */
.suggestion-meta {
    font-size: 11px !important;
    color: #888888 !important;
    margin-top: 4px !important;
}

/* Khi không tìm thấy bài viết nào */
.suggestion-no-result {
    padding: 15px 20px !important;
    font-size: 13px !important;
    color: #999999 !important;
    text-align: center !important;
}







.casa-filter-trigger {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: #ffffff !important;
    border: 2px solid var(--color-bg-dark) !important; 
    border-radius: 999px !important; 
    padding: 14px 35px !important;
    font-family: var(--special-font);
    font-size: 17px;
    letter-spacing: -0.02em;
    font-weight: 100;
    color: #111111;
    cursor: pointer;
    outline: none;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1) !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
}


/* Icon SVG và các đường nét chuyển động mềm */
.filter-icon-svg {
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.filter-icon-svg path,
.filter-icon-svg circle {
    transition: stroke 0.4s ease, fill 0.4s ease !important;
}


.filter-text::before {
    content: attr(data-show);
}
main.filter-activated .filter-text::before {
    content: attr(data-hide);
}


.casa-filter-trigger:hover {
    border-color: var(--color-bg-dark) !important;
    background: var(--color-bg-dark) !important;
    color: #ffffff !important;
}
/* Khi hover: biến các đường vẽ SVG sang màu trắng */
.casa-filter-trigger:hover .filter-icon-svg path {
    stroke: #ffffff !important;
}
.casa-filter-trigger:hover .filter-icon-svg circle {
    stroke: #ffffff !important;
    fill: #111111 !important; /* Tránh bị bóp méo hình tròn */
}

/* Khi bộ lọc đang được bật */
main.filter-activated .casa-filter-trigger {
    background: var(--color-bg-dark) !important;
    border-color: #111111 !important;
    color: #ffffff !important;
}
main.filter-activated .casa-filter-trigger .filter-icon-svg {
    transform: rotate(180deg); /* Xoay nhẹ icon tạo sự thú vị khi active */
}
main.filter-activated .casa-filter-trigger .filter-icon-svg path {
    stroke: #ffffff !important;
}
main.filter-activated .casa-filter-trigger .filter-icon-svg circle {
    stroke: #ffffff !important;
    fill: #111111 !important;
}





/* Các ô input gạch dưới */
.casa-filter-field {
    position: relative !important;
    width: 100%;
}

.casa-filter-field input,
.casa-filter-field select {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid #eeeeee;
    padding: 12px 0;
    font-family: var(--special-font);
    font-size: 17px;
    letter-spacing: -0.02em;
    color: #111111;
    outline: none;
    border-radius: 0;
    box-sizing: border-box;
    transition: border-color 0.3s ease;
}
.casa-filter-field input:focus,
.casa-filter-field select:focus {
    border-bottom-color: #111111;
}



#blog-keyword {
    width: 100%;
    padding-right: 40px !important; /* Chừa khoảng trống bên phải để chữ không đè lên nút x */
    box-sizing: border-box;
}

/* NÚT "X" XÓA NHANH */
.casa-clear-btn {
    position: absolute !important;
    right: 0px !important;
    top: 50% !important;
    transform: translateY(-50%) scale(0.8) !important;
    background: none !important;
    border: none !important;
    font-size: 25px !important;
    line-height: 1 !important;
    color: #999999 !important;
    cursor: pointer !important;
    padding: 0px !important;
    outline: none !important;
    
    /* Hiệu ứng ẩn/hiện mượt mà */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1), 
                transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), 
                color 0.2s !important;
}

/* Hover chuyển màu đen luxury */
.casa-clear-btn:hover {
    color: #111111 !important;
}

/* Hiện nút "x" khi có ký tự */
.casa-clear-btn.is-visible {
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateY(-50%) scale(1) !important;
}





/* ẨN THẺ SELECT GỐC ĐỂ CHẠY NGẦM */
.casa-filter-field select {
    display: none !important;
}

/* KHUNG HIỂN THỊ CHÍNH (TRIGGER) */
.casa-custom-select-trigger {
    position: relative !important; 
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 15px 0 !important;
    padding-right: 40px !important; 
    font-family: var(--special-font);
    font-size: 17px !important;
    font-weight: 100 !important;
    color: #111111 !important;
    border-bottom: 1px solid #e0e0e0 !important;
    cursor: pointer !important;
    transition: border-color 0.3s ease !important;
}

/* Khi dropdown đang mở thì viền dưới chuyển sang đen đậm */
.casa-filter-field.is-open .casa-custom-select-trigger {
    border-bottom-color: #111111 !important;
}

/* Mũi tên chữ V mảnh dẻ vuốt nhọn */
.casa-custom-select-trigger::after {
    content: "" !important;
    position: absolute !important;
    
    /* Căn thẳng hàng hoàn hảo với nút "x" ở trên */
    right: 4px !important; 
    top: 50% !important;
    
    /* Vẽ mũi tên chữ V */
    width: 5px !important;      
    height: 5px !important;      
    border-right: 1px solid #666666 !important;
    border-bottom: 1px solid #666666 !important;
    
    /* Gốc tọa độ xoay từ tâm chuẩn và căn giữa chiều dọc */
    transform-origin: center center !important;
    transform: translateY(-50%) rotate(45deg) !important; 
    
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

/* Xoay ngược mũi tên lên khi mở dropdown */
.casa-filter-field.is-open .casa-custom-select-trigger::after {
    transform: translateY(-50%) rotate(225deg) !important; /* Xoay đúng 180 độ từ góc 45deg ban đầu */
}

/* HỘP DANH SÁCH DROPDOWN XỔ XUỐNG */
.casa-custom-options-box {
    position: absolute !important;
    top: 100% !important;
    left: 0 !important;
    width: 100% !important;
    background: #ffffff !important;
    border: 1px solid #eef0f3 !important;
    border-radius: 12px !important;
    margin-top: 8px !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08) !important;
    z-index: 100 !important;
    overflow: hidden !important;
    
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px) !important;
    transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1),
                visibility 0.3s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

/* Trạng thái mở */
.casa-filter-field.is-open .casa-custom-options-box {
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateY(0) !important;
}

/* TỪNG MỤC LỰA CHỌN BÊN TRONG (OPTION) */
.casa-custom-option-item {
    padding: 12px 20px !important; 
    font-family: var(--special-font);
    font-size: 17px !important;
    font-weight: 100 !important;
    color: #000000 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
}

/* Rê chuột vào mục */
.casa-custom-option-item:hover {
    background: #f7f7f7 !important; /* Đổi nền xám cực nhẹ */
    color: #111111 !important;
}

/* Mục đang được chọn */
.casa-custom-option-item.active {
    background: #f1f1f1 !important;
    color: #111111 !important;
    font-weight: 700 !important;
}







/* ==========================================================================
   CASA FILTER SYSTEM - BẢN MOBILE CHUẨN FLOATING OVERLAY (< 767px)
   ========================================================================== */

@media screen and (max-width: 767px) {
    
  
    .blog-grid {
        display: flex !important;
        flex-direction: column !important;
        gap: 30px !important; 
        padding: 0 20px !important; 
        position: relative !important;
    }

   
    .casa-filter-wrapper {
        display: block !important;
        position: relative !important;
        width: 100% !important;
        margin-bottom: -10px !important; 
        z-index: 1000 !important;
    }

   
    .casa-filter-trigger {
        display: inline-flex !important;
        width: auto !important;
        min-width: 120px !important;
        max-width: 45% !important;
        justify-content: center !important;
        align-items: center !important;
        padding: 10px 18px !important;
        font-size: 13px !important;
        background: #111111 !important;
        border: 1px solid #111111 !important;
        border-radius: 999px !important;
        color: #ffffff !important;
        margin: 0 !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08) !important;
    }

    .casa-filter-trigger .filter-icon-svg path {
        stroke: #ffffff !important;
    }
    .casa-filter-trigger .filter-icon-svg circle {
        stroke: #ffffff !important;
        fill: #111111 !important;
    }

  
    .casa-filter-vertical-content {
        position: absolute !important;
        top: calc(100% + 10px) !important;
        left: 0 !important;
        width: 100% !important; 
        background: #ffffff !important;
        border-radius: 16px !important;
        padding: 20px !important;
        box-shadow: 0 15px 35px rgba(0, 0, 0, 0.18) !important;
        border: 1px solid #f0f0f0 !important;
        display: flex !important;
        flex-direction: column !important;
        gap: 16px !important;
        box-sizing: border-box !important;
        z-index: 9999 !important; /* Đảm bảo đè lên trên bài viết */

        /* Hiệu ứng thả nhẹ không làm giật trang */
        opacity: 0;
        visibility: hidden;
        transform: translateY(-8px);
        transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
                    opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1),
                    visibility 0.25s !important;
    }

    main.filter-activated .casa-filter-vertical-content {
        opacity: 1 !important;
        visibility: visible !important;
        transform: translateY(0) !important;
    }

   
    main.filter-activated .blog-page-wrapper > .blog-card {
        transform: none !important;
    }

    /* 6. CÁC Ô INPUT & DROPDOWN */
    .casa-filter-field input {
        font-size: 13px !important;
        padding: 10px 0 !important;
    }

    .casa-custom-select-trigger {
        font-size: 13px !important;
        padding: 10px 0 !important;
    }

    .casa-custom-options-box {
        max-height: 180px !important;
        overflow-y: auto !important;
        border-radius: 10px !important;
    }

    .casa-custom-option-item {
        padding: 12px 16px !important;
        font-size: 13px !important;
    }

    
    .casa-filter-submit-btn {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        width: 100% !important;
        background: #111111 !important;
        color: #ffffff !important;
        border: 1px solid #111111 !important;
        border-radius: 999px !important;
        padding: 12px 20px !important;
        font-size: 13px !important;
        font-weight: 500 !important;
        cursor: pointer !important;
        outline: none !important;
    }
}
















/* ==========================================================================
   FIRST BLOG SECTION - FULL RESPONSIVE SEPARATED
   ========================================================================== */

/* --- 1. BASE STYLES (DÙNG CHUNG) --- */
.firstblog-header { margin-bottom: 60px;}

.firstblog-main-title {
    font-size: clamp(38px, 5vw, 50px);
    color: var(--black);
}

.firstblog-subtitle {
    font-size: 13px;
    color: var(--black);
    max-width: 650px;
    line-height: 1.6;
}

.firstblog-text-container {
    max-width: 680px;
    margin: 0 auto;
    padding: 30px 0;
}

.blog-text-eyebrow {
    display: block;
    font-size: 13px;
    line-height: 1.6;
    color: var(--black);
    margin-bottom: 80px; 
}

.firstblog-text-container h2 {
    font-size: clamp(11px, 5vw, 26px);
    line-height: 1.4;
    margin: 60px 0 30px;
    font-weight: 400;
}

.firstblog-text-container p {
    font-size: 13px;
    line-height: 1.6;
    margin-bottom: 20px;
    color: var(--black);
}

.firstblog-middletext {
    display: block;
    font-size: 11px;
    font-weight: 200;
    color: var(--color-text-muted);
    margin-top: 40px !important;
    margin-bottom: 40px !important;
    text-transform: uppercase;    
}

.firstblog-gallery-item {
    aspect-ratio: 1/1.2;
    overflow: hidden !important; /* Khóa khung zoom */
    background-color: var(--gray);
}

.firstblog-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 1.2s cubic-bezier(0.165, 0.84, 0.44, 1);
    cursor: zoom-in;
}

.firstblog-gallery-item:hover img { transform: scale(1.1); }

.firstblog-photography-credit {
    font-style: italic;
    color: var(--color-text-muted);
    margin-top: 40px;
    font-size: 14px;
}

.blog-scroll-indicator {
    display: none;
    width: 100%;
    height: 1px;
    background: var(--color-border); 
    position: relative;
}


.article-cta-box {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    text-decoration: none; /* [cite: 2026-02-11] */
    margin: 0;
    color: var(--color-h3);
    transition: all 0.3s ease;
}

.cta-text {
    font-family: var(--font-body);
    font-size: 16px;
    font-weight: 400;
    font-style: italic;
}

.cta-arrow {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    fill: none;
    stroke-width: 1.2; /* Nét mảnh đúng gu luxury */
    transition: transform 0.3s ease;
}

/* Hiệu ứng Hover */
.article-cta-box:hover {
    color: var(--black);
}

.article-cta-box:hover .cta-arrow {
    transform: translateX(5px); /* Mũi tên nhích nhẹ sang phải khi hover */
}


/* --- 2. DESKTOP ( > 1024px ) --- */
@media screen and (min-width: 1025px) {
    .firstblog-gallery-grid {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
        padding-top: 40px;
    }
}



/* --- TẦNG 3. TABLET LỚN ( 992px - 1024px ): DẠNG LƯỚT SNAP CHUẨN LỀ --- */
@media screen and (min-width: 992px) and (max-width: 1024px) {
    .casa-container {padding: 40px 20px !important;}

    .firstblog-header { padding: 20px 0; }

    .firstblog-gallery-grid {
        display: flex !important;
        overflow-x: auto !important;
        /* Gap 20px đồng bộ với lề mặc định của mày [cite: 2026-02-07] */
        gap: 20px !important; 
        
        /* Reset hoàn toàn margin âm để hít đúng lề 20px của container */
        width: 100% !important;
        margin: 40px 0 !important; 
        padding: 0 0 20px 0 !important; 
        
        /* Bật tính năng lướt "khựng" (Snap) cho sang */
        scroll-snap-type: x mandatory !important;
        scrollbar-width: none !important;
    }
    .firstblog-gallery-grid::-webkit-scrollbar { display: none !important; }

    .firstblog-gallery-item {
        /* Công thức: (100% container - 20px gap) / 2 */
        width: calc((100% - 20px) / 2) !important;
        flex: 0 0 calc((100% - 20px) / 2) !important;
        
        flex-shrink: 0 !important;
        scroll-snap-align: start !important;
        aspect-ratio: 1 / 1.2 !important;
    }


    .indicator-wrapper {
        display: block !important;
        width: 100%;
        display: flex;
        justify-content: center; 
        margin: 0;
    }

    .blog-scroll-indicator {
        display: block !important;
        width: 100%;
        max-width: 678px;
        height: 1px !important;
        background: var(--color-border) !important;
        position: relative;
        overflow: visible; 
        transform: scaleY(0.5);
        transform-origin: center;
        margin-left: auto !important;
        margin-right: auto !important;
    }

    .scroll-progress {
        width: 60%; /* Hoặc px cố định như mobile */
        height: 100%;
        background: var(--black) !important;
        position: absolute;
        top: 0;
        left: 0;
        will-change: transform;
    }
}
    







/* --- 4. TABLET NHỎ ( 768px - 991px ): CỤM 2 TRÊN 2 DƯỚI (FIXED) --- */
@media screen and (min-width: 768px) and (max-width: 991px) {
    .firstblog-header { padding: 60px 0; max-width: 720px !important;}
    .firstblog-text-container {
        max-width: 480px !important;
        margin-bottom: 0;
}

    .firstblog-gallery-grid {
        /* Chuyển sang Flex để nuông chiều cái calc width của mày */
        display: flex !important;
        flex-wrap: wrap !important;
        
        /* KHOẢNG CÁCH NGANG: Phải khớp với con số 30px trong hàm calc của mày */
        column-gap: 8px !important; 
        
        /* KHOẢNG CÁCH DỌC: Mày muốn thưa bao nhiêu thì chỉnh ở đây */
        row-gap: 8px !important;    
        
        margin: 20px 0 -20px !important; 
        justify-content: center !important;
    }
    
    .firstblog-gallery-item {
        /* GIỮ NGUYÊN HIỆN TRẠNG ĐỂ ĐỒNG BỘ SLIDE */
        width: calc((100vw - 40px - 8px) / 2) !important;
        flex: 0 0 calc((100vw - 40px - 8px) / 2) !important;
        flex-shrink: 0 !important;
        aspect-ratio: 1 / 1.1 !important;
    }
    
    .firstblog-main-title { font-size: 48px; }
    .firstblog-text-container { max-width: 100%; padding: 20px 0; }
  
}




/* --- 5. MOBILE ( < 767px ) --- */
@media screen and (max-width: 767px) {
    .firstblog-header {
        padding: 0 20px;
    }

    .firstblog-main-title { font-size: 36px; margin-bottom: 20px; }

    .firstblog-text-container h2 {
        font-size: 28px; 
    }

    .firstblog-gallery-grid {
        padding: 20px 20px 0 !important; 
        scroll-padding-left: 20px !important; 
        gap: 9px !important; 
        scroll-snap-type: x mandatory !important; 
        display: flex !important;
        overflow-x: auto !important;
        margin-right: 0;

        scrollbar-width: none; /* Firefox */
       -ms-overflow-style: none; /* IE/Edge */
       -webkit-overflow-scrolling: touch;
    }

    .firstblog-gallery-grid::-webkit-scrollbar {
        display: none !important;
}

    .firstblog-gallery-item { 
        flex: 0 0 85% !important;
        min-width: 100% !important;
        max-width: 100% !important;
        scroll-snap-align: start !important; 
        scroll-snap-stop: always !important;
    }
    
    .firstblog-gallery-item img {
        aspect-ratio: 6/7 !important; 
        margin-bottom: 15px !important;
    }
    
    .indicator-wrapper {
        display: block !important;
        width: 100%;
        display: flex;
        justify-content: center; 
        margin: 0 0 -20px;
    }

    .blog-scroll-indicator {
        max-width: 670px;
        display: block !important;
        width: 100%;
        height: 1px !important; /* Giữ nguyên */
        background: var(--color-border);
        position: relative;
        overflow: hidden;
        /* THÊM DÒNG NÀY ĐỂ NÓ MẢNH NHƯ SỢI CHỈ */
        transform: scaleY(0.5); 
        transform-origin: center;
    }
    
   
    .scroll-progress {
        position: absolute;
        top: 0;
        left: 0;
        height: 100%;
        width: 80px; 
        background-color: var(--black) !important;
        transition: transform 0.1s linear; 
        will-change: transform;
    }
    
    .firstblog-text-container { max-width: 100%; padding: 20px 20px; }
    .casa-container { padding: 0 20px !important; }
    .section-space { padding: 40px 0 !important; } /* Thông số vàng [cite: 2026-02-07] */
}













/* --- 1. BASE STYLES (DESKTOP MẶC ĐỊNH) --- */
.secondblog-header { margin-bottom: 60px;}
.secondblog-main-title {
    font-size: clamp(38px, 5vw, 50px);
    color: var(--black);
}
.secondblog-subtitle {
    font-size: 13px;
    color: var(--black);
    max-width: 650px;
    line-height: 1.6;
}
.secondblog-text-container { max-width: 670px; margin: 0 auto; padding: 30px 0; }
.secondblog-text-container p { font-size: 13px; line-height: 1.6; margin-bottom: 20px; }

/* Ảnh đơn tràn viền */
.secondblog-single-image { width: 100%; margin-top: 40px; margin-bottom: 60px; display: block; overflow: hidden; background-color: var(--gray); }
.secondblog-single-image img { width: 100%; height: auto; aspect-ratio: 16 / 8; display: block; object-fit: cover; transition: transform 1.2s ease; cursor: zoom-in; }

/* Gallery Desktop */
.secondblog-gallery-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px; 
    width: 100%;
    max-width: 1120px; 
    margin: 40px auto !important; 
}
.secondblog-gallery-item { aspect-ratio: 1 / 1.2; overflow: hidden; background-color: var(--gray); margin-bottom: 20px;}
.secondblog-gallery-item img { width: 100%; height: 100%; object-fit: cover; }




/* --- 2. TABLET LỚN ( 992px - 1024px ): DẠNG LƯỚT --- */
@media screen and (min-width: 992px) and (max-width: 1024px) {
    .secondblog-header { padding: 20px 0;}

    .secondblog-gallery-grid {
        display: flex !important;
        gap: 20px !important;
        margin: 40px -20px !important; 
        padding: 0 20px 0 20px !important; 
        scrollbar-width: none !important;
    }

    
    .secondblog-gallery-item {
        width: calc((100vw - 40px - 20px) / 2) !important;
        flex: 0 0 calc((100vw - 40px - 20px) / 2) !important;
    }
}




/* --- 3. TABLET NHỎ ( 768px - 991px ): ÉP THÔNG SỐ RIÊNG BIỆT --- */
@media screen and (min-width: 768px) and (max-width: 991px) {
    
    /* 1. Reset Header & Text theo thông số mày muốn */
    .secondblog-header { 
        padding: 60px 0 !important; 
        max-width: 720px !important; 
        margin-left: auto; 
        margin-right: auto;
        margin-bottom: 20px;
    }
    
    /* 1. ĐẶC TRỊ SINGLE IMAGE - ÉP NÓ RA GIỮA VÀ TRÀN 2 BÊN */
    .secondblog-single-image { 
        width: 100vw !important; /* Ép lấy toàn bộ chiều ngang màn hình */
        position: relative !important;
        left: 50% !important;
        right: 50% !important;
        margin-left: -50vw !important; /* Kéo nó về lại chính giữa từ tâm */
        margin-right: -50vw !important;
        
        margin-top: 20px !important;
        margin-bottom: 40px !important;
        display: block !important;
        overflow: hidden !important;
    }

    .secondblog-single-image img { 
        width: 100% !important; 
        height: auto !important; 
        display: block !important;
        object-fit: cover !important; 
        /* Tỉ lệ ảnh mày muốn, ví dụ 16/9 cho sang */
        aspect-ratio: 16 / 9 !important; 
    }

    /* 2. Giữ mớ text ở giữa 480px như cũ */
    .secondblog-text-container {
        max-width: 480px !important;
        margin-left: auto !important;
        margin-right: auto !important;
        padding: 20px 0 !important;
        /* Đảm bảo text không bị dính vào lề */
    }

    .secondblog-gallery-grid {
        display: flex !important;
        flex-wrap: wrap !important;
        column-gap: 15px !important; 
        width: 100% !important;
        margin: 20px 0 !important;
        justify-content: center !important; 
    }


    .secondblog-gallery-item {
        /* Tính toán bề ngang khớp với lề 20px và gap 30px */
        width: calc((100vw - 40px - 20px) / 2) !important;
        flex: 0 0 calc((100vw - 40px - 20px) / 2) !important;
        aspect-ratio: 1 / 1.1 !important; 
        overflow: hidden !important;
        display: block !important;
        margin-bottom: 20px;
    }

    .secondblog-gallery-item img {
        width: 100% !important;
        height: 100% !important;
        object-fit: cover !important;
    }
}


/* --- 4. MOBILE ( DƯỚI 767px ) --- */
@media (max-width: 767px) {
    .secondblog-header {
        padding: 0 20px;
        margin-top: 10px;
    }

    .secondblog-main-title { 
        font-size: 28px !important; 
        line-height: 1.2;
        margin-bottom: 25px;
        max-width: 90%;
        font-weight: 400;
    }

    .secondblog-subtitle {
        font-size: 12px; 
        line-height: 1.6;
        max-width: 100%;
        color: var(--color-black);
    }

    .secondblog-text-container p {
        font-size: 12px; 
        line-height: 1.6;
        max-width: 100%;
        color: var(--color-black);
    } 

    .secondblog-single-image {
        width: 100vw;
        position: relative;
        left: 50%;
        margin-left: -50vw;
        margin-top: 20px;
        margin-bottom: 40px;
    }

    .secondblog-single-image img { 
        width: 100% !important; 
        height: auto !important; 
        display: block !important;
        object-fit: cover !important; 
        aspect-ratio: 16 / 12 !important; 
    }

    .secondblog-text-container { max-width: 100%; padding: 20px 20px; }

    .secondblog-gallery-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 5px !important;
        margin: 20px 0 !important;
    }
    .casa-container { padding: 0 20px !important; }
    .secondblog-gallery-item { aspect-ratio: 1 / 1.8 !important; }
}








/* ==========================================================================
   THIRD BLOG SECTION - FULL RESPONSIVE SEPARATED
   ========================================================================== */

/* --- 1. BASE STYLES (DÙNG CHUNG) --- */
.thirdblog-header { margin-bottom: 60px;}

.thirdblog-main-title {
    font-size: clamp(38px, 5vw, 50px);
    color: var(--black);
}

.thirdblog-subtitle {
    font-size: 13px;
    color: var(--black);
    max-width: 650px;
    line-height: 1.6;
}

.thirdblog-text-container {
    max-width: 680px;
    margin: 0 auto;
    padding: 30px 0;
}

.thirdblog-text-container p {
    font-size: 13px;
    line-height: 1.6;
    margin-bottom: 20px;
    color: var(--black);
}

.thirdblog-middletext {
    display: block;
    font-size: 11px;
    font-weight: 200;
    color: var(--color-text-muted);
    margin-top: 40px !important;
    margin-bottom: 40px !important;
    text-transform: uppercase;    
}

.thirdblog-gallery-item {
    aspect-ratio: 1/1.2;
    overflow: hidden !important; /* Khóa khung zoom */
    background-color: var(--gray);
}

.thirdblog-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 1.2s cubic-bezier(0.165, 0.84, 0.44, 1);
    cursor: zoom-in;
}

.thirdblog-gallery-item:hover img { transform: scale(1.1); }

.thirdblog-photography-credit {
    font-style: italic;
    color: var(--color-text-muted);
    margin-top: 40px;
    font-size: 14px;
}

.blog-scroll-indicator {
    display: none; /* Mặc định ẩn hết */
    width: 100%;
    height: 2px;
    background: var(--color-border); /* Màu nhạt của web */
    margin-top: 20px;
    position: relative;
}

/* --- 2. DESKTOP ( > 1024px ) --- */
@media screen and (min-width: 1025px) {
    .thirdblog-gallery-grid {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
        padding-top: 40px;
        padding-bottom: 60px;
    }
}

/* --- 3. TABLET LỚN ( 992px - 1024px ): DẠNG LƯỚT NGANG --- */
@media screen and (min-width: 992px) and (max-width: 1024px) {
    .thirdblog-header { padding: 20px 0;}

    .thirdblog-gallery-grid {
        display: flex !important;
        overflow-x: auto !important;
        gap: 20px !important;
        margin: 40px -20px !important; 
        padding: 0 20px 20px 20px !important; 
        scrollbar-width: none !important;
    }
    .thirdblog-gallery-grid::-webkit-scrollbar { display: none !important; }

    .thirdblog-gallery-item {
        width: calc((100vw - 40px - 20px) / 2) !important;
        flex: 0 0 calc((100vw - 40px - 20px) / 2) !important;
        flex-shrink: 0 !important;
        scroll-snap-align: start !important;
    }

    .thirdblog-indicator-wrapper {
        display: block !important;
        width: 100%;
        display: flex;
        justify-content: center; 
        margin-bottom: 60px;
    }

    .thirdblog-scroll-indicator {
        display: block !important;
        width: 100%;
        max-width: 678px;
        height: 1px !important;
        background: var(--color-border) !important;
        position: relative;
        overflow: visible; 
        transform: scaleY(0.5);
        transform-origin: center;
        margin-left: auto !important;
        margin-right: auto !important;
    }

    .scroll-progress {
        width: 60%; /* Hoặc px cố định như mobile */
        height: 100%;
        background: var(--black) !important;
        position: absolute;
        top: 0;
        left: 0;
        will-change: transform;
    }
}
    







/* --- 4. TABLET NHỎ ( 768px - 991px ): CỤM 2 TRÊN 2 DƯỚI (FIXED) --- */
@media screen and (min-width: 768px) and (max-width: 991px) {
    .thirdblog-header { padding: 60px 0; max-width: 720px !important;}
    .thirdblog-text-container {
        max-width: 480px !important;
        margin-bottom: 0;
}

    .thirdblog-gallery-grid {
        /* Chuyển sang Flex để nuông chiều cái calc width của mày */
        display: flex !important;
        flex-wrap: wrap !important;
        
        /* KHOẢNG CÁCH NGANG: Phải khớp với con số 30px trong hàm calc của mày */
        column-gap: 8px !important; 
        
        /* KHOẢNG CÁCH DỌC: Mày muốn thưa bao nhiêu thì chỉnh ở đây */
        row-gap: 8px !important;    
        
        margin: 20px 0 !important; 
        margin-bottom: 40px !important;
        justify-content: center !important;
    }
    
    .thirdblog-gallery-item {
        /* GIỮ NGUYÊN HIỆN TRẠNG ĐỂ ĐỒNG BỘ SLIDE */
        width: calc((100vw - 40px - 8px) / 2) !important;
        flex: 0 0 calc((100vw - 40px - 8px) / 2) !important;
        flex-shrink: 0 !important;
        aspect-ratio: 1 / 1.1 !important;
    }
    
    


    .thirdblog-main-title { font-size: 48px; }
    .thirdblog-text-container { max-width: 100%; padding: 20px 0; }
    .casa-container { padding: 0 20px !important; } 
}




/* --- 5. MOBILE ( < 767px ) --- */
@media screen and (max-width: 767px) {
    .thirdblog-header {
        padding: 0 20px;
    }

    .thirdblog-main-title { font-size: 36px; margin-bottom: 20px; }

    .thirdblog-gallery-grid {
        padding: 20px 20px 0 !important; 
        scroll-padding-left: 20px !important; 
        gap: 9px !important; 
        scroll-snap-type: x mandatory !important; 
        display: flex !important;
        overflow-x: auto !important;
        margin-right: 0;

        scrollbar-width: none; /* Firefox */
       -ms-overflow-style: none; /* IE/Edge */
       -webkit-overflow-scrolling: touch;
    }

    .thirdblog-gallery-grid::-webkit-scrollbar {
        display: none !important;
    }

    .thirdblog-gallery-item { 
        flex: 0 0 85% !important;
        min-width: 100% !important;
        max-width: 100% !important;
        scroll-snap-align: start !important; 
        scroll-snap-stop: always !important;
    }
    
    .thirdblog-gallery-item img {
        aspect-ratio: 6/7 !important; 
        margin-bottom: 15px !important;
    }

    .thirdblog-indicator-wrapper {
        display: block !important;
        width: 100%;
        display: flex;
        justify-content: center; 
        margin: 20px 0 20px;
    }

    .thirdblog-scroll-indicator {
        max-width: 670px;
        display: block !important;
        width: 100%;
        height: 1px !important; /* Giữ nguyên */
        background: var(--color-border);
        position: relative;
        overflow: hidden;
        /* THÊM DÒNG NÀY ĐỂ NÓ MẢNH NHƯ SỢI CHỈ */
        transform: scaleY(0.5); 
        transform-origin: center;
    }
    
   
    .scroll-progress {
        position: absolute;
        top: 0;
        left: 0;
        height: 100%;
        width: 80px; 
        background-color: var(--black) !important;
        transition: transform 0.1s linear; 
        will-change: transform;
    }
    
    .thirdblog-text-container { max-width: 100%; padding: 20px 20px; }
    .casa-container { padding: 0 20px !important; }
    .section-space { padding: 40px 0 !important; } /* Thông số vàng [cite: 2026-02-07] */
}









/* ==========================================================================
   FOURTH BLOG SECTION - FULL RESPONSIVE SEPARATED
   ========================================================================== */

/* --- 1. BASE STYLES (DÙNG CHUNG) --- */
.fourthblog-header { margin-bottom: 60px;}

.fourthblog-main-title {
    font-size: clamp(38px, 5vw, 50px);
    color: var(--black);
}

.fourthblog-subtitle {
    font-size: 13px;
    color: var(--black);
    max-width: 650px;
    line-height: 1.6;
}

.fourthblog-text-container {
    max-width: 680px;
    margin: 0 auto;
    padding: 30px 0;
}

.fourthblog-text-container h2 {
    font-size: clamp(11px, 5vw, 26px);
    line-height: 1.4;
    margin: 0 0 30px;
    font-weight: 400;
}

.fourthblog-text-container p {
    font-size: 13px;
    line-height: 1.6;
    margin-bottom: 20px;
    color: var(--black);
}

.fourthblog-middletext {
    display: block;
    font-size: 11px;
    font-weight: 200;
    color: var(--color-text-muted);
    margin-top: 40px !important;
    margin-bottom: 40px !important;
    text-transform: uppercase;    
}

.fourthblog-gallery-item {
    aspect-ratio: 1/1.2;
    overflow: hidden !important; /* Khóa khung zoom */
    background-color: var(--gray);
}

.fourthblog-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 1.2s cubic-bezier(0.165, 0.84, 0.44, 1);
    cursor: zoom-in;
}

.fourthblog-gallery-item:hover img { transform: scale(1.1); }

.fourthblog-photography-credit {
    font-style: italic;
    color: var(--color-text-muted);
    margin-top: 40px;
    font-size: 14px;
}

.blog-scroll-indicator {
    display: none; /* Mặc định ẩn hết */
    width: 100%;
    height: 2px;
    background: var(--color-border); /* Màu nhạt của web */
    margin-top: 20px;
    position: relative;
}

/* --- 2. DESKTOP ( > 1024px ) --- */
@media screen and (min-width: 1025px) {
    .fourthblog-gallery-grid {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
        padding-top: 40px;
        padding-bottom: 60px;
    }
}

/* --- 3. TABLET LỚN ( 992px - 1024px ): DẠNG LƯỚT NGANG --- */
@media screen and (min-width: 992px) and (max-width: 1024px) {
    .fourthblog-header { padding: 20px 0;}

    /* Giữ nguyên cái CSS cũ của mày bên dưới */
    .fourthblog-gallery-grid {
        display: flex !important;
        overflow-x: auto !important;
        gap: 20px !important;
        margin: 40px -20px !important; 
        padding: 0 20px 20px 20px !important; 
        scrollbar-width: none !important;
    }
    .fourthblog-gallery-grid::-webkit-scrollbar { display: none !important; }

    .fourthblog-gallery-item {
        width: calc((100vw - 40px - 20px) / 2) !important;
        flex: 0 0 calc((100vw - 40px - 20px) / 2) !important;
        flex-shrink: 0 !important;
        scroll-snap-align: start !important;
    }

    .fourthblog-indicator-wrapper {
        display: block !important;
        width: 100%;
        display: flex;
        justify-content: center; 
        margin-bottom: 60px;
    }

    .fourthblog-scroll-indicator {
        display: block !important;
        width: 100%;
        max-width: 678px;
        height: 1px !important;
        background: var(--color-border) !important;
        position: relative;
        overflow: visible; 
        transform: scaleY(0.5);
        transform-origin: center;
        margin-left: auto !important;
        margin-right: auto !important;
    }

    .scroll-progress {
        width: 60%; /* Hoặc px cố định như mobile */
        height: 100%;
        background: var(--black) !important;
        position: absolute;
        top: 0;
        left: 0;
        will-change: transform;
    }
}

    







/* --- 4. TABLET NHỎ ( 768px - 991px ): CỤM 2 TRÊN 2 DƯỚI (FIXED) --- */
@media screen and (min-width: 768px) and (max-width: 991px) {
    .fourthblog-header { padding: 60px 0; max-width: 720px !important;}
    .fourthblog-text-container {
        max-width: 480px !important;
        margin-bottom: 0;
}

    .fourthblog-gallery-grid {
        /* Chuyển sang Flex để nuông chiều cái calc width của mày */
        display: flex !important;
        flex-wrap: wrap !important;
        
        /* KHOẢNG CÁCH NGANG: Phải khớp với con số 30px trong hàm calc của mày */
        column-gap: 8px !important; 
        
        /* KHOẢNG CÁCH DỌC: Mày muốn thưa bao nhiêu thì chỉnh ở đây */
        row-gap: 8px !important;    
        
        margin: 20px 0 !important; 
        margin-bottom: 40px !important;
        justify-content: center !important;
    }
    
    .fourthblog-gallery-item {
        /* GIỮ NGUYÊN HIỆN TRẠNG ĐỂ ĐỒNG BỘ SLIDE */
        width: calc((100vw - 40px - 8px) / 2) !important;
        flex: 0 0 calc((100vw - 40px - 8px) / 2) !important;
        flex-shrink: 0 !important;
        aspect-ratio: 1 / 1.1 !important;
    }
    
    .fourthblog-main-title { font-size: 48px; }
    .fourthblog-text-container { max-width: 100%; padding: 20px 0; }
    .casa-container { padding: 0 20px !important; } 
}




/* --- 5. MOBILE ( < 767px ) --- */
@media screen and (max-width: 767px) {
    .fourthblog-header {
        padding: 0 20px;
    }
    .fourthblog-main-title { font-size: 36px; margin-bottom: 20px; }

    .fourthblog-gallery-grid {
        padding: 20px 20px !important; 
        scroll-padding-left: 20px !important; 
        gap: 9px !important; 
        scroll-snap-type: x mandatory !important; 
        display: flex !important;
        overflow-x: auto !important;
        margin-right: 0;

        scrollbar-width: none; /* Firefox */
       -ms-overflow-style: none; /* IE/Edge */
       -webkit-overflow-scrolling: touch;
    }

    .fourthblog-gallery-grid::-webkit-scrollbar {
        display: none !important;
    }

    .fourthblog-gallery-item { 
        flex: 0 0 85% !important;
        min-width: 100% !important;
        max-width: 100% !important;
        scroll-snap-align: start !important; 
        scroll-snap-stop: always !important;
    }
    
    .fourthblog-gallery-item img {
        aspect-ratio: 6/7 !important; 
        margin-bottom: 15px !important;
    }

    .fourthblog-indicator-wrapper {
        display: block !important;
        width: 100%;
        display: flex;
        justify-content: center; 
        margin: 20px 0 0;
    }

    .fourthblog-scroll-indicator {
        max-width: 670px;
        display: block !important;
        width: 100%;
        height: 1px !important; /* Giữ nguyên */
        background: var(--color-border);
        position: relative;
        overflow: hidden;
        /* THÊM DÒNG NÀY ĐỂ NÓ MẢNH NHƯ SỢI CHỈ */
        transform: scaleY(0.5); 
        transform-origin: center;
    }
    
   
    .scroll-progress {
        position: absolute;
        top: 0;
        left: 0;
        height: 100%;
        width: 80px; 
        background-color: var(--black) !important;
        transition: transform 0.1s linear; 
        will-change: transform;
    }
    
    .fourthblog-text-container { max-width: 100%; padding: 40px 20px 20px; }
    .casa-container { padding: 0 20px !important; }
    .section-space { padding: 40px 0 !important; } /* Thông số vàng [cite: 2026-02-07] */
}





















@media (min-width: 769px) {
    .sanpham-gallery {
       
        padding: 80px 55px; 
        background-color: #fff;
        overflow: hidden;
        
        
        display: block; 
        margin: 0 auto !important;
        max-width: 1650px; 
    }

    
    body {
        background-color: #fff;
    }

    
    .luot-header {
        padding: 0; 
        margin-bottom: 27px; 
    }

    .luot-header .sub-title {
        display: block;
        font-size: 11px;
        font-weight: 200;
        color: #2b2929;
        margin-bottom: 30px !important;
        letter-spacing: 1px;
        text-transform: uppercase;
    }

    .luot-header .main-title {
        font-size: 29px;
        font-weight: 400;
        color: #1a1a1a;
        margin: 0;
        line-height: 1.2;
    }

    .container-luot {
        max-width: 100% !important;
        padding: 0; 
        margin: 0 auto;
    }
    
    .luot-viewport {
        margin-left: -60px; 
        padding-left: 60px; 
        
        overflow: visible;
        margin-right: -10px; 
    }
    
    .luot-track { 
        display: flex; 
        gap: 25px; 
        transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1); 
    }
    .sanpham-card { flex: 0 0 calc(33.333% - 20px); }

    .sanpham-image { 
        position: relative; background-color: #f8f8f8; aspect-ratio: 7/8; 
        overflow: hidden; cursor: pointer;
    }
    .sanpham-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
    
    .quick-add-btn {
        position: absolute; bottom: 20px; left: 50%; transform: translate(-50%, 20px);
        background: #fff; padding: 12px 25px; border-radius: 50px;
        font-weight: 600; font-size: 13px; opacity: 0; transition: all 0.3s ease;
    }
    .sanpham-card:hover .quick-add-btn { opacity: 1; transform: translate(-50%, 0); }
    .sanpham-card:hover img { transform: scale(1.05); }

    .sanpham-info { padding: 7px 0; }
   
    .sanpham-info .name { font-size: 28px; margin: 10px 0; font-weight: 500; color: #1a1a1a; }
    .sanpham-info .desc { font-size: 13px !important; color: var(--color-text-muted); line-height: 1.6; margin-bottom: 15px; }

   .luot-footer {
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        margin-top: -20px;
        padding: 0 !important; 
    }

    .luot-progress-container {
        flex-grow: 1;
        height: 1px;
        background-color: #e5e5e5 !important;
        margin-right: 60px;
        position: relative;
    }

    .luot-progress-bar {
        position: absolute;
        top: 0;
        left: 0;
        height: 3px;
        background-color: #000 !important;
        width: 50%; 
        transition: width 0.6s cubic-bezier(0.25, 1, 0.5, 1);
    }

    .luot-nav {
        display: flex !important;
        gap: 15px !important;
        flex-shrink: 0; 
    }

    .nav-btn {
        border: 2px solid #eee !important;
        background: none;
        width: 55px;
        height: 55px;
        border-radius: 50%;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.3s;
    }
}






.blog-lightbox {
    display: none; 
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    cursor: zoom-out;
    align-items: center;
    justify-content: center;
}

.lightbox-content {
    max-width: 90%;
    max-height: 80%;
    transform: scale(0.8);
    transition: transform 0.3s ease;
}

.blog-lightbox.active .lightbox-content {
    transform: scale(1);
}


.lightbox-close {
    position: absolute;
    top: 30px;
    right: 40px;
    color: #fff;
    font-size: 40px;
    cursor: pointer;
}


.secondblog-single-image img, 
.secondblog-gallery-item img {
    cursor: zoom-in;
}