/* Global swatches settings */
.sp-smart-swatches-container * {
    box-sizing: border-box;
}

.sp-smart-swatches-container input,
.sp-smart-swatches-container input:focus {
    outline: none;
    border: none;
}

.sp-smart-swatches-label {
    display: flex;
    /* flex-flow: wrap; */
    flex-wrap: wrap;
    padding: 0;
    position: relative;
    box-sizing: border-box;
    grid-gap: 8px;
    /* width: fit-content; */
}

.sp-smart-swatches-container {
    display: flex;
    /* flex-flow: wrap; */
    flex-wrap: wrap;
    padding: 0;
    position: relative;
    box-sizing: border-box;
    grid-gap: 8px;
    padding-left: 2px;
    padding-right: 10px;
    padding-top: 8px;
    padding-bottom: 8px;
    /* width: fit-content; */
}

.sp-smart-swatches-item {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    -webkit-transition: 200ms;
    transition: 200ms;
    text-align: center;
    white-space: nowrap;
    line-height: 1.3;
    cursor: pointer;
    outline: 1px solid #fff;
    background: #fff;
    user-select: none;
    transition: all 0.11s;
}

.sp-smart-swatches-item.sp-smart-swatch-image-option-with-label {
    gap: 6px;
}

.sp-smart-swatch-label-option,
.sp-smart-image-option {
    border: 1px solid #ddd;
}

.sp-smart-swatches-item .sp-smart-swatches-inner {
    display: flex;
    width: calc(100% - 2px);
    height: calc(100% - 2px);
    border-radius: inherit;
    -webkit-transition: 200ms;
    transition: 200ms;
    align-items: center;
    justify-content: center;
}

.out-of-stock-smart-swatch,
.sp-smart-swatches-disabled,
.sp-smart-swatches-out-of-stock {
    opacity: 0.8;
    /* pointer-events: none; */
    cursor: default;
}

.sp-smart-image-option {
    background-repeat: no-repeat;
    background-position: center;
}

.sp-smart-swatch-image-option-with-label .sp-smart-swatches-inner {
    height: 24px;
    width: 24px;
    border: none;
}

.sp-smart-swatch-label-option {
    font-size: 12px;
    padding: 5px 10px;
}

.smart-swatches-hide-disable {
    display: none;
}

.sp-smart-hidden-select {
    display: none !important;
}

.smart-swatches-blur-disable::before,
.smart-swatches-blur::before {
    content: "";
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    background-color: #fff;
    opacity: 0.4;
    -webkit-transition: all 200ms;
    transition: all 200ms;
}

.smart-swatch-slider-box {
    position: relative;
    margin: 0 15px;
}

.smart-swatches-blur {
    opacity: 0.6 !important;
}

.smart-swatches-cross::before {
    background-repeat: no-repeat;
    background-position: center;
    background-size: 22px 22px;
    content: "";
    color: rgba(204, 69, 69, 1);
    position: absolute;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    z-index: 9999;
}

/* Swatches tooltip css */
.sp-smart-tooltip {
    position: absolute;
    min-width: 10px;
    min-height: 10px;
    padding: 0.2em 0.5em;
    content: "";
    background: #000;
    color: #fff;
    border-radius: 5px;
    font-size: 0.8em;
    left: 50%;
    transform: translateX(-50%) translateY(-50%);
    display: none;
    border: 1px solid;
}

.sp-smart-tooltip::before {
    content: "";
    position: absolute;
    width: 9px;
    height: 9px;
    bottom: -5px;
    left: calc(50% - 4px);
    transform: rotate(45deg);
    background: #000;
    border-top-left-radius: 10px;
    z-index: -1;
    border-right: 1px solid;
    border-bottom: 1px solid;
}

.sp-smart-tooltip-preview {
    min-width: 60px;
    min-height: 60px;
    display: block;
    background-color: #fff;
    background-position: center;
}

.sp-smart-tooltip-label {
    padding: 0.1em;
    display: flex;
    justify-content: center;
    font-size: 12px;
}

/*  Shop page settings */
table.spswp-shop-variations {
    width: 100%;
}

table.spswp-shop-variations,
.spswp-shop-variations tbody,
.spswp-shop-variations td,
.spswp-shop-variations tr {
    margin: 0;
    border: 0;
}

.spswp-shop-variations td.label {
    text-align: left;
}

.spswp-shop-variations tr td {
    display: flex;
}

.sp-smart_shop_align_center table tr td {
    justify-content: center;
}

.sp-smart_shop_align_right table tr td {
    justify-content: flex-end;
}

.spswp-shop-variations .reset_variations {
    display: none !important;
}

.spswp-shop-variations {
    margin-bottom: auto;
    padding: 0;
}

.spswp-shop-variations,
.spswp-shop-variations td {
    border: none;
    background-color: transparent !important;
}

.spswp-shop-variations .sp-smart-more-link {
    font-size: 14px;
    font-weight: 600;
    display: flex;
    margin: auto 0;
}

.sp-smart-swatches-original-price,
.sp-smart-swatches-original-thumbnail {
    display: none;
}

/* Product page css*/
.sp-smart-product-container .sp-smart-swatches-item:first-child {
    margin-left: 0;
}

.sp-smart-selected-label {
    content: " : ";
    font-weight: 300;
}

.sp-smart-selected-label::before {
    content: " : ";
}

.sp-smart-label-none table.variations tr th.label {
    display: none !important;
}

.sp-smart-label-inline table.variations td {
    display: table-cell !important;
}

.sp-smart-product-page table.variations .label label {
    font-size: var(--sp-smart-swatches-label-font-size, "inherit");
}

.sp-smart-swatches-inner {
    position: relative;
}

.sp-smart-swatches-stock-info.sp-smart-swatches-style-top {
    position: absolute;
    font-size: 8px;
    color: #fff;
    background: #A06000;
    height: 13px;
    width: 13px;
    line-height: 12px;
    border-radius: 100%;
    top: -5px;
    right: -6px;
}

.sp-smart-swatches-stock-info.sp-smart-swatches-style-bottom {
    position: absolute;
    font-size: 9px;
    bottom: -12px;
    color: #fff;
    background: #A06000;
    padding: 0px 2px;
    border-radius: 1px;
}

.theme-astra.sp-smart-product-page tr th.label {
    padding-left: 0;
    padding-top: 6px !important;
}

.theme-astra.sp-smart-label-stacked tr th.label {
    padding-left: 0;
}

.theme-astra.sp-smart-label-stacked tr td.value {
    padding: 6px 0 !important;
}

/**
 * 01. 14. Help Tooltip
 */
.smart-swatches-framework-tooltip {
    position: absolute;
    z-index: 5000001;
    line-height: 0;
    text-align: center;
    text-decoration: none;
    max-width: 200px;
    color: #fff;
    background-color: #000;
    background-color: rgba(0, 0, 0, 0.85);
    border-radius: 4px;
    transition: all 0.5s ease;
    z-index: 99999;
}

.smart-swatches-framework-tooltip img {
    max-width: 100%;
    border-radius: 0;
}

/* Fade in */
.smart-swatches-framework-tooltip.fade {
    opacity: 1 !important;
}

.smart-swatches-framework-tooltip.slide {
    opacity: 1;
    transform: translateY(0px);
    /* Adjust the distance to slide in */
}

/* Swing */
.smart-swatches-framework-tooltip.swing {
    animation: swing 0.3s linear infinite alternate;
}

.smart-swatches-framework-tooltip.grow {
    transform: scale(1);
    opacity: 1;
}

.smart-swatches-framework-tooltip .smart-swatch-tooltip-inner-text {
    padding: 3px 10px;
    line-height: 1.4;
    font-size: 13px;
    display: block;
    text-transform: capitalize;
}

.smart-swatches-framework-tooltip span.smart-swatch-tooltip-inner-img {
    display: block;
    border-top-left-radius: 4px;
    border-top-right-radius: 4px;
}

/* .spswp-shop-variations .sp-smart-swatches-item {
    overflow: hidden;
} */
@keyframes swing {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(5deg);
    }
}

.smart-swatches-framework-tooltip:before {
    content: '';
    position: absolute;
    height: 0;
    width: 0;
    z-index: 888;
}

.smart-swatches-framework-tooltip.smart-swatch-arrow-right:before {
    border-top: 10px solid transparent;
    border-bottom: 10px solid transparent;
    border-right: 10px solid rgba(12, 25, 36, .95);
    left: -8px;
    top: calc(50% - 10px);
}

.smart-swatches-framework-tooltip.smart-swatch-arrow-left:before {
    border-top: 7px solid transparent;
    border-bottom: 7px solid transparent;
    border-left: 7px solid rgba(12, 25, 36, .95);
    right: -5px;
    left: auto;
    top: calc(50% + 0px);
    transform: translateY(-50%);
}

.smart-swatches-framework-tooltip.smart-swatch-arrow-top:before {
    border-left: 7px solid transparent;
    border-right: 7px solid transparent;
    border-top: 7px solid rgba(12, 25, 36, .95);
    bottom: -5px;
    left: calc(50% - 0px);
    transform: translateX(-50%);
}

.smart-swatches-framework-tooltip.smart-swatch-arrow-bottom:before {
    border-left: 7px solid transparent;
    border-right: 7px solid transparent;
    border-bottom: 7px solid rgba(12, 25, 36, .95);
    top: -5px;
    left: calc(50% - 0px);
    transform: translateX(-50%);
}

.smart-swatch-tooltip .smart-swatch-tooltip-inner {
    display: none;
}

.spswp-shop-variations {
    margin-bottom: 10px;
}

.spswp-shop-variations .spswp-hidden .sp-smart-swatches-container,
.spswp-shop-variations .spswp-hidden {
    opacity: 0;
    height: 0 !important;
    display: block;
}

.spswp-shop-variations .tr .sp-smart-swatches-container,
.spswp-shop-variations .tr {
    transition: all 0.3s ease-in;
}

.smart-swatch-horizontal_scroll .sp-smart-swatches-container {
    display: flex;
    overflow-x: auto;
    white-space: nowrap;
    flex-flow: nowrap;
    padding: 10px 2px;
    justify-content: start !important;
}

.smart-swatch-horizontal_scroll .sp-smart-swatches-container .sp-smart-swatches-item {
    flex: 0 0 auto;
}

.smart-swatch-vertical_scroll .sp-smart-swatches-container {
    display: flex;
    overflow-y: auto;
    white-space: nowrap;
    width: 100%;
    flex-flow: nowrap;
}

.smart-swatch-vertical_scroll .sp-smart-swatches-container {
    display: flex;
    overflow-y: auto;
    width: 100%;
    flex-flow: wrap;
    overflow-x: auto;
    justify-content: left;
    white-space: nowrap;
}

.smart-swatch-vertical_scroll .sp-smart-swatches-container .sp-smart-swatches-item {
    flex: 0 0 auto;
}

/* Carousels */
.smart-swatch-slider .smart-swatch-slider-wrapper {
    position: relative;
    width: 100%;
    display: flex;
}

.smart-swatch-slider:not(.slider-not-initialized) .sp-smart-swatches-container {
    padding: 2px 4px;
}

.smart-swatch-slider-control {
    position: absolute;
    cursor: pointer;
    top: 0px;
    outline: 0
}

.smart-swatch-slider-control-buttons img {
    display: inline-block !important;
    width: 12px !important;
    height: 12px !important;
    margin: 0 !important;
}

.smart-swatch-slider-control.disabled {
    opacity: 0.6;
}

.smart-swatch-slider-control i {
    line-height: 30px;
    color: #959595;
}

.smart-swatch-slider-prev {
    left: -16px;
}

.smart-swatch-slider-next {
    right: -16px;
}

.smart-swatch-slider-next .fa,
.smart-swatch-slider-prev .fa {
    display: block;
    width: 30px;
    height: 30px;
    text-align: center !important;
    font-size: 20px;
    line-height: 30px;
    color: #ccc
}

.smart-swatch-slider-viewport {
    width: 100%;
    position: relative;
    overflow: hidden;
}

/* The add to cart and view cart button spacing css. */
.product_type_variable.add_to_cart_button.sp-smart-swatches_ajax_add_to_cart + a.added_to_cart {
    margin-left: 5px;
}

.fusion-price-rating > .spswp_variations_form {
    width: 100%;
}

.theme-Avada span.sp-smart-swatches-original-price+.price {
    display: none;
}

.fusion-product-wrapper.ssp-adding .cart-loading {
    z-index: 9999;
    display: block; 
}

/* Styles for BeTheme */
.woocommerce.single-product.mfn-variable-swatches:has(.sp-smart-swatches-item) .mfn-variations-wrapper {
    display: none !important;
}

.woocommerce.single-product.mfn-variable-swatches .variations:has(.sp-smart-swatches-item) {
    display: block !important;
}

.theme-betheme.woocommerce-shop .product-type-variable .desc:has(.sp-smart-swatches-item) .mfn-variations-wrapper-loop{
    display: none;
}

.theme-betheme.woocommerce-shop .spswp-shop-variations tr td.value{
    box-shadow: unset;
}