/*

Theme Name: Porto Child

Theme URI: https://www.portotheme.com/wordpress/porto

Author: P-THEMES

Author URI: https://www.portotheme.com/

Description: Porto Responsive WordPress + eCommerce Theme.

Version: 1.1

Template: porto

License: Commercial

License URI: http://themeforest.net/licenses/regular_extended

Tags: woocommerce, corporate, ecommerce, responsive, blue, black, green, white, light, dark, red, two-columns, three-columns, four-columns, left-sidebar, right-sidebar, fixed-layout, responsive-layout, custom-menu, editor-style, featured-images, flexible-header, full-width-template, microformats, post-formats, rtl-language-support, sticky-post, theme-options, translation-ready, accessibility-ready

*/



/*************** ADD YOUR CUSTOM CSS HERE  ***************/

.footer-wrapper {
    position: relative;
    width: 100%;
    bottom: 0;
}

/* Target carousel product images only */
.porto-tb-featured-image .img-thumbnail {
  display: block;
  width: 100%;
  height: 300px;            /* whatever uniform height you want */
  overflow: hidden;         /* hide any overflow */
  position: relative;
}
.porto-tb-featured-image .img-thumbnail img {
  position: absolute;
  top: 50%;
  left: 50%;
  height: 100%;             /* fill the container height */
  width: auto;              /* maintain aspect ratio */
  transform: translate(-50%, -50%);
  object-fit: contain;      /* ensure the whole image is visible */
}

/* Single product page image styling - Porto theme specific */
.single-product .product-images .img-thumbnail {
  border: none;
  padding: 0;
}

.single-product .product-images .img-thumbnail img {
  max-height: 500px;
  width: auto !important;
  margin: 0 auto;
  object-fit: contain;
  display: block;
}

/* Fix for thumbnail images */
.single-product .product-thumbnails .img-thumbnail img,
.single-product .product-thumbs-slider .img-thumbnail img {
  height: auto;
  width: auto;
  max-height: 100px;
  margin: 0 auto;
  object-fit: contain;
}

/* Ensure proper image display in zoom/lightbox */
.zoomContainer .zoomWindow img,
.zoom-image img {
  object-fit: contain;
}

.required {
    color: #EF7C00 !important;
}

#mini-cart .cart-items,.gutenberg-hb .compare-count,.my-wishlist .wishlist-count,header .compare-count {
    background-color: #EF7C00 !important;
}

/* Add "VAT excluded" text only on product cards, single product page, and checkout product items */

/* 
 * Product cards in shop/category pages & related/upsell products
 * Targeting the exact HTML structure:
 * <span class="woocommerce-Price-amount amount"><bdi>39,00&nbsp;<span class="woocommerce-Price-currencySymbol">€</span></bdi></span>
 */
/* This section has been moved to a more comprehensive selector below */

/* Make absolutely sure we're not applying this to total rows */
.cart_totals tr:not(.cart_item) .woocommerce-Price-amount.amount > bdi::after,
.woocommerce-checkout-review-order-table tr:not(.cart_item) .woocommerce-Price-amount.amount > bdi::after {
    content: none !important;
}

/* Exclude all cart/checkout totals and shipping - targeting both direct ::after and bdi::after */
.cart-subtotal .woocommerce-Price-amount.amount::after,
.cart-subtotal .woocommerce-Price-amount.amount > bdi::after,
.order-total .woocommerce-Price-amount.amount::after,
.order-total .woocommerce-Price-amount.amount > bdi::after,
.shipping .woocommerce-Price-amount.amount::after,
.shipping .woocommerce-Price-amount.amount > bdi::after,
.tax-rate .woocommerce-Price-amount.amount::after,
.tax-rate .woocommerce-Price-amount.amount > bdi::after,
.fee .woocommerce-Price-amount.amount::after,
.fee .woocommerce-Price-amount.amount > bdi::after,
#mini-cart .total .woocommerce-Price-amount.amount::after,
#mini-cart .total .woocommerce-Price-amount.amount > bdi::after,
#mini-cart .woocommerce-mini-cart__total .woocommerce-Price-amount.amount::after,
#mini-cart .woocommerce-mini-cart__total .woocommerce-Price-amount.amount > bdi::after,
.cart_totals .woocommerce-Price-amount.amount::after,
.cart_totals .woocommerce-Price-amount.amount > bdi::after,
.woocommerce-checkout-review-order-table .order-total .woocommerce-Price-amount.amount::after,
.woocommerce-checkout-review-order-table .order-total .woocommerce-Price-amount.amount > bdi::after,
.woocommerce-checkout-review-order-table .cart-subtotal .woocommerce-Price-amount.amount::after,
.woocommerce-checkout-review-order-table .cart-subtotal .woocommerce-Price-amount.amount > bdi::after,
.woocommerce-checkout-review-order-table tfoot .woocommerce-Price-amount.amount::after,
.woocommerce-checkout-review-order-table tfoot .woocommerce-Price-amount.amount > bdi::after {
    content: none !important;
}

/* Additional JavaScript-controlled classes - targeting both direct ::after and bdi::after */
.woocommerce-Price-amount.amount.no-iva-text::after,
.woocommerce-Price-amount.amount.no-iva-text > bdi::after {
    content: none !important;
}

/* Global rule for "+ IVA" text that works with Porto theme product display 
ul.products .woocommerce-Price-amount.amount > bdi::after,
.product-inner .woocommerce-Price-amount.amount > bdi::after,
.product-col .woocommerce-Price-amount.amount > bdi::after,
.product-default .woocommerce-Price-amount.amount > bdi::after,
.product-outimage_aq_onimage .woocommerce-Price-amount.amount > bdi::after,
.related.products .woocommerce-Price-amount.amount > bdi::after,
.up-sells .woocommerce-Price-amount.amount > bdi::after,
.cross-sells .woocommerce-Price-amount.amount > bdi::after,
.porto-products .woocommerce-Price-amount.amount > bdi::after,
.products-slider .woocommerce-Price-amount.amount > bdi::after,
.single-product .summary .woocommerce-Price-amount.amount > bdi::after,
.single-product div.product p.price .woocommerce-Price-amount.amount > bdi::after,
.single-product div.product span.price .woocommerce-Price-amount.amount > bdi::after,
.product-summary-wrap .woocommerce-Price-amount.amount > bdi::after,
.shop_table .cart_item td.product-price .woocommerce-Price-amount.amount > bdi::after,
.woocommerce-cart-form__cart-item .product-price .woocommerce-Price-amount.amount > bdi::after,
.shop_table .cart_item td.product-subtotal .woocommerce-Price-amount.amount > bdi::after,
.woocommerce-cart-form__cart-item .product-subtotal .woocommerce-Price-amount.amount > bdi::after,
#mini-cart .mini_cart_item .quantity .woocommerce-Price-amount.amount > bdi::after,
.woocommerce-checkout-review-order-table .cart_item .product-total .woocommerce-Price-amount.amount > bdi::after {
    content: " + IVA" !important;
    font-size: 0.85em !important;
    font-weight: normal !important;
    opacity: 0.8 !important;
    margin-left: 3px !important;
    display: inline-block !important;
} */

.alpus-horizontal-scroller {
    height: 100% !important;
}

/* Hide original elements - aggressive approach */
ul.product-categories.chips-hidden,
.widget_product_categories ul.product-categories.chips-hidden,
.sidebar-content ul.product-categories.chips-hidden,
.woocommerce-ordering.chips-hidden {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    overflow: hidden !important;
    margin: 0 !important;
    padding: 0 !important;
    position: absolute !important;
    opacity: 0 !important;
    pointer-events: none !important;
    max-height: 0 !important;
    clip: rect(1px, 1px, 1px, 1px) !important;
    -webkit-clip-path: inset(50%) !important;
    clip-path: inset(50%) !important;
}

/* Category Chips modern styling */
.product-categories-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 20px 0 30px;
    transition: all 0.4s ease;
    position: relative;
    justify-content: center;
}

/* Cool chip design with hover effects */
.product-categories-chips .category-chip {
    display: inline-flex;
    align-items: center;
    padding: 8px 16px;
    background-color: #f8f8f8;
    border-radius: 50px;
    font-size: 15px;
    font-weight: 500;
    color: #444;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    border: 1px solid #e8e8e8;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    position: relative;
    overflow: hidden;
}

/* Hover effect */
.product-categories-chips .category-chip:hover {
    background-color: #06953F;
    color: #fff;
    border-color: #06953F;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(6, 149, 63, 0.2);
}

/* Active category styling */
.product-categories-chips .category-chip.active {
    background-color: #06953F;
    color: #fff;
    border-color: #06953F;
    box-shadow: 0 3px 6px rgba(6, 149, 63, 0.25);
}

/* Category name styling */
.product-categories-chips .category-chip .category-name {
    position: relative;
    z-index: 2;
}

/* Count bubble styling */
.product-categories-chips .category-chip .count {
    font-size: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    height: 22px;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 12px;
    margin-left: 8px;
    padding: 0 6px;
    font-weight: 700;
    position: relative;
    z-index: 2;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

/* Count styling for active/hovered categories */
.product-categories-chips .category-chip:hover .count,
.product-categories-chips .category-chip.active .count {
    background-color: rgba(255, 255, 255, 0.3);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.4);
}

/* Animation for new items */
.product-categories-chips .category-chip {
    animation: chipAppear 0.4s ease forwards;
}

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

/* Category Chips Styling */
.chips-hidden {
    display: none !important;
}

.product-categories-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 10px 0;
}

.product-categories-chips .category-chip {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    background-color: #f5f5f5;
    border-radius: 20px;
    font-size: 14px;
    transition: all 0.3s ease;
    color: #333;
    border: 1px solid #e0e0e0;
    cursor: pointer;
    text-decoration: none;
}

.product-categories-chips .category-chip:hover {
    background-color: #e8f5ee;
    border-color: #06953F;
    transform: translateY(-2px);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.product-categories-chips .category-chip.current-cat {
    background-color: #06953F;
    color: white;
    border-color: #06953F;
    font-weight: bold;
}

.product-categories-chips .category-chip .count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    height: 22px;
    background: rgba(0,0,0,0.08);
    border-radius: 12px;
    margin-left: 8px;
    padding: 0 6px;
    font-size: 12px;
    font-weight: normal;
}

.product-categories-chips .category-chip.current-cat .count {
    background: rgba(255,255,255,0.2);
}

/* Animation effects */
.product-categories-chips .category-chip {
    animation: fadeIn 0.5s ease-out;
}

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

/* Responsive adjustments */
@media (max-width: 768px) {
    .product-categories-chips {
        gap: 8px;
    }
    
    .product-categories-chips .category-chip {
        font-size: 14px;
        padding: 6px 14px;
    }
}

@media (max-width: 575px) {
    .product-categories-chips {
        gap: 6px;
    }
    
    .product-categories-chips .category-chip {
        padding: 4px 10px;
        font-size: 13px;
    }
    
    .product-categories-chips .category-chip .count {
        min-width: 20px;
        height: 20px;
        margin-left: 6px;
        font-size: 11px;
    }
}

/* Price Filter Chips Styling - Simplified Structure */
.widget_price_filter {
    margin: 15px 0 25px !important;
    padding: 0 !important;
    background-color: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

/* COMMON FILTER CONTAINER STYLING - For all filter types */
.price-filter-chips-container,
.category-filter-chips-container,
.orderby-chips-container {
    background-color: rgba(255, 140, 0, 0.1) !important; /* Orange with 10% opacity */
    border-radius: 8px !important;
    padding: 12px !important;
    margin-bottom: 15px !important;
    width: 100% !important;
}

/* Add light orange background to the entire filter row */
.price-filter-chips-container {
    background-color: rgba(255, 140, 0, 0.1) !important; /* Orange with 10% opacity */
    border-radius: 8px !important;
    padding: 12px !important;
    margin-bottom: 15px !important;
}

/* Clean header styling */
.price-filter-header {
    margin-bottom: 15px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    color: #333 !important;
    display: inline-block !important;
    padding: 0 5px !important;
}

/* Common header styling for all filters */
.price-filter-header,
.widget_product_categories .widget-title,
.orderby-chips-label label {
    margin-bottom: 15px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    color: #333 !important;
    display: inline-block !important;
    padding: 0 5px !important;
    border: none !important;
    background: none !important;
    line-height: 1.4 !important;
}

/* Price filter container */
.price-filter-chips-container {
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
}

/* Slider container */
.price-slider-container {
    padding: 0 15px !important;
    margin: 5px 0 !important;
}

/* Style the slider track - more subtle */
.price-slider {
    height: 6px !important;
    background-color: rgba(224, 224, 224, 0.5) !important;
    border-radius: 6px !important;
    border: none !important;
    margin: 0 !important;
    display: block !important;
}

/* Style the selected range on the slider */
.price-slider .ui-slider-range {
    background-color: #06953F !important;
    height: 6px !important;
    border-radius: 6px !important;
    top: 0 !important;
}

/* Style the slider handles - smaller and more subtle */
.price-slider .ui-slider-handle {
    width: 16px !important;
    height: 16px !important;
    background-color: white !important;
    border: 2px solid #06953F !important;
    border-radius: 50% !important;
    top: -5px !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1) !important;
    transition: transform 0.2s ease, box-shadow 0.2s ease !important;
    cursor: pointer !important;
    margin-left: -8px !important;
    outline: none !important;
}

.price-slider .ui-slider-handle:hover,
.price-slider .ui-slider-handle:focus {
    transform: scale(1.05) !important;
    box-shadow: 0 2px 4px rgba(0,0,0,0.15) !important;
}

/* Controls container - uses flexbox for better alignment */
.price-controls {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 8px !important;
    margin-top: 10px !important;
    padding: 0 15px !important;
}

/* Style the price display as a chip - more subtle */
.price-range-chip {
    display: inline-flex !important;
    align-items: center !important;
    padding: 5px 10px !important;
    background-color: rgba(255, 255, 255, 0.7) !important;
    border-radius: 15px !important;
    border: 1px solid rgba(224, 224, 224, 0.5) !important;
    flex-grow: 1 !important;
    max-width: fit-content !important;
}

.price_label {
    margin: 0 !important;
    font-size: 13px !important;
    color: #333 !important;
    padding: 0 !important;
    text-align: center !important;
}

/* Style the filter button as a chip - smaller and more subtle */
.price-filter-button button.button {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 5px 12px !important;
    background-color: #06953F !important;
    color: white !important;
    border-radius: 15px !important;
    font-size: 13px !important;
    transition: all 0.3s ease !important;
    border: 1px solid #06953F !important;
    cursor: pointer !important;
    font-weight: 500 !important;
    margin: 0 !important;
    height: auto !important;
    line-height: 1.5 !important;
    width: auto !important;
    text-transform: none !important;
    box-shadow: none !important;
}

/* Match the style with category chips button - subtle hover effect */
.price-filter-button button.button:hover {
    background-color: #057a33 !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1) !important;
    color: white !important;
}

.price-filter-chips button.button.category-chip:hover {
    background-color: #057a33 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1) !important;
}

/* Orderby Chips Styling */
.orderby-chips-container {
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
    margin: 15px 0 25px !important;
}

.orderby-chips-label {
    display: block !important;
    margin-bottom: 8px !important;
}

.orderby-chips-wrapper {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 10px !important;
    margin-top: 5px !important;
}

.orderby-chip {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 8px 16px !important;
    background-color: #f8f8f8 !important;
    border-radius: 50px !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    color: #444 !important;
    text-decoration: none !important;
    transition: all 0.3s ease !important;
    border: 1px solid #e8e8e8 !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05) !important;
    cursor: pointer !important;
    white-space: nowrap !important;
}

.orderby-chip:hover {
    background-color: #06953F !important;
    color: #fff !important;
    border-color: #06953F !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 8px rgba(6, 149, 63, 0.2) !important;
}

.orderby-chip.active {
    background-color: #06953F !important;
    color: #fff !important;
    border-color: #06953F !important;
    box-shadow: 0 3px 6px rgba(6, 149, 63, 0.25) !important;
}

/* Remove all toggle arrows */
.widget-title .toggle,
.widget h3.widget-title .toggle,
.widget .widget-title .toggle,
aside.widget .widget-title .toggle,
.widget_product_categories .widget-title .toggle,
.woocommerce-widget-layered-nav .widget-title .toggle,
.widget_price_filter .widget-title .toggle,
.widget .toggle,
.porto-product-filters .widget-title .toggle {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    width: 0 !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    position: absolute !important;
    clip: rect(1px, 1px, 1px, 1px) !important;
}

/* Make sure all widgets show their content */
.widget_product_categories .product-categories,
.widget_price_filter .price_slider_wrapper,
.woocommerce-ordering .orderby {
    display: block !important;
    height: auto !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
}

/* Common styling for all filter containers for consistent spacing */
.widget_product_categories,
.widget_price_filter,
.woocommerce-ordering {
    margin-bottom: 20px !important;
}

/* Make all filter heights consistent */
.price-filter-chips-container,
.category-filter-chips-container,
.orderby-chips-container {
    min-height: 120px !important;
}

/* Mobile responsiveness for all filter types */
@media (max-width: 575px) {
    .price-filter-chips-container,
    .category-filter-chips-container,
    .orderby-chips-container {
        padding: 10px !important;
    }
    
    .orderby-chips-wrapper {
        justify-content: center !important;
    }
    
    .orderby-chip {
        font-size: 13px !important;
        padding: 6px 14px !important;
    }
}

/* Price range display - style to match category chips */
.price-filter-chips .price_slider_amount {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    gap: 8px !important;
    margin-top: 10px !important;
}

/* Use the same rounding and colors as category chips */
.price-filter-chips .price_label {
    font-size: 14px !important;
    color: #333 !important;
}

/* In filter popup context */
.sidebar-content .widget_price_filter {
    margin-bottom: 15px !important;
}

/* For the popup in the screenshot */
.price-filter-chips .price_slider_amount {
    margin-top: 15px !important;
}

/* For the specific popup filter in the image */
.yith-wcan-filters-opener + .yith-wcan-filters-area .widget_price_filter {
    margin-bottom: 15px !important;
}

/* Match category styling with text colors */
.price-filter-chips .widget-title {
    color: #333 !important;
}

/* Override Porto toggle behavior completely */
.widget_price_filter.price-filter-chips .toggle {
    display: none !important;
}

/* Porto product filters specific styling */
.porto-product-filters {
    position: relative;
}

.porto-product-filters .widget-title {
    cursor: default !important;
    border-bottom: none !important;
}

.porto-product-filters .toggle {
    display: none !important;
}

.porto-product-filters .widget {
    margin-bottom: 1.0714em;
}

/* Consistent style for all filter containers when in porto filters */
.porto-product-filters .category-filter-chips-container,
.porto-product-filters .price-filter-chips-container,
.porto-product-filters .orderby-chips-container {
    background-color: rgba(255, 140, 0, 0.1) !important;
    border-radius: 8px !important;
    padding: 12px !important;
    margin-bottom: 15px !important;
    width: 100% !important;
}

/* For widgets that are direct children of porto-product-filters */
.porto-product-filters > .widget {
    background-color: rgba(255, 140, 0, 0.1) !important;
    border-radius: 8px !important;
    padding: 12px !important;
    margin-bottom: 15px !important;
}

/* Ensure widget titles inside porto filter container are styled consistently */
.porto-product-filters .widget .widget-title,
.porto-product-filters .widget h3.widget-title {
    margin-bottom: 15px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    color: #333 !important;
    display: inline-block !important;
    padding: 0 5px !important;
    border: none !important;
    background: none !important;
    line-height: 1.4 !important;
}

/* Hide arrow indicators in Porto product filters */
.porto-product-filters .widget .toggle,
.porto-product-filters .widget-title .toggle {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

/* Fix for when filters are inside a popup/overlay */
.filter-overlay .porto-product-filters {
    padding: 15px !important;
}

.filter-overlay .porto-product-filters .widget {
    margin-bottom: 15px !important;
}

/* Fix for filter widgets that might be shown/hidden via JS */
.porto-product-filters .widget > div,
.porto-product-filters .widget > ul,
.porto-product-filters .widget > form {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
}

/* Specific styling for Porto product filters body */
.porto-product-filters-body {
    min-height: 50px !important;
    position: relative !important;
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
}

/* Better placement for chips inside Porto filters body */
.porto-product-filters-body .category-filter-chips-container,
.porto-product-filters-body .price-filter-chips-container,
.porto-product-filters-body .orderby-chips-container {
    width: 100% !important;
    margin-bottom: 15px !important;
    order: 1 !important; /* Ensure filters appear at the top */
}

/* Make sure original widgets inside Porto filters body are properly hidden */
.porto-product-filters-body .widget_product_categories:not(.opened),
.porto-product-filters-body .widget_price_filter:not(.opened),
.porto-product-filters-body .woocommerce-ordering.chips-hidden {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    min-height: 0 !important;
    overflow: hidden !important;
    margin: 0 !important;
    padding: 0 !important;
    opacity: 0 !important;
}

/* Hide all Porto toggle elements */
.porto-product-filters .widget-title .toggle,
.porto-product-filters-toggle-box .widget-title .toggle,
.porto-product-filters-body .widget-title .toggle {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
}

/* Make sure parent gets proper padding when filters are inside */
.sidebar-content .porto-product-filters,
.porto-products-filter-body .porto-product-filters,
.shop-loop-before .porto-product-filters {
    padding: 10px 0 !important;
}

/* Direct styling for Porto price filter elements */
.porto-product-filters-body .widget_price_filter,
.porto-product-filters .widget_price_filter {
    display: none !important; /* Hide the original widget once processed */
}

.porto-product-filters-body .price-filter-chips-container,
.porto-product-filters .price-filter-chips-container {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    overflow: visible !important;
}

/* Fix price slider in Porto environment */
.porto-product-filters-body .price-slider,
.porto-product-filters .price-slider {
    height: 6px !important;
    border-radius: 3px !important;
    background-color: rgba(224, 224, 224, 0.5) !important;
    border: none !important;
    box-shadow: none !important;
    margin: 10px 0 20px !important;
}

.porto-product-filters-body .price-slider .ui-slider-range,
.porto-product-filters .price-slider .ui-slider-range {
    height: 6px !important;
    background-color: #06953F !important;
}

.porto-product-filters-body .price-slider .ui-slider-handle,
.porto-product-filters .price-slider .ui-slider-handle {
    width: 16px !important;
    height: 16px !important;
    background-color: #fff !important;
    border: 2px solid #06953F !important;
    margin-top: -5px !important;
}

/* Modern Product Filter Widget Styles */

/* General widget container */
.modern-product-filter-widget {
    margin-bottom: 2rem;
    width: 100%;
}

.modern-product-filter-container {
    width: 100%;
    overflow: hidden;
    margin: 0 -10px;
}

/* Filter sections */
.modern-filter-section {
    float: left;
    width: 30%;
    min-width: 250px;
    background-color: rgba(255, 165, 0, 0.05);
    border-radius: 8px;
    padding: 15px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.03);
    border: 1px solid rgba(255, 165, 0, 0.1);
    box-sizing: border-box;
    margin: 0 1.66%;
    min-height: 300px;
    position: relative;
    padding-bottom: 40px;
}

.modern-filter-section h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 12px;
    color: #333;
    position: relative;
    padding-bottom: 5px;
}

.modern-filter-section h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background: linear-gradient(135deg, #ff6b35, #f7931e);
    border-radius: 2px;
}

/* Category chips */
.modern-category-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0;
}

.category-chip {
    display: inline-block;
    padding: 8px 16px;
    background: #f8f9fa;
    color: #333;
    text-decoration: none;
    border-radius: 20px;
    border: 1px solid #e0e0e0;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    white-space: nowrap;
    position: relative;
    cursor: pointer;
}

.category-chip:hover {
    background: #ff6b35;
    color: white;
    border-color: #ff6b35;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3);
}

.category-chip.active {
    background: linear-gradient(135deg, #ff6b35, #f7931e);
    color: white;
    border-color: transparent;
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.4);
}

/* Price filter */
.modern-price-filter-form {
    width: 100%;
}

.price-slider {
    height: 6px;
    border-radius: 3px;
    background-color: #e0e0e0;
    border: none;
    margin: 15px 0 20px;
}

.price-slider .ui-slider-range {
    height: 6px;
    background: linear-gradient(135deg, #ff6b35, #f7931e);
    border-radius: 3px;
}

.price-slider .ui-slider-handle {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #fff;
    border: 3px solid #ff6b35;
    top: -6px;
    margin-left: -9px;
    cursor: pointer;
    outline: none;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

.price-range {
    font-size: 14px;
    color: #666;
    margin-bottom: 15px;
    text-align: center;
}

.price-range .from,
.price-range .to {
    font-weight: 600;
    color: #ff6b35;
}

/* Order by dropdown */
.modern-orderby-select {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    background: #fff;
    font-size: 14px;
    color: #333;
    outline: none;
    transition: border-color 0.3s ease;
}

.modern-orderby-select:focus {
    border-color: #ff6b35;
    box-shadow: 0 0 0 2px rgba(255, 107, 53, 0.1);
}

/* Loading states */
.loading {
    opacity: 0.7;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #ff6b35;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive design */
@media (max-width: 992px) {
    .modern-filter-section {
        width: 48%;
        margin: 0 1%;
        margin-bottom: 20px;
    }
}

@media (max-width: 768px) {
    .modern-filter-section {
        width: 100%;
        margin: 0 0 20px 0;
        float: none;
    }
    
    .modern-product-filter-container {
        margin: 0;
    }
    
    .modern-category-chips {
        justify-content: center;
    }
}

/* AJAX loading overlay */
.ajax-loading .modern-product-filter-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.8);
    z-index: 1000;
}

/* Products updating state */
.products.updating {
    opacity: 0.6;
    pointer-events: none;
}

/* Message styling */
.modern-filter-message {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 8px;
    color: white;
    font-weight: 500;
    z-index: 9999;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.modern-filter-success {
    background: linear-gradient(135deg, #2ed573, #26d0ce);
}

.modern-filter-error {
    background: linear-gradient(135deg, #ff4757, #ff3742);
}

/* === Unified Sidebar Filter Styling (WooCommerce + Porto Child) === */

/* Reset Porto's box styling for all sidebar widgets */
.sidebar-content .widget,
.sidebar-content .wc-block-catalog-sorting {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
  margin-bottom: 2rem !important;
}

/* Match all filter headers */
.sidebar-content .widget-title {
  font-size: 1.1rem !important;
  font-weight: 600 !important;
  color: #222 !important;
  padding-left: 0.75rem !important;
  margin-bottom: 1rem !important;
  border-left: 4px solid #4CAF50 !important;
  background: none !important;
  line-height: 1.4 !important;
}

/* Remove Porto toggle arrows in widget headers */
.sidebar-content .widget-title .toggle {
  display: none !important;
}

/* Sort Dropdown ("Ordina per") */
.sidebar-content .woocommerce-ordering label {
  display: block !important;
  font-weight: 600 !important;
  margin-bottom: 0.5rem !important;
  padding-left: 0.75rem !important;
  color: #222 !important;
}

.sidebar-content .woocommerce-ordering select {
  display: block !important;
  width: calc(100% - 1.5rem) !important;
  margin-left: 0.75rem !important;
  padding: 0.5rem !important;
  border-radius: 4px !important;
  border: 1px solid #ccc !important;
  font-size: 0.95rem !important;
  background: #fff !important;
}

/* Product Categories Styling */
.sidebar-content .widget_product_categories ul.product-categories {
  list-style: none !important;
  padding-left: 0 !important;
  margin: 0 !important;
}

.sidebar-content .widget_product_categories ul.product-categories li {
  margin-bottom: 0.5rem !important;
}

.sidebar-content .widget_product_categories ul.product-categories li a {
  display: block !important;
  padding: 0.4rem 0 0.4rem 1.5rem !important;
  color: #0073aa !important;
  text-decoration: none !important;
  border-left: 2px solid transparent !important;
  transition: all 0.2s ease !important;
}

.sidebar-content .widget_product_categories ul.product-categories li a:hover {
  color: #005177 !important;
  border-left-color: #4CAF50 !important;
}

/* Price Filter Matching */
.widget_price_filter .price_slider_wrapper {
  margin-top: 1rem !important;
  padding-left: 0.75rem !important;
}

.widget_price_filter .ui-slider {
  height: 6px !important;
  background-color: #ddd !important;
}

.widget_price_filter .ui-slider-range {
  background-color: #4CAF50 !important;
}

.widget_price_filter .ui-slider-handle {
  background-color: #ff6b35 !important;
  border-radius: 50% !important;
  width: 14px !important;
  height: 14px !important;
  top: 0px !important;
}

.widget_price_filter .price_slider_amount {
  padding-top: 1rem !important;
}

.widget_price_filter .price_label {
  font-weight: 600 !important;
  margin-bottom: 0.5rem !important;
  color: #222 !important;
}

.widget_price_filter .button {
  background-color: #4CAF50 !important;
  color: white !important;
  border: none !important;
  padding: 0.4rem 0.8rem !important;
  border-radius: 4px !important;
  cursor: pointer !important;
  margin-top: 0.5rem !important;
  transition: background-color 0.2s ease !important;
}

.widget_price_filter .button:hover {
  background-color: #FC8C00 !important;
}
