/* ===== Nhonnguyen Vibali Product Options UI ===== */

/* Product card: giữ card gọn, gần kiểu SAKOS/Stargo */
.woocommerce .product-small .box-text,
.woocommerce .products .product .box-text {
    position: relative;
}

.woocommerce .product-small .product-title,
.woocommerce .products .product .woocommerce-loop-product__title {
    line-height: 1.35;
    margin-bottom: 4px;
}

/* Giá: giá cũ xám, giá sale đỏ */
.woocommerce .product-small .price,
.woocommerce .products .product .price {
    display: flex;
    align-items: baseline;
    gap: 8px;
    flex-wrap: wrap;
    margin: 4px 0 7px;
}

.woocommerce .product-small .price del,
.woocommerce .products .product .price del,
.single-product .summary .price del {
    opacity: .72;
    font-size: .86em;
    font-weight: 500;
}

.woocommerce .product-small .price ins,
.woocommerce .products .product .price ins,
.single-product .summary .price ins {
    color: #e11d2e;
    text-decoration: none;
    font-weight: 800;
}

/* Swatch + size ngoài card */
.nn-vibali-loop-options {
    display: grid;
    gap: 6px;
    margin-top: 7px;
    min-height: 54px;
}

.nn-vibali-loop-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    min-height: 24px;
}

.nn-vibali-loop-label {
    color: #5f6368;
    font-size: 11px;
    font-weight: 600;
    min-width: 29px;
}

.nn-vibali-color-dot {
    --nn-vibali-color: #d8d8d8;
    width: 22px;
    height: 22px;
    display: inline-block;
    flex: 0 0 22px;
    border-radius: 999px;
    background: var(--nn-vibali-color);
    border: 1px solid rgba(0,0,0,.18);
    box-shadow: 0 0 0 2px #fff, 0 0 0 3px rgba(0,0,0,.08);
}

.nn-vibali-size-chip {
    min-width: 34px;
    height: 24px;
    padding: 0 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #d6d8dc;
    border-radius: 6px;
    background: #fff;
    color: #333;
    font-size: 11px;
    line-height: 1;
    font-weight: 600;
}

.nn-vibali-more {
    color: #a17627;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

/* ===== v1.0.3: Swatches Compatibility + Unified Price Label =====
/*
 * Trang chi tiết Vibali đang dùng plugin Swatches riêng.
 * Không can thiệp layout bảng variations và không tạo bộ nút thứ hai.
 * Các selector .nn-vibali-option-* được giữ trong file JS cũ nhưng JS không enqueue.
 */

/* Giá chi tiết nổi bật */
.single-product .summary .price {
    display: flex;
    align-items: baseline;
    gap: 10px;
    flex-wrap: wrap;
}

.single-product .summary .price ins,
.single-product .summary .price > .woocommerce-Price-amount {
    color: #e11d2e;
    font-weight: 800;
}

@media (max-width: 549px) {
    .nn-vibali-loop-options {
        min-height: 48px;
        gap: 5px;
    }

    .nn-vibali-color-dot {
        width: 20px;
        height: 20px;
        flex-basis: 20px;
    }

    .nn-vibali-size-chip {
        min-width: 30px;
        padding: 0 6px;
        font-size: 10px;
    }

}

/* ===== v1.0.3: giá gốc + giá sau giảm ===== */
.nn-vibali-sale-price {
    display: inline-flex !important;
    align-items: baseline !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
}

.nn-vibali-price-prefix {
    color: #111 !important;
    font-weight: 700 !important;
}

.single-product .summary .price .nn-vibali-sale-price del,
.single-product .summary .price del,
.woocommerce .product-small .price del,
.woocommerce .products .product .price del {
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
    color: #777 !important;
    font-size: 16px !important;
    font-weight: 400 !important;
    text-decoration: line-through !important;
    margin: 0 !important;
}

.single-product .summary .price .nn-vibali-sale-price del .amount,
.single-product .summary .price del .amount,
.single-product .summary .price del bdi {
    display: inline !important;
    color: #777 !important;
    font-size: 16px !important;
    font-weight: 400 !important;
    text-decoration: line-through !important;
}

.single-product .summary .price .nn-vibali-sale-price ins,
.single-product .summary .price ins,
.woocommerce .product-small .price ins,
.woocommerce .products .product .price ins {
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
    color: #e00000 !important;
    font-weight: 800 !important;
    text-decoration: none !important;
    margin: 0 !important;
}

.single-product .summary .price .nn-vibali-sale-price ins .amount,
.single-product .summary .price ins .amount,
.single-product .summary .price ins bdi {
    color: #e00000 !important;
    font-size: 25px !important;
    font-weight: 800 !important;
    text-decoration: none !important;
}

.single-product .summary .price .woocommerce-Price-currencySymbol {
    font-size: .68em !important;
    vertical-align: super !important;
}
