/**
 * Valdes Products Widget - Main Styles
 */

/* Grid Container */
.vpw-products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px 30px;
}

/* Product Card */
.vpw-product-card {
    position: relative;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.vpw-product-card:hover {
    transform: translateY(-5px);
}

/* Product Image */
.vpw-product-image {
    position: relative;
    height: 280px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin-bottom: 15px;
}

.vpw-product-image a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

.vpw-product-image img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.vpw-product-card:hover .vpw-product-image img {
    transform: scale(1.05);
}

/* Badges */
.vpw-badges {
    position: absolute;
    bottom: 10px;
    left: 10px;
    z-index: 10;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.vpw-badge {
    display: inline-block;
    padding: 5px 10px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 3px;
    line-height: 1;
}

.vpw-badge-sale {
    background-color: #c67c4e;
    color: #ffffff;
}

.vpw-badge-coming-soon {
    background-color: #666666;
    color: #ffffff;
}

/* Product Content */
.vpw-product-content {
    padding: 0 10px;
}

/* Product Title */
.vpw-product-title {
    font-size: 14px;
    font-weight: 400;
    line-height: 1.4;
    margin: 0 0 10px 0;
    text-align: center;
}

.vpw-product-title a {
    color: #333333;
    text-decoration: none;
    transition: color 0.3s ease;
}

.vpw-product-title a:hover {
    color: #c67c4e;
}

/* Product Price */
.vpw-product-price {
    text-align: center;
    line-height: 1.6;
}

.vpw-product-price .price-amount {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: #333333;
}

.vpw-product-price .price-amount del {
    color: #999999;
    font-weight: 400;
    margin-right: 5px;
}

.vpw-product-price .retail-text {
    display: block;
    font-size: 12px;
    color: #c67c4e;
    font-weight: 400;
    margin-top: 2px;
}

/* Add to Cart Button */
.vpw-product-add-to-cart {
    margin-top: 15px;
}

.vpw-product-add-to-cart .button {
    width: 100%;
    background-color: #c67c4e;
    color: #ffffff;
    border: none;
    padding: 10px 20px;
    font-size: 13px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.vpw-product-add-to-cart .button:hover {
    background-color: #a5663d;
}

/* No Products Message */
.vpw-no-products {
    text-align: center;
    padding: 40px;
    color: #666666;
    font-size: 16px;
}

/* Responsive */
@media (max-width: 1024px) {
    .vpw-products-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 30px 20px;
    }

    .vpw-product-image {
        height: 220px;
    }
}

@media (max-width: 768px) {
    .vpw-products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px 15px;
    }

    .vpw-product-image {
        height: 200px;
    }

    .vpw-product-title {
        font-size: 13px;
    }

    .vpw-product-price .price-amount {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .vpw-products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px 10px;
    }

    .vpw-product-image {
        height: 160px;
    }

    .vpw-badge {
        font-size: 10px;
        padding: 4px 8px;
    }

    .vpw-product-title {
        font-size: 12px;
    }

    .vpw-product-price .price-amount {
        font-size: 12px;
    }

    .vpw-product-price .retail-text {
        font-size: 11px;
    }
}

/* ===================================
   Shop Toolbar Widget Styles
   =================================== */

.vpw-shop-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 15px 0;
}

.vpw-toolbar-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Results Count */
.vpw-results-count {
    font-size: 14px;
    color: #666666;
}

/* Sorting Dropdown */
.vpw-sorting-dropdown {
    position: relative;
    min-width: 180px;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    background-color: #ffffff;
    cursor: pointer;
    user-select: none;
}

.vpw-sorting-selected {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 15px;
    font-size: 14px;
    color: #333333;
}

.vpw-sorting-arrow {
    font-size: 10px;
    margin-left: 10px;
    transition: transform 0.3s ease;
}

.vpw-sorting-dropdown.open .vpw-sorting-arrow {
    transform: rotate(180deg);
}

.vpw-sorting-options {
    position: absolute;
    top: 100%;
    left: -1px;
    right: -1px;
    background-color: #ffffff;
    border: 1px solid #e0e0e0;
    border-top: none;
    border-radius: 0 0 4px 4px;
    z-index: 100;
    display: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.vpw-sorting-dropdown.open .vpw-sorting-options {
    display: block;
}

.vpw-sorting-option {
    padding: 10px 15px;
    font-size: 14px;
    color: #333333;
    transition: background-color 0.2s ease, color 0.2s ease;
    border-bottom: 1px solid #f0f0f0;
}

.vpw-sorting-option:last-child {
    border-bottom: none;
}

.vpw-sorting-option:hover {
    background-color: #f5f5f5;
}

.vpw-sorting-option.active {
    color: #c67c4e;
    font-weight: 500;
}

/* Filters Button */
.vpw-filters-button {
    display: inline-flex;
    align-items: center;
    padding: 10px 15px;
    font-size: 14px;
    color: #333333;
    background-color: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.vpw-filters-button:hover {
    background-color: #f5f5f5;
    border-color: #c67c4e;
}

.vpw-filters-button i,
.vpw-filters-button svg {
    margin-right: 8px;
    font-size: 14px;
    width: 14px;
    height: 14px;
}

/* Responsive Toolbar */
@media (max-width: 768px) {
    .vpw-shop-toolbar {
        flex-direction: column;
        align-items: flex-start;
    }

    .vpw-toolbar-right {
        width: 100%;
        justify-content: space-between;
    }

    .vpw-sorting-dropdown {
        flex: 1;
    }
}

@media (max-width: 480px) {
    .vpw-toolbar-right {
        flex-direction: column;
        align-items: stretch;
    }

    .vpw-sorting-dropdown,
    .vpw-filters-button {
        width: 100%;
    }

    .vpw-filters-button {
        justify-content: center;
    }
}