﻿/* ==============================================================
   1. Äá»’NG Bá»˜ FONT CHá»® CÃ”NG NGHIá»†P INTER & TRIá»†T TIÃŠU FONT CÅ¨
   (Báº£o vá»‡ Font Awesome khÃ´ng bá»‹ ghi Ä‘Ã¨ thÃ nh Ã´ vuÃ´ng rá»—ng)
============================================================== */
.infas-home-site {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}
.infas-home-site h1, .infas-home-site h2, .infas-home-site h3, .infas-home-site h4, 
.infas-home-site h5, .infas-home-site h6, .infas-home-site p, .infas-home-site label, 
.infas-home-site input, .infas-home-site button, .infas-home-site select, 
.infas-home-site strong, .infas-home-site small, 
.infas-home-site span:not([class*="fa"]):not([class*="bullet"]), 
.infas-home-site a:not([class*="fa"]), .infas-home-site div:not([class*="fa"]) {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}
.infas-home-site .fa, 
.infas-home-site .fas, 
.infas-home-site .far, 
.infas-home-site .fab {
    font-family: "Font Awesome 6 Free", "FontAwesome" !important;
    font-style: normal;
}

/* ==============================================================
   2. BANNER SLIDER CHUáº¨N KÃCH THÆ¯á»šC MECSU (3 BANNER)
============================================================== */
.infas-banner-section {
    padding: 16px 0 10px;
    background: #ffffff;
}
.infas-banner-item {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    aspect-ratio: 2 / 1;
    background: #e2e8f0;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: block;
    text-decoration: none !important;
}
.infas-banner-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.14);
}
.infas-banner-item img {
    width: 100%;
    height: 100%;
    object-fit: contain; /* Hoáº·c cover náº¿u hÃ¬nh gá»‘c Ä‘Ãºng tá»· lá»‡ 2:1. contain sáº½ giÃºp hiá»ƒn thá»‹ trá»n váº¹n banner dÃ¹ sai tá»· lá»‡ */
    background: #ffffff;
    display: block;
}

/* NÃºt Ä‘iá»u hÆ°á»›ng Owl Carousel trÃ²n tráº¯ng */
.owl-theme .owl-nav button.owl-prev,
.owl-theme .owl-nav button.owl-next {
    position: absolute;
    top: 45%;
    transform: translateY(-50%);
    width: 36px;
    height: 36px;
    background: #ffffff !important;
    color: #1e293b !important;
    border-radius: 50% !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.16) !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    font-size: 16px !important;
    z-index: 10;
    border: 1px solid #e2e8f0 !important;
    transition: 0.2s ease;
}
.owl-theme .owl-nav button.owl-prev { left: -14px; }
.owl-theme .owl-nav button.owl-next { right: -14px; }
.owl-theme .owl-nav button.owl-prev:hover,
.owl-theme .owl-nav button.owl-next:hover {
    background: var(--gomi-primary, #1e5ca8) !important;
    color: #ffffff !important;
    border-color: var(--gomi-primary, #1e5ca8) !important;
}

.owl-theme .owl-dots .owl-dot span {
    width: 8px; height: 8px; margin: 0 4px; background: #cbd5e1; border-radius: 10px; transition: 0.3s;
}
.owl-theme .owl-dots .owl-dot.active span {
    width: 22px; background: var(--gomi-primary, #1e5ca8);
}

/* ==============================================================
   3. THANH CAM Káº¾T VÃ€NG B2B
============================================================== */
.infas-commitments-bar {
    background: #ffffff;
    border: 1px solid var(--gomi-light, #e2e8f0);
    border-radius: 12px;
    padding: 12px 20px;
    margin-top: 14px;
    margin-bottom: 25px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.03);
}
.commitment-item {
    display: flex;
    align-items: center;
    gap: 12px;
}
.commitment-item i { font-size: 24px; flex-shrink: 0; }
.commitment-item strong { font-size: 13px; color: #1e293b; display: block; }
.commitment-item small { font-size: 11.5px; color: #64748b; display: block; }

/* ==============================================================
   4. TIÃŠU Äá»€ SECTION CHUáº¨N MECSU
============================================================== */
.infas-sec-wrap {
    padding: 18px 0 25px;
}
.infas-sec-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}
.infas-sec-title {
    font-size: 20px;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: -0.02em;
    margin: 0;
}
.infas-view-more {
    font-size: 13px;
    font-weight: 600;
    color: var(--gomi-primary, #1e5ca8);
    text-decoration: none !important;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: 0.2s;
}
.infas-view-more:hover { gap: 8px; color: #0f3d75; }

/* ==============================================================
   5. KHá»I DANH Má»¤C CÃ”NG NGHIá»†P DÃ€N Äá»€U CÃ‚N Äá»I (MEGA DIRECTORY)
============================================================== */
.mecsu-category-grid {
    display: grid;
    gap: 14px;
    width: 100%;
}
.mecsu-cat-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    transition: all 0.25s ease;
    box-shadow: 0 2px 6px rgba(0,0,0,0.03);
}
.mecsu-cat-card:hover {
    border-color: var(--gomi-primary, #1e5ca8);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
    transform: translateY(-3px);
}
.mecsu-cat-footer {
    margin-top: auto;
    padding-top: 10px;
}
.mecsu-cat-header {
    background: #f1f5f9;
    border-radius: 8px;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    text-decoration: none !important;
}
.mecsu-cat-icon {
    width: 30px; height: 30px; border-radius: 6px; background: #ffffff;
    display: flex; align-items: center; justify-content: center;
    font-size: 15px; color: var(--gomi-primary, #1e5ca8);
}
.mecsu-cat-title { font-size: 13.5px; font-weight: 700; color: #1e293b; margin: 0; }
.mecsu-subcat-list { list-style: none; padding: 0; margin: 0 0 10px 0; }
.mecsu-subcat-link {
    display: flex; align-items: center; gap: 8px; padding: 5px 2px;
    color: #334155; text-decoration: none !important; font-size: 12.8px; font-weight: 500;
}
.mecsu-subcat-link:hover { color: var(--gomi-primary, #1e5ca8); font-weight: 600; padding-left: 5px; }
.mecsu-bullet-icon {
    width: 18px; height: 18px; border-radius: 50%; background: #f1f5f9;
    color: #64748b; display: flex; align-items: center; justify-content: center; font-size: 8px;
}
.mecsu-subcat-link:hover .mecsu-bullet-icon { background: var(--gomi-primary, #1e5ca8); color: #ffffff; }
.mecsu-cat-footer { border-top: 1px dashed #e2e8f0; padding-top: 8px; }
.mecsu-view-all-btn { font-size: 12px; font-weight: 600; color: var(--gomi-primary, #1e5ca8); text-decoration: none !important; }

/* ==============================================================
   6. THáºº Sáº¢N PHáº¨M B2B Äáº¶C TRÆ¯NG MECSU & INFAS (FASTENER CARD)
============================================================== */
/* Äá»’NG Bá»˜ CHIá»€U CAO TUYá»†T Äá»I CHO OWL CAROUSEL */
.product-b2b-carousel .owl-stage {
    display: flex !important;
}
.product-b2b-carousel .owl-stage-outer {
    padding: 6px 0 14px; /* TrÃ¡nh cáº¯t viá»n shadow khi hover */
}
.product-b2b-carousel .owl-item {
    display: flex !important;
    flex: 1 0 auto;
    height: auto !important;
}
.product-b2b-carousel .owl-item .infas-product-card {
    width: 100% !important;
    height: 100% !important;
}

.infas-product-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all 0.25s ease;
    height: 100%;
    position: relative;
    box-sizing: border-box;
}
.infas-product-card:hover {
    border-color: var(--gomi-primary, #1e5ca8);
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
    transform: translateY(-2px);
}

.pcard-body {
    display: flex;
    flex-direction: column;
    flex: 1 0 auto;
}

.pcard-img-wrap {
    height: 145px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
    position: relative;
    background: #ffffff;
}
.pcard-img-wrap img {
    max-height: 135px;
    max-width: 100%;
    object-fit: contain;
    transition: transform 0.3s;
}
.infas-product-card:hover .pcard-img-wrap img {
    transform: scale(1.05);
}
.pcard-sku {
    font-size: 11px;
    color: #94a3b8;
    margin-bottom: 3px;
    font-family: monospace, sans-serif;
    height: 16px;
    line-height: 16px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.pcard-name {
    font-size: 13px;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.35;
    height: 36px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    text-decoration: none !important;
    margin-bottom: 8px;
}
.pcard-name:hover {
    color: var(--gomi-primary, #1e5ca8);
}
.pcard-price-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4px;
    margin-bottom: 3px;
    min-height: 24px;
    height: 24px;
}
.pcard-vat-note {
    font-size: 10.5px;
    color: #059669;
    font-weight: 600;
    margin-top: -2px;
    margin-bottom: 6px;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.pcard-price-left {
    display: flex;
    align-items: baseline;
    gap: 3px;
    white-space: nowrap;
}
.pcard-price {
    font-size: 15.5px;
    font-weight: 800;
    color: var(--gomi-primary, #1e5ca8);
    line-height: 1;
}
.pcard-unit {
    font-size: 11px;
    color: #64748b;
    font-weight: 500;
}
.pcard-moq-badge {
    margin-left: auto;
    background: #e0f2fe;
    color: #0369a1;
    border: 1px solid #bae6fd;
    font-size: 10px;
    font-weight: 700;
    padding: 1px 5px;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
}

/* Bá»™ chá»n sá»‘ lÆ°á»£ng stepper chuáº©n Mecsu */
.pcard-stepper {
    display: flex;
    align-items: center;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    overflow: hidden;
    height: 28px;
    margin-bottom: 6px;
}
.stepper-btn {
    width: 28px;
    height: 100%;
    background: #f8fafc;
    border: none;
    color: #475569;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: 0.15s;
    user-select: none;
}
.stepper-btn:hover { background: #e2e8f0; }
.stepper-input {
    flex: 1;
    border: none;
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    color: #1e293b;
    outline: none;
    width: 100%;
    background: #ffffff;
    height: 100%;
    padding: 0;
}
.stepper-input::-webkit-inner-spin-button,
.stepper-input::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Há»™p liÃªn há»‡ B2B khi hÃ ng bÃ¡o giÃ¡ - giá»¯ Ä‘Ãºng chiá»u cao báº±ng stepper */
.pcard-contact-box {
    height: 28px;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: 6px;
    font-size: 11px;
    color: #64748b;
    font-weight: 600;
}

.pcard-submeta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 11px;
    color: #64748b;
    margin-bottom: 10px;
    height: 18px;
    line-height: 18px;
    white-space: nowrap;
}
.pcard-subtotal-wrap {
    color: #475569;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 60%;
}
.pcard-subtotal-text {
    color: var(--gomi-primary, #1e5ca8);
    font-weight: 700;
}
.pcard-stock-text {
    white-space: nowrap;
    font-size: 10.5px;
    color: #64748b;
    text-align: right;
}

.pcard-action-wrap {
    margin-top: auto;
}
.pcard-btn-add {
    background: #ffb700;
    color: #0f172a;
    border: 1px solid #f59e0b;
    border-radius: 6px;
    height: 33px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12.5px;
    font-weight: 700;
    width: 100%;
    cursor: pointer;
    transition: 0.2s;
    text-align: center;
}
.pcard-btn-add:hover {
    background: #f59e0b;
}
.pcard-btn-add.pcard-btn-contact {
    background: #e0f2fe;
    color: #0369a1;
    border-color: #bae6fd;
}
.pcard-btn-add.pcard-btn-contact:hover {
    background: #bae6fd;
}

.pcard-bottom-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 8px;
    padding-top: 6px;
    border-top: 1px dashed #f1f5f9;
    height: 22px;
}
.pcard-badge-ship {
    color: #16a34a;
    font-size: 11px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
}
.pcard-wishlist {
    color: #94a3b8;
    cursor: pointer;
    transition: 0.2s;
    font-size: 13px;
}
.pcard-wishlist:hover { color: #ef4444; }

/* ==============================================================
   7. Má»¤C "KHÃM PHÃ THÃŠM DANH Má»¤C" Dáº NG ICON TRÃ’N
============================================================== */
.circle-cat-item {
    text-align: center;
    text-decoration: none !important;
    display: block;
    padding: 10px 6px;
}
.circle-cat-thumb {
    width: 86px;
    height: 86px;
    border-radius: 50%;
    background: #f1f5f9;
    margin: 0 auto 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 2px solid #ffffff;
    box-shadow: 0 4px 10px rgba(0,0,0,0.06);
}
.circle-cat-item:hover .circle-cat-thumb {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.12);
    border-color: var(--gomi-primary, #1e5ca8);
}
.circle-cat-name {
    font-size: 12.5px;
    font-weight: 700;
    color: #334155;
    line-height: 1.3;
}
.circle-cat-item:hover .circle-cat-name {
    color: var(--gomi-primary, #1e5ca8);
}

/* ==============================================================
   8. THÆ¯Æ NG HIá»†U ÄÃNG TIN Cáº¬Y
============================================================== */
.brand-partner-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 12px;
}
.brand-partner-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
    transition: 0.25s;
    text-decoration: none !important;
}
.brand-partner-card:hover {
    border-color: var(--gomi-primary, #1e5ca8);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}

/* ==============================================================
   9. BÃ€I VIáº¾T KIáº¾N THá»¨C Ná»”I Báº¬T
============================================================== */
.blog-card-home {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
    text-decoration: none !important;
    display: block;
    transition: 0.25s;
    height: 100%;
}
.blog-card-home:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
    border-color: var(--gomi-primary, #1e5ca8);
}
.blog-thumb-wrap {
    height: 160px;
    overflow: hidden;
}
.blog-thumb-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s;
}
.blog-card-home:hover .blog-thumb-wrap img {
    transform: scale(1.06);
}
.blog-content {
    padding: 14px;
}
.blog-meta-date {
    font-size: 11.5px;
    color: #94a3b8;
    margin-bottom: 6px;
}
.blog-title {
    font-size: 13.5px;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ==============================================================
   RESPONSIVE TOÀN DIỆN CHO TRANG CHỦ: PC / TABLET / MOBILE
============================================================== */
/* LAPTOP & TABLET LỚN (992px - 1199px) */
@media (max-width: 1199px) {
    .mecsu-category-grid { grid-template-columns: repeat(3, 1fr) !important; gap: 12px; }
    .brand-partner-grid { grid-template-columns: repeat(4, 1fr); }
    .infas-commitments-bar .row { row-gap: 12px; }
}

/* TABLET (768px - 991px): 3 CỘT DANH MỤC, 2 CỘT CAM KẾT B2B */
@media (max-width: 991px) {
    .infas-commitments-bar { padding: 12px 14px; margin-bottom: 18px; }
    .infas-commitments-bar .row > div { width: 50% !important; margin-bottom: 8px; }
    .commitment-item { gap: 10px; }
    .commitment-item i { font-size: 20px; }
    .commitment-item strong { font-size: 12.5px; }
    
    .mecsu-category-grid { grid-template-columns: repeat(3, 1fr) !important; gap: 10px; }
    .brand-partner-grid { grid-template-columns: repeat(3, 1fr); gap: 10px; }
    .infas-sec-title { font-size: 18px; }
}

/* MOBILE (< 768px): CHUẨN GIAO DIỆN APP ĐIỆN THOẠI THÔNG MINH */
@media (max-width: 767px) {
    .infas-banner-section { padding: 8px 0 6px; }
    .infas-banner-item { border-radius: 8px; }
    
    /* 4 Cam kết B2B chia 2 Cột x 2 Hàng gọn gàng */
    .infas-commitments-bar { 
        padding: 10px; 
        margin-top: 8px; 
        margin-bottom: 16px; 
        border-radius: 10px;
    }
    .infas-commitments-bar .row {
        margin: 0 -4px;
    }
    .infas-commitments-bar .row > div { 
        width: 50% !important; 
        padding: 4px !important;
    }
    .commitment-item { 
        gap: 8px; 
        padding: 6px 4px;
        background: #f8fafc;
        border-radius: 6px;
    }
    .commitment-item i { font-size: 18px; }
    .commitment-item strong { font-size: 11.5px; line-height: 1.2; }
    .commitment-item small { font-size: 10px; line-height: 1.2; }
    
    /* Danh mục Mecsu LUÔN GIỮ 2 CỘT trên điện thoại */
    .mecsu-category-grid { 
        grid-template-columns: repeat(2, 1fr) !important; 
        gap: 8px !important; 
    }
    .mecsu-cat-card {
        padding: 10px;
        border-radius: 8px;
    }
    .mecsu-cat-head h3 {
        font-size: 12.5px;
    }
    .mecsu-sub-list li a {
        font-size: 11.5px;
        padding: 3px 0;
    }
    
    /* Vòng tròn danh mục */
    .circle-cat-thumb { width: 62px; height: 62px; }
    .circle-cat-name { font-size: 11px; }
    
    /* Tiêu đề section */
    .infas-sec-wrap { padding: 12px 0 18px; }
    .infas-sec-title { font-size: 16px; }
    .infas-view-more { font-size: 11.5px; }
    
    /* Đối tác thương hiệu */
    .brand-partner-grid { 
        grid-template-columns: repeat(2, 1fr) !important; 
        gap: 8px; 
    }
    .brand-partner-item {
        padding: 8px;
        height: 52px;
    }
}
