/*
 * NPS custom Store.
 *
 * Outer Store is full width.
 * Catalog content mirrors current Elementor Store at 1132px desktop.
 */

.nps-store {
    position: relative;
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0;
}

.nps-store__catalog {
    position: relative;
    width: calc(100% - 40px);
    max-width: 1132px;
    margin: 0 auto;
    padding: 40px 0 0;
}

/* Program filter */
.nps-store__filter {
    position: absolute;
    top: 48px;
    right: 0;
    z-index: 2;
    margin: 0;
}

.nps-store__filter select {
    width: 283px;
    max-width: 100%;
}

/* Program sections */
.nps-store__program {
    margin: 30px 0 60px;
}

.nps-store__program:first-of-type {
    margin-top: 0;
}

.nps-store__program-title {
    margin: 0 0 36px;
    font-size: 44px;
    line-height: 1;
    font-weight: 400;
}

/* Product grid */
.nps-store__program ul.products {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    column-gap: 20px;
    row-gap: 40px;
    margin: 0;
    padding: 0;
}

.nps-store__program ul.products::before,
.nps-store__program ul.products::after {
    display: none;
}

.nps-store__program ul.products li.product {
    float: none;
    width: auto;
    margin: 0;
    padding: 0;
}

/* Exact existing product-title geometry */
.nps-store__program ul.products li.product h2,
.nps-store__program ul.products li.product .woocommerce-loop-product__title {
    height: 8ex;
    overflow: hidden;
    line-height: 2.5ex;
}

/*
 * Existing Elementor button:
 * 56px tall with 20px vertical padding.
 */
.nps-store__program ul.products li.product .button {
    display: block;
    width: 100%;
    margin-top: 16px;
    padding-top: 20px;
    padding-bottom: 20px;
    text-align: center;
}

/*
 * Shared sub-footer is deliberately outside .nps-store__catalog.
 * Use the site's existing .sub-footer implementation and styles.
 */
.nps-store > .sub-footer {
    width: 100%;
    max-width: none;
    margin-left: 0;
    margin-right: 0;
}

/* Mobile */
@media (max-width: 767px) {

    .nps-store__catalog {
        width: 90%;
        padding-top: 40px;
    }

    .nps-store__filter {
        top: -20px;
        left: 0;
        right: 0;
    }

    .nps-store__filter select {
        width: 100%;
    }

    .nps-store__program {
        margin-top: 32px;
        margin-bottom: 32px;
    }

    .nps-store__program-title {
        margin-bottom: 16px;
        font-size: 26px;
    }

    .nps-store__program ul.products {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        column-gap: 20px;
        row-gap: 40px;
    }
}

/*
 * Production Store card-button parity.
 * Existing Woo/theme rules otherwise reduce vertical padding to 10px.
 */
body.woocommerce-shop
.nps-store
.nps-store__program
ul.products
li.product
a.button {
    display: block;
    width: 100%;
    margin-top: 16px !important;
    padding-top: 20px !important;
    padding-bottom: 20px !important;
    text-align: center;
}
