/* Khair Al Watan catalog commerce UI: country of manufacture + piece/carton sales */

/* --- Country flag in Bevesi product cards --- */
.product .product-thumbnail-wrapper .product-buttons .product-button.kaw-origin-flag .kaw-origin-flag-button{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    width:1.625rem;
    height:1.625rem;
    border-radius:50%;
    overflow:hidden;
    background:#fff;
    border:1px solid rgba(15,39,73,.12);
    box-shadow:0 1px 4px rgba(15,39,73,.08);
    cursor:default;
}
.product .product-thumbnail-wrapper .product-buttons .product-button.kaw-origin-flag .kaw-flag-emoji{
    display:flex;
    align-items:center;
    justify-content:center;
    width:100%;
    height:100%;
    font-size:1.18rem;
    line-height:1;
    transform:scale(1.12);
}
@media screen and (min-width:576.1px){
    .product .product-thumbnail-wrapper .product-buttons .product-button.kaw-origin-flag .kaw-origin-flag-button{
        width:1.875rem;
        height:1.875rem;
    }
    /* Adding a fourth icon would otherwise break Bevesi's nth-child hover rules. */
    .products .product .product-thumbnail-wrapper .product-buttons > .product-button:not(:first-child){
        transform:translateX(6px);
        opacity:0;
        visibility:hidden;
    }
    .products .product:hover .product-thumbnail-wrapper .product-buttons > .product-button{
        transform:translateX(0)!important;
        opacity:1!important;
        visibility:visible!important;
    }
}

/* --- Country flag next to wishlist/compare on single product --- */
.single-product-wrapper .single-product-buttons .kaw-origin-single{
    display:inline-flex;
    align-items:center;
    gap:.45rem;
    font-size:.875rem;
    font-weight:500;
    color:currentColor;
}
.kaw-origin-single-badge{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    width:1.72rem;
    height:1.72rem;
    border-radius:50%;
    overflow:hidden;
    border:1px solid #e1e7eb;
    background:#fff;
    box-shadow:0 1px 3px rgba(15,39,73,.08);
    flex:0 0 1.72rem;
}
.kaw-origin-single-badge .kaw-flag-emoji{
    display:flex;
    align-items:center;
    justify-content:center;
    width:100%;
    height:100%;
    font-size:1.18rem;
    line-height:1;
    transform:scale(1.12);
}

/* --- Piece / carton selector --- */
.kaw-unit-selector{
    margin:14px 0 12px;
    padding:14px;
    border:1px solid #dbe3e8;
    border-radius:12px;
    background:#fff;
}
.kaw-unit-selector-title{
    margin-bottom:9px;
    font-size:.9rem;
    font-weight:700;
    color:#0f2749;
}
.kaw-unit-options{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:8px;
}
.kaw-unit-options .kaw-unit-option{
    appearance:none;
    -webkit-appearance:none;
    min-height:58px;
    padding:9px 12px;
    border:1px solid #cad5dd;
    border-radius:10px;
    background:#fff;
    color:#0f2749;
    display:flex;
    flex-direction:column;
    justify-content:center;
    align-items:flex-start;
    gap:3px;
    cursor:pointer;
    text-align:start;
    transition:border-color .15s ease,box-shadow .15s ease,background .15s ease;
}
.kaw-unit-options .kaw-unit-option:hover{
    border-color:#00aba7;
}
.kaw-unit-options .kaw-unit-option.is-active{
    border-color:#00aba7;
    background:rgba(0,171,167,.06);
    box-shadow:0 0 0 1px rgba(0,171,167,.18);
}
.kaw-unit-options .kaw-unit-option.is-disabled,
.kaw-unit-options .kaw-unit-option:disabled{
    opacity:.45;
    cursor:not-allowed;
    background:#f7f9fa;
}
.kaw-unit-option-name{
    font-size:.86rem;
    font-weight:700;
}
.kaw-unit-option-name small{
    font-size:.72rem;
    font-weight:500;
    color:#6d7b88;
}
.kaw-unit-option-price{
    font-size:.82rem;
    font-weight:700;
    color:#0aa34f;
}
.kaw-unit-selection-info{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:10px;
    margin-top:10px;
    padding-top:9px;
    border-top:1px dashed #dbe3e8;
    font-size:.8rem;
    color:#526271;
}
.kaw-unit-current-price{
    font-weight:700;
    color:#0f2749;
}
.kaw-unit-stock-note{
    margin-top:6px;
    font-size:.72rem;
    line-height:1.6;
    color:#788692;
}
.kaw-unit-selector + .quantity,
.kaw-unit-selector ~ .quantity{
    position:relative;
}

@media (max-width:575px){
    .kaw-unit-options{grid-template-columns:1fr;}
    .kaw-origin-single-text{font-size:.78rem;}
}
