/*
Theme Name: Hello Elementor Child
Theme URI: https://elementor.com/hello-theme/?utm_source=wp-themes&utm_campaign=theme-uri&utm_medium=wp-dash
Template: hello-elementor
Author: Elementor Team
Author URI: https://elementor.com/?utm_source=wp-themes&utm_campaign=author-uri&utm_medium=wp-dash
Description: Hello Elementor is a lightweight and minimalist WordPress theme that was built specifically to work seamlessly with the Elementor site builder plugin. The theme is free, open-source, and designed for users who want a flexible, easy-to-use, and customizable website. The theme, which is optimized for performance, provides a solid foundation for users to build their own unique designs using the Elementor drag-and-drop site builder. Its simplicity and flexibility make it a great choice for both beginners and experienced Web Creators.
Tags: accessibility-ready,flexible-header,custom-colors,custom-menu,custom-logo,featured-images,rtl-language-support,threaded-comments,translation-ready
Version: 3.4.9.1780991963
Updated: 2026-06-09 07:59:23

*/



.ys-product-card,
.ys-product-card * {
    box-sizing: border-box !important;
}

/* Card tổng */
.ys-product-card {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    border-radius: 30px !important;
    overflow: hidden !important;
    background: #fffdf4 !important;
    border: 2px solid #870004 !important;
    contain: layout paint !important;
}

/* Elementor inner */
.ys-product-card > .e-con-inner {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    border-radius: 28px !important;
}

/* Chặn widget con bung ngang */
.ys-product-card .elementor-widget,
.ys-product-card .elementor-widget-container,
.ys-product-card .elementor-shortcode {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
}

/* Khối ảnh */
.ys-product-card .elementor-widget-shortcode,
.ys-product-card .elementor-widget-shortcode .elementor-widget-container,
.ys-product-card .elementor-shortcode {
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
}

/* Khung ảnh */
.ys-product-card .product-card-hover-image {
    display: block !important;
    position: relative !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    aspect-ratio: 1 / 1 !important;
    overflow: hidden !important;
    background: #f5deb0 !important;
    border-radius: 28px 28px 0 0 !important;
}

/* Ảnh cover */
.ys-product-card .product-card-hover-image__img {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    object-fit: cover !important;
    object-position: center center !important;
    display: block !important;
    transition: opacity 0.35s ease, transform 0.35s ease !important;
}

/* Hover ảnh */
.ys-product-card .product-card-hover-image__img--main {
    opacity: 1 !important;
    z-index: 1 !important;
}

.ys-product-card .product-card-hover-image__img--secondary {
    opacity: 0 !important;
    z-index: 2 !important;
}

.ys-product-card .product-card-hover-image:hover .product-card-hover-image__img--main {
    opacity: 0 !important;
}

.ys-product-card .product-card-hover-image:hover .product-card-hover-image__img--secondary {
    opacity: 1 !important;
}

/* Padding nội dung */
.ys-product-card .elementor-widget-woocommerce-product-title,
.ys-product-card .elementor-widget-woocommerce-product-price,
.ys-product-card .elementor-widget-woocommerce-product-add-to-cart {
    padding-left: 16px !important;
    padding-right: 16px !important;
}

/* Tên sản phẩm */
.ys-product-card .product_title {
    width: 100% !important;
    max-width: 100% !important;
    margin: 14px 0 8px !important;
    padding: 0 !important;
    color: #870004 !important;
    text-align: center !important;
    word-break: break-word !important;
}

/* Giá */
.ys-product-card .price {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 8px !important;
    margin: 0 0 16px !important;
    padding: 0 !important;
    overflow: hidden !important;
}

/* Ẩn text hỗ trợ màn hình khỏi layout */
.ys-product-card .price .screen-reader-text {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    clip: rect(1px, 1px, 1px, 1px) !important;
}

/* Giá sale - sát trái */
.ys-product-card .price ins {
    order: 1 !important;
    flex: 1 1 auto !important;
    min-width: 0 !important;
    max-width: 58% !important;
    margin: 0 !important;
    padding: 0 !important;
    color: #870004 !important;
    text-decoration: none !important;
    text-align: left !important;
    white-space: nowrap !important;
    overflow: hidden !important;
}

/* Giá gốc - sát phải */
.ys-product-card .price del {
    order: 2 !important;
    flex: 0 1 auto !important;
    min-width: 0 !important;
    max-width: 42% !important;
    margin: 0 !important;
    padding: 0 !important;
    color: #9b8a76 !important;
    text-align: right !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    opacity: 0.8 !important;
}

/* Text giá không bung ngang */
.ys-product-card .price ins *,
.ys-product-card .price del * {
    white-space: nowrap !important;
}

/* Sản phẩm chỉ có 1 giá */
.ys-product-card .price > .woocommerce-Price-amount {
    color: #870004 !important;
    white-space: nowrap !important;
}

/* Nút thêm giỏ hàng */
.ys-product-card .elementor-widget-woocommerce-product-add-to-cart {
    padding-bottom: 16px !important;
}

.ys-product-card .elementor-add-to-cart,
.ys-product-card .e-loop-add-to-cart-form-container,
.ys-product-card .cart {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
}

.ys-product-card .add_to_cart_button,
.ys-product-card .button {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 999px !important;
    background: #870004 !important;
    color: #FEEA9D !important;
    border: 1px solid #870004 !important;
    text-align: center !important;
    padding: 12px 14px !important;
    white-space: normal !important;
    word-break: normal !important;
    overflow: hidden !important;
}

.ys-product-card .add_to_cart_button:hover,
.ys-product-card .button:hover {
    background: #b0000a !important;
    color: #fff7cf !important;
}

/* =========================================================
   MOBILE FIX
   Không ép font-size / line-height / font-weight
   Chỉ giữ layout, padding, bo góc, chống tràn
   ========================================================= */

@media (max-width: 767px) {
    .ys-product-card {
        border-radius: 24px !important;
        border-width: 1.5px !important;
        overflow: hidden !important;
    }

    .ys-product-card > .e-con-inner {
        border-radius: 22px !important;
        overflow: hidden !important;
    }

    .ys-product-card .product-card-hover-image {
        border-radius: 22px 22px 0 0 !important;
    }

    .ys-product-card .elementor-widget-woocommerce-product-title,
    .ys-product-card .elementor-widget-woocommerce-product-price,
    .ys-product-card .elementor-widget-woocommerce-product-add-to-cart {
        padding-left: 10px !important;
        padding-right: 10px !important;
    }

    .ys-product-card .product_title {
        margin: 12px 0 8px !important;
    }

    .ys-product-card .price {
        gap: 4px !important;
        margin-bottom: 12px !important;
    }

    .ys-product-card .price ins {
        max-width: 58% !important;
    }

    .ys-product-card .price del {
        max-width: 42% !important;
    }

    .ys-product-card .add_to_cart_button,
    .ys-product-card .button {
        padding: 10px 8px !important;
    }
}

/* Mobile rất nhỏ */
@media (max-width: 390px) {
    .ys-product-card .elementor-widget-woocommerce-product-title,
    .ys-product-card .elementor-widget-woocommerce-product-price,
    .ys-product-card .elementor-widget-woocommerce-product-add-to-cart {
        padding-left: 8px !important;
        padding-right: 8px !important;
    }

    .ys-product-card .add_to_cart_button,
    .ys-product-card .button {
        padding: 9px 6px !important;
    }
}