/* WooCommerce Base Styles */


/* Custom WooCommerce Styles */

.woocommerce-products-header {
    padding: 2rem;
}

.products {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.product-card {
    position: relative;
    background: #fff;
    border-radius: 0.5rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.product-image {
    position: relative;
    overflow: hidden;
    border-radius: 0.5rem 0.5rem 0 0;
}

.product-image img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.product-card:hover .product-image img {
    transform: scale(1.1);
}

.product-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: #ef4444;
    color: #fff;
    padding: 0.25rem 0.75rem;
    border-radius: 2rem;
    font-size: 0.875rem;
    font-weight: 600;
    z-index: 1;
}

.product-details {
    padding: 1.5rem;
}

.product-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.product-price {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.regular-price {
    color: #6b7280;
    text-decoration: line-through;
    font-size: 0.875rem;
}

.sale-price {
    color: #ef4444;
    font-weight: 600;
    font-size: 1.25rem;
}

.add-to-cart:hover {
    background: #eb4425;
}


/* Filters */

.filter-wrapper {
    background: #fff;
    padding: 1.5rem;
    border-radius: 0.5rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.filter-section {
    margin-bottom: 1.5rem;
}

.filter-title {
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 1rem;
}

.price-range {
    margin: 1rem 0;
}

.price-slider {
    height: 4px;
    background: #e5e7eb;
    border-radius: 2px;
    position: relative;
}

.price-range-progress {
    position: absolute;
    height: 100%;
    background: #3b82f6;
    border-radius: 2px;
}

.price-handle {
    width: 16px;
    height: 16px;
    background: #fff;
    border: 2px solid #3b82f6;
    border-radius: 50%;
    position: absolute;
    top: -6px;
    cursor: pointer;
}


/* Price Slider */

.price-slider {
    height: 4px;
    background: #e5e7eb;
    border-radius: 9999px;
    position: relative;
    margin: 1rem 0;
}

.price-slider .ui-slider-range {
    position: absolute;
    background: #eb4425;
    height: 100%;
}

.price-slider .ui-slider-handle {
    width: 16px;
    height: 16px;
    background: #fff;
    border: 2px solid #eb4425;
    border-radius: 50%;
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    cursor: pointer;
}


/* Product Cards */

.product-card .price-wrap del {
    color: #6b7280;
    /* Equivalent to text-gray-500 */
    text-decoration: line-through;
    font-size: 0.875rem;
    /* Equivalent to text-sm */
}

.product-card .price-wrap ins {
    color: #eb4425;
    /* Equivalent to text-blue-600 */
    font-weight: bold;
    font-size: 1.25rem;
    /* Equivalent to text-lg */
    text-decoration: none;
    /* Equivalent to no-underline */
}

.product-card .star-rating {
    color: #facc15;
    /* Equivalent to text-yellow-400 */
}


/* Grid/List Toggle */

.view-toggle button.active {
    background-color: #f3f4f6;
    /* Equivalent to bg-gray-100 */
}


/* List View */

.products-wrapper.list-view .product-card {
    display: flex;
    flex-direction: column;
}

@media (min-width: 768px) {
    /* Added min-width for md: */
    .products-wrapper.list-view .product-card {
        flex-direction: row;
    }
}

.products-wrapper.list-view .product-card .product-image {
    width: 100%;
}

@media (min-width: 768px) {
    /* Added min-width for md: */
    .products-wrapper.list-view .product-card .product-image {
        width: 33.333333%;
        /* Equivalent to md:w-1/3 */
    }
}

.products-wrapper.list-view .product-card .product-info {
    width: 100%;
}

@media (min-width: 768px) {
    /* Added min-width for md: */
    .products-wrapper.list-view .product-card .product-info {
        width: 66.666667%;
        /* Equivalent to md:w-2/3 */
    }
}


/* Responsive Adjustments */

@media (max-width: 768px) {
    .product-card {
        flex-direction: column;
    }
}


/* Animations */

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animated {
    animation: fadeIn 0.3s ease-out;
}

.products-container[data-view="list"] .product-card {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 1rem;
}

.products-container[data-view="list"] .product-card .aspect-square {
    height: 100%;
}

.view-toggle button.active {
    background-color: #e5e7eb;
}

@media (max-width: 768px) {
    .products-container[data-view="list"] .product-card {
        grid-template-columns: 1fr;
    }
}