/* =========================
   HEADER NEW
========================= */

.site-header { font-family: Arial, sans-serif; }

/* TOP BAR */
/* =========================
   HEADER COLOR CONFIG (FROM DB)
========================= */

/* Top bar */
.header-top {
    background-color: var(--header-top-bg, #802420) !important;
    color: #fff;
    font-size: 13px;
}

/* Header main */
.header-main {
    background-color: var(--header-main-bg, #CB0011) !important;
    padding: 12px 0;
}

/* Footer */
.footer_1 {
    background-color: var(--footer-bg, #CB0011) !important;
    padding-bottom: 20px;
}

/* Submenu */
#cssmenu ul ul li a {
    padding: 14px 20px;
    width: 220px;
    font-size: 16px;
    background-color: var(--submenu-bg, #E13300) !important;
    color: #fff;
    transition: color .2s ease, background-color .2s ease;
    font-family: UVN_Nice;
}


.header-top .container {
    display: flex;
    justify-content: flex-end;
    padding: 6px 0;
}

.header-top a {
    color: #fff;
    margin-left: 15px;
}

/* MAIN */

.header-flex {
    display: flex;
    align-items: center;
    gap: 20px;
}

.header-logo img {
    max-height: 60px;
    width: auto;
}

/* SEARCH */
.header-search { flex: 1; }

.header-search form {
    display: flex;
    background: #fff;
    border-radius: 4px;
    overflow: hidden;
    border: 1px solid #000; /* viền đen */
}


.header-search input {
    flex: 1;
    border: none;
    padding: 10px 12px;
}

.header-search button {
    background: #ff9800;
    border: none;
    color: #fff;
    padding: 0 16px;
}

/* CART */
/* ===== CART WRAPPER ===== */
.header-cart a {
    display: flex;
    align-items: center;
    gap: 8px;

    font-size: 16px;          /* chữ to hơn */
    font-weight: 600;

    padding: 8px 14px;
    border-radius: 20px;

    transition: all .2s ease;
    text-decoration: none;
}

/* Icon giỏ */
.header-cart a::before {
    content: "🛒";
    font-size: 20px;          /* icon to hơn */
}

/* ===== CART COUNT ===== */
.cart-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 22px;
    height: 22px;

    font-size: 13px;
    font-weight: 700;

    padding: 0 6px;
    border-radius: 999px;

    margin-left: 6px;
    transition: all .2s ease;
}
/* Header nền tối */
.header-cart.light a {
    color: #fff;
}

.header-cart.light .cart-count {
    background: #ff7043; /* cam nổi trên nền tối */
    color: #fff;
}

/* Header nền sáng */
.header-cart.dark a {
    color: #000;
}

.header-cart.dark .cart-count {
    background: #ff5722; /* cam đậm nổi trên nền trắng */
    color: #fff;
}


/* MENU */
.header-menu {
    background: #5aa51f;
}

.main-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

.main-menu > li > a {
    padding: 12px 18px;
    color: #fff;
    font-weight: 600;
    display: block;
}

.main-menu > li:hover {
    background: #4a8f1a;
}

/* SUB */
.sub-menu {
    display: none;
    position: absolute;
    background: #fff;
    min-width: 200px;
    top: 100%;
    left: 0;
}

.has-sub:hover .sub-menu {
    display: block;
}
.product-promotion {
    border: 2px dashed red;
    padding: 12px;
    margin: 12px 0;
    background: #fffafa;
    font-size: 14px;
}

.product-promotion ol {
    padding-left: 18px;
}

.product-promotion a {
    color: #0066cc;
    text-decoration: underline;
}
.product-price {
    font-size: 15px;
    font-weight: bold;
}

.product-price .price-currency {
    font-size: 15px;
    vertical-align: super;
    text-decoration: underline;
    margin-left: 2px;
}
#cssmenu, #cssmenu ul, #cssmenu ul li, #cssmenu ul li a, #cssmenu #menu-button {
    display: block;
    position: relative;
    box-sizing: border-box;}

#cssmenu:after, #cssmenu > ul:after {
    content: ".";
    display: block;
    clear: both;
    visibility: hidden;
    line-height: 0;
    height: 0;}

#cssmenu #menu-button {
    display: none;}

#cssmenu{
    z-index:999;}

#cssmenu > ul > li {
    float: left;}

#cssmenu > ul > li > a {
    padding: 15px 26px;
    font-size: 16px;
    font-family:UVN_Nice;
    text-transform: uppercase;
    color: #333;
    transition: color .2s ease;
    border-left:1px solid rgba(125, 125, 125, 0.2);}

#cssmenu > ul > li:last-child > a{
    border-right:1px solid rgba(125, 125, 125, 0.2);}

#cssmenu > ul > li:hover > a, #cssmenu > ul > li.active > a {
    color: #fe8802;}

#cssmenu > ul > li.has-sub > a {
    padding-right: 25px;}

#cssmenu ul ul {
    position: absolute;
    left: -9999px;}

#cssmenu li:hover > ul {
    left: auto;}

#cssmenu ul ul ul {
    margin-left: 100%;
    top: 0;}

#cssmenu ul ul li a {
    padding: 14px 20px;
    width: 220px;
    font-size: 16px;
    background: #7fbb35;
    color: #fff;
    transition: color .2s ease;
    font-family:UVN_Nice;}

#cssmenu ul ul li:hover > a, #cssmenu ul ul li a:hover {
    color: #fff;
    background:#333;
    display:block;}

#cssmenu ul ul li.has-sub > a::after {
    position: absolute;
    top: 13px;
    right: 10px;
    width: 4px;
    height: 4px;
    border-bottom: 1px solid #dddddd;
    border-right: 1px solid #dddddd;
    content: "";
    transform: rotate(-45deg);
    transition: border-color 0.2s ease;}

#cssmenu ul ul li.has-sub:hover > a::after {
    border-color: #ffffff;}

@media all and (max-width: 768px), only screen and (-webkit-min-device-pixel-ratio: 2) and (max-width: 768px), only screen and (min--moz-device-pixel-ratio: 2) and (max-width: 768px), only screen and (-o-min-device-pixel-ratio: 2/1) and (max-width: 768px), only screen and (min-device-pixel-ratio: 2) and (max-width: 768px), only screen and (min-resolution: 192dpi) and (max-width: 768px), only screen and (min-resolution: 2dppx) and (max-width: 768px) {
    #cssmenu {
        width: 100%;}

    #cssmenu ul {
        width: 100%;
        display: none;}

    #cssmenu ul li, #cssmenu ul ul li,  #cssmenu ul li:hover > ul > li {
        width: 100%;
        height: auto;
        border-top: 1px solid rgba(120, 120, 120, 0.15);}

    #cssmenu ul li a, #cssmenu ul ul li a {
        width: 100%;}

    #cssmenu ul ul li a {
        padding: 12px 20px 12px 40px;
        font-size: 15px;
        color: #777;
        background: none;}

    #cssmenu ul ul li:hover > a,  #cssmenu ul ul li a:hover {
        color: #fff;}

    #cssmenu ul ul ul li a {
        padding-left: 40px;}

    #cssmenu ul ul, #cssmenu ul ul ul {
        position: relative;
        left: 0;
        right: auto;
        width: 100%;
        margin: 0;}

    #cssmenu > ul > li.has-sub > a::after,  #cssmenu ul ul li.has-sub > a::after {
        display: none;}

    #cssmenu #menu-button {
        display: block;
        padding: 15px 10px;
        font-family:UVN_Nice;
        color: #333;
        cursor: pointer;
        font-size: 15px;
        text-transform: uppercase;
        border:1px solid rgba(125, 125, 125, 0.5);}

    #cssmenu #menu-button::after {
        content: '';
        position: absolute;
        top: 32px;
        right: 10px;
        display: block;
        width: 25px;
        height: 2px;
        background: #333333;}

    #cssmenu #menu-button::before {
        content: '';
        position: absolute;
        top: 20px;
        right: 10px;
        display: block;
        width: 25px;
        height: 8px;
        border-top: 2px solid #333333;
        border-bottom: 2px solid #333333;}

    #cssmenu .submenu-button {
        position: absolute;
        z-index: 10;
        right: 0;
        top: 0;
        display: block;
        border-left: 1px solid rgba(120, 120, 120, 0.15);
        height: 52px;
        width: 52px;
        cursor: pointer;}

    #cssmenu .submenu-button::after {
        content: '';
        position: absolute;
        top: 21px;
        left: 26px;
        display: block;
        width: 1px;
        height: 11px;
        background: #333333;
        z-index: 99;}

    #cssmenu .submenu-button::before {
        content: '';
        position: absolute;
        left: 21px;
        top: 26px;
        display: block;
        width: 11px;
        height: 1px;
        background: #333333;
        z-index: 99;}

    #cssmenu .submenu-button.submenu-opened:after {
        display: none;}
}
/* ===============================
   MENU COLOR OVERRIDE ONLY
   (no layout / no UI change)
================================ */

/* Menu cấp 1 hover & active dùng màu header-top */
#cssmenu > ul > li:hover > a,
#cssmenu > ul > li.active > a {
    color: var(--header-top-bg, #802420);
}

/* Submenu dùng biến nền */
#cssmenu ul ul li a {
    background-color: var(--submenu-bg, #7fbb35) !important;
    color: var(--submenu-text, #fff) !important;
}

/* Hover submenu: giữ UI cũ, chỉ đổi màu chữ nếu cần */
#cssmenu ul ul li:hover > a,
#cssmenu ul ul li a:hover {
    background-color: var(--submenu-hover-bg, #333) !important;
    color: var(--submenu-text-hover, #fff) !important;
}
/* ===============================
   HEADER TOP – TEXT CONTRAST
================================ */

/* Màu chữ mặc định lấy từ biến */
.header-top .top-right,
.header-top .top-right span,
.header-top .top-right strong,
.header-top .top-right a {
    color: var(--header-top-text, #fff);
}

/* Link hover */
.header-top .top-right a:hover {
    text-decoration: underline;
    opacity: .9;
}

.product{
    border: 1px solid #eee;
    padding: 10px;
    min-height: 430px;
    position: relative;
    background: #fff;
}

.product img{
    width: 100%;
    height: 200px;
    object-fit: contain;
}

.product h5 a{
    color:  #7FBB35;
    font-size:17px;
    font-weight:bold;
    margin:15px 0 5px;
    display:block;}
.product p{
    max-height: 60px;
    overflow: hidden;
    font-size: 13px;
    color: #555;
}

.add_cart{
    position: absolute;
    bottom: 10px;
    left: 10px;
    right: 10px;
}

.add_cart a{
    display: block;
    text-align: center;
    padding: 8px 0;
    background: #f57224;
    color: #fff;
    font-weight: bold;
    border-radius: 3px;
    text-decoration: none;
}

.add_cart a:hover{
    background: #e55b0a;
}
.menu-icon{
    font-size: 18px;
    margin-right: 6px;
    position: relative;
    top: 1px;
}


.float-contact{
    position: fixed;
    right: 20px;
    bottom: 90px;
    z-index: 999999;
}

.float-btn{
    width: 54px;
    height: 54px;
    margin-top: 12px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 14px rgba(0,0,0,.35);
    transition: transform .2s ease;
}

.float-btn:hover{
    transform: scale(1.08);
}

.float-btn img{
    width: 32px;
    height: 32px;
}

.float-btn.zalo{
    background: #0068ff;
}

.float-btn.messenger{
    background: linear-gradient(45deg,#0084ff,#5b3fff);
}
.float-btn.facebook{
    background: #1877f2;
}
/* ===== MOBILE FIX FLOAT CONTACT (QUAN TRỌNG) ===== */

/* gỡ transform khỏi body / html */
html, body{
    transform: none !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
}

/* gỡ transform khỏi các wrapper mobile */
.site-header,
.header-main,
.Zeptain_LT,
#main,
.container,
.container-fluid{
    transform: none !important;
    overflow: visible !important;
}

/* ép float-contact vượt mọi layer */
.float-contact{
    position: fixed !important;
    right: 12px !important;
    bottom: 80px !important;
    z-index: 2147483647 !important;
    display: flex !important;
    flex-direction: column;
    pointer-events: auto !important;
}
.float-contact{
    position: fixed;
    right: 14px;
    bottom: 80px;
    z-index: 2147483647;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* TOGGLE BUTTON */
.float-toggle{
    width: 54px;
    height: 54px;
    border-radius: 50%;
    background: #ff7a00;
    color: #fff;
    font-size: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,.4);
    margin-bottom: 10px;
}

/* CHAT BUTTON */
.float-btn{
    width: 50px;
    height: 50px;
    margin-bottom: 10px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(0,0,0,.35);
    transition: all .25s ease;
}

.float-btn img{
    width: 28px;
    height: 28px;
}

/* MÀU */
.float-btn.zalo {
    background: var(--header-top-bg);
}

.float-btn.messenger {
    background: var(--header-top-bg);
}

.float-btn.facebook {
    background: var(--header-top-bg);
}

/* ===== TRẠNG THÁI THU GỌN ===== */
.float-contact.collapsed .float-btn{
    opacity: 0;
    transform: translateY(10px) scale(0.5);
    pointer-events: none;
    height: 0;
    margin: 0;
}

/* MOBILE TO HƠN */
@media (max-width: 768px){
    .float-toggle{ width:58px; height:58px; }
    .float-btn{ width:52px; height:52px; }
}
/* ================================
   FIX ẢNH TRONG BÀI VIẾT (MOBILE)
   ================================ */
@media (max-width: 768px) {
    .content_view img {
        max-width: 100% !important;
        height: auto !important;
        display: block;
        margin: 10px auto;
    }

    /* Nếu ảnh quá cao (ảnh dọc) */
    .content_view img {
        max-height: 300px;
        object-fit: contain;
    }
}
/* =====================================
   PRODUCT VIEW – ẢNH TRONG MÔ TẢ (MOBILE)
   ===================================== */
@media (max-width: 768px) {
    #detail_product p img,
    #detail_product .content img {
        max-width: 100% !important;
        height: auto !important;
        display: block;
        margin: 10px auto;
        max-height: 280px;
        object-fit: contain;
    }
}
/* ===============================
   HEADER MOBILE – FIX CỨNG GRID
   =============================== */
@media (max-width: 768px) {

    .header-main .header-flex {
        display: grid;
        grid-template-columns: 1fr auto;
        grid-template-areas:
                "logo cart"
                "search search";
        row-gap: 8px;
        align-items: center;
    }

    /* LOGO */
    .header-logo {
        grid-area: logo;
    }

    .header-logo img {
        max-height: 38px;
        width: auto;
    }

    /* CART */
    .header-cart {
        grid-area: cart;
        text-align: right;
        white-space: nowrap;
    }

    .header-cart a {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        font-size: 13px;
    }

    /* SEARCH */
    .header-search {
        grid-area: search;
        width: 100%;
    }

    .header-search form {
        display: flex;
        width: 100%;
    }

    .header-search input {
        flex: 1;
        height: 36px;
        font-size: 14px;
    }

    .header-search button {
        width: 44px;
        height: 36px;
    }
}
/* ===============================
   HEADER TOP – USER BAR MOBILE
   =============================== */
@media (max-width: 768px) {

    .user-bar {
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 6px;
        font-size: 13px;
    }

    .user-name {
        flex: 1;
        font-weight: 600;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .user-btn {
        padding: 6px 10px;
        border-radius: 16px;
        font-size: 12px;
        white-space: nowrap;
    }

    .user-btn.account {
        background: rgba(255,255,255,.25);
        color: #fff;
    }

    .user-btn.logout {
        background: #ff5722;
        color: #fff;
    }

    .user-btn.login {
        background: rgba(255,255,255,.25);
        color: #4caf50;
        font-weight: 600;
    }

    .user-btn.register {
        background: rgba(255,255,255,.25);
        color: #fff;
    }
}
/* ===============================
   CONTACT MAP – RESPONSIVE MOBILE
   =============================== */
.map-embed {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 */
    overflow: hidden;
    border-radius: 8px;
}

.map-embed iframe,
.map-embed embed,
.map-embed object {
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important;
    height: 100% !important;
    border: 0;
}
/* ===============================
   SECTION TITLE – RIBBON + LINE
   =============================== */
.section-title {
    display: inline-block;
    position: relative;
    padding: 10px 20px;
    background: var(--header-top-bg);
    color: #fff;
    font-size: 18px;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 10px;
    z-index: 1;
}

/* ĐUÔI XÉO */
.section-title::after {
    content: "";
    position: absolute;
    top: 0;
    right: -30px;
    width: 0;
    height: 30px;
    border-top: 40px solid transparent;
    border-bottom: 0px solid transparent;
    border-left: 30px solid #000000;
}

/* ĐƯỜNG KẺ NGANG */
.section-title::before {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    height: 2px;
    width: 37vw;              /* kéo dài */
    background: var(--header-top-bg);
    margin-left: 30px;         /* né phần xéo */
}
@media (max-width: 768px) {
    .section-title::before {
        content: "";
        position: absolute;
        left: 0;
        bottom: 0;
        height: 2px;
        width: 90vw;              /* kéo dài */
        background: var(--header-top-bg);
        margin-left: 30px;         /* né phần xéo */
    }
}
/* ===============================
   MOVE ASIDE BELOW CONTENT – MOBILE
   =============================== */
@media (max-width: 768px) {

    .row.margin0 {
        display: flex;
        flex-direction: column;
    }

    .content-col {
        order: 1;
    }

    .aside-col {
        order: 2;
        margin-top: 15px;
    }

}
/* ===============================
   PRODUCT SLOGAN – RESPONSIVE
   =============================== */

/* MOBILE: info bar gọn */
.product-slogan-mobile {
    display: none;
}

@media (max-width: 768px) {

    .product-slogan-desktop {
        display: none;
    }

    .product-slogan-mobile {
        display: flex;
        align-items: center;
        gap: 14px;
        padding: 8px 10px;
        margin: 10px 0;
        background: #f6f6f6;
        border-radius: 6px;
        font-size: 13px;
        overflow-x: auto;
    }

    .product-slogan-mobile::-webkit-scrollbar {
        display: none;
    }


    .product-slogan-mobile .slogan-item {
        position: relative;
        padding-right: 14px;
        margin-right: 10px;
    }

    .product-slogan-mobile .slogan-item:not(:last-child)::after {
        content: "|";
        position: absolute;
        right: 0;
        top: 50%;
        transform: translateY(-50%);
        color: #bbb;
        font-weight: 400;
    }
}

/* DESKTOP giữ nguyên layout cũ */
@media (min-width: 769px) {
    .product-slogan-desktop {
        display: block;
    }
}
.product-price {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin: 6px 0;
}

.price-final {
    color: #ff6a00;
    font-weight: 700;
    font-size: 19px;
}

.price-old {
    color: #888;
    font-size: 12px;
    text-decoration: line-through;
}


/* icon */
.btn-add-cart i {
    font-size: 16px;
}

/* hover */
.btn-add-cart:hover {
    background: #e74c3c;
    color: #fff;
}

/* hover icon */
.btn-add-cart:hover i {
    color: #fff;
}
.btn-add-cart {
    display: inline-flex;
    align-items: center;     /* ⭐ căn giữa theo chiều dọc */
    justify-content: center;

    height: 45px;
    padding: 0 22px;

    border: 2px solid #ff3b30;
    border-radius: 4px;

    background: #fff;
    color: #ff3b30;

    font-size: 15px;
    font-weight: 500;
    font-style: italic;      /* giữ nghiêng */
    box-sizing: border-box;
}

/* wrapper <a> */
.btn-buy-wrap {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

/* nút ĐẶT HÀNG */
.button_cart {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    height: 48px;
    padding: 0 26px;

    background-color: #ff8c00; /* cam đặt hàng */
    color: #fff;

    font-size: 15px;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;

    border-radius: 4px;
    border: none;

    box-sizing: border-box;
    white-space: nowrap;

    cursor: pointer;
    transition: background-color 0.25s ease;
}

/* hover */
.button_cart:hover {
    background-color: #ff7a00;
}
