/* Free Backbar Template Styles */

/* Section Container */
.vda_fbb_section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 20px;
}

/* Promo Description */
.vda_fbb_promo_description {
    text-align: center;
    margin-bottom: 50px;
}

.vda_fbb_module_header {
    font-size: 2.5rem;
    font-weight: 300;
    letter-spacing: 0.05em;
    color: #1a1a1a;
    margin-bottom: 16px;
    text-transform: uppercase;
}

.vda_fbb_promo_description p {
    font-size: 1.1rem;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.7;
}

/* Loading Spinner */
.vda_fbb_module_header .fa-spinner {
    margin-left: 10px;
    color: #ff5a00;
}

/* Product Grid */
ul.backbars {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

/* Product Card */
ul.backbars li {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

ul.backbars li:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
}

/* Product Link */
ul.backbars li a.woocommerce-LoopProduct-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

/* Product Image Container */
.backbar_image {
    display: block;
    position: relative;
    overflow: hidden;
    background: linear-gradient(145deg, #fafafa 0%, #f0f0f0 100%);
    aspect-ratio: 1 / 1;
}

.backbar_image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 20px;
    transition: transform 0.4s ease;
}

ul.backbars li:hover .backbar_image img {
    transform: scale(1.05);
}

/* Overlay Effect */
.backbar_image .et_overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, transparent 60%, rgba(0, 0, 0, 0.03) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

ul.backbars li:hover .backbar_image .et_overlay {
    opacity: 1;
}

/* Product Title */
h2.backbar_product_title {
    padding: 20px 24px;
    margin: 0;
    font-size: 1rem;
    font-weight: 500;
    text-align: center;
    color: #333;
    letter-spacing: 0.03em;
    border-top: 1px solid #f0f0f0;
    transition: color 0.3s ease, background-color 0.3s ease;
    /* Fixed height with centered text for consistent card heights */
    display: flex;
    align-items: center;
    justify-content: center;
    height: 3.2em;
    line-height: 1.3;
    overflow: hidden;
}

ul.backbars li:hover h2.backbar_product_title {
    color: #ff5a00;
    background-color: #fdfcfa;
}

/* Select Button Indicator */
ul.backbars li a.woocommerce-LoopProduct-link::after {
    content: 'Select';
    display: block;
    text-align: center;
    padding: 14px 24px;
    background: #1a1a1a;
    color: #fff;
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    transition: background-color 0.3s ease;
}

ul.backbars li:hover a.woocommerce-LoopProduct-link::after {
    background: #ff5a00;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .vda_fbb_section {
        padding: 40px 16px;
    }

    .vda_fbb_module_header {
        font-size: 1.75rem;
    }

    .vda_fbb_promo_description p {
        font-size: 1rem;
    }

    ul.backbars {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 20px;
    }

    h2.backbar_product_title {
        padding: 16px 20px;
        font-size: 0.95rem;
    }

    ul.backbars li a.woocommerce-LoopProduct-link::after {
        padding: 12px 20px;
    }
}

@media (max-width: 480px) {
    .vda_fbb_module_header {
        font-size: 1.5rem;
    }

    ul.backbars {
        grid-template-columns: 1fr;
    }
}
