/* =========================================================
   1. STANDARD HEART OVERLAYS (Shop & Single Product)
========================================================= */

/* Shop Loop Heart */
.product .bslco-heart {
    position: absolute; top: 10px; right: 10px; width: 30px; height: 30px; cursor: pointer; z-index: 10; transition: transform 0.2s ease;
}
.product .bslco-heart svg { fill: rgba(255, 255, 255, 0.8); stroke: #ff4757; stroke-width: 2px; }
.product .bslco-heart:hover { transform: scale(1.1); }

/* Single Product Page Gallery Heart (Moved left to avoid zoom trigger) */
.woocommerce-product-gallery .bslco-heart-single {
    position: absolute;
    top: 15px;
    right: 60px !important; 
    width: 35px;
    height: 35px;
    cursor: pointer;
    z-index: 9999 !important;
    transition: transform 0.2s ease;
}
.woocommerce-product-gallery .bslco-heart-single svg {
    fill: rgba(255, 255, 255, 0.9);
    stroke: #ff4757;
    stroke-width: 2px;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3)); 
}
.woocommerce-product-gallery .bslco-heart-single:hover {
    transform: scale(1.15);
}

/* Liked State overrides (Theme Agnostic) */
.bslco-heart.liked svg,
.bslco-heart-block.liked svg,
.bslco-heart-featured.liked svg,
.bslco-heart-single.liked svg {
    fill: #ff4757 !important; stroke: #ff4757 !important;
}

/* Ensure the product card is the anchor for the heart */
.product, .wc-block-grid__product {
    position: relative !important;
}

/* Specific styling to keep it on the product image */
.bslco-heart-block {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 10;
    cursor: pointer;
}

/* Hide the duplicate if it somehow still appears outside a product */
body > .bslco-heart {
    display: none !important;
}

/* =========================================================
   2. PRODUCT PAGE BUTTONS (Fully Customized)
========================================================= */

/* The Flexbox wrapper for both buttons */
.bslco-actions-wrapper {
    display: flex; 
    gap: 10px; 
    margin: 20px 0; 
    clear: both; 
    flex-wrap: wrap;
}

/* Universal styles for BOTH buttons (Layout & Font) */
.bslco-like-btn, 
.bslco-open-msg-btn {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 10px; /* Space between icon and text */
    white-space: nowrap !important; /* Prevents text from breaking into two lines */
    text-transform: uppercase !important;
    font-weight: bold !important;
    font-size: 16px !important;
    padding: 10px 24px !important;
    border-radius: 50px !important; /* This creates the curved radius! */
    transition: all 0.2s ease-in-out !important;
}

/* --- Like & Get Offer Button (Red) --- */
.bslco-like-btn {
    background-color: #ff4757 !important;
    color: #ffffff !important;
    border: 2px solid #ff4757 !important;
}
.bslco-like-btn .bslco-btn-icon { 
    width: 22px; 
    height: 22px; 
    fill: #ffffff !important; /* Force heart to be white */
}

/* Hover State - Darker Red */
.bslco-like-btn:hover {
    background-color: #e84150 !important;
    border-color: #e84150 !important;
    color: #ffffff !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1) !important;
}

/* Fades the button slightly after it has been clicked */
.bslco-like-btn.liked { 
    opacity: 0.8; 
    cursor: default !important;
}

#bslco-add-to-cart-btn.button.alt.bslco-btn-main {
   background-color: #000000 !important; 
   color: #ffffff !important;  
   border-color: #CCCCCC !important;
   transform: translateY(-1px);
   box-shadow: 0 4px 8px rgba(0,0,0,0.1) !important;
}

/* Fix for the two-line stretching issue */
.button { 
  display: inline-flex !important;
    align-items: center;
    justify-content: center;
    white-space: nowrap !important;
    width: auto !important;
    min-width: max-content;
}

/* Container alignment for the My Account table cell */
.woocommerce-MyAccount-content td {
    white-space: nowrap; /* Prevents the buttons from stacking on top of each other */
    vertical-align: middle;
}

/* Ensure both buttons sit side-by-side with a gap */
.woocommerce-MyAccount-content .button {
    display: inline-block !important;
    vertical-align: middle;
    margin-right: 8px; /* Space between View Product and Unlike */
}

/* Specific styling for the Unlike button to differentiate it */
.bslco-unlike-btn {
    margin-right: 0 !important; /* Remove margin from the last button */
    background-color: #eee !important;
    color: #444 !important;
}

.bslco-unlike-btn:hover {
    background-color: #ba3333 !important;
    color: #fff !important;
}

/* =========================================================
   4. MODALS & LOADERS
========================================================= */

/* The actual popup background and structure */
.bslco-modal { 
    display: none; 
    position: fixed; 
    z-index: 999999 !important; 
    left: 0; 
    top: 0; 
    width: 100%; 
    height: 100%; 
    background: rgba(0,0,0,0.7); 
}
.bslco-modal-content { 
    background: #ffffff !important; 
    margin: 15% auto; 
    padding: 30px; 
    width: 90%; 
    max-width: 400px; 
    border-radius: 8px; 
    text-align: center; 
    position: relative; 
    box-shadow: 0 5px 25px rgba(0,0,0,0.5); 
    border: 1px solid #dddddd; 
}

/* Modal text forced to Black */
.bslco-modal-content *,
.bslco-modal-content h1,
.bslco-modal-content h2,
.bslco-modal-content h3,
.bslco-modal-content h4,
.bslco-modal-content p,
.bslco-modal-content span,
.bslco-modal-content strong,
.bslco-modal-content small { 
    color: #000000 !important; 
    text-shadow: none !important; 
}

/* Message Modal specific fixes */
.bslco-msg-content { text-align: left; }
.bslco-msg-content textarea { 
    width: 100%; 
    padding: 10px; 
    box-sizing: border-box; 
    color: #000000 !important; 
    background: #ffffff !important;
    border: 1px solid #cccccc !important;
}

/* Modal Close Button (X) */
body .bslco-modal .bslco-modal-content .bslco-close { 
    position: absolute !important; 
    top: 5px !important; 
    right: 15px !important; 
    font-size: 38px !important; 
    font-weight: bold !important; 
    cursor: pointer !important; 
    line-height: 1 !important; 
    opacity: 1 !important; 
    color: #000000 !important; 
    text-decoration: none !important;
}
body .bslco-modal .bslco-modal-content .bslco-close:hover { 
    color: #ff4757 !important; 
    transform: scale(1.1) !important;
}

/* --- THE SPINNER & LOADING TEXT --- */
.bslco-loader { 
    text-align: center !important; 
    padding: 20px 0 !important; 
}
.bslco-loader p { 
    font-size: 16px !important; 
    font-weight: bold !important; 
    color: #333333 !important; 
    margin-top: 15px !important;
}
.bslco-spinner { 
    animation: bslco_rotate 2s linear infinite !important; 
    width: 40px !important; 
    height: 40px !important; 
    margin: 0 auto !important; 
    display: block !important;
}
.bslco-spinner .path { 
    stroke: #ff4757 !important; 
    stroke-linecap: round !important; 
    animation: bslco_dash 1.5s ease-in-out infinite !important; 
    stroke-width: 5 !important; 
    fill: none !important; 
}
.bslco-success-text { color: green !important; font-weight: bold !important; }
.bslco-error-text { color: #ff4757 !important; font-weight: bold !important; }

@keyframes bslco_rotate { 100% { transform: rotate(360deg); } }
@keyframes bslco_dash {
    0% { stroke-dasharray: 1, 150; stroke-dashoffset: 0; }
    50% { stroke-dasharray: 90, 150; stroke-dashoffset: -35; }
    100% { stroke-dasharray: 90, 150; stroke-dashoffset: -124; }
}

/* =========================================================
   5. GUTENBERG BLOCKS & ASNP BADGES
========================================================= */
.asnp-sale-badge-image-wrapper, .wc-block-grid__product-image, .wc-block-grid__product-image a, .wp-block-woocommerce-product-image, .wp-block-woocommerce-product-image a, .wc-block-components-product-image, .wc-block-grid__product, .wc-block-components-product-card, .wp-block-woocommerce-featured-product {
    position: relative !important; overflow: visible !important; 
}
.bslco-heart-block {
    position: absolute !important; top: 15px !important; right: 15px !important; width: 35px !important; height: 35px !important; z-index: 99999 !important;
    cursor: pointer !important; transition: transform 0.2s ease !important; display: flex !important; align-items: center !important; justify-content: center !important; pointer-events: auto !important; 
}
.bslco-heart-block svg { fill: rgba(255, 255, 255, 0.9) !important; stroke: #ff4757 !important; stroke-width: 2px !important; filter: drop-shadow(0 2px 5px rgba(0,0,0,0.6)) !important; }
.bslco-heart-block:hover { transform: scale(1.15) !important; }

.wp-block-woocommerce-featured-product .bslco-heart-featured, .wc-block-featured-product .bslco-heart-featured {
    position: absolute !important; top: 25px !important; right: 25px !important; width: 45px !important; height: 45px !important; z-index: 99999 !important; cursor: pointer !important; transition: transform 0.2s ease !important;
}
.wp-block-woocommerce-featured-product .bslco-heart-featured svg, .wc-block-featured-product .bslco-heart-featured svg {
    fill: rgba(255, 255, 255, 0.9) !important; stroke: #ff4757 !important; stroke-width: 2px !important; filter: drop-shadow(0 3px 6px rgba(0,0,0,0.5)) !important; 
}
.wp-block-woocommerce-featured-product .bslco-heart-featured:hover, .wc-block-featured-product .bslco-heart-featured:hover { transform: scale(1.15) !important; }