/* ============================================================
   Liquidation Mart — Single Product Page
   ============================================================ */

/* ---- [lm_single_price] ---- */
.lm-single-price {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px 14px;
    line-height: 1;
}

.lm-sp-sale {
    font-size: 38px;
    font-weight: 600;
    color: #1a1a1a;
}

.lm-sp-sale .woocommerce-Price-amount {
    color: #1a1a1a;
}

.lm-sp-regular {
    font-size: 18px;
    font-weight: 400;
    color: #888;
    text-decoration: line-through;
}

.lm-sp-regular .woocommerce-Price-amount {
    color: #888;
}

.lm-save-badge {
    display: inline-flex;
    align-items: center;
    background: #C51E19;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    padding: 5px 10px;
    border-radius: 3px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    line-height: 1;
    white-space: nowrap;
}

/* ---- Variation Swatches (cfvsw plugin) — scoped to single product only ---- */

/* Remove table/grey-background styling */
.single-product table.variations,
.single-product table.variations tbody,
.single-product table.variations tr,
.single-product table.variations th,
.single-product table.variations td {
    display: block !important;
    border: none !important;
    background: none !important;
    padding: 0 !important;
    width: 100% !important;
}

.single-product table.variations tr {
    margin-bottom: 20px;
}

.single-product table.variations tr:last-child {
    margin-bottom: 8px;
}

/* Label */
.single-product table.variations th.label {
    margin-bottom: 10px;
}

.single-product table.variations th.label label {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #1a1a1a;
    display: block;
}

/* Swatches row */
.single-product .cfvsw-swatches-container.cfvsw-product-container {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    background: none !important;
}

/* Individual swatch — override inline min-width/min-height */
.single-product .cfvsw-swatches-option.cfvsw-label-option {
    min-width: unset !important;
    min-height: unset !important;
    width: auto !important;
    height: auto !important;
    padding: 8px 16px !important;
    border: 1.5px solid #d0d0d0 !important;
    border-radius: 4px !important;
    background: #fff !important;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s;
    box-sizing: border-box !important;
}

.single-product .cfvsw-swatch-inner {
    font-size: 13px;
    font-weight: 600;
    color: #1a1a1a;
    line-height: 1;
    white-space: nowrap;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Hover */
.single-product .cfvsw-swatches-option.cfvsw-label-option:hover {
    border-color: #C51E19 !important;
    background: #fff5f5 !important;
}

/* Selected */
.single-product .cfvsw-swatches-option.cfvsw-label-option.cfvsw-selected-swatch {
    background: #C51E19 !important;
    border-color: #C51E19 !important;
}

.single-product .cfvsw-swatches-option.cfvsw-label-option.cfvsw-selected-swatch .cfvsw-swatch-inner {
    color: #fff !important;
}

/* Disabled/unavailable */
.single-product .cfvsw-swatches-option.cfvsw-label-option.cfvsw-disabled {
    opacity: 0.4 !important;
    cursor: not-allowed !important;
}

/* Hide "SIZE : QUEEN" selected value shown next to the label */
.single-product table.variations th.label .attribute-value,
.single-product table.variations th.label span:not([class]),
.single-product table.variations th.label .selected-attribute-name {
    display: none !important;
}
/* Broader fallback — hides the colon + value appended after the label text */
.single-product .woocommerce-variation-selection-label {
    display: none !important;
}

/* Reset link */
.single-product .reset_variations {
    font-size: 12px;
    color: #888;
    margin-top: 8px;
    display: block;
}

/* ---- Product Gallery [lm_gallery] ---- */

.lm-gallery {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.lm-gallery-main {
    position: relative;
    aspect-ratio: 4 / 3;
    background: #fff;
    overflow: hidden;
}

.lm-gallery-link {
    display: block;
    width: 100%;
    height: 100%;
}

.lm-main-img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    object-position: center top;
    transition: opacity 0.2s ease;
    display: block;
}

.lm-main-img.lm-fade {
    opacity: 0;
}

.lm-zoom-icon {
    position: absolute;
    bottom: 10px;
    right: 10px;
    font-size: 15px;
    background: rgba(255, 255, 255, 0.88);
    border-radius: 50%;
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.15);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.lm-gallery-main:hover .lm-zoom-icon {
    opacity: 1;
}

.lm-gallery-thumbs {
    display: flex;
    align-items: center;
    gap: 6px;
}

.lm-thumb-track {
    flex: 1;
    overflow: hidden;
}

.lm-thumb-list {
    display: flex;
    gap: 8px;
    list-style: none;
    margin: 0;
    padding: 0;
    transition: transform 0.25s ease;
    will-change: transform;
}

.lm-thumb {
    flex: 0 0 100px;
    height: 100px;
    border: 2px solid #e0e0e0;
    cursor: pointer;
    background: #f8f8f8;
    overflow: hidden;
    transition: border-color 0.15s;
}

.lm-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

.lm-thumb:hover {
    border-color: #aaa;
}

.lm-thumb.lm-thumb-active {
    border-color: #C51E19;
}

.lm-thumb-arrow {
    flex-shrink: 0;
    width: 30px;
    height: 30px;
    border: 1.5px solid #d0d0d0;
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
    font-size: 20px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    color: #555;
    transition: border-color 0.15s, color 0.15s;
}

.lm-thumb-arrow:hover {
    border-color: #C51E19;
    color: #C51E19;
}

.lm-thumb-arrow:disabled {
    opacity: 0.3;
    cursor: default;
}

/* ---- Responsive ---- */
@media ( max-width: 767px ) {
    .lm-sp-sale {
        font-size: 26px;
    }
    .lm-sp-regular {
        font-size: 15px;
    }
    .lm-save-badge {
        font-size: 11px;
        padding: 4px 8px;
    }
    .lm-thumb {
        flex: 0 0 64px;
        height: 64px;
    }
    .lm-thumb-arrow {
        display: none;
    }
    .lm-thumb-track {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    .lm-thumb-track::-webkit-scrollbar {
        display: none;
    }
}
