/*
Theme Name: bonbon
Description: This is a child theme for Flatsome Theme
Author: UX Themes
Template: flatsome
Version: 3.0
*/

/*************** ADD CUSTOM CSS HERE ***************/

/* ================================
   FONT
================================== */
@font-face {
    font-family: 'SVN-Poppins';
    src: url('font/SVN-Poppins.woff2') format('woff2'),
        url('font/SVN-Poppins.woff') format('woff');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'SVN-Poppins';
    src: url('font/SVN-PoppinsMedium.woff2') format('woff2'),
        url('font/SVN-PoppinsMedium.woff') format('woff');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'SVN-Poppins';
    src: url('font/SVN-PoppinsBold.woff2') format('woff2'),
        url('font/SVN-PoppinsBold.woff') format('woff');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

html,
body {
    font-family: 'SVN-Poppins';
    font-weight: 400;
}

h1,
h2,
h3,
h4,
h5 {
    color: #262f5a;
    font-family: 'SVN-Poppins';
    font-weight: 700;
}

.header-bottom li a {
    font-family: 'SVN-Poppins';
    font-weight: 500;
}

/* =========================
   FIX: WP ADMIN BAR (không bị “mất” / bị che)
   - Chỉ tác động khi đã login (body.admin-bar)
========================= */
#wpadminbar {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 999999 !important;
}

html {
    margin-top: 0 !important;
}

body.admin-bar {
    margin-top: 32px !important;
}

@media (max-width:782px) {
    body.admin-bar {
        margin-top: 46px !important;
    }
}

/* ============================================================
   GLOBAL (KHÔNG scope) – dùng nhiều nơi khác
   - QUÀ TẶNG / ƯU ĐÃI
============================================================ */
.flatsome-uudai {
    border: 2px dashed #1e73be;
    border-radius: 10px;
    padding: 18px;
    background: #f9fbff;
    margin: 20px 0;
}

.uudai-header {
    display: flex;
    align-items: center;
    font-size: 18px;
    font-weight: 700;
    color: #1e73be;
    margin-bottom: 12px;
}

.uudai-header i {
    margin-right: 8px;
    font-size: 20px;
}

.uudai-list {
    list-style: none;
    padding-left: 0;
    margin-bottom: 16px;
}

.uudai-list li {
    padding: 8px 0 8px 26px;
    position: relative;
    line-height: 1.6;
}

.uudai-list li::before {
    content: "✔";
    position: absolute;
    left: 0;
    top: 8px;
    color: #2ecc71;
    font-weight: 700;
}

.uudai-list.highlight li::before {
    content: "★";
    color: #f39c12;
}

.uudai-sub {
    background: #fff3cd;
    border-left: 4px solid #f39c12;
    padding: 10px 12px;
    margin-bottom: 12px;
    font-size: 15px;
}

.uudai-sub i {
    color: #f39c12;
    margin-right: 6px;
}

/* ============================================================
   BPF SUMMARY SCOPE (dùng trong hook) – chỉ ẨN phần bị lặp
   (KHÔNG can thiệp màu/nền của mô tả nữa)
============================================================ */
.bpf-summary-scope table.variations,
.bpf-summary-scope form.cart,
.bpf-summary-scope .single_variation_wrap,
.bpf-summary-scope .woocommerce-variation-add-to-cart {
    display: none !important;
}

.bpf-summary-scope nav.woocommerce-breadcrumb,
.bpf-summary-scope .woocommerce-breadcrumb {
    display: none !important;
}

.bpf-summary-scope h1.product-title,
.bpf-summary-scope .product_title,
.bpf-summary-scope .entry-title {
    display: none !important;
}

.bpf-summary-scope {
    margin: 0 !important;
    padding: 0 !important;
}

.bpf-summary-scope>* {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}

/* ============================================================
   SCOPE: CHỈ TRANG J7PRO (bọc bởi div.Shop_box_phone_farm_PC)
============================================================ */

/* Ẩn breadcrumb nằm sau thumbnails (chỉ page này) */
.Shop_box_phone_farm_PC.single-product .product-thumbnails~nav.woocommerce-breadcrumb {
    display: none !important;
}

/* --- Thông số kỹ thuật (bpf-spec-card) --- */
.Shop_box_phone_farm_PC .bpf-spec-card {
    background: #f7f7f9;
    border: 1px solid #edf0f4;
    border-radius: 18px;
    padding: 18px 18px 10px;
}

.Shop_box_phone_farm_PC .bpf-spec-head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.Shop_box_phone_farm_PC .bpf-spec-title {
    font-size: 17px;
    font-weight: 900;
    color: #1f2a44;
}

.Shop_box_phone_farm_PC .bpf-spec-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 12px 0;
    border-top: 1px dashed rgba(0, 0, 0, .08);
}

.Shop_box_phone_farm_PC .bpf-spec-row:first-of-type {
    border-top: 0;
}

.Shop_box_phone_farm_PC .bpf-spec-left {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 200px;
}

.Shop_box_phone_farm_PC .bpf-spec-ico {
    width: 22px;
    text-align: center;
    opacity: .9;
    transform: translateY(-.5px);
}

.Shop_box_phone_farm_PC .bpf-spec-label {
    font-weight: 700;
    color: #1f2a44;
}

.Shop_box_phone_farm_PC .bpf-spec-val {
    font-weight: 900;
    color: #111;
    text-align: right;
    max-width: 55%;
    white-space: normal;
    line-height: 1.35;
}

.Shop_box_phone_farm_PC .bpf-spec-row:hover {
    background: rgba(255, 255, 255, .6);
}

@media (max-width:549px) {
    .Shop_box_phone_farm_PC .bpf-spec-card {
        padding: 16px 14px 8px;
    }

    .Shop_box_phone_farm_PC .bpf-spec-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .Shop_box_phone_farm_PC .bpf-spec-left {
        min-width: 0;
    }

    .Shop_box_phone_farm_PC .bpf-spec-val {
        max-width: 100%;
        text-align: left;
    }
}

/* --- Biến thể (radio) --- */
.Shop_box_phone_farm_PC .variations select,
.Shop_box_phone_farm_PC .bpf-hidden-select {
    display: none !important;
}

.Shop_box_phone_farm_PC table.variations {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 10px 0 8px !important;
}

.Shop_box_phone_farm_PC table.variations th,
.Shop_box_phone_farm_PC table.variations td {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    padding: 0 !important;
    vertical-align: middle;
}

/* Hàng variation dạng flex như bạn đang dùng */
.Shop_box_phone_farm_PC .variations tr {
    display: flex;
    align-items: center;
    gap: 12px;
}

.Shop_box_phone_farm_PC .variations th.label {
    width: auto;
    padding: 0;
    white-space: nowrap;
    font-weight: 600;
}

.Shop_box_phone_farm_PC .variations td.value {
    width: auto;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.Shop_box_phone_farm_PC .bpf-radio-group {
    display: flex;
    gap: 10px;
    flex-wrap: nowrap;
    align-items: center;
}

@media (max-width:549px) {
    .Shop_box_phone_farm_PC .bpf-radio-group {
        flex-wrap: wrap;
    }
}

.Shop_box_phone_farm_PC .bpf-radio input {
    display: none;
}

.Shop_box_phone_farm_PC .bpf-radio span {
    display: inline-block;
    padding: 6px 14px;
    border: 2px solid #ddd;
    border-radius: 6px;
    background: #fff;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s ease;
}

.Shop_box_phone_farm_PC .bpf-radio input:checked+span {
    border-color: #111;
}

/* Reset variations icon */
.Shop_box_phone_farm_PC a.reset_variations[style*="hidden"] {
    opacity: 0;
    pointer-events: none;
}

.Shop_box_phone_farm_PC a.reset_variations {
    visibility: visible !important;
    position: relative;
    width: 28px;
    height: 28px;
    min-width: 28px;
    padding: 0 !important;
    border-radius: 50%;
    border: 1px solid #f3caca;
    background: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0;
    line-height: 1;
    text-decoration: none !important;
}

.Shop_box_phone_farm_PC a.reset_variations::before {
    content: "✕";
    font-size: 14px;
    font-weight: 800;
    color: #d94848;
    line-height: 1;
}

.Shop_box_phone_farm_PC a.reset_variations:hover {
    border-color: #efb4b4;
    background: #fff5f5;
}

.Shop_box_phone_farm_PC a.reset_variations:hover::before {
    color: #b91c1c;
}

/* --- Price box (Giá chỉ từ) – KHÔNG tạo “khung nổi” cho vùng số lượng --- */
.Shop_box_phone_farm_PC .bpf-from-price {
    display: inline-flex;
    align-items: baseline;
    justify-content: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 10px;
    background: #f7f9ff;
    border: 1px solid #e6ecff;
    line-height: 1.2;
    font-weight: 700;
    color: #1f2a44;
    font-size: 16px;
    text-align: center;
}

.Shop_box_phone_farm_PC .bpf-from-price strong {
    display: inline-flex;
    align-items: baseline;
    gap: 8px;
    font-size: 18px;
}

.Shop_box_phone_farm_PC .bpf-from-price del {
    opacity: .55;
    font-weight: 600;
    margin-right: 6px;
}

.Shop_box_phone_farm_PC .bpf-from-price ins {
    text-decoration: none;
    font-weight: 800;
    position: relative;
}

.Shop_box_phone_farm_PC .bpf-from-price ins .woocommerce-Price-amount.amount {
    color: #0a8f3c;
    font-weight: 800;
}

.Shop_box_phone_farm_PC .bpf-from-price .woocommerce-Price-amount.amount {
    font-weight: 800;
}

.Shop_box_phone_farm_PC .bpf-from-price .woocommerce-Price-currencySymbol {
    margin-left: 2px;
    font-weight: 700;
}

.Shop_box_phone_farm_PC .bpf-from-price ins::after {
    content: "SALE";
    display: inline-block;
    margin-left: 10px;
    padding: 3px 8px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
    background: #eafaf1;
    border: 1px solid #bfe8cf;
    color: #0a8f3c;
    transform: translateY(-2px);
}

@media (max-width:549px) {
    .Shop_box_phone_farm_PC .bpf-from-price {
        display: flex;
        flex-wrap: wrap;
        gap: 6px 10px;
    }
}

/* Ẩn price Woo “dư” của variation (chỉ page này) */
.Shop_box_phone_farm_PC.single-product form.variations_form .single_variation,
.Shop_box_phone_farm_PC.single-product form.variations_form .woocommerce-variation-price,
.Shop_box_phone_farm_PC.single-product form.variations_form .single_variation_wrap .price,
.Shop_box_phone_farm_PC.single-product .variations_form .woocommerce-variation.single_variation {
    display: none !important;
}

/* --- SUMMARY: bỏ đóng khung nổi của vùng số lượng bên ngoài + canh lại thứ tự --- */
.Shop_box_phone_farm_PC.single-product .summary.entry-summary {
    /* GIỮ style summary như bạn đang dùng (nếu muốn bỏ luôn thì xóa block này) */
    background: #f7efee;
    border: 1px solid #f0d9d6;
    border-radius: 18px;
    padding: 22px 24px 24px;
    box-shadow: none;

    /* Cho phép sắp xếp lại thứ tự các block */
    display: flex;
    flex-direction: column;
}

.Shop_box_phone_farm_PC.single-product .summary.entry-summary::before {
    content: "";
    display: block;
    height: 3px;
    background: #2e7d32;
    border-radius: 3px;
    margin-bottom: 14px;
}

/* Thứ tự: Thông số -> Giá -> Chọn số lượng/Add to cart */
.Shop_box_phone_farm_PC.single-product .summary.entry-summary .bpf-spec-card {
    order: 10;
}

.Shop_box_phone_farm_PC.single-product .summary.entry-summary .price,
.Shop_box_phone_farm_PC.single-product .summary.entry-summary .bpf-from-price {
    order: 20;
    align-self: center;
    /* căn giữa */
    margin: 12px auto 12px;
    /* nằm “giữa” specs và chọn số lượng */
}

.Shop_box_phone_farm_PC.single-product .summary.entry-summary form.variations_form,
.Shop_box_phone_farm_PC.single-product .summary.entry-summary form.cart {
    order: 30;
}

/* add-to-cart-container: bỏ nền/viền “box” bên ngoài (nếu Flatsome tự thêm) */
.Shop_box_phone_farm_PC.single-product .add-to-cart-container {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    padding: 0 !important;
}

/* form.cart gọn */
.Shop_box_phone_farm_PC.single-product .summary.entry-summary form.cart {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.Shop_box_phone_farm_PC.single-product .summary.entry-summary .quantity {
    margin: 0;
}

.Shop_box_phone_farm_PC.single-product .summary.entry-summary .single_add_to_cart_button {
    padding: 12px 20px;
    font-size: 14px;
    font-weight: 700;
    border-radius: 10px;
}

@media (max-width:768px) {
    .Shop_box_phone_farm_PC.single-product .summary.entry-summary {
        padding: 18px 16px 20px;
        border-radius: 14px;
    }

    .Shop_box_phone_farm_PC.single-product .summary.entry-summary form.cart {
        flex-direction: column;
        align-items: stretch;
    }

    .Shop_box_phone_farm_PC.single-product .summary.entry-summary .single_add_to_cart_button {
        width: 100%;
    }
}

/* ============================================================
   BỎ "Mô tả" mặc định (Woo tabs)
   - Không đổi màu nội dung mô tả
============================================================ */
.Shop_box_phone_farm_PC.single-product .woocommerce-tabs #tab-description>h2,
.Shop_box_phone_farm_PC.single-product .woocommerce-tabs #tab-description>h2:first-child,
.Shop_box_phone_farm_PC.single-product .woocommerce-Tabs-panel--description>h2 {
    display: none !important;
}

/* =====================================================
   FORCE THUMBNAILS = SQUARE (300x300) - Flatsome
   Scope: chỉ trang có .Shop_box_phone_farm_PC
===================================================== */

/* 1) Ô thumbnail vuông (cả wrapper) */
.Shop_box_phone_farm_PC.single-product .product-thumbnails .col,
.Shop_box_phone_farm_PC.single-product .woocommerce-product-gallery__thumbs .col {
    flex: 0 0 300px !important;
    max-width: 300px !important;
}

.Shop_box_phone_farm_PC.single-product .product-thumbnails .col-inner,
.Shop_box_phone_farm_PC.single-product .woocommerce-product-gallery__thumbs .col-inner,
.Shop_box_phone_farm_PC.single-product .product-thumbnails a,
.Shop_box_phone_farm_PC.single-product .woocommerce-product-gallery__thumbs a {
    width: 300px !important;
    height: 300px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    overflow: hidden !important;
    background: #fff !important;
    border-radius: 8px !important;
}

/* 2) Ảnh bên trong luôn nằm gọn trong ô vuông */
.Shop_box_phone_farm_PC.single-product .product-thumbnails img,
.Shop_box_phone_farm_PC.single-product .woocommerce-product-gallery__thumbs img {
    width: 100% !important;
    height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    object-fit: cover !important;
    /* ✅ ô vuông đầy, đồng đều */
    display: block !important;
}

/* 3) Mobile: ô vuông nhỏ lại */
@media (max-width: 849px) {

    .Shop_box_phone_farm_PC.single-product .product-thumbnails .col,
    .Shop_box_phone_farm_PC.single-product .woocommerce-product-gallery__thumbs .col {
        flex: 0 0 90px !important;
        max-width: 90px !important;
    }

    .Shop_box_phone_farm_PC.single-product .product-thumbnails .col-inner,
    .Shop_box_phone_farm_PC.single-product .woocommerce-product-gallery__thumbs .col-inner,
    .Shop_box_phone_farm_PC.single-product .product-thumbnails a,
    .Shop_box_phone_farm_PC.single-product .woocommerce-product-gallery__thumbs a {
        width: 90px !important;
        height: 90px !important;
        border-radius: 6px !important;
    }
}
/* =========================================
   BPF INFO BOX – dùng lại nhiều nơi
========================================= */
.bpf-box-info {
    margin: 16px 0;
    padding: 14px 16px;
    background: #f8fafc;
    border: 1px dashed #d6e2f0;
    border-radius: 10px;
}

.bpf-box-info p {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 0 0 8px;
    font-size: 14px;
    line-height: 1.6;
    color: #1f2a44;
    font-weight: 500;
}

.bpf-box-info p:last-child {
    margin-bottom: 0
}

/* icon flatsome có thể ra <i> hoặc <svg> */
.bpf-box-info i,
.bpf-box-info svg {
    font-size: 16px;
    color: #0a8f3c;
    margin-top: 2px;
    min-width: 18px;
    text-align: center;
}

.bpf-box-info strong {
    font-weight: 800;
    color: #0a8f3c;
}

@media (max-width:768px) {
    .bpf-box-info {
        padding: 12px
    }

    .bpf-box-info p {
        font-size: 13px
    }
}

/* =========================================
   CTA ZALO – ICON + TEXT LIỀN NHAU
   NÚT CHỈ RỘNG THEO NỘI DUNG
========================================= */

.bpf-zalo-cta {
    position: relative;
    display: inline-flex;
    /* 🔥 quan trọng */
    align-items: center;
    gap: 10px;

    padding: 10px 18px 10px 46px;
    /* chừa chỗ icon */
    margin: 12px 0;

    background: linear-gradient(135deg, #0aa84f, #22d36a);
    color: #fff !important;
    font-size: 15px;
    font-weight: 800;
    text-decoration: none !important;

    border-radius: 999px;
    /* dạng pill */
    box-shadow: 0 8px 22px rgba(10, 168, 79, .35);
    white-space: nowrap;
    /* không xuống dòng */
}

/* ICON ZALO PNG */
.bpf-zalo-cta::before {
    content: "";
    position: absolute;
    left: 10px;

    width: 26px;
    height: 26px;

    background-image: url("https://boxphonethanhly.com/wp-content/uploads/2025/12/icon_zalo.png");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;

    background-color: #fff;
    border-radius: 50%;
}

/* SỐ ĐIỆN THOẠI NỔI HƠN */
.bpf-zalo-cta strong {
    font-weight: 900;
    letter-spacing: .3px;
}

/* Hover */
.bpf-zalo-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 28px rgba(10, 168, 79, .45);
}

/* MOBILE */
@media (max-width: 768px) {
    .bpf-zalo-cta {
        font-size: 14px;
        padding: 9px 16px 9px 44px;
    }

    .bpf-zalo-cta::before {
        width: 24px;
        height: 24px;
        left: 9px;
    }
}

/* =====================================================
   GIAO HÀNG TOÀN QUỐC – MÀU XANH ZALO + ANIMATION
===================================================== */

.bpf-ship-banner {
    position: relative;
    display: flex;
    align-items: center;

    width: 100%;
    min-height: 56px;

    padding: 12px 78px 12px 18px;
    margin: 10px 0 14px;

    /* ✅ MÀU XANH GIỐNG NÚT ZALO */
    background: linear-gradient(135deg, #0aa84f, #22d36a);
    border: 1px solid #0aa84f;

    border-radius: 14px;

    font-size: 14px;
    font-weight: 800;
    color: #ffffff;

    box-sizing: border-box;
    overflow: hidden;
}

/* line sáng phía trên */
.bpf-ship-banner::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 3px;
    background: rgba(255, 255, 255, .55);
}

/* ICON SHIPPER */
.bpf-ship-banner::after {
    content: "";
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);

    width: 46px;
    height: 46px;

    background-image: url("https://boxphonethanhly.com/wp-content/uploads/2025/12/shiper.png");
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;

    pointer-events: none;

    /* animation nhẹ */
    animation: bpf-ship-slide 2.5s ease-in-out infinite,
        bpf-ship-pulse 2.5s ease-in-out infinite;
}

/* trượt icon */
@keyframes bpf-ship-slide {

    0%,
    100% {
        transform: translateY(-50%) translateX(0);
    }

    100% {
        transform: translateY(-50%) translateX(-6px);
    }
}

/* pulse sáng nhẹ */
@keyframes bpf-ship-pulse {
    0% {
        filter: drop-shadow(0 0 0 rgba(255, 255, 255, 0));
    }

    50% {
        filter: drop-shadow(0 6px 12px rgba(255, 255, 255, .45));
    }

    100% {
        filter: drop-shadow(0 0 0 rgba(255, 255, 255, 0));
    }
}

/* hover giống nút Zalo */
.bpf-ship-banner:hover {
    filter: brightness(1.05);
}

/* =========================
   MOBILE
========================= */
@media (max-width: 768px) {
    .bpf-ship-banner {
        min-height: 50px;
        padding: 10px 66px 10px 14px;
        font-size: 13px;
        border-radius: 12px;
    }

    .bpf-ship-banner::after {
        width: 38px;
        height: 38px;
        right: 12px;
    }

    @keyframes bpf-ship-slide {

        0%,
        100% {
            transform: translateY(-50%) translateX(0);
        }

        50% {
            transform: translateY(-50%) translateX(-4px);
        }
    }
}