/*
Theme Name: Betheme Child
Theme URI: https://themes.muffingroup.com/betheme
Author: Muffin group
Author URI: https://muffingroup.com
Description: Child Theme for Betheme
Template: betheme
Version: 2.0.2
*/

@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;600;700;800;900&display=swap');

/* Fix submenu gap when header is not sticky */
#Top_bar:not(.is-sticky) .menu > li > ul {
    margin-top: 0 !important;
    top: 100% !important;
}

/* Change mobile menu expand toggle (+ icon) color */
#menu ul li.menu-item-has-children > a::after,
#menu ul li.menu-item-has-children .menu-toggle,
.mfn-menu-toggle {
    color: #C08552 !important;
}

/* Change mobile menu hamburger button (3 lines) color */
.responsive-menu-toggle,
.responsive-menu-toggle i,
.responsive-menu-toggle span,
.responsive-menu-toggle .icon-menu-fine {
    color: #C08552 !important;
}

/* Change cart badge background color to #C08552 */
#header_cart .header-cart-count,
a#header_cart span.header-cart-count,
.top_bar_right_wrapper .header-cart-count,
.header-cart-count {
    background-color: #C08552 !important;
    border-color: #C08552 !important;
    color: #ffffff !important;
}




/* --- CUSTOM CONTACT FORM (HÌNH 2) --- */

/* 1. Blurred Background for the Section */
.custom-contact-section {
    position: relative;
}

.custom-contact-section::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    background: rgba(255, 255, 255, 0.1); 
    z-index: 1;
}

.custom-contact-section .section_wrapper {
    position: relative;
    z-index: 2;
}

/* 2. The Main Card (Wrap) */
.custom-contact-card {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.15);
    overflow: hidden; 
    display: flex !important;
    flex-wrap: wrap;
    align-items: stretch;
}

/* 3. Columns Layout */
.custom-contact-card .mcb-column {
    float: none !important;
    margin: 0 !important;
    width: 50% !important;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* 4. The Form Column (Moved to right) */
.custom-form-col {
    order: 2; 
    padding: 60px 50px !important;
    background: #ffffff;
}

/* 5. The Image Column (Moved to left) */
.custom-image-col {
    order: 1; 
    padding: 0 !important;
    background-size: cover !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
}

/* Remove default padding/margin in BeBuilder image elements if used */
.custom-image-col .image_wrapper {
    height: 100%;
}
.custom-image-col .image_wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Style the form button to match Image 2 */
.custom-form-col input[type="submit"], 
.custom-form-col button {
    background-color: #0d6efd !important; /* Blue color like Image 2 */
    color: #fff !important;
    border-radius: 8px !important;
    width: 100%;
    padding: 15px !important;
    font-weight: 600;
}


/* Responsive adjustments for mobile */
@media (max-width: 767px) {
    .custom-contact-card {
        flex-direction: column;
    }
    .custom-contact-card .mcb-column {
        width: 100% !important;
    }
    .custom-form-col {
        order: 2;
        padding: 30px !important;
    }
    .custom-image-col {
        order: 1;
        min-height: 350px; 
    }

    /* Grid layout for "Lĩnh vực kinh doanh" section on mobile (2 columns, 2 rows) */
    body.home .mcb-section-h6r08jrai > .section_wrapper {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 12px !important;
        padding-left: 15px !important;
        padding-right: 15px !important;
    }

    /* Title wrap spans across both grid columns */
    body.home .mcb-section-h6r08jrai > .section_wrapper > .mcb-wrap:first-child {
        grid-column: span 2 !important;
        width: 100% !important;
        margin-bottom: 10px !important;
    }

    /* Column wraps representing the category cards (only target .one-sixth to avoid matching 'Về chúng tôi') */
    body.home .mcb-section-h6r08jrai > .section_wrapper > .mcb-wrap.one-sixth {
        width: 100% !important;
        margin: 0 !important;
        grid-column: span 1 !important;
    }

    /* Shrink the inner box padding to fit mobile viewports nicely */
    body.home .mcb-section-h6r08jrai > .section_wrapper > .mcb-wrap.one-sixth .column_attr {
        padding: 25px 10px 15px !important;
        border-radius: 16px !important;
    }

    /* Scale down SVG icons inside the boxes */
    body.home .mcb-section-h6r08jrai > .section_wrapper > .mcb-wrap.one-sixth img {
        height: 50px !important;
        width: auto !important;
        margin: 0 auto !important;
        display: block !important;
    }

    body.home .mcb-section-h6r08jrai > .section_wrapper > .mcb-wrap.one-sixth h4 {
        font-size: 14px !important;
        margin-top: 10px !important;
        margin-bottom: 0 !important;
    }

    /* Fix order of image and text for section 02 and 04 on About Us page on mobile */
    .page-id-8 .mcb-section-0wn31s051 .section_wrapper,
    .page-id-8 .mcb-section-w8vzb6tyq .section_wrapper {
        display: flex !important;
        flex-direction: column-reverse !important;
    }
}

/* Typography: Headings 1-6 */
h1, h2, h3, h4, h5, h6, 
.entry-title, .title, 
.mcb-column-inner h1, .mcb-column-inner h2, .mcb-column-inner h3, 
.mcb-column-inner h4, .mcb-column-inner h5, .mcb-column-inner h6 {
    font-family: 'Roboto', sans-serif !important;
}

h1, .mcb-column-inner h1 { font-size: 42px; font-weight: 700; line-height: 1.2; margin-bottom: 24px; }
h2, .mcb-column-inner h2 { font-size: 32px; font-weight: 700; line-height: 1.3; margin-bottom: 20px; }
h3, .mcb-column-inner h3 { font-size: 26px; font-weight: 600; line-height: 1.3; margin-bottom: 16px; }
h4, .mcb-column-inner h4 { font-size: 20px; font-weight: 600; line-height: 1.4; margin-bottom: 12px; }
h5, .mcb-column-inner h5 { font-size: 18px; font-weight: 500; line-height: 1.4; margin-bottom: 8px; }
h6, .mcb-column-inner h6 { font-size: 16px; font-weight: 500; line-height: 1.5; margin-bottom: 8px; }

/* Mobile Heading Sizes */
@media (max-width: 767px) {
    h1, .mcb-column-inner h1 { font-size: 32px; }
    h2, .mcb-column-inner h2 { font-size: 26px; }
    h3, .mcb-column-inner h3 { font-size: 22px; }
    h4, .mcb-column-inner h4 { font-size: 18px; }
    h5, .mcb-column-inner h5 { font-size: 16px; }
    h6, .mcb-column-inner h6 { font-size: 14px; }
}

/* Fix for homepage counters that use H1 tags */
.home .mcb-section-inner-isysggunb .column_attr h1 {
    font-size: 70px !important;
    font-weight: 400 !important;
}
@media (max-width: 767px) {
    .home .mcb-section-inner-isysggunb .column_attr h1 {
        font-size: 50px !important;
    }
}

/* Force 1:1 Aspect Ratio for Default BeTheme WooCommerce Grid Images */
.product-loop-thumb .image_wrapper {
    position: relative;
    padding-top: 100%;
    overflow: hidden;
    background-color: #f7f7f7;
}
.product-loop-thumb .image_wrapper > a {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: block;
}
.product-loop-thumb .image_wrapper img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
}
