/* ==========================================
   BLENTREE PRODUCTS GRID
   Prefix: bln-products- / bln-product- / bln-tab
   Full width comes from parent Elementor "Full Width"
   container — no fragile breakout CSS used.
   ========================================== */

/* Force the widget element to stretch full width inside Elementor
   flex container (Elementor sets align-self:flex-start which prevents
   the widget from stretching — override it) */
.elementor-widget-blentree-products-grid,
.elementor-widget-blentree-products-grid > .elementor-widget-container {
    width: 100% !important;
    max-width: 100% !important;
    overflow: visible !important;
    align-self: stretch !important;
    flex: 1 1 100% !important;
}

/* ===========================================
   SECTION — fills parent width
   =========================================== */
.bln-products-section {
    position: relative;
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    margin: 0;
    left: 0;
    right: 0;
    background-color: #F5A623;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center center;
    overflow: visible;          /* allow top wave to rise above body */
    display: block;
}

/* Old breakout class kept harmless — no negative margins */
.bln-products-section.bln-products-fullwidth {
    width: 100%;
    max-width: 100%;
    margin-left: 0;
    margin-right: 0;
}

.bln-products-section * {
    box-sizing: border-box;
}

/* ===========================================
   WAVE LAYERS — top & bottom (3-layer bg)
   =========================================== */
.bln-products-bg-top,
.bln-products-bg-bottom {
    position: absolute;
    left: 0;
    width: 100%;
    height: 80px;
    background-repeat: no-repeat;
    background-position: center;
    background-size: 100% 100%;
    z-index: 1;
    pointer-events: none;
}

/* Top wave overhangs ABOVE the yellow body (rises into section above) */
.bln-products-bg-top {
    top: 0;
    transform: translateY(-99%);
}

/* Bottom wave sits at the bottom edge */
.bln-products-bg-bottom {
    bottom: 0;
}

/* Inner content — sits above waves, 50px vertical / 10% horizontal */
.bln-products-section-inner {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: none;
    margin: 0 auto;
    padding: 50px 10%;
}

.bln-products-container {
    width: 100%;
}

/* ===========================================
   HEADER (Eyebrow + Heading + Tabs)
   =========================================== */
.bln-products-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 50px;
    gap: 24px;
    flex-wrap: wrap;
}

.bln-products-header-left {
    flex: 1 1 auto;
}

.bln-eyebrow {
    font-family: 'Poppins', sans-serif;
    font-size: 13px;
    font-weight: 700;
    color: #1A1A1A;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 8px;
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.bln-eyebrow::after {
    content: '';
    display: block;
    width: 60px;
    height: 1px;
    background: #1A1A1A;
}

.bln-products-heading {
    font-family: 'Poppins', sans-serif;
    font-size: 36px;
    font-weight: 800;
    color: #FFFFFF;
    line-height: 1.2;
    margin: 0;
}

/* ===========================================
   TABS — no hover color change
   =========================================== */
.bln-tabs {
    display: flex;
    gap: 30px;
    align-items: center;
    flex-wrap: wrap;
}

.bln-tab,
.bln-tab:hover,
.bln-tab:focus,
.bln-tab:active {
    background: transparent !important;
    border: none !important;
    outline: none !important;
    cursor: pointer;
    font-family: 'Poppins', sans-serif;
    font-size: 15px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.6) !important;
    padding: 8px 0;
    position: relative;
    text-decoration: none !important;
    box-shadow: none !important;
}

.bln-tab.active,
.bln-tab.active:hover {
    color: #1A1A1A !important;
}

.bln-tab.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: #1A1A1A;
}

/* ===========================================
   PRODUCTS GRID — 4 columns of SQUARE cards
   =========================================== */
.bln-products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.bln-product-card {
    aspect-ratio: 1 / 1;
    background: #FFFFFF;
    border-radius: 8px;
    padding: 24px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: grid;
    grid-template-rows: 1fr auto;
    align-items: center;
    justify-items: center;
    overflow: hidden;
}

.bln-product-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
}

.bln-product-image {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    min-height: 0;
}

.bln-product-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    display: block;
}

.bln-product-name {
    width: 100%;
    font-family: 'Poppins', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: #1A1A1A;
    margin: 12px 0 0;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.bln-product-card.highlighted .bln-product-name {
    color: #F5A623;
}

.bln-products-price {
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    font-weight: 700;
    color: #E63946;
    margin-top: 6px;
}

.bln-products-price del { color: #999; font-weight: 400; margin-right: 6px; font-size: 12px; }
.bln-products-price ins { background: transparent; text-decoration: none; color: #E63946; }

/* Filtering */
.bln-product-card.bln-hide { display: none !important; }
.bln-product-card.bln-fade-in { animation: blnFadeIn 0.4s ease forwards; }

@keyframes blnFadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ===========================================
   RESPONSIVE
   =========================================== */
@media (max-width: 1199px) {
    .bln-products-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 991px) {
    .bln-products-header {
        flex-direction: column;
        align-items: flex-start;
    }
    .bln-products-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }
    .bln-products-heading { font-size: 30px; }
}

@media (max-width: 768px) {
    .bln-products-section-inner { padding: 70px 24px; }
    .bln-products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
    .bln-tabs { gap: 16px; }
    .bln-products-heading { font-size: 26px; }
    .bln-product-name { font-size: 14px; }
    .bln-product-card { padding: 16px; }
}

@media (max-width: 480px) {
    .bln-products-section-inner { padding: 60px 16px; }
    .bln-products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    .bln-product-card { padding: 12px; }
    .bln-products-heading { font-size: 22px; }
    .bln-product-name { font-size: 13px; }
    .bln-tab { font-size: 13px; }
}
