/* Variables */
:root {
    --hexa-primary-color: #2563EB;
    --hexa-accent-color: #1F2937;
    --hexa-border-color: #E5E7EB;
    --hexa-background-color: #FFFFFF;
    --hexa-text-color: #374151;
    --hexa-light-text: #6B7280;
    --hexa-cart-background: #111111;
    --hexa-cart-color: #FFFFFF;
    --hexa-cart-hover-background: #2A2A2A;
    --hexa-cart-height: 56px;
    --hexa-cart-font-size: 16px;
    --hexa-cart-radius: 999px;
    --hexa-whatsapp-background: #25D366;
    --hexa-whatsapp-color: #FFFFFF;
    --hexa-whatsapp-hover-background: #1EBE5D;
    --hexa-whatsapp-size: 56px;
    --hexa-buttons-gap: 12px;
    --hexa-buttons-shadow: 0 8px 20px rgba(17, 24, 39, 0.20);
    --hexa-cart-wa-background: #25D366;
    --hexa-cart-wa-color: #FFFFFF;
    --hexa-cart-wa-hover-background: #1EBE5D;
    --hexa-cart-wa-height: 52px;
    --hexa-cart-wa-font-size: 15px;
    --hexa-cart-wa-radius: 10px;
}

.hexa-filter-wrapper {
    display: flex;
    gap: 2rem;
    width: 100%;
    min-width: 0;
    max-width: 1400px;
    margin: 0 auto;
    box-sizing: border-box;
}

/* Filter Sidebar */
.hexa-filter {
    box-sizing: border-box;
    width: 280px;
    max-width: 100%;
    background-color: var(--hexa-background-color);
    border: 1px solid var(--hexa-border-color);
    border-radius: 8px;
    padding: 1.5rem;
    height: fit-content;
    position: sticky;
    top: 20px;
}

.hexa-filter-backdrop,
.hexa-filter-mobile-header {
    display: none;
}

.hexa-filter-section {
    border-bottom: 1px solid var(--hexa-border-color);
    padding: 1rem 0;
}

.hexa-filter-section:last-of-type {
    border-bottom: none;
}

.hexa-filter-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    user-select: none;
}

.hexa-filter-header h3 {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--hexa-accent-color);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.hexa-toggle-icon {
    font-size: 12px;
    color: var(--hexa-light-text);
    transition: transform 0.3s ease;
}

.hexa-toggle-icon.hexa-active {
    transform: rotate(180deg);
}

.hexa-filter-content {
    margin-top: 1rem;
    display: none;
}

.hexa-filter-content.hexa-active {
    display: block;
}

/* Switch */
.hexa-switch {
    display: flex;
    align-items: center;
    cursor: pointer;
    gap: 0.75rem;
    font-size: 14px;
    color: var(--hexa-text-color);
}

.hexa-switch input {
    display: none;
}

.hexa-slider {
    display: inline-block;
    width: 44px;
    height: 24px;
    background-color: var(--hexa-border-color);
    border-radius: 12px;
    position: relative;
    transition: background-color 0.3s ease;
}

.hexa-slider::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    background-color: white;
    border-radius: 50%;
    top: 2px;
    left: 2px;
    transition: left 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.hexa-switch input:checked + .hexa-slider {
    background-color: var(--hexa-primary-color);
}

.hexa-switch input:checked + .hexa-slider::after {
    left: 22px;
}

/* Price Section */
.hexa-price-info {
    font-size: 12px;
    color: var(--hexa-light-text);
    margin-bottom: 0.5rem;
}

.hexa-price-current-range {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 13px;
    font-weight: 600;
    color: var(--hexa-accent-color);
    margin-bottom: 1rem;
}

.hexa-price-slider-container {
    position: relative;
    margin-bottom: 1.5rem;
}

.hexa-price-slider {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: var(--hexa-border-color);
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    margin-bottom: 0.5rem;
}

.hexa-price-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--hexa-primary-color);
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    transition: all 0.2s ease;
}

.hexa-price-slider::-webkit-slider-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.hexa-price-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--hexa-primary-color);
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    transition: all 0.2s ease;
}

.hexa-price-slider::-moz-range-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* Categories Select */
.hexa-categories-select {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid var(--hexa-border-color);
    border-radius: 4px;
    font-size: 13px;
    color: var(--hexa-text-color);
    background-color: var(--hexa-background-color);
}

.hexa-categories-select option {
    padding: 0.5rem;
}

/* Order Section */
.hexa-order-section {
    border-bottom: none;
    padding: 1rem 0 0 0;
}

.hexa-order-section label {
    display: block;
    font-size: 12px;
    color: var(--hexa-light-text);
    margin-bottom: 0.5rem;
    text-transform: uppercase;
}

.hexa-order-select {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid var(--hexa-border-color);
    border-radius: 4px;
    font-size: 13px;
    color: var(--hexa-text-color);
    background-color: var(--hexa-background-color);
}

/* Buttons */
.hexa-btn-clear {
    width: 100%;
    margin-top: 1rem;
    padding: 0.75rem;
    border: 1px solid var(--hexa-border-color);
    background-color: transparent;
    color: var(--hexa-text-color);
    font-size: 13px;
    font-weight: 500;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.hexa-btn-clear:hover {
    border-color: var(--hexa-primary-color);
    color: var(--hexa-primary-color);
}

.hexa-btn-load-more {
    display: block;
    margin: 2rem auto 0;
    padding: 0.75rem 2rem;
    border: 1px solid var(--hexa-primary-color);
    background-color: var(--hexa-primary-color);
    color: white;
    font-size: 13px;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.hexa-btn-load-more:hover {
    background-color: #1D4ED8;
    border-color: #1D4ED8;
}

/* Products Wrapper */
.hexa-products-wrapper {
    flex: 1;
    position: relative;
}

.hexa-products-container {
    min-height: 400px;
}

.hexa-products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1.5rem;
}

.hexa-no-products {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem 1rem;
    color: var(--hexa-light-text);
}

.woocommerce ul.products li.product img,
ul.products li.product img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: contain;
}

ul.products.hexa-filtered-products {
    align-items: start;
}

ul.products.hexa-filtered-products li.product {
    align-self: start;
    height: auto !important;
    max-width: 100%;
    overflow: hidden;
}

ul.products.hexa-filtered-products li.product .woocommerce-LoopProduct-link {
    display: block;
    height: auto !important;
}

ul.products.hexa-filtered-products li.product .hexa-product-image-frame {
    display: block !important;
    width: 100%;
    aspect-ratio: 1 / 1;
    background-color: #F9FAFB;
    background-position: center;
    background-repeat: no-repeat;
    background-size: contain;
    border-radius: inherit;
    overflow: hidden;
}

ul.products.hexa-filtered-products li.product .woocommerce-LoopProduct-link img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: contain;
}

ul.products.hexa-filtered-products li.product img.hexa-product-image {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    object-position: center;
}

.hexa-product-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    column-gap: var(--hexa-buttons-gap);
    row-gap: 8px;
    width: 100%;
    min-width: 0;
    max-width: 100%;
    margin-top: 1rem;
    box-sizing: border-box;
}

.woocommerce ul.products li.product .hexa-product-actions .button,
ul.products li.product .hexa-product-actions .button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    margin: 0;
    border: 0;
    max-width: 100%;
    overflow: hidden;
    text-decoration: none !important;
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.woocommerce ul.products li.product .hexa-product-actions .button::before,
.woocommerce ul.products li.product .hexa-product-actions .button::after,
ul.products li.product .hexa-product-actions .button::before,
ul.products li.product .hexa-product-actions .button::after {
    content: none !important;
    display: none !important;
}

.woocommerce ul.products li.product .hexa-product-actions .hexa-cart-button,
ul.products li.product .hexa-product-actions .hexa-cart-button {
    background: var(--hexa-cart-background) !important;
    color: var(--hexa-cart-color) !important;
    font-size: var(--hexa-cart-font-size);
    font-weight: 700;
    line-height: 1.15 !important;
}

.woocommerce ul.products li.product .hexa-product-actions .hexa-cart-button:hover,
.woocommerce ul.products li.product .hexa-product-actions .hexa-cart-button:focus-visible,
ul.products li.product .hexa-product-actions .hexa-cart-button:hover,
ul.products li.product .hexa-product-actions .hexa-cart-button:focus-visible {
    background: var(--hexa-cart-hover-background) !important;
    color: var(--hexa-cart-color) !important;
    transform: translateY(-1px);
}

.woocommerce ul.products li.product .hexa-product-actions .hexa-whatsapp-button,
ul.products li.product .hexa-product-actions .hexa-whatsapp-button {
    background: var(--hexa-whatsapp-background) !important;
    color: var(--hexa-whatsapp-color) !important;
    font-size: 14px;
    font-weight: 700;
}

.woocommerce ul.products li.product .hexa-product-actions .hexa-whatsapp-button:hover,
.woocommerce ul.products li.product .hexa-product-actions .hexa-whatsapp-button:focus-visible,
ul.products li.product .hexa-product-actions .hexa-whatsapp-button:hover,
ul.products li.product .hexa-product-actions .hexa-whatsapp-button:focus-visible {
    background: var(--hexa-whatsapp-hover-background) !important;
    color: var(--hexa-whatsapp-color) !important;
    transform: translateY(-1px);
}

.woocommerce ul.products li.product .hexa-product-actions .hexa-action-primary,
ul.products li.product .hexa-product-actions .hexa-action-primary {
    order: 1;
    flex: 1 1 0%;
    min-width: 0;
    width: auto;
    padding: 0 22px;
    gap: 10px;
    box-shadow: var(--hexa-buttons-shadow);
}

.woocommerce ul.products li.product .hexa-product-actions .hexa-cart-button.hexa-action-primary,
ul.products li.product .hexa-product-actions .hexa-cart-button.hexa-action-primary {
    height: var(--hexa-cart-height);
    border-radius: var(--hexa-cart-radius);
}

.woocommerce ul.products li.product .hexa-product-actions .hexa-whatsapp-button.hexa-action-primary,
ul.products li.product .hexa-product-actions .hexa-whatsapp-button.hexa-action-primary {
    height: var(--hexa-whatsapp-size);
    border-radius: 999px;
}

.woocommerce ul.products li.product .hexa-product-actions .hexa-action-secondary,
ul.products li.product .hexa-product-actions .hexa-action-secondary {
    order: 2;
    flex: 0 0 auto;
    width: var(--hexa-whatsapp-size);
    min-width: var(--hexa-whatsapp-size);
    height: var(--hexa-whatsapp-size);
    padding: 0;
    border-radius: 50%;
    box-shadow: var(--hexa-buttons-shadow);
}

.woocommerce ul.products li.product .hexa-product-actions .hexa-cart-button.hexa-action-secondary,
ul.products li.product .hexa-product-actions .hexa-cart-button.hexa-action-secondary {
    width: var(--hexa-cart-height);
    min-width: var(--hexa-cart-height);
    height: var(--hexa-cart-height);
}

.hexa-product-actions .hexa-action-secondary .hexa-button-label {
    display: none;
}

.hexa-product-actions .hexa-button-icon {
    display: block;
    flex: 0 0 auto;
    width: 25px;
    height: 25px;
}

.hexa-product-actions .hexa-cart-icon {
    fill: none;
    stroke: currentColor;
    stroke-width: 2.2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.hexa-product-actions .hexa-whatsapp-icon {
    width: 29px;
    height: 29px;
    fill: currentColor;
}

.hexa-product-actions .hexa-button-label {
    min-width: 0;
    padding: 0 !important;
    border: 0 !important;
    overflow: hidden;
    background: transparent !important;
    box-shadow: none !important;
    color: inherit !important;
    line-height: inherit !important;
    text-overflow: ellipsis;
    transform: none !important;
    white-space: nowrap;
}

.hexa-product-actions .hexa-button-label--compact {
    display: none;
}

.hexa-product-actions.hexa-actions-compact {
    gap: min(var(--hexa-buttons-gap), 8px);
}

.woocommerce ul.products li.product .hexa-product-actions.hexa-actions-compact .hexa-action-primary,
ul.products li.product .hexa-product-actions.hexa-actions-compact .hexa-action-primary {
    padding-right: 10px;
    padding-left: 10px;
    gap: 6px;
}

.woocommerce ul.products li.product .hexa-product-actions.hexa-actions-compact .hexa-cart-button.hexa-action-primary,
ul.products li.product .hexa-product-actions.hexa-actions-compact .hexa-cart-button.hexa-action-primary {
    height: min(var(--hexa-cart-height), 50px);
    font-size: min(var(--hexa-cart-font-size), 13px);
}

.woocommerce ul.products li.product .hexa-product-actions.hexa-actions-compact .hexa-whatsapp-button.hexa-action-primary,
ul.products li.product .hexa-product-actions.hexa-actions-compact .hexa-whatsapp-button.hexa-action-primary {
    height: min(var(--hexa-whatsapp-size), 50px);
    font-size: 13px;
}

.woocommerce ul.products li.product .hexa-product-actions.hexa-actions-compact .hexa-action-secondary,
ul.products li.product .hexa-product-actions.hexa-actions-compact .hexa-action-secondary {
    width: min(var(--hexa-whatsapp-size), 48px);
    min-width: min(var(--hexa-whatsapp-size), 48px);
    height: min(var(--hexa-whatsapp-size), 48px);
}

.woocommerce ul.products li.product .hexa-product-actions.hexa-actions-compact .hexa-cart-button.hexa-action-secondary,
ul.products li.product .hexa-product-actions.hexa-actions-compact .hexa-cart-button.hexa-action-secondary {
    width: min(var(--hexa-cart-height), 48px);
    min-width: min(var(--hexa-cart-height), 48px);
    height: min(var(--hexa-cart-height), 48px);
}

.hexa-product-actions.hexa-actions-compact .hexa-cart-button .hexa-button-label--full {
    display: none;
}

.hexa-product-actions.hexa-actions-compact .hexa-cart-button.hexa-action-primary .hexa-button-label--compact {
    display: inline;
}

.hexa-product-actions.hexa-actions-compact .hexa-cart-icon {
    width: 21px;
    height: 21px;
}

.hexa-product-actions.hexa-actions-compact .hexa-whatsapp-icon {
    width: 26px;
    height: 26px;
}

.hexa-product-actions.hexa-actions-narrow {
    gap: min(var(--hexa-buttons-gap), 6px);
}

.woocommerce ul.products li.product .hexa-product-actions.hexa-actions-narrow .hexa-action-primary,
ul.products li.product .hexa-product-actions.hexa-actions-narrow .hexa-action-primary {
    padding-right: 8px;
    padding-left: 8px;
    gap: 4px;
}

.woocommerce ul.products li.product .hexa-product-actions.hexa-actions-narrow .hexa-action-secondary,
ul.products li.product .hexa-product-actions.hexa-actions-narrow .hexa-action-secondary {
    width: min(var(--hexa-whatsapp-size), 44px);
    min-width: min(var(--hexa-whatsapp-size), 44px);
    height: min(var(--hexa-whatsapp-size), 44px);
}

.woocommerce ul.products li.product .hexa-product-actions.hexa-actions-narrow .hexa-cart-button.hexa-action-secondary,
ul.products li.product .hexa-product-actions.hexa-actions-narrow .hexa-cart-button.hexa-action-secondary {
    width: min(var(--hexa-cart-height), 44px);
    min-width: min(var(--hexa-cart-height), 44px);
    height: min(var(--hexa-cart-height), 44px);
}

.woocommerce ul.products li.product .hexa-product-actions.hexa-actions-narrow .hexa-cart-button.hexa-action-primary,
ul.products li.product .hexa-product-actions.hexa-actions-narrow .hexa-cart-button.hexa-action-primary,
.woocommerce ul.products li.product .hexa-product-actions.hexa-actions-narrow .hexa-whatsapp-button.hexa-action-primary,
ul.products li.product .hexa-product-actions.hexa-actions-narrow .hexa-whatsapp-button.hexa-action-primary {
    height: 44px;
    font-size: 12px;
}

.hexa-product-actions .hexa-cart-button.loading {
    opacity: 0.7;
}

.hexa-product-actions .added_to_cart {
    display: inline-flex !important;
    order: 3;
    flex: 1 0 100%;
    align-items: center;
    justify-content: center;
    gap: 7px;
    width: 100%;
    min-height: 34px;
    margin: 0 !important;
    padding: 7px 12px !important;
    border: 1px solid #E5E7EB;
    border-radius: 9px;
    box-sizing: border-box;
    background: #F8FAFC;
    color: #111827 !important;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.2;
    text-align: center;
    text-decoration: none !important;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.hexa-product-actions .added_to_cart::before {
    display: inline-flex;
    flex: 0 0 18px;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #16A34A;
    color: #FFFFFF;
    content: "✓";
    font-size: 11px;
    font-weight: 800;
    line-height: 1;
}

.hexa-product-actions .added_to_cart::after {
    content: none !important;
    display: none !important;
}

.hexa-product-actions .added_to_cart:hover,
.hexa-product-actions .added_to_cart:focus-visible {
    border-color: #111827;
    background: #111827;
    color: #FFFFFF !important;
    transform: translateY(-1px);
}

.hexa-product-actions .added_to_cart:focus-visible {
    outline: 2px solid var(--hexa-primary-color);
    outline-offset: 2px;
}

.hexa-product-actions .screen-reader-text {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* WhatsApp order button: cart page and mini cart */
.woocommerce .wc-proceed-to-checkout .hexa-cart-whatsapp-order,
.woocommerce-mini-cart__buttons .hexa-cart-whatsapp-order,
.widget_shopping_cart_content .hexa-cart-whatsapp-order,
.elementor-menu-cart__footer-buttons .hexa-cart-whatsapp-order {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    min-height: var(--hexa-cart-wa-height);
    margin: 10px 0 0;
    padding: 10px 18px;
    box-sizing: border-box;
    border: 0;
    border-radius: var(--hexa-cart-wa-radius);
    background: var(--hexa-cart-wa-background) !important;
    color: var(--hexa-cart-wa-color) !important;
    font-size: var(--hexa-cart-wa-font-size);
    font-weight: 700;
    line-height: 1.2;
    text-align: center;
    text-decoration: none !important;
    box-shadow: 0 7px 18px rgba(37, 211, 102, 0.20);
    transition: background-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.woocommerce .wc-proceed-to-checkout .hexa-cart-whatsapp-order:hover,
.woocommerce .wc-proceed-to-checkout .hexa-cart-whatsapp-order:focus-visible,
.woocommerce-mini-cart__buttons .hexa-cart-whatsapp-order:hover,
.woocommerce-mini-cart__buttons .hexa-cart-whatsapp-order:focus-visible,
.widget_shopping_cart_content .hexa-cart-whatsapp-order:hover,
.widget_shopping_cart_content .hexa-cart-whatsapp-order:focus-visible,
.elementor-menu-cart__footer-buttons .hexa-cart-whatsapp-order:hover,
.elementor-menu-cart__footer-buttons .hexa-cart-whatsapp-order:focus-visible {
    background: var(--hexa-cart-wa-hover-background) !important;
    color: var(--hexa-cart-wa-color) !important;
    transform: translateY(-1px);
    box-shadow: 0 9px 22px rgba(37, 211, 102, 0.27);
}

.hexa-cart-whatsapp-order .hexa-whatsapp-icon {
    flex: 0 0 auto;
    width: 25px;
    height: 25px;
    fill: currentColor;
}

.hexa-cart-whatsapp-order__label {
    min-width: 0;
}

.hexa-mini-cart-whatsapp-fragment {
    display: none !important;
}

.elementor-menu-cart__footer-buttons .hexa-cart-whatsapp-order {
    grid-column: 1 / -1;
    flex: 0 0 100%;
}

/* Loader */
.hexa-products-loader {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 100;
}

.hexa-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--hexa-border-color);
    border-top-color: var(--hexa-primary-color);
    border-radius: 50%;
    animation: hexa-spin 0.8s linear infinite;
}

@keyframes hexa-spin {
    to {
        transform: rotate(360deg);
    }
}

/* Filter Toggle (Mobile) */
.hexa-filter-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 0.75rem 1rem;
    background-color: var(--hexa-primary-color);
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
}

.hexa-filter-toggle-icon {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    body.hexa-filter-open {
        overflow: hidden;
    }

    .hexa-filter-wrapper {
        flex-direction: column;
        gap: 1.5rem;
        width: 100%;
        min-width: 0;
        box-sizing: border-box;
    }

    .hexa-filter {
        display: block;
        width: min(92vw, 420px);
        max-width: 420px;
        height: 100vh;
        height: 100dvh;
        max-height: 100vh;
        max-height: 100dvh;
        margin: 0;
        padding: 0 20px calc(24px + env(safe-area-inset-bottom));
        position: fixed;
        top: 0;
        left: 0;
        right: auto;
        bottom: 0;
        z-index: 2147483000;
        border: 0;
        border-right: 1px solid rgba(17, 24, 39, 0.10);
        border-radius: 0;
        overflow-y: auto;
        overscroll-behavior: contain;
        background: var(--hexa-background-color);
        box-shadow: 18px 0 45px rgba(15, 23, 42, 0.22);
        transform: translate3d(-105%, 0, 0);
        visibility: hidden;
        -webkit-overflow-scrolling: touch;
        touch-action: pan-y;
        transition: transform 0.28s ease, visibility 0.28s ease;
        will-change: transform;
    }

    .hexa-filter.hexa-mobile.hexa-active {
        transform: translate3d(0, 0, 0);
        visibility: visible;
    }

    .hexa-filter-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        z-index: 2147482999;
        background: rgba(15, 23, 42, 0.52);
        opacity: 0;
        visibility: hidden;
        cursor: pointer;
        transition: opacity 0.28s ease, visibility 0.28s ease;
        -webkit-backdrop-filter: blur(2px);
        backdrop-filter: blur(2px);
    }

    .hexa-filter-backdrop.hexa-active {
        opacity: 1;
        visibility: visible;
    }

    .hexa-filter-mobile-header {
        display: flex;
        position: sticky;
        top: 0;
        z-index: 3;
        align-items: center;
        justify-content: space-between;
        gap: 16px;
        min-height: 66px;
        margin: 0 -20px 8px;
        padding: calc(12px + env(safe-area-inset-top)) 20px 12px;
        border-bottom: 1px solid var(--hexa-border-color);
        background: var(--hexa-background-color);
        box-shadow: 0 5px 14px rgba(15, 23, 42, 0.05);
    }

    .hexa-filter-mobile-header > div {
        display: flex;
        flex-direction: column;
        gap: 2px;
    }

    .hexa-filter-mobile-header strong {
        color: var(--hexa-accent-color);
        font-size: 17px;
        line-height: 1.2;
    }

    .hexa-filter-mobile-eyebrow {
        color: var(--hexa-primary-color);
        font-size: 10px;
        font-weight: 700;
        letter-spacing: 0.08em;
        text-transform: uppercase;
    }

    .hexa-filter-close {
        display: inline-flex;
        position: relative;
        flex: 0 0 42px;
        align-items: center;
        justify-content: center;
        width: 42px;
        height: 42px;
        padding: 0;
        border: 1px solid var(--hexa-border-color);
        border-radius: 50%;
        background: #f8fafc;
        color: var(--hexa-accent-color);
        cursor: pointer;
    }

    .hexa-filter-close:hover,
    .hexa-filter-close:focus-visible {
        border-color: var(--hexa-primary-color);
        background: #ffffff;
        color: var(--hexa-primary-color);
    }

    .hexa-filter-close:focus-visible {
        outline: 2px solid var(--hexa-primary-color);
        outline-offset: 2px;
    }

    .hexa-filter-close span,
    .hexa-filter-close span::after {
        display: block;
        position: absolute;
        width: 18px;
        height: 2px;
        border-radius: 2px;
        background: currentColor;
        content: "";
        transform: rotate(45deg);
    }

    .hexa-filter-close span::after {
        transform: rotate(90deg);
    }

    .hexa-filter-toggle {
        display: inline-flex;
        position: relative;
        z-index: 2;
        min-height: 46px;
        border-radius: 8px;
        box-shadow: 0 5px 14px rgba(37, 99, 235, 0.16);
    }

    .hexa-products-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    body.admin-bar .hexa-filter {
        top: 46px;
        height: calc(100vh - 46px);
        height: calc(100dvh - 46px);
        max-height: calc(100vh - 46px);
        max-height: calc(100dvh - 46px);
    }
}

@media (max-width: 480px) {
    .hexa-filter {
        width: min(94vw, 420px);
    }

    .hexa-products-grid {
        grid-template-columns: 1fr;
    }

    .woocommerce ul.products li.product .hexa-product-actions .hexa-cart-button,
    ul.products li.product .hexa-product-actions .hexa-cart-button {
        padding-right: 14px;
        padding-left: 14px;
        gap: 7px;
    }

    .hexa-product-actions .hexa-cart-icon {
        width: 22px;
        height: 22px;
    }
}

/* Elementor Compatibility */
.elementor-widget-hexa_filter_widget .hexa-filter-wrapper {
    margin: 0;
}

/*
 * Elementor/WooCommerce can calculate grid columns from the intrinsic width of
 * their contents. Keep the controls shrinkable so a long label cannot expand
 * the products column before the filter is used.
 */
.woocommerce ul.products,
.elementor-products-grid ul.products.elementor-grid {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
}

.woocommerce ul.products li.product,
.elementor-products-grid ul.products.elementor-grid li.product {
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
}

.elementor-column:has(.hexa-filter-wrapper),
.elementor-column:has(.hexa-product-actions),
.elementor-widget-wrap:has(.hexa-filter-wrapper),
.elementor-widget-wrap:has(.hexa-product-actions),
.elementor-widget-container:has(.hexa-filter-wrapper),
.elementor-widget-container:has(.hexa-product-actions) {
    min-width: 0;
}
